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-2024-50217

published high CVSS 3.1 · 7.8

btrfs: fix use-after-free of block device file in __btrfs_free_extra_devids()

Published
09 Nov 2024, 10:14:28 UTC
Updated
05 Aug 2026, 11:42:34 UTC
Language
en

Package status and fixes

Distro / vendorReleasePackage / productPublisher statusFixed buildSource
Linux — Linux142388194191a3edc9ba01cfcfd8b691e0971fb2 to < 47a83f8df39545f3f552bb6a1b6d9c30e37621dd · 142388194191a3edc9ba01cfcfd8b691e0971fb2 to < aec8e6bf839101784f3ef037dcdb9432c3f32343 · Other versions: unaffected Affected Not stated Linux
Linux — Linux4.8 (affected) · 0 to < 4.8 (unaffected · semver) · 6.11.7 through 6.11.* (unaffected · semver) · 6.12 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
SUSE / openSUSE openSUSE-Tumbleweed kernel-develaarch64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
Ubuntu noble linux-buildinfo-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-develppc64le Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-devels390x Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
Show 96 more entries
Distro / vendorReleasePackage / productPublisher statusFixed buildSource
SUSE / openSUSE openSUSE-Tumbleweed kernel-develx86_64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-devel-longtermaarch64 Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-devel-longtermppc64le Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-devel-longterms390x Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-devel-longtermx86_64 Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-macrosaarch64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-macrosppc64le Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-macross390x Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-macrosx86_64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-sourceaarch64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-sourceppc64le Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-sources390x Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-sourcex86_64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-longtermaarch64 Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-longtermppc64le Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-longterms390x Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-longtermx86_64 Advisory build 6.12.11-1.1 OPENSUSE-SU-2025:14705-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-vanillaaarch64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-vanillappc64le Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-vanillas390x Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
SUSE / openSUSE openSUSE-Tumbleweed kernel-source-vanillax86_64 Advisory build 6.11.8-1.1 OPENSUSE-SU-2024:14500-1
Ubuntu noble linux-buildinfo-6.8.0-1035-nvidia-tegra Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-buildinfo-6.8.0-1035-nvidia-tegra-rt Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-headers-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-headers-6.8.0-1035-nvidia-tegra Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-headers-6.8.0-1035-nvidia-tegra-rt Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-image-unsigned-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-image-unsigned-6.8.0-1035-nvidia-tegra Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-image-unsigned-6.8.0-1035-nvidia-tegra-rt Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-modules-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-modules-6.8.0-1035-nvidia-tegra Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-modules-6.8.0-1035-nvidia-tegra-rt Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-modules-extra-6.8.0-1035-nvidia-tegra Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-modules-extra-6.8.0-1035-nvidia-tegra-rt Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-modules-ipu6-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-modules-ipu7-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-modules-iwlwifi-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-modules-usbio-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-modules-vision-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-nvidia-tegra Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-nvidia-tegra-headers-6.8.0-1035 Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-nvidia-tegra-tools-6.8.0-1035 Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-oem-6.11 Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-oem-6.11-headers-6.11.0-1015 Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-oem-6.11-tools-6.11.0-1015 Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-tools-6.11.0-1015-oem Advisory build 6.11.0-1015.15 USN-7310-1
Ubuntu noble linux-tools-6.8.0-1035-nvidia-tegra Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu noble linux-tools-6.8.0-1035-nvidia-tegra-rt Advisory build 6.8.0-1035.38 USN-8781-1
Ubuntu oracular linux Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-aws Advisory build 6.11.0-1009.10 USN-7277-1
Ubuntu oracular linux-aws-cloud-tools-6.11.0-1009 Advisory build 6.11.0-1009.10 USN-7277-1
Ubuntu oracular linux-aws-headers-6.11.0-1009 Advisory build 6.11.0-1009.10 USN-7277-1
Ubuntu oracular linux-aws-tools-6.11.0-1009 Advisory build 6.11.0-1009.10 USN-7277-1
Ubuntu oracular linux-azure Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-azure-cloud-tools-6.11.0-1009 Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-azure-headers-6.11.0-1009 Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-azure-tools-6.11.0-1009 Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-bpf-dev Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-buildinfo-6.11.0-1005-realtime Advisory build 6.11.0-1005.5 USN-7277-1
Ubuntu oracular linux-buildinfo-6.11.0-1008-raspi Advisory build 6.11.0-1008.8 USN-7277-1
Ubuntu oracular linux-buildinfo-6.11.0-1009-aws Advisory build 6.11.0-1009.10 USN-7277-1
Ubuntu oracular linux-buildinfo-6.11.0-1009-azure Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-buildinfo-6.11.0-1009-gcp Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-buildinfo-6.11.0-1010-lowlatency Advisory build 6.11.0-1010.11 USN-7276-1
Ubuntu oracular linux-buildinfo-6.11.0-1010-lowlatency-64k Advisory build 6.11.0-1010.11 USN-7276-1
Ubuntu oracular linux-buildinfo-6.11.0-1011-oracle Advisory build 6.11.0-1011.12 USN-7277-1
Ubuntu oracular linux-buildinfo-6.11.0-1011-oracle-64k Advisory build 6.11.0-1011.12 USN-7277-1
Ubuntu oracular linux-buildinfo-6.11.0-18-generic Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-buildinfo-6.11.0-18-generic-64k Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-cloud-tools-6.11.0-1005-realtime Advisory build 6.11.0-1005.5 USN-7277-1
Ubuntu oracular linux-cloud-tools-6.11.0-1009-aws Advisory build 6.11.0-1009.10 USN-7277-1
Ubuntu oracular linux-cloud-tools-6.11.0-1009-azure Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-cloud-tools-6.11.0-1010-lowlatency Advisory build 6.11.0-1010.11 USN-7276-1
Ubuntu oracular linux-cloud-tools-6.11.0-18 Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-cloud-tools-6.11.0-18-generic Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-cloud-tools-common Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-doc Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-gcp Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-gcp-headers-6.11.0-1009 Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-gcp-tools-6.11.0-1009 Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-1005-realtime Advisory build 6.11.0-1005.5 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-1008-raspi Advisory build 6.11.0-1008.8 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-1009-aws Advisory build 6.11.0-1009.10 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-1009-azure Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-1009-gcp Advisory build 6.11.0-1009.9 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-1010-lowlatency Advisory build 6.11.0-1010.11 USN-7276-1
Ubuntu oracular linux-headers-6.11.0-1010-lowlatency-64k Advisory build 6.11.0-1010.11 USN-7276-1
Ubuntu oracular linux-headers-6.11.0-1011-oracle Advisory build 6.11.0-1011.12 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-1011-oracle-64k Advisory build 6.11.0-1011.12 USN-7277-1
Ubuntu oracular linux-headers-6.11.0-18 Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-headers-6.11.0-18-generic Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-headers-6.11.0-18-generic-64k Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-image-6.11.0-1008-raspi Advisory build 6.11.0-1008.8 USN-7277-1
Ubuntu oracular linux-image-6.11.0-1008-raspi-dbgsym Advisory build 6.11.0-1008.8 USN-7277-1
Ubuntu oracular linux-image-6.11.0-18-generic Advisory build 6.11.0-18.18 USN-7276-1
Ubuntu oracular linux-image-6.11.0-18-generic-dbgsym Advisory build 6.11.0-18.18 USN-7276-1

