Skip to main content
Live Webinar with SANS (June 25)— Agentic CTI Automation for Fun & ProfitRegister Free
Mallory
CriticalCISA KEVExploited in the wildPublic exploit

Unauthenticated OS Command Injection in Zyxel USG FLEX, ATP, and VPN Series

IdentifiersCVE-2022-30525CWE-78· Improper Neutralization of Special…

CVE-2022-30525 is a critical unauthenticated OS command injection vulnerability in the CGI-based web management functionality of multiple Zyxel firewall and VPN products, including USG FLEX, ATP, and VPN series devices. The vendor description states that the flaw exists in a CGI program and can allow an attacker to modify specific files and then execute OS commands on the device. Supporting reporting further indicates exploitation via the /ztp/cgi-bin/handler URI, where unsanitized attacker-controlled input is passed to os.system in lib_wan_settings.py. This improper neutralization of special elements in an OS command allows a remote attacker to inject arbitrary shell commands without authentication. Affected firmware ranges include USG FLEX 100(W)/200/500/700 versions 5.00 through 5.21 Patch 1, USG FLEX 50(W) and USG20(W)-VPN versions 5.10 through 5.21 Patch 1, ATP series versions 5.10 through 5.21 Patch 1, and VPN series versions 4.60 through 5.21 Patch 1.

Share:
For your environment

Are you exposed to this one?

Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.

ANALYST BRIEF

Impact, mitigation & remediation

What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Successful exploitation allows unauthenticated remote command execution on the vulnerable appliance. Reporting indicates attackers can inject arbitrary commands, establish a reverse shell, and gain initial foothold on exposed firewall or VPN devices. Commands were reported to execute as the "nobody" user, but this still provides meaningful control of the appliance and can be sufficient for device compromise, persistence, configuration manipulation, and use of the device as a pivot point into internal networks. Observed and anticipated downstream impacts include lateral movement, espionage, data exfiltration, ransomware enablement, and resale of access to other threat actors.

Mitigation

If you can’t patch tonight, do this now.

If immediate patching is not possible, reduce exposure of the web management and affected CGI interface to untrusted networks, especially the internet. Restrict administrative access to trusted management networks or VPN-only paths, disable external access to the management interface where feasible, and monitor for requests to /ztp/cgi-bin/handler and signs of command injection or reverse-shell activity. CERT.be also recommended enabling two-factor authentication for administrative and VPN access; while this does not fix the underlying unauthenticated flaw, it can reduce risk from other access paths and improve overall device security posture.

Remediation

Patch, then assume compromise.

Apply Zyxel’s fixed firmware updates immediately. The provided content states Zyxel released patches on May 12 and recommends upgrading affected devices to patched releases, including ZLD V5.30 / Patch 1 as applicable to the product line. Administrators should identify all affected USG FLEX, ATP, USG20(W)-VPN, and VPN series devices running vulnerable firmware and upgrade them to the vendor-recommended fixed version from Zyxel’s advisory.
PUBLIC EXPLOITS

Exploits

4 valid exploits after Mallory filtered fakes, detection scripts, and README-only repos (2 hidden).

VALID 4 / 6 TOTALView more in app
CVE-2022-30525MaturityPoCVerified exploit

This repository provides a Python proof-of-concept exploit for CVE-2022-30525, an unauthenticated remote command injection vulnerability in Zyxel firewalls. The main script, CVE-2022-30525.py, allows the user to specify a single target URL or a file containing multiple targets. It sends a crafted POST request to the /ztp/cgi-bin/handler endpoint on the target, injecting a command via the 'mtu' parameter in the JSON body. The injected command pings a unique domain obtained from dnslog.cn, and the script then checks dnslog.cn for evidence of the ping, confirming successful code execution. The exploit does not require authentication and is designed for detection and verification of the vulnerability, not for weaponized post-exploitation. The repository also includes a helper script (dnslog.py) for interacting with dnslog.cn and a sample target list file (ip.txt).

Henry4E36Disclosed May 13, 2022pythonnetwork
victorian_machineryMaturityPoCVerified exploit

