blob: aea3f2e45988839f08572b445bbd1b4aad27c010 [file] [log] [blame]
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001<html><body>
2<style>
3
4body, 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
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, 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
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070075<h1><a href="cloudkms_v1.html">Cloud Key Management Service (KMS) API</a> . <a href="cloudkms_v1.projects.html">projects</a> . <a href="cloudkms_v1.projects.locations.html">locations</a> . <a href="cloudkms_v1.projects.locations.keyRings.html">keyRings</a> . <a href="cloudkms_v1.projects.locations.keyRings.cryptoKeys.html">cryptoKeys</a> . <a href="cloudkms_v1.projects.locations.keyRings.cryptoKeys.cryptoKeyVersions.html">cryptoKeyVersions</a></h1>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040076<h2>Instance Methods</h2>
77<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070078 <code><a href="#asymmetricDecrypt">asymmetricDecrypt(name, body=None, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070079<p class="firstline">Decrypts data that was encrypted with a public key retrieved from GetPublicKey corresponding to a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_DECRYPT.</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070080<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070081 <code><a href="#asymmetricSign">asymmetricSign(name, body=None, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070082<p class="firstline">Signs data using a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_SIGN, producing a signature that can be verified with the public key retrieved from GetPublicKey.</p>
83<p class="toc_element">
84 <code><a href="#close">close()</a></code></p>
85<p class="firstline">Close httplib2 connections.</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070086<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070087 <code><a href="#create">create(parent, body=None, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070088<p class="firstline">Create a new CryptoKeyVersion in a CryptoKey. The server will assign the next sequential id. If unset, state will be set to ENABLED.</p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040089<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070090 <code><a href="#destroy">destroy(name, body=None, x__xgafv=None)</a></code></p>
yoshi-code-botcdf480e2021-08-17 00:20:40 -070091<p class="firstline">Schedule a CryptoKeyVersion for destruction. Upon calling this method, CryptoKeyVersion.state will be set to DESTROY_SCHEDULED, and destroy_time will be set to the time destroy_scheduled_duration in the future. At that time, the state will automatically change to DESTROYED, and the key material will be irrevocably destroyed. Before the destroy_time is reached, RestoreCryptoKeyVersion may be called to reverse the process.</p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040092<p class="toc_element">
93 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
94<p class="firstline">Returns metadata for a given CryptoKeyVersion.</p>
95<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070096 <code><a href="#getPublicKey">getPublicKey(name, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070097<p class="firstline">Returns the public key for the given CryptoKeyVersion. The CryptoKey.purpose must be ASYMMETRIC_SIGN or ASYMMETRIC_DECRYPT.</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070098<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070099 <code><a href="#import_">import_(parent, body=None, x__xgafv=None)</a></code></p>
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700100<p class="firstline">Import wrapped key material into a CryptoKeyVersion. All requests must specify a CryptoKey. If a CryptoKeyVersion is additionally specified in the request, key material will be reimported into that version. Otherwise, a new version will be created, and will be assigned the next sequential id within the CryptoKey.</p>
Dan O'Mearadd494642020-05-01 07:42:23 -0700101<p class="toc_element">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800102 <code><a href="#list">list(parent, filter=None, orderBy=None, pageSize=None, pageToken=None, view=None, x__xgafv=None)</a></code></p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400103<p class="firstline">Lists CryptoKeyVersions.</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">
yoshi-code-botb539cc42021-08-03 00:20:27 -0700108 <code><a href="#macSign">macSign(name, body=None, x__xgafv=None)</a></code></p>
109<p class="firstline">Signs data using a CryptoKeyVersion with CryptoKey.purpose MAC, producing a tag that can be verified by another source with the same key.</p>
110<p class="toc_element">
111 <code><a href="#macVerify">macVerify(name, body=None, x__xgafv=None)</a></code></p>
112<p class="firstline">Verifies MAC tag using a CryptoKeyVersion with CryptoKey.purpose MAC, and returns a response that indicates whether or not the verification was successful.</p>
113<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700114 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700115<p class="firstline">Update a CryptoKeyVersion's metadata. state may be changed between ENABLED and DISABLED using this method. See DestroyCryptoKeyVersion and RestoreCryptoKeyVersion to move between other states.</p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400116<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700117 <code><a href="#restore">restore(name, body=None, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700118<p class="firstline">Restore a CryptoKeyVersion in the DESTROY_SCHEDULED state. Upon restoration of the CryptoKeyVersion, state will be set to DISABLED, and destroy_time will be cleared.</p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400119<h3>Method Details</h3>
120<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700121 <code class="details" id="asymmetricDecrypt">asymmetricDecrypt(name, body=None, x__xgafv=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700122 <pre>Decrypts data that was encrypted with a public key retrieved from GetPublicKey corresponding to a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_DECRYPT.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700123
124Args:
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700125 name: string, Required. The resource name of the CryptoKeyVersion to use for decryption. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700126 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700127 The object takes the form of:
128
129{ # Request message for KeyManagementService.AsymmetricDecrypt.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800130 &quot;ciphertext&quot;: &quot;A String&quot;, # Required. The data encrypted with the named CryptoKeyVersion&#x27;s public key using OAEP.
yoshi-code-bot1a4514d2021-07-13 00:20:24 -0700131 &quot;ciphertextCrc32c&quot;: &quot;A String&quot;, # Optional. An optional CRC32C checksum of the AsymmetricDecryptRequest.ciphertext. If specified, KeyManagementService will verify the integrity of the received AsymmetricDecryptRequest.ciphertext using this checksum. KeyManagementService will report an error if the checksum verification fails. If you receive a checksum error, your client should verify that CRC32C(AsymmetricDecryptRequest.ciphertext) is equal to AsymmetricDecryptRequest.ciphertext_crc32c, and if so, perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800132}
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700133
134 x__xgafv: string, V1 error format.
135 Allowed values
136 1 - v1 error format
137 2 - v2 error format
138
139Returns:
140 An object of the form:
141
142 { # Response message for KeyManagementService.AsymmetricDecrypt.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800143 &quot;plaintext&quot;: &quot;A String&quot;, # The decrypted data originally encrypted with the matching public key.
yoshi-code-bot1a4514d2021-07-13 00:20:24 -0700144 &quot;plaintextCrc32c&quot;: &quot;A String&quot;, # Integrity verification field. A CRC32C checksum of the returned AsymmetricDecryptResponse.plaintext. An integrity check of AsymmetricDecryptResponse.plaintext can be performed by computing the CRC32C checksum of AsymmetricDecryptResponse.plaintext and comparing your results to this field. Discard the response in case of non-matching checksum values, and perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
yoshi-code-botb6dc1b92021-03-02 11:49:08 -0800145 &quot;protectionLevel&quot;: &quot;A String&quot;, # The ProtectionLevel of the CryptoKeyVersion used in decryption.
yoshi-code-bot1a4514d2021-07-13 00:20:24 -0700146 &quot;verifiedCiphertextCrc32c&quot;: True or False, # Integrity verification field. A flag indicating whether AsymmetricDecryptRequest.ciphertext_crc32c was received by KeyManagementService and used for the integrity verification of the ciphertext. A false value of this field indicates either that AsymmetricDecryptRequest.ciphertext_crc32c was left unset or that it was not delivered to KeyManagementService. If you&#x27;ve set AsymmetricDecryptRequest.ciphertext_crc32c but this field is still false, discard the response and perform a limited number of retries.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800147}</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700148</div>
149
150<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700151 <code class="details" id="asymmetricSign">asymmetricSign(name, body=None, x__xgafv=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700152 <pre>Signs data using a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_SIGN, producing a signature that can be verified with the public key retrieved from GetPublicKey.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700153
154Args:
155 name: string, Required. The resource name of the CryptoKeyVersion to use for signing. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700156 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700157 The object takes the form of:
158
159{ # Request message for KeyManagementService.AsymmetricSign.
yoshi-code-bot12d387c2021-10-26 00:24:32 -0700160 &quot;data&quot;: &quot;A String&quot;, # Optional. This field will only be honored for RAW_PKCS1 keys. The data to sign. A digest is computed over the data that will be signed, PKCS #1 padding is applied to the digest directly and then encrypted.
161 &quot;dataCrc32c&quot;: &quot;A String&quot;, # Optional. An optional CRC32C checksum of the AsymmetricSignRequest.data. If specified, KeyManagementService will verify the integrity of the received AsymmetricSignRequest.data using this checksum. KeyManagementService will report an error if the checksum verification fails. If you receive a checksum error, your client should verify that CRC32C(AsymmetricSignRequest.data) is equal to AsymmetricSignRequest.data_crc32c, and if so, perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
yoshi-code-botb6dc1b92021-03-02 11:49:08 -0800162 &quot;digest&quot;: { # A Digest holds a cryptographic message digest. # Optional. The digest of the data to sign. The digest must be produced with the same digest algorithm as specified by the key version&#x27;s algorithm.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800163 &quot;sha256&quot;: &quot;A String&quot;, # A message digest produced with the SHA-256 algorithm.
164 &quot;sha384&quot;: &quot;A String&quot;, # A message digest produced with the SHA-384 algorithm.
165 &quot;sha512&quot;: &quot;A String&quot;, # A message digest produced with the SHA-512 algorithm.
166 },
yoshi-code-bot1a4514d2021-07-13 00:20:24 -0700167 &quot;digestCrc32c&quot;: &quot;A String&quot;, # Optional. An optional CRC32C checksum of the AsymmetricSignRequest.digest. If specified, KeyManagementService will verify the integrity of the received AsymmetricSignRequest.digest using this checksum. KeyManagementService will report an error if the checksum verification fails. If you receive a checksum error, your client should verify that CRC32C(AsymmetricSignRequest.digest) is equal to AsymmetricSignRequest.digest_crc32c, and if so, perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800168}
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700169
170 x__xgafv: string, V1 error format.
171 Allowed values
172 1 - v1 error format
173 2 - v2 error format
174
175Returns:
176 An object of the form:
177
178 { # Response message for KeyManagementService.AsymmetricSign.
yoshi-code-bot1a4514d2021-07-13 00:20:24 -0700179 &quot;name&quot;: &quot;A String&quot;, # The resource name of the CryptoKeyVersion used for signing. Check this field to verify that the intended resource was used for signing.
yoshi-code-botb6dc1b92021-03-02 11:49:08 -0800180 &quot;protectionLevel&quot;: &quot;A String&quot;, # The ProtectionLevel of the CryptoKeyVersion used for signing.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800181 &quot;signature&quot;: &quot;A String&quot;, # The created signature.
yoshi-code-bot1a4514d2021-07-13 00:20:24 -0700182 &quot;signatureCrc32c&quot;: &quot;A String&quot;, # Integrity verification field. A CRC32C checksum of the returned AsymmetricSignResponse.signature. An integrity check of AsymmetricSignResponse.signature can be performed by computing the CRC32C checksum of AsymmetricSignResponse.signature and comparing your results to this field. Discard the response in case of non-matching checksum values, and perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
yoshi-code-bot12d387c2021-10-26 00:24:32 -0700183 &quot;verifiedDataCrc32c&quot;: True or False, # Integrity verification field. A flag indicating whether AsymmetricSignRequest.data_crc32c was received by KeyManagementService and used for the integrity verification of the data. A false value of this field indicates either that AsymmetricSignRequest.data_crc32c was left unset or that it was not delivered to KeyManagementService. If you&#x27;ve set AsymmetricSignRequest.data_crc32c but this field is still false, discard the response and perform a limited number of retries.
yoshi-code-bot1a4514d2021-07-13 00:20:24 -0700184 &quot;verifiedDigestCrc32c&quot;: True or False, # Integrity verification field. A flag indicating whether AsymmetricSignRequest.digest_crc32c was received by KeyManagementService and used for the integrity verification of the digest. A false value of this field indicates either that AsymmetricSignRequest.digest_crc32c was left unset or that it was not delivered to KeyManagementService. If you&#x27;ve set AsymmetricSignRequest.digest_crc32c but this field is still false, discard the response and perform a limited number of retries.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800185}</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700186</div>
187
188<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700189 <code class="details" id="close">close()</code>
190 <pre>Close httplib2 connections.</pre>
191</div>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400192
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700193<div class="method">
194 <code class="details" id="create">create(parent, body=None, x__xgafv=None)</code>
195 <pre>Create a new CryptoKeyVersion in a CryptoKey. The server will assign the next sequential id. If unset, state will be set to ENABLED.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400196
197Args:
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700198 parent: string, Required. The name of the CryptoKey associated with the CryptoKeyVersions. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700199 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400200 The object takes the form of:
201
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700202{ # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800203 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700204 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700205 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800206 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700207 &quot;A String&quot;,
208 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800209 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
210 &quot;A String&quot;,
211 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800212 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
213 &quot;A String&quot;,
214 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700215 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800216 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
217 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700218 },
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800219 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800220 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
221 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800222 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
223 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
224 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800225 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700226 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
227 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
228 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800229 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
230 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700231 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800232 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400233}
234
235 x__xgafv: string, V1 error format.
236 Allowed values
237 1 - v1 error format
238 2 - v2 error format
239
240Returns:
241 An object of the form:
242
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700243 { # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800244 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
245 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
246 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
247 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
248 &quot;A String&quot;,
249 ],
250 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
251 &quot;A String&quot;,
252 ],
253 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
254 &quot;A String&quot;,
255 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700256 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800257 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
258 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
259 },
260 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
261 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
262 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
263 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
264 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
265 },
266 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700267 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
268 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
269 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800270 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
271 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700272 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800273 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
274}</pre>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400275</div>
276
277<div class="method">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700278 <code class="details" id="destroy">destroy(name, body=None, x__xgafv=None)</code>
yoshi-code-botcdf480e2021-08-17 00:20:40 -0700279 <pre>Schedule a CryptoKeyVersion for destruction. Upon calling this method, CryptoKeyVersion.state will be set to DESTROY_SCHEDULED, and destroy_time will be set to the time destroy_scheduled_duration in the future. At that time, the state will automatically change to DESTROYED, and the key material will be irrevocably destroyed. Before the destroy_time is reached, RestoreCryptoKeyVersion may be called to reverse the process.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400280
281Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700282 name: string, Required. The resource name of the CryptoKeyVersion to destroy. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700283 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400284 The object takes the form of:
285
286{ # Request message for KeyManagementService.DestroyCryptoKeyVersion.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800287}
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400288
289 x__xgafv: string, V1 error format.
290 Allowed values
291 1 - v1 error format
292 2 - v2 error format
293
294Returns:
295 An object of the form:
296
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700297 { # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800298 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
299 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
300 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
301 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
302 &quot;A String&quot;,
303 ],
304 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
305 &quot;A String&quot;,
306 ],
307 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
308 &quot;A String&quot;,
309 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700310 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800311 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
312 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
313 },
314 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
315 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
316 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
317 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
318 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
319 },
320 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700321 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
322 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
323 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800324 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
325 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700326 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800327 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
328}</pre>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400329</div>
330
331<div class="method">
332 <code class="details" id="get">get(name, x__xgafv=None)</code>
333 <pre>Returns metadata for a given CryptoKeyVersion.
334
335Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700336 name: string, Required. The name of the CryptoKeyVersion to get. (required)
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400337 x__xgafv: string, V1 error format.
338 Allowed values
339 1 - v1 error format
340 2 - v2 error format
341
342Returns:
343 An object of the form:
344
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700345 { # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800346 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
347 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
348 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
349 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
350 &quot;A String&quot;,
351 ],
352 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
353 &quot;A String&quot;,
354 ],
355 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
356 &quot;A String&quot;,
357 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700358 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800359 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
360 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
361 },
362 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
363 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
364 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
365 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
366 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
367 },
368 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700369 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
370 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
371 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800372 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
373 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700374 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800375 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
376}</pre>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400377</div>
378
379<div class="method">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700380 <code class="details" id="getPublicKey">getPublicKey(name, x__xgafv=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700381 <pre>Returns the public key for the given CryptoKeyVersion. The CryptoKey.purpose must be ASYMMETRIC_SIGN or ASYMMETRIC_DECRYPT.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700382
383Args:
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700384 name: string, Required. The name of the CryptoKeyVersion public key to get. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700385 x__xgafv: string, V1 error format.
386 Allowed values
387 1 - v1 error format
388 2 - v2 error format
389
390Returns:
391 An object of the form:
392
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700393 { # The public key for a given CryptoKeyVersion. Obtained via GetPublicKey.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800394 &quot;algorithm&quot;: &quot;A String&quot;, # The Algorithm associated with this key.
395 &quot;name&quot;: &quot;A String&quot;, # The name of the CryptoKeyVersion public key. Provided here for verification. NOTE: This field is in Beta.
396 &quot;pem&quot;: &quot;A String&quot;, # The public key, encoded in PEM format. For more information, see the [RFC 7468](https://tools.ietf.org/html/rfc7468) sections for [General Considerations](https://tools.ietf.org/html/rfc7468#section-2) and [Textual Encoding of Subject Public Key Info] (https://tools.ietf.org/html/rfc7468#section-13).
397 &quot;pemCrc32c&quot;: &quot;A String&quot;, # Integrity verification field. A CRC32C checksum of the returned PublicKey.pem. An integrity check of PublicKey.pem can be performed by computing the CRC32C checksum of PublicKey.pem and comparing your results to this field. Discard the response in case of non-matching checksum values, and perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type. NOTE: This field is in Beta.
yoshi-code-botb6dc1b92021-03-02 11:49:08 -0800398 &quot;protectionLevel&quot;: &quot;A String&quot;, # The ProtectionLevel of the CryptoKeyVersion public key.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800399}</pre>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700400</div>
401
402<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700403 <code class="details" id="import_">import_(parent, body=None, x__xgafv=None)</code>
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700404 <pre>Import wrapped key material into a CryptoKeyVersion. All requests must specify a CryptoKey. If a CryptoKeyVersion is additionally specified in the request, key material will be reimported into that version. Otherwise, a new version will be created, and will be assigned the next sequential id within the CryptoKey.
Dan O'Mearadd494642020-05-01 07:42:23 -0700405
406Args:
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700407 parent: string, Required. The name of the CryptoKey to be imported into. The create permission is only required on this key when creating a new CryptoKeyVersion. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700408 body: object, The request body.
409 The object takes the form of:
410
411{ # Request message for KeyManagementService.ImportCryptoKeyVersion.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800412 &quot;algorithm&quot;: &quot;A String&quot;, # Required. The algorithm of the key being imported. This does not need to match the version_template of the CryptoKey this version imports into.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700413 &quot;cryptoKeyVersion&quot;: &quot;A String&quot;, # Optional. The optional name of an existing CryptoKeyVersion to target for an import operation. If this field is not present, a new CryptoKeyVersion containing the supplied key material is created. If this field is present, the supplied key material is imported into the existing CryptoKeyVersion. To import into an existing CryptoKeyVersion, the CryptoKeyVersion must be a child of ImportCryptoKeyVersionRequest.parent, have been previously created via ImportCryptoKeyVersion, and be in DESTROYED or IMPORT_FAILED state. The key material and algorithm must match the previous CryptoKeyVersion exactly if the CryptoKeyVersion has ever contained key material.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800414 &quot;importJob&quot;: &quot;A String&quot;, # Required. The name of the ImportJob that was used to wrap this key material.
415 &quot;rsaAesWrappedKey&quot;: &quot;A String&quot;, # Wrapped key material produced with RSA_OAEP_3072_SHA1_AES_256 or RSA_OAEP_4096_SHA1_AES_256. This field contains the concatenation of two wrapped keys: 1. An ephemeral AES-256 wrapping key wrapped with the public_key using RSAES-OAEP with SHA-1, MGF1 with SHA-1, and an empty label. 2. The key to be imported, wrapped with the ephemeral AES-256 key using AES-KWP (RFC 5649). If importing symmetric key material, it is expected that the unwrapped key contains plain bytes. If importing asymmetric key material, it is expected that the unwrapped key is in PKCS#8-encoded DER format (the PrivateKeyInfo structure from RFC 5208). This format is the same as the format produced by PKCS#11 mechanism CKM_RSA_AES_KEY_WRAP.
416}
Dan O'Mearadd494642020-05-01 07:42:23 -0700417
418 x__xgafv: string, V1 error format.
419 Allowed values
420 1 - v1 error format
421 2 - v2 error format
422
423Returns:
424 An object of the form:
425
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700426 { # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800427 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
428 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
429 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
430 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
431 &quot;A String&quot;,
432 ],
433 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
434 &quot;A String&quot;,
435 ],
436 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
437 &quot;A String&quot;,
438 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700439 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800440 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
441 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
442 },
443 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
444 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
445 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
446 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
447 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
448 },
449 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700450 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
451 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
452 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800453 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
454 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700455 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800456 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
457}</pre>
Dan O'Mearadd494642020-05-01 07:42:23 -0700458</div>
459
460<div class="method">
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800461 <code class="details" id="list">list(parent, filter=None, orderBy=None, pageSize=None, pageToken=None, view=None, x__xgafv=None)</code>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400462 <pre>Lists CryptoKeyVersions.
463
464Args:
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700465 parent: string, Required. The resource name of the CryptoKey to list, in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*`. (required)
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800466 filter: string, Optional. Only include resources that match the filter in the response. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering).
467 orderBy: string, Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see [Sorting and filtering list results](https://cloud.google.com/kms/docs/sorting-and-filtering).
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800468 pageSize: integer, Optional. Optional limit on the number of CryptoKeyVersions to include in the response. Further CryptoKeyVersions can subsequently be obtained by including the ListCryptoKeyVersionsResponse.next_page_token in a subsequent request. If unspecified, the server will pick an appropriate default.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800469 pageToken: string, Optional. Optional pagination token, returned earlier via ListCryptoKeyVersionsResponse.next_page_token.
Bu Sun Kim65020912020-05-20 12:08:20 -0700470 view: string, The fields to include in the response.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700471 Allowed values
472 CRYPTO_KEY_VERSION_VIEW_UNSPECIFIED - Default view for each CryptoKeyVersion. Does not include the attestation field.
473 FULL - Provides all fields in each CryptoKeyVersion, including the attestation.
Bu Sun Kim65020912020-05-20 12:08:20 -0700474 x__xgafv: string, V1 error format.
475 Allowed values
476 1 - v1 error format
477 2 - v2 error format
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400478
479Returns:
480 An object of the form:
481
482 { # Response message for KeyManagementService.ListCryptoKeyVersions.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800483 &quot;cryptoKeyVersions&quot;: [ # The list of CryptoKeyVersions.
484 { # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
485 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
486 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
487 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
488 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
489 &quot;A String&quot;,
490 ],
491 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
492 &quot;A String&quot;,
493 ],
494 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
495 &quot;A String&quot;,
496 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700497 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800498 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
499 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400500 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800501 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
502 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
503 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
504 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
505 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
506 },
507 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700508 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
509 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
510 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800511 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
512 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700513 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800514 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
515 },
516 ],
517 &quot;nextPageToken&quot;: &quot;A String&quot;, # A token to retrieve next page of results. Pass this value in ListCryptoKeyVersionsRequest.page_token to retrieve the next page of results.
518 &quot;totalSize&quot;: 42, # The total number of CryptoKeyVersions that matched the query.
519}</pre>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400520</div>
521
522<div class="method">
523 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
524 <pre>Retrieves the next page of results.
525
526Args:
527 previous_request: The request for the previous page. (required)
528 previous_response: The response from the request for the previous page. (required)
529
530Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -0700531 A request object that you can call &#x27;execute()&#x27; on to request the next
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400532 page. Returns None if there are no more items in the collection.
533 </pre>
534</div>
535
536<div class="method">
yoshi-code-botb539cc42021-08-03 00:20:27 -0700537 <code class="details" id="macSign">macSign(name, body=None, x__xgafv=None)</code>
538 <pre>Signs data using a CryptoKeyVersion with CryptoKey.purpose MAC, producing a tag that can be verified by another source with the same key.
539
540Args:
541 name: string, Required. The resource name of the CryptoKeyVersion to use for signing. (required)
542 body: object, The request body.
543 The object takes the form of:
544
545{ # Request message for KeyManagementService.MacSign.
546 &quot;data&quot;: &quot;A String&quot;, # Required. The data to sign. The MAC tag is computed over this data field based on the specific algorithm.
547 &quot;dataCrc32c&quot;: &quot;A String&quot;, # Optional. An optional CRC32C checksum of the MacSignRequest.data. If specified, KeyManagementService will verify the integrity of the received MacSignRequest.data using this checksum. KeyManagementService will report an error if the checksum verification fails. If you receive a checksum error, your client should verify that CRC32C(MacSignRequest.data) is equal to MacSignRequest.data_crc32c, and if so, perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
548}
549
550 x__xgafv: string, V1 error format.
551 Allowed values
552 1 - v1 error format
553 2 - v2 error format
554
555Returns:
556 An object of the form:
557
558 { # Response message for KeyManagementService.MacSign.
559 &quot;mac&quot;: &quot;A String&quot;, # The created signature.
560 &quot;macCrc32c&quot;: &quot;A String&quot;, # Integrity verification field. A CRC32C checksum of the returned MacSignResponse.mac. An integrity check of MacSignResponse.mac can be performed by computing the CRC32C checksum of MacSignResponse.mac and comparing your results to this field. Discard the response in case of non-matching checksum values, and perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
561 &quot;name&quot;: &quot;A String&quot;, # The resource name of the CryptoKeyVersion used for signing. Check this field to verify that the intended resource was used for signing.
562 &quot;protectionLevel&quot;: &quot;A String&quot;, # The ProtectionLevel of the CryptoKeyVersion used for signing.
563 &quot;verifiedDataCrc32c&quot;: True or False, # Integrity verification field. A flag indicating whether MacSignRequest.data_crc32c was received by KeyManagementService and used for the integrity verification of the data. A false value of this field indicates either that MacSignRequest.data_crc32c was left unset or that it was not delivered to KeyManagementService. If you&#x27;ve set MacSignRequest.data_crc32c but this field is still false, discard the response and perform a limited number of retries.
564}</pre>
565</div>
566
567<div class="method">
568 <code class="details" id="macVerify">macVerify(name, body=None, x__xgafv=None)</code>
569 <pre>Verifies MAC tag using a CryptoKeyVersion with CryptoKey.purpose MAC, and returns a response that indicates whether or not the verification was successful.
570
571Args:
572 name: string, Required. The resource name of the CryptoKeyVersion to use for verification. (required)
573 body: object, The request body.
574 The object takes the form of:
575
576{ # Request message for KeyManagementService.MacVerify.
577 &quot;data&quot;: &quot;A String&quot;, # Required. The data used previously as a MacSignRequest.data to generate the MAC tag.
578 &quot;dataCrc32c&quot;: &quot;A String&quot;, # Optional. An optional CRC32C checksum of the MacVerifyRequest.data. If specified, KeyManagementService will verify the integrity of the received MacVerifyRequest.data using this checksum. KeyManagementService will report an error if the checksum verification fails. If you receive a checksum error, your client should verify that CRC32C(MacVerifyRequest.data) is equal to MacVerifyRequest.data_crc32c, and if so, perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
579 &quot;mac&quot;: &quot;A String&quot;, # Required. The signature to verify.
580 &quot;macCrc32c&quot;: &quot;A String&quot;, # Optional. An optional CRC32C checksum of the MacVerifyRequest.mac. If specified, KeyManagementService will verify the integrity of the received MacVerifyRequest.mac using this checksum. KeyManagementService will report an error if the checksum verification fails. If you receive a checksum error, your client should verify that CRC32C(MacVerifyRequest.tag) is equal to MacVerifyRequest.mac_crc32c, and if so, perform a limited number of retries. A persistent mismatch may indicate an issue in your computation of the CRC32C checksum. Note: This field is defined as int64 for reasons of compatibility across different languages. However, it is a non-negative integer, which will never exceed 2^32-1, and can be safely downconverted to uint32 in languages that support this type.
581}
582
583 x__xgafv: string, V1 error format.
584 Allowed values
585 1 - v1 error format
586 2 - v2 error format
587
588Returns:
589 An object of the form:
590
591 { # Response message for KeyManagementService.MacVerify.
592 &quot;name&quot;: &quot;A String&quot;, # The resource name of the CryptoKeyVersion used for verification. Check this field to verify that the intended resource was used for verification.
593 &quot;protectionLevel&quot;: &quot;A String&quot;, # The ProtectionLevel of the CryptoKeyVersion used for verification.
594 &quot;success&quot;: True or False, # This field indicates whether or not the verification operation for MacVerifyRequest.mac over MacVerifyRequest.data was successful.
595 &quot;verifiedDataCrc32c&quot;: True or False, # Integrity verification field. A flag indicating whether MacVerifyRequest.data_crc32c was received by KeyManagementService and used for the integrity verification of the data. A false value of this field indicates either that MacVerifyRequest.data_crc32c was left unset or that it was not delivered to KeyManagementService. If you&#x27;ve set MacVerifyRequest.data_crc32c but this field is still false, discard the response and perform a limited number of retries.
596 &quot;verifiedMacCrc32c&quot;: True or False, # Integrity verification field. A flag indicating whether MacVerifyRequest.mac_crc32c was received by KeyManagementService and used for the integrity verification of the data. A false value of this field indicates either that MacVerifyRequest.mac_crc32c was left unset or that it was not delivered to KeyManagementService. If you&#x27;ve set MacVerifyRequest.mac_crc32c but this field is still false, discard the response and perform a limited number of retries.
597 &quot;verifiedSuccessIntegrity&quot;: True or False, # Integrity verification field. This value is used for the integrity verification of [MacVerifyResponse.success]. If the value of this field contradicts the value of [MacVerifyResponse.success], discard the response and perform a limited number of retries.
598}</pre>
599</div>
600
601<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700602 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700603 <pre>Update a CryptoKeyVersion&#x27;s metadata. state may be changed between ENABLED and DISABLED using this method. See DestroyCryptoKeyVersion and RestoreCryptoKeyVersion to move between other states.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400604
605Args:
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700606 name: string, Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700607 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400608 The object takes the form of:
609
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700610{ # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800611 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700612 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700613 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800614 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700615 &quot;A String&quot;,
616 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800617 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
618 &quot;A String&quot;,
619 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800620 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
621 &quot;A String&quot;,
622 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700623 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800624 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
625 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700626 },
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800627 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800628 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
629 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800630 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
631 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
632 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800633 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700634 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
635 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
636 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800637 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
638 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700639 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800640 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400641}
642
Dan O'Mearadd494642020-05-01 07:42:23 -0700643 updateMask: string, Required. List of fields to be updated in this request.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400644 x__xgafv: string, V1 error format.
645 Allowed values
646 1 - v1 error format
647 2 - v2 error format
648
649Returns:
650 An object of the form:
651
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700652 { # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800653 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
654 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
655 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
656 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
657 &quot;A String&quot;,
658 ],
659 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
660 &quot;A String&quot;,
661 ],
662 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
663 &quot;A String&quot;,
664 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700665 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800666 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
667 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
668 },
669 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
670 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
671 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
672 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
673 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
674 },
675 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700676 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
677 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
678 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800679 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
680 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700681 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800682 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
683}</pre>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400684</div>
685
686<div class="method">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700687 <code class="details" id="restore">restore(name, body=None, x__xgafv=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700688 <pre>Restore a CryptoKeyVersion in the DESTROY_SCHEDULED state. Upon restoration of the CryptoKeyVersion, state will be set to DISABLED, and destroy_time will be cleared.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400689
690Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700691 name: string, Required. The resource name of the CryptoKeyVersion to restore. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700692 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400693 The object takes the form of:
694
695{ # Request message for KeyManagementService.RestoreCryptoKeyVersion.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800696}
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400697
698 x__xgafv: string, V1 error format.
699 Allowed values
700 1 - v1 error format
701 2 - v2 error format
702
703Returns:
704 An object of the form:
705
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700706 { # A CryptoKeyVersion represents an individual cryptographic key, and the associated key material. An ENABLED version can be used for cryptographic operations. For security reasons, the raw cryptographic key material represented by a CryptoKeyVersion can never be viewed or exported. It can only be used to encrypt, decrypt, or sign data when an authorized user or application invokes Cloud KMS.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800707 &quot;algorithm&quot;: &quot;A String&quot;, # Output only. The CryptoKeyVersionAlgorithm that this CryptoKeyVersion supports.
708 &quot;attestation&quot;: { # Contains an HSM-generated attestation about a key operation. For more information, see [Verifying attestations] (https://cloud.google.com/kms/docs/attest-key). # Output only. Statement that was generated and signed by the HSM at key creation time. Use this statement to verify attributes of the key as stored on the HSM, independently of Google. Only provided for key versions with protection_level HSM.
709 &quot;certChains&quot;: { # Certificate chains needed to verify the attestation. Certificates in chains are PEM-encoded and are ordered based on https://tools.ietf.org/html/rfc5246#section-7.4.2. # Output only. The certificate chains needed to validate the attestation
710 &quot;caviumCerts&quot;: [ # Cavium certificate chain corresponding to the attestation.
711 &quot;A String&quot;,
712 ],
713 &quot;googleCardCerts&quot;: [ # Google card certificate chain corresponding to the attestation.
714 &quot;A String&quot;,
715 ],
716 &quot;googlePartitionCerts&quot;: [ # Google partition certificate chain corresponding to the attestation.
717 &quot;A String&quot;,
718 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700719 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800720 &quot;content&quot;: &quot;A String&quot;, # Output only. The attestation data provided by the HSM when the key operation was performed.
721 &quot;format&quot;: &quot;A String&quot;, # Output only. The format of the attestation data.
722 },
723 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion was created.
724 &quot;destroyEventTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was destroyed. Only present if state is DESTROYED.
725 &quot;destroyTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material is scheduled for destruction. Only present if state is DESTROY_SCHEDULED.
726 &quot;externalProtectionLevelOptions&quot;: { # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level. # ExternalProtectionLevelOptions stores a group of additional fields for configuring a CryptoKeyVersion that are specific to the EXTERNAL protection level.
727 &quot;externalKeyUri&quot;: &quot;A String&quot;, # The URI for an external resource that this CryptoKeyVersion represents.
728 },
729 &quot;generateTime&quot;: &quot;A String&quot;, # Output only. The time this CryptoKeyVersion&#x27;s key material was generated.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700730 &quot;importFailureReason&quot;: &quot;A String&quot;, # Output only. The root cause of the most recent import failure. Only present if state is IMPORT_FAILED.
731 &quot;importJob&quot;: &quot;A String&quot;, # Output only. The name of the ImportJob used in the most recent import of this CryptoKeyVersion. Only present if the underlying key material was imported.
732 &quot;importTime&quot;: &quot;A String&quot;, # Output only. The time at which this CryptoKeyVersion&#x27;s key material was most recently imported.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800733 &quot;name&quot;: &quot;A String&quot;, # Output only. The resource name for this CryptoKeyVersion in the format `projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*`.
734 &quot;protectionLevel&quot;: &quot;A String&quot;, # Output only. The ProtectionLevel describing how crypto operations are performed with this CryptoKeyVersion.
yoshi-code-bot8bb904c2021-08-31 00:28:27 -0700735 &quot;reimportEligible&quot;: True or False, # Output only. Whether or not this key version is eligible for reimport, by being specified as a target in ImportCryptoKeyVersionRequest.crypto_key_version.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800736 &quot;state&quot;: &quot;A String&quot;, # The current state of the CryptoKeyVersion.
737}</pre>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400738</div>
739
740</body></html>