]> git.ipfire.org Git - people/ms/linux.git/commit
udf: Check component length before reading it
authorJan Kara <jack@suse.cz>
Fri, 19 Dec 2014 13:27:55 +0000 (14:27 +0100)
committerJiri Slaby <jslaby@suse.cz>
Mon, 16 Feb 2015 15:10:56 +0000 (16:10 +0100)
commitc94011ac6ae0bbfc8966ec256ad7b1bf30feaeec
tree47768c3a148fc64650554dd4ab2cfc6fa4b223eb
parentebfce5ccba81292a5e34710a602117769118fa9a
udf: Check component length before reading it

commit e237ec37ec154564f8690c5bd1795339955eeef9 upstream.

Check that length specified in a component of a symlink fits in the
input buffer we are reading. Also properly ignore component length for
component types that do not use it. Otherwise we read memory after end
of buffer for corrupted udf image.

Reported-by: Carl Henrik Lunde <chlunde@ping.uio.no>
CC: stable@vger.kernel.org
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
fs/udf/symlink.c