T09 · Insecure Skill Coding Practices
- Location
SKILL.md:37- Finding
Machine-specific configuration may expose plaintext credentials
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 37-52
Vulnerability Type: Insecure storage of sensitive configuration
Risk Level: MediumVulnerable Code Snippet
markdown ### 2) Configuration (portable) Rules: - Never hardcode machine/user-specific paths, usernames, tenant IDs, tokens, etc. inside `SKILL.md`. - Prefer skill-local config files stored next to `SKILL.md`, e.g.: - `config.env` (dotenv-style KEY="VALUE") - `config.json` (structured) - **Config must be split into two files**: - `config.env.example` (or `config.json.example`) — checked-in/shareable example; never mutated by onboarding - `config.env` (or `config.json`) — real machine-specific values written/updated during onboarding - `SKILL.md` documents: - where config lives - required keys + defaults - which file is the example vs real - how to run onboarding to generate/update the real configTechnical Analysis
The standard directs child Skills to persist real machine-specific configuration in
config.envorconfig.jsonbeside checked-in Skill resources. Machine-specific values can include tokens, as indicated by the prohibition against placing tokens directly inSKILL.md.Although separating example and real configuration files is appropriate, the guidance does not require:
- Excluding real configuration files from version control
- Creating them with restrictive permissions such as
0600 - Using atomic writes that preserve restrictive permissions
- Storing secrets in a credential manager instead of plaintext
- Checking whether a real configuration file is already tracked
- Preventing secret values from appearing in logs, diffs, backups, or error output
Consequently, child Skills implementing this authoritative standard may store credentials in plaintext within a source-controlled or broadly readable directory. The audited file does not itself contain credentials or executa ...[truncated 1399 chars]
- Remediation
View remediation
Remediation Suggestions
Strengthen the configuration standard with mandatory controls:
- Require real configuration files to be excluded from version control, while keeping only example files tracked.
- Require onboarding to verify that real configuration files are not already tracked before writing secrets.
- Create sensitive files atomically with owner-only permissions, such as mode
0600, and verify permissions after writing. - Prefer references to operating-system keychains or dedicated secret managers over storing plaintext token values.
- Prohibit printing secrets in logs, command output, diffs, exceptions, or onboarding summaries.
- Ensure backups and exported Skill packages exclude machine-specific configuration.
- Add an automated smoke test that rejects tracked real configuration files and warns about unsafe permissions.
- Document safe rotation and revocation procedures for credentials that may have been exposed.
