Agent skill

Implementing Secrets Scanning In CI CD

by mukul975 in mukul975/Anthropic-Cybersecurity-Skills

Integrate gitleaks and trufflehog into CI/CD pipelines to detect leaked secrets before deployment

Apache-2.0Auto-check passedDevOps & Cloud

Install Implementing Secrets Scanning In CI CD

skills CLI
$ npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill implementing-secrets-scanning-in-ci-cd -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install mukul975/Anthropic-Cybersecurity-Skills implementing-secrets-scanning-in-ci-cd --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/mukul975/Anthropic-Cybersecurity-Skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/implementing-secrets-scanning-in-ci-cd .claude/skills/implementing-secrets-scanning-in-ci-cd && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
implementing-secrets-scanning-in-ci-cd
GitHub stars
34k
Token cost
~956 tokens
SKILL.md length
427 words
Files
4 (incl. scripts, references)
Skills in repo
644
Repo updated
First seen
Licence
Apache-2.0

At a glance

Integrate gitleaks and trufflehog into CI/CD pipelines to detect leaked secrets before deployment

  • Works in 8 steps: Install scanning tools: Install gitleaks… → Configure gitleaks: Create a… → Run gitleaks directory scan: Execute… → …
  • Tasks that involve Secrets management
  • SKILL.md covers Overview, When to Use, Prerequisites and Steps, plus 1 more section
  • Runs Python scripts from its folder; calls gitleaks and brew

What it does

Implementing Secrets Scanning In CI CD is an agent skill from mukul975/Anthropic-Cybersecurity-Skills. Integrate gitleaks and trufflehog into CI/CD pipelines to detect leaked secrets before deployment

Its SKILL.md is about 960 tokens, which your agent loads only when the skill is triggered. The skill folder holds 5 other files, including scripts and reference files (for example `references/api-reference.md` and `scripts/agent.py`).

It sits in DevOps & Cloud, covering Secrets management and CI/CD. The repository describes itself as: 817 structured cybersecurity skills for AI agents · Mapped to 6 frameworks: MITRE ATT&CK, NIST CSF 2.0, MITRE ATLAS, D3FEND, NIST AI RMF & MITRE F3 (Fight Fraud) · agentskills.io…. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Secrets management
  • Tasks that involve CI/CD

Example prompts

  • “/implementing-secrets-scanning-in-ci-cd”

Requirements

  • Python 3

Workflow steps

8 steps, taken from the first numbered list in SKILL.md.

  1. Install scanning tools: Install gitleaks via package manager or binary download. Install trufflehog via brew install trufflehog or…
  2. Configure gitleaks: Create a .gitleaks.toml configuration file in the repository root to define custom rules, allowlists, and path…
  3. Run gitleaks directory scan: Execute gitleaks dir --source . --report-format json --report-path gitleaks-report.json to scan the working…
  4. Run trufflehog filesystem scan: Execute trufflehog filesystem /path/to/repo --json > trufflehog-report.json to scan files and output JSON…
  5. Parse and filter findings: Use the agent script to parse both JSON reports, filter findings by severity (critical, high, medium, low), and…
  6. Integrate into CI pipeline: Add the scanning step to your GitHub Actions workflow, GitLab CI config, or Jenkins pipeline as a…
  7. Configure pre-commit hooks: Set up gitleaks as a pre-commit hook using gitleaks protect --staged to catch secrets before they are committed.
  8. Review and triage findings: Examine the JSON output for false positives, add legitimate entries to .gitleaksignore, and rotate any…

What it can do on your machine

