Tainted flow: 'target_url' from requests.get (line 106, network input) → requests.get (network output)
Medium
- Category
- Data Flow
- Content
if target_url.startswith('//'): target_url = 'https:' + target_url resp = requests.get(target_url) body = resp.json().get('body', []) full_text = "\n".join([b.get('content', '') for b in body]) return full_text- Confidence
- 88% confidence
- Finding
- The code fetches a second URL taken from Bilibili API response data without validating the destination host or scheme. If that upstream response is compromised or unexpectedly attacker-controlled, this can trigger server-side requests to arbitrary locations, including internal services or sensitive metadata endpoints, creating an SSRF-style risk.
