udf: Avoid run away loop when partition table length is corrupted
authorJan Kara <jack@suse.cz>
Wed, 27 Jun 2012 18:20:22 +0000 (20:20 +0200)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Wed, 16 Jan 2013 21:45:05 +0000 (16:45 -0500)
commitd7542a6eb171336db2101522803f46e6e624bd1f
treecc32d28886ee5219e0f983a3e179d1ce7eded8cf
parent9ae30e324a96d0328a575329d7a95a09b3318601
udf: Avoid run away loop when partition table length is corrupted

commit adee11b2085bee90bd8f4f52123ffb07882d6256 upstream.

Check provided length of partition table so that (possibly maliciously)
corrupted partition table cannot cause accessing data beyond current buffer.

Signed-off-by: Jan Kara <jack@suse.cz>
[PG: in 2.6.34 udf_err() is called udf_error()]
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
fs/udf/super.c