- Choosing 'don't ask again' writes the full command, including secrets, in plaintext to the local settings file
- The file should be covered by the global .gitignore but still reaches public repos at scale
- Thousands of database passwords, API tokens, and root credentials were found exposed
AI CURATED HOT STORY · 11/8/2026
Claude Code Config Leak Exposes 2,539 Secrets Across 63 Organizations
Security firm Apiiro has discovered a critical flaw in Anthropic's Claude Code: the "Yes, and don't ask again" option persists full commands containing sensitive credentials—including database passwords, cloud admin keys, API tokens, and SSH root login details—in plaintext to the local settings file .claude/settings.local.json. Although Anthropic's documentation states this file is added to the global .gitignore by default, the protection has gaps, resulting in 2,539 real secrets leaked across 1,994 public GitHub repositories and affecting 63 organizations.
Cross-validation by Apiiro shows the leaked credentials span multiple high-privilege categories, enabling attackers to directly access databases, cloud resources, or servers. The fact that many files still reached public repositories indicates the safeguard is not effectively enforced. Boris Cherny, head of Claude Code, acknowledged the issue and said the team is working on mitigations, including auto-mode interception and basic secret scanning, but no timeline has been provided.
The incident highlights a deep tension between convenience and security in AI coding assistants. As tools like Claude Code rapidly gain adoption among developers, the interaction design of auto-approving commands may inadvertently become a new channel for credential leaks. The industry needs stricter default security measures, such as mandatory secret scanning, sensitive data redaction, and more reliable .gitignore enforcement, or similar risks will continue to grow with the widespread deployment of AI coding tools.
Hourly heat curve
46 fully observed hoursThe line compares only sources observed throughout; gap hours are interpolated to keep the trend continuous.
Coverage timeline
Total 2 reports · Latest first- Ars Technica AIT2·72 pts
- Hacker News AIT2·78 pts
- Claude Code's 'Don't Ask Again' option persists config-file secrets into saved commands, leaking 2,539 real credentials to public repos
- Leaked data includes database passwords, admin-level cloud keys, API tokens and SSH root logins across 63 organizations
- Anthropic plans auto-mode interception and built-in secret scanning as fixes, but no timeline was given