CVE-2023-53791
BaseFortify
Publication date: 2025-12-09
Last updated on: 2025-12-09
Assigner: kernel.org
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| linux | linux_kernel | * |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-UNKNOWN |
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?
This vulnerability in the Linux kernel's md (multiple device) subsystem involves a mismatch in how device holders are managed between functions export_rdev(), blkdev_get_by_dev(), and blkdev_put(). Specifically, when the mddev->external flag changes from 0 to 1, the code inconsistently uses 'rdev' and 'claim_rdev' as holders for device reference counting, leading to warnings and potential improper device handling. The issue was fixed by properly recording which holder ('rdev' or 'claim_rdev') is used to avoid mismatches.
How can this vulnerability impact me? :
This vulnerability can cause warnings and potentially improper management of block device references in the Linux kernel's md subsystem. This could lead to unstable behavior or resource management issues when adding or removing devices from md arrays, possibly affecting system stability or data integrity during such operations.
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability can be detected by running the provided test script that reproduces the issue. The test involves creating a new md device and repeatedly adding and removing a device via sysfs, which triggers the warning. The commands include running the test as follows: ./test --save-logs --logdir=/tmp/ --keep-going --dev=loop --tests=23rdev-lifetime. Monitoring kernel logs for warnings related to blkdev_put and export_rdev in md_mod module can also indicate the presence of this issue.
What immediate steps should I take to mitigate this vulnerability?
The immediate mitigation is to apply the fix that records if 'rdev' is used as holder, which resolves the mismatch warning. Until the fix is applied, avoid changing mddev->external from 0 to 1 to prevent triggering the issue. Monitoring kernel logs for related warnings can help identify if the problem occurs.