Tainted flow: 'req' from os.environ.get (line 31, credential/environment) → urllib.request.urlopen (network output)
Critical
- Category
- Data Flow
- Content
headers = {"Content-Type": "application/json", "X-Proxy-Token": PROXY_TOKEN} req = urllib.request.Request(PROXY_URL, data=payload, headers=headers, method="POST") try: with urllib.request.urlopen(req, timeout=timeout) as resp: return json.loads(resp.read().decode("utf-8")) except (socket.timeout, TimeoutError): return {"ok": False, "error": "timeout"}- Confidence
- 97% confidence
- Finding
- The request destination and authentication token are both sourced from environment variables and then used in an outbound HTTP request without validation or allowlisting. If an attacker can influence PROXY_URL or deployment configuration, the skill can be redirected to an attacker-controlled endpoint and will transmit the X-Proxy-Token, enabling SSRF-like behavior and credential leakage.
