T09 · Insecure Skill Coding Practices
- Location
scripts/setup.py:79- Finding
DataForSEO Password Is Collected Through Echoed Terminal Input
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This SEO skill mostly does what it says, but its setup handles API credentials and Python installation in risky ways that should be reviewed before use.
Review before installing. Use a virtual environment instead of running setup.py against your system Python, do not use the README command that prints ~/.config/seo-agi/.env, avoid entering passwords in a shared or recorded terminal, and protect or replace the plaintext .env file with environment variables or a credential manager where possible.
scripts/setup.py:79DataForSEO Password Is Collected Through Echoed Terminal Input
scripts/setup.py:102Credential File Is Written Without Enforced Restrictive Permissions and Documentation Prints Its Contents
scripts/setup.py:41Setup Installs Unpinned Dependencies Into the Active Python Environment
The troubleshooting step recommends cat ~/.config/seo-agi/.env, which would print stored API credentials directly to the terminal or agent output. In an agent environment, that can expose secrets to logs, transcripts, screenshots, or downstream model context, turning a benign check into credential disclosure.
Check if API keys are configured:
cat ~/.config/seo-agi/.env 2>/dev/null || echo "No .env file -- skill will use fallback mode"
Test with live DataForSEO (if you have keys):
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The skill description suggests straightforward content generation, yet the instructions include dependency installation, filesystem setup, credential collection, and configuration for third-party research services. These actions materially change the risk profile because they encourage environment modification and secret handling not implied by the public description.
The spec calls for API credentials to be stored in ~/.config/seo-agi/.env, which implies plaintext secret storage on disk. If file permissions are weak, the home directory is backed up/synced, or another local process/user can read the file, DataForSEO and GSC credentials could be stolen and abused for account access, data extraction, or billing-impacting API use.
~/.config/seo-agi/
├── .env # API credentials
├── config.json # User preferences (default location, language, site URL)
└── sites.json # GSC verified sites cache
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
"""
seo-agi environment and configuration loader.
Reads API keys from ~/.config/seo-agi/.env or os.environ.
Resolves paths relative to the skill installation directory.
"""
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
"""
seo-agi environment and configuration loader.
Reads API keys from ~/.config/seo-agi/.env or os.environ.
Resolves paths relative to the skill installation directory.
"""
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
"""
seo-agi environment and configuration loader.
Reads API keys from ~/.config/seo-agi/.env or os.environ.
Resolves paths relative to the skill installation directory.
"""
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
from pathlib import Path
CONFIG_DIR = Path.home() / ".config" / "seo-agi"
ENV_FILE = CONFIG_DIR / ".env"
CONFIG_FILE = CONFIG_DIR / "config.json"
OUTPUT_DIR = Path.home() / "Documents" / "SEO-AGI"
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
from pathlib import Path
CONFIG_DIR = Path.home() / ".config" / "seo-agi"
ENV_FILE = CONFIG_DIR / ".env"
CONFIG_FILE = CONFIG_DIR / "config.json"
OUTPUT_DIR = Path.home() / "Documents" / "SEO-AGI"
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
from pathlib import Path
CONFIG_DIR = Path.home() / ".config" / "seo-agi"
ENV_FILE = CONFIG_DIR / ".env"
CONFIG_FILE = CONFIG_DIR / "config.json"
OUTPUT_DIR = Path.home() / "Documents" / "SEO-AGI"
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
from pathlib import Path
CONFIG_DIR = Path.home() / ".config" / "seo-agi"
ENV_FILE = CONFIG_DIR / ".env"
CONFIG_FILE = CONFIG_DIR / "config.json"
OUTPUT_DIR = Path.home() / "Documents" / "SEO-AGI"
This finding corresponds to the code path that persists credentials into a .env file, creating a local credential exposure risk. In the context of an SEO skill, collecting third-party API secrets may be legitimate, but storing them unencrypted and without explicit warning makes compromise more likely if the workstation or home directory is accessed.
else:
gsc_path = input("Path to GSC service account JSON (or Enter to skip): ").strip()
# Write .env
env_lines = [
"# SEO-AGI Configuration",
f"# Generated by setup.py on {__import__('datetime').datetime.now().isoformat()[:10]}",
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
mkdir -p ~/.config/seo-agi
cp ~/.claude/skills/seo-agi/.env.example ~/.config/seo-agi/.env
The README states the skill auto-triggers on broad SEO content requests, which can cause unintended invocation on generic prompts and lead an agent to perform networked research, content generation, and file-writing actions the user did not explicitly authorize. In an agent environment, overbroad trigger scope increases the chance of surprise side effects and tool execution beyond user intent.
The README says the skill will save generated pages to ~/Documents/SEO-AGI/pages/ but does not warn about file creation, naming, or overwrite behavior. In agentic contexts this can result in silent local writes, clobbering existing content, or leaving sensitive/generated material on disk without informed consent.
Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
Check if the skill is installed:
ls ~/.claude/skills/seo-agi/SKILL.md && echo "Installed" || echo "Not found"
Check if API keys are configured:
Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
Check if the skill is installed:
ls ~/.claude/skills/seo-agi/SKILL.md && echo "Installed" || echo "Not found"
Check if API keys are configured:
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
1. Find what's ranking
2. Figure out what they cover that you don't
3. Write something deeper
4. Add the technical SEO (schema, meta, structure)
5. Publish and move on
No suspicious patterns detected.