Re: [PATCH] PR other/54411: libiberty: objalloc_alloc integer overflows (CVE-2012-3509)

2012-09-18 Thread Florian Weimer
On 09/17/2012 05:59 PM, Ian Lance Taylor wrote: Fair enough. I've added a wraparound check to the macro. Okay for trunk? { + unsigned long len = original_len; /* We avoid confusion from zero sized objects by always allocating at least 1 byte. */ Please add a blank line

Re: [PATCH] PR other/54411: libiberty: objalloc_alloc integer overflows (CVE-2012-3509)

2012-09-17 Thread Florian Weimer
On 09/05/2012 07:31 AM, Ian Lance Taylor wrote: On Wed, Aug 29, 2012 at 10:32 AM, Florian Weimer f...@deneb.enyo.de wrote: This patches fixes an integer overflow in libiberty, which leads to crashes in binutils. The long version of the objalloc_alloc macro would have needed another

Re: [PATCH] PR other/54411: libiberty: objalloc_alloc integer overflows (CVE-2012-3509)

2012-09-17 Thread Ian Lance Taylor
On Mon, Sep 17, 2012 at 2:49 AM, Florian Weimer fwei...@redhat.com wrote: On 09/05/2012 07:31 AM, Ian Lance Taylor wrote: On Wed, Aug 29, 2012 at 10:32 AM, Florian Weimer f...@deneb.enyo.de wrote: This patches fixes an integer overflow in libiberty, which leads to crashes in binutils. The

Re: [PATCH] PR other/54411: libiberty: objalloc_alloc integer overflows (CVE-2012-3509)

2012-09-04 Thread Ian Lance Taylor
On Wed, Aug 29, 2012 at 10:32 AM, Florian Weimer f...@deneb.enyo.de wrote: This patches fixes an integer overflow in libiberty, which leads to crashes in binutils. The long version of the objalloc_alloc macro would have needed another conditional, so I removed that and replaced it with a

[PATCH] PR other/54411: libiberty: objalloc_alloc integer overflows (CVE-2012-3509)

2012-08-29 Thread Florian Weimer
This patches fixes an integer overflow in libiberty, which leads to crashes in binutils. The long version of the objalloc_alloc macro would have needed another conditional, so I removed that and replaced it with a call to the actual implementation. This has been compiled-tested only. We do not