GitGuardian finds 31,088 secrets in public Claude Code settings files, 5,343 still valid when found

GitGuardian · Company report

Read the source (opens in a new tab)
What happened
GitGuardian said on November 9, 2026 that it found 31,088 distinct secrets in Claude Code's .claude/settings.local.json files pushed to public GitHub, across 23,276 repositories, from January 2025 through November 7, 2026.
Key points
  • In the behavior GitGuardian studied, answering "Yes, and don't ask again" made Claude Code save an allow rule that was the full command string, so secrets typed into commands landed in the file.
  • Of the 31,088 secrets, 5,343 worked when detected, including 1,955 Postgres connection strings; another 613 secrets, 99 valid, reached public Docker Hub images.
  • Monthly leaks peaked at 12,535 in April 2026 and fell 92% to 959 by October; GitGuardian says it does not know what changed.
  • Citing iTnews, it says Anthropic's Claude Code lead called the issue under review and exposed copies were likely created manually and committed; GitGuardian says every secret it inspected matched the prompt's rule format.
Evidence
Security vendor's research post from its own scanning of public commits and Docker images. Validity counts come from automatic read-only checks and are floors, since some detectors have no checker.
Uncertain
Anthropic's response is reported secondhand through iTnews. The cause of the drop since April is unknown, and GitGuardian has not ruled out changes in its own detectors.

See it in the latest record