CVE-2026-30874 OpenWrt procd PATH Environment Variable Filter Bypass via Incorrect String Comparison Leads to Privilege Escalation

Low 1.8 Published Updated

An attacker can bypass environment variable filtering in OpenWrt procd to inject a malicious PATH, leading to privilege escalation via hotplug scripts.

Exploited in the wild
Not known
Login needed
An administrator
Attackable
Local or same network only
Victim action needed
Not needed
Fix
None listed

What is CVE-2026-30874?

CVE-2026-30874 is a low-severity vulnerability in Openwrt Openwrt, published on 19 Mar 2026. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

OpenWrt Project is a Linux operating system targeting embedded devices. In versions prior to 24.10.6, a vulnerability in the hotplug_call function allows an attacker to bypass environment variable filtering and inject an arbitrary PATH variable, potentially leading to privilege escalation. The function is intended to filter out sensitive environment variables like PATH when executing hotplug scripts in /etc/hotplug.d, but a bug using strcmp instead of strncmp causes the filter to compare the full environment string (e.g., PATH=/some/value) against the literal "PATH", so the match always fails. As a result, the PATH variable is never excluded, enabling an attacker to control which binaries are executed by procd-invoked scripts running with elevated privileges. This issue has been fixed in version 24.10.6.

Weakness: CWE-74, CWE-269, CWE-187

Which versions are affected by CVE-2026-30874?

It affects 1 product.

Products include Openwrt Openwrt.

How do I fix CVE-2026-30874?

No fix has been published for CVE-2026-30874 yet. Limit exposure of the affected software until one is available.

Is CVE-2026-30874 being exploited?

There is no known exploitation of CVE-2026-30874 in the wild and no public exploit code.

All Openwrt Openwrt vulnerabilities

Sources

Also known as GHSA-jw28-hxcm-j934.

Is CVE-2026-30874 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free