Read from SKILL.md and the folder at commit 54a7988. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 1 file in scripts/ (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • gitleaks
    • brew

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Implementing Secrets Scanning In CI CD loads about 956 tokens when it runs, and up to ~1.7k if it reads all its reference files. Until then it costs about 34 tokens; SKILL.md has 427 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~34
When it runs · the whole SKILL.md, loaded when a task matches
~956
With references · SKILL.md plus every file in references/, read only if the agent opens them
~1.7k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from mukul975/Anthropic-Cybersecurity-Skills at commit 54a7988, republished under its Apache-2.0 licence (© mukul975). 427 words, ~956 tokens.

Download SKILL.mdSave it as .claude/skills/implementing-secrets-scanning-in-ci-cd/SKILL.md (or your agent's skills folder). This skill also uses 3 other files; get the full folder from GitHub.
name
implementing-secrets-scanning-in-ci-cd
description
Integrate gitleaks and trufflehog into CI/CD pipelines to detect leaked secrets before deployment
domain
cybersecurity
subdomain
devsecops
tags
secrets-scanning, gitleaks, trufflehog, ci-cd
version
1.0
author
mahipal
license
Apache-2.0
nist_csf
PR.PS-01, GV.SC-07, ID.IM-04, PR.PS-04
mitre_attack
T1195, T1554, T1059.004

Implementing Secrets Scanning in CI/CD

Overview

This skill covers implementing automated secrets scanning in CI/CD pipelines using gitleaks and trufflehog. It enables security teams to detect API keys, tokens, passwords, and other credentials that have been accidentally committed to source code repositories, providing a CI gate that blocks deployments containing high-severity findings.

Gitleaks scans git repositories and directories for hardcoded secrets using regex patterns and entropy analysis. TruffleHog performs filesystem and git history scans with optional secret verification against live services. Together they provide comprehensive coverage for secrets detection.

When to Use

  • When deploying or configuring implementing secrets scanning in ci cd capabilities in your environment
  • When establishing security controls aligned to compliance requirements
  • When building or improving security architecture for this domain
  • When conducting security assessments that require this implementation

Prerequisites

  • Python 3.9 or later
  • gitleaks v8.x installed and available on PATH
  • trufflehog v3.x installed and available on PATH
  • A git repository or directory to scan
  • Access to CI/CD platform (GitHub Actions, GitLab CI, Jenkins)

Steps

  1. Install scanning tools: Install gitleaks via package manager or binary download. Install trufflehog via brew install trufflehog or download from GitHub releases.

  2. Configure gitleaks: Create a .gitleaks.toml configuration file in the repository root to define custom rules, allowlists, and path exclusions. Use --config flag to point to custom configs.

  3. Run gitleaks directory scan: Execute gitleaks dir --source . --report-format json --report-path gitleaks-report.json to scan the working directory and generate a JSON report.

  4. Run trufflehog filesystem scan: Execute trufflehog filesystem /path/to/repo --json > trufflehog-report.json to scan files and output JSON findings to a report file.

  5. Parse and filter findings: Use the agent script to parse both JSON reports, filter findings by severity (critical, high, medium, low), and determine whether the CI pipeline should pass or fail.

  6. Integrate into CI pipeline: Add the scanning step to your GitHub Actions workflow, GitLab CI config, or Jenkins pipeline as a pre-deployment gate. Use --exit-code flag in gitleaks to control pipeline behavior.

  7. Configure pre-commit hooks: Set up gitleaks as a pre-commit hook using gitleaks protect --staged to catch secrets before they are committed.

  8. Review and triage findings: Examine the JSON output for false positives, add legitimate entries to .gitleaksignore, and rotate any confirmed leaked credentials immediately.

Show full SKILL.md (53 more words)Show less

Expected Output

The agent script produces a JSON report containing:

  • Total findings count from each scanner
  • Findings grouped by severity level
  • Individual finding details including file path, line number, rule ID, and redacted secret
  • A CI gate verdict (pass/fail) based on the configured severity threshold
  • Execution metadata including scan duration and tool versions
json
{
  "scan_summary": {
    "tool": "both",
    "total_findings": 3,
    "critical": 1,
    "high": 1,
    "medium": 1,
    "low": 0,
    "ci_gate": "FAIL",
    "fail_reason": "Found 1 critical and 1 high severity findings"
  },
  "findings": [...]
}

© mukul975, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 3 other files (scripts, references) in skills/implementing-secrets-scanning-in-ci-cd of mukul975/Anthropic-Cybersecurity-Skills.

  • SKILL.md
  • LICENSE
  • references/api-reference.md
  • scripts/agent.py

Open the folder on GitHubat commit 54a7988

Compare with similar skills

Implementing Secrets Scanning In CI CD next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Implementing Secrets Scanning In CI CD compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Implementing Secrets Scanning In CI CD this skillmukul975/Anthropic-Cybersecurity-Skills34k—~956Automated safety check: PassApache-2.0
Azure Bicep Skilltimothywarner-org/claude-code224—~2.9kAutomated safety check: PassMIT
Secrets GitleaksAgentSecOps/SecOpsAgentKit2202 repos~4.1kAutomated safety check: PassCustom licence
Secure GitHub Actionsvechain/x-app-template450—~1.2kAutomated safety check: PassMIT
Env Managerbobmatnyc/claude-mpm156—~2kAutomated safety check: NotesMIT
KubeSphere DevOps Credentialskubesphere/kubesphere17k—~4.2kAutomated safety check: PassCustom licence

Similar skills

  • Azure Bicep Skill

    timothywarner-org/claude-code

    A skill your agent uses when authoring, reviewing, or refactoring Azure Bicep code.

    224 GitHub stars~2.9k tokensUpdated 2 mo ago
    DevOps & CloudAuto-check passed
  • Secrets Gitleaks

    AgentSecOps/SecOpsAgentKit

    Hardcoded secret detection and prevention in git repositories and codebases using Gitleaks.

    220 GitHub starsUsed in 2 repos~4.1k tokens
    DevOps & CloudAuto-check passed
  • Secure GitHub Actions

    vechain/x-app-template

    Secure GitHub Actions workflows against supply-chain, privilege, and shell-injection risks.

    450 GitHub stars~1.2k tokensUpdated 2 mo ago
    DevOps & CloudAuto-check passed
  • Env Manager

    bobmatnyc/claude-mpm

    Environment variable validation, synchronization, and management across local development, CI/CD, and deployment platforms

    156 GitHub stars~2k tokensUpdated 1 mo ago
    DevOps & CloudAuto-check: notes
  • KubeSphere DevOps Credentials

    kubesphere/kubesphere

    Covers creating and managing KubeSphere DevOps credentials as typed Kubernetes Secrets that sync to Jenkins, including the API endpoints and a common pitfall.

    17k GitHub stars~4.2k tokensUpdated 2 mo ago
    DevOps & CloudAuto-check passed
  • Secrets Management

    davila7/claude-code-templates

    Secure secrets management practices for CI/CD pipelines using Vault, AWS Secrets Manager, and other tools.

    33k GitHub starsUsed in 12 repos~2k tokens
    DevOps & CloudAuto-check passed

More from mukul975/Anthropic-Cybersecurity-Skills

All 644 skills in this repo
  • Campaign Attribution Evidence Analysis

    mukul975/Anthropic-Cybersecurity-Skills

    Weighs infrastructure, TTP, malware code and timing evidence with the Diamond Model and competing hypotheses to reach a confidence-rated attribution.

    34k GitHub stars~2.3k tokensUpdated 1 mo ago
    Auto-check passed
  • Go Malware Analysis in Ghidra

    mukul975/Anthropic-Cybersecurity-Skills

    Walks through reverse engineering Go-compiled malware in Ghidra: parsing buildinfo and pclntab, recovering stripped function names and extracting dependencies.

    34k GitHub stars~2.8k tokensUpdated 1 mo ago
    Auto-check passed
  • LNK and Jump List Forensics

    mukul975/Anthropic-Cybersecurity-Skills

    Guides forensic analysis of Windows LNK shortcut files and Jump Lists with LECmd, JLECmd and manual parsing to show file access and program execution.

    34k GitHub stars~2.8k tokensUpdated 1 mo ago
    Auto-check passed
  • Malware Persistence Analysis with Autoruns

    mukul975/Anthropic-Cybersecurity-Skills

    Hunts Windows malware persistence with Sysinternals Autoruns, covering run keys, services, scheduled tasks and drivers, with baseline comparison.

    34k GitHub stars~1.2k tokensUpdated 1 mo ago
    Auto-check passed
  • NTFS MFT Deleted File Recovery

    mukul975/Anthropic-Cybersecurity-Skills

    Guides a Windows forensic examination of the NTFS Master File Table to recover deleted-file evidence, build timelines and spot timestomping.

    34k GitHub stars~2.7k tokensUpdated 1 mo ago
    Auto-check passed
  • Network Covert Channel Analysis

    mukul975/Anthropic-Cybersecurity-Skills

    Detects DNS tunneling, ICMP exfiltration and HTTP-based covert channels in packet captures and DNS logs when hunting for hidden command-and-control traffic.

    34k GitHub stars~2k tokensUpdated 1 mo ago
    Auto-check passed

Categories

Questions about Implementing Secrets Scanning In CI CD

What does Implementing Secrets Scanning In CI CD do?

Integrate gitleaks and trufflehog into CI/CD pipelines to detect leaked secrets before deployment. Implementing Secrets Scanning In CI CD is an agent skill from mukul975/Anthropic-Cybersecurity-Skills.

When should I use Implementing Secrets Scanning In CI CD?

Implementing Secrets Scanning In CI CD fits situations like: tasks that involve Secrets management; tasks that involve CI/CD.

How do I install Implementing Secrets Scanning In CI CD in Claude Code?

Run `npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill implementing-secrets-scanning-in-ci-cd -a claude-code`. Or copy the skill folder (skills/implementing-secrets-scanning-in-ci-cd in mukul975/Anthropic-Cybersecurity-Skills) into .claude/skills/implementing-secrets-scanning-in-ci-cd in your project. Claude Code loads it when a task matches its description.

How do I install Implementing Secrets Scanning In CI CD in Codex?

Run `npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill implementing-secrets-scanning-in-ci-cd -a codex`. Or copy the skill folder (skills/implementing-secrets-scanning-in-ci-cd in mukul975/Anthropic-Cybersecurity-Skills) into .agents/skills/implementing-secrets-scanning-in-ci-cd in your project. Codex loads it when a task matches its description.

Can I use Implementing Secrets Scanning In CI CD in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill implementing-secrets-scanning-in-ci-cd -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/implementing-secrets-scanning-in-ci-cd, .gemini/skills/implementing-secrets-scanning-in-ci-cd, .github/skills/implementing-secrets-scanning-in-ci-cd and .opencode/skills/implementing-secrets-scanning-in-ci-cd in your project.

What does Implementing Secrets Scanning In CI CD need to run?

Going by SKILL.md and its folder, Implementing Secrets Scanning In CI CD needs Python for the scripts in its folder and the command-line tools its instructions call (gitleaks and brew). Our summary lists: Python 3.

Does Implementing Secrets Scanning In CI CD access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Implementing Secrets Scanning In CI CD safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Implementing Secrets Scanning In CI CD use?

Implementing Secrets Scanning In CI CD is published under the Apache-2.0 licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Implementing Secrets Scanning In CI CD use?

About 956 tokens (SKILL.md is roughly 3.8k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 759 tokens, read only when the agent opens those files.

What are the alternatives to Implementing Secrets Scanning In CI CD?

Skills that share tags, products or a category with Implementing Secrets Scanning In CI CD: Azure Bicep Skill (timothywarner-org/claude-code, 224 stars), Secrets Gitleaks (AgentSecOps/SecOpsAgentKit, 220 stars), Secure GitHub Actions (vechain/x-app-template, 450 stars) and Env Manager (bobmatnyc/claude-mpm, 156 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Implementing Secrets Scanning In CI CD?

mukul975 (a GitHub user) maintains it in mukul975/Anthropic-Cybersecurity-Skills, which has 34,116 GitHub stars. The repository holds 644 skills in this directory. The repository was last updated on August 31, 2026.

Source: mukul975/Anthropic-Cybersecurity-Skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.