T09 · Insecure Skill Coding Practices
- Location
SKILL.md:37- Finding
Insecure Plaintext Persistence of Orb API Credentials
- Content
View full analysis
I need your Orb API key to create artifacts. > Get one at **https://byorb.app/dashboard/settings** → **Create API Key** 2. Once the user provides the key, **persist it** so it survives across sessions. Use your native configuration mechanism: - **Claude Code**: Add to `~/.claude/settings.json` under `"env": { "ORB_API_KEY": "..." }` - **Gemini CLI**: Write to `~/.gemini/.env` as `ORB_API_KEY=...` - **Codex**: Add to `~/.codex/config.toml` under `[shell_environment_policy]` with `set = { ORB_API_KEY = "..." }` - **Fallback**: Append `export ORB_API_KEY=...` to the user's shell profile (`~/.zshrc` or `~/.bashrc`) 3. Also `export ORB_API_KEY=...` in the current session so it's available immediately. ``` ### Technical Analysis The Skill explicitly requires an Agent to persist `ORB_API_KEY` in plaintext configuration files, dotenv files, or shell startup files. Persistent storage is not required for the declared operation of submitting artifacts to the Orb API; a process-scoped or session-scoped environment variable is sufficient. The instructions do not require: - Explicit user consent before persistent storage. - Use of an operating-system credential manager or secret vault. - Restrictive owner-only permissions on credential files. - Validation or safe encoding of the supplied credential. - Protection against symlink attacks when writing configuration files. - Secure removal or API-key revocation procedures. The shell-profile fallback is particularly risky. Files such as `~/.zshrc` and `~/.bashrc` are interpreted whenever a new shell starts. If an Agent directly interpolates an untrusted key into a ...[truncated 2612 chars]- Remediation
View remediation
