Skip to content

Commit 4066512

Browse files
Google APIscopybara-github
authored andcommitted
feat: A new message File is added
feat: A new field `files` is added to message `.grafeas.v1.DiscoveryOccurrence` feat: A new field `return_partial_success` is added to message `.grafeas.v1.ListOccurrencesRequest` feat: A new field `unreachable` is added to message `.grafeas.v1.ListOccurrencesResponse` feat: A new field `return_partial_success` is added to message `.grafeas.v1.ListNotesRequest` feat: A new field `unreachable` is added to message `.grafeas.v1.ListNotesResponse` feat: A new message `Risk` is added feat: A new message `CISAKnownExploitedVulnerabilities` is added feat: A new message `ExploitPredictionScoringSystem` is added feat: A new field `data` is added to message `.grafeas.v1.SecretOccurrence` feat: A new field `digest` is added to message `.grafeas.v1.SecretOccurrence` feat: A new value `SECRET_KIND_GCP_API_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GCP_OAUTH2_CLIENT_CREDENTIALS` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GCP_OAUTH2_ACCESS_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_ANTHROPIC_ADMIN_API_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_ANTHROPIC_API_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_AZURE_ACCESS_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_AZURE_IDENTITY_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_DOCKER_HUB_PERSONAL_ACCESS_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GITHUB_APP_REFRESH_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GITHUB_APP_SERVER_TO_SERVER_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GITHUB_APP_USER_TO_SERVER_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GITHUB_CLASSIC_PERSONAL_ACCESS_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GITHUB_FINE_GRAINED_PERSONAL_ACCESS_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_GITHUB_OAUTH_TOKEN` is added to enum `SecretKind` feat: A new value `SECRET_KIND_HUGGINGFACE_API_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_OPENAI_API_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_PERPLEXITY_API_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_STRIPE_SECRET_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_STRIPE_RESTRICTED_KEY` is added to enum `SecretKind` feat: A new value `SECRET_KIND_STRIPE_WEBHOOK_SECRET` is added to enum `SecretKind` feat: A new field `risk` is added to message `.grafeas.v1.VulnerabilityOccurrence` docs: A comment for enum value `SECRET_KIND_GCP_SERVICE_ACCOUNT_KEY` in enum `SecretKind` is changed PiperOrigin-RevId: 855331622
1 parent 1e3baa9 commit 4066512

File tree

7 files changed

+272
-4
lines changed

7 files changed

+272
-4
lines changed

grafeas/v1/BUILD.bazel

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ proto_library(
3838
"intoto_statement.proto",
3939
"package.proto",
4040
"provenance.proto",
41+
"risk.proto",
4142
"sbom.proto",
4243
"secret.proto",
4344
"severity.proto",

grafeas/v1/discovery.proto

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,4 +148,12 @@ message DiscoveryOccurrence {
148148

149149
// The status of an vulnerability attestation generation.
150150
VulnerabilityAttestation vulnerability_attestation = 10;
151+
152+
message File {
153+
string name = 1;
154+
map<string, string> digest = 2;
155+
}
156+
157+
// Files that make up the resource described by the occurrence.
158+
repeated File files = 11;
151159
}

grafeas/v1/grafeas.proto

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -402,6 +402,13 @@ message ListOccurrencesRequest {
402402

403403
// Token to provide to skip to a particular spot in the list.
404404
string page_token = 4;
405+
406+
// If set, the request will return all reachable Occurrences
407+
// and report all unreachable regions in the `unreachable` field in
408+
// the response.
409+
//
410+
// Only applicable for requests in the global region.
411+
bool return_partial_success = 5;
405412
}
406413

407414
// Response for listing occurrences.
@@ -412,6 +419,12 @@ message ListOccurrencesResponse {
412419
// `page_token` for the following request. An empty value means no more
413420
// results.
414421
string next_page_token = 2;
422+
// Unreachable regions. Populated for requests from the global region
423+
// when `return_partial_success` is set.
424+
//
425+
// Format: `projects/[PROJECT_ID]/locations/[LOCATION]`
426+
repeated string unreachable = 3
427+
[(google.api.field_behavior) = UNORDERED_LIST];
415428
}
416429

417430
// Request to delete an occurrence.
@@ -488,6 +501,13 @@ message ListNotesRequest {
488501

489502
// Token to provide to skip to a particular spot in the list.
490503
string page_token = 4;
504+
505+
// If set, the request will return all reachable Notes
506+
// and report all unreachable regions in the `unreachable` field in
507+
// the response.
508+
//
509+
// Only applicable for requests in the global region.
510+
bool return_partial_success = 5;
491511
}
492512

493513
// Response for listing notes.
@@ -498,6 +518,12 @@ message ListNotesResponse {
498518
// `page_token` for the following request. An empty value means no more
499519
// results.
500520
string next_page_token = 2;
521+
// Unreachable regions. Populated for requests from the global region
522+
// when `return_partial_success` is set.
523+
//
524+
// Format: `projects/[PROJECT_ID]/locations/[LOCATION]`
525+
repeated string unreachable = 3
526+
[(google.api.field_behavior) = UNORDERED_LIST];
501527
}
502528

503529
// Request to delete a note.

grafeas/v1/risk.proto

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
// Copyright 2025 The Grafeas Authors. All rights reserved.
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
syntax = "proto3";
16+
17+
package grafeas.v1;
18+
19+
option go_package = "google.golang.org/genproto/googleapis/grafeas/v1;grafeas";
20+
option java_multiple_files = true;
21+
option java_package = "io.grafeas.v1";
22+
option objc_class_prefix = "GRA";
23+
24+
message Risk {
25+
// CISA maintains the authoritative source of vulnerabilities that have been
26+
// exploited in the wild.
27+
CISAKnownExploitedVulnerabilities cisa_kev = 1;
28+
// The Exploit Prediction Scoring System (EPSS) estimates the likelihood
29+
// (probability) that a software vulnerability will be exploited in the wild.
30+
ExploitPredictionScoringSystem epss = 2;
31+
}
32+
33+
message CISAKnownExploitedVulnerabilities {
34+
// Whether the vulnerability is known to have been leveraged as part of a
35+
// ransomware campaign.
36+
string known_ransomware_campaign_use = 1;
37+
}
38+
39+
message ExploitPredictionScoringSystem {
40+
// The percentile of the current score, the proportion of all scored
41+
// vulnerabilities with the same or a lower EPSS score
42+
double percentile = 1;
43+
// The EPSS score representing the probability [0-1] of exploitation in the
44+
// wild in the next 30 days
45+
double score = 2;
46+
}

grafeas/v1/secret.proto

Lines changed: 52 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ syntax = "proto3";
1717
package grafeas.v1;
1818

1919
import "google/api/field_behavior.proto";
20+
import "google/protobuf/any.proto";
2021
import "google/protobuf/timestamp.proto";
2122
import "grafeas/v1/common.proto";
2223

@@ -39,6 +40,13 @@ message SecretOccurrence {
3940

4041
// Status of the secret.
4142
repeated SecretStatus statuses = 3 [(google.api.field_behavior) = OPTIONAL];
43+
44+
// Scan result of the secret.
45+
google.protobuf.Any data = 4;
46+
47+
// Hash value, typically a digest for the secret data, that allows unique
48+
// identification of a specific secret.
49+
Digest digest = 5;
4250
}
4351

4452
// The location of the secret.
@@ -84,7 +92,50 @@ enum SecretKind {
8492
SECRET_KIND_UNSPECIFIED = 0;
8593
// The secret kind is unknown.
8694
SECRET_KIND_UNKNOWN = 1;
87-
// A GCP service account key per:
95+
// A Google Cloud service account key per:
8896
// https://cloud.google.com/iam/docs/creating-managing-service-account-keys
8997
SECRET_KIND_GCP_SERVICE_ACCOUNT_KEY = 2;
98+
// A Google Cloud API key per:
99+
// https://cloud.google.com/docs/authentication/api-keys
100+
SECRET_KIND_GCP_API_KEY = 3;
101+
// A Google Cloud OAuth2 client credentials per:
102+
// https://developers.google.com/identity/protocols/oauth2
103+
SECRET_KIND_GCP_OAUTH2_CLIENT_CREDENTIALS = 4;
104+
// A Google Cloud OAuth2 access token per:
105+
// https://cloud.google.com/docs/authentication/token-types#access
106+
SECRET_KIND_GCP_OAUTH2_ACCESS_TOKEN = 5;
107+
// An Anthropic Admin API key.
108+
SECRET_KIND_ANTHROPIC_ADMIN_API_KEY = 6;
109+
// An Anthropic API key.
110+
SECRET_KIND_ANTHROPIC_API_KEY = 7;
111+
// An Azure access token.
112+
SECRET_KIND_AZURE_ACCESS_TOKEN = 8;
113+
// An Azure Identity Platform ID token.
114+
SECRET_KIND_AZURE_IDENTITY_TOKEN = 9;
115+
// A Docker Hub personal access token.
116+
SECRET_KIND_DOCKER_HUB_PERSONAL_ACCESS_TOKEN = 10;
117+
// A GitHub App refresh token.
118+
SECRET_KIND_GITHUB_APP_REFRESH_TOKEN = 11;
119+
// A GitHub App server-to-server token.
120+
SECRET_KIND_GITHUB_APP_SERVER_TO_SERVER_TOKEN = 12;
121+
// A GitHub App user-to-server token.
122+
SECRET_KIND_GITHUB_APP_USER_TO_SERVER_TOKEN = 13;
123+
// A GitHub personal access token (classic).
124+
SECRET_KIND_GITHUB_CLASSIC_PERSONAL_ACCESS_TOKEN = 14;
125+
// A GitHub fine-grained personal access token.
126+
SECRET_KIND_GITHUB_FINE_GRAINED_PERSONAL_ACCESS_TOKEN = 15;
127+
// A GitHub OAuth token.
128+
SECRET_KIND_GITHUB_OAUTH_TOKEN = 16;
129+
// A Hugging Face API key.
130+
SECRET_KIND_HUGGINGFACE_API_KEY = 17;
131+
// An OpenAI API key.
132+
SECRET_KIND_OPENAI_API_KEY = 18;
133+
// A Perplexity API key.
134+
SECRET_KIND_PERPLEXITY_API_KEY = 19;
135+
// A Stripe secret key.
136+
SECRET_KIND_STRIPE_SECRET_KEY = 20;
137+
// A Stripe restricted key.
138+
SECRET_KIND_STRIPE_RESTRICTED_KEY = 21;
139+
// A Stripe webhook secret.
140+
SECRET_KIND_STRIPE_WEBHOOK_SECRET = 22;
90141
}

0 commit comments

Comments
 (0)