Claude Code approval option can save secrets to settings files that leak to public GitHub repositories
VULNERABILITYApiiroredteam/daily · 2 sources
- Severity
- High
- Sources
- 2
What happened
When a developer clicks a "Yes, and don't ask again" option in the Claude Code tool, the approved command can be saved to a project file, including any passwords or keys it contains. If that file is uploaded to a public GitHub project, the secrets become visible to anyone. Apiiro found 2,539 distinct secrets across 1,994 public repositories.
Like I’m new · Written by AI from 2 sources · Wrong?
What to do
- Rotate any credentials found in Claude Code settings files before removing them from repositories.
- Run git rm --cached .claude/settings.local.json and add the path to .gitignore.
- Search current files and Git history for .claude/settings.local.json and review shared .claude/settings.json allow rules for passwords or tokens.
- Use secret-manager references rather than literal passwords in commands.
Written by AI from the sources, checked against them
Full story timeline · 2 updates
Who reported · 2 outlets
The Hacker NewsCyber Security News
Who and what is in it
Malware
Companies
Products