Tainted flow: 'req' from os.environ.get (line 170, credential/environment) → urllib.request.urlopen (network output)
Critical
- Category
- Data Flow
- Content
ctx = ssl.create_default_context() try: with urllib.request.urlopen(req, context=ctx) as resp: return json.loads(resp.read().decode("utf-8")) except urllib.error.HTTPError as e: text = e.read().decode("utf-8", errors="replace") if hasattr(e, "read") else ""- Confidence
- 82% confidence
- Finding
- The script constructs authenticated requests using a bearer token and sends them to a base URL that can come from configuration (`audience` or `base_url`). If that configuration is modified to point to an attacker-controlled host, the Authorization header will disclose the Tesla access token and may also expose sensitive vehicle telemetry to an untrusted endpoint. In a skill handling fleet APIs and vehicle data, this is more dangerous because the token grants access to highly sensitive telemetry and possibly remote vehicle actions depending on scope.
