Re: [PATCH 1/2] setup_arg_pages can insert overlapping vma

From: Chris Wright
Date: Thu Nov 18 2004 - 14:02:35 EST


* Hugh Dickins (hugh@xxxxxxxxxxx) wrote:
> On Tue, 16 Nov 2004, Chris Wright wrote:
> > Florian Heinz built an a.out binary that could map bss from 0x0 to
> > 0xc0000000, and setup_arg_pages() would BUG() in insert_vma_struct
> > because the arg pages overlapped. This just checks before inserting,
> > and bails out if it would overlap.
>
> Chris, shouldn't your patch also cover the setup_arg_pages clones for
> 32-bit support on 64-bit architectures, with something - uncompiled,
> untested - like the below? I'm not sure how necessary the additional
> vma->vm_start < mpnt->vm_end test is, but suspect ia64 might need it.

I expect other arches should need the fix as well, it would be nice
to test them. I'm not clear on that extra test. Wouldn't it imply
vm_end < vm_start?

thanks,
-chris
--
Linux Security Modules http://lsm.immunix.org http://lsm.bkbits.net
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/