Written retention schedule for each data type; automated deletion confirmed
Why it matters
GDPR Art. 5(1)(e) requires data to be kept in identifiable form no longer than necessary — "storage limitation" is a core data protection principle, not an optional enhancement. Art. 13(2)(a) requires retention periods to be disclosed in the privacy policy, creating a legal promise you must technically enforce. CCPA §1798.105 gives California residents the right to demand deletion, which requires that you have the infrastructure to actually delete. ISO-27001:2022 A.8.10 requires media disposal and data deletion controls. An undocumented or unenforced retention schedule is also a significant incident amplifier: data you promised to delete but didn't can appear in a breach years after the user expected it was gone.
Severity rationale
High because failing to delete data per the documented schedule constitutes both a broken legal promise and a GDPR Art. 5(1)(e) violation, and undeleted data expands the blast radius of any future breach.
Remediation
Document retention periods in your privacy policy and enforce them with an automated cron job. Align the cron schedule with what the policy promises.
// app/api/cron/cleanup/route.ts
// Schedule via vercel.json: { "crons": [{ "path": "/api/cron/cleanup", "schedule": "0 2 * * *" }] }
export async function GET() {
const logCutoff = new Date()
logCutoff.setDate(logCutoff.getDate() - 90)
await db.auditLog.deleteMany({ where: { createdAt: { lt: logCutoff } } })
const graceCutoff = new Date()
graceCutoff.setDate(graceCutoff.getDate() - 30)
await db.user.deleteMany({ where: { deletedAt: { lt: graceCutoff } } })
return Response.json({ ok: true })
}
For each data type in your policy, implement the matching cleanup: analytics events at 26 months, server logs at 90 days, deleted-account data after the grace period. Verify cron jobs are actually running by checking deployment logs monthly.
DetectionPro
The detection method for this pattern is part of AuditBuffet Pro.
The full method (what to look for, pass and fail conditions, and how results get reported) ships inside the Data Protection Audit. The pattern definition, severity rationale, and remediation remain openly licensed under CC-BY-4.0.
External references
- gdpr · Art. 5(1)(e) — Principle of storage limitation
- gdpr · Art. 13(2)(a) — Retention period to be communicated to data subjects
- iso-27001:2022 · A.8.10 — Information deletion
- ccpa · §1798.105 — Consumer right to deletion
- soc2:2017 · CC6.5 — Logical and physical protections over disposed assets
- soc2:2017 · C1.2 — Disposal of confidential information
Taxons
History
- 2026-04-18·v1.0.0·Initial import from data-protection·automated
- 2026-07-06·v1.0.1·Add SOC 2 TSC mapping (CC6.5, C1.2) from the verified compliance crosswalk register (docs/compliance/).·by soc2-mapping-enrichment-ship-2