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.
| Tool | Category | What makes it fail on findings |
|---|---|---|
| Trivy | Dependencies, secrets, IaC | --exit-code 1 (or TRIVY_EXIT_CODE); trivy-action's exit-code input defaults to 0 too |
| Grype | Dependencies | --fail-on <severity> (or -f, GRYPE_FAIL_ON_SEVERITY, or fail-on-severity in .grype.yaml) |
| TruffleHog | Secrets | --fail |
| Semgrep, Opengrep | Code scanning | semgrep ci, or --error with semgrep scan |
| GuardDog | Malicious packages | --exit-non-zero-on-finding |
| Kubescape | Kubernetes manifests | --severity-threshold, or a --compliance-threshold above 0 |
| Polaris | Kubernetes manifests | --set-exit-code-on-danger or --set-exit-code-below-score |
| Sobelow | Code scanning (Phoenix) | --exit |
| Flawfinder | Code scanning (C/C++) | --error-level |
| license-checker | Licences | --failOn or --onlyAllow; without them it only lists licences |
| pinact | Workflow security | --check, --diff or --fix=false; pinact run rewrites the files by default |
Scanners that fail by default, and the switch that stops them
| Tool | Category | What turns failing off |
|---|---|---|
| Gitleaks | Secrets | --exit-code 0 |
| Checkov, tfsec | IaC | --soft-fail, or soft_fail: true on their actions |
| govulncheck | Dependencies (Go) | -json or -format json|sarif|openvex, which report and exit 0 |
| zizmor | Workflow security | --format sarif or --no-exit-codes; zizmor-action uploads SARIF and passes unless advanced-security: false |
| anchore/scan-action | Dependencies | fail-build: false |
| OSV-Scanner action | Dependencies | fail-on-vuln: false |
| Dependency Review | Dependencies | warn-only: true |
| Safety | Dependencies (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.
Check your pipeline
Scan a repository in your browserzanadir 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.