- 2.56.0 (latest)
- 2.55.0
- 2.54.0
- 2.52.0
- 2.51.0
- 2.50.0
- 2.49.0
- 2.48.0
- 2.47.0
- 2.46.0
- 2.45.0
- 2.44.0
- 2.43.0
- 2.42.0
- 2.40.0
- 2.39.0
- 2.38.0
- 2.37.0
- 2.36.0
- 2.35.0
- 2.34.0
- 2.33.0
- 2.32.0
- 2.31.0
- 2.30.0
- 2.27.0
- 2.26.0
- 2.25.0
- 2.24.0
- 2.23.0
- 2.22.0
- 2.21.0
- 2.20.0
- 2.19.0
- 2.18.0
- 2.17.0
- 2.16.0
- 2.15.0
- 2.14.0
- 2.12.0
- 2.11.0
- 2.10.0
- 2.9.0
- 2.8.0
- 2.7.0
- 2.6.8
- 2.5.3
- 2.4.4
- 2.3.1
public abstract static class KeyManagementServiceGrpc.KeyManagementServiceImplBase implements BindableService
Google Cloud Key Management Service Manages cryptographic keys and operations using those keys. Implements a REST model with the following objects:
- KeyRing
- CryptoKey
- CryptoKeyVersion
- ImportJob If you are using manual gRPC libraries, see Using gRPC with Cloud KMS.
Implements
io.grpc.BindableServiceConstructors
KeyManagementServiceImplBase()
public KeyManagementServiceImplBase()
Methods
asymmetricDecrypt(AsymmetricDecryptRequest request, StreamObserver<AsymmetricDecryptResponse> responseObserver)
public void asymmetricDecrypt(AsymmetricDecryptRequest request, StreamObserver<AsymmetricDecryptResponse> responseObserver)
Decrypts data that was encrypted with a public key retrieved from GetPublicKey corresponding to a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_DECRYPT.
Name | Description |
request | AsymmetricDecryptRequest |
responseObserver | io.grpc.stub.StreamObserver<AsymmetricDecryptResponse> |
asymmetricSign(AsymmetricSignRequest request, StreamObserver<AsymmetricSignResponse> responseObserver)
public void asymmetricSign(AsymmetricSignRequest request, StreamObserver<AsymmetricSignResponse> responseObserver)
Signs data using a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_SIGN, producing a signature that can be verified with the public key retrieved from GetPublicKey.
Name | Description |
request | AsymmetricSignRequest |
responseObserver | io.grpc.stub.StreamObserver<AsymmetricSignResponse> |
bindService()
public final ServerServiceDefinition bindService()
Type | Description |
io.grpc.ServerServiceDefinition |
createCryptoKey(CreateCryptoKeyRequest request, StreamObserver<CryptoKey> responseObserver)
public void createCryptoKey(CreateCryptoKeyRequest request, StreamObserver<CryptoKey> responseObserver)
Create a new CryptoKey within a KeyRing. CryptoKey.purpose and CryptoKey.version_template.algorithm are required.
Name | Description |
request | CreateCryptoKeyRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKey> |
createCryptoKeyVersion(CreateCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
public void createCryptoKeyVersion(CreateCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
Create a new CryptoKeyVersion in a CryptoKey. The server will assign the next sequential id. If unset, state will be set to ENABLED.
Name | Description |
request | CreateCryptoKeyVersionRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKeyVersion> |
createImportJob(CreateImportJobRequest request, StreamObserver<ImportJob> responseObserver)
public void createImportJob(CreateImportJobRequest request, StreamObserver<ImportJob> responseObserver)
Create a new ImportJob within a KeyRing. ImportJob.import_method is required.
Name | Description |
request | CreateImportJobRequest |
responseObserver | io.grpc.stub.StreamObserver<ImportJob> |
createKeyRing(CreateKeyRingRequest request, StreamObserver<KeyRing> responseObserver)
public void createKeyRing(CreateKeyRingRequest request, StreamObserver<KeyRing> responseObserver)
Create a new KeyRing in a given Project and Location.
Name | Description |
request | CreateKeyRingRequest |
responseObserver | io.grpc.stub.StreamObserver<KeyRing> |
decrypt(DecryptRequest request, StreamObserver<DecryptResponse> responseObserver)
public void decrypt(DecryptRequest request, StreamObserver<DecryptResponse> responseObserver)
Decrypts data that was protected by Encrypt. The CryptoKey.purpose must be ENCRYPT_DECRYPT.
Name | Description |
request | DecryptRequest |
responseObserver | io.grpc.stub.StreamObserver<DecryptResponse> |
destroyCryptoKeyVersion(DestroyCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
public void destroyCryptoKeyVersion(DestroyCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
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.
Name | Description |
request | DestroyCryptoKeyVersionRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKeyVersion> |
encrypt(EncryptRequest request, StreamObserver<EncryptResponse> responseObserver)
public void encrypt(EncryptRequest request, StreamObserver<EncryptResponse> responseObserver)
Encrypts data, so that it can only be recovered by a call to Decrypt. The CryptoKey.purpose must be ENCRYPT_DECRYPT.
Name | Description |
request | EncryptRequest |
responseObserver | io.grpc.stub.StreamObserver<EncryptResponse> |
generateRandomBytes(GenerateRandomBytesRequest request, StreamObserver<GenerateRandomBytesResponse> responseObserver)
public void generateRandomBytes(GenerateRandomBytesRequest request, StreamObserver<GenerateRandomBytesResponse> responseObserver)
Generate random bytes using the Cloud KMS randomness source in the provided location.
Name | Description |
request | GenerateRandomBytesRequest |
responseObserver | io.grpc.stub.StreamObserver<GenerateRandomBytesResponse> |
getCryptoKey(GetCryptoKeyRequest request, StreamObserver<CryptoKey> responseObserver)
public void getCryptoKey(GetCryptoKeyRequest request, StreamObserver<CryptoKey> responseObserver)
Returns metadata for a given CryptoKey, as well as its primary CryptoKeyVersion.
Name | Description |
request | GetCryptoKeyRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKey> |
getCryptoKeyVersion(GetCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
public void getCryptoKeyVersion(GetCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
Returns metadata for a given CryptoKeyVersion.
Name | Description |
request | GetCryptoKeyVersionRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKeyVersion> |
getImportJob(GetImportJobRequest request, StreamObserver<ImportJob> responseObserver)
public void getImportJob(GetImportJobRequest request, StreamObserver<ImportJob> responseObserver)
Returns metadata for a given ImportJob.
Name | Description |
request | GetImportJobRequest |
responseObserver | io.grpc.stub.StreamObserver<ImportJob> |
getKeyRing(GetKeyRingRequest request, StreamObserver<KeyRing> responseObserver)
public void getKeyRing(GetKeyRingRequest request, StreamObserver<KeyRing> responseObserver)
Returns metadata for a given KeyRing.
Name | Description |
request | GetKeyRingRequest |
responseObserver | io.grpc.stub.StreamObserver<KeyRing> |
getPublicKey(GetPublicKeyRequest request, StreamObserver<PublicKey> responseObserver)
public void getPublicKey(GetPublicKeyRequest request, StreamObserver<PublicKey> responseObserver)
Returns the public key for the given CryptoKeyVersion. The CryptoKey.purpose must be ASYMMETRIC_SIGN or ASYMMETRIC_DECRYPT.
Name | Description |
request | GetPublicKeyRequest |
responseObserver | io.grpc.stub.StreamObserver<PublicKey> |
importCryptoKeyVersion(ImportCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
public void importCryptoKeyVersion(ImportCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
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.
Name | Description |
request | ImportCryptoKeyVersionRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKeyVersion> |
listCryptoKeyVersions(ListCryptoKeyVersionsRequest request, StreamObserver<ListCryptoKeyVersionsResponse> responseObserver)
public void listCryptoKeyVersions(ListCryptoKeyVersionsRequest request, StreamObserver<ListCryptoKeyVersionsResponse> responseObserver)
Lists CryptoKeyVersions.
Name | Description |
request | ListCryptoKeyVersionsRequest |
responseObserver | io.grpc.stub.StreamObserver<ListCryptoKeyVersionsResponse> |
listCryptoKeys(ListCryptoKeysRequest request, StreamObserver<ListCryptoKeysResponse> responseObserver)
public void listCryptoKeys(ListCryptoKeysRequest request, StreamObserver<ListCryptoKeysResponse> responseObserver)
Lists CryptoKeys.
Name | Description |
request | ListCryptoKeysRequest |
responseObserver | io.grpc.stub.StreamObserver<ListCryptoKeysResponse> |
listImportJobs(ListImportJobsRequest request, StreamObserver<ListImportJobsResponse> responseObserver)
public void listImportJobs(ListImportJobsRequest request, StreamObserver<ListImportJobsResponse> responseObserver)
Lists ImportJobs.
Name | Description |
request | ListImportJobsRequest |
responseObserver | io.grpc.stub.StreamObserver<ListImportJobsResponse> |
listKeyRings(ListKeyRingsRequest request, StreamObserver<ListKeyRingsResponse> responseObserver)
public void listKeyRings(ListKeyRingsRequest request, StreamObserver<ListKeyRingsResponse> responseObserver)
Lists KeyRings.
Name | Description |
request | ListKeyRingsRequest |
responseObserver | io.grpc.stub.StreamObserver<ListKeyRingsResponse> |
macSign(MacSignRequest request, StreamObserver<MacSignResponse> responseObserver)
public void macSign(MacSignRequest request, StreamObserver<MacSignResponse> responseObserver)
Signs data using a CryptoKeyVersion with CryptoKey.purpose MAC, producing a tag that can be verified by another source with the same key.
Name | Description |
request | MacSignRequest |
responseObserver | io.grpc.stub.StreamObserver<MacSignResponse> |
macVerify(MacVerifyRequest request, StreamObserver<MacVerifyResponse> responseObserver)
public void macVerify(MacVerifyRequest request, StreamObserver<MacVerifyResponse> responseObserver)
Verifies MAC tag using a CryptoKeyVersion with CryptoKey.purpose MAC, and returns a response that indicates whether or not the verification was successful.
Name | Description |
request | MacVerifyRequest |
responseObserver | io.grpc.stub.StreamObserver<MacVerifyResponse> |
restoreCryptoKeyVersion(RestoreCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
public void restoreCryptoKeyVersion(RestoreCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
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.
Name | Description |
request | RestoreCryptoKeyVersionRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKeyVersion> |
updateCryptoKey(UpdateCryptoKeyRequest request, StreamObserver<CryptoKey> responseObserver)
public void updateCryptoKey(UpdateCryptoKeyRequest request, StreamObserver<CryptoKey> responseObserver)
Update a CryptoKey.
Name | Description |
request | UpdateCryptoKeyRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKey> |
updateCryptoKeyPrimaryVersion(UpdateCryptoKeyPrimaryVersionRequest request, StreamObserver<CryptoKey> responseObserver)
public void updateCryptoKeyPrimaryVersion(UpdateCryptoKeyPrimaryVersionRequest request, StreamObserver<CryptoKey> responseObserver)
Update the version of a CryptoKey that will be used in Encrypt. Returns an error if called on a key whose purpose is not ENCRYPT_DECRYPT.
Name | Description |
request | UpdateCryptoKeyPrimaryVersionRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKey> |
updateCryptoKeyVersion(UpdateCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
public void updateCryptoKeyVersion(UpdateCryptoKeyVersionRequest request, StreamObserver<CryptoKeyVersion> responseObserver)
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.
Name | Description |
request | UpdateCryptoKeyVersionRequest |
responseObserver | io.grpc.stub.StreamObserver<CryptoKeyVersion> |