CVE-2025-40044: fs: udf: fix OOB read in lengthAllocDescs handling
In the Linux kernel, the following vulnerability has been resolved:
fs: udf: fix OOB read in lengthAllocDescs handling
When parsing Allocation Extent Descriptor, lengthAllocDescs comes from
on-disk data and must be validated against the block size. Crafted or
corrupted images may set lengthAllocDescs so that the total descriptor
length (sizeof(allocExtDesc) + lengthAllocDescs) exceeds the buffer,
leading udf_update_tag() to call crc_itu_t() on out-of-bounds memory and
trigger a KASAN use-after-free read.
BUG: KASAN: use-after-free in crc_itu_t+0x1d5/0x2b0 lib/crc-itu-t.c:60
Read of size 1 at addr ffff888041e7d000 by task syz-executor317/5309
CPU: 0 UID: 0 PID: 5309 Comm: syz-executor317 Not tainted 6.12.0-rc4-syzkaller-00261-g850925a8133c #0
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
Call Trace:
<TASK>
__dump_stack lib/dump_stack.c:94 [inline]
dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
print_address_description mm/kasan/report.c:377 [inline]
print_report+0x169/0x550 mm/kasan/report.c:488
kasan_report+0x143/0x180 mm/kasan/report.c:601
crc_itu_t+0x1d5/0x2b0 lib/crc-itu-t.c:60
udf_update_tag+0x70/0x6a0 fs/udf/misc.c:261
udf_write_aext+0x4d8/0x7b0 fs/udf/inode.c:2179
extent_trunc+0x2f7/0x4a0 fs/udf/truncate.c:46
udf_truncate_tail_extent+0x527/0x7e0 fs/udf/truncate.c:106
udf_release_file+0xc1/0x120 fs/udf/file.c:185
__fput+0x23f/0x880 fs/file_table.c:431
task_work_run+0x24f/0x310 kernel/task_work.c:239
exit_task_work include/linux/task_work.h:43 [inline]
do_exit+0xa2f/0x28e0 kernel/exit.c:939
do_group_exit+0x207/0x2c0 kernel/exit.c:1088
__do_sys_exit_group kernel/exit.c:1099 [inline]
__se_sys_exit_group kernel/exit.c:1097 [inline]
__x64_sys_exit_group+0x3f/0x40 kernel/exit.c:1097
x64_sys_call+0x2634/0x2640 arch/x86/include/generated/asm/syscalls_64.h:232
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x77/0x7f
</TASK>
Validate the computed total length against epos->bh->b_size.
Found by Linux Verification Center (linuxtesting.org) with Syzkaller.
Security readout for executives and security teams
Plain-English summary
A malformed or corrupted UDF filesystem image can make a vulnerable Linux kernel read beyond an allocated buffer. Triggering requires local processing of the image and user interaction, such as exposing it to the UDF filesystem path. The reported impact is potentially severe, but the supplied evidence demonstrates a sanitizer-detected invalid read, not a proven real-world compromise.
Executive priority
Prioritize remediation for workstations, analysis systems, media-processing hosts, and other machines handling untrusted UDF content. Treat internet-facing status alone as a poor exposure indicator because this is a local filesystem-processing flaw. Apply normal expedited high-severity patching, with faster action where untrusted images are routinely handled.
Technical view
The UDF driver trusts the on-disk lengthAllocDescs value while handling an Allocation Extent Descriptor. If the descriptor header plus that value exceeds the buffer block size, udf_update_tag() can pass out-of-bounds memory to crc_itu_t(), producing a KASAN use-after-free read. The kernel fix validates the computed total against epos->bh->b_size.
Likely exposure
Exposure is concentrated in affected Linux systems that mount or otherwise process UDF filesystem images or media, especially content from untrusted sources. Systems without UDF use have lower practical exposure. The source lists affected upstream versions and commits, but does not provide distribution-specific package mappings.
Exploitation context
The supplied CVSS 3.1 score is 7.8 with local access, low complexity, no privileges, and required user interaction. KEV is false, and the bundle provides no evidence of active exploitation or a public weaponized exploit. Discovery came from Syzkaller testing by the Linux Verification Center.
Researcher notes
The observed failure is a one-byte KASAN use-after-free read during CRC calculation, reached through UDF extent writing and truncation. CVSS claims high confidentiality, integrity, and availability impact, but the provided sources do not demonstrate code execution, privilege escalation, or exploitation beyond the sanitizer crash. Distribution backports must be assessed separately.
Mitigation direction
Update to a vendor-supported kernel containing the applicable upstream fix.
Check Linux distribution advisories for exact fixed package versions.
Limit mounting or processing of untrusted UDF images and removable media where operationally feasible.
Prioritize systems that routinely ingest externally supplied filesystem images.
Validation and detection
Inventory kernel versions and identify systems where UDF support is enabled or used.
Map installed distribution packages to vendor advisories or the cited stable-kernel fixes.
Confirm the kernel source validates descriptor header plus lengthAllocDescs against the buffer block size.
After updating, verify the running kernel version and reboot status.
Run relevant UDF regression tests in an isolated, non-production environment.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cve · low confidence lookup
CVE-2025-40044 mapping review
Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
0ADP providers
9Source links
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.