Add awareness of whether scanners have been enabled on Security Dashboard - Frontend
frontend issue for parent issue: #214392 (closed)
Design
Implementation Outline
-
Create GraphQL Query to retrieve list of scanners for the current project (with enabled
/disabled
status) -
Add query to ee/app/assets/javascripts/vulnerabilities/components/project_vulnerabilities_app.vue
and pass data toVulnerabilityList
-
Add props to VulnerabilityList
to retrieve scanner data -
Create new component (e.g.: VulnerabilityInfoBanner
) that receives the scanners-data as a prop and includes render logic (1+ scanner(s) types enabled and 1+ scanner type(s) NOT enabled - display banner) and also setslocalStorage
on dismissal / checks for the flag -
Render the newly created component within the VulnerabilityList
table'stop-row
slot (https://bootstrap-vue.org/docs/components/table#comp-ref-b-table-slots)
Proposed GraphQL schema:
enum SecurityScanner {
SAST
DAST
CONTAINER_SCANNING
SECRET_DETECTION
LICENSE_SCANNING
LICENSE_MANAGEMENT
DEPENDENCY_SCANNING
}
type SecurityScanners {
enabled: [SecurityScanner!]!
available: [SecurityScanner!]!
pipelineRun: [SecurityScanner!]!
}
extend type Project {
securityScanners: SecurityScanners
}
Edited by David Pisek