-
Notifications
You must be signed in to change notification settings - Fork 583
Expand file tree
/
Copy pathGHSA-v7p8-c4f6-jw32.json
More file actions
48 lines (48 loc) · 1.86 KB
/
GHSA-v7p8-c4f6-jw32.json
File metadata and controls
48 lines (48 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
{
"schema_version": "1.4.0",
"id": "GHSA-v7p8-c4f6-jw32",
"modified": "2026-04-20T00:00:00Z",
"published": "2026-04-20T00:00:00Z",
"aliases": [],
"summary": "hexstrike-ai: Command Injection in multiple /api/tools/* endpoints via unsanitized parameters",
"details": "hexstrike-ai contains command injection vulnerabilities in multiple tool endpoints of its Flask REST API server (hexstrike_server.py). Endpoints such as /api/tools/nmap, /api/tools/dig, /api/tools/whois, and 10+ other tool endpoints construct shell commands using Python f-strings with user-supplied input, then execute them via subprocess.Popen() with shell=True.\n\nNo authentication is required. An attacker can inject arbitrary shell commands via the tool parameters.\n\nExample exploitation via /api/tools/nmap:\n\n```\ncurl -X POST http://<host>:5000/api/tools/nmap -H \"Content-Type: application/json\" -d '{\"target\": \"127.0.0.1; id > /tmp/pwned.txt\"}'\n```\n\nVulnerable pattern (repeated across 10+ endpoints):\n```python\ncommand = f\"nmap {flags} {target}\"\nprocess = subprocess.Popen(command, shell=True, ...)\n```\n\nRoot cause: Unsanitized user input concatenated into shell commands (CWE-78).",
"severity": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
}
],
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "hexstrike-ai"
},
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
}
]
}
]
}
],
"references": [
{
"type": "WEB",
"url": "https://github.com/0x4m4/hexstrike-ai"
}
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"severity": "CRITICAL",
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": null
}
}