Search CVEs and advisories

Search CVEs and Linux security advisories by vendor, product, package, or severity, and see which vulnerabilities each advisory addresses.

CVE

CVE-2025-71159

published critical CVSS 3.1 · 9.8

btrfs: fix use-after-free warning in btrfs_get_or_create_delayed_node()

Published
23 Jan 2026, 15:23:57 UTC
Updated
05 Aug 2026, 12:12:25 UTC
Language
en

Package status and fixes

Distro / vendorReleasePackage / productPublisher statusFixed buildSource
Linux — Linuxe8513c012de75fd65e2df5499572bc6ef3f6e409 to < c8385851a5435f4006281828d428e5d0b0bbf8af · e8513c012de75fd65e2df5499572bc6ef3f6e409 to < 83f59076a1ae6f5c6845d6f7ed3a1a373d883684 · Other versions: unaffected Affected Not stated Linux
Linux — Linux6.18 (affected) · 0 to < 6.18 (unaffected · semver) · 6.18.6 through 6.18.* (unaffected · semver) · 6.19 and later (unaffected · original_commit_for_fix) · Other versions: affected Version-specific Not stated Linux
Amazon Linux AL2 Release evaluation Not Affected Not required Amazon Linux assessment
Amazon Linux AL2023 Release evaluation Not Affected Not required Amazon Linux assessment

Description

In the Linux kernel, the following vulnerability has been resolved: btrfs: fix use-after-free warning in btrfs_get_or_create_delayed_node() Previously, btrfs_get_or_create_delayed_node() set the delayed_node's refcount before acquiring the root->delayed_nodes lock. Commit e8513c012de7 ("btrfs: implement ref_tracker for delayed_nodes") moved refcount_set inside the critical section, which means there is no longer a memory barrier between setting the refcount and setting btrfs_inode->delayed_node. Without that barrier, the stores to node->refs and btrfs_inode->delayed_node may become visible out of order. Another thread can then read btrfs_inode->delayed_node and attempt to increment a refcount that hasn't been set yet, leading to a refcounting bug and a use-after-free warning. The fix is to move refcount_set back to where it was to take advantage of the implicit memory barrier provided by lock acquisition. Because the allocations now happen outside of the lock's critical section, they can use GFP_NOFS instead of GFP_ATOMIC.

en · Linux · cna

Vendor advisories explicitly linked to this CVE.

0

No linked advisories were found for this CVE.

Assessment

CVSS risk assessment and additional context for this vulnerability.

CVSS version
3.1
Base score
9.8 / 10
Severity
critical
Provider
Linux · cna
Vector string
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Scenarios
en: AV:N - A remote attacker can reach the path through a writable Btrfs-backed ksmbd guest share: SMB2 WRITE reaches ksmbd_vfs_write(), kernel_write(), and the Btrfs ordered-write completion path. This is a reasonable network-facing Btrfs deployment. AC:L - Concurrent writes create multiple ordered extents whose parallel end-I/O workers can race while publishing and acquiring the same delayed node. The attacker controls the workload and can repeatedly create both sides of the race. PR:N - Although ksmbd checks the session, writable tree connection, and file handle, a guest-writable share grants these without attacker credentials. No prior account, capability, or local privilege is therefore required in that deployment. UI:N - The attacker directly triggers the race with concurrent write requests; no separate victim action is required. S:U - The vulnerable Btrfs code and the resulting kernel memory corruption are within the same host-kernel security authority. C:H - The lost reference can leave a delayed-node pointer usable after its slab object is freed and reused. Exploitation of this kernel use-after-free can expose arbitrary kernel memory. I:H - Subsequent mutex, flag, counter, tree, and inode-item operations write through the stale pointer. Heap reuse and spraying can turn these writes into kernel memory corruption and potential code execution. A:H - The observed refcount failure raises a kernel warning, and use of the prematurely freed delayed node can cause an oops, panic, hang, or filesystem shutdown.

Publisher product statements

Version ranges and default statuses as reported by each provider.

Affected vendor and product assertions
VendorProductVersion statusSource
Linux Linux e8513c012de75fd65e2df5499572bc6ef3f6e409 to < c8385851a5435f4006281828d428e5d0b0bbf8af (affected · git)e8513c012de75fd65e2df5499572bc6ef3f6e409 to < 83f59076a1ae6f5c6845d6f7ed3a1a373d883684 (affected · git)Default: unaffected Linux · cna
Linux Linux 6.18 (affected)0 to < 6.18 (unaffected · semver)6.18.6 through 6.18.* (unaffected · semver)6.19 and later (unaffected · original_commit_for_fix)Default: affected Linux · cna

Weaknesses

0

No weakness assertions.

References

2

Provider assertions

1

Linux · cna

btrfs: fix use-after-free warning in btrfs_get_or_create_delayed_node()

Provenance

Schema
5.2
Searchable
yes
Content hash
30efb3dc4ec61bee7166de66016555223102d5599204bb06d4bf19d4c4623e9d
Ingested
23 Sep 2026, 08:58:12 UTC
Source record
Official CVE record

Search filters

Match options apply to free text. CVE words match tokens; use contains:"…" for literal substrings.

Text

Words and phrases
buffer overflow "remote code execution"
Word prefix
auth*
Literal substring (title or description)
contains:"use-after-free"
Exclude a term or filter
-test -vendor:example

Affected product

Vendor
vendor:Example
Product
product:"Demo Widget"

Severity and score

Severity · none, low, medium, high, critical, unknown
severity:critical
CWE identifier
cwe:CWE-863
CVSS score (0–10)
cvss:>=7.0

Dates and status

Published date · comparisons, relative days
published:>=2026-01-01
Updated date · comparisons, relative days
updated:<30d
Status · published (default), rejected, unknown
status:rejected