Package entries are limited to the first 100 builds and 100 linked advisories.

Description

In the Linux kernel, the following vulnerability has been resolved: btrfs: fix use-after-free of block device file in __btrfs_free_extra_devids() Mounting btrfs from two images (which have the same one fsid and two different dev_uuids) in certain executing order may trigger an UAF for variable 'device->bdev_file' in __btrfs_free_extra_devids(). And following are the details: 1. Attach image_1 to loop0, attach image_2 to loop1, and scan btrfs devices by ioctl(BTRFS_IOC_SCAN_DEV): / btrfs_device_1 → loop0 fs_device \ btrfs_device_2 → loop1 2. mount /dev/loop0 /mnt btrfs_open_devices btrfs_device_1->bdev_file = btrfs_get_bdev_and_sb(loop0) btrfs_device_2->bdev_file = btrfs_get_bdev_and_sb(loop1) btrfs_fill_super open_ctree fail: btrfs_close_devices // -ENOMEM btrfs_close_bdev(btrfs_device_1) fput(btrfs_device_1->bdev_file) // btrfs_device_1->bdev_file is freed btrfs_close_bdev(btrfs_device_2) fput(btrfs_device_2->bdev_file) 3. mount /dev/loop1 /mnt btrfs_open_devices btrfs_get_bdev_and_sb(&bdev_file) // EIO, btrfs_device_1->bdev_file is not assigned, // which points to a freed memory area btrfs_device_2->bdev_file = btrfs_get_bdev_and_sb(loop1) btrfs_fill_super open_ctree btrfs_free_extra_devids if (btrfs_device_1->bdev_file) fput(btrfs_device_1->bdev_file) // UAF ! Fix it by setting 'device->bdev_file' as 'NULL' after closing the btrfs_device in btrfs_close_one_device().

