Plumber detects CI/CD security issues in your GitHub workflows and gives you a score
Plumber detects CI/CD security issues in your GitHub workflows and gives you a score
CI/CD security scanner for GitLab CI and GitHub Actions
One CLI, one .plumber.yaml, one Rego policy engine.
Website • Docs • Discord • Issues
Plumber scans CI/CD pipelines for risky patterns and security gaps.
.gitlab-ci.yml, resolved includes, and repository settings..github/workflows/*.{yml,yaml} locally or through the GitHub API..plumber.yaml contains provider-specific policy sections for GitLab and GitHub.Plumber reports findings in the terminal, JSON, SARIF, GitLab SAST, CSV, OCSF, PBOM, and CycloneDX formats.
Run your first scan before reading the full docs.
brew tap getplumber/plumber
brew install plumber
plumber config generate # generate the default configuration file
plumber analyzeSee the generated default config in this repo: defaultConfig/.plumber.yaml.
Plumber auto-detects the provider from your git remote. Use explicit flags when scanning a repo that is not the current checkout.
| I want to... | Use this | Start here |
|---|---|---|
| Try Plumber locally | CLI | plumber analyze |
| Add checks to GitLab CI | GitLab CI Component | GitLab CI Component |
| Add checks to GitHub Actions | GitHub Action | GitHub Action |
| Audit many repos from a script | CLI + JSON/SARIF | Outputs |
| Tune policy rules | .plumber.yaml |
Configuration |
brew tap getplumber/plumber
brew install plumberOther options:
mise use -g github:getplumber/plumbergetplumber/plumberFull install docs:
GitLab:
export GITLAB_TOKEN=glpat_xxxxGitHub (preferred, uses the gh CLI's keyring):
gh auth loginAlternative (CI runners, automation):
export GH_TOKEN=ghp_xxxxLocal GitHub scans can run without a token for workflow-content checks. A token enables repo-level and action-metadata checks.
If a workflow uses an action hosted in an org with an IP allow list (which blocks the runner's GITHUB_TOKEN), set PLUMBER_METADATA_TOKEN to a token with public-repository read so Plumber can still resolve that action's version for the known-CVE check. Without it, Plumber falls back to an anonymous read and, if that is rate-limited too, skips the version check rather than guessing.
Current repo:
plumber analyzeSpecific GitLab project:
plumber analyze \
--provider gitlab \
--gitlab-url https://gitlab.com \
--project group/projectSpecific GitHub repo without a local clone:
plumber analyze \
--provider github \
--github-url github.com \
--project owner/repo.github/workflows/plumber.yml:name: Plumber
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
security-events: write
# id-token: write # uncomment to enable score-push below
jobs:
plumber:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v6
- uses: getplumber/plumber@
with:
# Set to `true` to publish an official Plumber score badge
# (it makes your score and repo name public, see Score Push section below)
score-push: falseTo resolve action versions hosted in an org with an IP allow list, pass a public-repo-read token via the
metadata-tokeninput (kept in a secret):with: metadata-token: ${{ secrets.PLUMBER_METADATA_TOKEN }}
Full guide: getplumber.io/docs/cli/github#run-with-github-actions
.gitlab-ci.yml:include:
- component: gitlab.com/getplumber/plumber/plumber@
inputs:
# Set to `true` to publish an official Plumber score badge
# (it makes your score and repo name public, see Score Push section below)
score_push: falseGITLAB_TOKEN in Settings -> CI/CD -> Variables.
Use read_api + read_repository for scanning, or api if you want Plumber to post MR comments or badges.Full guide: getplumber.io/docs/cli/gitlab#run-with-the-gitlab-ci-component
Enabling score push publishes a self-updating A–E badge to the hosted score
service. It's the only way to get an official Plumber score. It's only
available in CI, not when running the CLI locally.
Display it with a badge in your README (swap in your platform/owner/repo):
⚠️ Opt-in and off by default. Enabling it makes your score and repository name public. Only the default branch's score is displayed. See score docs.
analyze flags| Flag | Purpose |
|---|---|
--score-endpoint |
Score service base URL (default https://score.getplumber.io). Override only for a self-hosted score service. |
--platform |
Plumber platform base URL. Setting it turns on platform mode (see below) and pushes this run's full results there over CI OIDC, taking precedence over --score-push. Requires an id-token grant: permissions: id-token: write on GitHub, the component's id_tokens: block on GitLab. |
Without --platform nothing changes: Plumber collects everything itself and
evaluates one policy, exactly as it always has.
A plain-http --platform URL is refused unless its host is loopback
(localhost, 127.0.0.0/8, ::1): the push carries the CI OIDC id-token
and the response carries the run's own verdict, and either can be read or
rewritten by anyone on the network path between the job and a plain-http
endpoint. Pass --platform-allow-http (or PLUMBER_ANALYZE_PLATFORM_ALLOW_HTTP=1)
to opt in for a trusted internal instance that has no TLS in front of it;
https:// and loopback http:// need no opt-in.
With --platform, Plumber first reads the project's context from the
platform - the resolved policy set and a cached settings snapshot - and uses
it to decide what to collect and what to report:
.plumber.yaml (or the built-in default) is not evaluated at all: if
one is present the log says it was ignored. The job log prints one section
per policy (its controls, findings and score), then a Platform verdict
block with the platform's decision per policy, the platform's global score
and the exit code.
The local file decides nothing on a linked run, collection included: what
Plumber fetches is the union of the resolved policies' own configurations,
collected once, so a control any policy enables has its data collected
even when the local file switches that control off. --controls and
--skip-controls are ignored the same way (one notice each): the
platform's policy configuration is the only way to exclude a control from
a linked run.--min-points, --min-score and
the deprecated --threshold are ignored in platform mode (one notice each):
each policy's own enforcement and min_points, as configured on the
platform, decide whether the job fails. A degraded collection is pushed and
gated by the platform, never failed locally.include:
directives needs an API a CI job token cannot reach, so platform mode reads
the resolved configuration from the platform instead of asking the git host
itself.GIT_STRATEGY: none, a sparse checkout, a ci_config_path in another
project), the snapshot's copy of the project's own un-merged CI file
stands in for the one that could not be read, so
pipelineMustNotOverrideJobVariables still reports instead of abstaining.
That copy is the file the platform collected when it built the snapshot,
so it is used only when the run is analysing that same commit; at any
other commit, and on a copy the platform flags as incomplete, the control
reports not_evaluable rather than compare two different revisions.CI_* variables, its checkout, and its
environment. Set --platform and Plumber runs without a GITLAB_TOKEN,
as it has since v0.4.50.
A few checks still read the projects your pipeline includes from, and
without a token those report not_evaluable rather than passing.not_evaluable, never a
pass. If the platform cannot resolve a configuration, or reports a
settings collection as failed, the controls that read it say so instead of
reporting a clean result over data nobody collected. A lane the platform
vouches for as genuinely empty is still a real verdict a control may fail
on. A run prints which configuration it used and why, with no --verbose
needed. A control whose data lane was not collected at all reports
`not_evaluablNo open issues yet, or sync has not completed.