Tainted flow: 'req' from os.environ.get (line 50, credential/environment) → urllib.request.urlopen (network output)
Critical
- Category
- Data Flow
- Content
data = json.dumps(payload).encode("utf-8") headers["Content-Type"] = "application/json" req = urllib.request.Request(url, method=method, data=data, headers=headers) with urllib.request.urlopen(req) as resp: return json.loads(resp.read())- Confidence
- 87% confidence
- Finding
- The request target is derived in part from the HUANGLI_BASE environment variable and then used directly in urllib.request.urlopen with an Authorization bearer token attached. If an attacker can influence that environment variable, they can redirect requests to an attacker-controlled host and capture the token or proxy sensitive responses, creating an SSRF-style exfiltration path.
