T09 · Insecure Skill Coding Practices
- Location
SKILL.md:69- Finding
Plaintext Storage of Social-Media API Credentials
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 69–86
Vulnerability Type: Plaintext sensitive credential storage
Risk Level: Highyaml accounts: twitter: api_key: "..." api_secret: "..." access_token: "..." access_secret: "..." linkedin: client_id: "..." client_secret: "..." access_token: "..." instagram: access_token: "..." user_id: "..." # Add as many as neededTechnical Analysis
The documented quick-start procedure instructs users to place API keys, API secrets, client secrets, and access tokens directly in a local
social-config.yamlfile. Although the displayed values are placeholders rather than active credentials, users following these instructions would create a plaintext credential store.The documentation does not prescribe environment-variable substitution, an operating-system or cloud secret manager, encryption, restrictive file permissions, repository exclusions, or token-rotation procedures. Consequently, credentials may be exposed through accidental source-control commits, permissive local file access, workstation backups, archive sharing, or diagnostic collection.
The affected tokens may authorize social-media publishing, engagement, analytics access, and other account operations supported by their granted scopes.
Attack Path
- A user follows the quick-start instructions and inserts real platform credentials into
social-config.yaml. - The plaintext configuration is accidentally committed to source control, copied into a shared archive, included in a backup, or read by another local user or process.
- An attacker extracts the API keys, client secrets, or access tokens.
- The attacker submits authenticated requests to the affected social-media APIs.
- Subject to each token's scopes and platform controls, the attacker impersonates the account, publishes or modifies content, performs engagement actions, or accesses account information and analytics.
...[truncated 627 chars]
- A user follows the quick-start instructions and inserts real platform credentials into
- Remediation
View remediation
Remediation Suggestions
- Replace literal credential fields with environment-variable references or secret-manager identifiers, for example
${TWITTER_ACCESS_TOKEN}. - Recommend an operating-system keychain, CI/CD secret store, or managed cloud vault for production credentials.
- If a local configuration file is unavoidable, separate secrets from non-sensitive configuration and enforce owner-only permissions such as
chmod 600. - Add
social-config.yamland equivalent secret-bearing files to.gitignore. - Provide a sanitized
social-config.example.yamlcontaining placeholders only. - Validate configuration at runtime and reject credential files with unsafe permissions where the operating system supports that check.
- Request only the minimum API scopes required for each selected feature.
- Use short-lived credentials where supported and document revocation and rotation procedures.
- Add explicit warnings against committing, logging, sharing, or backing up plaintext credentials.
- Introduce secret scanning in development and release workflows to detect accidental credential exposure.
- Replace literal credential fields with environment-variable references or secret-manager identifiers, for example
