- Home
- Skills
- DevOps & Cloud
- Docker and GitHub Actions Hardening Audit
Docker and GitHub Actions Hardening Audit
Audit and fix supply-chain flaws, root containers, and GitHub Actions privilege escalations.
$9
Works with the AI Agents you already use
Docker and GitHub Actions Hardening Audit
Example session with this skill installed
Audit my Dockerfile and GitHub workflows for security flaws and suggest fixes.
- Read your context and instructions
- Compiled the docker and github
I have audited your repository for CI and Docker hardening flaws. The scan identified 3 High-severity issues and 1 Medium-severity issue.
Security Audit Report
| File | Severity | Rule ID | Finding | Proposed Fix |
|---|---|---|---|---|
Dockerfile | High | D1 | Base image node:20 is unpinned. | FROM node:20-slim@sha256:d32f... |
Dockerfile | High | D2 | No USER defined (runs as root). | Add RUN useradd -u 1001 app && USER app |
.github/workflows/deploy.yml | High | W1 | actions/checkout@v4 is not pinned to SHA. | actions/checkout@b4ff... # v4 |
.github/workflows/deploy.yml | Medium | W3 | Missing permissions block (defaults to wide). | Add permissions: contents: read |
Proposed Changes for Dockerfile
# Before
FROM node:20
WORKDIR /app
COPY . .
RUN npm install
CMD ["node", "index.js"]
# After
FROM node:20-slim@sha256:d32f62e47a6b22f6d773468d6f5f3e9b5f5f5f5f5f5f5f5f5f5f5f5f5f5f5f5f
WORKDIR /app
COPY . .
RUN npm install
RUN useradd -m appuser
USER appuser
CMD ["node", "index.js"]
Proposed Changes for deploy.yml
# Add to top of file
permissions:
contents: read
# Update step
- name: Checkout
uses: actions/checkout@b4ffaa5b94d3b9639121b589b2787dd7653a76af # v4
Next steps
- Approve these changes to apply the fixes to your files.
- I will rerun
scripts/audit.pyto confirm all issues are resolved. - Commit the changes to your security-hardening branch.
Connects securely to your tools. The creator never sees your data.
About this skill
Supply chain attacks and privilege escalation in CI/CD pipelines often go unnoticed until a breach occurs. This skill audits Dockerfiles and GitHub Actions workflows to identify and remediate security flaws like unpinned dependencies and root-run containers.
What it does
- Supply chain auditing finds unpinned Docker images and GitHub Actions that should use commit SHAs.
- Privilege analysis detects root-user execution in containers and overly broad
write-allpermissions in workflows. - Injection prevention identifies dangerous
curl | shpatterns and unsafe use of GitHub event context in shell scripts. - Secret hygiene flags sensitive data leaked in
ENVorARGinstructions. - Automated remediation proposes and applies precise fixes for identified vulnerabilities upon approval.
How it works
- Scan the repository using a dedicated audit script to map all Dockerfiles and YAML workflows.
- Triaging findings by severity (High, Medium, Low) while filtering out false positives in comments.
- Drafting exact replacement lines for every confirmed flaw based on a standardized fix table.
- Execution of file edits only after user confirmation, followed by a post-remediation scan to verify the delta.
Frameworks & tools
This skill uses Python for scanning logic and targets Docker, GitHub Actions, and POSIX shell scripts within CI environments.
Why this beats prompting it yourself
Generic prompts often miss subtle risks like pull_request_target abuse or fail to provide the actual commit SHAs needed for true pinning. This skill follows a specific security rulebook and verifies its work with a secondary scan.
Use cases
- Audit a new repository before its first production deployment.
- Harden legacy CI pipelines against supply chain attacks.
- Enforce non-root container standards across a microservices mono-repo.
- Secure GitHub Actions permissions to follow the principle of least privilege.
Known limitations
Requires an internet connection to look up valid commit SHAs for pinning. It cannot verify the safety of self-hosted runners beyond checking their configuration in public repos.
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for DevOps & Cloud.
Requires internet to fetch real commit SHAs. Cannot guarantee total pipeline safety, only checks against the defined rule set. Requires Python to run the audit script.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed today