public static final class CreateKeyRequest.Builder extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
CreateKeyRequest |
build() |
CreateKeyRequest.Builder |
description(String description)
The operation that you want to perform.
|
CreateKeyRequest.Builder |
DKMSInstanceId(String DKMSInstanceId)
The type of the CMK.
|
CreateKeyRequest.Builder |
enableAutomaticRotation(Boolean enableAutomaticRotation)
The protection level of the CMK.
|
CreateKeyRequest.Builder |
keySpec(String keySpec)
The period of automatic key rotation.
|
CreateKeyRequest.Builder |
keyUsage(String keyUsage)
The description of the CMK.
|
CreateKeyRequest.Builder |
origin(String origin)
The usage of the CMK.
|
CreateKeyRequest.Builder |
protectionLevel(String protectionLevel)
The source of key material.
|
CreateKeyRequest.Builder |
rotationInterval(String rotationInterval)
Specifies whether to enable automatic key rotation.
|
CreateKeyRequest.Builder |
tags(String tags)
Tags.
|
public CreateKeyRequest.Builder DKMSInstanceId(String DKMSInstanceId)
* Aliyun_AES\_256 * Aliyun_AES\_128 * Aliyun_AES\_192 * Aliyun_SM4 * RSA\_2048 * RSA\_3072 * EC_P256 * EC_P256K * EC_SM2 > * The default type of the CMK is Aliyun\_AES\_256. > * Only Dedicated KMS supports Aliyun\_AES\_128 and Aliyun\_AES\_192.
public CreateKeyRequest.Builder description(String description)
public CreateKeyRequest.Builder enableAutomaticRotation(Boolean enableAutomaticRotation)
* SOFTWARE * HSM Default value: SOFTWARE. > * The value of this parameter is case-sensitive. > * Assume that you set this parameter to HSM. If you set the Origin parameter to Aliyun_KMS, the CMK is created in a managed HSM. If you set the Origin parameter to EXTERNAL, you can import an external key into the managed HSM.
public CreateKeyRequest.Builder keySpec(String keySpec)
> If you set the EnableAutomaticRotation parameter to true, you must also specify this parameter. If you set the EnableAutomaticRotation parameter to false, you can leave this parameter unspecified.
public CreateKeyRequest.Builder keyUsage(String keyUsage)
The description can be 0 to 8,192 characters in length.
public CreateKeyRequest.Builder origin(String origin)
* ENCRYPT/DECRYPT: encrypts or decrypts data. * SIGN/VERIFY: generates or verifies a digital signature. If the CMK supports signature verification, the default value is SIGN/VERIFY. If the CMK does not support signature verification, the default value is ENCRYPT/DECRYPT.
public CreateKeyRequest.Builder protectionLevel(String protectionLevel)
* Aliyun_KMS (default value) * EXTERNAL > * The value of this parameter is case-sensitive. > * If you set the KeySpec parameter to an asymmetric CMK type, you are not allowed to set the Origin parameter to EXTERNAL. > * If you set the Origin parameter to EXTERNAL, you must import key material. For more information, see [Import key material](~~68523~~).
public CreateKeyRequest.Builder rotationInterval(String rotationInterval)
* true * false Default value: false. > If the Origin parameter is set to EXTERNAL or the KeySpec parameter is set to an asymmetric CMK type, automatic key rotation is not supported.
public CreateKeyRequest.Builder tags(String tags)
public CreateKeyRequest build()
Copyright © 2023. All rights reserved.