T05 · Unauthorized Access and Privilege Escalation
- Location
scripts/proxy-server.py:10- Finding
Unauthenticated CORS Proxy Exposes Privileged Gateway Tool Invocation
- Content
View full analysis
0 else b'' # Forward to Gateway url = f'{GATEWAY_URL}{path}' headers = { 'Authorization': f'Bearer {GATEWAY_TOKEN}', 'Content-Type': 'application/json' } req = urllib.request.Request(url, data=body, headers=headers, method='POST') with urllib.request.urlopen(req) as response: response_data = response.read() ``` ### Technical Analysis The localhost proxy accepts arbitrary POST bodies under `/api/*`, does not authenticate callers, and automatically attaches a privileged gateway bearer token. Its wildcard CORS policy permits JavaScript fro ...[truncated 1843 chars]- Remediation
View remediation
