
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
secretshield
Advanced tools
π‘οΈ SecretShield is a CLI tool that detects API keys and sensitive credentials before you commit code.
Secure your commits before they go public!
SecretShield is a powerful, blazing-fast CLI tool to scan your codebase for hardcoded secrets like API keys, tokens, database passwords, and more. Avoid accidental leaks and secure your development workflow in seconds.
You can install SecretShield globally or use it with npx.
npx secret-shield
npm install -g secret-shield
npm install --save-dev secret-shield
Once installed, simply run:
npx secret-shield
Or, if installed globally:
secretshield
This will scan your staged files (those added via git add) for any potential secrets.
β
SecretShield CLI is working!
π SecretShield scanning staged files...
π Files to scan: [ './.env', './app.js' ]
π¨ Possible secret found in ./app.js at line 12
π Matched Line: API_KEY="sk_live_1234567890abcdef"
β Commit blocked. Secrets detected!
SecretShield currently detects over 127 patterns across multiple categories:
π§ You can also customize the regex for your org in future versions!
Add this to your pre-commit hook:
#!/bin/sh
npx secret-shield
if [ $? -ne 0 ]; then
echo "β SecretShield blocked your commit!"
exit 1
fi
Or use tools like husky to integrate it smoothly into your dev workflow.
If you discover a vulnerability or a false negative, please do not report it publicly. Instead, reach out securely: π§ support@decodedev.in
If you need to ignore a specific line that contains a secret (for example, if it's a test value or a public key), you can add a special comment to that line. SecretShield will skip any line that contains this comment.
const API_KEY = "test-key-123"; // secretshield: safe to push
const DB_PASSWORD = "test-pass-456"; /* secretshield: safe to push */
const SECRET_TOKEN = "test-token-789"; /*secretshield: safe to push */
const AUTH_KEY = "test-auth-012"; //secretshield: safe to push
β οΈ Important: Use this feature carefully and only for legitimate cases where the secret is safe to commit (like test values, public keys, or intentionally public tokens).
Arunq Singh Pundir GitHub β @Arunsinghpundir
Licensed under the MIT License
If you find SecretShield useful:
βThe best time to protect secrets was yesterday. The second best time is now.β π
FAQs
π‘οΈ SecretShield is a CLI tool that detects API keys and sensitive credentials before you commit code.
We found that secretshield demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.Β It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.