Blog · 보안
Claude Code: thousands of secrets exposed on GitHub by a settings file
Researchers found over 100,000 Claude Code settings files published on GitHub, about 1,100 of them holding secrets such as passwords or private keys. Here is where the problem comes from and how to avoid it.
2026년 11월 9일 · 4 분 분량 · 1 출처

Where the leak comes from
The problem stems from how Claude Code remembers approvals for automated commands. When you choose “Yes, and don’t ask again”, that choice is stored as a rule in the local .claude/settings.local.json file; the command is often written there as is, including any sensitive information it contains [1].
Why these files end up online
As long as the file stays on the computer the risk is limited, and Anthropic’s documentation says it is added to the developer’s global .gitignore [1]. But that setting is not reflected at the repository level: the file can be published by mistake if a repo is cloned to another machine or a folder later becomes a repo; according to Apiiro, Claude Code sometimes even commits the file without the user’s input [1].
The scale
Apiiro’s researchers found over 100,000 such files in public GitHub repositories [1]. About 1,100, from 63 organizations, held secrets such as API tokens, database passwords or private keys [1]. Even once removed from a repository, the secrets can persist in forks of the project [1].
The issue had been flagged in a Claude Code bug report as far back as August 2025 [1].
Good habits
The mechanism shows where to look: make sure .claude/settings.local.json is in each repository’s .gitignore, not only your global configuration, and review settings files before publishing [1]. If a secret was already published, removing it from the repository is not enough since it can live on in forks: treat it as compromised and replace it [1].
출처
- [1] Ars Technica · Claude Code is accidentally exposing secrets all over GitHub
인용한 출처를 바탕으로 작성한 기사입니다. 사실과 수치는 해당 매체에서 가져왔습니다.
SOL 무료로 써 보기무료 500 크레딧, 신용카드 불필요.