public class KmsClient extends AbstractBceClient
config, DEFAULT_CONTENT_TYPE, DEFAULT_ENCODING, DEFAULT_SERVICE_DOMAIN, URL_PREFIX| Constructor and Description |
|---|
KmsClient() |
KmsClient(KmsClientConfiguration clientConfiguration) |
| Modifier and Type | Method and Description |
|---|---|
void |
cancelKeyDeletion(CancelKeyDeletionRequest request)
Cancels deletion of the specified master key.
|
CreateKeyResponse |
createKey(CreateKeyRequest request)
Creates a new master key.
|
DecryptResponse |
decrypt(DecryptRequest request)
Returns DecryptResponse containing plaintext which is decrypted using ciphertext.
|
DescribeKeyResponse |
describeKey(DescribeKeyRequest request)
Returns DescribeKeyResponse containing deletionDate of specified master key and master key id.
|
void |
disableKey(DisableKeyRequest request)
Disable the specified master key.
|
void |
enableKey(EnableKeyRequest request)
Enable the specified master key.
|
EncryptResponse |
encrypt(EncryptRequest request)
Returns EncryptResponse containing ciphertext which is encrypted using plaintext by master key.
|
GenerateDataKeyResponse |
generateDataKey(GenerateDataKeyRequest request)
Returns GenerateDataKeyResponse containing ciphertext, keyId and plaintext which is random generated
by kms.
|
GetParametersForImportResponse |
getParametersForImport(GetParametersForImportRequest request) |
KmsResponse |
importAsymmetricKey(ImportAsymmetricKeyRequest request) |
KmsResponse |
importKey(ImportKeyRequest request) |
ListKeysResponse |
listKeys(ListKeysRequest request)
Returns ListKeysResponse containing master keys.
|
ScheduleKeyDeletionResponse |
scheduleKeyDeletion(ScheduleKeyDeletionRequest request)
Returns ScheduleKeyDeletionResponse containing deletionDate of specified master key and master key id.
|
void |
setInternalRequest(InternalRequest internalRequest,
StringWriter writer)
set InternalRequest with StringWriter
|
UpdateRotationResponse |
updateRotateKey(UpdateRotationRequest request) |
computeBktVirEndpoint, computeServiceId, getBktVirEndpoint, getClient, getEndpoint, getServiceId, invokeHttpClient, isRegionSupported, setClient, shutdownpublic KmsClient()
public KmsClient(KmsClientConfiguration clientConfiguration)
public CreateKeyResponse createKey(CreateKeyRequest request) throws Exception
request - The request object containing all options for creating master key.Exceptionpublic ListKeysResponse listKeys(ListKeysRequest request) throws Exception
request - The request object containing limit and marker for listing master keys.Exceptionpublic EncryptResponse encrypt(EncryptRequest request) throws Exception
request - The request object containing masterKeyId and plaintext.Exceptionpublic DecryptResponse decrypt(DecryptRequest request) throws Exception
request - The request object containing ciphertext.Exceptionpublic GenerateDataKeyResponse generateDataKey(GenerateDataKeyRequest request) throws Exception
request - The request object containing master key id, keySpec and numberOfBytes.Exceptionpublic void enableKey(EnableKeyRequest request) throws Exception
request - The request object containing master key id.Exceptionpublic void disableKey(DisableKeyRequest request) throws Exception
request - The request object containing master key id.Exceptionpublic ScheduleKeyDeletionResponse scheduleKeyDeletion(ScheduleKeyDeletionRequest request) throws Exception
request - The request object containing master key id, pendingWindowsInDays.Exceptionpublic void cancelKeyDeletion(CancelKeyDeletionRequest request) throws Exception
request - The request object containing master key id.Exceptionpublic DescribeKeyResponse describeKey(DescribeKeyRequest request) throws Exception
request - The request object containing master key id, pendingWindowsInDays.Exceptionpublic GetParametersForImportResponse getParametersForImport(GetParametersForImportRequest request) throws Exception
Exceptionpublic KmsResponse importKey(ImportKeyRequest request) throws Exception
Exceptionpublic KmsResponse importAsymmetricKey(ImportAsymmetricKeyRequest request) throws Exception
Exceptionpublic UpdateRotationResponse updateRotateKey(UpdateRotationRequest request) throws Exception
Exceptionpublic void setInternalRequest(InternalRequest internalRequest, StringWriter writer)
internalRequest - writer - Copyright © 2023. All rights reserved.