secrets-management
Skill4 starsChanged 4 months agoMITView on GitHub
Handles credentials safely through their whole life — where they live, how code gets them, how they rotate, and what to do when one leaks. Use this whenever the user is adding an API key, database password, token, or certificate, mentions a secrets manager or vault, asks how to store credentials, or has committed a secret to git. For finding exposed secrets during a code review, use security-analysis.
- Reads credentials
26 other projects use a version of this.
Adopted by
Most recently taken up by
- nahid-sparktales/agent-dispatchertheir own version, first seen Sep 21, 2026
- sammasak/claude-code-skillstheir own version, first seen Sep 14, 2026
- socialadsmentor/sam-agentic-harnesstheir own version, first seen Sep 3, 2026
- TheHiddenDeveloper/jarvis-skillstheir own version, first seen Aug 19, 2026
- Zephyrex21/claude-skills-vettedtheir own version, first seen Aug 9, 2026
- vanara-agents/skillstheir own version, first seen Jul 14, 2026
Used with
Projects with it also use secure-code-review, api-security and 2 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
Robotti-ioSkillsecure-code-review
Repeatable process for an application security code review that produces prioritized findings and fix guidance.
Also in 3 projects that use this
jefflesterSkillapi-security
API security best practices and common vulnerability prevention. Enforces security checks for authentication, input validation, SQL injection, XSS, and OWASP Top 10 vulnerabilities. Use when building or modifying APIs.
Also in 3 projects that use this
ElasticSkillaccessibility
Accessibility guidance for Kibana. Use this skill when working with or reviewing EUI components, resolving a11y-related (@elastic/eui) ESLint issues, and ensuring proper use of ARIA attributes, focus management, keyboard interactions, and accessible naming conventions.
Also in 4 projects that use this
Svenja-devSkille2e-testing
Also in 3 projects that use this
Other versions26 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 26
- UnitOneAI/SecuritySkills★ 78same name
- nahid-sparktales/agent-dispatcher★ 59same name
- Hack23/European-Parliament-MCP-Server★ 28same name
- nimadorostkar/Claude-Skills-collection★ 28same name
- Fandry96/k3-agentic-skills★ 27same name
- acedergren/oci-agent-skills★ 21same name
- Sir-chawakorn/sanook-cli★ 9same name
- vanara-agents/skills★ 9same name
- xfstudio/skills★ 9same name
- YepAPI/skills★ 8same name
16 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository61 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- agent-deploymentSkill
- agent-designSkill
- agent-evaluationSkill
- agent-hardeningSkill
- agent-implementationSkill
- agent-observabilitySkill
- agent-scopingSkill
- api-designSkill
- code-templatingSkill
- dependency-upgradeSkill
- error-handlingSkill
- feature-implementationSkill
- project-scaffoldingSkill
- refactoringSkill
- data-analysisSkill
- data-migrationSkill
- data-modelingSkill
- sql-queriesSkill
- ci-pipelinesSkill
- containerizationSkill
- deployment-strategiesSkill
- infrastructure-as-codeSkill
- debuggingSkill
- issue-investigationSkill
- issue-triageSkill
- log-analysisSkill
- network-troubleshootingSkill
- performance-profilingSkill
- api-documentationSkill
- commit-messagesSkill
- diagrammingSkill
- markdown-docsSkill
- plain-languageSkill
- pr-descriptionsSkill
- release-notesSkill
- browser-testingSkill
- integration-testingSkill
- load-testingSkill
- test-dataSkill
- test-driven-developmentSkill
- unit-testingSkill
- deep-researchSkill
- feed-digestSkill
- summarizationSkill
- accessibility-reviewSkill
- code-analysisSkill
- code-lintingSkill
- code-reviewSkill
- auth-designSkill
- dependency-auditSkill
- security-analysisSkill
- threat-modelingSkill
- capacity-planningSkill
- disaster-recoverySkill
- incident-responseSkill
- monitoring-setupSkill
- root-cause-analysisSkill
- runbooksSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
5 rules. 0 are common, 2 are distinctive, and 3 are very specific to this project.
0
Common
Most of the 25 edited versions we read keep these.
2
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 31
Done when: every static credential has been checked for a workload-identity alternative.
- Very specific: line 35
Not in code, config, or a committed
.env: Commit a .env.example with empty values - Very specific: line 43
Run a scanner in CI and as a pre-commit hook — gitleaks, trufflehog, or the platform's own.
- Very specific: line 98
Prefer a mounted file or a direct API call over an environment variable.
- Distinctive: line 100
Do not write secrets to disk unencrypted, including temp files
“Common” is measured: kept by at least 6 in 10 of the 25 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Secrets management
A secret's danger is proportional to how many places it exists and how long it lives. Most practice focuses on the first storage decision and ignores rotation and revocation, which is where the real exposure sits — a key nobody has rotated in four years has been on more laptops than anyone can name.
Assume every secret will eventually leak. Design so that when it does, the blast radius is small and the fix is one command.
1. Prefer not having a secret at all
The best credential is one that does not exist. In order of preference:
- Workload identity, the platform vouches for the service. IAM roles, service accounts, OIDC federation. Nothing to store, nothing to rotate, nothing to leak
- Short-lived credentials issued on demand, expiring in minutes or hours
- A long-lived secret in a manager, injected at runtime
- A long-lived secret in an environment variable — workable, and the floor
- A secret in a file in the repo, never
Most cloud-to-cloud authentication can use option 1 today, and teams keep using static keys out of habit. That is the single biggest available improvement.
Done when: every static credential has been checked for a workload-identity alternative.
2. Never let a secret near the repository
- Not in code, config, or a committed
.env. Commit a.env.examplewith empty values - Not in a Dockerfile
ARGorENV. Layers are permanent and readable withdocker history, even if a later layer deletes it - Not in CI config, only in the platform's secret store
- Not in a log line, error message, URL, or trace. Redact at the logging boundary, not at each call site, or one new code path leaks everything
- Not in a ticket, chat message, or screenshot. These are searched and archived
Run a scanner in CI and as a pre-commit hook — gitleaks, trufflehog, or the platform's own.
It is cheap and it catches the mistake before it becomes permanent.
Done when: a scanner runs on every commit and the history is clean.
3. Scope every credential narrowly
The permissions a secret carries determine what a leak costs.
- One credential per service, never shared. A shared key cannot be revoked without an outage for everyone, so it never gets revoked
- Least privilege, and check it. Most credentials carry far more than they use
- Separate per environment. Staging must never hold a production credential
- Read-only where reads are all that is needed
- Constrain by source: IP, network, or workload — where the provider supports it
Done when: a leaked credential would grant only what that one service actually needs.
4. Make rotation routine, not an event
Rotation that requires downtime never happens, so design for overlap:
- Issue the new credential
- Deploy config accepting both old and new
- Switch to the new one
- Confirm the old one is unused — via access logs, not assumption
- Revoke the old one
Step 4 is the one people skip, and revoking a still-used credential is how a routine rotation becomes an outage.
Rotate on a schedule, and automate it. A documented manual procedure decays into a documented procedure nobody runs.
Done when: rotation has been performed once without downtime.
5. Know what to do when one leaks
Written in advance, because the instinct is wrong. Order matters:
- Revoke first. Not "assess the impact first" — revoke. The credential is compromised the moment it is exposed, and every minute is exposure
- Then rotate and deploy the replacement
- Then investigate — access logs for the exposure window, looking for use you cannot account for
- Then clean up the exposure
Removing a secret from git history does not un-leak it. It was cloned, cached, and possibly indexed. Rewriting history is housekeeping, not remediation. The only real fix is revocation.
Done when: the old credential is dead and you know whether it was used.
6. Inject at runtime, hold in memory
- Fetch from the secret manager at startup or on demand — do not bake into images or artifacts
- Prefer a mounted file or a direct API call over an environment variable. Environment variables
leak into crash dumps, child processes, and
/proc - Do not write secrets to disk unencrypted, including temp files
- Cache in memory with a TTL so rotation takes effect without a restart
Done when: the same artifact runs in every environment with no secret in it.
Report
State where each secret lives, what it can do, how it is injected, when it was last rotated, and who can read it. That last question is frequently the surprising one — a secret manager with overly broad read access is a shared password with extra steps.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

