BE: Support new Attribute filtering options
Why are we doing this work
Filtering by "attribute". An expected scenario for these filters would be to create a policy that requires approvals from the Security team only when a fix is available and when the vulnerability is not a false positive. Users will be able to use an "Is" or "Is Not" operator when defining attributes.
- Fix Available: Whether or not a fix is available for the vulnerability (only applies to Container and Dependency Scanning)
- False Positive: Whether or not the vulnerability has been identified as a false positive
This issue focusses on updating backend to support the attribute filter
Relevant links
- Epic: &6826 (closed)
- Design:
Non-functional requirements
-
Documentation: Update scan_finding
rule type to includevulnerability_attribute
attribute -
Feature flag: -
Performance: -
Testing:
Implementation plan
-
Update security_orchestration_policy.json
JSON schema to add definition forvulnerability_attribute
attribute -
Add column for vulnerability_attribute
inscan_result_policies
table -
Update Security::SecurityOrchestrationPolicies::ProcessScanResultPolicyService
to persistvulnerability_attribute
in ScanResultPolicyRead -
Update Security::ScanResultPolicies::UpdateApprovalsService
to filtersecurity_findings
byfalse_positive
andfix_available
along with the logical condition
Verification steps
Edited by Sashi Kumar Kumaresan