@ulisesgascon/openjs-cna-tools 0.0.0-stage → 1.0.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +312 -2
  3. package/bin/openjs-cna.js +128 -0
  4. package/components/config.js +92 -0
  5. package/components/convert.js +81 -0
  6. package/components/get.js +35 -0
  7. package/components/health.js +30 -0
  8. package/components/list.js +36 -0
  9. package/components/llm-review-prompt.js +84 -0
  10. package/components/preview.js +42 -0
  11. package/components/publish.js +238 -0
  12. package/components/reserve.js +48 -0
  13. package/components/review.js +170 -0
  14. package/components/update.js +104 -0
  15. package/lib/auth.js +20 -0
  16. package/lib/batch.js +141 -0
  17. package/lib/cli.js +81 -0
  18. package/lib/client.js +244 -0
  19. package/lib/component-utils.js +74 -0
  20. package/lib/config.js +121 -0
  21. package/lib/convert/ghsa.js +450 -0
  22. package/lib/convert/version-range.js +251 -0
  23. package/lib/cvss.js +113 -0
  24. package/lib/errors.js +44 -0
  25. package/lib/index.js +9 -0
  26. package/lib/preview.js +145 -0
  27. package/lib/prompt.js +170 -0
  28. package/lib/record.js +123 -0
  29. package/lib/review/index.js +78 -0
  30. package/lib/review/rules.js +433 -0
  31. package/lib/review/schema.js +99 -0
  32. package/lib/review/schemas/cve-record-format.json +1362 -0
  33. package/lib/review/schemas/imports/cvss/cvss-v2.0.json +195 -0
  34. package/lib/review/schemas/imports/cvss/cvss-v3.0.json +577 -0
  35. package/lib/review/schemas/imports/cvss/cvss-v3.1.json +577 -0
  36. package/lib/review/schemas/imports/cvss/cvss-v4.0.json +784 -0
  37. package/lib/review/schemas/tags/adp-tags.json +7 -0
  38. package/lib/review/schemas/tags/cna-tags.json +7 -0
  39. package/lib/review/schemas/tags/reference-tags.json +27 -0
  40. package/package.json +55 -4
