Certificate Bypass: Hiding and Executing Malware from a Digitally Signed Executable

Black Hat USA 2016

Presented by: Tom Nipravsky
Date: Wednesday August 03, 2016
Time: 13:50 - 14:15
Location: South Seas IJ

Malware developers are constantly looking for new ways to evade the detection and prevention capabilities of security solutions. In recent years, we have seen many different tools, such as packers and new encryption techniques, help malware reach this goal of hiding the malicious code. If the security solution cannot unpack the compressed or encrypted malicious content (or at least unpack it dynamically), then the security solution will not be able to identify that it is facing malware. To further complicate the matter, we present a new technique for hiding malware (encrypted and unencrypted) inside a digitally signed file (while still keeping the file with a valid certificate) and executing it from the memory, using a benign executable (which acts as a reflective EXE loader, written from scratch). Our research demonstrates our Certificate Bypass tool and the Reflective EXE Loader. During the presentation, we will focus on the research we conducted on the PE file structure. We will take a closer look at the certificate table and how we can inject data to the table without damaging the certificate itself (the file will still look and be treated as a valid digitally signed file). We will examine the tool we wrote to execute PE files from memory (without writing them to the disk). We will cover the relevant fields in the PE structure, as well as the steps required to run a PE file directly from the memory without requiring any files on disk. Last, we will conclude the demonstration with a live example and show how we bypass security solutions based on the way they look at the certificate table.

Tom Nipravsky

Tom Nipravsky is a security researcher for Deep Instinct, specializing inmalware development. Tom has over five years experience in an elitetechnological operational unit in the Intelligence department of the IsraeliDefense Forces. He also has several years of experience in several leadinginternational companies, where his main area of expertise was developingsophisticated malware to reveal flaws in the protection process of leadingsecurity vendors. In addition, Tom is also a pianist and a performingmusician.


KhanFu - Mobile schedules for INFOSEC conferences.
Mobile interface | Alternate Formats