PINDemonium: A DBI-Based Generic Unpacker for Windows Executables by Sebastiano Mariani and Lorenzo Fontana
Malware Unpacking by Stefano Maccaglia
In this work we explored the possibility to exploit the functionality of a dynamic binary instrumentation framework to perform runtime unpacking. Our system can extract and reconstruct the original program from a packed version of it, speeding up the analysis of an obfuscated binary. Packers employ different techniques with various levels of complexity, but all of them must share one common behavior during the run-time unpacking: they have to write new code in memory and eventually execute it. Starting from this observation, we have designed a generic unpacking algorithm that can correctly detect this behavior and defeat the most popular packing techniques. Our tool also takes care of other modern techniques such as unpacking on dynamic memory allocated areas, and Import Address Table (IAT) obfuscation. When it is not possible to reconstruct a fully working PE, we provide all the memory dumps, representing the unpacked program along with a log of the unpacking process, which can be useful to malware analysts to speed up their task.
To validate our work, we have conducted two experiments: the first one demonstrates the generality of our unpacking process with respect to fifteen different known packers, while the second one demonstrates the effectiveness of our system against malware samples packed with both known and unknown packers.