T09 · Insecure Skill Coding Practices
- Location
scripts/full-scan.sh:107- Finding
Plaintext Secrets and Master Password Are Exposed to an Unverified External Helper
- Content
View full analysis
/dev/null | grep -q "Stored"; then echo " 🔒 Encrypted to Notion as 'scan-${label}'" else echo " ⚠️ Failed to encrypt to Notion" fi } ``` ```bash if [[ "$ENCRYPT_FOUND" == "true" ]]; then local secret_line secret_line=$(grep -rEn "$secret_regex" "$file" 2>/dev/null | head -1 || true) [[ -n "$secret_line" ]] && encrypt_to_notion "${skill_name}-$(basename "$file")" "$secret_line" fi ``` ### Technical Analysis When `--encrypt-found` is enabled, the scanner extracts the first complete source line matching its secret-detection expression. It then passes that line as a command-line argument to `~/.openclaw/scripts/notion-secrets.js` while providing `NOTION_MASTER_PASSWORD` through standard input. The helper is outside the audited package. This project does not bundle it, pin its expected hash, verify its ownership or permissions, or otherwise establish its integrity before executing it. Consequently, the audit cannot verify the helper's claimed local encryption or its network destination. A malicious or replaced helper would receive both the plaintext finding and the master password. Passing the finding through `"$secret"` as an argument also exposes it ...[truncated 2419 chars]- Remediation
View remediation