@@ -0,0 +1,784 @@
1
+ {
2
+ "license": [
3
+ "Copyright (c) 2023, FIRST.ORG, INC.",
4
+ "All rights reserved.",
5
+ "",
6
+ "Redistribution and use in source and binary forms, with or without modification, are permitted provided that the ",
7
+ "following conditions are met:",
8
+ "1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following ",
9
+ " disclaimer.",
10
+ "2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the ",
11
+ " following disclaimer in the documentation and/or other materials provided with the distribution.",
12
+ "3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote ",
13
+ " products derived from this software without specific prior written permission.",
14
+ "",
15
+ "THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS' AND ANY EXPRESS OR IMPLIED WARRANTIES, ",
16
+ "INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE ",
17
+ "DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ",
18
+ "SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR ",
19
+ "SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, ",
20
+ "WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE ",
21
+ "OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
22
+ ],
23
+ "$schema": "http://json-schema.org/draft-07/schema#",
24
+ "title": "JSON Schema for Common Vulnerability Scoring System version 4.0",
25
+ "$id": "https://www.first.org/cvss/cvss-v4.0.json?20231011",
26
+ "type": "object",
27
+ "definitions": {
28
+ "attackVectorType": {
29
+ "type": "string",
30
+ "enum": [
31
+ "NETWORK",
32
+ "ADJACENT",
33
+ "LOCAL",
34
+ "PHYSICAL"
35
+ ]
36
+ },
37
+ "modifiedAttackVectorType": {
38
+ "type": "string",
39
+ "enum": [
40
+ "NETWORK",
41
+ "ADJACENT",
42
+ "LOCAL",
43
+ "PHYSICAL",
44
+ "NOT_DEFINED"
45
+ ],
46
+ "default": "NOT_DEFINED"
47
+ },
48
+ "attackComplexityType": {
49
+ "type": "string",
50
+ "enum": [
51
+ "HIGH",
52
+ "LOW"
53
+ ]
54
+ },
55
+ "modifiedAttackComplexityType": {
56
+ "type": "string",
57
+ "enum": [
58
+ "HIGH",
59
+ "LOW",
60
+ "NOT_DEFINED"
61
+ ],
62
+ "default": "NOT_DEFINED"
63
+ },
64
+ "attackRequirementsType": {
65
+ "type": "string",
66
+ "enum": [
67
+ "NONE",
68
+ "PRESENT"
69
+ ]
70
+ },
71
+ "modifiedAttackRequirementsType": {
72
+ "type": "string",
73
+ "enum": [
74
+ "NONE",
75
+ "PRESENT",
76
+ "NOT_DEFINED"
77
+ ],
78
+ "default": "NOT_DEFINED"
79
+ },
80
+ "privilegesRequiredType": {
81
+ "type": "string",
82
+ "enum": [
83
+ "HIGH",
84
+ "LOW",
85
+ "NONE"
86
+ ]
87
+ },
88
+ "modifiedPrivilegesRequiredType": {
89
+ "type": "string",
90
+ "enum": [
91
+ "HIGH",
92
+ "LOW",
93
+ "NONE",
94
+ "NOT_DEFINED"
95
+ ],
96
+ "default": "NOT_DEFINED"
97
+ },
98
+ "userInteractionType": {
99
+ "type": "string",
100
+ "enum": [
101
+ "NONE",
102
+ "PASSIVE",
103
+ "ACTIVE"
104
+ ]
105
+ },
106
+ "modifiedUserInteractionType": {
107
+ "type": "string",
108
+ "enum": [
109
+ "NONE",
110
+ "PASSIVE",
111
+ "ACTIVE",
112
+ "NOT_DEFINED"
113
+ ],
114
+ "default": "NOT_DEFINED"
115
+ },
116
+ "vulnCiaType": {
117
+ "type": "string",
118
+ "enum": [
119
+ "NONE",
120
+ "LOW",
121
+ "HIGH"
122
+ ]
123
+ },
124
+ "modifiedVulnCiaType": {
125
+ "type": "string",
126
+ "enum": [
127
+ "NONE",
128
+ "LOW",
129
+ "HIGH",
130
+ "NOT_DEFINED"
131
+ ],
132
+ "default": "NOT_DEFINED"
133
+ },
134
+ "subCiaType": {
135
+ "type": "string",
136
+ "enum": [
137
+ "NONE",
138
+ "LOW",
139
+ "HIGH"
140
+ ]
141
+ },
142
+ "modifiedSubCType": {
143
+ "type": "string",
144
+ "enum": [
145
+ "NONE",
146
+ "LOW",
147
+ "HIGH",
148
+ "NOT_DEFINED"
149
+ ],
150
+ "default": "NOT_DEFINED"
151
+ },
152
+ "modifiedSubIaType": {
153
+ "type": "string",
154
+ "enum": [
155
+ "NONE",
156
+ "LOW",
157
+ "HIGH",
158
+ "SAFETY",
159
+ "NOT_DEFINED"
160
+ ],
161
+ "default": "NOT_DEFINED"
162
+ },
163
+ "exploitMaturityType": {
164
+ "type": "string",
165
+ "enum": [
166
+ "UNREPORTED",
167
+ "PROOF_OF_CONCEPT",
168
+ "ATTACKED",
169
+ "NOT_DEFINED"
170
+ ],
171
+ "default": "NOT_DEFINED"
172
+ },
173
+ "ciaRequirementType": {
174
+ "type": "string",
175
+ "enum": [
176
+ "LOW",
177
+ "MEDIUM",
178
+ "HIGH",
179
+ "NOT_DEFINED"
180
+ ],
181
+ "default": "NOT_DEFINED"
182
+ },
183
+ "safetyType": {
184
+ "type": "string",
185
+ "enum": [
186
+ "NEGLIGIBLE",
187
+ "PRESENT",
188
+ "NOT_DEFINED"
189
+ ],
190
+ "default": "NOT_DEFINED"
191
+ },
192
+ "automatableType": {
193
+ "type": "string",
194
+ "enum": [
195
+ "NO",
196
+ "YES",
197
+ "NOT_DEFINED"
198
+ ],
199
+ "default": "NOT_DEFINED"
200
+ },
201
+ "recoveryType": {
202
+ "type": "string",
203
+ "enum": [
204
+ "AUTOMATIC",
205
+ "USER",
206
+ "IRRECOVERABLE",
207
+ "NOT_DEFINED"
208
+ ],
209
+ "default": "NOT_DEFINED"
210
+ },
211
+ "valueDensityType": {
212
+ "type": "string",
213
+ "enum": [
214
+ "DIFFUSE",
215
+ "CONCENTRATED",
216
+ "NOT_DEFINED"
217
+ ],
218
+ "default": "NOT_DEFINED"
219
+ },
220
+ "vulnerabilityResponseEffortType": {
221
+ "type": "string",
222
+ "enum": [
223
+ "LOW",
224
+ "MODERATE",
225
+ "HIGH",
226
+ "NOT_DEFINED"
227
+ ],
228
+ "default": "NOT_DEFINED"
229
+ },
230
+ "providerUrgencyType": {
231
+ "type": "string",
232
+ "enum": [
233
+ "CLEAR",
234
+ "GREEN",
235
+ "AMBER",
236
+ "RED",
237
+ "NOT_DEFINED"
238
+ ],
239
+ "default": "NOT_DEFINED"
240
+ },
241
+ "scoreType": {
242
+ "type": "number",
243
+ "enum": [
244
+ 0.0,
245
+ 0.1,
246
+ 0.2,
247
+ 0.3,
248
+ 0.4,
249
+ 0.5,
250
+ 0.6,
251
+ 0.7,
252
+ 0.8,
253
+ 0.9,
254
+ 1.0,
255
+ 1.1,
256
+ 1.2,
257
+ 1.3,
258
+ 1.4,
259
+ 1.5,
260
+ 1.6,
261
+ 1.7,
262
+ 1.8,
263
+ 1.9,
264
+ 2.0,
265
+ 2.1,
266
+ 2.2,
267
+ 2.3,
268
+ 2.4,
269
+ 2.5,
270
+ 2.6,
271
+ 2.7,
272
+ 2.8,
273
+ 2.9,
274
+ 3.0,
275
+ 3.1,
276
+ 3.2,
277
+ 3.3,
278
+ 3.4,
279
+ 3.5,
280
+ 3.6,
281
+ 3.7,
282
+ 3.8,
283
+ 3.9,
284
+ 4.0,
285
+ 4.1,
286
+ 4.2,
287
+ 4.3,
288
+ 4.4,
289
+ 4.5,
290
+ 4.6,
291
+ 4.7,
292
+ 4.8,
293
+ 4.9,
294
+ 5.0,
295
+ 5.1,
296
+ 5.2,
297
+ 5.3,
298
+ 5.4,
299
+ 5.5,
300
+ 5.6,
301
+ 5.7,
302
+ 5.8,
303
+ 5.9,
304
+ 6.0,
305
+ 6.1,
306
+ 6.2,
307
+ 6.3,
308
+ 6.4,
309
+ 6.5,
310
+ 6.6,
311
+ 6.7,
312
+ 6.8,
313
+ 6.9,
314
+ 7.0,
315
+ 7.1,
316
+ 7.2,
317
+ 7.3,
318
+ 7.4,
319
+ 7.5,
320
+ 7.6,
321
+ 7.7,
322
+ 7.8,
323
+ 7.9,
324
+ 8.0,
325
+ 8.1,
326
+ 8.2,
327
+ 8.3,
328
+ 8.4,
329
+ 8.5,
330
+ 8.6,
331
+ 8.7,
332
+ 8.8,
333
+ 8.9,
334
+ 9.0,
335
+ 9.1,
336
+ 9.2,
337
+ 9.3,
338
+ 9.4,
339
+ 9.5,
340
+ 9.6,
341
+ 9.7,
342
+ 9.8,
343
+ 9.9,
344
+ 10.0
345
+ ]
346
+ },
347
+ "noneScoreType": {
348
+ "type": "number",
349
+ "minimum": 0,
350
+ "maximum": 0
351
+ },
352
+ "lowScoreType": {
353
+ "type": "number",
354
+ "enum": [
355
+ 0.1,
356
+ 0.2,
357
+ 0.3,
358
+ 0.4,
359
+ 0.5,
360
+ 0.6,
361
+ 0.7,
362
+ 0.8,
363
+ 0.9,
364
+ 1.0,
365
+ 1.1,
366
+ 1.2,
367
+ 1.3,
368
+ 1.4,
369
+ 1.5,
370
+ 1.6,
371
+ 1.7,
372
+ 1.8,
373
+ 1.9,
374
+ 2.0,
375
+ 2.1,
376
+ 2.2,
377
+ 2.3,
378
+ 2.4,
379
+ 2.5,
380
+ 2.6,
381
+ 2.7,
382
+ 2.8,
383
+ 2.9,
384
+ 3.0,
385
+ 3.1,
386
+ 3.2,
387
+ 3.3,
388
+ 3.4,
389
+ 3.5,
390
+ 3.6,
391
+ 3.7,
392
+ 3.8,
393
+ 3.9
394
+ ]
395
+ },
396
+ "mediumScoreType": {
397
+ "type": "number",
398
+ "enum": [
399
+ 4.0,
400
+ 4.1,
401
+ 4.2,
402
+ 4.3,
403
+ 4.4,
404
+ 4.5,
405
+ 4.6,
406
+ 4.7,
407
+ 4.8,
408
+ 4.9,
409
+ 5.0,
410
+ 5.1,
411
+ 5.2,
412
+ 5.3,
413
+ 5.4,
414
+ 5.5,
415
+ 5.6,
416
+ 5.7,
417
+ 5.8,
418
+ 5.9,
419
+ 6.0,
420
+ 6.1,
421
+ 6.2,
422
+ 6.3,
423
+ 6.4,
424
+ 6.5,
425
+ 6.6,
426
+ 6.7,
427
+ 6.8,
428
+ 6.9
429
+ ]
430
+ },
431
+ "highScoreType": {
432
+ "type": "number",
433
+ "enum": [
434
+ 7.0,
435
+ 7.1,
436
+ 7.2,
437
+ 7.3,
438
+ 7.4,
439
+ 7.5,
440
+ 7.6,
441
+ 7.7,
442
+ 7.8,
443
+ 7.9,
444
+ 8.0,
445
+ 8.1,
446
+ 8.2,
447
+ 8.3,
448
+ 8.4,
449
+ 8.5,
450
+ 8.6,
451
+ 8.7,
452
+ 8.8,
453
+ 8.9
454
+ ]
455
+ },
456
+ "criticalScoreType": {
457
+ "type": "number",
458
+ "enum": [
459
+ 9.0,
460
+ 9.1,
461
+ 9.2,
462
+ 9.3,
463
+ 9.4,
464
+ 9.5,
465
+ 9.6,
466
+ 9.7,
467
+ 9.8,
468
+ 9.9,
469
+ 10.0
470
+ ]
471
+ },
472
+ "severityType": {
473
+ "type": "string",
474
+ "enum": [
475
+ "NONE",
476
+ "LOW",
477
+ "MEDIUM",
478
+ "HIGH",
479
+ "CRITICAL"
480
+ ]
481
+ },
482
+ "noneSeverityType": {
483
+ "const": "NONE"
484
+ },
485
+ "lowSeverityType": {
486
+ "const": "LOW"
487
+ },
488
+ "mediumSeverityType": {
489
+ "const": "MEDIUM"
490
+ },
491
+ "highSeverityType": {
492
+ "const": "HIGH"
493
+ },
494
+ "criticalSeverityType": {
495
+ "const": "CRITICAL"
496
+ }
497
+ },
498
+ "properties": {
499
+ "version": {
500
+ "description": "CVSS Version",
501
+ "type": "string",
502
+ "enum": [
503
+ "4.0"
504
+ ]
505
+ },
506
+ "vectorString": {
507
+ "type": "string",
508
+ "pattern": "^CVSS:4[.]0/AV:[NALP]/AC:[LH]/AT:[NP]/PR:[NLH]/UI:[NPA]/VC:[HLN]/VI:[HLN]/VA:[HLN]/SC:[HLN]/SI:[HLN]/SA:[HLN](/E:[XAPU])?(/CR:[XHML])?(/IR:[XHML])?(/AR:[XHML])?(/MAV:[XNALP])?(/MAC:[XLH])?(/MAT:[XNP])?(/MPR:[XNLH])?(/MUI:[XNPA])?(/MVC:[XNLH])?(/MVI:[XNLH])?(/MVA:[XNLH])?(/MSC:[XNLH])?(/MSI:[XNLHS])?(/MSA:[XNLHS])?(/S:[XNP])?(/AU:[XNY])?(/R:[XAUI])?(/V:[XDC])?(/RE:[XLMH])?(/U:(X|Clear|Green|Amber|Red))?$"
509
+ },
510
+ "baseScore": {
511
+ "$ref": "#/definitions/scoreType"
512
+ },
513
+ "baseSeverity": {
514
+ "$ref": "#/definitions/severityType"
515
+ },
516
+ "attackVector": {
517
+ "$ref": "#/definitions/attackVectorType"
518
+ },
519
+ "attackComplexity": {
520
+ "$ref": "#/definitions/attackComplexityType"
521
+ },
522
+ "attackRequirements": {
523
+ "$ref": "#/definitions/attackRequirementsType"
524
+ },
525
+ "privilegesRequired": {
526
+ "$ref": "#/definitions/privilegesRequiredType"
527
+ },
528
+ "userInteraction": {
529
+ "$ref": "#/definitions/userInteractionType"
530
+ },
531
+ "vulnConfidentialityImpact": {
532
+ "$ref": "#/definitions/vulnCiaType"
533
+ },
534
+ "vulnIntegrityImpact": {
535
+ "$ref": "#/definitions/vulnCiaType"
536
+ },
537
+ "vulnAvailabilityImpact": {
538
+ "$ref": "#/definitions/vulnCiaType"
539
+ },
540
+ "subConfidentialityImpact": {
541
+ "$ref": "#/definitions/subCiaType"
542
+ },
543
+ "subIntegrityImpact": {
544
+ "$ref": "#/definitions/subCiaType"
545
+ },
546
+ "subAvailabilityImpact": {
547
+ "$ref": "#/definitions/subCiaType"
548
+ },
549
+ "exploitMaturity": {
550
+ "$ref": "#/definitions/exploitMaturityType"
551
+ },
552
+ "confidentialityRequirement": {
553
+ "$ref": "#/definitions/ciaRequirementType"
554
+ },
555
+ "integrityRequirement": {
556
+ "$ref": "#/definitions/ciaRequirementType"
557
+ },
558
+ "availabilityRequirement": {
559
+ "$ref": "#/definitions/ciaRequirementType"
560
+ },
561
+ "modifiedAttackVector": {
562
+ "$ref": "#/definitions/modifiedAttackVectorType"
563
+ },
564
+ "modifiedAttackComplexity": {
565
+ "$ref": "#/definitions/modifiedAttackComplexityType"
566
+ },
567
+ "modifiedAttackRequirements": {
568
+ "$ref": "#/definitions/modifiedAttackRequirementsType"
569
+ },
570
+ "modifiedPrivilegesRequired": {
571
+ "$ref": "#/definitions/modifiedPrivilegesRequiredType"
572
+ },
573
+ "modifiedUserInteraction": {
574
+ "$ref": "#/definitions/modifiedUserInteractionType"
575
+ },
576
+ "modifiedVulnConfidentialityImpact": {
577
+ "$ref": "#/definitions/modifiedVulnCiaType"
578
+ },
579
+ "modifiedVulnIntegrityImpact": {
580
+ "$ref": "#/definitions/modifiedVulnCiaType"
581
+ },
582
+ "modifiedVulnAvailabilityImpact": {
583
+ "$ref": "#/definitions/modifiedVulnCiaType"
584
+ },
585
+ "modifiedSubConfidentialityImpact": {
586
+ "$ref": "#/definitions/modifiedSubCType"
587
+ },
588
+ "modifiedSubIntegrityImpact": {
589
+ "$ref": "#/definitions/modifiedSubIaType"
590
+ },
591
+ "modifiedSubAvailabilityImpact": {
592
+ "$ref": "#/definitions/modifiedSubIaType"
593
+ },
594
+ "Safety": {
595
+ "$ref": "#/definitions/safetyType"
596
+ },
597
+ "Automatable": {
598
+ "$ref": "#/definitions/automatableType"
599
+ },
600
+ "Recovery": {
601
+ "$ref": "#/definitions/recoveryType"
602
+ },
603
+ "valueDensity": {
604
+ "$ref": "#/definitions/valueDensityType"
605
+ },
606
+ "vulnerabilityResponseEffort": {
607
+ "$ref": "#/definitions/vulnerabilityResponseEffortType"
608
+ },
609
+ "providerUrgency": {
610
+ "$ref": "#/definitions/providerUrgencyType"
611
+ }
612
+ },
613
+ "allOf": [
614
+ {
615
+ "anyOf": [
616
+ {
617
+ "properties": {
618
+ "baseScore": {
619
+ "$ref": "#/definitions/noneScoreType"
620
+ },
621
+ "baseSeverity": {
622
+ "$ref": "#/definitions/noneSeverityType"
623
+ }
624
+ }
625
+ },
626
+ {
627
+ "properties": {
628
+ "baseScore": {
629
+ "$ref": "#/definitions/lowScoreType"
630
+ },
631
+ "baseSeverity": {
632
+ "$ref": "#/definitions/lowSeverityType"
633
+ }
634
+ }
635
+ },
636
+ {
637
+ "properties": {
638
+ "baseScore": {
639
+ "$ref": "#/definitions/mediumScoreType"
640
+ },
641
+ "baseSeverity": {
642
+ "$ref": "#/definitions/mediumSeverityType"
643
+ }
644
+ }
645
+ },
646
+ {
647
+ "properties": {
648
+ "baseScore": {
649
+ "$ref": "#/definitions/highScoreType"
650
+ },
651
+ "baseSeverity": {
652
+ "$ref": "#/definitions/highSeverityType"
653
+ }
654
+ }
655
+ },
656
+ {
657
+ "properties": {
658
+ "baseScore": {
659
+ "$ref": "#/definitions/criticalScoreType"
660
+ },
661
+ "baseSeverity": {
662
+ "$ref": "#/definitions/criticalSeverityType"
663
+ }
664
+ }
665
+ }
666
+ ]
667
+ },
668
+ {
669
+ "anyOf": [
670
+ {
671
+ "properties": {
672
+ "threatScore": {
673
+ "$ref": "#/definitions/noneScoreType"
674
+ },
675
+ "threatSeverity": {
676
+ "$ref": "#/definitions/noneSeverityType"
677
+ }
678
+ }
679
+ },
680
+ {
681
+ "properties": {
682
+ "threatScore": {
683
+ "$ref": "#/definitions/lowScoreType"
684
+ },
685
+ "threatSeverity": {
686
+ "$ref": "#/definitions/lowSeverityType"
687
+ }
688
+ }
689
+ },
690
+ {
691
+ "properties": {
692
+ "threatScore": {
693
+ "$ref": "#/definitions/mediumScoreType"
694
+ },
695
+ "threatSeverity": {
696
+ "$ref": "#/definitions/mediumSeverityType"
697
+ }
698
+ }
699
+ },
700
+ {
701
+ "properties": {
702
+ "threatScore": {
703
+ "$ref": "#/definitions/highScoreType"
704
+ },
705
+ "threatSeverity": {
706
+ "$ref": "#/definitions/highSeverityType"
707
+ }
708
+ }
709
+ },
710
+ {
711
+ "properties": {
712
+ "threatScore": {
713
+ "$ref": "#/definitions/criticalScoreType"
714
+ },
715
+ "threatSeverity": {
716
+ "$ref": "#/definitions/criticalSeverityType"
717
+ }
718
+ }
719
+ }
720
+ ]
721
+ },
722
+ {
723
+ "anyOf": [
724
+ {
725
+ "properties": {
726
+ "environmentalScore": {
727
+ "$ref": "#/definitions/noneScoreType"
728
+ },
729
+ "environmentalSeverity": {
730
+ "$ref": "#/definitions/noneSeverityType"
731
+ }
732
+ }
733
+ },
734
+ {
735
+ "properties": {
736
+ "environmentalScore": {
737
+ "$ref": "#/definitions/lowScoreType"
738
+ },
739
+ "environmentalSeverity": {
740
+ "$ref": "#/definitions/lowSeverityType"
741
+ }
742
+ }
743
+ },
744
+ {
745
+ "properties": {
746
+ "environmentalScore": {
747
+ "$ref": "#/definitions/mediumScoreType"
748
+ },
749
+ "environmentalSeverity": {
750
+ "$ref": "#/definitions/mediumSeverityType"
751
+ }
752
+ }
753
+ },
754
+ {
755
+ "properties": {
756
+ "environmentalScore": {
757
+ "$ref": "#/definitions/highScoreType"
758
+ },
759
+ "environmentalSeverity": {
760
+ "$ref": "#/definitions/highSeverityType"
761
+ }
762
+ }
763
+ },
764
+ {
765
+ "properties": {
766
+ "environmentalScore": {
767
+ "$ref": "#/definitions/criticalScoreType"
768
+ },
769
+ "environmentalSeverity": {
770
+ "$ref": "#/definitions/criticalSeverityType"
771
+ }
772
+ }
773
+ }
774
+ ]
775
+ }
776
+ ],
777
+ "required": [
778
+ "version",
779
+ "vectorString",
780
+ "baseScore",
781
+ "baseSeverity"
782
+ ],
783
+ "additionalProperties": false
784
+ }