CVE-2022-49849

btrfs: fix match incorrectly in dev_args_match_device

MEDIUM
5.5
CVSS Score
Published: May 1, 2025 at 02:10 PM UTC
Updated: June 17, 2026 at 05:19 AM UTC
1 product affected across 1 vendorLinux Kernel

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.5
Exploit prediction
EPSS 0.2%

Description

In the Linux kernel, the following vulnerability has been resolved: btrfs: fix match incorrectly in dev_args_match_device syzkaller found a failed assertion: assertion failed: (args->devid != (u64)-1) || args->missing, in fs/btrfs/volumes.c:6921 This can be triggered when we set devid to (u64)-1 by ioctl. In this case, the match of devid will be skipped and the match of device may succeed incorrectly. Patch 562d7b1512f7 introduced this function which is used to match device. This function contains two matching scenarios, we can distinguish them by checking the value of args->missing rather than check whether args->devid and args->uuid is default value.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

5.15.54 ≤ v < 5.15.795.16 ≤ v < 6.0.95.16 ≤ v < 6.15.15.545.165578b681fbf2b22d61189a2539efd3009518b328562d7b1512f7369a19bca2883e2e8672d78f04816.1 rc16.1 rc26.1 rc36.1 rc4
Vendor states this is fixed in 0fca385d6ebc3cabb20f67bcf8a71f1448bdc001 (fixed)
Vendor states this is fixed in bc6c127c377010f136360552ebf91c2723081c1b (fixed)
Vendor states this is fixed in c9fe4719c662e0af17eea723cf345e37719fd3c9 (fixed)
Vendor states this is fixed in 5.15.79 (unaffected)
Vendor states this is fixed in 5.16 (unaffected)
Vendor states this is fixed in 6.0.9 (unaffected)
Vendor states this is fixed in 6.1 (unaffected)

References (3)

Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/0fca385d6ebc3cabb20f67bcf8a71f1448bdc001
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/bc6c127c377010f136360552ebf91c2723081c1b
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/c9fe4719c662e0af17eea723cf345e37719fd3c9

CVSS

Attack Vector
LOCAL
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusANALYZED
CWE
NVD-CWE-noinfo

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card