gitlab-security_report_schemas 0.1.0.min15.1.0.max15.1.0 → 0.1.1.min15.0.0.max15.1.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (89) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +6 -9
  3. data/README.md +14 -10
  4. data/RUNBOOK.md +28 -0
  5. data/Rakefile +1 -1
  6. data/gem_version +1 -1
  7. data/gitlab-security_report_schemas.gemspec +1 -1
  8. data/lib/gitlab/security_report_schemas/configuration.rb +2 -2
  9. data/lib/gitlab/security_report_schemas/version.rb +1 -3
  10. data/schemas/15.0.0/cluster-image-scanning-report-format.json +946 -0
  11. data/schemas/15.0.0/container-scanning-report-format.json +880 -0
  12. data/schemas/15.0.0/coverage-fuzzing-report-format.json +836 -0
  13. data/schemas/15.0.0/dast-report-format.json +1241 -0
  14. data/schemas/15.0.0/dependency-scanning-report-format.json +944 -0
  15. data/schemas/15.0.0/sast-report-format.json +831 -0
  16. data/schemas/15.0.0/secret-detection-report-format.json +854 -0
  17. data/schemas/15.0.1/cluster-image-scanning-report-format.json +980 -0
  18. data/schemas/15.0.1/container-scanning-report-format.json +914 -0
  19. data/schemas/15.0.1/coverage-fuzzing-report-format.json +870 -0
  20. data/schemas/15.0.1/dast-report-format.json +1275 -0
  21. data/schemas/15.0.1/dependency-scanning-report-format.json +978 -0
  22. data/schemas/15.0.1/sast-report-format.json +865 -0
  23. data/schemas/15.0.1/secret-detection-report-format.json +888 -0
  24. data/schemas/15.0.2/cluster-image-scanning-report-format.json +980 -0
  25. data/schemas/15.0.2/container-scanning-report-format.json +912 -0
  26. data/schemas/15.0.2/coverage-fuzzing-report-format.json +870 -0
  27. data/schemas/15.0.2/dast-report-format.json +1275 -0
  28. data/schemas/15.0.2/dependency-scanning-report-format.json +978 -0
  29. data/schemas/15.0.2/sast-report-format.json +865 -0
  30. data/schemas/15.0.2/secret-detection-report-format.json +888 -0
  31. data/schemas/15.0.4/cluster-image-scanning-report-format.json +984 -0
  32. data/schemas/15.0.4/container-scanning-report-format.json +916 -0
  33. data/schemas/15.0.4/coverage-fuzzing-report-format.json +874 -0
  34. data/schemas/15.0.4/dast-report-format.json +1279 -0
  35. data/schemas/15.0.4/dependency-scanning-report-format.json +982 -0
  36. data/schemas/15.0.4/sast-report-format.json +869 -0
  37. data/schemas/15.0.4/secret-detection-report-format.json +893 -0
  38. data/schemas/15.0.5/cluster-image-scanning-report-format.json +1035 -0
  39. data/schemas/15.0.5/container-scanning-report-format.json +967 -0
  40. data/schemas/15.0.5/coverage-fuzzing-report-format.json +925 -0
  41. data/schemas/15.0.5/dast-report-format.json +1330 -0
  42. data/schemas/15.0.5/dependency-scanning-report-format.json +1033 -0
  43. data/schemas/15.0.5/sast-report-format.json +920 -0
  44. data/schemas/15.0.5/secret-detection-report-format.json +944 -0
  45. data/schemas/15.0.6/cluster-image-scanning-report-format.json +1035 -0
  46. data/schemas/15.0.6/container-scanning-report-format.json +967 -0
  47. data/schemas/15.0.6/coverage-fuzzing-report-format.json +925 -0
  48. data/schemas/15.0.6/dast-report-format.json +1330 -0
  49. data/schemas/15.0.6/dependency-scanning-report-format.json +1033 -0
  50. data/schemas/15.0.6/sast-report-format.json +920 -0
  51. data/schemas/15.0.6/secret-detection-report-format.json +944 -0
  52. data/schemas/15.0.7/cluster-image-scanning-report-format.json +1085 -0
  53. data/schemas/15.0.7/container-scanning-report-format.json +1017 -0
  54. data/schemas/15.0.7/coverage-fuzzing-report-format.json +975 -0
  55. data/schemas/15.0.7/dast-report-format.json +1380 -0
  56. data/schemas/15.0.7/dependency-scanning-report-format.json +1083 -0
  57. data/schemas/15.0.7/sast-report-format.json +970 -0
  58. data/schemas/15.0.7/secret-detection-report-format.json +994 -0
  59. data/schemas/15.1.1/cluster-image-scanning-report-format.json +1065 -0
  60. data/schemas/15.1.1/container-scanning-for-registry-report-format.json +0 -0
  61. data/schemas/15.1.1/container-scanning-report-format.json +998 -0
  62. data/schemas/15.1.1/coverage-fuzzing-report-format.json +975 -0
  63. data/schemas/15.1.1/dast-report-format.json +1380 -0
  64. data/schemas/15.1.1/dependency-scanning-report-format.json +986 -0
  65. data/schemas/15.1.1/sast-report-format.json +970 -0
  66. data/schemas/15.1.1/secret-detection-report-format.json +994 -0
  67. data/schemas/15.1.2/cluster-image-scanning-report-format.json +1190 -0
  68. data/schemas/15.1.2/container-scanning-report-format.json +1123 -0
  69. data/schemas/15.1.2/coverage-fuzzing-report-format.json +1100 -0
  70. data/schemas/15.1.2/dast-report-format.json +1505 -0
  71. data/schemas/15.1.2/dependency-scanning-report-format.json +1111 -0
  72. data/schemas/15.1.2/sast-report-format.json +1095 -0
  73. data/schemas/15.1.2/secret-detection-report-format.json +1119 -0
  74. data/schemas/15.1.3/cluster-image-scanning-report-format.json +1190 -0
  75. data/schemas/15.1.3/container-scanning-report-format.json +1123 -0
  76. data/schemas/15.1.3/coverage-fuzzing-report-format.json +1100 -0
  77. data/schemas/15.1.3/dast-report-format.json +1505 -0
  78. data/schemas/15.1.3/dependency-scanning-report-format.json +1111 -0
  79. data/schemas/15.1.3/sast-report-format.json +1095 -0
  80. data/schemas/15.1.3/secret-detection-report-format.json +1119 -0
  81. data/schemas/15.1.4/cluster-image-scanning-report-format.json +1190 -0
  82. data/schemas/15.1.4/container-scanning-report-format.json +1123 -0
  83. data/schemas/15.1.4/coverage-fuzzing-report-format.json +1100 -0
  84. data/schemas/15.1.4/dast-report-format.json +1505 -0
  85. data/schemas/15.1.4/dependency-scanning-report-format.json +1111 -0
  86. data/schemas/15.1.4/sast-report-format.json +1095 -0
  87. data/schemas/15.1.4/secret-detection-report-format.json +1119 -0
  88. data/supported_versions +11 -0
  89. metadata +83 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f4c389c7784c3bbbd5456fab0128a39755f46cd9decd3b6056c22e97861f0adf
