Skip to content
This repository was archived by the owner on Jul 20, 2023. It is now read-only.

Commit d461de8

Browse files
feat: add new analysis status and cvss version fields (#187)
* feat: add new analysis status and cvss version fields PiperOrigin-RevId: 477815955 Source-Link: googleapis/googleapis@57e38f0 Source-Link: https://github.com/googleapis/googleapis-gen/commit/3a587e147521ff94c68a79163aa16855db9a7a8c Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiM2E1ODdlMTQ3NTIxZmY5NGM2OGE3OTE2M2FhMTY4NTVkYjlhN2E4YyJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 2b5fc77 commit d461de8

3 files changed

Lines changed: 34 additions & 1 deletion

File tree

protos/grafeas/v1/cvss.proto

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,3 +157,10 @@ message CVSS {
157157
IMPACT_NONE = 3;
158158
}
159159
}
160+
161+
// CVSS Version.
162+
enum CVSSVersion {
163+
CVSS_VERSION_UNSPECIFIED = 0;
164+
CVSS_VERSION_2 = 1;
165+
CVSS_VERSION_3 = 2;
166+
}

protos/grafeas/v1/discovery.proto

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,8 @@ message DiscoveryOccurrence {
5353
// Analysis status for a resource. Currently for initial analysis only (not
5454
// updated in continuous analysis).
5555
enum AnalysisStatus {
56+
option allow_alias = true;
57+
5658
// Unknown.
5759
ANALYSIS_STATUS_UNSPECIFIED = 0;
5860
// Resource is known but no action has been taken yet.
@@ -61,16 +63,30 @@ message DiscoveryOccurrence {
6163
SCANNING = 2;
6264
// Analysis has finished successfully.
6365
FINISHED_SUCCESS = 3;
66+
// Analysis has completed.
67+
COMPLETE = 3;
6468
// Analysis has finished unsuccessfully, the analysis itself is in a bad
6569
// state.
6670
FINISHED_FAILED = 4;
67-
// The resource is known not to be supported
71+
// The resource is known not to be supported.
6872
FINISHED_UNSUPPORTED = 5;
6973
}
7074

7175
// The status of discovery for the resource.
7276
AnalysisStatus analysis_status = 2;
7377

78+
// Indicates which analysis completed successfully. Multiple types of
79+
// analysis can be performed on a single resource.
80+
message AnalysisCompleted {
81+
repeated string analysis_type = 1;
82+
}
83+
84+
AnalysisCompleted analysis_completed = 7;
85+
86+
// Indicates any errors encountered during analysis of a resource. There
87+
// could be 0 or more of these errors.
88+
repeated google.rpc.Status analysis_error = 8;
89+
7490
// When an error is encountered this will contain a LocalizedMessage under
7591
// details to show to the user. The LocalizedMessage is output only and
7692
// populated by the API.

protos/grafeas/v1/vulnerability.proto

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,11 @@ message VulnerabilityNote {
148148
// upstream timestamp from the underlying information source - e.g. Ubuntu
149149
// security tracker.
150150
google.protobuf.Timestamp source_update_time = 6;
151+
152+
// CVSS version used to populate cvss_score and severity.
153+
grafeas.v1.CVSSVersion cvss_version = 7;
154+
155+
// Next free ID is 8.
151156
}
152157

153158
// An occurrence of a severity vulnerability on a resource.
@@ -238,4 +243,9 @@ message VulnerabilityOccurrence {
238243
// Output only. Whether at least one of the affected packages has a fix
239244
// available.
240245
bool fix_available = 9;
246+
247+
// Output only. CVSS version used to populate cvss_score and severity.
248+
grafeas.v1.CVSSVersion cvss_version = 11;
249+
250+
// Next free ID is 12.
241251
}

0 commit comments

Comments
 (0)