T09 · Insecure Skill Coding Practices
- Location
scripts/guard.py:43- Finding
Sensitive values are disclosed in plaintext security reports
- Content
View full analysis
- Remediation
View remediation
str: if len(value) <= 8: return "*" * len(value) return value[:3] + "*" * (len(value) - 7) + value[-4:] ``` 3. Ensure both text and JSON output use the masked representation. 4. When `--auto-redact` is enabled, sanitize every output field rather than only adding a sanitized copy of the prompt. 5. If raw-match reporting is operationally necessary, place it behind an explicitly named option such as `--unsafe-show-raw-matches`, display a warning, and keep it disabled by default. 6. Document that command output may be captured by shell, CI, or monitoring logs. 7. Add automated tests asserting that known test credentials and personal identifiers never appear in default text or JSON output. ]]>