4
- data.tar.gz: a3a9d4d8fe97cebe404fc5d1a653d564aff3163abd7d0d5add42be64b598cf6a
3
+ metadata.gz: 83ef49533aa14d57d606e97177dd522e6ad3017504cd733b0e9176f7c02202f6
4
+ data.tar.gz: b3e12d90ce76650f2fbdfca751c0aff425c1b40ead2d631f3efd9e2e394d17a0
5
5
  SHA512:
6
- metadata.gz: 778edd32130b9e3859a35dfdd3635c24d07dd8a0eef0e58ca01090c8035430a7199763c02fcba017f8dfd4793d0c92e82c09ae240215d5f5313d969c6f56fb8f
7
- data.tar.gz: a250c4845733d632c13a002d7fa5e173221559876add385372a75e043835007ef2cd471a263904ff9121d83e68c30ebbe7f886b954366737e983642f90e1aa58
6
+ metadata.gz: a0001fca053530429d39dc2acded7cf33bbdb3722431c2a4525640c94277f86b523abd01a033845d1e581a8591b36b19fa3275f92fc073fee2e55df7ebe13fd4
7
+ data.tar.gz: 47bad16e12f3cd883e5709e41a28d35be222df315963a5dd995ea07597e1af9f579b8df02848ecc44aa91f4440f6c407d242fd61c87471ac37293b6e66a81b0f
data/Gemfile.lock CHANGED
@@ -1,9 +1,9 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gitlab-security_report_schemas (0.1.0.min15.1.0.max15.1.0)
4
+ gitlab-security_report_schemas (0.1.1.min15.0.0.max15.1.4)
5
5
  activesupport (>= 6, < 8)
6
- json_schemer (~> 0.2.18)
6
+ json_schemer (~> 2.3.0)
7
7
 
8
8
  GEM
9
9
  remote: https://rubygems.org/
@@ -14,23 +14,21 @@ GEM
14
14
  minitest (>= 5.1)
15
15
  tzinfo (~> 2.0)
16
16
  ast (2.4.2)
17
+ bigdecimal (3.1.8)
17
18
  coderay (1.1.3)
18
19
  concurrent-ruby (1.1.10)
19
20
  diff-lcs (1.5.0)
20
- ecma-re-validator (0.4.0)
21
- regexp_parser (~> 2.2)
22
21
  git (1.11.0)
23
22
  rchardet (~> 1.8)
24
23
  hana (1.3.7)
25
24
  i18n (1.12.0)
26
25
  concurrent-ruby (~> 1.0)
27
26
  json (2.6.2)
28
- json_schemer (0.2.25)
29
- ecma-re-validator (~> 0.3)
27
+ json_schemer (2.3.0)
28
+ bigdecimal
30
29
  hana (~> 1.3)
31
30
  regexp_parser (~> 2.0)
32
31
  simpleidn (~> 0.2)
33
- uri_template (~> 0.7)
34
32
  method_source (1.0.0)
35
33
  minitest (5.16.2)
36
34
  parallel (1.22.1)
@@ -76,7 +74,6 @@ GEM
76
74
  tzinfo (2.0.5)
77
75
  concurrent-ruby (~> 1.0)
78
76
  unicode-display_width (2.2.0)
79
- uri_template (0.7.0)
80
77
 
81
78
  PLATFORMS
82
79
  arm64-darwin-21
@@ -93,4 +90,4 @@ DEPENDENCIES
93
90
  shoulda-matchers (~> 5.0)
94
91
 
95
92
  BUNDLED WITH
96
- 2.3.15
93
+ 2.5.14
data/README.md CHANGED
@@ -47,21 +47,25 @@ bundle exec security-reports-schemas $FILE_PATH
47
47
 
48
48
  #### Credentials
49
49
 
50
- | Key | Description |
51
- |-----------------------------|-----------------------------------------------------------------------------------------------------------------------------|
52
- | `GITLAB_PUSH_ACCESS_TOKEN` | Own project access token used to push new schema versions. Requires `write_repository` scope. |
53
- | `GITLAB_ISSUE_ACCESS_TOKEN` | Project access token used to create an issue on `gitlab-org/gitlab`. Requires `api` scopes. |
54
- | `GEM_HOST_API_KEY` | rubygems.org API key |
50
+ | Key | Description |
51
+ |-----------------------------|-----------------------------------------------------------------------------------------------|
52
+ | `GITLAB_PUSH_ACCESS_TOKEN` | Own project access token used to push new schema versions. Requires `write_repository` scope. |
53
+ | `GITLAB_ISSUE_ACCESS_TOKEN` | Project access token used to create an issue on `gitlab-org/gitlab`. Requires `api` scopes. |
54
+ | `GEM_HOST_API_KEY` | rubygems.org API key |
55
55
 
56
56
  #### Configuration
57
57
 
58
- | Key | Default | Description |
59
- |---------------------------|--------------------------------------------------------|----------------------------|
60
- | `SCHEMAS_PATH` | `./schemas` | Schema storage location |
61
- | `SCHEMA_PROJECT` | `gitlab-org/security-products/security-report-schemas` | Where to source schemas |
62
- | `GITLAB_PROJECT` | `gitlab-org/gitlab` | Project to open MRs for |
58
+ | Key | Default | Description |
59
+ |---------------------------|--------------------------------------------------------|----------------------------------------|
60
+ | `SCHEMAS_PATH` | `./schemas` | Schema storage location |
61
+ | `SCHEMA_PROJECT` | `gitlab-org/security-products/security-report-schemas` | Where to source schemas |
62
+ | `GITLAB_PROJECT` | `gitlab-org/gitlab` | Project to open MRs for |
63
63
  | `ISSUE_TARGET_PROJECT_ID` | `278964` (`gitlab-org/gitlab`) | Project ID for which to open an issue. |
64
64
 
65
+ ## Maintenance
66
+
67
+ See [`RUNBOOK.md`](./RUNBOOK.md) for solutions to common maintenance tasks.
68
+
65
69
  ## Development
66
70
 
67
71
  ### Updating the schemas
data/RUNBOOK.md ADDED
@@ -0,0 +1,28 @@
1
+ # Common maintenance tasks
2
+
3
+ ### Problem
4
+
5
+ * an upstream [security-report-schemas](https://gitlab.com/gitlab-org/security-products/security-report-schemas) pipeline failed to trigger the release pipeline
6
+ * you want to add, remove or deprecate support for report schema versions
7
+ * you need to release a new version of the gem without altering version ranges,
8
+ because for example:
9
+ * an existing gem release has a bug, and the bugfix release needs to cover the
10
+ same version range.
11
+ * there were breaking changes to the gem's public API that must be released
12
+ for the currently supported version range.
13
+
14
+ ### Solution
15
+
16
+ 1. Open and merge an MR targeting the default branch which may:
17
+ * change the [`supported_versions`](../supported_versions) file to set the
18
+ report schema version range that the release should include.
19
+ * change the `Gitlab::SecurityReportSchemas::Version::GEM_VERSION` constant
20
+ to set the MAJOR.MINOR.PATCH version components of the resulting release.
21
+ 2. Run a new pipeline for the default branch and set the `MANUAL_RELEASE` CI
22
+ variable.
23
+ 3. Trigger the manual `manual-release` job in the resulting pipeline.
24
+
25
+ ## Find the commit SHA for a RubyGem version
26
+
27
+ Before a rubygems.org release is created, a git tag referencing the full
28
+ v-prefixed release version is pushed, for example `v0.1.0.min15.0.0.max15.0.1`.
data/Rakefile CHANGED
@@ -30,7 +30,7 @@ desc "Bundles the Security Report Schemas into the project and builds the gem"
30
30
  task :prepare, %i[versions] => %i[prepare_schemas build]
31
31
 
32
32
  desc "Checks the integrity of the schema files with upstream"
33
- task :integrity_check do
33
+ task integrity_check: :prepare_schemas do
34
34
  require "gitlab/security_report_schemas"
35
35
  require "gitlab/security_report_schemas/cli/integrity_checker"
36
36
 
data/gem_version CHANGED
@@ -1 +1 @@
1
- 0.1.0.min15.1.0.max15.1.0
1
+ 0.1.1.min15.0.0.max15.1.4
@@ -29,5 +29,5 @@ Gem::Specification.new do |spec|
29
29
  spec.require_paths = ["lib"]
30
30
 
31
31
  spec.add_dependency "activesupport", ">= 6", "< 8"
32
- spec.add_dependency "json_schemer", "~> 0.2.18"
32
+ spec.add_dependency "json_schemer", "~> 2.3.0"
33
33
  end
@@ -9,8 +9,8 @@ module Gitlab
9
9
  deprecated_versions: -> { [] },
10
10
  schema_project: -> { "gitlab-org/security-products/security-report-schemas" },
11
11
  gitlab_project: -> { "gitlab-org/gitlab" },
12
- issue_target_project_id: -> { ENV.fetch("GITLAB_MR_ACCESS_TOKEN", "278964") }, # gitlab-org/gitlab
13
- gitlab_issue_access_token: -> { ENV["GITLAB_MR_ACCESS_TOKEN"] },
12
+ issue_target_project_id: -> { "278964" }, # gitlab-org/gitlab
13
+ gitlab_issue_access_token: nil,
14
14
  ci_server_host: nil
15
15
  }.freeze
16
16
 
@@ -5,7 +5,7 @@ module Gitlab
5
5
  # Represents the version of the gem
6
6
  class Version
7
7
  VERSION_SPEC = "%<gem_version>s.min%<min_schema>s.max%<max_schema>s"
8
- GEM_VERSION = "0.1.0"
8
+ GEM_VERSION = "0.1.1"
9
9
  MISSING_SCHEMA_VERSION = "0.0.0"
10
10
 
11
11
  class << self
@@ -16,8 +16,6 @@ module Gitlab
16
16
  max_schema: max_schema)
17
17
  end
18
18
 
19
- private
20
-
21
19
  def min_schema
22
20
  SecurityReportSchemas.supported_versions.first || MISSING_SCHEMA_VERSION
23
21
  end