Nytro Posted January 29, 2014 Report Posted January 29, 2014 Detecting Custom Memory Allocators in C BinariesXi Chen Asia Slowinska Herbert BosVrije Universiteit Amsterdam, The NetherlandsAbstract—Many reversing techniques for data structures relyon the knowledge of memory allocation routines. Typically, theyinterpose on the system’s malloc and free functions, and trackeach chunk of memory thus allocated as a data structure. How-ever, many performance-critical applications implement theirown custom memory allocators. Examples include webservers,database management systems, and compilers like gcc and clang.As a result, current binary analysis techniques for tracking datastructures fail on such binaries.We present MemBrush, a new tool to detect memory allocationand deallocation functions in stripped binaries with high accu-racy. We evaluated the technique on a large number of real worldapplications that use custom memory allocators. As we show, wecan furnish existing reversing tools with detailed informationabout the memory management API, and as a result perform ananalysis of the actual application specific data structures designedby the programmer. Our system uses dynamic analysis anddetects memory allocation and deallocation routines by searchingfor functions that comply with a set of generic characteristics ofallocators and deallocators.Download:http://www.cs.vu.nl/~herbertb/papers/membrush_wcre13.pdf Quote