Cloudanix VulnDB

CVE-2025-38708

High · 7.8

CVSS

7.8

EPSS

0.4%

Published

Sep 4, 2025

CISA due date

—

Cloudanix analysis

Schedule a fix SSVC: Track

A rare flaw in Linux storage replication software can cause system crashes during unusual simultaneous write scenarios on multiple servers, though most real setups avoid the problem entirely.

Exploitation
Local Privilege
Attacker needs
Low Privilege
Complexity
Low
Impact
Full Compromise
Component
OS kernel
Class
Use After Free
Remediation
Upgrade
Effort
Medium
Patch risk
Low

What it actually does

Missing kref_get in DRBD handle_write_conflicts leads to premature drbd_destroy_device and use-after-free when two-primaries mode processes superseded writes, causing kernel crashes.

Why it matters to the business

Rare but possible kernel instability or crashes on systems using DRBD replication with concurrent writes enabled, though production cluster filesystems and live migration typically avoid this path; low urgency given 418 days since publication and stable low EPSS.

How an attack unfolds

An attacker triggers simultaneous writes to the same sector on both nodes in a two-primaries DRBD setup, causing the kernel to mishandle a superseded write without the required reference count, resulting in use-after-free and crash; the path is noted as test-only in real deployments and unrelated listed threat actors target different kernel issues.

How to fix it

Update Linux kernel to commit 0336bfe9c237476bd7c45605a36ca79c2bca62e5 or later; for MinimOS mariadb packages upgrade to 11.4.6-r0 or equivalent fixed builds; disable two-primaries if unused.

How to confirm the fix worked

Verify kernel source contains the kref_get addition in handle_write_conflicts; confirm package versions match listed fixed releases; test DRBD two-primaries with concurrent writes in a lab to ensure no crashes.

Typical attack path

  1. Enable two-primaries on DRBD resource
  2. Submit concurrent writes to identical sectors from both nodes
  3. Trigger superseded write handling path
  4. Exploit missing kref_get to free device structure while still referenced
  5. Cause use-after-free leading to kernel panic or potential escalation

How to detect it

Review kernel logs for use-after-free or drbd_destroy_device references during DRBD write conflict handling; correlate with two-primaries configurations and concurrent write attempts; no widespread exploitation reported.

What your security team should do

  • Prioritize kernel upgrades on any systems with DRBD two-primaries enabled
  • Audit configurations to confirm two-primaries necessity and upper-layer write coordination
  • Monitor for kernel oops or panic logs mentioning drbd_destroy_device
  • Apply updates within standard patch cycles given low EPSS and non-KEV status

The record

In the Linux kernel, the following vulnerability has been resolved: drbd: add missing kref_get in handle_write_conflicts With `two-primaries` enabled, DRBD tries to detect "concurrent" writes and handle write conflicts, so that even if you write to the same sector simultaneously on both nodes, they end up with the identical data once the writes are completed. In handling "superseeded" writes, we forgot a kref_get, resulting in a premature drbd_destroy_device and use after free, and further to kernel crashes with symptoms. Relevance: No one should use DRBD as a random data generator, and apparently all users of "two-primaries" handle concurrent writes correctly on layer up. That is cluster file systems use some distributed lock manager, and live migration in virtualization environments stops writes on one node before starting writes on the other node. Which means that other than for "test cases", this code path is never taken in real life. FYI, in DRBD 9, things are handled differently nowadays. We still detect "write conflicts", but no longer try to be smart about them. We decided to disconnect hard instead: upper layers must not submit concurrent writes. If they do, that's their fault.

Affected packages

Ecosystem Package Introduced Fixed
Debian:11 linux 0 No fix
Debian:12 linux 0 No fix
Debian:13 linux 0 6.12.43-1
Debian:14 linux 0 6.16.3-1
Linux Kernel 0 5.4.297
Linux Kernel 4.5.0 5.4.297
Mageia:9 kernel 0 6.6.105-1.mga9
Mageia:9 kernel-linus 0 6.6.105-1.mga9
Mageia:9 kmod-virtualbox 0 7.1.10-10.mga9
Mageia:9 kmod-xtables-addons 0 3.24-86.mga9
Mageia:9 mageia-repos 0 9-4.mga9
Mageia:9 meta-task 0 9-4.mga9

Related vulnerabilities