This repository contains a proof-of-concept exploit for CVE-2022-30525, a remote unauthenticated command injection vulnerability in several Zyxel firewall models. The main exploit script, 'victorian_machinery.py', is a Python program that takes attacker- and target-specific parameters (remote host/port, local host/port, protocol, and netcat path). It works by forking a process: the child sends a crafted HTTP POST request to the vulnerable Zyxel endpoint ('/ztp/cgi-bin/handler') with a malicious payload in the 'mtu' parameter, which triggers a reverse shell connection back to the attacker's machine. The parent process starts a netcat listener to catch the shell. The exploit is effective against unpatched Zyxel firewalls with the management web interface exposed. The repository is well-documented, with a detailed README explaining the vulnerability, affected models, usage instructions, and example output. No detection or scanning functionality is present; this is a direct exploitation tool.

jbaines-r7Disclosed May 10, 2022pythonnetwork
CVE-2022-30525_ExploitMaturityPoCVerified exploit

This repository contains a Python proof-of-concept exploit for CVE-2022-30525, a remote command injection vulnerability affecting multiple Zyxel firewall products. The main script, CVE-2022-30525.py, allows the user to test a single target or perform bulk scanning against multiple targets listed in a file. The exploit works by sending a crafted POST request to the /ztp/cgi-bin/handler endpoint on the target device, injecting a command via the 'mtu' parameter. The injected command triggers a DNS request to a domain controlled by dnslog.cn, allowing the script to verify successful command execution by checking for the corresponding DNS query. The repository also includes a README.md with detailed vulnerability information, affected products, and usage instructions. No weaponized payload is included; the exploit is designed for verification and demonstration purposes.

arajsingh-infosecDisclosed Feb 27, 2024pythonnetwork
CVE-2022-30525-Reverse-ShellMaturityPoCVerified exploit

This repository contains a Python exploit script (CVE-2022-30525.py) targeting Zyxel firewall devices running ZLD firmware versions 5.00 through 5.21. The exploit leverages an unauthenticated remote command injection vulnerability in the /ztp/cgi-bin/handler HTTP endpoint. The attacker supplies the target URL, a remote host, and a port; the script then sends a specially crafted JSON payload that injects a bash reverse shell command via the 'mtu' parameter. If successful, the target device initiates a reverse shell connection to the attacker's machine, granting remote command execution. The repository also includes a 'banner' file (ASCII art and credits) and a 'requirements.txt' specifying the 'requests' Python library. The exploit is operational, providing a working reverse shell payload, and is not part of a larger framework.

ChocapikkDisclosed May 18, 2022pythonnetwork
EXPOSURE SURFACE

Affected products & vendors

Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.

VendorProductType
Zyxel CommunicationsAtp100 Firmwareoperating_system
Zyxel CommunicationsAtp100w Firmwareoperating_system
Zyxel CommunicationsAtp200 Firmwareoperating_system
Zyxel CommunicationsAtp500 Firmwareoperating_system
Zyxel CommunicationsAtp700 Firmwareoperating_system
Zyxel CommunicationsAtp800 Firmwareoperating_system
Zyxel CommunicationsUsg Flex 100w Firmwareoperating_system
Zyxel CommunicationsUsg Flex 200 Firmwareoperating_system
Zyxel CommunicationsUsg Flex 500 Firmwareoperating_system
Zyxel CommunicationsUsg Flex 50w Firmwareoperating_system
Zyxel CommunicationsUsg Flex 700 Firmwareoperating_system
Zyxel CommunicationsUsg20w-Vpn Firmwareoperating_system
Zyxel CommunicationsVpn100 Firmwareoperating_system
Zyxel CommunicationsVpn1000 Firmwareoperating_system
Zyxel CommunicationsVpn300 Firmwareoperating_system
Zyxel CommunicationsVpn50 Firmwareoperating_system

Vendor-confirmed product mapping. Mallory continuously reconciles this list against your asset inventory.

What this page doesn’t show

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, which detections to deploy, and what to do tonight.
Exposure mapping

Query your assets running an affected version, and investigate the blast radius.

Threat actor evidence2

Every observed campaign linking this CVE to a named adversary.

Associated malware1

Malware families riding this exploit, with evidence and IOCs.

Detection signatures2

YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.

Vendor-by-vendor mapping

Cross-references every affected SKU, including bundled OEM variants.

Social activity1

Community discussion across Reddit, Mastodon, and other social sources.