T09 · Insecure Skill Coding Practices
- Location
SKILL.md:105- Finding
Sensitive credentials and session tokens exposed through command-line arguments
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:105-107, 156-157;auth/SKILL.md:22-25, 33-36;session/SKILL.md:77;session/references/lifecycle.md:28
Vulnerability Type: Sensitive information exposure through process arguments
Risk Level: HighVulnerable Code
SKILL.md:105-107:bash - For password login, use `mttsports auth login --email ... --password ... --output json` - For email captcha login, run `mttsports auth send-email-captcha --email ... --output json` first, then `mttsports auth login --email ... --captcha ... --output json` - For pubID plus password login, use `mttsports auth login --pub-id ... --password ... --output json`SKILL.md:156-157:bash - `mttsports session start --room-key <room_key> --table-key <table_key> --table-server-id <id> --session-token <token> --output json` - If `session_token` is not explicitly available here, check the most recent structured output first. Only fall back to local login state if needed.auth/SKILL.md:33-36:bash mttsports auth send-email-captcha --email you@example.com --output json mttsports auth login --email you@example.com --password '***' --output json mttsports auth login --email you@example.com --captcha '123456' --output json mttsports auth login --pub-id PUB123 --password '***' --output jsonsession/SKILL.md:77:bash mttsports session start --room-key <room_key> --table-key <table_key> --table-server-id <id> --session-token <token> --output jsonTechnical Analysis
The Skill instructs the agent to place passwords, one-time email captchas, and session tokens directly in command-line arguments. Command-line secrets may be observable through process inspection facilities, shell history, terminal capture, system audit facilities, process-monitoring software, or agent command-execution logs.
Quoting a password only controls shell ...[truncated 1809 chars]
- Remediation
View remediation
Remediation Suggestions
- Add CLI support for secrets supplied through protected standard input or a dedicated file descriptor, such as
--password-stdinand--session-token-stdin. - For interactive use, read passwords and captchas through a no-echo terminal prompt rather than command-line flags.
- Store reusable credentials in an operating-system credential manager or keychain with access limited to the current user and CLI.
- Prefer an opaque reference to locally protected login state over copying a session token into agent-generated command text.
- Explicitly prohibit placing passwords, captchas, and tokens in shell commands, shell history, conversation messages, or tool logs.
- Apply field-level redaction to command telemetry and structured output. Redact password, captcha, authorization, cookie, refresh-token, and session-token fields.
- If a temporary secret file is unavoidable, create it with mode
0600, avoid predictable paths, pass it by descriptor where possible, and securely delete it immediately after use. - Rotate credentials and invalidate active sessions if command or execution logs containing real values may already exist.
- Add CLI support for secrets supplied through protected standard input or a dedicated file descriptor, such as
