Skip to main content

Zigbee2MQTT CVE-2026-71279

| EUVDEUVD-2026-53364 HIGH
Path Traversal (CWE-22)
2026-08-05 TuranSec GHSA-77vh-g47p-vh46
8.0
CVSS 3.1 · Vendor: TuranSec
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Gain publish access to unauthenticated MQTT broker
  2. Delivery
    Publish crafted extension save message with traversal name
  3. Exploit
    getFilePath() resolves path outside extensions directory
  4. Execution
    Malicious .js payload written to arbitrary host path
  5. Persist
    Node.js import() immediately executes payload
  6. Impact
    RCE as Zigbee2MQTT process user

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK

2 techniques across 2 tactics: Discovery, Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Two conditions must both be met: (1) enable_external_js must be set to true in the Zigbee2MQTT configuration - this option defaults to false, meaning default-configured deployments are not reachable through this code path, but the description explicitly characterizes it as commonly enabled in legacy installations; (2) the attacker must have publish access to the MQTT broker on topic zigbee2mqtt/bridge/request/extension/save - CVSS AV:A/PR:L reflects adjacent-network low-privilege access, but the description states that real-world Zigbee2MQTT MQTT brokers are frequently unauthenticated, effectively making this condition trivially satisfiable in a large fraction of deployments. Exploitation is further limited to the fact that the extension name must terminate in .js, .mjs, or .cjs, which is trivially satisfied by path traversal payloads (e.g., ../../tmp/evil.js). No specific platform, OS version, or Zigbee hardware configuration is required beyond the two conditions above.

Impact

The CVSS 8.0 base score (AV:A/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H) correctly reflects the adjacent-network requirement: the attacker must publish to the MQTT broker, which is nominally a PR:L condition. However, the CVE description explicitly states that MQTT brokers in real Zigbee2MQTT deployments are frequently unauthenticated, effectively collapsing PR:L toward PR:N in a significant portion of real-world targets and elevating practical risk above what the CVSS score alone implies. The second gating condition - enable_external_js must be true - is off by default, which is a meaningful mitigation; however, the description characterizes it as commonly enabled in legacy installations, so this is not a strong deterrent for the installed base. No KEV listing, EPSS score, or confirmed POC was provided in the input data, so active exploitation cannot be confirmed at this time. The dual-impact nature of the flaw (RCE plus arbitrary file deletion via the same vulnerable function) is atypical and increases the overall risk surface beyond what a single-primitive vulnerability would carry. Real-world priority should be elevated for any deployment where enable_external_js is true and the MQTT broker is unauthenticated.

Exploit ScenarioDerived

An attacker with network access to an unauthenticated MQTT broker publishes a message to zigbee2mqtt/bridge/request/extension/save with a JSON body where the name field is set to ../../tmp/evil.js and the content field contains arbitrary JavaScript (for example, a reverse shell). Zigbee2MQTT's getFilePath() resolves the traversal, writes the payload to /tmp/evil.js outside the extensions directory, and immediately imports it via Node.js import(), executing the attacker's code as the Zigbee2MQTT process user. No publicly confirmed POC was identified in the provided data, but the exploitation path requires no specialized knowledge beyond crafting an MQTT publish message.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
No patch listed yet 0.4% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 05, 2026

Remote code execution and arbitrary file deletion in Zigbee2MQTT stem from an unsanitized path.join() call in ExternalJSExtension.getFilePath() (lib/extension/externalJS.ts), allowing any MQTT client with publish access to escape the extensions directory via traversal sequences and write arbitrary files to the host filesystem. Once the malicious .js file is written, Zigbee2MQTT immediately imports it via Node.js import(), executing attacker-controlled code in the application process context. The same vulnerable code path also backs the extension-removal handler, yielding a second primitive for arbitrary file deletion. No public exploit or KEV listing was identified at time of analysis, but the exploitation path is mechanically straightforward given the detailed description.

RemediationAI

