Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit a47241cd authored by Alden Tondettar's avatar Alden Tondettar Committed by Jan Kara
Browse files

udf: Prevent stack overflow on corrupted filesystem mount



Presently, a corrupted or malicious UDF filesystem containing a very large
number (or cycle) of Logical Volume Integrity Descriptor extent
indirections may trigger a stack overflow and kernel panic in
udf_load_logicalvolint() on mount.

Replace the unnecessary recursion in udf_load_logicalvolint() with
simple iteration. Set an arbitrary limit of 1000 indirections (which would
have almost certainly overflowed the stack without this fix), and treat
such cases as if there were no LVID.

Signed-off-by: default avatarAlden Tondettar <alden.tondettar@gmail.com>
Signed-off-by: default avatarJan Kara <jack@suse.cz>
parent c26f6c61
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment