Skip to content
GitLab
Next
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Primary navigation
Search or go to…
Project
GitLab
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Privacy statement
Keyboard shortcuts
?
What's new
4
Snippets
Groups
Projects
Show more breadcrumbs
GitLab.org
GitLab
Commits
22d48554
Verified
Commit
22d48554
authored
4 months ago
by
Thiago Figueiró
Browse files
Options
Downloads
Patches
Plain Diff
Add section on schema compatibility
parent
4a01e50d
No related branches found
No related tags found
1 merge request
!169216
Add section on schema compatibility
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
doc/development/sec/analyzer_development_guide.md
+35
-0
35 additions, 0 deletions
doc/development/sec/analyzer_development_guide.md
with
35 additions
and
0 deletions
doc/development/sec/analyzer_development_guide.md
+
35
−
0
View file @
22d48554
...
...
@@ -282,6 +282,41 @@ The [security-report-schema](https://gitlab.com/gitlab-org/security-products/sec
-
[
SAST
](
https://gitlab.com/gitlab-org/security-products/security-report-schemas/-/blob/master/dist/sast-report-format.json
)
-
[
Secret Detection
](
https://gitlab.com/gitlab-org/security-products/security-report-schemas/-/blob/master/dist/secret-detection-report-format.json
)
#### Compatibility with report schema
Security reports uploaded as
[
artifacts
](
../../user/application_security/index.md#all-tiers
)
to
GitLab are
[
validated
](
../integrations/secure.md#report-validation
)
before being
[
ingested
](
security_report_ingestion_overview.md
)
.
Security report schemas are versioned using SchemaVer:
`MODEL-REVISION-ADDITION`
. The Sec Section
is responsible for the
[
`security-report-schemas` project
](
https://gitlab.com/gitlab-org/security-products/security-report-schemas
)
,
including the compatibility of GitLab and the schema versions. Schema changes must follow the
product-wide
[
deprecation guidelines
](
../deprecation_guidelines/index.md
)
.
When a new
`MODEL`
version is introduced, analyzers that adopt the new schema are responsible for
ensuring that GitLab deployments that do not vendor this new schema version continue to ingest
security reports without errors or warnings.
This can be accomplished in different ways:
1.
Implement support for multiple schema versions in the analyzer. Based on the GitLab version, the
analyzer emits a security report using the latest schema version supported by GitLab.
-
Pro: analyzer can decide at runtime what the best version to utilize is.
-
Con: implementation effort and increased complexity.
1.
Release a new analyzer major version. Instances that don't vendor the latest
`MODEL`
schema
version continue to use an analyzer version that emits reports using version
`MODEL-1`
.
-
Pro: keeps analyzer code simple.
-
Con: extra analyzer version to maintain.
1.
Delay use of new schema. This relies on
`additionalProperties=true`
, which allows a report to
include properties that are not present in the schema. A new analyzer major version would be
released at the usual cadence.
-
Pro: no extra analyzer to maintain, keep analyzer code simple.
-
Con: increased risk and/or effort to mitigate the risk of not having the schema validated.
If you are unsure which path to follow, reach-out to the
[
`security-report-schemas` maintainers
](
https://gitlab.com/groups/gitlab-org/maintainers/security-report-schemas/-/group_members?with_inherited_permissions=exclude
)
.
### Location of Container Images
In order to
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment