T09 · Insecure Skill Coding Practices
- Location
bin/run.mjs:18- Finding
API Token Exposed Through URL Query Parameters
- Content
View full analysis
item.location === "query")) { const value = params[parameter.name]; if (value === undefined) { continue; } appendValue(url.searchParams, parameter.name, value); } } ``` ### Technical Analysis The operation defines the API token as a query parameter. `applyQueryParams` subsequently inserts that token into the URL before the request is sent to the declared HTTPS endpoint. HTTPS protects the URL while it is transmitted over the network, but it does not prevent the complete URL from being recorded by the API server, reverse proxies, gateways, monitoring platforms, diagnostic tooling, or access logs. Query strings may also receive weaker redaction treatment than authorization headers. The network request is necessary for the Skill's declared functionality, and the destination is statically restricted to `https://api.justoneapi.com`. No evidence was found that the token is intentionally transmitted to an unrelated host. Nevertheless, placing the credential in the URL exposes it more broadly than necessary. ### Attack Path 1. A user invokes the Skill with a valid JustOneAPI token. 2. The runner assigns the token to the operation's `token` parameter. 3. `applyQueryParams` constructs a URL containing `?token=`. 4. A reverse proxy, API gateway, server access logger, telemetry system, or ...[truncated 677 chars]- Remediation
View remediation
