Fetch dependency paths with GraphQL query on vulnerability details page
What does this MR do and why?
Related #550623 (closed)
Fetch dependency paths with GraphQL query on vulnerability details page
- The dropdown in the dependency path drawer that is used to select the project on the group-level dependencies page is re-used to select an occurrence on the vulnerability details page
- The
sbomOccurrencesare parsed independency_path.vueand converted todropdownItems - Manually passing the dependency paths to the drawer is removed in this MR
References
Screenshots or screen recordings
vulnerability-details-dependency-paths
How to set up and validate locally
- Enable feature flags: http://gdk.test:3000/rails/features/dependency_paths and http://gdk.test:3000/rails/features/dependency_graph_graphql
- Import project in group gitlab-org: https://gitlab.com/gitlab-org/govern/threat-insights-demos/frontend/security-reports-with-dependency-paths/-/dependencies
- Run pipeline in that project (run twice due to bug)
- On project-level dependencies page, find
lodash 4.17.11, expand, and click on a vulnerability - On the vulnerability details page, click "View dependency paths"
- Validate the drawer opens and 10 paths load. Verify you see a dropdown for selecting occurrence (only 1 occurrence
yarn.lock) - Validate you can use "next" and "previous" pagination buttons
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Edited by Lorenz van Herwaarden