Published on: March 25, 2026
6 min read
Learn how to cut through scanner noise and focus on the vulnerabilities that matter most with GitLab security, including use cases and templates.

Security scanners are essential, but not every finding requires action. Test code, vendored dependencies, generated files, and known false positives create noise that buries the vulnerabilities that actually matter. Security teams waste hours manually dismissing the same irrelevant findings across projects and pipelines. They experience slower triage, alert fatigue, and developer friction that undermines adoption of security scanning itself.
GitLab's auto-dismiss vulnerability policies let you codify your triage decisions once and apply them automatically on every default-branch pipeline. Define criteria based on file path, directory, or vulnerability identifier (CVE, CWE), choose a dismissal reason, and let GitLab handle the rest.
Auto-dismiss vulnerability policies enable security teams to:
Each example below includes a policy configuration you can copy, customize, and apply immediately.
SAST and dependency scanners flag hardcoded credentials, insecure fixtures, and dev-only dependencies in test directories. These are not production risks.
vulnerability_management_policy:
- name: "Dismiss test code vulnerabilities"
description: "Auto-dismiss findings in test directories"
enabled: true
rules:
- type: detected
criteria:
- type: file_path
value: "test/**/*"
- type: detected
criteria:
- type: file_path
value: "tests/**/*"
- type: detected
criteria:
- type: file_path
value: "spec/**/*"
- type: detected
criteria:
- type: directory
value: "__tests__/*"
actions:
- type: auto_dismiss
dismissal_reason: used_in_tests
Vulnerabilities in vendor/, third_party/, or checked-in node_modules are managed upstream and not actionable for your team.
vulnerability_management_policy:
- name: "Dismiss vendored dependency findings"
description: "Findings in vendored code are managed upstream"
enabled: true
rules:
- type: detected
criteria:
- type: directory
value: "vendor/*"
- type: detected
criteria:
- type: directory
value: "third_party/*"
- type: detected
criteria:
- type: directory
value: "vendored/*"
actions:
- type: auto_dismiss
dismissal_reason: not_applicable
Certain CVEs are repeatedly flagged but don't apply to your usage context. Teams dismiss these manually every time they appear. Replace the example CVEs below with your own.
vulnerability_management_policy:
- name: "Dismiss known false positive CVEs"
description: "CVEs confirmed as false positives for our environment"
enabled: true
rules:
- type: detected
criteria:
- type: identifier
value: "CVE-2023-44487"
- type: detected
criteria:
- type: identifier
value: "CVE-2024-29041"
- type: detected
criteria:
- type: identifier
value: "CVE-2023-26136"
actions:
- type: auto_dismiss
dismissal_reason: false_positive
Protobuf, gRPC, OpenAPI generators, and ORM scaffolding tools produce files with flagged patterns that cannot be patched by your team.
vulnerability_management_policy:
- name: "Dismiss generated code findings"
description: "Generated files are not authored by us"
enabled: true
rules:
- type: detected
criteria:
- type: directory
value: "generated/*"
- type: detected
criteria:
- type: file_path
value: "**/*.pb.go"
- type: detected
criteria:
- type: file_path
value: "**/*.generated.*"
actions:
- type: auto_dismiss
dismissal_reason: not_applicable
Vulnerability classes like XSS (CWE-79) or SQL injection (CWE-89) that are already addressed by WAF rules or runtime protection. Only use this when mitigating controls are verified and consistently enforced.
vulnerability_management_policy:
- name: "Dismiss CWEs mitigated by WAF"
description: "XSS and SQLi mitigated by WAF rules"
enabled: true
rules:
- type: detected
criteria:
- type: identifier
value: "CWE-79"
- type: detected
criteria:
- type: identifier
value: "CWE-89"
actions:
- type: auto_dismiss
dismissal_reason: mitigating_control
A wave of related CVEs for a widely-used library your team has assessed? Apply at the group level to dismiss them across dozens of projects. The wildcard pattern (e.g., CVE-2021-44*) matches all CVEs with that prefix.
vulnerability_management_policy:
- name: "Accept risk for log4j CVE family"
description: "Log4j CVEs mitigated by version pinning and WAF"
enabled: true
rules:
- type: detected
criteria:
- type: identifier
value: "CVE-2021-44*"
actions:
- type: auto_dismiss
dismissal_reason: acceptable_risk
| Parameter | Details |
|---|---|
| Criteria types | file_path (glob patterns, e.g., test/**/*), directory (e.g., vendor/*), identifier (CVE/CWE with wildcards, e.g., CVE-2023-*) |
| Dismissal reasons | acceptable_risk, false_positive, mitigating_control, used_in_tests, not_applicable |
| Criteria logic | Multiple criteria within a rule = AND (must match all). Multiple rules within a policy = OR (match any). |
| Limits | 3 criteria per rule, 5 rules per policy, 5 policies per security policy project. Vulnerabilty management policy actions process 1000 vulnerabilities per pipeline run in the target project, until all matching vulnerabilities are processed. |
| Affected statuses | Needs triage, Confirmed |
| Scope | Project-level or group-level (group-level applies across all projects) |
Here's how to get started with auto-dismiss policies:
For full configuration details, see the vulnerability management policy documentation.
Ready to take control of vulnerability noise? Start a free GitLab Ultimate trial and configure your first auto-dismiss policy today.
Enjoyed reading this blog post or have questions or feedback? Share your thoughts by creating a new topic in the GitLab community forum.
Share your feedback