en · Linux · cna

Vendor advisories explicitly linked to this CVE.

6

Assessment

CVSS risk assessment and additional context for this vulnerability.

CVSS version
3.1
Base score
7.8 / 10
Severity
high
Provider
Linux · cna
Vector string
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
Scenarios
en: AV:L - The vulnerability is reached only through local block-device operations — `mount(2)` of a btrfs volume plus device registration via `BTRFS_IOC_SCAN_DEV`/`device=` — on a locally attached device or loop-mounted image. No network or remote-peer data is involved. AC:L - The attacker fully controls both filesystem images and the order of the two mounts; the first mount's `open_ctree()` failure can be forced deterministically by corrupting the superblock/chunk tree rather than relying on the ENOMEM fault injection in the report, and no race must be won. Heap grooming of the `filp` slab between the two mounts is entirely under attacker control. PR:N - The attacker supplies only the malicious images (USB stick, disk image file, or loop-backed file) and needs no account or privilege on the target system; the privileged mount is performed by the victim or by an automounter such as udisks2 on the attacker's behalf. UI:R - Exploitation requires the victim (or an automount daemon acting for a logged-in user) to mount the attacker's crafted btrfs images, twice in sequence, since btrfs lacks `FS_USERNS_MOUNT` and cannot be mounted directly by an unprivileged attacker. S:U - The corruption and its consequences are confined to the kernel of the same system; no VM, IOMMU, or sandbox boundary is crossed. C:H - The stray `fput()` on a freed `struct file` in a `SLAB_TYPESAFE_BY_RCU` cache causes a live file's refcount to be dropped, yielding a reusable use-after-free object that can be leveraged for arbitrary kernel memory disclosure. I:H - The same reference-count underflow gives a premature-free UAF on `struct file`, a well-established primitive for heap spraying, arbitrary write, and control-flow hijack leading to privilege escalation. A:H - Even without full exploitation the `fput()` on freed memory corrupts the slab and reliably produces a KASAN splat, refcount BUG, or kernel panic, taking the system down.

Additional Assessments

Additional normalized CVSS assessments
VersionScoreSeverityProviderVectorScenarios
3.1 7.8 high CISA-ADP · adp CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H —

Publisher product statements

Version ranges and default statuses as reported by each provider.

Affected vendor and product assertions
VendorProductVersion statusSource
Linux Linux 142388194191a3edc9ba01cfcfd8b691e0971fb2 to < 47a83f8df39545f3f552bb6a1b6d9c30e37621dd (affected · git)142388194191a3edc9ba01cfcfd8b691e0971fb2 to < aec8e6bf839101784f3ef037dcdb9432c3f32343 (affected · git)Default: unaffected Linux · cna
Linux Linux 4.8 (affected)0 to < 4.8 (unaffected · semver)6.11.7 through 6.11.* (unaffected · semver)6.12 and later (unaffected · original_commit_for_fix)Default: affected Linux · cna

Weaknesses

1
  • CWE-416 CWE-416 Use After Free (CISA-ADP · adp)

References

5

Provider assertions

3

Linux · cna

btrfs: fix use-after-free of block device file in __btrfs_free_extra_devids()

CISA-ADP · adp

CISA ADP Vulnrichment

CVE · adp

CVE Program Container

Provenance

Schema
5.2
Searchable
yes
Content hash
a6093697aa176b68dcbb9c72e51f6835cf7d68a6e21781fecfd03bd35c2565ad
Ingested
23 Sep 2026, 08:29:52 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