T09 · Insecure Skill Coding Practices
- Location
SKILL.md:156- Finding
Unnecessary Plaintext API Key Stored in Persistent Scheduler Configuration
- Content
View full analysis
> ~/finance/fetch.log 2>&1 ``` ```text ### Windows 任务计划程序 1. 创建基本任务,触发器:每小时 2. 操作:启动程序 → `py` 3. 参数:`fetch_data.py --db-path C:\Users\你\finance\finance.db` 4. 在用户环境变量中设置 `FINNHUB_API_KEY=你的key` ``` ```json { "cron": "0 * * * *", "command": "python3", "args": ["fetch_data.py", "--db-path", "~/finance/finance.db"], "env": { "FINNHUB_API_KEY": "你的key" }, "workdir": "~/finance" } ``` ### Technical Analysis The documentation instructs users to place a Finnhub API key directly into crontab, an OpenClaw cron environment object, or a persistent user environment variable. These locations may be exposed through scheduler inspection tools, configuration exports, backups, diagnostics, or compromise of the same user account. This credential is not necessary for the implemented functionality. `scripts/fetch_data.py` only performs unauthenticated HTTPS requests to fixed CNBC quote URLs. Its argument parser does not support `--finnhub-key`, and the script does not read `FINNHUB_API_KEY`. Persisting the key therefore exceeds the minimum privileges and information required by the Skill. The scheduled execution itself is visible, explicitly configured by the user, and aligned with periodic financial monitoring. It is not evidence of a covert backdoor. The vulnerability is the unnecessary persistence and exposure of a real credential within scheduler configuration. ### Attack Path 1. A user follows `SKILL.md` and substitutes a real Finnhub API key for the placeholder. 2. The key is saved in crontab, OpenClaw scheduler configuration, or the user's persistent environment. 3. A local process, diagnostic u ...[truncated 1043 chars]- Remediation
View remediation
