Skip to content

Draft: Move security reports code to Security namespace

Brian Williams requested to merge bwill/move-security-classes-from-ci into master

What does this MR do and why?

Describe in detail what your merge request does and why.

There is quite a lot of code related to security reports which lives in the Gitlab::Ci::Reports namespace. This code is actually highly specialized and isn't really related to Ci at all. This change moves it into the Security namespace instead. The new directory structure is as follows.

lib/security
├── parsers
│   ├── common.rb
│   ├── sast.rb
│   └── secret_detection.rb
├── reports
│   ├── aggregated_report.rb
│   ├── analyzer.rb
│   ├── collection.rb
│   ├── concerns
│   │   └── fingerprint_path_from_file.rb
│   ├── evidence.rb
│   ├── finding.rb
│   ├── finding_key.rb
│   ├── finding_signature.rb
│   ├── flag.rb
│   ├── identifier.rb
│   ├── link.rb
│   ├── locations
│   │   ├── base.rb
│   │   ├── sast.rb
│   │   └── secret_detection.rb
│   ├── report.rb
│   ├── scan.rb
│   ├── scanned_resource.rb
│   └── scanner.rb
├── validators
    └── schema_validator.rb
lib/sbom
└── reports
    ├── collection.rb
    ├── component.rb
    ├── report.rb
    └── source.rb
ee/lib/security
├── formatters
│   └── dependency_list.rb
├── parsers
│   ├── cluster_image_scanning.rb
│   ├── container_scanning.rb
│   ├── coverage_fuzzing.rb
│   ├── dast.rb
│   ├── dependency_list.rb
│   └── dependency_scanning.rb
├── reports
│   ├── concerns
│   │   └── scan_finding.rb
│   ├── locations
│   │   ├── cluster_image_scanning.rb
│   │   ├── container_scanning.rb
│   │   ├── coverage_fuzzing.rb
│   │   ├── dast.rb
│   │   └── dependency_scanning.rb
│   ├── remediation.rb
│   └── vulnerability_reports_comparer.rb
└── validators
    └── default_branch_image_validator.rb
ee/lib/ee/security
├── parsers
│   └── common.rb
├── reports
│   └── collection.rb
└── validators
    └── schema_validator.rb

Related to #404645

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Thiago Figueiró

Merge request reports