1- // Copyright 2019 Google LLC.
1+ // Copyright 2020 Google LLC
22//
33// Licensed under the Apache License, Version 2.0 (the "License");
44// you may not use this file except in compliance with the License.
@@ -16,11 +16,11 @@ syntax = "proto3";
1616
1717package google.cloud.kms.v1 ;
1818
19- import "google/api/annotations.proto" ;
2019import "google/api/field_behavior.proto" ;
2120import "google/api/resource.proto" ;
2221import "google/protobuf/duration.proto" ;
2322import "google/protobuf/timestamp.proto" ;
23+ import "google/api/annotations.proto" ;
2424
2525option cc_enable_arenas = true ;
2626option csharp_namespace = "Google.Cloud.Kms.V1" ;
@@ -142,11 +142,6 @@ message CryptoKey {
142142 map <string , string > labels = 10 ;
143143}
144144
145- option (google.api.resource_definition ) = {
146- type : "cloudkms.googleapis.com/CryptoKey"
147- pattern : "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key_path=**}"
148- };
149-
150145// A [CryptoKeyVersionTemplate][google.cloud.kms.v1.CryptoKeyVersionTemplate] specifies the properties to use when creating
151146// a new [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion], either manually with
152147// [CreateCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.CreateCryptoKeyVersion] or
@@ -289,6 +284,9 @@ message CryptoKeyVersion {
289284
290285 // ECDSA on the NIST P-384 curve with a SHA384 digest.
291286 EC_SIGN_P384_SHA384 = 13 ;
287+
288+ // Algorithm representing symmetric encryption by an external key manager.
289+ EXTERNAL_SYMMETRIC_ENCRYPTION = 18 ;
292290 }
293291
294292 // The state of a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion], indicating if it can be used.
@@ -395,11 +393,21 @@ message CryptoKeyVersion {
395393 // [state][google.cloud.kms.v1.CryptoKeyVersion.state] is
396394 // [IMPORT_FAILED][google.cloud.kms.v1.CryptoKeyVersion.CryptoKeyVersionState.IMPORT_FAILED].
397395 string import_failure_reason = 16 [(google.api.field_behavior ) = OUTPUT_ONLY ];
396+
397+ // ExternalProtectionLevelOptions stores a group of additional fields for
398+ // configuring a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] that are specific to the
399+ // [EXTERNAL][google.cloud.kms.v1.ProtectionLevel.EXTERNAL] protection level.
400+ ExternalProtectionLevelOptions external_protection_level_options = 17 ;
398401}
399402
400403// The public key for a given [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]. Obtained via
401404// [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey].
402405message PublicKey {
406+ option (google.api.resource ) = {
407+ type : "cloudkms.googleapis.com/PublicKey"
408+ pattern : "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}/publicKey"
409+ };
410+
403411 // The public key, encoded in PEM format. For more information, see the
404412 // [RFC 7468](https://tools.ietf.org/html/rfc7468) sections for
405413 // [General Considerations](https://tools.ietf.org/html/rfc7468#section-2) and
@@ -565,3 +573,11 @@ enum ProtectionLevel {
565573 // Crypto operations are performed by an external key manager.
566574 EXTERNAL = 3 ;
567575}
576+
577+ // ExternalProtectionLevelOptions stores a group of additional fields for
578+ // configuring a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] that are specific to the
579+ // [EXTERNAL][google.cloud.kms.v1.ProtectionLevel.EXTERNAL] protection level.
580+ message ExternalProtectionLevelOptions {
581+ // The URI for an external resource that this [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] represents.
582+ string external_key_uri = 1 ;
583+ }
0 commit comments