Tainted flow: 'req' from os.environ.get (line 99, credential/environment) → urllib.request.urlopen (network output)
- Category
- Data Flow
- Confidence
- 90% confidence
- Finding
Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.
- Content
python req = urllib.request.Request(url, data=bytes(body), method="POST", headers={ "Authorization": f"Bearer {key}", "Content-Type": f"multipart/form-data; boundary={boundary}"}) try: with urllib.request.urlopen(req, timeout=600) as r: return json.loads(r.read()) except urllib.error.HTTPError as e: sys.exit(f"Transcription API error {e.code}: {e.read().decode(errors='replace')[:400]}")
