Skip to content

Commit ed174d5

Browse files
committed
Update spec to OPEV-0015
This commit updates the SPEC to incorporate the changes approved in the OpenVEX Enhancement Proposal 0015: Expansion of the Vulnerability Field. Signed-off-by: Adolfo García Veytia (Puerco) <puerco@chainguard.dev>
1 parent 1abe3f7 commit ed174d5

File tree

1 file changed

+74
-11
lines changed

1 file changed

+74
-11
lines changed

OPENVEX-SPEC.md

Lines changed: 74 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@
44

55
OpenVEX is an implementation of Vulnerability Exploitability eXchange (VEX)
66
designed to be lightweight, and embeddable while meeting all requirements of
7-
a valid VEX implementation as defined in the [Minimum Requirements for VEX] document published on April 2023 as defined by the VEX Working Group coordinated by the [Cybersecurity & Infrastructure Security
8-
Agency](https://www.cisa.gov/) (CISA).
7+
a valid VEX implementation as defined in the [Minimum Requirements for VEX]
8+
document published on April 2023 as defined by the VEX Working Group coordinated
9+
by the [Cybersecurity & Infrastructure Security Agency](https://www.cisa.gov/) (CISA).
910

1011

1112
## The VEX Statement
@@ -133,7 +134,9 @@ Here is a sample of a minimal OpenVEX document:
133134
"version": 1,
134135
"statements": [
135136
{
136-
"vulnerability": "CVE-2023-12345",
137+
"vulnerability": {
138+
"name": "CVE-2023-12345"
139+
},
137140
"products": [
138141
{"@id": "pkg:apk/wolfi/git@2.39.0-r1?arch=armv7"},
139142
{"@id": "pkg:apk/wolfi/git@2.39.0-r1?arch=x86_64"}
@@ -172,7 +175,9 @@ A statement in an OpenVEX document looks like the following snippet:
172175
```json
173176
"statements": [
174177
{
175-
"vulnerability": "CVE-2023-12345",
178+
"vulnerability": {
179+
"name": "CVE-2023-12345"
180+
},
176181
"products": [
177182
{"@id": "pkg:apk/wolfi/git@2.39.0-r1?arch=armv7"},
178183
{"@id": "pkg:apk/wolfi/git@2.39.0-r1?arch=x86_64"}
@@ -190,8 +195,7 @@ The following table lists the fields of the OpenVEX statement struct.
190195
| --- | --- | --- |
191196
| @id || Optional IRI identifying the statement to make it externally referenceable. |
192197
| version || Optional integer representing the statement's version number. Defaults to zero, required when incremented. |
193-
| vulnerability || Vulnerability SHOULD use existing and well known identifiers. For example: [CVE](https://cve.mitre.org/), [OSV](https://osv.dev/), [GHSA](https://github.com/advisories), a supplier's vulnerability tracking system such as [RHSA](https://access.redhat.com/security/security-updates/#/) or a propietary system. It is expected that vulnerability identification systems are external to and maintained separately from VEX.<br>`vulnerability` MAY be an IRI and MAY be arbitrary, created by the VEX document `author`. |
194-
| vuln_description || Optional free-form text describing the vulnerability |
198+
| vulnerability || A struct identifying the vulnerability. See the [Vulnerability Data Structure] section below for the complete data structure reference. |
195199
| timestamp || Timestamp is the time at which the information expressed in the Statement was known to be true. Cascades down from the document, see [Inheritance](#Inheritance). |
196200
| last_updated || Timestamp when the statement was last updated. |
197201
| products || List of product structs that the statement applies to. See the [Product Data Structure] section below for the full description. While a product is required to have a complete statement, this field is optional as it can cascade down from the encapsulating document, see [Inheritance](#Inheritance). |
@@ -217,7 +221,9 @@ readable justification labels and optionally enrich the statement with an
217221

218222
```json
219223
{
220-
"vulnerability": "CVE-2023-12345",
224+
"vulnerability": {
225+
"name": "CVE-2023-12345",
226+
}
221227
"products": [
222228
{"@id": "pkg:apk/wolfi/product@1.23.0-r1?arch=armv7"}
223229
],
@@ -285,6 +291,49 @@ each itself a `component` subclass:
285291
| --- | --- | --- |
286292
| subcomponents || List of `component` structs describing the subcomponents subject of the VEX statement. |
287293

294+
### Vulnerability Data Structure
295+
296+
The vulnerability field in an OpenVEX statement takes the value of a struct that
297+
has the capability to enumerate the vulnerability name and other aliases that may
298+
be used to track it in different databases and systems.
299+
300+
As with the product field, the vulberability has an optional "@id" field that
301+
takes an IRI to make the field referenceable in the document and linkable from
302+
other linked data resources.
303+
304+
#### Example Vulnerability Struct
305+
306+
```json
307+
{
308+
"vulnerability": {
309+
"@id": "https://nvd.nist.gov/vuln/detail/CVE-2019-17571",
310+
"name": "CVE-2019-17571",
311+
"description": "The product deserializes untrusted data without sufficiently verifying that the resulting data will be valid.",
312+
"aliases": [
313+
"GHSA-2qrg-x229-3v8q",
314+
"openSUSE-SU-2020:0051-1",
315+
"SNYK-RHEL7-LOG4J-1472071",
316+
"DSA-4686-1",
317+
"USN-4495",
318+
"DLA-2065-1",
319+
],
320+
}
321+
}
322+
```
323+
324+
#### Vulnerability Struct Fields
325+
326+
The only required field in the vulnerability field is `name`, the main identifier
327+
of the vulnerability. Note that it is not an error to include the identifier used
328+
in the `name` field in the list of aliases.
329+
330+
| Field | Required | Description |
331+
| --- | --- | --- |
332+
| @id || An Internationalized Resource Identifier (IRI) identifying the struct. Used to reference and link the vulnerability data. |
333+
| name || A string with the main identifier used to name the vulnerability. |
334+
| description || Optional free form text describing the vulnerability. |
335+
| aliases | x | A list of strings enumerating other names under which the vulnerability may be known. |
336+
288337
### Status Labels
289338

290339
Status labels inform the impact of a vulnerability in the products listed
@@ -394,7 +443,9 @@ example, the sole statement has its timestamp data derived from the document:
394443
"version": 1,
395444
"statements": [
396445
{
397-
"vulnerability": "CVE-2023-12345",
446+
"vulnerability": {
447+
"name": "CVE-2023-12345"
448+
},
398449
"products": [
399450
{"@id": "pkg:apk/wolfi/git@2.39.0-r1?arch=armv7"}
400451
],
@@ -420,14 +471,18 @@ to avoid duplication:
420471
"statements": [
421472
{
422473
"timestamp": "2023-01-08T18:02:03-06:00",
423-
"vulnerability": "CVE-2023-12345",
474+
"vulnerability": {
475+
"name": "CVE-2023-12345"
476+
},
424477
"products": [
425478
{"@id": "pkg:apk/wolfi/git@2.39.0-r1?arch=armv7"},
426479
],
427480
"status": "under_investigation"
428481
},
429482
{
430-
"vulnerability": "CVE-2023-12345",
483+
"vulnerability": {
484+
"name": "CVE-2023-12345"
485+
},
431486
"products": [
432487
{"@id": "pkg:apk/wolfi/git@2.39.0-r1?arch=armv7"}
433488
],
@@ -509,7 +564,14 @@ the project could issue an OpenVEX document as follows:
509564
"version": 1,
510565
"statements": [
511566
{
512-
"vulnerability": "CVE-2021-44228",
567+
"vulnerability": {
568+
"@id": "https://nvd.nist.gov/vuln/detail/CVE-2021-44228",
569+
"name": "CVE-2021-44228",
570+
"description": "Remote code injection in Log4j",
571+
"aliases": [
572+
"GHSA-jfh8-c2jp-5v3q"
573+
]
574+
},
513575
"products": [
514576
{
515577
"@id": "pkg:maven/org.springframework.boot/spring-boot@2.6.0-M3",
@@ -536,6 +598,7 @@ alert and dashboards could present users with the official guidance from the pro
536598

537599
| Date | Revision |
538600
| --- | --- |
601+
| 2023-07-18 | Updated spec to reflect changes in [OPEV-0015: Expansion of the Vulnerability Field](https://github.com/openvex/community/blob/main/enhancements/opev-0015.md) |
539602
| 2023-07-18 | Updated spec to reflect changes in [OPEV-0014: Expansion of the VEX Product Field](https://github.com/openvex/community/blob/main/enhancements/opev-0014.md) |
540603
| 2023-07-18 | Bumped version of the spec to v0.0.2 after update to meet the VEX-WG doc. |
541604
| 2023-06-01 | Removed supplier from the document level (following VEX-WG doc). |

0 commit comments

Comments
 (0)