nday
CVE-2025-40246

xfs: fix out of bounds memory read error in symlink repair

Linux / Linux

披露于 。本站尚未获取修复依据,不能据此认为没有补丁。四个 PoC 来源都还没有收录。尚未列入 CISA KEV。

标签 产品Linux kernel 产品类型操作系统
这些标签的依据

这些标签由 nday 按固定规则从下列事实自动推导,不是 NVD、编号分配方或其他来源给出的。全部标签和规则见 ~/tags。

Linux kernel
CVE 记录列出的受影响产品:Linux · Linux
操作系统
CVE 记录列出的受影响产品:Linux · Linuxnday 产品登记表中 Linux kernel 的产品类型
当前阶段
DIS
披露
CVSS
暂无评分

生命周期

横轴 UTC;点=精确到分钟,宽条=仅日期,空心=未知或推定。
时间未知
DIS披露
2025-12-04T16:08Z
PAT补丁
尚无记录
ANA分析
尚无记录
POCPoC
尚无记录
ITW在野
尚无记录
KEVKEV
尚无记录

摘要

In the Linux kernel, the following vulnerability has been resolved:

xfs: fix out of bounds memory read error in symlink repair

xfs/286 produced this report on my test fleet:

==================================================================
BUG: KFENCE: out-of-bounds read in memcpy_orig+0x54/0x110

Out-of-bounds read at 0xffff88843fe9e038 (184B right of kfence-#184):
 memcpy_orig+0x54/0x110
 xrep_symlink_salvage_inline+0xb3/0xf0 [xfs]
 xrep_symlink_salvage+0x100/0x110 [xfs]
 xrep_symlink+0x2e/0x80 [xfs]
 xrep_attempt+0x61/0x1f0 [xfs]
 xfs_scrub_metadata+0x34f/0x5c0 [xfs]
 xfs_ioc_scrubv_metadata+0x387/0x560 [xfs]
 xfs_file_ioctl+0xe23/0x10e0 [xfs]
 __x64_sys_ioctl+0x76/0xc0
 do_syscall_64+0x4e/0x1e0
 entry_SYSCALL_64_after_hwframe+0x4b/0x53

kfence-#184: 0xffff88843fe9df80-0xffff88843fe9dfea, size=107, cache=kmalloc-128

allocated by task 3470 on cpu 1 at 263329.131592s (192823.508886s ago):

 xfs_init_local_fork+0x79/0xe0 [xfs]
 xfs_iformat_local+0xa4/0x170 [xfs]
 xfs_iformat_data_fork+0x148/0x180 [xfs]
 xfs_inode_from_disk+0x2cd/0x480 [xfs]
 xfs_iget+0x450/0xd60 [xfs]
 xfs_bulkstat_one_int+0x6b/0x510 [xfs]
 xfs_bulkstat_iwalk+0x1e/0x30 [xfs]
 xfs_iwalk_ag_recs+0xdf/0x150 [xfs]
 xfs_iwalk_run_callbacks+0xb9/0x190 [xfs]
 xfs_iwalk_ag+0x1dc/0x2f0 [xfs]
 xfs_iwalk_args.constprop.0+0x6a/0x120 [xfs]
 xfs_iwalk+0xa4/0xd0 [xfs]
 xfs_bulkstat+0xfa/0x170 [xfs]
 xfs_ioc_fsbulkstat.isra.0+0x13a/0x230 [xfs]
 xfs_file_ioctl+0xbf2/0x10e0 [xfs]
 __x64_sys_ioctl+0x76/0xc0
 do_syscall_64+0x4e/0x1e0
 entry_SYSCALL_64_after_hwframe+0x4b/0x53

CPU: 1 UID: 0 PID: 1300113 Comm: xfs_scrub Not tainted 6.18.0-rc4-djwx #rc4 PREEMPT(lazy)  3d744dd94e92690f00a04398d2bd8631dcef1954
Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.0-4.module+el8.8.0+21164+ed375313 04/01/2014
==================================================================

On further analysis, I realized that the second parameter to min() is not correct. xfs_ifork::if_bytes is the size of the xfs_ifork::if_data buffer. if_bytes can be smaller than the data fork size because:

(a) the forkoff code tries to keep the data area as large as possible (b) for symbolic links, if_bytes is the ondisk file size + 1 (c) forkoff is always a multiple of 8.

Case in point: for a single-byte symlink target, forkoff will be 8 but the buffer will only be 2 bytes long.

In other words, the logic here is wrong and we walk off the end of the incore buffer. Fix that.

以上是 CVE 记录(cvelist)中的原文,未经改写。

事件记录

+DIS披露

CVE 记录发布,编号分配方是 Linux。

来源 cvelist · 本站 批量导入 · 原始记录
{
  "id": 375708,
  "type": "disclosed",
  "source": "cvelist",
  "url": "https://www.cve.org/CVERecord?id=CVE-2025-40246",
  "occurred_at": "2025-12-04T16:08:09.751Z",
  "observed_at": "2026-11-13T05:39:08.090137Z",
  "is_backfill": true,
  "dedupe_key": "",
  "detail": {
    "state": "PUBLISHED",
    "date_published": "2025-12-04T16:08:09.751Z",
    "assigner_short_name": "Linux"
  }
}

纠错

报告错误或缺失

页面有误或缺失?告诉编辑;采纳后在本页修订记录公开说明,上游数据不会被改动。

研究员讨论

近 7 天有 0 位研究员提到

研究员在 X 上提到此 CVE 的帖子,原文照录,nday 不核实。

尚未采集到名单内研究员在 X 上提到此 CVE 的帖子。

讨论

0 条评论

还没有评论。