]> git.ipfire.org Git - thirdparty/linux.git/commit
f2fs: validate inline dentry name lengths before conversion
authorSamuel Moelius <sam.moelius@trailofbits.com>
Wed, 3 Jun 2026 15:11:40 +0000 (15:11 +0000)
committerJaegeuk Kim <jaegeuk@kernel.org>
Mon, 22 Jun 2026 19:52:36 +0000 (19:52 +0000)
commitcfcd0e49a178b3dac2c0ece656079081dbf5da74
tree9530e49895ea945356dd4ed4abd95816b1f352c6
parenta41075acde0124d2f8a5f563068a5d63e8ffd57b
f2fs: validate inline dentry name lengths before conversion

Inline dentry conversion copies names out of the inline dentry area
before checking that each recorded name length fits in the available
filename slots.

A corrupted image can therefore make the conversion path read past
the inline filename storage while building the regular dentry block.

Validate each inline dentry name length against the inline filename
area before copying it.

Assisted-by: Codex:gpt-5.5-cyber-preview
Signed-off-by: Samuel Moelius <samuel.moelius@trailofbits.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/inline.c