Tainted flow: 'req' from os.environ.get (line 60, credential/environment) → urllib.request.urlopen (network output)
Critical
- Category
- Data Flow
- Content
headers=_headers(), ) try: with urllib.request.urlopen(req, timeout=30) as resp: return json.loads(resp.read().decode("utf-8")) except urllib.error.HTTPError as e: err_body = e.read().decode("utf-8") if e.fp else ""- Confidence
- 96% confidence
- Finding
- The request destination is derived from the environment-controlled IM_BASE value and then used in urllib.request.urlopen while always attaching the Bearer access key in the Authorization header. If an attacker can influence environment variables or deployment configuration, they can redirect requests to an arbitrary host and exfiltrate the LIBTV_ACCESS_KEY, turning this into an SSRF-style credential leakage issue. In an agent skill context, this is more dangerous because the code is designed to run with privileged API credentials and make outbound network calls automatically.
