Skip to content
Permalink
Browse files
feat: add support for HMAC, Variable Key Destruction, and GenerateRan…
…dom (#566)

PiperOrigin-RevId: 389008671

Source-Author: Google APIs <noreply@google.com>
Source-Date: Thu Aug 5 13:21:02 2021 -0700
Source-Repo: googleapis/googleapis
Source-Sha: 2efb6951f151116fb7b5766fb4e377db465d49e9
Source-Link: googleapis/googleapis@2efb695
  • Loading branch information
yoshi-automation committed Aug 10, 2021
1 parent 1e54ced commit d1634f20c728f4beccd266403637c9eb8121941d
Showing with 12,885 additions and 1,610 deletions.
  1. +688 −316 google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceClient.java
  2. +57 −25 google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceSettings.java
  3. +9 −0 google-cloud-kms/src/main/java/com/google/cloud/kms/v1/gapic_metadata.json
  4. +171 −75 google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/GrpcKeyManagementServiceStub.java
  5. +29 −10 google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStub.java
  6. +139 −60 google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStubSettings.java
  7. +521 −252 google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientTest.java
  8. +81 −18 google-cloud-kms/src/test/java/com/google/cloud/kms/v1/MockKeyManagementServiceImpl.java
  9. +613 −249 grpc-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceGrpc.java
  10. +0 −12 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricDecryptRequest.java
  11. +0 −3 ...-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricDecryptRequestOrBuilder.java
  12. +152 −16 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricDecryptResponse.java
  13. +25 −4 ...google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricDecryptResponseOrBuilder.java
  14. +0 −12 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricSignRequest.java
  15. +0 −3 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricSignRequestOrBuilder.java
  16. +152 −23 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricSignResponse.java
  17. +25 −6 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/AsymmetricSignResponseOrBuilder.java
  18. +465 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKey.java
  19. +66 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKeyOrBuilder.java
  20. +26 −2 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKeyVersion.java
  21. +0 −24 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecryptRequest.java
  22. +0 −6 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecryptRequestOrBuilder.java
  23. +242 −12 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecryptResponse.java
  24. +38 −3 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecryptResponseOrBuilder.java
  25. +0 −24 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/EncryptRequest.java
  26. +0 −6 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/EncryptRequestOrBuilder.java
  27. +152 −20 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/EncryptResponse.java
  28. +25 −5 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/EncryptResponseOrBuilder.java
  29. +896 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/GenerateRandomBytesRequest.java
  30. +93 −0 ...oogle-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/GenerateRandomBytesRequestOrBuilder.java
  31. +945 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/GenerateRandomBytesResponse.java
  32. +103 −0 ...ogle-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/GenerateRandomBytesResponseOrBuilder.java
  33. +334 −208 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsProto.java
  34. +114 −107 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsResourcesProto.java
  35. +1,175 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacSignRequest.java
  36. +142 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacSignRequestOrBuilder.java
  37. +1,396 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacSignResponse.java
  38. +175 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacSignResponseOrBuilder.java
  39. +1,697 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacVerifyRequest.java
  40. +229 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacVerifyRequestOrBuilder.java
  41. +1,232 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacVerifyResponse.java
  42. +149 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/MacVerifyResponseOrBuilder.java
  43. +152 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/PublicKey.java
  44. +25 −0 proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/PublicKeyOrBuilder.java
  45. +26 −1 proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/resources.proto
  46. +311 −105 proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/service.proto
  47. +15 −3 synth.metadata

Large diffs are not rendered by default.

@@ -171,6 +171,25 @@ public UnaryCallSettings<UpdateCryptoKeyRequest, CryptoKey> updateCryptoKeySetti
return ((KeyManagementServiceStubSettings) getStubSettings()).updateCryptoKeyVersionSettings();
}

/** Returns the object with the settings used for calls to updateCryptoKeyPrimaryVersion. */
public UnaryCallSettings<UpdateCryptoKeyPrimaryVersionRequest, CryptoKey>
updateCryptoKeyPrimaryVersionSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings())
.updateCryptoKeyPrimaryVersionSettings();
}

/** Returns the object with the settings used for calls to destroyCryptoKeyVersion. */
public UnaryCallSettings<DestroyCryptoKeyVersionRequest, CryptoKeyVersion>
destroyCryptoKeyVersionSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).destroyCryptoKeyVersionSettings();
}

/** Returns the object with the settings used for calls to restoreCryptoKeyVersion. */
public UnaryCallSettings<RestoreCryptoKeyVersionRequest, CryptoKeyVersion>
restoreCryptoKeyVersionSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).restoreCryptoKeyVersionSettings();
}

/** Returns the object with the settings used for calls to encrypt. */
public UnaryCallSettings<EncryptRequest, EncryptResponse> encryptSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).encryptSettings();
@@ -192,23 +211,20 @@ public UnaryCallSettings<AsymmetricSignRequest, AsymmetricSignResponse> asymmetr
return ((KeyManagementServiceStubSettings) getStubSettings()).asymmetricDecryptSettings();
}

/** Returns the object with the settings used for calls to updateCryptoKeyPrimaryVersion. */
public UnaryCallSettings<UpdateCryptoKeyPrimaryVersionRequest, CryptoKey>
updateCryptoKeyPrimaryVersionSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings())
.updateCryptoKeyPrimaryVersionSettings();
/** Returns the object with the settings used for calls to macSign. */
public UnaryCallSettings<MacSignRequest, MacSignResponse> macSignSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).macSignSettings();
}

