Skip to content

Commit cfa01b5

Browse files
Adding support vulnerability rejected timestamp along with unit tests
Signed-off-by: Steve Springett <[email protected]>
1 parent cfe1be0 commit cfa01b5

File tree

6 files changed

+19
-0
lines changed

6 files changed

+19
-0
lines changed

schema/bom-1.5.proto

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,8 @@ message Vulnerability {
528528
repeated VulnerabilityAffects affects = 17;
529529
// Specifies optional, custom, properties
530530
repeated Property properties = 18;
531+
// The date and time (timestamp) when the vulnerability record was rejected (if applicable).
532+
optional google.protobuf.Timestamp rejected = 19;
531533
}
532534

533535
message VulnerabilityReference {

schema/bom-1.5.schema.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1536,6 +1536,12 @@
15361536
"title": "Updated",
15371537
"description": "The date and time (timestamp) when the vulnerability record was last updated."
15381538
},
1539+
"rejected": {
1540+
"type": "string",
1541+
"format": "date-time",
1542+
"title": "Rejected",
1543+
"description": "The date and time (timestamp) when the vulnerability record was rejected (if applicable)."
1544+
},
15391545
"credits": {
15401546
"type": "object",
15411547
"title": "Credits",

schema/bom-1.5.xsd

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1880,6 +1880,11 @@ limitations under the License.
18801880
<xs:documentation>The date and time (timestamp) when the vulnerability record was last updated.</xs:documentation>
18811881
</xs:annotation>
18821882
</xs:element>
1883+
<xs:element name="rejected" type="xs:dateTime" minOccurs="0" maxOccurs="1">
1884+
<xs:annotation>
1885+
<xs:documentation>The date and time (timestamp) when the vulnerability record was rejected (if applicable).</xs:documentation>
1886+
</xs:annotation>
1887+
</xs:element>
18831888
<xs:element name="credits" minOccurs="0" maxOccurs="1">
18841889
<xs:annotation>
18851890
<xs:documentation>Individuals or organizations credited with the discovery of the vulnerability.</xs:documentation>

tools/src/test/resources/1.5/valid-vulnerability-1.5.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@
6363
"created": "2021-01-01T00:00:00.000Z",
6464
"published": "2021-01-01T00:00:00.000Z",
6565
"updated": "2021-01-01T00:00:00.000Z",
66+
"rejected": "2022-01-01T00:00:00.000Z",
6667
"credits": {
6768
"organizations": [
6869
{

tools/src/test/resources/1.5/valid-vulnerability-1.5.textproto

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ vulnerabilities {
5959
seconds: 3173618478
6060
nanos: 3
6161
}
62+
rejected: {
63+
seconds: 3173618478
64+
nanos: 3
65+
}
6266
credits: {
6367
organizations: {
6468
name: "Acme, Inc."

tools/src/test/resources/1.5/valid-vulnerability-1.5.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@
6464
<created>2021-01-01T00:00:00.000Z</created>
6565
<published>2021-01-01T00:00:00.000Z</published>
6666
<updated>2021-01-01T00:00:00.000Z</updated>
67+
<rejected>2022-01-01T00:00:00.000Z</rejected>
6768
<credits>
6869
<organizations>
6970
<organization>

0 commit comments

Comments
 (0)