Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1 | <html><body> |
| 2 | <style> |
| 3 | |
| 4 | body, h1, h2, h3, div, span, p, pre, a { |
| 5 | margin: 0; |
| 6 | padding: 0; |
| 7 | border: 0; |
| 8 | font-weight: inherit; |
| 9 | font-style: inherit; |
| 10 | font-size: 100%; |
| 11 | font-family: inherit; |
| 12 | vertical-align: baseline; |
| 13 | } |
| 14 | |
| 15 | body { |
| 16 | font-size: 13px; |
| 17 | padding: 1em; |
| 18 | } |
| 19 | |
| 20 | h1 { |
| 21 | font-size: 26px; |
| 22 | margin-bottom: 1em; |
| 23 | } |
| 24 | |
| 25 | h2 { |
| 26 | font-size: 24px; |
| 27 | margin-bottom: 1em; |
| 28 | } |
| 29 | |
| 30 | h3 { |
| 31 | font-size: 20px; |
| 32 | margin-bottom: 1em; |
| 33 | margin-top: 1em; |
| 34 | } |
| 35 | |
| 36 | pre, code { |
| 37 | line-height: 1.5; |
| 38 | font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; |
| 39 | } |
| 40 | |
| 41 | pre { |
| 42 | margin-top: 0.5em; |
| 43 | } |
| 44 | |
| 45 | h1, h2, h3, p { |
| 46 | font-family: Arial, sans serif; |
| 47 | } |
| 48 | |
| 49 | h1, h2, h3 { |
| 50 | border-bottom: solid #CCC 1px; |
| 51 | } |
| 52 | |
| 53 | .toc_element { |
| 54 | margin-top: 0.5em; |
| 55 | } |
| 56 | |
| 57 | .firstline { |
| 58 | margin-left: 2 em; |
| 59 | } |
| 60 | |
| 61 | .method { |
| 62 | margin-top: 1em; |
| 63 | border: solid 1px #CCC; |
| 64 | padding: 1em; |
| 65 | background: #EEE; |
| 66 | } |
| 67 | |
| 68 | .details { |
| 69 | font-weight: bold; |
| 70 | font-size: 14px; |
| 71 | } |
| 72 | |
| 73 | </style> |
| 74 | |
| 75 | <h1><a href="containeranalysis_v1beta1.html">Container Analysis API</a> . <a href="containeranalysis_v1beta1.projects.html">projects</a> . <a href="containeranalysis_v1beta1.projects.occurrences.html">occurrences</a></h1> |
| 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 78 | <code><a href="#batchCreate">batchCreate(parent, body=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 79 | <p class="firstline">Creates new occurrences in batch.</p> |
| 80 | <p class="toc_element"> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 81 | <code><a href="#close">close()</a></code></p> |
| 82 | <p class="firstline">Close httplib2 connections.</p> |
| 83 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 84 | <code><a href="#create">create(parent, body=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 85 | <p class="firstline">Creates a new occurrence.</p> |
| 86 | <p class="toc_element"> |
| 87 | <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 88 | <p class="firstline">Deletes the specified occurrence. For example, use this method to delete an occurrence when the occurrence is no longer applicable for the given resource.</p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 89 | <p class="toc_element"> |
| 90 | <code><a href="#get">get(name, x__xgafv=None)</a></code></p> |
| 91 | <p class="firstline">Gets the specified occurrence.</p> |
| 92 | <p class="toc_element"> |
| 93 | <code><a href="#getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</a></code></p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 94 | <p class="firstline">Gets the access control policy for a note or an occurrence resource. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.</p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 95 | <p class="toc_element"> |
| 96 | <code><a href="#getNotes">getNotes(name, x__xgafv=None)</a></code></p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 97 | <p class="firstline">Gets the note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.</p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 98 | <p class="toc_element"> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 99 | <code><a href="#getVulnerabilitySummary">getVulnerabilitySummary(parent, filter=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 100 | <p class="firstline">Gets a summary of the number and severity of occurrences.</p> |
| 101 | <p class="toc_element"> |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 102 | <code><a href="#list">list(parent, pageToken=None, pageSize=None, filter=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 103 | <p class="firstline">Lists occurrences for the specified project.</p> |
| 104 | <p class="toc_element"> |
| 105 | <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> |
| 106 | <p class="firstline">Retrieves the next page of results.</p> |
| 107 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 108 | <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 109 | <p class="firstline">Updates the specified occurrence.</p> |
| 110 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 111 | <code><a href="#setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</a></code></p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 112 | <p class="firstline">Sets the access control policy on the specified note or occurrence. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or an occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.</p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 113 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 114 | <code><a href="#testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</a></code></p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 115 | <p class="firstline">Returns the permissions that a caller has on the specified note or occurrence. Requires list permission on the project (for example, `containeranalysis.notes.list`). The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences.</p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 116 | <h3>Method Details</h3> |
| 117 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 118 | <code class="details" id="batchCreate">batchCreate(parent, body=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 119 | <pre>Creates new occurrences in batch. |
| 120 | |
| 121 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 122 | parent: string, Required. The name of the project in the form of `projects/[PROJECT_ID]`, under which the occurrences are to be created. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 123 | body: object, The request body. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 124 | The object takes the form of: |
| 125 | |
| 126 | { # Request to create occurrences in batch. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 127 | "occurrences": [ # Required. The occurrences to create. Max allowed length is 1000. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 128 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 129 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 130 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 131 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 132 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 133 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 134 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 135 | "package": "A String", # Required. The package being described. |
| 136 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 137 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 138 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 139 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 140 | "revision": "A String", # The iteration of the package build from the above version. |
| 141 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 142 | }, |
| 143 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 144 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 145 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 146 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 147 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 148 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 149 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 150 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 151 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 152 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 153 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 154 | }, |
| 155 | }, |
| 156 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 157 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 158 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 159 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 160 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 161 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 162 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 163 | }, |
| 164 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 165 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 166 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 167 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 168 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 169 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 170 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 171 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 172 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 173 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 174 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 175 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 176 | "builtArtifacts": [ # Output of the build. |
| 177 | { # Artifact describes a build product. |
| 178 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 179 | "A String", |
| 180 | ], |
| 181 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 182 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 183 | }, |
| 184 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 185 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 186 | "a_key": "A String", |
| 187 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 188 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 189 | "commands": [ # Commands requested by the build. |
| 190 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 191 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 192 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 193 | "A String", |
| 194 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 195 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 196 | "args": [ # Command-line arguments used when executing this command. |
| 197 | "A String", |
| 198 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 199 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 200 | "env": [ # Environment variables set before running this command. |
| 201 | "A String", |
| 202 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 203 | }, |
| 204 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 205 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 206 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 207 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 208 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 209 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 210 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 211 | "name": "A String", # The alias name. |
| 212 | "kind": "A String", # The alias kind. |
| 213 | }, |
| 214 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 215 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 216 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 217 | }, |
| 218 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 219 | "url": "A String", # Git repository URL. |
| 220 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 221 | }, |
| 222 | "labels": { # Labels with user defined metadata. |
| 223 | "a_key": "A String", |
| 224 | }, |
| 225 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 226 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 227 | "name": "A String", # The alias name. |
| 228 | "kind": "A String", # The alias kind. |
| 229 | }, |
| 230 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 231 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 232 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 233 | "projectId": "A String", # The ID of the project. |
| 234 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 235 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 236 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 237 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 238 | }, |
| 239 | }, |
| 240 | ], |
| 241 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 242 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 243 | "fileHash": [ # Required. Collection of file hashes. |
| 244 | { # Container message for hash values. |
| 245 | "type": "A String", # Required. The type of hash that was performed. |
| 246 | "value": "A String", # Required. The hash value. |
| 247 | }, |
| 248 | ], |
| 249 | }, |
| 250 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 251 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 252 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 253 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 254 | "name": "A String", # The alias name. |
| 255 | "kind": "A String", # The alias kind. |
| 256 | }, |
| 257 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 258 | "revisionId": "A String", # A revision (commit) ID. |
| 259 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 260 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 261 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 262 | "url": "A String", # Git repository URL. |
| 263 | "revisionId": "A String", # Git commit hash. |
| 264 | }, |
| 265 | "labels": { # Labels with user defined metadata. |
| 266 | "a_key": "A String", |
| 267 | }, |
| 268 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 269 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 270 | "name": "A String", # The alias name. |
| 271 | "kind": "A String", # The alias kind. |
| 272 | }, |
| 273 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 274 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 275 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 276 | "projectId": "A String", # The ID of the project. |
| 277 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 278 | }, |
| 279 | }, |
| 280 | "revisionId": "A String", # A revision ID. |
| 281 | }, |
| 282 | }, |
| 283 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 284 | }, |
| 285 | "createTime": "A String", # Time at which the build was created. |
| 286 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 287 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 288 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 289 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 290 | }, |
| 291 | }, |
| 292 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 293 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 294 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 295 | "A String", |
| 296 | ], |
| 297 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 298 | "platform": "A String", # Platform hosting this deployment. |
| 299 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 300 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 301 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 302 | "config": "A String", # Configuration used to create this deployment. |
| 303 | }, |
| 304 | }, |
| 305 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 306 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 307 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 308 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 309 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 310 | "A String", |
| 311 | ], |
| 312 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 313 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 314 | }, |
| 315 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 316 | { # Layer holds metadata specific to a layer of a Docker image. |
| 317 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 318 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 319 | }, |
| 320 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 321 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 322 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 323 | }, |
| 324 | }, |
| 325 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 326 | "signatures": [ |
| 327 | { # A signature object consists of the KeyID used and the signature itself. |
| 328 | "sig": "A String", |
| 329 | "keyid": "A String", |
| 330 | }, |
| 331 | ], |
| 332 | "signed": { # This corresponds to an in-toto link. |
| 333 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 334 | "customValues": { |
| 335 | "a_key": "A String", |
| 336 | }, |
| 337 | }, |
| 338 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 339 | "A String", |
| 340 | ], |
| 341 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 342 | "customValues": { |
| 343 | "a_key": "A String", |
| 344 | }, |
| 345 | }, |
| 346 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 347 | { |
| 348 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 349 | "sha256": "A String", |
| 350 | }, |
| 351 | "resourceUri": "A String", |
| 352 | }, |
| 353 | ], |
| 354 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 355 | { |
| 356 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 357 | "sha256": "A String", |
| 358 | }, |
| 359 | "resourceUri": "A String", |
| 360 | }, |
| 361 | ], |
| 362 | }, |
| 363 | }, |
| 364 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 365 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 366 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 367 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 368 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 369 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 370 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 371 | { |
| 372 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 373 | }, |
| 374 | ], |
| 375 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 376 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 377 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 378 | }, |
| 379 | }, |
| 380 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 381 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 382 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 383 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 384 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 385 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 386 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 387 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 388 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 389 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 390 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 391 | }, |
| 392 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 393 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 394 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 395 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 396 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 397 | }, |
| 398 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 399 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 400 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 401 | "type": "A String", # Required. The type of hash that was performed. |
| 402 | "value": "A String", # Required. The hash value. |
| 403 | }, |
| 404 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 405 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 406 | }, |
| 407 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 408 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 409 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 410 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 411 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 412 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 413 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 414 | "revision": "A String", # The iteration of the package build from the above version. |
| 415 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 416 | }, |
| 417 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 418 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 419 | }, |
| 420 | ], |
| 421 | "name": "A String", # Output only. The name of the installed package. |
| 422 | }, |
| 423 | }, |
| 424 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 425 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 426 | }, |
| 427 | ], |
| 428 | } |
| 429 | |
| 430 | x__xgafv: string, V1 error format. |
| 431 | Allowed values |
| 432 | 1 - v1 error format |
| 433 | 2 - v2 error format |
| 434 | |
| 435 | Returns: |
| 436 | An object of the form: |
| 437 | |
| 438 | { # Response for creating occurrences in batch. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 439 | "occurrences": [ # The occurrences that were created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 440 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 441 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 442 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 443 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 444 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 445 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 446 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 447 | "package": "A String", # Required. The package being described. |
| 448 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 449 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 450 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 451 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 452 | "revision": "A String", # The iteration of the package build from the above version. |
| 453 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 454 | }, |
| 455 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 456 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 457 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 458 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 459 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 460 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 461 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 462 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 463 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 464 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 465 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 466 | }, |
| 467 | }, |
| 468 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 469 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 470 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 471 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 472 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 473 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 474 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 475 | }, |
| 476 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 477 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 478 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 479 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 480 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 481 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 482 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 483 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 484 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 485 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 486 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 487 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 488 | "builtArtifacts": [ # Output of the build. |
| 489 | { # Artifact describes a build product. |
| 490 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 491 | "A String", |
| 492 | ], |
| 493 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 494 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 495 | }, |
| 496 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 497 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 498 | "a_key": "A String", |
| 499 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 500 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 501 | "commands": [ # Commands requested by the build. |
| 502 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 503 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 504 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 505 | "A String", |
| 506 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 507 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 508 | "args": [ # Command-line arguments used when executing this command. |
| 509 | "A String", |
| 510 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 511 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 512 | "env": [ # Environment variables set before running this command. |
| 513 | "A String", |
| 514 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 515 | }, |
| 516 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 517 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 518 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 519 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 520 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 521 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 522 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 523 | "name": "A String", # The alias name. |
| 524 | "kind": "A String", # The alias kind. |
| 525 | }, |
| 526 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 527 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 528 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 529 | }, |
| 530 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 531 | "url": "A String", # Git repository URL. |
| 532 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 533 | }, |
| 534 | "labels": { # Labels with user defined metadata. |
| 535 | "a_key": "A String", |
| 536 | }, |
| 537 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 538 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 539 | "name": "A String", # The alias name. |
| 540 | "kind": "A String", # The alias kind. |
| 541 | }, |
| 542 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 543 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 544 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 545 | "projectId": "A String", # The ID of the project. |
| 546 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 547 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 548 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 549 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 550 | }, |
| 551 | }, |
| 552 | ], |
| 553 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 554 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 555 | "fileHash": [ # Required. Collection of file hashes. |
| 556 | { # Container message for hash values. |
| 557 | "type": "A String", # Required. The type of hash that was performed. |
| 558 | "value": "A String", # Required. The hash value. |
| 559 | }, |
| 560 | ], |
| 561 | }, |
| 562 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 563 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 564 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 565 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 566 | "name": "A String", # The alias name. |
| 567 | "kind": "A String", # The alias kind. |
| 568 | }, |
| 569 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 570 | "revisionId": "A String", # A revision (commit) ID. |
| 571 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 572 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 573 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 574 | "url": "A String", # Git repository URL. |
| 575 | "revisionId": "A String", # Git commit hash. |
| 576 | }, |
| 577 | "labels": { # Labels with user defined metadata. |
| 578 | "a_key": "A String", |
| 579 | }, |
| 580 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 581 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 582 | "name": "A String", # The alias name. |
| 583 | "kind": "A String", # The alias kind. |
| 584 | }, |
| 585 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 586 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 587 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 588 | "projectId": "A String", # The ID of the project. |
| 589 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 590 | }, |
| 591 | }, |
| 592 | "revisionId": "A String", # A revision ID. |
| 593 | }, |
| 594 | }, |
| 595 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 596 | }, |
| 597 | "createTime": "A String", # Time at which the build was created. |
| 598 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 599 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 600 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 601 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 602 | }, |
| 603 | }, |
| 604 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 605 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 606 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 607 | "A String", |
| 608 | ], |
| 609 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 610 | "platform": "A String", # Platform hosting this deployment. |
| 611 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 612 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 613 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 614 | "config": "A String", # Configuration used to create this deployment. |
| 615 | }, |
| 616 | }, |
| 617 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 618 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 619 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 620 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 621 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 622 | "A String", |
| 623 | ], |
| 624 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 625 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 626 | }, |
| 627 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 628 | { # Layer holds metadata specific to a layer of a Docker image. |
| 629 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 630 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 631 | }, |
| 632 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 633 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 634 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 635 | }, |
| 636 | }, |
| 637 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 638 | "signatures": [ |
| 639 | { # A signature object consists of the KeyID used and the signature itself. |
| 640 | "sig": "A String", |
| 641 | "keyid": "A String", |
| 642 | }, |
| 643 | ], |
| 644 | "signed": { # This corresponds to an in-toto link. |
| 645 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 646 | "customValues": { |
| 647 | "a_key": "A String", |
| 648 | }, |
| 649 | }, |
| 650 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 651 | "A String", |
| 652 | ], |
| 653 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 654 | "customValues": { |
| 655 | "a_key": "A String", |
| 656 | }, |
| 657 | }, |
| 658 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 659 | { |
| 660 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 661 | "sha256": "A String", |
| 662 | }, |
| 663 | "resourceUri": "A String", |
| 664 | }, |
| 665 | ], |
| 666 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 667 | { |
| 668 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 669 | "sha256": "A String", |
| 670 | }, |
| 671 | "resourceUri": "A String", |
| 672 | }, |
| 673 | ], |
| 674 | }, |
| 675 | }, |
| 676 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 677 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 678 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 679 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 680 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 681 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 682 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 683 | { |
| 684 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 685 | }, |
| 686 | ], |
| 687 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 688 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 689 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 690 | }, |
| 691 | }, |
| 692 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 693 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 694 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 695 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 696 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 697 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 698 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 699 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 700 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 701 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 702 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 703 | }, |
| 704 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 705 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 706 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 707 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 708 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 709 | }, |
| 710 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 711 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 712 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 713 | "type": "A String", # Required. The type of hash that was performed. |
| 714 | "value": "A String", # Required. The hash value. |
| 715 | }, |
| 716 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 717 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 718 | }, |
| 719 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 720 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 721 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 722 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 723 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 724 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 725 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 726 | "revision": "A String", # The iteration of the package build from the above version. |
| 727 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 728 | }, |
| 729 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 730 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 731 | }, |
| 732 | ], |
| 733 | "name": "A String", # Output only. The name of the installed package. |
| 734 | }, |
| 735 | }, |
| 736 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 737 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 738 | }, |
| 739 | ], |
| 740 | }</pre> |
| 741 | </div> |
| 742 | |
| 743 | <div class="method"> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 744 | <code class="details" id="close">close()</code> |
| 745 | <pre>Close httplib2 connections.</pre> |
| 746 | </div> |
| 747 | |
| 748 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 749 | <code class="details" id="create">create(parent, body=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 750 | <pre>Creates a new occurrence. |
| 751 | |
| 752 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 753 | parent: string, Required. The name of the project in the form of `projects/[PROJECT_ID]`, under which the occurrence is to be created. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 754 | body: object, The request body. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 755 | The object takes the form of: |
| 756 | |
| 757 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 758 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 759 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 760 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 761 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 762 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 763 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 764 | "package": "A String", # Required. The package being described. |
| 765 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 766 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 767 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 768 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 769 | "revision": "A String", # The iteration of the package build from the above version. |
| 770 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 771 | }, |
| 772 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 773 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 774 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 775 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 776 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 777 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 778 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 779 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 780 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 781 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 782 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 783 | }, |
| 784 | }, |
| 785 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 786 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 787 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 788 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 789 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 790 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 791 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 792 | }, |
| 793 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 794 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 795 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 796 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 797 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 798 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 799 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 800 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 801 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 802 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 803 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 804 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 805 | "builtArtifacts": [ # Output of the build. |
| 806 | { # Artifact describes a build product. |
| 807 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 808 | "A String", |
| 809 | ], |
| 810 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 811 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 812 | }, |
| 813 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 814 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 815 | "a_key": "A String", |
| 816 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 817 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 818 | "commands": [ # Commands requested by the build. |
| 819 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 820 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 821 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 822 | "A String", |
| 823 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 824 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 825 | "args": [ # Command-line arguments used when executing this command. |
| 826 | "A String", |
| 827 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 828 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 829 | "env": [ # Environment variables set before running this command. |
| 830 | "A String", |
| 831 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 832 | }, |
| 833 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 834 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 835 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 836 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 837 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 838 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 839 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 840 | "name": "A String", # The alias name. |
| 841 | "kind": "A String", # The alias kind. |
| 842 | }, |
| 843 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 844 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 845 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 846 | }, |
| 847 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 848 | "url": "A String", # Git repository URL. |
| 849 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 850 | }, |
| 851 | "labels": { # Labels with user defined metadata. |
| 852 | "a_key": "A String", |
| 853 | }, |
| 854 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 855 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 856 | "name": "A String", # The alias name. |
| 857 | "kind": "A String", # The alias kind. |
| 858 | }, |
| 859 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 860 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 861 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 862 | "projectId": "A String", # The ID of the project. |
| 863 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 864 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 865 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 866 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 867 | }, |
| 868 | }, |
| 869 | ], |
| 870 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 871 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 872 | "fileHash": [ # Required. Collection of file hashes. |
| 873 | { # Container message for hash values. |
| 874 | "type": "A String", # Required. The type of hash that was performed. |
| 875 | "value": "A String", # Required. The hash value. |
| 876 | }, |
| 877 | ], |
| 878 | }, |
| 879 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 880 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 881 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 882 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 883 | "name": "A String", # The alias name. |
| 884 | "kind": "A String", # The alias kind. |
| 885 | }, |
| 886 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 887 | "revisionId": "A String", # A revision (commit) ID. |
| 888 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 889 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 890 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 891 | "url": "A String", # Git repository URL. |
| 892 | "revisionId": "A String", # Git commit hash. |
| 893 | }, |
| 894 | "labels": { # Labels with user defined metadata. |
| 895 | "a_key": "A String", |
| 896 | }, |
| 897 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 898 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 899 | "name": "A String", # The alias name. |
| 900 | "kind": "A String", # The alias kind. |
| 901 | }, |
| 902 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 903 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 904 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 905 | "projectId": "A String", # The ID of the project. |
| 906 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 907 | }, |
| 908 | }, |
| 909 | "revisionId": "A String", # A revision ID. |
| 910 | }, |
| 911 | }, |
| 912 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 913 | }, |
| 914 | "createTime": "A String", # Time at which the build was created. |
| 915 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 916 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 917 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 918 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 919 | }, |
| 920 | }, |
| 921 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 922 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 923 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 924 | "A String", |
| 925 | ], |
| 926 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 927 | "platform": "A String", # Platform hosting this deployment. |
| 928 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 929 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 930 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 931 | "config": "A String", # Configuration used to create this deployment. |
| 932 | }, |
| 933 | }, |
| 934 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 935 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 936 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 937 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 938 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 939 | "A String", |
| 940 | ], |
| 941 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 942 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 943 | }, |
| 944 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 945 | { # Layer holds metadata specific to a layer of a Docker image. |
| 946 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 947 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 948 | }, |
| 949 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 950 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 951 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 952 | }, |
| 953 | }, |
| 954 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 955 | "signatures": [ |
| 956 | { # A signature object consists of the KeyID used and the signature itself. |
| 957 | "sig": "A String", |
| 958 | "keyid": "A String", |
| 959 | }, |
| 960 | ], |
| 961 | "signed": { # This corresponds to an in-toto link. |
| 962 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 963 | "customValues": { |
| 964 | "a_key": "A String", |
| 965 | }, |
| 966 | }, |
| 967 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 968 | "A String", |
| 969 | ], |
| 970 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 971 | "customValues": { |
| 972 | "a_key": "A String", |
| 973 | }, |
| 974 | }, |
| 975 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 976 | { |
| 977 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 978 | "sha256": "A String", |
| 979 | }, |
| 980 | "resourceUri": "A String", |
| 981 | }, |
| 982 | ], |
| 983 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 984 | { |
| 985 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 986 | "sha256": "A String", |
| 987 | }, |
| 988 | "resourceUri": "A String", |
| 989 | }, |
| 990 | ], |
| 991 | }, |
| 992 | }, |
| 993 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 994 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 995 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 996 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 997 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 998 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 999 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 1000 | { |
| 1001 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 1002 | }, |
| 1003 | ], |
| 1004 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 1005 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 1006 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1007 | }, |
| 1008 | }, |
| 1009 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 1010 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 1011 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1012 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1013 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 1014 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1015 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1016 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1017 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1018 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1019 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1020 | }, |
| 1021 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1022 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1023 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 1024 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1025 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1026 | }, |
| 1027 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1028 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 1029 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 1030 | "type": "A String", # Required. The type of hash that was performed. |
| 1031 | "value": "A String", # Required. The hash value. |
| 1032 | }, |
| 1033 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 1034 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 1035 | }, |
| 1036 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 1037 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 1038 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 1039 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 1040 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 1041 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1042 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1043 | "revision": "A String", # The iteration of the package build from the above version. |
| 1044 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1045 | }, |
| 1046 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 1047 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 1048 | }, |
| 1049 | ], |
| 1050 | "name": "A String", # Output only. The name of the installed package. |
| 1051 | }, |
| 1052 | }, |
| 1053 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1054 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1055 | } |
| 1056 | |
| 1057 | x__xgafv: string, V1 error format. |
| 1058 | Allowed values |
| 1059 | 1 - v1 error format |
| 1060 | 2 - v2 error format |
| 1061 | |
| 1062 | Returns: |
| 1063 | An object of the form: |
| 1064 | |
| 1065 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1066 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1067 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 1068 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1069 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 1070 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1071 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 1072 | "package": "A String", # Required. The package being described. |
| 1073 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 1074 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 1075 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1076 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1077 | "revision": "A String", # The iteration of the package build from the above version. |
| 1078 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1079 | }, |
| 1080 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1081 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 1082 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1083 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1084 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 1085 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 1086 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1087 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1088 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1089 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1090 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1091 | }, |
| 1092 | }, |
| 1093 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1094 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1095 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1096 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 1097 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1098 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1099 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1100 | }, |
| 1101 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1102 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 1103 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 1104 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1105 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1106 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 1107 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1108 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1109 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1110 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1111 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1112 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1113 | "builtArtifacts": [ # Output of the build. |
| 1114 | { # Artifact describes a build product. |
| 1115 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 1116 | "A String", |
| 1117 | ], |
| 1118 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 1119 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 1120 | }, |
| 1121 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1122 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1123 | "a_key": "A String", |
| 1124 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1125 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1126 | "commands": [ # Commands requested by the build. |
| 1127 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1128 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1129 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 1130 | "A String", |
| 1131 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1132 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1133 | "args": [ # Command-line arguments used when executing this command. |
| 1134 | "A String", |
| 1135 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1136 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1137 | "env": [ # Environment variables set before running this command. |
| 1138 | "A String", |
| 1139 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1140 | }, |
| 1141 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1142 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1143 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1144 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 1145 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 1146 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1147 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1148 | "name": "A String", # The alias name. |
| 1149 | "kind": "A String", # The alias kind. |
| 1150 | }, |
| 1151 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 1152 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1153 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 1154 | }, |
| 1155 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 1156 | "url": "A String", # Git repository URL. |
| 1157 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1158 | }, |
| 1159 | "labels": { # Labels with user defined metadata. |
| 1160 | "a_key": "A String", |
| 1161 | }, |
| 1162 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1163 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1164 | "name": "A String", # The alias name. |
| 1165 | "kind": "A String", # The alias kind. |
| 1166 | }, |
| 1167 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1168 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1169 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 1170 | "projectId": "A String", # The ID of the project. |
| 1171 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 1172 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1173 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1174 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1175 | }, |
| 1176 | }, |
| 1177 | ], |
| 1178 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 1179 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1180 | "fileHash": [ # Required. Collection of file hashes. |
| 1181 | { # Container message for hash values. |
| 1182 | "type": "A String", # Required. The type of hash that was performed. |
| 1183 | "value": "A String", # Required. The hash value. |
| 1184 | }, |
| 1185 | ], |
| 1186 | }, |
| 1187 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1188 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 1189 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 1190 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1191 | "name": "A String", # The alias name. |
| 1192 | "kind": "A String", # The alias kind. |
| 1193 | }, |
| 1194 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 1195 | "revisionId": "A String", # A revision (commit) ID. |
| 1196 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1197 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1198 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 1199 | "url": "A String", # Git repository URL. |
| 1200 | "revisionId": "A String", # Git commit hash. |
| 1201 | }, |
| 1202 | "labels": { # Labels with user defined metadata. |
| 1203 | "a_key": "A String", |
| 1204 | }, |
| 1205 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 1206 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1207 | "name": "A String", # The alias name. |
| 1208 | "kind": "A String", # The alias kind. |
| 1209 | }, |
| 1210 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 1211 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 1212 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 1213 | "projectId": "A String", # The ID of the project. |
| 1214 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 1215 | }, |
| 1216 | }, |
| 1217 | "revisionId": "A String", # A revision ID. |
| 1218 | }, |
| 1219 | }, |
| 1220 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 1221 | }, |
| 1222 | "createTime": "A String", # Time at which the build was created. |
| 1223 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 1224 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 1225 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 1226 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 1227 | }, |
| 1228 | }, |
| 1229 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 1230 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 1231 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 1232 | "A String", |
| 1233 | ], |
| 1234 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 1235 | "platform": "A String", # Platform hosting this deployment. |
| 1236 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 1237 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 1238 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 1239 | "config": "A String", # Configuration used to create this deployment. |
| 1240 | }, |
| 1241 | }, |
| 1242 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 1243 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 1244 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 1245 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 1246 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 1247 | "A String", |
| 1248 | ], |
| 1249 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 1250 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 1251 | }, |
| 1252 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 1253 | { # Layer holds metadata specific to a layer of a Docker image. |
| 1254 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 1255 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1256 | }, |
| 1257 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1258 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 1259 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 1260 | }, |
| 1261 | }, |
| 1262 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 1263 | "signatures": [ |
| 1264 | { # A signature object consists of the KeyID used and the signature itself. |
| 1265 | "sig": "A String", |
| 1266 | "keyid": "A String", |
| 1267 | }, |
| 1268 | ], |
| 1269 | "signed": { # This corresponds to an in-toto link. |
| 1270 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 1271 | "customValues": { |
| 1272 | "a_key": "A String", |
| 1273 | }, |
| 1274 | }, |
| 1275 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 1276 | "A String", |
| 1277 | ], |
| 1278 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 1279 | "customValues": { |
| 1280 | "a_key": "A String", |
| 1281 | }, |
| 1282 | }, |
| 1283 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 1284 | { |
| 1285 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 1286 | "sha256": "A String", |
| 1287 | }, |
| 1288 | "resourceUri": "A String", |
| 1289 | }, |
| 1290 | ], |
| 1291 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 1292 | { |
| 1293 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 1294 | "sha256": "A String", |
| 1295 | }, |
| 1296 | "resourceUri": "A String", |
| 1297 | }, |
| 1298 | ], |
| 1299 | }, |
| 1300 | }, |
| 1301 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 1302 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 1303 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 1304 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 1305 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 1306 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 1307 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 1308 | { |
| 1309 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 1310 | }, |
| 1311 | ], |
| 1312 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 1313 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 1314 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1315 | }, |
| 1316 | }, |
| 1317 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 1318 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 1319 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1320 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1321 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 1322 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1323 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1324 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1325 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1326 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1327 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1328 | }, |
| 1329 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1330 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1331 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 1332 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1333 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1334 | }, |
| 1335 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1336 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 1337 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 1338 | "type": "A String", # Required. The type of hash that was performed. |
| 1339 | "value": "A String", # Required. The hash value. |
| 1340 | }, |
| 1341 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 1342 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 1343 | }, |
| 1344 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 1345 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 1346 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 1347 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 1348 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 1349 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1350 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1351 | "revision": "A String", # The iteration of the package build from the above version. |
| 1352 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1353 | }, |
| 1354 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 1355 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 1356 | }, |
| 1357 | ], |
| 1358 | "name": "A String", # Output only. The name of the installed package. |
| 1359 | }, |
| 1360 | }, |
| 1361 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1362 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1363 | }</pre> |
| 1364 | </div> |
| 1365 | |
| 1366 | <div class="method"> |
| 1367 | <code class="details" id="delete">delete(name, x__xgafv=None)</code> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1368 | <pre>Deletes the specified occurrence. For example, use this method to delete an occurrence when the occurrence is no longer applicable for the given resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1369 | |
| 1370 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1371 | name: string, Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. (required) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1372 | x__xgafv: string, V1 error format. |
| 1373 | Allowed values |
| 1374 | 1 - v1 error format |
| 1375 | 2 - v2 error format |
| 1376 | |
| 1377 | Returns: |
| 1378 | An object of the form: |
| 1379 | |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1380 | { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1381 | }</pre> |
| 1382 | </div> |
| 1383 | |
| 1384 | <div class="method"> |
| 1385 | <code class="details" id="get">get(name, x__xgafv=None)</code> |
| 1386 | <pre>Gets the specified occurrence. |
| 1387 | |
| 1388 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1389 | name: string, Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. (required) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1390 | x__xgafv: string, V1 error format. |
| 1391 | Allowed values |
| 1392 | 1 - v1 error format |
| 1393 | 2 - v2 error format |
| 1394 | |
| 1395 | Returns: |
| 1396 | An object of the form: |
| 1397 | |
| 1398 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1399 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1400 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 1401 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1402 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 1403 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1404 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 1405 | "package": "A String", # Required. The package being described. |
| 1406 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 1407 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 1408 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1409 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1410 | "revision": "A String", # The iteration of the package build from the above version. |
| 1411 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1412 | }, |
| 1413 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1414 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 1415 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1416 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1417 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 1418 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 1419 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1420 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1421 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1422 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1423 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1424 | }, |
| 1425 | }, |
| 1426 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1427 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1428 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1429 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 1430 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1431 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1432 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1433 | }, |
| 1434 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1435 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 1436 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 1437 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1438 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1439 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 1440 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1441 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1442 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1443 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1444 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1445 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1446 | "builtArtifacts": [ # Output of the build. |
| 1447 | { # Artifact describes a build product. |
| 1448 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 1449 | "A String", |
| 1450 | ], |
| 1451 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 1452 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 1453 | }, |
| 1454 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1455 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1456 | "a_key": "A String", |
| 1457 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1458 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1459 | "commands": [ # Commands requested by the build. |
| 1460 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1461 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1462 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 1463 | "A String", |
| 1464 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1465 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1466 | "args": [ # Command-line arguments used when executing this command. |
| 1467 | "A String", |
| 1468 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1469 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1470 | "env": [ # Environment variables set before running this command. |
| 1471 | "A String", |
| 1472 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1473 | }, |
| 1474 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1475 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1476 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1477 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 1478 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 1479 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1480 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1481 | "name": "A String", # The alias name. |
| 1482 | "kind": "A String", # The alias kind. |
| 1483 | }, |
| 1484 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 1485 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1486 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 1487 | }, |
| 1488 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 1489 | "url": "A String", # Git repository URL. |
| 1490 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1491 | }, |
| 1492 | "labels": { # Labels with user defined metadata. |
| 1493 | "a_key": "A String", |
| 1494 | }, |
| 1495 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1496 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1497 | "name": "A String", # The alias name. |
| 1498 | "kind": "A String", # The alias kind. |
| 1499 | }, |
| 1500 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1501 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1502 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 1503 | "projectId": "A String", # The ID of the project. |
| 1504 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 1505 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1506 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1507 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1508 | }, |
| 1509 | }, |
| 1510 | ], |
| 1511 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 1512 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1513 | "fileHash": [ # Required. Collection of file hashes. |
| 1514 | { # Container message for hash values. |
| 1515 | "type": "A String", # Required. The type of hash that was performed. |
| 1516 | "value": "A String", # Required. The hash value. |
| 1517 | }, |
| 1518 | ], |
| 1519 | }, |
| 1520 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1521 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 1522 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 1523 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1524 | "name": "A String", # The alias name. |
| 1525 | "kind": "A String", # The alias kind. |
| 1526 | }, |
| 1527 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 1528 | "revisionId": "A String", # A revision (commit) ID. |
| 1529 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1530 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1531 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 1532 | "url": "A String", # Git repository URL. |
| 1533 | "revisionId": "A String", # Git commit hash. |
| 1534 | }, |
| 1535 | "labels": { # Labels with user defined metadata. |
| 1536 | "a_key": "A String", |
| 1537 | }, |
| 1538 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 1539 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 1540 | "name": "A String", # The alias name. |
| 1541 | "kind": "A String", # The alias kind. |
| 1542 | }, |
| 1543 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 1544 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 1545 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 1546 | "projectId": "A String", # The ID of the project. |
| 1547 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 1548 | }, |
| 1549 | }, |
| 1550 | "revisionId": "A String", # A revision ID. |
| 1551 | }, |
| 1552 | }, |
| 1553 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 1554 | }, |
| 1555 | "createTime": "A String", # Time at which the build was created. |
| 1556 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 1557 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 1558 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 1559 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 1560 | }, |
| 1561 | }, |
| 1562 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 1563 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 1564 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 1565 | "A String", |
| 1566 | ], |
| 1567 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 1568 | "platform": "A String", # Platform hosting this deployment. |
| 1569 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 1570 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 1571 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 1572 | "config": "A String", # Configuration used to create this deployment. |
| 1573 | }, |
| 1574 | }, |
| 1575 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 1576 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 1577 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 1578 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 1579 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 1580 | "A String", |
| 1581 | ], |
| 1582 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 1583 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 1584 | }, |
| 1585 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 1586 | { # Layer holds metadata specific to a layer of a Docker image. |
| 1587 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 1588 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1589 | }, |
| 1590 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1591 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 1592 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 1593 | }, |
| 1594 | }, |
| 1595 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 1596 | "signatures": [ |
| 1597 | { # A signature object consists of the KeyID used and the signature itself. |
| 1598 | "sig": "A String", |
| 1599 | "keyid": "A String", |
| 1600 | }, |
| 1601 | ], |
| 1602 | "signed": { # This corresponds to an in-toto link. |
| 1603 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 1604 | "customValues": { |
| 1605 | "a_key": "A String", |
| 1606 | }, |
| 1607 | }, |
| 1608 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 1609 | "A String", |
| 1610 | ], |
| 1611 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 1612 | "customValues": { |
| 1613 | "a_key": "A String", |
| 1614 | }, |
| 1615 | }, |
| 1616 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 1617 | { |
| 1618 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 1619 | "sha256": "A String", |
| 1620 | }, |
| 1621 | "resourceUri": "A String", |
| 1622 | }, |
| 1623 | ], |
| 1624 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 1625 | { |
| 1626 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 1627 | "sha256": "A String", |
| 1628 | }, |
| 1629 | "resourceUri": "A String", |
| 1630 | }, |
| 1631 | ], |
| 1632 | }, |
| 1633 | }, |
| 1634 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 1635 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 1636 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 1637 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 1638 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 1639 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 1640 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 1641 | { |
| 1642 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 1643 | }, |
| 1644 | ], |
| 1645 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 1646 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 1647 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1648 | }, |
| 1649 | }, |
| 1650 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 1651 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 1652 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1653 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1654 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 1655 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1656 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1657 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1658 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1659 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1660 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1661 | }, |
| 1662 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1663 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1664 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 1665 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1666 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1667 | }, |
| 1668 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1669 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 1670 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 1671 | "type": "A String", # Required. The type of hash that was performed. |
| 1672 | "value": "A String", # Required. The hash value. |
| 1673 | }, |
| 1674 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 1675 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 1676 | }, |
| 1677 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 1678 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 1679 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 1680 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 1681 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 1682 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1683 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1684 | "revision": "A String", # The iteration of the package build from the above version. |
| 1685 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1686 | }, |
| 1687 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 1688 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 1689 | }, |
| 1690 | ], |
| 1691 | "name": "A String", # Output only. The name of the installed package. |
| 1692 | }, |
| 1693 | }, |
| 1694 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1695 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1696 | }</pre> |
| 1697 | </div> |
| 1698 | |
| 1699 | <div class="method"> |
| 1700 | <code class="details" id="getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</code> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1701 | <pre>Gets the access control policy for a note or an occurrence resource. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1702 | |
| 1703 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1704 | resource: string, REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. (required) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1705 | body: object, The request body. |
| 1706 | The object takes the form of: |
| 1707 | |
| 1708 | { # Request message for `GetIamPolicy` method. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1709 | "options": { # Encapsulates settings provided to GetIamPolicy. # OPTIONAL: A `GetPolicyOptions` object for specifying options to `GetIamPolicy`. |
| 1710 | "requestedPolicyVersion": 42, # Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1711 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1712 | } |
| 1713 | |
| 1714 | x__xgafv: string, V1 error format. |
| 1715 | Allowed values |
| 1716 | 1 - v1 error format |
| 1717 | 2 - v2 error format |
| 1718 | |
| 1719 | Returns: |
| 1720 | An object of the form: |
| 1721 | |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1722 | { # An Identity and Access Management (IAM) policy, which specifies access controls for Google Cloud resources. A `Policy` is a collection of `bindings`. A `binding` binds one or more `members` to a single `role`. Members can be user accounts, service accounts, Google groups, and domains (such as G Suite). A `role` is a named list of permissions; each `role` can be an IAM predefined role or a user-created custom role. For some types of Google Cloud resources, a `binding` can also specify a `condition`, which is a logical expression that allows access to a resource only if the expression evaluates to `true`. A condition can add constraints based on attributes of the request, the resource, or both. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). **JSON example:** { "bindings": [ { "role": "roles/resourcemanager.organizationAdmin", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role": "roles/resourcemanager.organizationViewer", "members": [ "user:eve@example.com" ], "condition": { "title": "expirable access", "description": "Does not grant access after Sep 2020", "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag": "BwWWja0YfJA=", "version": 3 } **YAML example:** bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/resourcemanager.organizationAdmin - members: - user:eve@example.com role: roles/resourcemanager.organizationViewer condition: title: expirable access description: Does not grant access after Sep 2020 expression: request.time < timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version: 3 For a description of IAM and its features, see the [IAM documentation](https://cloud.google.com/iam/docs/). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1723 | "version": 42, # Specifies the format of the policy. Valid values are `0`, `1`, and `3`. Requests that specify an invalid value are rejected. Any operation that affects conditional role bindings must specify version `3`. This requirement applies to the following operations: * Getting a policy that includes a conditional role binding * Adding a conditional role binding to a policy * Changing a conditional role binding in a policy * Removing any role binding, with or without a condition, from a policy that includes conditions **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost. If a policy does not include any conditions, operations on that policy may specify any valid version or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1724 | "bindings": [ # Associates a list of `members` to a `role`. Optionally, may specify a `condition` that determines how and when the `bindings` are applied. Each of the `bindings` must contain at least one member. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1725 | { # Associates `members` with a `role`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1726 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1727 | "A String", |
| 1728 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1729 | "bindingId": "A String", |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1730 | "condition": { # Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: "Summary size limit" description: "Determines if a summary is less than 100 chars" expression: "document.summary.size() < 100" Example (Equality): title: "Requestor is owner" description: "Determines if requestor is the document owner" expression: "document.owner == request.auth.claims.email" Example (Logic): title: "Public documents" description: "Determine whether the document should be publicly visible" expression: "document.type != 'private' && document.type != 'internal'" Example (Data Manipulation): title: "Notification string" description: "Create a notification string with a timestamp." expression: "'New message received at ' + string(document.create_time)" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. # The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
| 1731 | "title": "A String", # Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1732 | "location": "A String", # Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1733 | "expression": "A String", # Textual representation of an expression in Common Expression Language syntax. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1734 | "description": "A String", # Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1735 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1736 | "role": "A String", # Role that is assigned to `members`. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1737 | }, |
| 1738 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1739 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1740 | }</pre> |
| 1741 | </div> |
| 1742 | |
| 1743 | <div class="method"> |
| 1744 | <code class="details" id="getNotes">getNotes(name, x__xgafv=None)</code> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1745 | <pre>Gets the note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1746 | |
| 1747 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1748 | name: string, Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. (required) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1749 | x__xgafv: string, V1 error format. |
| 1750 | Allowed values |
| 1751 | 1 - v1 error format |
| 1752 | 2 - v2 error format |
| 1753 | |
| 1754 | Returns: |
| 1755 | An object of the form: |
| 1756 | |
| 1757 | { # A type of analysis that can be done for a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1758 | "relatedNoteNames": [ # Other notes related to this note. |
| 1759 | "A String", |
| 1760 | ], |
| 1761 | "kind": "A String", # Output only. The type of analysis. This field can be used as a filter in list requests. |
| 1762 | "updateTime": "A String", # Output only. The time this note was last updated. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1763 | "relatedUrl": [ # URLs associated with this note. |
| 1764 | { # Metadata for any related URL information. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1765 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1766 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1767 | }, |
| 1768 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1769 | "expirationTime": "A String", # Time of expiration for this note. Empty if note does not expire. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1770 | "build": { # Note holding the version of the provider's builder and the signature of the provenance message in the build details occurrence. # A note describing build provenance for a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1771 | "builderVersion": "A String", # Required. Immutable. Version of the builder which produced this build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1772 | "signature": { # Message encapsulating the signature of the verified build. # Signature of the build in occurrences pointing to this build note containing build details. |
| 1773 | "keyId": "A String", # An ID for the key used to sign. This could be either an ID for the key stored in `public_key` (such as the ID or fingerprint for a PGP key, or the CN for a cert), or a reference to an external key (such as a reference to a key in Cloud Key Management Service). |
| 1774 | "signature": "A String", # Required. Signature of the related `BuildProvenance`. In JSON, this is base-64 encoded. |
| 1775 | "publicKey": "A String", # Public key of the builder which can be used to verify that the related findings are valid and unchanged. If `key_type` is empty, this defaults to PEM encoded public keys. This field may be empty if `key_id` references an external key. For Cloud Build based signatures, this is a PEM encoded public key. To verify the Cloud Build signature, place the contents of this field into a file (public.pem). The signature field is base64-decoded into its binary representation in signature.bin, and the provenance bytes from `BuildDetails` are base64-decoded into a binary representation in signed.bin. OpenSSL can then verify the signature: `openssl sha256 -verify public.pem -signature signature.bin signed.bin` |
| 1776 | "keyType": "A String", # The type of the key, either stored in `public_key` or referenced in `key_id`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1777 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1778 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1779 | "longDescription": "A String", # A detailed description of this note. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1780 | "attestationAuthority": { # Note kind that represents a logical attestation "role" or "authority". For example, an organization might have one `Authority` for "QA" and one for "build". This note is intended to act strictly as a grouping mechanism for the attached occurrences (Attestations). This grouping mechanism also provides a security boundary, since IAM ACLs gate the ability for a principle to attach an occurrence to a given note. It also provides a single point of lookup to find all attached attestation occurrences, even if they don't all live in the same project. # A note describing an attestation role. |
| 1781 | "hint": { # This submessage provides human-readable hints about the purpose of the authority. Because the name of a note acts as its resource reference, it is important to disambiguate the canonical name of the Note (which might be a UUID for security purposes) from "readable" names more suitable for debug output. Note that these hints should not be used to look up authorities in security sensitive contexts, such as when looking up attestations to verify. # Hint hints at the purpose of the attestation authority. |
| 1782 | "humanReadableName": "A String", # Required. The human readable name of this attestation authority, for example "qa". |
| 1783 | }, |
| 1784 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1785 | "baseImage": { # Basis describes the base image portion (Note) of the DockerImage relationship. Linked occurrences are derived from this or an equivalent image via: FROM Or an equivalent reference, e.g. a tag of the resource_url. # A note describing a base image. |
| 1786 | "resourceUrl": "A String", # Required. Immutable. The resource_url for the resource representing the basis of associated occurrence images. |
| 1787 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. Immutable. The fingerprint of the base image. |
| 1788 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 1789 | "A String", |
| 1790 | ], |
| 1791 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 1792 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 1793 | }, |
| 1794 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1795 | "discovery": { # A note that indicates a type of analysis a provider would perform. This note exists in a provider's project. A `Discovery` occurrence is created in a consumer's project at the start of analysis. # A note describing the initial analysis of a resource. |
| 1796 | "analysisKind": "A String", # Required. Immutable. The kind of analysis that is handled by this discovery. |
| 1797 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1798 | "vulnerability": { # Vulnerability provides metadata about a security vulnerability in a Note. # A note describing a package vulnerability. |
| 1799 | "cvssScore": 3.14, # The CVSS score for this vulnerability. |
| 1800 | "windowsDetails": [ # Windows details get their own format because the information format and model don't match a normal detail. Specifically Windows updates are done as patches, thus Windows vulnerabilities really are a missing package, rather than a package being at an incorrect version. |
| 1801 | { |
| 1802 | "fixingKbs": [ # Required. The names of the KBs which have hotfixes to mitigate this vulnerability. Note that there may be multiple hotfixes (and thus multiple KBs) that mitigate a given vulnerability. Currently any listed kb's presence is considered a fix. |
| 1803 | { |
| 1804 | "name": "A String", # The KB name (generally of the form KB[0-9]+ i.e. KB123456). |
| 1805 | "url": "A String", # A link to the KB in the Windows update catalog - https://www.catalog.update.microsoft.com/ |
| 1806 | }, |
| 1807 | ], |
| 1808 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) in which the vulnerability manifests. Examples include distro or storage location for vulnerable jar. |
| 1809 | "description": "A String", # The description of the vulnerability. |
| 1810 | "name": "A String", # Required. The name of the vulnerability. |
| 1811 | }, |
| 1812 | ], |
| 1813 | "cvssV3": { # Common Vulnerability Scoring System version 3. For details, see https://www.first.org/cvss/specification-document # The full description of the CVSSv3. |
| 1814 | "userInteraction": "A String", |
| 1815 | "integrityImpact": "A String", |
| 1816 | "exploitabilityScore": 3.14, |
| 1817 | "impactScore": 3.14, |
| 1818 | "availabilityImpact": "A String", |
| 1819 | "attackComplexity": "A String", |
| 1820 | "attackVector": "A String", # Base Metrics Represents the intrinsic characteristics of a vulnerability that are constant over time and across user environments. |
| 1821 | "baseScore": 3.14, # The base score is a function of the base metric scores. |
| 1822 | "confidentialityImpact": "A String", |
| 1823 | "privilegesRequired": "A String", |
| 1824 | "scope": "A String", |
| 1825 | }, |
| 1826 | "details": [ # All information about the package to specifically identify this vulnerability. One entry per (version range and cpe_uri) the package vulnerability has manifested in. |
| 1827 | { # Identifies all appearances of this vulnerability in the package for a specific distro/location. For example: glibc in cpe:/o:debian:debian_linux:8 for versions 2.1 - 2.2 |
| 1828 | "description": "A String", # A vendor-specific description of this note. |
| 1829 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) in which the vulnerability manifests. Examples include distro or storage location for vulnerable jar. |
| 1830 | "severityName": "A String", # The severity (eg: distro assigned severity) for this vulnerability. |
| 1831 | "minAffectedVersion": { # Version contains structured information about the version of a package. # The min version of the package in which the vulnerability exists. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1832 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1833 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1834 | "revision": "A String", # The iteration of the package build from the above version. |
| 1835 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1836 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1837 | "isObsolete": True or False, # Whether this detail is obsolete. Occurrences are expected not to point to obsolete details. |
| 1838 | "package": "A String", # Required. The name of the package where the vulnerability was found. |
| 1839 | "fixedLocation": { # The location of the vulnerability. # The fix for this specific package version. |
| 1840 | "package": "A String", # Required. The package being described. |
| 1841 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 1842 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 1843 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1844 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1845 | "revision": "A String", # The iteration of the package build from the above version. |
| 1846 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1847 | }, |
| 1848 | }, |
| 1849 | "maxAffectedVersion": { # Version contains structured information about the version of a package. # The max version of the package in which the vulnerability exists. |
| 1850 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1851 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1852 | "revision": "A String", # The iteration of the package build from the above version. |
| 1853 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1854 | }, |
| 1855 | "sourceUpdateTime": "A String", # The time this information was last changed at the source. This is an upstream timestamp from the underlying information source - e.g. Ubuntu security tracker. |
| 1856 | "packageType": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1857 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1858 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1859 | "sourceUpdateTime": "A String", # The time this information was last changed at the source. This is an upstream timestamp from the underlying information source - e.g. Ubuntu security tracker. |
| 1860 | "severity": "A String", # Note provider assigned impact of the vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1861 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1862 | "shortDescription": "A String", # A one sentence description of this note. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1863 | "intoto": { # This contains the fields corresponding to the definition of a software supply chain step in an in-toto layout. This information goes into a Grafeas note. # A note describing an in-toto link. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1864 | "expectedProducts": [ |
| 1865 | { # Defines an object to declare an in-toto artifact rule |
| 1866 | "artifactRule": [ |
| 1867 | "A String", |
| 1868 | ], |
| 1869 | }, |
| 1870 | ], |
| 1871 | "expectedMaterials": [ # The following fields contain in-toto artifact rules identifying the artifacts that enter this supply chain step, and exit the supply chain step, i.e. materials and products of the step. |
| 1872 | { # Defines an object to declare an in-toto artifact rule |
| 1873 | "artifactRule": [ |
| 1874 | "A String", |
| 1875 | ], |
| 1876 | }, |
| 1877 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1878 | "expectedCommand": [ # This field contains the expected command used to perform the step. |
| 1879 | "A String", |
| 1880 | ], |
| 1881 | "signingKeys": [ # This field contains the public keys that can be used to verify the signatures on the step metadata. |
| 1882 | { # This defines the format used to record keys used in the software supply chain. An in-toto link is attested using one or more keys defined in the in-toto layout. An example of this is: { "key_id": "776a00e29f3559e0141b3b096f696abc6cfb0c657ab40f441132b345b0...", "key_type": "rsa", "public_key_value": "-----BEGIN PUBLIC KEY-----\nMIIBojANBgkqhkiG9w0B...", "key_scheme": "rsassa-pss-sha256" } The format for in-toto's key definition can be found in section 4.2 of the in-toto specification. |
| 1883 | "keyScheme": "A String", # This field contains the corresponding signature scheme. Eg: "rsassa-pss-sha256". |
| 1884 | "keyId": "A String", # key_id is an identifier for the signing key. |
| 1885 | "keyType": "A String", # This field identifies the specific signing method. Eg: "rsa", "ed25519", and "ecdsa". |
| 1886 | "publicKeyValue": "A String", # This field contains the actual public key. |
| 1887 | }, |
| 1888 | ], |
| 1889 | "threshold": "A String", # This field contains a value that indicates the minimum number of keys that need to be used to sign the step's in-toto link. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1890 | "stepName": "A String", # This field identifies the name of the step in the supply chain. |
| 1891 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1892 | "createTime": "A String", # Output only. The time this note was created. This field can be used as a filter in list requests. |
| 1893 | "deployable": { # An artifact that can be deployed in some runtime. # A note describing something that can be deployed. |
| 1894 | "resourceUri": [ # Required. Resource URI for the artifact being deployed. |
| 1895 | "A String", |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1896 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1897 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1898 | "package": { # This represents a particular package that is distributed over various channels. E.g., glibc (aka libc6) is distributed by many, at various versions. # A note describing a package hosted by various package managers. |
| 1899 | "name": "A String", # Required. Immutable. The name of the package. |
| 1900 | "distribution": [ # The various channels by which a package is distributed. |
| 1901 | { # This represents a particular channel of distribution for a given package. E.g., Debian's jessie-backports dpkg mirror. |
| 1902 | "description": "A String", # The distribution channel-specific description of this package. |
| 1903 | "maintainer": "A String", # A freeform string denoting the maintainer of this package. |
| 1904 | "url": "A String", # The distribution channel-specific homepage for this package. |
| 1905 | "latestVersion": { # Version contains structured information about the version of a package. # The latest available version of this package in this distribution channel. |
| 1906 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1907 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1908 | "revision": "A String", # The iteration of the package build from the above version. |
| 1909 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1910 | }, |
| 1911 | "architecture": "A String", # The CPU architecture for which packages in this distribution channel were built. |
| 1912 | "cpeUri": "A String", # Required. The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 1913 | }, |
| 1914 | ], |
| 1915 | }, |
| 1916 | "name": "A String", # Output only. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1917 | }</pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1918 | </div> |
| 1919 | |
| 1920 | <div class="method"> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1921 | <code class="details" id="getVulnerabilitySummary">getVulnerabilitySummary(parent, filter=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1922 | <pre>Gets a summary of the number and severity of occurrences. |
| 1923 | |
| 1924 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1925 | parent: string, Required. The name of the project to get a vulnerability summary for in the form of `projects/[PROJECT_ID]`. (required) |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1926 | filter: string, The filter expression. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1927 | x__xgafv: string, V1 error format. |
| 1928 | Allowed values |
| 1929 | 1 - v1 error format |
| 1930 | 2 - v2 error format |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1931 | |
| 1932 | Returns: |
| 1933 | An object of the form: |
| 1934 | |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1935 | { # A summary of how many vulnerability occurrences there are per resource and severity type. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1936 | "counts": [ # A listing by resource of the number of fixable and total vulnerabilities. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1937 | { # Per resource and severity counts of fixable and total vulnerabilities. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1938 | "severity": "A String", # The severity for this count. SEVERITY_UNSPECIFIED indicates total across all severities. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1939 | "fixableCount": "A String", # The number of fixable vulnerabilities associated with this resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1940 | "totalCount": "A String", # The total number of vulnerabilities associated with this resource. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1941 | "resource": { # An entity that can have metadata. For example, a Docker image. # The affected resource. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1942 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1943 | "type": "A String", # Required. The type of hash that was performed. |
| 1944 | "value": "A String", # Required. The hash value. |
| 1945 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1946 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 1947 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1948 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1949 | }, |
| 1950 | ], |
| 1951 | }</pre> |
| 1952 | </div> |
| 1953 | |
| 1954 | <div class="method"> |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1955 | <code class="details" id="list">list(parent, pageToken=None, pageSize=None, filter=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1956 | <pre>Lists occurrences for the specified project. |
| 1957 | |
| 1958 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1959 | parent: string, Required. The name of the project to list occurrences for in the form of `projects/[PROJECT_ID]`. (required) |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1960 | pageToken: string, Token to provide to skip to a particular spot in the list. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1961 | pageSize: integer, Number of occurrences to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1962 | filter: string, The filter expression. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1963 | x__xgafv: string, V1 error format. |
| 1964 | Allowed values |
| 1965 | 1 - v1 error format |
| 1966 | 2 - v2 error format |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1967 | |
| 1968 | Returns: |
| 1969 | An object of the form: |
| 1970 | |
| 1971 | { # Response for listing occurrences. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1972 | "nextPageToken": "A String", # The next pagination token in the list response. It should be used as `page_token` for the following request. An empty value means no more results. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1973 | "occurrences": [ # The occurrences requested. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1974 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1975 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 1976 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 1977 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1978 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 1979 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1980 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 1981 | "package": "A String", # Required. The package being described. |
| 1982 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 1983 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 1984 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 1985 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 1986 | "revision": "A String", # The iteration of the package build from the above version. |
| 1987 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 1988 | }, |
| 1989 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1990 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 1991 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1992 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1993 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 1994 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 1995 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1996 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1997 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 1998 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 1999 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2000 | }, |
| 2001 | }, |
| 2002 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2003 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2004 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2005 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 2006 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2007 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2008 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2009 | }, |
| 2010 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2011 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 2012 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 2013 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2014 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2015 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 2016 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2017 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2018 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2019 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2020 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2021 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2022 | "builtArtifacts": [ # Output of the build. |
| 2023 | { # Artifact describes a build product. |
| 2024 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 2025 | "A String", |
| 2026 | ], |
| 2027 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 2028 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 2029 | }, |
| 2030 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2031 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2032 | "a_key": "A String", |
| 2033 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2034 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2035 | "commands": [ # Commands requested by the build. |
| 2036 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2037 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2038 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 2039 | "A String", |
| 2040 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2041 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2042 | "args": [ # Command-line arguments used when executing this command. |
| 2043 | "A String", |
| 2044 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2045 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2046 | "env": [ # Environment variables set before running this command. |
| 2047 | "A String", |
| 2048 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2049 | }, |
| 2050 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2051 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2052 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2053 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 2054 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 2055 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2056 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2057 | "name": "A String", # The alias name. |
| 2058 | "kind": "A String", # The alias kind. |
| 2059 | }, |
| 2060 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 2061 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2062 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 2063 | }, |
| 2064 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 2065 | "url": "A String", # Git repository URL. |
| 2066 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2067 | }, |
| 2068 | "labels": { # Labels with user defined metadata. |
| 2069 | "a_key": "A String", |
| 2070 | }, |
| 2071 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2072 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2073 | "name": "A String", # The alias name. |
| 2074 | "kind": "A String", # The alias kind. |
| 2075 | }, |
| 2076 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2077 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2078 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 2079 | "projectId": "A String", # The ID of the project. |
| 2080 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 2081 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2082 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2083 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2084 | }, |
| 2085 | }, |
| 2086 | ], |
| 2087 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 2088 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2089 | "fileHash": [ # Required. Collection of file hashes. |
| 2090 | { # Container message for hash values. |
| 2091 | "type": "A String", # Required. The type of hash that was performed. |
| 2092 | "value": "A String", # Required. The hash value. |
| 2093 | }, |
| 2094 | ], |
| 2095 | }, |
| 2096 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2097 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 2098 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 2099 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2100 | "name": "A String", # The alias name. |
| 2101 | "kind": "A String", # The alias kind. |
| 2102 | }, |
| 2103 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 2104 | "revisionId": "A String", # A revision (commit) ID. |
| 2105 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2106 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2107 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 2108 | "url": "A String", # Git repository URL. |
| 2109 | "revisionId": "A String", # Git commit hash. |
| 2110 | }, |
| 2111 | "labels": { # Labels with user defined metadata. |
| 2112 | "a_key": "A String", |
| 2113 | }, |
| 2114 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 2115 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2116 | "name": "A String", # The alias name. |
| 2117 | "kind": "A String", # The alias kind. |
| 2118 | }, |
| 2119 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 2120 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 2121 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 2122 | "projectId": "A String", # The ID of the project. |
| 2123 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 2124 | }, |
| 2125 | }, |
| 2126 | "revisionId": "A String", # A revision ID. |
| 2127 | }, |
| 2128 | }, |
| 2129 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 2130 | }, |
| 2131 | "createTime": "A String", # Time at which the build was created. |
| 2132 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 2133 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 2134 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 2135 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 2136 | }, |
| 2137 | }, |
| 2138 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 2139 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 2140 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 2141 | "A String", |
| 2142 | ], |
| 2143 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 2144 | "platform": "A String", # Platform hosting this deployment. |
| 2145 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 2146 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 2147 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 2148 | "config": "A String", # Configuration used to create this deployment. |
| 2149 | }, |
| 2150 | }, |
| 2151 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 2152 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 2153 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 2154 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 2155 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 2156 | "A String", |
| 2157 | ], |
| 2158 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 2159 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 2160 | }, |
| 2161 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 2162 | { # Layer holds metadata specific to a layer of a Docker image. |
| 2163 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 2164 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2165 | }, |
| 2166 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2167 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 2168 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 2169 | }, |
| 2170 | }, |
| 2171 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 2172 | "signatures": [ |
| 2173 | { # A signature object consists of the KeyID used and the signature itself. |
| 2174 | "sig": "A String", |
| 2175 | "keyid": "A String", |
| 2176 | }, |
| 2177 | ], |
| 2178 | "signed": { # This corresponds to an in-toto link. |
| 2179 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 2180 | "customValues": { |
| 2181 | "a_key": "A String", |
| 2182 | }, |
| 2183 | }, |
| 2184 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 2185 | "A String", |
| 2186 | ], |
| 2187 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 2188 | "customValues": { |
| 2189 | "a_key": "A String", |
| 2190 | }, |
| 2191 | }, |
| 2192 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 2193 | { |
| 2194 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 2195 | "sha256": "A String", |
| 2196 | }, |
| 2197 | "resourceUri": "A String", |
| 2198 | }, |
| 2199 | ], |
| 2200 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 2201 | { |
| 2202 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 2203 | "sha256": "A String", |
| 2204 | }, |
| 2205 | "resourceUri": "A String", |
| 2206 | }, |
| 2207 | ], |
| 2208 | }, |
| 2209 | }, |
| 2210 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 2211 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 2212 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 2213 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 2214 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 2215 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 2216 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 2217 | { |
| 2218 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 2219 | }, |
| 2220 | ], |
| 2221 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 2222 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 2223 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2224 | }, |
| 2225 | }, |
| 2226 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 2227 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 2228 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2229 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2230 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 2231 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2232 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2233 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2234 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2235 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2236 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2237 | }, |
| 2238 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2239 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2240 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 2241 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2242 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2243 | }, |
| 2244 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2245 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 2246 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 2247 | "type": "A String", # Required. The type of hash that was performed. |
| 2248 | "value": "A String", # Required. The hash value. |
| 2249 | }, |
| 2250 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 2251 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 2252 | }, |
| 2253 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 2254 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 2255 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 2256 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 2257 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 2258 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 2259 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 2260 | "revision": "A String", # The iteration of the package build from the above version. |
| 2261 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 2262 | }, |
| 2263 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 2264 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 2265 | }, |
| 2266 | ], |
| 2267 | "name": "A String", # Output only. The name of the installed package. |
| 2268 | }, |
| 2269 | }, |
| 2270 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2271 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2272 | }, |
| 2273 | ], |
| 2274 | }</pre> |
| 2275 | </div> |
| 2276 | |
| 2277 | <div class="method"> |
| 2278 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> |
| 2279 | <pre>Retrieves the next page of results. |
| 2280 | |
| 2281 | Args: |
| 2282 | previous_request: The request for the previous page. (required) |
| 2283 | previous_response: The response from the request for the previous page. (required) |
| 2284 | |
| 2285 | Returns: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2286 | A request object that you can call 'execute()' on to request the next |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2287 | page. Returns None if there are no more items in the collection. |
| 2288 | </pre> |
| 2289 | </div> |
| 2290 | |
| 2291 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2292 | <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2293 | <pre>Updates the specified occurrence. |
| 2294 | |
| 2295 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2296 | name: string, Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2297 | body: object, The request body. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2298 | The object takes the form of: |
| 2299 | |
| 2300 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2301 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2302 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 2303 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2304 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 2305 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2306 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 2307 | "package": "A String", # Required. The package being described. |
| 2308 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 2309 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 2310 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 2311 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 2312 | "revision": "A String", # The iteration of the package build from the above version. |
| 2313 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 2314 | }, |
| 2315 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2316 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 2317 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2318 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2319 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 2320 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 2321 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2322 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2323 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2324 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2325 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2326 | }, |
| 2327 | }, |
| 2328 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2329 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2330 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2331 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 2332 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2333 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2334 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2335 | }, |
| 2336 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2337 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 2338 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 2339 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2340 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2341 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 2342 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2343 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2344 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2345 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2346 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2347 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2348 | "builtArtifacts": [ # Output of the build. |
| 2349 | { # Artifact describes a build product. |
| 2350 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 2351 | "A String", |
| 2352 | ], |
| 2353 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 2354 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 2355 | }, |
| 2356 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2357 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2358 | "a_key": "A String", |
| 2359 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2360 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2361 | "commands": [ # Commands requested by the build. |
| 2362 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2363 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2364 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 2365 | "A String", |
| 2366 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2367 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2368 | "args": [ # Command-line arguments used when executing this command. |
| 2369 | "A String", |
| 2370 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2371 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2372 | "env": [ # Environment variables set before running this command. |
| 2373 | "A String", |
| 2374 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2375 | }, |
| 2376 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2377 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2378 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2379 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 2380 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 2381 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2382 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2383 | "name": "A String", # The alias name. |
| 2384 | "kind": "A String", # The alias kind. |
| 2385 | }, |
| 2386 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 2387 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2388 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 2389 | }, |
| 2390 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 2391 | "url": "A String", # Git repository URL. |
| 2392 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2393 | }, |
| 2394 | "labels": { # Labels with user defined metadata. |
| 2395 | "a_key": "A String", |
| 2396 | }, |
| 2397 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2398 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2399 | "name": "A String", # The alias name. |
| 2400 | "kind": "A String", # The alias kind. |
| 2401 | }, |
| 2402 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2403 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2404 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 2405 | "projectId": "A String", # The ID of the project. |
| 2406 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 2407 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2408 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2409 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2410 | }, |
| 2411 | }, |
| 2412 | ], |
| 2413 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 2414 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2415 | "fileHash": [ # Required. Collection of file hashes. |
| 2416 | { # Container message for hash values. |
| 2417 | "type": "A String", # Required. The type of hash that was performed. |
| 2418 | "value": "A String", # Required. The hash value. |
| 2419 | }, |
| 2420 | ], |
| 2421 | }, |
| 2422 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2423 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 2424 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 2425 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2426 | "name": "A String", # The alias name. |
| 2427 | "kind": "A String", # The alias kind. |
| 2428 | }, |
| 2429 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 2430 | "revisionId": "A String", # A revision (commit) ID. |
| 2431 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2432 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2433 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 2434 | "url": "A String", # Git repository URL. |
| 2435 | "revisionId": "A String", # Git commit hash. |
| 2436 | }, |
| 2437 | "labels": { # Labels with user defined metadata. |
| 2438 | "a_key": "A String", |
| 2439 | }, |
| 2440 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 2441 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2442 | "name": "A String", # The alias name. |
| 2443 | "kind": "A String", # The alias kind. |
| 2444 | }, |
| 2445 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 2446 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 2447 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 2448 | "projectId": "A String", # The ID of the project. |
| 2449 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 2450 | }, |
| 2451 | }, |
| 2452 | "revisionId": "A String", # A revision ID. |
| 2453 | }, |
| 2454 | }, |
| 2455 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 2456 | }, |
| 2457 | "createTime": "A String", # Time at which the build was created. |
| 2458 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 2459 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 2460 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 2461 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 2462 | }, |
| 2463 | }, |
| 2464 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 2465 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 2466 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 2467 | "A String", |
| 2468 | ], |
| 2469 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 2470 | "platform": "A String", # Platform hosting this deployment. |
| 2471 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 2472 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 2473 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 2474 | "config": "A String", # Configuration used to create this deployment. |
| 2475 | }, |
| 2476 | }, |
| 2477 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 2478 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 2479 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 2480 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 2481 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 2482 | "A String", |
| 2483 | ], |
| 2484 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 2485 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 2486 | }, |
| 2487 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 2488 | { # Layer holds metadata specific to a layer of a Docker image. |
| 2489 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 2490 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2491 | }, |
| 2492 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2493 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 2494 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 2495 | }, |
| 2496 | }, |
| 2497 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 2498 | "signatures": [ |
| 2499 | { # A signature object consists of the KeyID used and the signature itself. |
| 2500 | "sig": "A String", |
| 2501 | "keyid": "A String", |
| 2502 | }, |
| 2503 | ], |
| 2504 | "signed": { # This corresponds to an in-toto link. |
| 2505 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 2506 | "customValues": { |
| 2507 | "a_key": "A String", |
| 2508 | }, |
| 2509 | }, |
| 2510 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 2511 | "A String", |
| 2512 | ], |
| 2513 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 2514 | "customValues": { |
| 2515 | "a_key": "A String", |
| 2516 | }, |
| 2517 | }, |
| 2518 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 2519 | { |
| 2520 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 2521 | "sha256": "A String", |
| 2522 | }, |
| 2523 | "resourceUri": "A String", |
| 2524 | }, |
| 2525 | ], |
| 2526 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 2527 | { |
| 2528 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 2529 | "sha256": "A String", |
| 2530 | }, |
| 2531 | "resourceUri": "A String", |
| 2532 | }, |
| 2533 | ], |
| 2534 | }, |
| 2535 | }, |
| 2536 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 2537 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 2538 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 2539 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 2540 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 2541 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 2542 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 2543 | { |
| 2544 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 2545 | }, |
| 2546 | ], |
| 2547 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 2548 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 2549 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2550 | }, |
| 2551 | }, |
| 2552 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 2553 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 2554 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2555 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2556 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 2557 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2558 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2559 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2560 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2561 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2562 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2563 | }, |
| 2564 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2565 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2566 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 2567 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2568 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2569 | }, |
| 2570 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2571 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 2572 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 2573 | "type": "A String", # Required. The type of hash that was performed. |
| 2574 | "value": "A String", # Required. The hash value. |
| 2575 | }, |
| 2576 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 2577 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 2578 | }, |
| 2579 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 2580 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 2581 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 2582 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 2583 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 2584 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 2585 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 2586 | "revision": "A String", # The iteration of the package build from the above version. |
| 2587 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 2588 | }, |
| 2589 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 2590 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 2591 | }, |
| 2592 | ], |
| 2593 | "name": "A String", # Output only. The name of the installed package. |
| 2594 | }, |
| 2595 | }, |
| 2596 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2597 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2598 | } |
| 2599 | |
| 2600 | updateMask: string, The fields to update. |
| 2601 | x__xgafv: string, V1 error format. |
| 2602 | Allowed values |
| 2603 | 1 - v1 error format |
| 2604 | 2 - v2 error format |
| 2605 | |
| 2606 | Returns: |
| 2607 | An object of the form: |
| 2608 | |
| 2609 | { # An instance of an analysis type that has been found on a resource. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2610 | "remediation": "A String", # A description of actions that can be taken to remedy the note. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2611 | "vulnerability": { # Details of a vulnerability Occurrence. # Describes a security vulnerability. |
| 2612 | "shortDescription": "A String", # Output only. A one sentence description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2613 | "packageIssue": [ # Required. The set of affected locations and their fixes (if available) within the associated resource. |
| 2614 | { # This message wraps a location affected by a vulnerability and its associated fix (if one is available). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2615 | "fixedLocation": { # The location of the vulnerability. # The location of the available fix for vulnerability. |
| 2616 | "package": "A String", # Required. The package being described. |
| 2617 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 2618 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 2619 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 2620 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 2621 | "revision": "A String", # The iteration of the package build from the above version. |
| 2622 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 2623 | }, |
| 2624 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2625 | "severityName": "A String", # Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. |
| 2626 | "affectedLocation": { # The location of the vulnerability. # Required. The location of the vulnerability. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2627 | "package": "A String", # Required. The package being described. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2628 | "cpeUri": "A String", # Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) format. Examples include distro or storage location for vulnerable jar. |
| 2629 | "version": { # Version contains structured information about the version of a package. # Required. The version of the package being described. |
| 2630 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2631 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2632 | "revision": "A String", # The iteration of the package build from the above version. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2633 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2634 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2635 | }, |
| 2636 | }, |
| 2637 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2638 | "longDescription": "A String", # Output only. A detailed description of this vulnerability. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2639 | "effectiveSeverity": "A String", # The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2640 | "relatedUrls": [ # Output only. URLs related to this vulnerability. |
| 2641 | { # Metadata for any related URL information. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2642 | "label": "A String", # Label to describe usage of the URL. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2643 | "url": "A String", # Specific URL associated with the resource. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2644 | }, |
| 2645 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2646 | "type": "A String", # The type of package; whether native or non native(ruby gems, node.js packages etc) |
| 2647 | "severity": "A String", # Output only. The note provider assigned Severity of the vulnerability. |
| 2648 | "cvssScore": 3.14, # Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2649 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2650 | "name": "A String", # Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. |
| 2651 | "noteName": "A String", # Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2652 | "build": { # Details of a build occurrence. # Describes a verifiable build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2653 | "provenanceBytes": "A String", # Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2654 | "provenance": { # Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. # Required. The actual provenance for the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2655 | "projectId": "A String", # ID of the project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2656 | "id": "A String", # Required. Unique identifier of the build. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2657 | "builtArtifacts": [ # Output of the build. |
| 2658 | { # Artifact describes a build product. |
| 2659 | "names": [ # Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. |
| 2660 | "A String", |
| 2661 | ], |
| 2662 | "id": "A String", # Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. |
| 2663 | "checksum": "A String", # Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. |
| 2664 | }, |
| 2665 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2666 | "buildOptions": { # Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2667 | "a_key": "A String", |
| 2668 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2669 | "endTime": "A String", # Time at which execution of the build was finished. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2670 | "commands": [ # Commands requested by the build. |
| 2671 | { # Command describes a step performed as part of the build pipeline. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2672 | "id": "A String", # Optional unique identifier for this command, used in wait_for to reference this command as a dependency. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2673 | "waitFor": [ # The ID(s) of the command(s) that this command depends on. |
| 2674 | "A String", |
| 2675 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2676 | "dir": "A String", # Working directory (relative to project source root) used when running this command. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2677 | "args": [ # Command-line arguments used when executing this command. |
| 2678 | "A String", |
| 2679 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2680 | "name": "A String", # Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2681 | "env": [ # Environment variables set before running this command. |
| 2682 | "A String", |
| 2683 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2684 | }, |
| 2685 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2686 | "startTime": "A String", # Time at which execution of the build was started. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2687 | "sourceProvenance": { # Source describes the location of the source used for the build. # Details of the Source input to the build. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2688 | "additionalContexts": [ # If provided, some of the source code used for the build may be found in these locations, in the case where the source repository had multiple remotes or submodules. This list will not include the context specified in the context field. |
| 2689 | { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. |
| 2690 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2691 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2692 | "name": "A String", # The alias name. |
| 2693 | "kind": "A String", # The alias kind. |
| 2694 | }, |
| 2695 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 2696 | "revisionId": "A String", # A revision (commit) ID. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2697 | "hostUri": "A String", # The URI of a running Gerrit instance. |
| 2698 | }, |
| 2699 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 2700 | "url": "A String", # Git repository URL. |
| 2701 | "revisionId": "A String", # Git commit hash. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2702 | }, |
| 2703 | "labels": { # Labels with user defined metadata. |
| 2704 | "a_key": "A String", |
| 2705 | }, |
| 2706 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2707 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2708 | "name": "A String", # The alias name. |
| 2709 | "kind": "A String", # The alias kind. |
| 2710 | }, |
| 2711 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2712 | "uid": "A String", # A server-assigned, globally unique identifier. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2713 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 2714 | "projectId": "A String", # The ID of the project. |
| 2715 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 2716 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2717 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2718 | "revisionId": "A String", # A revision ID. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2719 | }, |
| 2720 | }, |
| 2721 | ], |
| 2722 | "fileHashes": { # Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (.tar.gz), the FileHash will be for the single path to that file. |
| 2723 | "a_key": { # Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2724 | "fileHash": [ # Required. Collection of file hashes. |
| 2725 | { # Container message for hash values. |
| 2726 | "type": "A String", # Required. The type of hash that was performed. |
| 2727 | "value": "A String", # Required. The hash value. |
| 2728 | }, |
| 2729 | ], |
| 2730 | }, |
| 2731 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2732 | "context": { # A SourceContext is a reference to a tree of files. A SourceContext together with a path point to a unique revision of a single file or directory. # If provided, the source code used for the build came from this location. |
| 2733 | "gerrit": { # A SourceContext referring to a Gerrit project. # A SourceContext referring to a Gerrit project. |
| 2734 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2735 | "name": "A String", # The alias name. |
| 2736 | "kind": "A String", # The alias kind. |
| 2737 | }, |
| 2738 | "gerritProject": "A String", # The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. |
| 2739 | "revisionId": "A String", # A revision (commit) ID. |
| 2740 | "hostUri": "A String", # The URI of a running Gerrit instance. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2741 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2742 | "git": { # A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). # A SourceContext referring to any third party Git repo (e.g., GitHub). |
| 2743 | "url": "A String", # Git repository URL. |
| 2744 | "revisionId": "A String", # Git commit hash. |
| 2745 | }, |
| 2746 | "labels": { # Labels with user defined metadata. |
| 2747 | "a_key": "A String", |
| 2748 | }, |
| 2749 | "cloudRepo": { # A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. # A SourceContext referring to a revision in a Google Cloud Source Repo. |
| 2750 | "aliasContext": { # An alias to a repo revision. # An alias, which may be a branch or tag. |
| 2751 | "name": "A String", # The alias name. |
| 2752 | "kind": "A String", # The alias kind. |
| 2753 | }, |
| 2754 | "repoId": { # A unique identifier for a Cloud Repo. # The ID of the repo. |
| 2755 | "uid": "A String", # A server-assigned, globally unique identifier. |
| 2756 | "projectRepoId": { # Selects a repo using a Google Cloud Platform project ID (e.g., winged-cargo-31) and a repo name within that project. # A combination of a project ID and a repo name. |
| 2757 | "projectId": "A String", # The ID of the project. |
| 2758 | "repoName": "A String", # The name of the repo. Leave empty for the default repo. |
| 2759 | }, |
| 2760 | }, |
| 2761 | "revisionId": "A String", # A revision ID. |
| 2762 | }, |
| 2763 | }, |
| 2764 | "artifactStorageSourceUri": "A String", # If provided, the input binary artifacts for the build came from this location. |
| 2765 | }, |
| 2766 | "createTime": "A String", # Time at which the build was created. |
| 2767 | "builderVersion": "A String", # Version string of the builder at the time this build was executed. |
| 2768 | "triggerId": "A String", # Trigger identifier if the build was triggered automatically; empty if not. |
| 2769 | "creator": "A String", # E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. |
| 2770 | "logsUri": "A String", # URI where any logs for this provenance were written. |
| 2771 | }, |
| 2772 | }, |
| 2773 | "deployment": { # Details of a deployment occurrence. # Describes the deployment of an artifact on a runtime. |
| 2774 | "deployment": { # The period during which some deployable was active in a runtime. # Required. Deployment history for the resource. |
| 2775 | "resourceUri": [ # Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. |
| 2776 | "A String", |
| 2777 | ], |
| 2778 | "userEmail": "A String", # Identity of the user that triggered this deployment. |
| 2779 | "platform": "A String", # Platform hosting this deployment. |
| 2780 | "address": "A String", # Address of the runtime element hosting this deployment. |
| 2781 | "undeployTime": "A String", # End of the lifetime of this deployment. |
| 2782 | "deployTime": "A String", # Required. Beginning of the lifetime of this deployment. |
| 2783 | "config": "A String", # Configuration used to create this deployment. |
| 2784 | }, |
| 2785 | }, |
| 2786 | "updateTime": "A String", # Output only. The time this occurrence was last updated. |
| 2787 | "derivedImage": { # Details of an image occurrence. # Describes how this resource derives from the basis in the associated note. |
| 2788 | "derivedImage": { # Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . # Required. Immutable. The child image derived from the base image. |
| 2789 | "fingerprint": { # A set of properties that uniquely identify a given Docker image. # Required. The fingerprint of the derived image. |
| 2790 | "v2Blob": [ # Required. The ordered list of v2 blobs that represent a given image. |
| 2791 | "A String", |
| 2792 | ], |
| 2793 | "v2Name": "A String", # Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. |
| 2794 | "v1Name": "A String", # Required. The layer ID of the final layer in the Docker image's v1 representation. |
| 2795 | }, |
| 2796 | "layerInfo": [ # This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. |
| 2797 | { # Layer holds metadata specific to a layer of a Docker image. |
| 2798 | "directive": "A String", # Required. The recovered Dockerfile directive used to construct this layer. |
| 2799 | "arguments": "A String", # The recovered arguments to the Dockerfile directive. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2800 | }, |
| 2801 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2802 | "distance": 42, # Output only. The number of layers by which this image differs from the associated image basis. |
| 2803 | "baseResourceUrl": "A String", # Output only. This contains the base image URL for the derived image occurrence. |
| 2804 | }, |
| 2805 | }, |
| 2806 | "intoto": { # This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. # Describes a specific in-toto link. |
| 2807 | "signatures": [ |
| 2808 | { # A signature object consists of the KeyID used and the signature itself. |
| 2809 | "sig": "A String", |
| 2810 | "keyid": "A String", |
| 2811 | }, |
| 2812 | ], |
| 2813 | "signed": { # This corresponds to an in-toto link. |
| 2814 | "byproducts": { # Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". # ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. |
| 2815 | "customValues": { |
| 2816 | "a_key": "A String", |
| 2817 | }, |
| 2818 | }, |
| 2819 | "command": [ # This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] |
| 2820 | "A String", |
| 2821 | ], |
| 2822 | "environment": { # Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". # This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." } } |
| 2823 | "customValues": { |
| 2824 | "a_key": "A String", |
| 2825 | }, |
| 2826 | }, |
| 2827 | "products": [ # Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. |
| 2828 | { |
| 2829 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 2830 | "sha256": "A String", |
| 2831 | }, |
| 2832 | "resourceUri": "A String", |
| 2833 | }, |
| 2834 | ], |
| 2835 | "materials": [ # Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : } } ] |
| 2836 | { |
| 2837 | "hashes": { # Defines a hash object for use in Materials and Products. |
| 2838 | "sha256": "A String", |
| 2839 | }, |
| 2840 | "resourceUri": "A String", |
| 2841 | }, |
| 2842 | ], |
| 2843 | }, |
| 2844 | }, |
| 2845 | "discovered": { # Details of a discovery occurrence. # Describes when a resource was discovered. |
| 2846 | "discovered": { # Provides information about the analysis status of a discovered resource. # Required. Analysis status for the discovered resource. |
| 2847 | "lastAnalysisTime": "A String", # The last time continuous analysis was done for this resource. Deprecated, do not use. |
| 2848 | "analysisStatus": "A String", # The status of discovery for the resource. |
| 2849 | "continuousAnalysis": "A String", # Whether the resource is continuously analyzed. |
| 2850 | "analysisStatusError": { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. |
| 2851 | "details": [ # A list of messages that carry the error details. There is a common set of message types for APIs to use. |
| 2852 | { |
| 2853 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 2854 | }, |
| 2855 | ], |
| 2856 | "message": "A String", # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client. |
| 2857 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 2858 | }, |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2859 | }, |
| 2860 | }, |
| 2861 | "attestation": { # Details of an attestation occurrence. # Describes an attestation of an artifact. |
| 2862 | "attestation": { # Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). # Required. Attestation for the resource. |
| 2863 | "genericSignedAttestation": { # An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2864 | "serializedPayload": "A String", # The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2865 | "signatures": [ # One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. |
| 2866 | { # Verifiers (e.g. Kritis implementations) MUST verify signatures with respect to the trust anchors defined in policy (e.g. a Kritis policy). Typically this means that the verifier has been configured with a map from `public_key_id` to public key material (and any required parameters, e.g. signing algorithm). In particular, verification implementations MUST NOT treat the signature `public_key_id` as anything more than a key lookup hint. The `public_key_id` DOES NOT validate or authenticate a public key; it only provides a mechanism for quickly selecting a public key ALREADY CONFIGURED on the verifier through a trusted channel. Verification implementations MUST reject signatures in any of the following circumstances: * The `public_key_id` is not recognized by the verifier. * The public key that `public_key_id` refers to does not verify the signature with respect to the payload. The `signature` contents SHOULD NOT be "attached" (where the payload is included with the serialized `signature` bytes). Verifiers MUST ignore any "attached" payload and only verify signatures with respect to explicitly provided payload (e.g. a `payload` field on the proto message that holds this Signature, or the canonical serialization of the proto message that holds this signature). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2867 | "signature": "A String", # The content of the signature, an opaque bytestring. The payload that this signature verifies MUST be unambiguously provided with the Signature during verification. A wrapper message might provide the payload explicitly. Alternatively, a message might have a canonical serialization that can always be unambiguously computed to derive the payload. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2868 | "publicKeyId": "A String", # The identifier for the public key that verifies this signature. * The `public_key_id` is required. * The `public_key_id` SHOULD be an RFC3986 conformant URI. * When possible, the `public_key_id` SHOULD be an immutable reference, such as a cryptographic digest. Examples of valid `public_key_id`s: OpenPGP V4 public key fingerprint: * "openpgp4fpr:74FAF3B861BDA0870C7B6DEF607E48D2A663AEEA" See https://www.iana.org/assignments/uri-schemes/prov/openpgp4fpr for more details on this scheme. RFC6920 digest-named SubjectPublicKeyInfo (digest of the DER serialization): * "ni:///sha-256;cD9o9Cq6LG3jD0iKXqEi_vdjJGecm_iXkbqVoScViaU" * "nih:///sha-256;703f68f42aba2c6de30f488a5ea122fef76324679c9bf89791ba95a1271589a5" |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2869 | }, |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2870 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2871 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2872 | }, |
| 2873 | "pgpSignedAttestation": { # An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. # A PGP signed attestation. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2874 | "pgpKeyId": "A String", # The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg --with-colons --with-fingerprint --force-v4-certs \ --list-keys attester@example.com tru::1:1513631572:0:3:1:5 pub:...... fpr:::::::::24FF6481B76AC91E66A00AC657A93A81EF3AE6FB: ``` Above, the fingerprint is `24FF6481B76AC91E66A00AC657A93A81EF3AE6FB`. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2875 | "signature": "A String", # Required. The raw content of the signature, as output by GNU Privacy Guard (GPG) or equivalent. Since this message only supports attached signatures, the payload that was signed must be attached. While the signature format supported is dependent on the verification implementation, currently only ASCII-armored (`--armor` to gpg), non-clearsigned (`--sign` rather than `--clearsign` to gpg) are supported. Concretely, `gpg --sign --armor --output=signature.gpg payload.json` will create the signature content expected in this field in `signature.gpg` for the `payload.json` attestation payload. |
| 2876 | "contentType": "A String", # Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2877 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2878 | }, |
| 2879 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2880 | "resource": { # An entity that can have metadata. For example, a Docker image. # Required. Immutable. The resource for which the occurrence applies. |
| 2881 | "contentHash": { # Container message for hash values. # Deprecated, do not use. Use uri instead. The hash of the resource content. For example, the Docker digest. |
| 2882 | "type": "A String", # Required. The type of hash that was performed. |
| 2883 | "value": "A String", # Required. The hash value. |
| 2884 | }, |
| 2885 | "name": "A String", # Deprecated, do not use. Use uri instead. The name of the resource. For example, the name of a Docker image - "Debian". |
| 2886 | "uri": "A String", # Required. The unique URI of the resource. For example, `https://gcr.io/project/image@sha256:foo` for a Docker image. |
| 2887 | }, |
| 2888 | "installation": { # Details of a package occurrence. # Describes the installation of a package on the linked resource. |
| 2889 | "installation": { # This represents how a particular software package may be installed on a system. # Required. Where the package was installed. |
| 2890 | "location": [ # Required. All of the places within the filesystem versions of this package have been found. |
| 2891 | { # An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. |
| 2892 | "version": { # Version contains structured information about the version of a package. # The version installed at this location. |
| 2893 | "name": "A String", # Required only when version kind is NORMAL. The main part of the version name. |
| 2894 | "epoch": 42, # Used to correct mistakes in the version numbering scheme. |
| 2895 | "revision": "A String", # The iteration of the package build from the above version. |
| 2896 | "kind": "A String", # Required. Distinguishes between sentinel MIN/MAX versions and normal versions. |
| 2897 | }, |
| 2898 | "cpeUri": "A String", # Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. |
| 2899 | "path": "A String", # The path from which we gathered that this package/version is installed. |
| 2900 | }, |
| 2901 | ], |
| 2902 | "name": "A String", # Output only. The name of the installed package. |
| 2903 | }, |
| 2904 | }, |
| 2905 | "kind": "A String", # Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2906 | "createTime": "A String", # Output only. The time this occurrence was created. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2907 | }</pre> |
| 2908 | </div> |
| 2909 | |
| 2910 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2911 | <code class="details" id="setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</code> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2912 | <pre>Sets the access control policy on the specified note or occurrence. Requires `containeranalysis.notes.setIamPolicy` or `containeranalysis.occurrences.setIamPolicy` permission if the resource is a note or an occurrence, respectively. The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2913 | |
| 2914 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2915 | resource: string, REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2916 | body: object, The request body. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2917 | The object takes the form of: |
| 2918 | |
| 2919 | { # Request message for `SetIamPolicy` method. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2920 | "policy": { # An Identity and Access Management (IAM) policy, which specifies access controls for Google Cloud resources. A `Policy` is a collection of `bindings`. A `binding` binds one or more `members` to a single `role`. Members can be user accounts, service accounts, Google groups, and domains (such as G Suite). A `role` is a named list of permissions; each `role` can be an IAM predefined role or a user-created custom role. For some types of Google Cloud resources, a `binding` can also specify a `condition`, which is a logical expression that allows access to a resource only if the expression evaluates to `true`. A condition can add constraints based on attributes of the request, the resource, or both. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). **JSON example:** { "bindings": [ { "role": "roles/resourcemanager.organizationAdmin", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role": "roles/resourcemanager.organizationViewer", "members": [ "user:eve@example.com" ], "condition": { "title": "expirable access", "description": "Does not grant access after Sep 2020", "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag": "BwWWja0YfJA=", "version": 3 } **YAML example:** bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/resourcemanager.organizationAdmin - members: - user:eve@example.com role: roles/resourcemanager.organizationViewer condition: title: expirable access description: Does not grant access after Sep 2020 expression: request.time < timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version: 3 For a description of IAM and its features, see the [IAM documentation](https://cloud.google.com/iam/docs/). # REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud Platform services (such as Projects) might reject them. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2921 | "version": 42, # Specifies the format of the policy. Valid values are `0`, `1`, and `3`. Requests that specify an invalid value are rejected. Any operation that affects conditional role bindings must specify version `3`. This requirement applies to the following operations: * Getting a policy that includes a conditional role binding * Adding a conditional role binding to a policy * Changing a conditional role binding in a policy * Removing any role binding, with or without a condition, from a policy that includes conditions **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost. If a policy does not include any conditions, operations on that policy may specify any valid version or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2922 | "bindings": [ # Associates a list of `members` to a `role`. Optionally, may specify a `condition` that determines how and when the `bindings` are applied. Each of the `bindings` must contain at least one member. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2923 | { # Associates `members` with a `role`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2924 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2925 | "A String", |
| 2926 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2927 | "bindingId": "A String", |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2928 | "condition": { # Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: "Summary size limit" description: "Determines if a summary is less than 100 chars" expression: "document.summary.size() < 100" Example (Equality): title: "Requestor is owner" description: "Determines if requestor is the document owner" expression: "document.owner == request.auth.claims.email" Example (Logic): title: "Public documents" description: "Determine whether the document should be publicly visible" expression: "document.type != 'private' && document.type != 'internal'" Example (Data Manipulation): title: "Notification string" description: "Create a notification string with a timestamp." expression: "'New message received at ' + string(document.create_time)" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. # The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
| 2929 | "title": "A String", # Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2930 | "location": "A String", # Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2931 | "expression": "A String", # Textual representation of an expression in Common Expression Language syntax. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2932 | "description": "A String", # Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 2933 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2934 | "role": "A String", # Role that is assigned to `members`. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2935 | }, |
| 2936 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2937 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2938 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2939 | } |
| 2940 | |
| 2941 | x__xgafv: string, V1 error format. |
| 2942 | Allowed values |
| 2943 | 1 - v1 error format |
| 2944 | 2 - v2 error format |
| 2945 | |
| 2946 | Returns: |
| 2947 | An object of the form: |
| 2948 | |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2949 | { # An Identity and Access Management (IAM) policy, which specifies access controls for Google Cloud resources. A `Policy` is a collection of `bindings`. A `binding` binds one or more `members` to a single `role`. Members can be user accounts, service accounts, Google groups, and domains (such as G Suite). A `role` is a named list of permissions; each `role` can be an IAM predefined role or a user-created custom role. For some types of Google Cloud resources, a `binding` can also specify a `condition`, which is a logical expression that allows access to a resource only if the expression evaluates to `true`. A condition can add constraints based on attributes of the request, the resource, or both. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). **JSON example:** { "bindings": [ { "role": "roles/resourcemanager.organizationAdmin", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role": "roles/resourcemanager.organizationViewer", "members": [ "user:eve@example.com" ], "condition": { "title": "expirable access", "description": "Does not grant access after Sep 2020", "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag": "BwWWja0YfJA=", "version": 3 } **YAML example:** bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/resourcemanager.organizationAdmin - members: - user:eve@example.com role: roles/resourcemanager.organizationViewer condition: title: expirable access description: Does not grant access after Sep 2020 expression: request.time < timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version: 3 For a description of IAM and its features, see the [IAM documentation](https://cloud.google.com/iam/docs/). |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2950 | "version": 42, # Specifies the format of the policy. Valid values are `0`, `1`, and `3`. Requests that specify an invalid value are rejected. Any operation that affects conditional role bindings must specify version `3`. This requirement applies to the following operations: * Getting a policy that includes a conditional role binding * Adding a conditional role binding to a policy * Changing a conditional role binding in a policy * Removing any role binding, with or without a condition, from a policy that includes conditions **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost. If a policy does not include any conditions, operations on that policy may specify any valid version or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2951 | "bindings": [ # Associates a list of `members` to a `role`. Optionally, may specify a `condition` that determines how and when the `bindings` are applied. Each of the `bindings` must contain at least one member. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2952 | { # Associates `members` with a `role`. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2953 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. |
Bu Sun Kim | d059ad8 | 2020-07-22 17:02:09 -0700 | [diff] [blame] | 2954 | "A String", |
| 2955 | ], |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2956 | "bindingId": "A String", |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2957 | "condition": { # Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: "Summary size limit" description: "Determines if a summary is less than 100 chars" expression: "document.summary.size() < 100" Example (Equality): title: "Requestor is owner" description: "Determines if requestor is the document owner" expression: "document.owner == request.auth.claims.email" Example (Logic): title: "Public documents" description: "Determine whether the document should be publicly visible" expression: "document.type != 'private' && document.type != 'internal'" Example (Data Manipulation): title: "Notification string" description: "Create a notification string with a timestamp." expression: "'New message received at ' + string(document.create_time)" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. # The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
| 2958 | "title": "A String", # Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2959 | "location": "A String", # Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file. |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2960 | "expression": "A String", # Textual representation of an expression in Common Expression Language syntax. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2961 | "description": "A String", # Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 2962 | }, |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 2963 | "role": "A String", # Role that is assigned to `members`. For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2964 | }, |
| 2965 | ], |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2966 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2967 | }</pre> |
| 2968 | </div> |
| 2969 | |
| 2970 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2971 | <code class="details" id="testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</code> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2972 | <pre>Returns the permissions that a caller has on the specified note or occurrence. Requires list permission on the project (for example, `containeranalysis.notes.list`). The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for occurrences. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2973 | |
| 2974 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2975 | resource: string, REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2976 | body: object, The request body. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2977 | The object takes the form of: |
| 2978 | |
| 2979 | { # Request message for `TestIamPermissions` method. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2980 | "permissions": [ # The set of permissions to check for the `resource`. Permissions with wildcards (such as '*' or 'storage.*') are not allowed. For more information see [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2981 | "A String", |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2982 | ], |
| 2983 | } |
| 2984 | |
| 2985 | x__xgafv: string, V1 error format. |
| 2986 | Allowed values |
| 2987 | 1 - v1 error format |
| 2988 | 2 - v2 error format |
| 2989 | |
| 2990 | Returns: |
| 2991 | An object of the form: |
| 2992 | |
| 2993 | { # Response message for `TestIamPermissions` method. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 2994 | "permissions": [ # A subset of `TestPermissionsRequest.permissions` that the caller is allowed. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2995 | "A String", |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2996 | ], |
| 2997 | }</pre> |
| 2998 | </div> |
| 2999 | |
| 3000 | </body></html> |