CVE-2025-68266 bfs: Reconstruct file type when loading from disk

Not scored Published Updated

A flaw in the Linux kernel's BFS filesystem allows attackers to cause memory corruption or denial of service by mounting a maliciously crafted filesystem image.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2025-68266?

CVE-2025-68266 is a memory corruption vulnerability in Linux, published on 16 Dec 2025. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

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

bfs: Reconstruct file type when loading from disk

syzbot is reporting that S_IFMT bits of inode->i_mode can become bogus when the S_IFMT bits of the 32bits "mode" field loaded from disk are corrupted or when the 32bits "attributes" field loaded from disk are corrupted.

A documentation says that BFS uses only lower 9 bits of the "mode" field. But I can't find an explicit explanation that the unused upper 23 bits (especially, the S_IFMT bits) are initialized with 0.

Therefore, ignore the S_IFMT bits of the "mode" field loaded from disk. Also, verify that the value of the "attributes" field loaded from disk is either BFS_VREG or BFS_VDIR (because BFS supports only regular files and the root directory).

Which versions are affected by CVE-2025-68266?

How do I fix CVE-2025-68266?

Apply the vendor's patch.

Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.

Is CVE-2025-68266 being exploited?

There is no known exploitation of CVE-2025-68266 in the wild and no public exploit code.

Sources

Also known as BELL-CVE-2025-68266, DEBIAN-CVE-2025-68266, GHSA-cf7w-xh8m-r378, ROOT-OS-DEBIAN-11-CVE-2025-68266, ROOT-OS-DEBIAN-12-CVE-2025-68266, ROOT-OS-DEBIAN-13-CVE-2025-68266 and 3 more.

Is CVE-2025-68266 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free