No vendor-released patched version was confirmed from the provided references at time of analysis; operators should monitor the Zigbee2MQTT GitHub repository at https://github.com/Koenkk/zigbee2mqtt for an official fix and upgrade immediately upon release. The most impactful compensating control is to set enable_external_js to false (its default) in the Zigbee2MQTT configuration - this removes the extension save and delete MQTT handlers entirely, eliminating the attack surface with no functional impact for deployments that do not use external JS extensions. If enable_external_js cannot be disabled, enforce MQTT broker authentication (username/password or mutual TLS) so that only trusted clients can publish to any topic; this raises the attacker's required access from adjacent-unauthenticated to adjacent-authenticated. Additionally, configure MQTT broker ACLs to restrict publish rights on zigbee2mqtt/bridge/request/extension/save to only the Zigbee2MQTT service account itself, preventing lateral abuse from other broker clients. Note that ACL-only mitigations without disabling enable_external_js leave the path traversal logic reachable from any client that can escalate MQTT privileges.

Affected VersionsENISA

zigbee2mqtt 0 ≤2.12.0

Affected Packages

euvd zigbee2mqtt no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Zigbee2MQTT (cpe:2.3:a:koenkk:zigbee2mqtt:*:*:*:*:*:*:*:*) is an open-source Node.js bridge that connects Zigbee devices to an MQTT broker, most commonly deployed on Raspberry Pi or Linux single-board computers in home automation environments. The root cause is CWE-22 (Path Traversal) in lib/extension/externalJS.ts: the getFilePath() method constructs a filesystem path with path.join(basePath, name), where name is taken directly from the MQTT message payload on topic zigbee2mqtt/bridge/request/extension/save. While path.join() normalizes the resulting path, it does not strip or reject ../ sequences - a name value of ../../tmp/evil.js resolves cleanly to a path outside the intended extensions directory. The only server-side guard is a suffix check enforcing .js, .mjs, or .cjs extensions, which is trivially bypassed by the traversal payload itself (../../tmp/evil.js satisfies the check). After writing the file, the handler invokes Node.js dynamic import() on the resolved path, converting a write-to-disk primitive directly into code execution. The getFilePath() function is shared verbatim with the extension-deletion handler, making the same traversal available as an arbitrary file deletion primitive.

Know when Zigbee2Mqtt gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (TuranSec) PRIMARY 8.0 HIGH
AV:A/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
vuln.today AI 8.0 HIGH

Adjacent vector and low privileges reflect MQTT broker publish access; full CIA follows from arbitrary code execution in the application process.

3.1 AV:A/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
4.0 AV:A/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (TuranSec).

CVSS VectorVendor: TuranSec

Attack Vector
Adjacent
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

2
CVSS changed
Aug 05, 2026 - 13:37 NVD
8.1 (HIGH) 8.0 (HIGH)
CVE Published
Aug 05, 2026 - 12:26 cve.org
HIGH 8.0

DescriptionCVE.org

Zigbee2MQTT's ExternalJSExtension.getFilePath() (lib/extension/externalJS.ts) joins a name parameter received via an MQTT message (topic zigbee2mqtt/bridge/request/extension/save) into the extensions base path using path.join(basePath, name) with no sanitization. Because path.join() resolves ../ sequences, a name such as ../../tmp/evil.js escapes the intended extensions directory. The extension handler only validates that the name ends in .js/.mjs/.cjs, writes the file, and then dynamically imports it via Node.js import(), achieving remote code execution. Requires the enable_external_js config option (off by default, but commonly enabled in legacy installs) and MQTT broker access, which is frequently unauthenticated in real deployments. The identical unsanitized getFilePath() is also used by the extension-removal handler, enabling arbitrary file deletion.

Executive ViewAI

Why It Matters

Zigbee2MQTT contains a critical vulnerability enabling remote code execution and arbitrary file deletion for any attacker with access to publish messages on the MQTT broker. No public exploit has been identified at time of analysis, but the exploitation mechanism is mechanically straightforward. This poses an immediate threat to IoT gateway deployments and any connected systems that rely on Zigbee2MQTT for automation and control.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Restrict MQTT broker publish access to authenticated, trusted clients via broker authentication and authorization controls; implement network segmentation to isolate Zigbee2MQTT instances from untrusted networks; disable the ExternalJS extension if not required for operations; deploy real-time monitoring on file system modifications and MQTT message patterns to detect exploitation attempts; consider temporarily disabling Zigbee2MQTT in non-critical environments pending patch availability.

Threat Intelligence Overview

EPSS Score
0.4%
Top 71% exploitable
Prevalence
Medium
popular open-source Zigbee bridge in home automation
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.4%
Patch available No
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Controlled
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

40
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +40
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy