summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorZhengYuan Huang <gality369@gmail.com>2026-05-08 11:59:14 +0300
committerAndrew Morton <akpm@linux-foundation.org>2026-05-29 07:24:48 +0300
commitbda614e6b4f27d3535ee86a96a6bab3b9b4f5e87 (patch)
tree1007bc270c24a2c2f533efd58e5bb9c4b76fc3c4 /scripts
parent4523ba0ee2e9ab6ee9c4b20b2867c3e4aa01f503 (diff)
downloadlinux-bda614e6b4f27d3535ee86a96a6bab3b9b4f5e87.tar.xz
ocfs2: validate inline xattr header before reflinking inline xattrs
[BUG] A corrupt inline xattr header can make ocfs2_reflink_xattr_inline() lock, copy, and reflink xattr state from an unchecked ibody xattr header. [CAUSE] The inline reflink path still trusted di->i_xattr_inline_size to compute header_off, xh, and new_xh before handing the source header to the reflink allocator and copy logic. [FIX] Validate the source inode's inline xattr header with the shared helper first, then derive the reflink copy offsets from the validated inline size/header. This keeps the reflink path from traversing corrupt ibody xattr geometry. Link: https://lore.kernel.org/20260508085914.61647-6-gality369@gmail.com Signed-off-by: ZhengYuan Huang <gality369@gmail.com> Reviewed-by: Joseph Qi <joseph.qi@linux.alibaba.com> Cc: Changwei Ge <gechangwei@live.cn> Cc: Heming Zhao <heming.zhao@suse.com> Cc: Jia-Ju Bai <baijiaju1990@gmail.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Jun Piao <piaojun@huawei.com> Cc: Junxiao Bi <junxiao.bi@oracle.com> Cc: Mark Fasheh <mark@fasheh.com> Cc: Zixuan Fu <r33s3n6@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions