T09 · Insecure Skill Coding Practices
- Location
SKILL.md:54- Finding
Plaintext Bearer Credential Storage Without Access-Control Guidance
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 54–57
Vulnerability Type: Plaintext sensitive credential storage
Risk Level: MediumVulnerable Code
markdown **Save your API key!** Store it in `~/.config/agentarcade/credentials.json`: ```json {"api_key": "aa_sk_xxx", "agent_name": "YourName"}text ### Technical Analysis The Skill instructs users or agents to save an AgentArcade bearer API key in a plaintext JSON file. It does not require restrictive permissions for either the `~/.config/agentarcade` directory or the credential file. Because possession of a bearer key is sufficient for authentication, any local user or process able to read this file may reuse the key. Actual exposure depends on the operating system, account isolation, default `umask`, and resulting file permissions. The audited package contains documentation only and does not itself create or read the file, so automatic credential theft was not identified. The separate reference to `~/.config/moltbook/credentials.json` at `SKILL.md:18` is only a prerequisite. No instruction in the audited files sends that credential file to AgentArcade or otherwise demonstrates exfiltration. ### Attack Path 1. A user or agent follows the documented instructions and writes the AgentArcade API key to `~/.config/agentarcade/credentials.json`. 2. The file is created with permissions that permit access by another local account or an untrusted process operating under the same account. 3. The attacker reads and copies the `aa_sk_*` bearer token. 4. The attacker supplies the stolen token in the `Authorization: Bearer` header documented by the Skill. 5. AgentArcade accepts requests as originating from the victim's agent until the credential is revoked or expires. ### Impact Assessment A successful attacker could impersonate the affected AgentArcade agent and invoke API operations authorized by the stolen key, including viewing its profile or match information, finding opponents, ...[truncated 283 chars]- Remediation
View remediation
Remediation Suggestions
- Create
~/.config/agentarcadewith mode0700. - Create and retain
credentials.jsonwith mode0600; do not rely solely on ambientumasksettings. - Prefer an operating-system credential manager or secret store instead of a plaintext JSON file.
- Never print, log, commit, or include the API key in diagnostics.
- Document key revocation and rotation procedures.
- Use narrowly scoped and expiring API tokens if the service supports them.
- Before reading the credential, verify that the file is owned by the expected user and is not a symbolic link or accessible by group/other users.
- Create
