Does your security scanner fail the build?

Often it doesn't. Trivy, Grype, TruffleHog, Semgrep's scan command and several other scanners report findings and still exit 0 unless you pass a fail flag. Others fail by default but are commonly switched off with a soft-fail option. zanadir, an open-source CI/CD security tool, reads your pipeline and grades each scanner it finds as enforcing (can fail a merge) or advisory (cannot), so you can see which ones would really stop a bad change.

Scanners that pass by default

These exit 0 on findings unless the flag in the last column is set.

ToolCategoryWhat makes it fail on findings
TrivyDependencies, secrets, IaC--exit-code 1 (or TRIVY_EXIT_CODE); trivy-action's exit-code input defaults to 0 too
GrypeDependencies--fail-on <severity> (or -f, GRYPE_FAIL_ON_SEVERITY, or fail-on-severity in .grype.yaml)
TruffleHogSecrets--fail
Semgrep, OpengrepCode scanningsemgrep ci, or --error with semgrep scan
GuardDogMalicious packages--exit-non-zero-on-finding
KubescapeKubernetes manifests--severity-threshold, or a --compliance-threshold above 0
PolarisKubernetes manifests--set-exit-code-on-danger or --set-exit-code-below-score
SobelowCode scanning (Phoenix)--exit
FlawfinderCode scanning (C/C++)--error-level
license-checkerLicences--failOn or --onlyAllow; without them it only lists licences
pinactWorkflow security--check, --diff or --fix=false; pinact run rewrites the files by default

Scanners that fail by default, and the switch that stops them

ToolCategoryWhat turns failing off
GitleaksSecrets--exit-code 0
Checkov, tfsecIaC--soft-fail, or soft_fail: true on their actions
govulncheckDependencies (Go)-json or -format json|sarif|openvex, which report and exit 0
zizmorWorkflow security--format sarif or --no-exit-codes; zizmor-action uploads SARIF and passes unless advanced-security: false
anchore/scan-actionDependenciesfail-build: false
OSV-Scanner actionDependenciesfail-on-vuln: false
Dependency ReviewDependencieswarn-only: true
SafetyDependencies (Python)--continue-on-error

Any scanner, any CI

Whatever the tool, the step cannot fail a build when it has continue-on-error: true (GitHub Actions), allow_failure: true (GitLab CI) or || true after the command. And a scanner that only runs on pushes to the main branch fails after the change is already merged. zanadir checks for these, and follows the command into Makefiles, scripts, package.json scripts and reusable workflows.

enforcingcan fail a merge
partialruns, but not on every change
advisorycannot fail a build
unknownbehind a condition the file cannot settle

Check your pipeline

Scan a repository in your browser
zanadir scan --dir .

Each row above comes from zanadir's rule catalogue, which records every tool's exit behaviour with a link to its documentation or source. See also State of CI security 2026: 1 in 6 of the most-starred repositories that run a scanner in CI have one that cannot fail the build.