Date: Sun, 22 Mar 2009 13:42:41 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: cvs-src-old@freebsd.org Subject: cvs commit: src/sys/kern imgact_elf.c Message-ID: <200903221342.n2MDguq0033752@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
kib 2009-03-22 13:42:41 UTC FreeBSD src repository Modified files: sys/kern imgact_elf.c Log: SVN rev 190264 on 2009-03-22 13:42:41Z by kib Fix several issues with parsing the notes for ELF objects. Badly formed ELF note may cause the caclulated pointer to the next note to point both after the note region, that was checked in the code, but also to point before the region, that was not checked [1]. Remember the first note location in note0 and leap out if the note is not between note0 and note_end. In the similar way, badly formed note may cause infinite loop by pointing next note into the same or previous note. Guard against this by limiting amount of loop iterations by arbitrary choosen big number. For clarity, check the calculated note alignment in each iteration. Reported by: Chris Palmer <chris noncombatant org> [1] PR: kern/132886 Reviewed and tested by: dchagin MFC after: 3 days Revision Changes Path 1.196 +5 -5 src/sys/kern/imgact_elf.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200903221342.n2MDguq0033752>