Apiiro research found that Claude Code's "don't ask again" feature led to 2,539 sensitive credentials being exposed in 1,994 public GitHub repositories
Claude Code's "Don't Ask Again" Feature Exposes 2,539 Secrets Across 1,994 GitHub Repositories
Apiiro's research traced the exposure of 2,539 sensitive credentials in 1,994 public GitHub repositories to coding agent configuration files, Git history and session records, involving 63 organizations. The research states that Claude Code's "approve and don't ask again" approval stores commands containing credentials verbatim as allow rules in .claude/settings.local.json, while global Git ignore protections do not propagate with the project; one organization confirmed that its exposed key had been valid. Apiiro scanned 104,185 public settings files and found 1,379 distinct credentials in 1,122 of them, including 379 database passwords, 122 Supabase service-role keys and 43 SSH credentials; historical versions also contained 734 credentials not present in current copies. Gitleaks and TruffleHog flagged only 564 and 643 files containing secrets respectively, and 215 were found by neither.
The research presents the mechanism by which credentials are stored in settings files along with approved commands, and the scan data, which teams using Claude Code can use to check local configurations and Git history for sensitive commands.