Back to Checks
Claude organization data retention periods are within the documented maximum
dataprivacy_retention_within_maximum
Service: dataprivacySeverity: medium
OfficialVerifiedPrivate
Categories:gen-ai
Resource Type:ClaudeOrganizationSettings
Retention windows match the documented maximum. A retention window longer than the one your privacy notice states is a commitment the organization is not keeping.
Risk
A retention window longer than the one your privacy notice states is a commitment the organization is not keeping.
Run this check with Prowler
Run in Prowler CloudInstall
pip install --extra-index-url https://__token__:${PROWLER_REGISTRY_DOWNLOAD_API_KEY}@registry.prowler.com/simple/ "prowler-provider-claude[runtime]"Run
prowler claude --checks dataprivacy_retention_within_maximumRecommendation
Shorten retention to the window you documented, or update claude_max_retention_days to the window you actually committed to.
Remediation
Other
1Shorten retention to the window you documented, or update claude_max_retention_days to the window you actually committed to.
Check Code
from prowler.lib.check.models import Check
from prowler_provider_claude.lib.report import CheckReportClaude
from prowler_provider_claude.services.dataprivacy.dataprivacy_client import (
dataprivacy_client,
)
class dataprivacy_retention_within_maximum(Check):
"""Retention windows match the documented maximum."""
def execute(self) -> list[CheckReportClaude]:
maximum = dataprivacy_client.audit_config.get("claude_max_retention_days", 90)
findings = []
for settings in dataprivacy_client.settings:
row = settings.get("data_retention_periods")
periods = row.value if row and isinstance(row.value, dict) else {}
if not periods:
continue
report = CheckReportClaude(metadata=self.metadata(), resource=settings)
org = settings.name.removesuffix(" effective settings")
over = []
for name, value in periods.items():
# Only fixed windows have a length; indefinite is its own check.
if not isinstance(value, dict) or value.get("type") != "fixed":
continue
duration = value.get("duration")
if not isinstance(duration, (int, float)):
continue
days = int(duration) * (30 if value.get("timescale") == "month" else 1)
if days > maximum:
over.append(f"{name} ({days} days)")
if over:
report.status = "FAIL"
report.status_extended = (
f"Organization {org} retains {', '.join(sorted(over))}, longer than the "
f"documented maximum of {maximum} days."
)
else:
report.status = "PASS"
report.status_extended = (
f"Organization {org} retains every configured data type within the "
f"documented maximum of {maximum} days."
)
findings.append(report)
return findings