/** Returns the object with the settings used for calls to destroyCryptoKeyVersion. */
public UnaryCallSettings<DestroyCryptoKeyVersionRequest, CryptoKeyVersion>
destroyCryptoKeyVersionSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).destroyCryptoKeyVersionSettings();
/** Returns the object with the settings used for calls to macVerify. */
public UnaryCallSettings<MacVerifyRequest, MacVerifyResponse> macVerifySettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).macVerifySettings();
}

/** Returns the object with the settings used for calls to restoreCryptoKeyVersion. */
public UnaryCallSettings<RestoreCryptoKeyVersionRequest, CryptoKeyVersion>
restoreCryptoKeyVersionSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).restoreCryptoKeyVersionSettings();
/** Returns the object with the settings used for calls to generateRandomBytes. */
public UnaryCallSettings<GenerateRandomBytesRequest, GenerateRandomBytesResponse>
generateRandomBytesSettings() {
return ((KeyManagementServiceStubSettings) getStubSettings()).generateRandomBytesSettings();
}

/** Returns the object with the settings used for calls to setIamPolicy. */
@@ -419,6 +435,24 @@ public UnaryCallSettings.Builder<UpdateCryptoKeyRequest, CryptoKey> updateCrypto
return getStubSettingsBuilder().updateCryptoKeyVersionSettings();
}

/** Returns the builder for the settings used for calls to updateCryptoKeyPrimaryVersion. */
public UnaryCallSettings.Builder<UpdateCryptoKeyPrimaryVersionRequest, CryptoKey>
updateCryptoKeyPrimaryVersionSettings() {
return getStubSettingsBuilder().updateCryptoKeyPrimaryVersionSettings();
}

/** Returns the builder for the settings used for calls to destroyCryptoKeyVersion. */
public UnaryCallSettings.Builder<DestroyCryptoKeyVersionRequest, CryptoKeyVersion>
destroyCryptoKeyVersionSettings() {
return getStubSettingsBuilder().destroyCryptoKeyVersionSettings();
}

/** Returns the builder for the settings used for calls to restoreCryptoKeyVersion. */
public UnaryCallSettings.Builder<RestoreCryptoKeyVersionRequest, CryptoKeyVersion>
restoreCryptoKeyVersionSettings() {
return getStubSettingsBuilder().restoreCryptoKeyVersionSettings();
}

/** Returns the builder for the settings used for calls to encrypt. */
public UnaryCallSettings.Builder<EncryptRequest, EncryptResponse> encryptSettings() {
return getStubSettingsBuilder().encryptSettings();
@@ -441,22 +475,20 @@ public UnaryCallSettings.Builder<DecryptRequest, DecryptResponse> decryptSetting
return getStubSettingsBuilder().asymmetricDecryptSettings();
}

/** Returns the builder for the settings used for calls to updateCryptoKeyPrimaryVersion. */
public UnaryCallSettings.Builder<UpdateCryptoKeyPrimaryVersionRequest, CryptoKey>
updateCryptoKeyPrimaryVersionSettings() {
return getStubSettingsBuilder().updateCryptoKeyPrimaryVersionSettings();
/** Returns the builder for the settings used for calls to macSign. */
public UnaryCallSettings.Builder<MacSignRequest, MacSignResponse> macSignSettings() {
return getStubSettingsBuilder().macSignSettings();
}

/** Returns the builder for the settings used for calls to destroyCryptoKeyVersion. */
public UnaryCallSettings.Builder<DestroyCryptoKeyVersionRequest, CryptoKeyVersion>
destroyCryptoKeyVersionSettings() {
return getStubSettingsBuilder().destroyCryptoKeyVersionSettings();
/** Returns the builder for the settings used for calls to macVerify. */
public UnaryCallSettings.Builder<MacVerifyRequest, MacVerifyResponse> macVerifySettings() {
return getStubSettingsBuilder().macVerifySettings();
}

/** Returns the builder for the settings used for calls to restoreCryptoKeyVersion. */
public UnaryCallSettings.Builder<RestoreCryptoKeyVersionRequest, CryptoKeyVersion>
restoreCryptoKeyVersionSettings() {
return getStubSettingsBuilder().restoreCryptoKeyVersionSettings();
/** Returns the builder for the settings used for calls to generateRandomBytes. */
public UnaryCallSettings.Builder<GenerateRandomBytesRequest, GenerateRandomBytesResponse>
generateRandomBytesSettings() {
return getStubSettingsBuilder().generateRandomBytesSettings();
}

/** Returns the builder for the settings used for calls to setIamPolicy. */
@@ -37,6 +37,9 @@
"Encrypt": {
"methods": ["encrypt", "encrypt", "encrypt", "encryptCallable"]
},
"GenerateRandomBytes": {
"methods": ["generateRandomBytes", "generateRandomBytes", "generateRandomBytesCallable"]
},
"GetCryptoKey": {
"methods": ["getCryptoKey", "getCryptoKey", "getCryptoKey", "getCryptoKeyCallable"]
},
@@ -70,6 +73,12 @@
"ListKeyRings": {
"methods": ["listKeyRings", "listKeyRings", "listKeyRings", "listKeyRingsPagedCallable", "listKeyRingsCallable"]
},
"MacSign": {
"methods": ["macSign", "macSign", "macSign", "macSignCallable"]
},
"MacVerify": {
"methods": ["macVerify", "macVerify", "macVerify", "macVerifyCallable"]
},
"RestoreCryptoKeyVersion": {
"methods": ["restoreCryptoKeyVersion", "restoreCryptoKeyVersion", "restoreCryptoKeyVersion", "restoreCryptoKeyVersionCallable"]
},

0 comments on commit d1634f2

Please sign in to comment.