CVE-2026-124757: Local Root Privilege Escalation in needrestart via Cgroup Spoofing and Shell Injection
CVE-2026-124757 is a local privilege-escalation vulnerability in needrestart caused by improper validation of systemd cgroup paths and unsafe handling of process names. An unanchored cgroup-path match allows a local attacker to make their process appear to belong to root's session. On Debian bookworm with needrestart 3.6-4+deb12u3 and Ubuntu 24.04 with needrestart 3.6-7ubuntu4.5, the packaged desktop notification hook interpolates the attacker-controlled process name into a shell command executed through su, permitting command execution as root. Debian trixie with needrestart 3.11-1 is affected by session misidentification and attacker-controlled notifications executed as root, although arbitrary command execution was not reproduced on that version.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Successful exploitation on the confirmed command-injection configurations allows a low-privileged local user to execute arbitrary commands as root, compromising system confidentiality, integrity, and availability. On Debian trixie with needrestart 3.11-1, demonstrated behavior was limited to running the notification utility as root with attacker-selected display settings and notification text; arbitrary command execution was not demonstrated.
Mitigation
If you can’t patch tonight, do this now.
Until patched packages are available, consider disabling the affected desktop notification hook to interrupt the demonstrated exploitation path, subject to operational requirements. Review all privileged needrestart invocations, including package-management hooks, automation, and monitoring; exposure is not necessarily limited to interactive package operations. Disabling notifications does not correct the underlying cgroup session-identification flaw.
Remediation
Patch, then assume compromise.
Install the distribution-provided security update for needrestart. For Debian 13 (trixie), upgrade to 3.11-1.1~deb13u1 or a subsequent fixed version. On Ubuntu, install the corrected package through the applicable release's security updates; fixes for Ubuntu 18.04 LTS and 20.04 LTS require Ubuntu Pro ESM Apps. Upstream's three-patch fix passes notification text through environment variables rather than interpolating it into shell commands, anchors systemd cgroup matching, and replaces non-printable characters in notification text. The patch series applies with offsets to needrestart 3.11, while the second patch requires backporting for needrestart 3.6.
Exploits
No public exploits tracked yet. Mallory keeps watching.
References
Frequently asked questions
- Is CVE-2026-124757 exploited in the wild?
- As of Nov 21, 2026, Mallory has no reports of CVE-2026-124757 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2026-124757?
- As of Nov 21, 2026, Mallory has found no public exploit for CVE-2026-124757.
- Is there a patch for CVE-2026-124757?
- Install the distribution-provided security update for needrestart. For Debian 13 (trixie), upgrade to 3.11-1.1~deb13u1 or a subsequent fixed version.
Recent activity
9 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.