]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
udf: Check path length when reading symlink
authorJan Kara <jack@suse.cz>
Thu, 18 Dec 2014 21:37:50 +0000 (22:37 +0100)
committerJiri Slaby <jslaby@suse.cz>
Mon, 16 Feb 2015 15:10:55 +0000 (16:10 +0100)
commitebfce5ccba81292a5e34710a602117769118fa9a
tree7bc3a8e83a4373446b6a8da95e27fe43601f9231
parent4ff6c40be897225cf818c5202871cfb91ed064f6
udf: Check path length when reading symlink

commit 0e5cc9a40ada6046e6bc3bdfcd0c0d7e4b706b14 upstream.

Symlink reading code does not check whether the resulting path fits into
the page provided by the generic code. This isn't as easy as just
checking the symlink size because of various encoding conversions we
perform on path. So we have to check whether there is still enough space
in the buffer on the fly.

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