[32665] in bugtraq

home help back first fref pref prev next nref lref last post

Re: [ANNOUNCE] glibc heap protection patch

daemon@ATHENA.MIT.EDU (Stefan Esser)
Wed Dec 3 14:54:46 2003

Message-ID: <3FCDDEB3.8050006@nopiracy.de>
Date: Wed, 03 Dec 2003 14:01:39 +0100
From: Stefan Esser <se@nopiracy.de>
MIME-Version: 1.0
To: William Robertson <wkr@cs.ucsb.edu>
Cc: Stefan Esser <stefan@suspekt.org>, sectools@securityfocus.com,
        bugtraq@securityfocus.com, focus-ids@securityfocus.com
In-Reply-To: <349B64A4-24EB-11D8-8B1F-000A95675F0E@cs.ucsb.edu>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

William Robertson wrote:

> This is true in the case of the fd and bk pointers, and in fact this 
> is one of the checks that dlmalloc's debugging code performs.  
> However, as we also demonstrated in the paper, you are still open to 
> other heap-related attacks, such as overwriting size fields and 
> setting up fake chunk headers.  So, unfortunately I don't think that 
> check alone is sufficient.

The last time I checked there was no such check in the unlink macro (no 
matter if debug mode or not). Overwriting size fields and setting up 
fake chunk headers are the standard way to exploit malloc()/free() 
structures. And you should rethink about my unlink macro. It perfectly 
stops ALL
heap attacks that try to make use of the unlink macro (and this are the 
most out there). I know that modifying unlink does not protect against 
frontlink attacks. But most heap exploiters do not even know that there 
is anything else than unlink. I never said that the unlink macro is the 
ultimate solution to all heap problems, but it is certainly securer to 
check the pointers on unlink than protecting it only with magic numbers. 
The best solution would be a combination of both.

Ohh btw... Feel free to demonstrate me an unlink exploit that works 
while my unlink macro
is in place... In the last two years I nearly only concentrated on heap 
exploits on a various
number of platforms. glibc/bsd/solaris/windows and I even exploited the 
heap on XBOX
with my dashboard-font exploit. So I very much doubt that my statement 
was incorrect.

Stefan Esser



home help back first fref pref prev next nref lref last post