T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:16- Finding
Unnecessary Collection of Unused Financial Credentials
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 16-31
Vulnerability Type: Excessive credential requirements and violation of least privilege
Risk Level: Mediumyaml - id: "kalshi-api-key" name: "Kalshi API Key" description: "Read-only API key from Kalshi account settings" env: "KALSHI_API_KEY" - id: "polygon-rpc-url" name: "Polygon RPC URL" description: "Polygon JSON-RPC endpoint (Alchemy, Infura, or public)" env: "POLYGON_RPC_URL" - id: "polymarket-wallet" name: "Polymarket Wallet Address" description: "Your 0x Polygon wallet address holding USDC" env: "POLYMARKET_WALLET_ADDRESS"Technical Analysis
The skill declares a Kalshi API key, Polygon RPC URL, and Polymarket wallet address as required credentials. However, the only implemented operation in the audited file is a Coinbase API request. No documented command uses these three values.
Requiring credentials that are not necessary for implemented functionality violates the principle of least privilege. In particular, a Kalshi API key and a private Polygon RPC URL may grant account access or consume a metered provider service. Making these values available as environment variables unnecessarily increases the sensitive data exposed to the agent runtime and other processes operating in the same security context.
The audited file does not directly transmit these unused values, so this finding concerns unnecessary access and increased exposure rather than confirmed credential exfiltration.
Attack Path
- A user installs or enables the skill based on its stated multi-platform balance-checking functionality.
- The runtime requests the credentials declared in the skill metadata.
- The user supplies a Kalshi API key, Polygon RPC URL, and Polymarket wallet address.
- These values become available in the runtime environment even though the implemented operation does not require them.
...[truncated 905 chars]
- Remediation
View remediation
Remediation Suggestions
- Remove the Kalshi, Polygon RPC, and Polymarket credential declarations until corresponding operations are implemented.
- Request each credential only when the user explicitly invokes the operation that requires it.
- Separate platform integrations so enabling Coinbase balance retrieval does not expose credentials for unrelated services.
- Enforce and verify read-only API scopes rather than relying solely on descriptive text.
- Warn users when an RPC URL contains an embedded provider token and store it using a protected secret mechanism.
- Ensure secrets are isolated per skill and are not broadly inherited by unrelated tools or subprocesses.
- Document precisely why each credential is needed, where it is sent, and which permissions it must possess.
