T09 · Insecure Skill Coding Practices
Warning
- Location
- SKILL.md:27
- Finding
- Actual Budget credentials may be exposed through command-line arguments and plaintext HTTP<![CDATA[ ## Vulnerability Details **File Location**: - `SKILL.md:27` - `references/commands.md:13` - `references/commands.md:152-159` - `references/command-reference.md:76` - `references/command-reference.md:97-106` **Vulnerability Type**: Credential exposure and insecure transport **Risk Level**: Medium ### Vulnerable Code Snippets `SKILL.md:27`: ```text - If a command returns `{ code: "not-logged-in" }`, ask for the server password, run `fscl login [server-url] --password <pw>`, then retry the original command. ``` `references/commands.md:152-159`: ```bash # Pull existing remote budget fscl login http://actual.local:5006 --password secret fscl init --non-interactive --mode remote \ --server-url http://actual.local:5006 --sync-id <id> # Create local, then upload to server fscl init --non-interactive --mode local --budget-name "My Budget" fscl login http://actual.local:5006 --password secret fscl budgets push --server-url http://actual.local:5006 ``` `references/command-reference.md:97-106`: ```text ## login `fscl login [server-url] [--password <pw>]` Authenticates with the Actual server and stores `serverURL` + `token` in config. If `--password` is omitted in a TTY, fscl prompts securely. Server URL resolution: 1. Positional arg (`[server-url]`) 2. `FISCAL_SERVER_URL` 3. Config `serverURL` ``` ### Technical Analysis The primary Skill instruction tells the Agent to request the user's server password and place it directly in the `fscl` process arguments. Command-line secrets can be exposed through: - Shell history - Process enumeration facilities - Terminal transcripts - Agent tool-call logs - Debugging and telemetry systems - Error reports that record the complete command The command reference expressly documents that omitting `--password` causes `fscl` to prompt securely in a TTY. The Skill nevertheless directs the Agent to use the less secure command-line option. The examples also authenticate and upload financial data through an `http://` UR ...[truncated 1940 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Remove `--password <pw>` from Agent-facing login instructions. 2. Use the documented secure TTY prompt: ```bash fscl login <verified-https-server-url> ``` 3. If non-interactive authentication is required, implement a protected stdin or operating-system secret-store integration that does not expose the password in process arguments. 4. Do not ask users to submit reusable passwords in ordinary chat when a secure prompt is available. 5. Require HTTPS for every non-loopback server. Reject unsupported schemes and warn before connecting to plaintext HTTP endpoints. 6. Before login, synchronization, or upload, show the normalized destination URL and obtain explicit user confirmation. 7. Default to local-only mode unless the user expressly chooses remote synchronization. 8. Ensure stored session tokens have restrictive filesystem permissions, are excluded from logs and backups where appropriate, and can be revoked through logout or server-side session management. 9. Redact passwords, tokens, server URLs containing credentials, and authentication commands from Agent logs and error messages. ]]>
