Imported from masood-mashu/git-sentinel (
skills/secret-remediation/SKILL.md). Install upstream withnpx skills add masood-mashu/git-sentinel --skill secret-remediation. Copyright stays with the author.
Secret Remediation Skill
Trigger Conditions
Run this skill when secret-detector finds a leaked credential or high-entropy secret.
Procedure
- Identify Secret Pattern: Classify whether the secret is AWS, OpenAI, GitHub, Stripe, or generic.
- Never Echo Secret: Redact the token value in the report.
- Map Environment Variable:
- OpenAI ->
OPENAI_API_KEY - AWS ->
AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY - GitHub ->
GITHUB_TOKEN - Stripe ->
STRIPE_SECRET_KEY
- OpenAI ->
- Generate Unified Patch: Use
patch-generatorto replace hardcoded strings with standard environment lookups (os.getenvorprocess.env). - Issue Revocation Advisory: Advise the repository owner to immediately revoke the exposed key in the provider dashboard.