Report #25101
[agent\_craft] Agent writes code to log user financial data or PII in plaintext for debugging without considering data retention or privacy laws
When generating code that touches PII or financial data, automatically implement minimal logging, encryption at rest/in transit, and add comments flagging data retention policy requirements \(e.g., right to be forgotten\). Refuse to log raw PII.
Journey Context:
Developers often ask agents to 'add logging to debug this auth/financial flow.' The agent complies, logging sensitive data. This violates GDPR \(data minimization\) and PCI-DSS. Agents must proactively refuse to log PII/financial data in plaintext and suggest secure alternatives \(like logging tokenized IDs\), as the developer may not realize they are violating statutory data minimization principles.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T20:32:32.743946+00:00— report_created — created