T09 · Insecure Skill Coding Practices
- Location
scripts/script.sh:4- Finding
Undisclosed Persistent Storage and Raw Activity Logging
- Content
View full analysis
> "$DATA_DIR/history.log"; } ``` ```bash cmd_list() { [ -f "$DB" ] && cat "$DB" || echo " (empty)" _log "list" "${1:-}" } cmd_add() { echo "$(date +%Y-%m-%d) $*" >> "$DB"; echo " Added: $*" _log "add" "${1:-}" } ``` ### Technical Analysis The script creates a persistent data directory and stores user-supplied content in `data.log`. It also silently records command activity and the first supplied argument in `history.log`. This behavior is not aligned with the functionality documented in `SKILL.md`, which presents the skill as a generator of release-readiness checklists for code, APIs, deployment, versioning, launches, and regression tests. The documentation does not disclose that user input or command activity may be retained on disk. The storage destination is derived from `TEST_PUBLISH_CHECK_DIR`, `XDG_DATA_HOME`, or the user's home directory. Consequently, data can persist across executions and outside the audited project directory. Raw arguments are written without data classification, redaction, retention controls, or restrictive file permissions. This is not agent memory poisoning because the stored content is not shown to be loaded as future agent instructions. It is an insecure data-handling and privacy practice. ### Attack Path 1. A user or agent invokes `scripts/script.sh`, believing it provides the documented release-checking functionality. 2. The script creates a persistent directory under the configured data path. 3. The caller executes ...[truncated 1203 chars]- Remediation
View remediation
