ZeroHour

CVE-2026-78422

niche

Polkit authorization bypass via PID-reuse TOCTOU race in Rust zbus_polkit crate

CVSS 4.0
7.3 high
EPSS
<1%p0
Published
()
Modified
AI analysis

CVE-2026-78422 is a flaw in the zbus_polkit Rust crate's Subject::new_for_owner() function, which encodes the caller-supplied UID with the wrong D-Bus type (unsigned integer instead of the signed integer required by the org.freedesktop.PolicyKit1.Authority interface), so polkit silently discards the supplied UID and instead re-derives the process owner itself by looking the PID up in /proc. That /proc lookup is inherently a time-of-check/time-of-use race, meaning the UID that applications pass in — typically taken from a trusted source such as SO_PEERCRED socket peer credentials precisely to defend against PID reuse — has no effect on the authorization decision. An unprivileged local attacker who can cause an already-authorized process to terminate and then win the race to have their own process assigned the recycled PID is treated by polkit as that authorized subject, bypassing the authorization check and performing actions they are not entitled to. Only Linux applications built with zbus_polkit versions before 5.1.0 that rely on this API for authorization decisions are affected, along with their users. No public proof-of-concept, in-the-wild exploitation, or CISA KEV listing is known, and EPSS assigns a 0.1% 30-day exploitation probability; the flaw is rated 7.3 (high) in CVSS 4.0 with high attack complexity due to the required race.

What to do: Upgrade zbus_polkit to 5.1.0 or later, which encodes the UID with the correct signed D-Bus type so polkit honors the caller-supplied identity. If you maintain a Rust application using Subject::new_for_owner(), audit whether authorization decisions depend on that call and, until patched, consider re-validating subjects after authorization or using an alternative authorization path that is not vulnerable to PID reuse. Watch for updated packages from your distribution (SUSE is the assigning CNA) and rebuild dependent applications against the fixed crate.

Affected
zbus project (Rust D-Bus ecosystem; advisory assigned by SUSE) zbus_polkit crate (Subject::new_for_owner)all versions before 5.1.0
Estimated exposure
nicheunknown — plausibly no more than a few thousand affected application deployments — No install or download counts for the zbus_polkit crate are provided in the available data, and by deployment pattern only the relatively small subset of Rust software on Linux that calls polkit's Authority interface via this API is…

Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.

Description

Subject::new_for_owner() in the zbus_polkit crate encodes the uid entry of a unix-process polkit subject as an unsigned 32-bit integer (D-Bus type u), whereas the org.freedesktop.PolicyKit1.Authority interface specifies a signed 32-bit integer (D-Bus type i). Because of this type mismatch, polkit silently discards the caller-supplied UID and instead determines the subject's owner itself by looking up the PID in /proc, a lookup that is inherently subject to a time-of-check/time-of-use race. Consequently, an application that passes a UID obtained from a trustworthy source — for example SO_PEERCRED Unix socket peer credentials — in order to defend against PID reuse receives no protection, and the supplied UID has no effect on the authorization decision. A local unprivileged attacker who can cause an authorized process to terminate and then win the race to have their own process assigned the same PID can be authorized under the identity of the terminated process, bypassing the polkit authorization check and performing actions the attacker is not entitled to. This issue affects zbus_polkit before 5.1.0.

Weakness
CWE-367, CWE-686
Vector
CVSS:4.0/AV:L/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

In the news

No ingested article mentions this CVE yet.