💾 Archived View for gmi.noulin.net › gitRepositories › git-off › file › src › node_modules › aws-sdk… captured on 2023-01-29 at 11:53:02. Gemini links have been rewritten to link to archived content
-=-=-=-=-=-=-
kms.d.ts (81284B)
1 import {Request} from '../lib/request'; 2 import {Response} from '../lib/response'; 3 import {AWSError} from '../lib/error'; 4 import {Service} from '../lib/service'; 5 import {ServiceConfigurationOptions} from '../lib/service'; 6 import {ConfigBase as Config} from '../lib/config'; 7 interface Blob {} 8 declare class KMS extends Service { 9 /** 10 * Constructs a service object. This object has one method for each API operation. 11 */ 12 constructor(options?: KMS.Types.ClientConfiguration) 13 config: Config & KMS.Types.ClientConfiguration; 14 /** 15 * Cancels the deletion of a customer master key (CMK). When this operation is successful, the CMK is set to the Disabled state. To enable a CMK, use EnableKey. For more information about scheduling and canceling deletion of a CMK, see Deleting Customer Master Keys in the AWS Key Management Service Developer Guide. 16 */ 17 cancelKeyDeletion(params: KMS.Types.CancelKeyDeletionRequest, callback?: (err: AWSError, data: KMS.Types.CancelKeyDeletionResponse) => void): Request<KMS.Types.CancelKeyDeletionResponse, AWSError>; 18 /** 19 * Cancels the deletion of a customer master key (CMK). When this operation is successful, the CMK is set to the Disabled state. To enable a CMK, use EnableKey. For more information about scheduling and canceling deletion of a CMK, see Deleting Customer Master Keys in the AWS Key Management Service Developer Guide. 20 */ 21 cancelKeyDeletion(callback?: (err: AWSError, data: KMS.Types.CancelKeyDeletionResponse) => void): Request<KMS.Types.CancelKeyDeletionResponse, AWSError>; 22 /** 23 * Creates a display name for a customer master key. An alias can be used to identify a key and should be unique. The console enforces a one-to-one mapping between the alias and a key. An alias name can contain only alphanumeric characters, forward slashes (/), underscores (_), and dashes (-). An alias must start with the word "alias" followed by a forward slash (alias/). An alias that begins with "aws" after the forward slash (alias/aws...) is reserved by Amazon Web Services (AWS). The alias and the key it is mapped to must be in the same AWS account and the same region. To map an alias to a different key, call UpdateAlias. 24 */ 25 createAlias(params: KMS.Types.CreateAliasRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 26 /** 27 * Creates a display name for a customer master key. An alias can be used to identify a key and should be unique. The console enforces a one-to-one mapping between the alias and a key. An alias name can contain only alphanumeric characters, forward slashes (/), underscores (_), and dashes (-). An alias must start with the word "alias" followed by a forward slash (alias/). An alias that begins with "aws" after the forward slash (alias/aws...) is reserved by Amazon Web Services (AWS). The alias and the key it is mapped to must be in the same AWS account and the same region. To map an alias to a different key, call UpdateAlias. 28 */ 29 createAlias(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 30 /** 31 * Adds a grant to a key to specify who can use the key and under what conditions. Grants are alternate permission mechanisms to key policies. For more information about grants, see Grants in the AWS Key Management Service Developer Guide. 32 */ 33 createGrant(params: KMS.Types.CreateGrantRequest, callback?: (err: AWSError, data: KMS.Types.CreateGrantResponse) => void): Request<KMS.Types.CreateGrantResponse, AWSError>; 34 /** 35 * Adds a grant to a key to specify who can use the key and under what conditions. Grants are alternate permission mechanisms to key policies. For more information about grants, see Grants in the AWS Key Management Service Developer Guide. 36 */ 37 createGrant(callback?: (err: AWSError, data: KMS.Types.CreateGrantResponse) => void): Request<KMS.Types.CreateGrantResponse, AWSError>; 38 /** 39 * Creates a customer master key (CMK). You can use a CMK to encrypt small amounts of data (4 KiB or less) directly, but CMKs are more commonly used to encrypt data encryption keys (DEKs), which are used to encrypt raw data. For more information about DEKs and the difference between CMKs and DEKs, see the following: The GenerateDataKey operation AWS Key Management Service Concepts in the AWS Key Management Service Developer Guide 40 */ 41 createKey(params: KMS.Types.CreateKeyRequest, callback?: (err: AWSError, data: KMS.Types.CreateKeyResponse) => void): Request<KMS.Types.CreateKeyResponse, AWSError>; 42 /** 43 * Creates a customer master key (CMK). You can use a CMK to encrypt small amounts of data (4 KiB or less) directly, but CMKs are more commonly used to encrypt data encryption keys (DEKs), which are used to encrypt raw data. For more information about DEKs and the difference between CMKs and DEKs, see the following: The GenerateDataKey operation AWS Key Management Service Concepts in the AWS Key Management Service Developer Guide 44 */ 45 createKey(callback?: (err: AWSError, data: KMS.Types.CreateKeyResponse) => void): Request<KMS.Types.CreateKeyResponse, AWSError>; 46 /** 47 * Decrypts ciphertext. Ciphertext is plaintext that has been previously encrypted by using any of the following functions: GenerateDataKey GenerateDataKeyWithoutPlaintext Encrypt Note that if a caller has been granted access permissions to all keys (through, for example, IAM user policies that grant Decrypt permission on all resources), then ciphertext encrypted by using keys in other accounts where the key grants access to the caller can be decrypted. To remedy this, we recommend that you do not grant Decrypt access in an IAM user policy. Instead grant Decrypt access only in key policies. If you must grant Decrypt access in an IAM user policy, you should scope the resource to specific keys or to specific trusted accounts. 48 */ 49 decrypt(params: KMS.Types.DecryptRequest, callback?: (err: AWSError, data: KMS.Types.DecryptResponse) => void): Request<KMS.Types.DecryptResponse, AWSError>; 50 /** 51 * Decrypts ciphertext. Ciphertext is plaintext that has been previously encrypted by using any of the following functions: GenerateDataKey GenerateDataKeyWithoutPlaintext Encrypt Note that if a caller has been granted access permissions to all keys (through, for example, IAM user policies that grant Decrypt permission on all resources), then ciphertext encrypted by using keys in other accounts where the key grants access to the caller can be decrypted. To remedy this, we recommend that you do not grant Decrypt access in an IAM user policy. Instead grant Decrypt access only in key policies. If you must grant Decrypt access in an IAM user policy, you should scope the resource to specific keys or to specific trusted accounts. 52 */ 53 decrypt(callback?: (err: AWSError, data: KMS.Types.DecryptResponse) => void): Request<KMS.Types.DecryptResponse, AWSError>; 54 /** 55 * Deletes the specified alias. To map an alias to a different key, call UpdateAlias. 56 */ 57 deleteAlias(params: KMS.Types.DeleteAliasRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 58 /** 59 * Deletes the specified alias. To map an alias to a different key, call UpdateAlias. 60 */ 61 deleteAlias(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 62 /** 63 * Deletes key material that you previously imported and makes the specified customer master key (CMK) unusable. For more information about importing key material into AWS KMS, see Importing Key Material in the AWS Key Management Service Developer Guide. When the specified CMK is in the PendingDeletion state, this operation does not change the CMK's state. Otherwise, it changes the CMK's state to PendingImport. After you delete key material, you can use ImportKeyMaterial to reimport the same key material into the CMK. 64 */ 65 deleteImportedKeyMaterial(params: KMS.Types.DeleteImportedKeyMaterialRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 66 /** 67 * Deletes key material that you previously imported and makes the specified customer master key (CMK) unusable. For more information about importing key material into AWS KMS, see Importing Key Material in the AWS Key Management Service Developer Guide. When the specified CMK is in the PendingDeletion state, this operation does not change the CMK's state. Otherwise, it changes the CMK's state to PendingImport. After you delete key material, you can use ImportKeyMaterial to reimport the same key material into the CMK. 68 */ 69 deleteImportedKeyMaterial(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 70 /** 71 * Provides detailed information about the specified customer master key. 72 */ 73 describeKey(params: KMS.Types.DescribeKeyRequest, callback?: (err: AWSError, data: KMS.Types.DescribeKeyResponse) => void): Request<KMS.Types.DescribeKeyResponse, AWSError>; 74 /** 75 * Provides detailed information about the specified customer master key. 76 */ 77 describeKey(callback?: (err: AWSError, data: KMS.Types.DescribeKeyResponse) => void): Request<KMS.Types.DescribeKeyResponse, AWSError>; 78 /** 79 * Sets the state of a customer master key (CMK) to disabled, thereby preventing its use for cryptographic operations. For more information about how key state affects the use of a CMK, see How Key State Affects the Use of a Customer Master Key in the AWS Key Management Service Developer Guide. 80 */ 81 disableKey(params: KMS.Types.DisableKeyRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 82 /** 83 * Sets the state of a customer master key (CMK) to disabled, thereby preventing its use for cryptographic operations. For more information about how key state affects the use of a CMK, see How Key State Affects the Use of a Customer Master Key in the AWS Key Management Service Developer Guide. 84 */ 85 disableKey(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 86 /** 87 * Disables rotation of the specified key. 88 */ 89 disableKeyRotation(params: KMS.Types.DisableKeyRotationRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 90 /** 91 * Disables rotation of the specified key. 92 */ 93 disableKeyRotation(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 94 /** 95 * Marks a key as enabled, thereby permitting its use. 96 */ 97 enableKey(params: KMS.Types.EnableKeyRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 98 /** 99 * Marks a key as enabled, thereby permitting its use. 100 */ 101 enableKey(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 102 /** 103 * Enables rotation of the specified customer master key. 104 */ 105 enableKeyRotation(params: KMS.Types.EnableKeyRotationRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 106 /** 107 * Enables rotation of the specified customer master key. 108 */ 109 enableKeyRotation(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 110 /** 111 * Encrypts plaintext into ciphertext by using a customer master key. The Encrypt function has two primary use cases: You can encrypt up to 4 KB of arbitrary data such as an RSA key, a database password, or other sensitive customer information. If you are moving encrypted data from one region to another, you can use this API to encrypt in the new region the plaintext data key that was used to encrypt the data in the original region. This provides you with an encrypted copy of the data key that can be decrypted in the new region and used there to decrypt the encrypted data. Unless you are moving encrypted data from one region to another, you don't use this function to encrypt a generated data key within a region. You retrieve data keys already encrypted by calling the GenerateDataKey or GenerateDataKeyWithoutPlaintext function. Data keys don't need to be encrypted again by calling Encrypt. If you want to encrypt data locally in your application, you can use the GenerateDataKey function to return a plaintext data encryption key and a copy of the key encrypted under the customer master key (CMK) of your choosing. 112 */ 113 encrypt(params: KMS.Types.EncryptRequest, callback?: (err: AWSError, data: KMS.Types.EncryptResponse) => void): Request<KMS.Types.EncryptResponse, AWSError>; 114 /** 115 * Encrypts plaintext into ciphertext by using a customer master key. The Encrypt function has two primary use cases: You can encrypt up to 4 KB of arbitrary data such as an RSA key, a database password, or other sensitive customer information. If you are moving encrypted data from one region to another, you can use this API to encrypt in the new region the plaintext data key that was used to encrypt the data in the original region. This provides you with an encrypted copy of the data key that can be decrypted in the new region and used there to decrypt the encrypted data. Unless you are moving encrypted data from one region to another, you don't use this function to encrypt a generated data key within a region. You retrieve data keys already encrypted by calling the GenerateDataKey or GenerateDataKeyWithoutPlaintext function. Data keys don't need to be encrypted again by calling Encrypt. If you want to encrypt data locally in your application, you can use the GenerateDataKey function to return a plaintext data encryption key and a copy of the key encrypted under the customer master key (CMK) of your choosing. 116 */ 117 encrypt(callback?: (err: AWSError, data: KMS.Types.EncryptResponse) => void): Request<KMS.Types.EncryptResponse, AWSError>; 118 /** 119 * Returns a data encryption key that you can use in your application to encrypt data locally. You must specify the customer master key (CMK) under which to generate the data key. You must also specify the length of the data key using either the KeySpec or NumberOfBytes field. You must specify one field or the other, but not both. For common key lengths (128-bit and 256-bit symmetric keys), we recommend that you use KeySpec. This operation returns a plaintext copy of the data key in the Plaintext field of the response, and an encrypted copy of the data key in the CiphertextBlob field. The data key is encrypted under the CMK specified in the KeyId field of the request. We recommend that you use the following pattern to encrypt data locally in your application: Use this operation (GenerateDataKey) to retrieve a data encryption key. Use the plaintext data encryption key (returned in the Plaintext field of the response) to encrypt data locally, then erase the plaintext data key from memory. Store the encrypted data key (returned in the CiphertextBlob field of the response) alongside the locally encrypted data. To decrypt data locally: Use the Decrypt operation to decrypt the encrypted data key into a plaintext copy of the data key. Use the plaintext data key to decrypt data locally, then erase the plaintext data key from memory. To return only an encrypted copy of the data key, use GenerateDataKeyWithoutPlaintext. To return an arbitrary unpredictable byte string, use GenerateRandom. If you use the optional EncryptionContext field, you must store at least enough information to be able to reconstruct the full encryption context when you later send the ciphertext to the Decrypt operation. It is a good practice to choose an encryption context that you can reconstruct on the fly to better secure the ciphertext. For more information, see Encryption Context in the AWS Key Management Service Developer Guide. 120 */ 121 generateDataKey(params: KMS.Types.GenerateDataKeyRequest, callback?: (err: AWSError, data: KMS.Types.GenerateDataKeyResponse) => void): Request<KMS.Types.GenerateDataKeyResponse, AWSError>; 122 /** 123 * Returns a data encryption key that you can use in your application to encrypt data locally. You must specify the customer master key (CMK) under which to generate the data key. You must also specify the length of the data key using either the KeySpec or NumberOfBytes field. You must specify one field or the other, but not both. For common key lengths (128-bit and 256-bit symmetric keys), we recommend that you use KeySpec. This operation returns a plaintext copy of the data key in the Plaintext field of the response, and an encrypted copy of the data key in the CiphertextBlob field. The data key is encrypted under the CMK specified in the KeyId field of the request. We recommend that you use the following pattern to encrypt data locally in your application: Use this operation (GenerateDataKey) to retrieve a data encryption key. Use the plaintext data encryption key (returned in the Plaintext field of the response) to encrypt data locally, then erase the plaintext data key from memory. Store the encrypted data key (returned in the CiphertextBlob field of the response) alongside the locally encrypted data. To decrypt data locally: Use the Decrypt operation to decrypt the encrypted data key into a plaintext copy of the data key. Use the plaintext data key to decrypt data locally, then erase the plaintext data key from memory. To return only an encrypted copy of the data key, use GenerateDataKeyWithoutPlaintext. To return an arbitrary unpredictable byte string, use GenerateRandom. If you use the optional EncryptionContext field, you must store at least enough information to be able to reconstruct the full encryption context when you later send the ciphertext to the Decrypt operation. It is a good practice to choose an encryption context that you can reconstruct on the fly to better secure the ciphertext. For more information, see Encryption Context in the AWS Key Management Service Developer Guide. 124 */ 125 generateDataKey(callback?: (err: AWSError, data: KMS.Types.GenerateDataKeyResponse) => void): Request<KMS.Types.GenerateDataKeyResponse, AWSError>; 126 /** 127 * Returns a data encryption key encrypted under a customer master key (CMK). This operation is identical to GenerateDataKey but returns only the encrypted copy of the data key. This operation is useful in a system that has multiple components with different degrees of trust. For example, consider a system that stores encrypted data in containers. Each container stores the encrypted data and an encrypted copy of the data key. One component of the system, called the control plane, creates new containers. When it creates a new container, it uses this operation (GenerateDataKeyWithoutPlaintext) to get an encrypted data key and then stores it in the container. Later, a different component of the system, called the data plane, puts encrypted data into the containers. To do this, it passes the encrypted data key to the Decrypt operation, then uses the returned plaintext data key to encrypt data, and finally stores the encrypted data in the container. In this system, the control plane never sees the plaintext data key. 128 */ 129 generateDataKeyWithoutPlaintext(params: KMS.Types.GenerateDataKeyWithoutPlaintextRequest, callback?: (err: AWSError, data: KMS.Types.GenerateDataKeyWithoutPlaintextResponse) => void): Request<KMS.Types.GenerateDataKeyWithoutPlaintextResponse, AWSError>; 130 /** 131 * Returns a data encryption key encrypted under a customer master key (CMK). This operation is identical to GenerateDataKey but returns only the encrypted copy of the data key. This operation is useful in a system that has multiple components with different degrees of trust. For example, consider a system that stores encrypted data in containers. Each container stores the encrypted data and an encrypted copy of the data key. One component of the system, called the control plane, creates new containers. When it creates a new container, it uses this operation (GenerateDataKeyWithoutPlaintext) to get an encrypted data key and then stores it in the container. Later, a different component of the system, called the data plane, puts encrypted data into the containers. To do this, it passes the encrypted data key to the Decrypt operation, then uses the returned plaintext data key to encrypt data, and finally stores the encrypted data in the container. In this system, the control plane never sees the plaintext data key. 132 */ 133 generateDataKeyWithoutPlaintext(callback?: (err: AWSError, data: KMS.Types.GenerateDataKeyWithoutPlaintextResponse) => void): Request<KMS.Types.GenerateDataKeyWithoutPlaintextResponse, AWSError>; 134 /** 135 * Generates an unpredictable byte string. 136 */ 137 generateRandom(params: KMS.Types.GenerateRandomRequest, callback?: (err: AWSError, data: KMS.Types.GenerateRandomResponse) => void): Request<KMS.Types.GenerateRandomResponse, AWSError>; 138 /** 139 * Generates an unpredictable byte string. 140 */ 141 generateRandom(callback?: (err: AWSError, data: KMS.Types.GenerateRandomResponse) => void): Request<KMS.Types.GenerateRandomResponse, AWSError>; 142 /** 143 * Retrieves a policy attached to the specified key. 144 */ 145 getKeyPolicy(params: KMS.Types.GetKeyPolicyRequest, callback?: (err: AWSError, data: KMS.Types.GetKeyPolicyResponse) => void): Request<KMS.Types.GetKeyPolicyResponse, AWSError>; 146 /** 147 * Retrieves a policy attached to the specified key. 148 */ 149 getKeyPolicy(callback?: (err: AWSError, data: KMS.Types.GetKeyPolicyResponse) => void): Request<KMS.Types.GetKeyPolicyResponse, AWSError>; 150 /** 151 * Retrieves a Boolean value that indicates whether key rotation is enabled for the specified key. 152 */ 153 getKeyRotationStatus(params: KMS.Types.GetKeyRotationStatusRequest, callback?: (err: AWSError, data: KMS.Types.GetKeyRotationStatusResponse) => void): Request<KMS.Types.GetKeyRotationStatusResponse, AWSError>; 154 /** 155 * Retrieves a Boolean value that indicates whether key rotation is enabled for the specified key. 156 */ 157 getKeyRotationStatus(callback?: (err: AWSError, data: KMS.Types.GetKeyRotationStatusResponse) => void): Request<KMS.Types.GetKeyRotationStatusResponse, AWSError>; 158 /** 159 * Returns the items you need in order to import key material into AWS KMS from your existing key management infrastructure. For more information about importing key material into AWS KMS, see Importing Key Material in the AWS Key Management Service Developer Guide. You must specify the key ID of the customer master key (CMK) into which you will import key material. This CMK's Origin must be EXTERNAL. You must also specify the wrapping algorithm and type of wrapping key (public key) that you will use to encrypt the key material. This operation returns a public key and an import token. Use the public key to encrypt the key material. Store the import token to send with a subsequent ImportKeyMaterial request. The public key and import token from the same response must be used together. These items are valid for 24 hours, after which they cannot be used for a subsequent ImportKeyMaterial request. To retrieve new ones, send another GetParametersForImport request. 160 */ 161 getParametersForImport(params: KMS.Types.GetParametersForImportRequest, callback?: (err: AWSError, data: KMS.Types.GetParametersForImportResponse) => void): Request<KMS.Types.GetParametersForImportResponse, AWSError>; 162 /** 163 * Returns the items you need in order to import key material into AWS KMS from your existing key management infrastructure. For more information about importing key material into AWS KMS, see Importing Key Material in the AWS Key Management Service Developer Guide. You must specify the key ID of the customer master key (CMK) into which you will import key material. This CMK's Origin must be EXTERNAL. You must also specify the wrapping algorithm and type of wrapping key (public key) that you will use to encrypt the key material. This operation returns a public key and an import token. Use the public key to encrypt the key material. Store the import token to send with a subsequent ImportKeyMaterial request. The public key and import token from the same response must be used together. These items are valid for 24 hours, after which they cannot be used for a subsequent ImportKeyMaterial request. To retrieve new ones, send another GetParametersForImport request. 164 */ 165 getParametersForImport(callback?: (err: AWSError, data: KMS.Types.GetParametersForImportResponse) => void): Request<KMS.Types.GetParametersForImportResponse, AWSError>; 166 /** 167 * Imports key material into an AWS KMS customer master key (CMK) from your existing key management infrastructure. For more information about importing key material into AWS KMS, see Importing Key Material in the AWS Key Management Service Developer Guide. You must specify the key ID of the CMK to import the key material into. This CMK's Origin must be EXTERNAL. You must also send an import token and the encrypted key material. Send the import token that you received in the same GetParametersForImport response that contained the public key that you used to encrypt the key material. You must also specify whether the key material expires and if so, when. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. To use the CMK again, you can reimport the same key material. If you set an expiration date, you can change it only by reimporting the same key material and specifying a new expiration date. When this operation is successful, the specified CMK's key state changes to Enabled, and you can use the CMK. After you successfully import key material into a CMK, you can reimport the same key material into that CMK, but you cannot import different key material. 168 */ 169 importKeyMaterial(params: KMS.Types.ImportKeyMaterialRequest, callback?: (err: AWSError, data: KMS.Types.ImportKeyMaterialResponse) => void): Request<KMS.Types.ImportKeyMaterialResponse, AWSError>; 170 /** 171 * Imports key material into an AWS KMS customer master key (CMK) from your existing key management infrastructure. For more information about importing key material into AWS KMS, see Importing Key Material in the AWS Key Management Service Developer Guide. You must specify the key ID of the CMK to import the key material into. This CMK's Origin must be EXTERNAL. You must also send an import token and the encrypted key material. Send the import token that you received in the same GetParametersForImport response that contained the public key that you used to encrypt the key material. You must also specify whether the key material expires and if so, when. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. To use the CMK again, you can reimport the same key material. If you set an expiration date, you can change it only by reimporting the same key material and specifying a new expiration date. When this operation is successful, the specified CMK's key state changes to Enabled, and you can use the CMK. After you successfully import key material into a CMK, you can reimport the same key material into that CMK, but you cannot import different key material. 172 */ 173 importKeyMaterial(callback?: (err: AWSError, data: KMS.Types.ImportKeyMaterialResponse) => void): Request<KMS.Types.ImportKeyMaterialResponse, AWSError>; 174 /** 175 * Lists all of the key aliases in the account. 176 */ 177 listAliases(params: KMS.Types.ListAliasesRequest, callback?: (err: AWSError, data: KMS.Types.ListAliasesResponse) => void): Request<KMS.Types.ListAliasesResponse, AWSError>; 178 /** 179 * Lists all of the key aliases in the account. 180 */ 181 listAliases(callback?: (err: AWSError, data: KMS.Types.ListAliasesResponse) => void): Request<KMS.Types.ListAliasesResponse, AWSError>; 182 /** 183 * List the grants for a specified key. 184 */ 185 listGrants(params: KMS.Types.ListGrantsRequest, callback?: (err: AWSError, data: KMS.Types.ListGrantsResponse) => void): Request<KMS.Types.ListGrantsResponse, AWSError>; 186 /** 187 * List the grants for a specified key. 188 */ 189 listGrants(callback?: (err: AWSError, data: KMS.Types.ListGrantsResponse) => void): Request<KMS.Types.ListGrantsResponse, AWSError>; 190 /** 191 * Retrieves a list of policies attached to a key. 192 */ 193 listKeyPolicies(params: KMS.Types.ListKeyPoliciesRequest, callback?: (err: AWSError, data: KMS.Types.ListKeyPoliciesResponse) => void): Request<KMS.Types.ListKeyPoliciesResponse, AWSError>; 194 /** 195 * Retrieves a list of policies attached to a key. 196 */ 197 listKeyPolicies(callback?: (err: AWSError, data: KMS.Types.ListKeyPoliciesResponse) => void): Request<KMS.Types.ListKeyPoliciesResponse, AWSError>; 198 /** 199 * Lists the customer master keys. 200 */ 201 listKeys(params: KMS.Types.ListKeysRequest, callback?: (err: AWSError, data: KMS.Types.ListKeysResponse) => void): Request<KMS.Types.ListKeysResponse, AWSError>; 202 /** 203 * Lists the customer master keys. 204 */ 205 listKeys(callback?: (err: AWSError, data: KMS.Types.ListKeysResponse) => void): Request<KMS.Types.ListKeysResponse, AWSError>; 206 /** 207 * Returns a list of all grants for which the grant's RetiringPrincipal matches the one specified. A typical use is to list all grants that you are able to retire. To retire a grant, use RetireGrant. 208 */ 209 listRetirableGrants(params: KMS.Types.ListRetirableGrantsRequest, callback?: (err: AWSError, data: KMS.Types.ListGrantsResponse) => void): Request<KMS.Types.ListGrantsResponse, AWSError>; 210 /** 211 * Returns a list of all grants for which the grant's RetiringPrincipal matches the one specified. A typical use is to list all grants that you are able to retire. To retire a grant, use RetireGrant. 212 */ 213 listRetirableGrants(callback?: (err: AWSError, data: KMS.Types.ListGrantsResponse) => void): Request<KMS.Types.ListGrantsResponse, AWSError>; 214 /** 215 * Attaches a key policy to the specified customer master key (CMK). For more information about key policies, see Key Policies in the AWS Key Management Service Developer Guide. 216 */ 217 putKeyPolicy(params: KMS.Types.PutKeyPolicyRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 218 /** 219 * Attaches a key policy to the specified customer master key (CMK). For more information about key policies, see Key Policies in the AWS Key Management Service Developer Guide. 220 */ 221 putKeyPolicy(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 222 /** 223 * Encrypts data on the server side with a new customer master key without exposing the plaintext of the data on the client side. The data is first decrypted and then encrypted. This operation can also be used to change the encryption context of a ciphertext. Unlike other actions, ReEncrypt is authorized twice - once as ReEncryptFrom on the source key and once as ReEncryptTo on the destination key. We therefore recommend that you include the "action":"kms:ReEncrypt*" statement in your key policies to permit re-encryption from or to the key. The statement is included automatically when you authorize use of the key through the console but must be included manually when you set a policy by using the PutKeyPolicy function. 224 */ 225 reEncrypt(params: KMS.Types.ReEncryptRequest, callback?: (err: AWSError, data: KMS.Types.ReEncryptResponse) => void): Request<KMS.Types.ReEncryptResponse, AWSError>; 226 /** 227 * Encrypts data on the server side with a new customer master key without exposing the plaintext of the data on the client side. The data is first decrypted and then encrypted. This operation can also be used to change the encryption context of a ciphertext. Unlike other actions, ReEncrypt is authorized twice - once as ReEncryptFrom on the source key and once as ReEncryptTo on the destination key. We therefore recommend that you include the "action":"kms:ReEncrypt*" statement in your key policies to permit re-encryption from or to the key. The statement is included automatically when you authorize use of the key through the console but must be included manually when you set a policy by using the PutKeyPolicy function. 228 */ 229 reEncrypt(callback?: (err: AWSError, data: KMS.Types.ReEncryptResponse) => void): Request<KMS.Types.ReEncryptResponse, AWSError>; 230 /** 231 * Retires a grant. You can retire a grant when you're done using it to clean up. You should revoke a grant when you intend to actively deny operations that depend on it. The following are permitted to call this API: The account that created the grant The RetiringPrincipal, if present The GranteePrincipal, if RetireGrant is a grantee operation The grant to retire must be identified by its grant token or by a combination of the key ARN and the grant ID. A grant token is a unique variable-length base64-encoded string. A grant ID is a 64 character unique identifier of a grant. Both are returned by the CreateGrant function. 232 */ 233 retireGrant(params: KMS.Types.RetireGrantRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 234 /** 235 * Retires a grant. You can retire a grant when you're done using it to clean up. You should revoke a grant when you intend to actively deny operations that depend on it. The following are permitted to call this API: The account that created the grant The RetiringPrincipal, if present The GranteePrincipal, if RetireGrant is a grantee operation The grant to retire must be identified by its grant token or by a combination of the key ARN and the grant ID. A grant token is a unique variable-length base64-encoded string. A grant ID is a 64 character unique identifier of a grant. Both are returned by the CreateGrant function. 236 */ 237 retireGrant(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 238 /** 239 * Revokes a grant. You can revoke a grant to actively deny operations that depend on it. 240 */ 241 revokeGrant(params: KMS.Types.RevokeGrantRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 242 /** 243 * Revokes a grant. You can revoke a grant to actively deny operations that depend on it. 244 */ 245 revokeGrant(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 246 /** 247 * Schedules the deletion of a customer master key (CMK). You may provide a waiting period, specified in days, before deletion occurs. If you do not provide a waiting period, the default period of 30 days is used. When this operation is successful, the state of the CMK changes to PendingDeletion. Before the waiting period ends, you can use CancelKeyDeletion to cancel the deletion of the CMK. After the waiting period ends, AWS KMS deletes the CMK and all AWS KMS data associated with it, including all aliases that point to it. Deleting a CMK is a destructive and potentially dangerous operation. When a CMK is deleted, all data that was encrypted under the CMK is rendered unrecoverable. To restrict the use of a CMK without deleting it, use DisableKey. For more information about scheduling a CMK for deletion, see Deleting Customer Master Keys in the AWS Key Management Service Developer Guide. 248 */ 249 scheduleKeyDeletion(params: KMS.Types.ScheduleKeyDeletionRequest, callback?: (err: AWSError, data: KMS.Types.ScheduleKeyDeletionResponse) => void): Request<KMS.Types.ScheduleKeyDeletionResponse, AWSError>; 250 /** 251 * Schedules the deletion of a customer master key (CMK). You may provide a waiting period, specified in days, before deletion occurs. If you do not provide a waiting period, the default period of 30 days is used. When this operation is successful, the state of the CMK changes to PendingDeletion. Before the waiting period ends, you can use CancelKeyDeletion to cancel the deletion of the CMK. After the waiting period ends, AWS KMS deletes the CMK and all AWS KMS data associated with it, including all aliases that point to it. Deleting a CMK is a destructive and potentially dangerous operation. When a CMK is deleted, all data that was encrypted under the CMK is rendered unrecoverable. To restrict the use of a CMK without deleting it, use DisableKey. For more information about scheduling a CMK for deletion, see Deleting Customer Master Keys in the AWS Key Management Service Developer Guide. 252 */ 253 scheduleKeyDeletion(callback?: (err: AWSError, data: KMS.Types.ScheduleKeyDeletionResponse) => void): Request<KMS.Types.ScheduleKeyDeletionResponse, AWSError>; 254 /** 255 * Updates an alias to map it to a different key. An alias is not a property of a key. Therefore, an alias can be mapped to and unmapped from an existing key without changing the properties of the key. An alias name can contain only alphanumeric characters, forward slashes (/), underscores (_), and dashes (-). An alias must start with the word "alias" followed by a forward slash (alias/). An alias that begins with "aws" after the forward slash (alias/aws...) is reserved by Amazon Web Services (AWS). The alias and the key it is mapped to must be in the same AWS account and the same region. 256 */ 257 updateAlias(params: KMS.Types.UpdateAliasRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 258 /** 259 * Updates an alias to map it to a different key. An alias is not a property of a key. Therefore, an alias can be mapped to and unmapped from an existing key without changing the properties of the key. An alias name can contain only alphanumeric characters, forward slashes (/), underscores (_), and dashes (-). An alias must start with the word "alias" followed by a forward slash (alias/). An alias that begins with "aws" after the forward slash (alias/aws...) is reserved by Amazon Web Services (AWS). The alias and the key it is mapped to must be in the same AWS account and the same region. 260 */ 261 updateAlias(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 262 /** 263 * Updates the description of a key. 264 */ 265 updateKeyDescription(params: KMS.Types.UpdateKeyDescriptionRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 266 /** 267 * Updates the description of a key. 268 */ 269 updateKeyDescription(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>; 270 } 271 declare namespace KMS.Types { 272 export type AWSAccountIdType = string; 273 export type AlgorithmSpec = "RSAES_PKCS1_V1_5"|"RSAES_OAEP_SHA_1"|"RSAES_OAEP_SHA_256"|string; 274 export type AliasList = AliasListEntry[]; 275 export interface AliasListEntry { 276 /** 277 * String that contains the alias. 278 */ 279 AliasName?: AliasNameType; 280 /** 281 * String that contains the key ARN. 282 */ 283 AliasArn?: ArnType; 284 /** 285 * String that contains the key identifier pointed to by the alias. 286 */ 287 TargetKeyId?: KeyIdType; 288 } 289 export type AliasNameType = string; 290 export type ArnType = string; 291 export type BooleanType = boolean; 292 export interface CancelKeyDeletionRequest { 293 /** 294 * The unique identifier for the customer master key (CMK) for which to cancel deletion. To specify this value, use the unique key ID or the Amazon Resource Name (ARN) of the CMK. Examples: Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab To obtain the unique key ID and key ARN for a given CMK, use ListKeys or DescribeKey. 295 */ 296 KeyId: KeyIdType; 297 } 298 export interface CancelKeyDeletionResponse { 299 /** 300 * The unique identifier of the master key for which deletion is canceled. 301 */ 302 KeyId?: KeyIdType; 303 } 304 export type CiphertextType = Buffer|Uint8Array|Blob|string; 305 export interface CreateAliasRequest { 306 /** 307 * String that contains the display name. The name must start with the word "alias" followed by a forward slash (alias/). Aliases that begin with "alias/AWS" are reserved. 308 */ 309 AliasName: AliasNameType; 310 /** 311 * An identifier of the key for which you are creating the alias. This value cannot be another alias but can be a globally unique identifier or a fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 312 */ 313 TargetKeyId: KeyIdType; 314 } 315 export interface CreateGrantRequest { 316 /** 317 * The unique identifier for the customer master key (CMK) that the grant applies to. To specify this value, use the globally unique key ID or the Amazon Resource Name (ARN) of the key. Examples: Globally unique key ID: 12345678-1234-1234-1234-123456789012 Key ARN: arn:aws:kms:us-west-2:123456789012:key/12345678-1234-1234-1234-123456789012 318 */ 319 KeyId: KeyIdType; 320 /** 321 * The principal that is given permission to perform the operations that the grant permits. To specify the principal, use the Amazon Resource Name (ARN) of an AWS principal. Valid AWS principals include AWS accounts (root), IAM users, federated users, and assumed role users. For examples of the ARN syntax to use for specifying a principal, see AWS Identity and Access Management (IAM) in the Example ARNs section of the AWS General Reference. 322 */ 323 GranteePrincipal: PrincipalIdType; 324 /** 325 * The principal that is given permission to retire the grant by using RetireGrant operation. To specify the principal, use the Amazon Resource Name (ARN) of an AWS principal. Valid AWS principals include AWS accounts (root), IAM users, federated users, and assumed role users. For examples of the ARN syntax to use for specifying a principal, see AWS Identity and Access Management (IAM) in the Example ARNs section of the AWS General Reference. 326 */ 327 RetiringPrincipal?: PrincipalIdType; 328 /** 329 * A list of operations that the grant permits. The list can contain any combination of one or more of the following values: Decrypt Encrypt GenerateDataKey GenerateDataKeyWithoutPlaintext ReEncryptFrom ReEncryptTo CreateGrant RetireGrant DescribeKey 330 */ 331 Operations?: GrantOperationList; 332 /** 333 * The conditions under which the operations permitted by the grant are allowed. You can use this value to allow the operations permitted by the grant only when a specified encryption context is present. For more information, see Encryption Context in the AWS Key Management Service Developer Guide. 334 */ 335 Constraints?: GrantConstraints; 336 /** 337 * A list of grant tokens. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 338 */ 339 GrantTokens?: GrantTokenList; 340 /** 341 * A friendly name for identifying the grant. Use this value to prevent unintended creation of duplicate grants when retrying this request. When this value is absent, all CreateGrant requests result in a new grant with a unique GrantId even if all the supplied parameters are identical. This can result in unintended duplicates when you retry the CreateGrant request. When this value is present, you can retry a CreateGrant request with identical parameters; if the grant already exists, the original GrantId is returned without creating a new grant. Note that the returned grant token is unique with every CreateGrant request, even when a duplicate GrantId is returned. All grant tokens obtained in this way can be used interchangeably. 342 */ 343 Name?: GrantNameType; 344 } 345 export interface CreateGrantResponse { 346 /** 347 * The grant token. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 348 */ 349 GrantToken?: GrantTokenType; 350 /** 351 * The unique identifier for the grant. You can use the GrantId in a subsequent RetireGrant or RevokeGrant operation. 352 */ 353 GrantId?: GrantIdType; 354 } 355 export interface CreateKeyRequest { 356 /** 357 * The key policy to attach to the CMK. If you specify a policy and do not set BypassPolicyLockoutSafetyCheck to true, the policy must meet the following criteria: It must allow the principal making the CreateKey request to make a subsequent PutKeyPolicy request on the CMK. This reduces the likelihood that the CMK becomes unmanageable. For more information, refer to the scenario in the Default Key Policy section in the AWS Key Management Service Developer Guide. The principal(s) specified in the key policy must exist and be visible to AWS KMS. When you create a new AWS principal (for example, an IAM user or role), you might need to enforce a delay before specifying the new principal in a key policy because the new principal might not immediately be visible to AWS KMS. For more information, see Changes that I make are not always immediately visible in the IAM User Guide. If you do not specify a policy, AWS KMS attaches a default key policy to the CMK. For more information, see Default Key Policy in the AWS Key Management Service Developer Guide. The policy size limit is 32 KiB (32768 bytes). 358 */ 359 Policy?: PolicyType; 360 /** 361 * A description of the CMK. Use a description that helps you decide whether the CMK is appropriate for a task. 362 */ 363 Description?: DescriptionType; 364 /** 365 * The intended use of the CMK. You can use CMKs only for symmetric encryption and decryption. 366 */ 367 KeyUsage?: KeyUsageType; 368 /** 369 * The source of the CMK's key material. The default is AWS_KMS, which means AWS KMS creates the key material. When this parameter is set to EXTERNAL, the request creates a CMK without key material so that you can import key material from your existing key management infrastructure. For more information about importing key material into AWS KMS, see Importing Key Material in the AWS Key Management Service Developer Guide. The CMK's Origin is immutable and is set when the CMK is created. 370 */ 371 Origin?: OriginType; 372 /** 373 * A flag to indicate whether to bypass the key policy lockout safety check. Setting this value to true increases the likelihood that the CMK becomes unmanageable. Do not set this value to true indiscriminately. For more information, refer to the scenario in the Default Key Policy section in the AWS Key Management Service Developer Guide. Use this parameter only when you include a policy in the request and you intend to prevent the principal making the request from making a subsequent PutKeyPolicy request on the CMK. The default value is false. 374 */ 375 BypassPolicyLockoutSafetyCheck?: BooleanType; 376 } 377 export interface CreateKeyResponse { 378 /** 379 * Metadata associated with the CMK. 380 */ 381 KeyMetadata?: KeyMetadata; 382 } 383 export type DataKeySpec = "AES_256"|"AES_128"|string; 384 export type DateType = Date; 385 export interface DecryptRequest { 386 /** 387 * Ciphertext to be decrypted. The blob includes metadata. 388 */ 389 CiphertextBlob: CiphertextType; 390 /** 391 * The encryption context. If this was specified in the Encrypt function, it must be specified here or the decryption operation will fail. For more information, see Encryption Context. 392 */ 393 EncryptionContext?: EncryptionContextType; 394 /** 395 * A list of grant tokens. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 396 */ 397 GrantTokens?: GrantTokenList; 398 } 399 export interface DecryptResponse { 400 /** 401 * ARN of the key used to perform the decryption. This value is returned if no errors are encountered during the operation. 402 */ 403 KeyId?: KeyIdType; 404 /** 405 * Decrypted plaintext data. This value may not be returned if the customer master key is not available or if you didn't have permission to use it. 406 */ 407 Plaintext?: PlaintextType; 408 } 409 export interface DeleteAliasRequest { 410 /** 411 * The alias to be deleted. The name must start with the word "alias" followed by a forward slash (alias/). Aliases that begin with "alias/AWS" are reserved. 412 */ 413 AliasName: AliasNameType; 414 } 415 export interface DeleteImportedKeyMaterialRequest { 416 /** 417 * The identifier of the CMK whose key material to delete. The CMK's Origin must be EXTERNAL. A valid identifier is the unique key ID or the Amazon Resource Name (ARN) of the CMK. Examples: Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab 418 */ 419 KeyId: KeyIdType; 420 } 421 export interface DescribeKeyRequest { 422 /** 423 * A unique identifier for the customer master key. This value can be a globally unique identifier, a fully specified ARN to either an alias or a key, or an alias name prefixed by "alias/". Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Alias ARN Example - arn:aws:kms:us-east-1:123456789012:alias/MyAliasName Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 Alias Name Example - alias/MyAliasName 424 */ 425 KeyId: KeyIdType; 426 /** 427 * A list of grant tokens. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 428 */ 429 GrantTokens?: GrantTokenList; 430 } 431 export interface DescribeKeyResponse { 432 /** 433 * Metadata associated with the key. 434 */ 435 KeyMetadata?: KeyMetadata; 436 } 437 export type DescriptionType = string; 438 export interface DisableKeyRequest { 439 /** 440 * A unique identifier for the CMK. Use the CMK's unique identifier or its Amazon Resource Name (ARN). For example: Unique ID: 1234abcd-12ab-34cd-56ef-1234567890ab ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab 441 */ 442 KeyId: KeyIdType; 443 } 444 export interface DisableKeyRotationRequest { 445 /** 446 * A unique identifier for the customer master key. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 447 */ 448 KeyId: KeyIdType; 449 } 450 export interface EnableKeyRequest { 451 /** 452 * A unique identifier for the customer master key. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 453 */ 454 KeyId: KeyIdType; 455 } 456 export interface EnableKeyRotationRequest { 457 /** 458 * A unique identifier for the customer master key. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 459 */ 460 KeyId: KeyIdType; 461 } 462 export interface EncryptRequest { 463 /** 464 * A unique identifier for the customer master key. This value can be a globally unique identifier, a fully specified ARN to either an alias or a key, or an alias name prefixed by "alias/". Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Alias ARN Example - arn:aws:kms:us-east-1:123456789012:alias/MyAliasName Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 Alias Name Example - alias/MyAliasName 465 */ 466 KeyId: KeyIdType; 467 /** 468 * Data to be encrypted. 469 */ 470 Plaintext: PlaintextType; 471 /** 472 * Name-value pair that specifies the encryption context to be used for authenticated encryption. If used here, the same value must be supplied to the Decrypt API or decryption will fail. For more information, see Encryption Context. 473 */ 474 EncryptionContext?: EncryptionContextType; 475 /** 476 * A list of grant tokens. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 477 */ 478 GrantTokens?: GrantTokenList; 479 } 480 export interface EncryptResponse { 481 /** 482 * The encrypted plaintext. If you are using the CLI, the value is Base64 encoded. Otherwise, it is not encoded. 483 */ 484 CiphertextBlob?: CiphertextType; 485 /** 486 * The ID of the key used during encryption. 487 */ 488 KeyId?: KeyIdType; 489 } 490 export type EncryptionContextKey = string; 491 export type EncryptionContextType = {[key: string]: EncryptionContextValue}; 492 export type EncryptionContextValue = string; 493 export type ErrorMessageType = string; 494 export type ExpirationModelType = "KEY_MATERIAL_EXPIRES"|"KEY_MATERIAL_DOES_NOT_EXPIRE"|string; 495 export interface GenerateDataKeyRequest { 496 /** 497 * The identifier of the CMK under which to generate and encrypt the data encryption key. A valid identifier is the unique key ID or the Amazon Resource Name (ARN) of the CMK, or the alias name or ARN of an alias that points to the CMK. Examples: Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab CMK ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab Alias name: alias/ExampleAlias Alias ARN: arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias 498 */ 499 KeyId: KeyIdType; 500 /** 501 * A set of key-value pairs that represents additional authenticated data. For more information, see Encryption Context in the AWS Key Management Service Developer Guide. 502 */ 503 EncryptionContext?: EncryptionContextType; 504 /** 505 * The length of the data encryption key in bytes. For example, use the value 64 to generate a 512-bit data key (64 bytes is 512 bits). For common key lengths (128-bit and 256-bit symmetric keys), we recommend that you use the KeySpec field instead of this one. 506 */ 507 NumberOfBytes?: NumberOfBytesType; 508 /** 509 * The length of the data encryption key. Use AES_128 to generate a 128-bit symmetric key, or AES_256 to generate a 256-bit symmetric key. 510 */ 511 KeySpec?: DataKeySpec; 512 /** 513 * A list of grant tokens. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 514 */ 515 GrantTokens?: GrantTokenList; 516 } 517 export interface GenerateDataKeyResponse { 518 /** 519 * The encrypted data encryption key. 520 */ 521 CiphertextBlob?: CiphertextType; 522 /** 523 * The data encryption key. Use this data key for local encryption and decryption, then remove it from memory as soon as possible. 524 */ 525 Plaintext?: PlaintextType; 526 /** 527 * The identifier of the CMK under which the data encryption key was generated and encrypted. 528 */ 529 KeyId?: KeyIdType; 530 } 531 export interface GenerateDataKeyWithoutPlaintextRequest { 532 /** 533 * The identifier of the CMK under which to generate and encrypt the data encryption key. A valid identifier is the unique key ID or the Amazon Resource Name (ARN) of the CMK, or the alias name or ARN of an alias that points to the CMK. Examples: Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab CMK ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab Alias name: alias/ExampleAlias Alias ARN: arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias 534 */ 535 KeyId: KeyIdType; 536 /** 537 * A set of key-value pairs that represents additional authenticated data. For more information, see Encryption Context in the AWS Key Management Service Developer Guide. 538 */ 539 EncryptionContext?: EncryptionContextType; 540 /** 541 * The length of the data encryption key. Use AES_128 to generate a 128-bit symmetric key, or AES_256 to generate a 256-bit symmetric key. 542 */ 543 KeySpec?: DataKeySpec; 544 /** 545 * The length of the data encryption key in bytes. For example, use the value 64 to generate a 512-bit data key (64 bytes is 512 bits). For common key lengths (128-bit and 256-bit symmetric keys), we recommend that you use the KeySpec field instead of this one. 546 */ 547 NumberOfBytes?: NumberOfBytesType; 548 /** 549 * A list of grant tokens. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 550 */ 551 GrantTokens?: GrantTokenList; 552 } 553 export interface GenerateDataKeyWithoutPlaintextResponse { 554 /** 555 * The encrypted data encryption key. 556 */ 557 CiphertextBlob?: CiphertextType; 558 /** 559 * The identifier of the CMK under which the data encryption key was generated and encrypted. 560 */ 561 KeyId?: KeyIdType; 562 } 563 export interface GenerateRandomRequest { 564 /** 565 * The length of the byte string. 566 */ 567 NumberOfBytes?: NumberOfBytesType; 568 } 569 export interface GenerateRandomResponse { 570 /** 571 * The unpredictable byte string. 572 */ 573 Plaintext?: PlaintextType; 574 } 575 export interface GetKeyPolicyRequest { 576 /** 577 * A unique identifier for the customer master key. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 578 */ 579 KeyId: KeyIdType; 580 /** 581 * String that contains the name of the policy. Currently, this must be "default". Policy names can be discovered by calling ListKeyPolicies. 582 */ 583 PolicyName: PolicyNameType; 584 } 585 export interface GetKeyPolicyResponse { 586 /** 587 * A policy document in JSON format. 588 */ 589 Policy?: PolicyType; 590 } 591 export interface GetKeyRotationStatusRequest { 592 /** 593 * A unique identifier for the customer master key. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 594 */ 595 KeyId: KeyIdType; 596 } 597 export interface GetKeyRotationStatusResponse { 598 /** 599 * A Boolean value that specifies whether key rotation is enabled. 600 */ 601 KeyRotationEnabled?: BooleanType; 602 } 603 export interface GetParametersForImportRequest { 604 /** 605 * The identifier of the CMK into which you will import key material. The CMK's Origin must be EXTERNAL. A valid identifier is the unique key ID or the Amazon Resource Name (ARN) of the CMK. Examples: Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab 606 */ 607 KeyId: KeyIdType; 608 /** 609 * The algorithm you will use to encrypt the key material before importing it with ImportKeyMaterial. For more information, see Encrypt the Key Material in the AWS Key Management Service Developer Guide. 610 */ 611 WrappingAlgorithm: AlgorithmSpec; 612 /** 613 * The type of wrapping key (public key) to return in the response. Only 2048-bit RSA public keys are supported. 614 */ 615 WrappingKeySpec: WrappingKeySpec; 616 } 617 export interface GetParametersForImportResponse { 618 /** 619 * The identifier of the CMK to use in a subsequent ImportKeyMaterial request. This is the same CMK specified in the GetParametersForImport request. 620 */ 621 KeyId?: KeyIdType; 622 /** 623 * The import token to send in a subsequent ImportKeyMaterial request. 624 */ 625 ImportToken?: CiphertextType; 626 /** 627 * The public key to use to encrypt the key material before importing it with ImportKeyMaterial. 628 */ 629 PublicKey?: PlaintextType; 630 /** 631 * The time at which the import token and public key are no longer valid. After this time, you cannot use them to make an ImportKeyMaterial request and you must send another GetParametersForImport request to retrieve new ones. 632 */ 633 ParametersValidTo?: DateType; 634 } 635 export interface GrantConstraints { 636 /** 637 * Contains a list of key-value pairs, a subset of which must be present in the encryption context of a subsequent operation permitted by the grant. When a subsequent operation permitted by the grant includes an encryption context that matches this list or is a subset of this list, the grant allows the operation. Otherwise, the operation is not allowed. 638 */ 639 EncryptionContextSubset?: EncryptionContextType; 640 /** 641 * Contains a list of key-value pairs that must be present in the encryption context of a subsequent operation permitted by the grant. When a subsequent operation permitted by the grant includes an encryption context that matches this list, the grant allows the operation. Otherwise, the operation is not allowed. 642 */ 643 EncryptionContextEquals?: EncryptionContextType; 644 } 645 export type GrantIdType = string; 646 export type GrantList = GrantListEntry[]; 647 export interface GrantListEntry { 648 /** 649 * The unique identifier for the customer master key (CMK) to which the grant applies. 650 */ 651 KeyId?: KeyIdType; 652 /** 653 * The unique identifier for the grant. 654 */ 655 GrantId?: GrantIdType; 656 /** 657 * The friendly name that identifies the grant. If a name was provided in the CreateGrant request, that name is returned. Otherwise this value is null. 658 */ 659 Name?: GrantNameType; 660 /** 661 * The date and time when the grant was created. 662 */ 663 CreationDate?: DateType; 664 /** 665 * The principal that receives the grant's permissions. 666 */ 667 GranteePrincipal?: PrincipalIdType; 668 /** 669 * The principal that can retire the grant. 670 */ 671 RetiringPrincipal?: PrincipalIdType; 672 /** 673 * The AWS account under which the grant was issued. 674 */ 675 IssuingAccount?: PrincipalIdType; 676 /** 677 * The list of operations permitted by the grant. 678 */ 679 Operations?: GrantOperationList; 680 /** 681 * The conditions under which the grant's operations are allowed. 682 */ 683 Constraints?: GrantConstraints; 684 } 685 export type GrantNameType = string; 686 export type GrantOperation = "Decrypt"|"Encrypt"|"GenerateDataKey"|"GenerateDataKeyWithoutPlaintext"|"ReEncryptFrom"|"ReEncryptTo"|"CreateGrant"|"RetireGrant"|"DescribeKey"|string; 687 export type GrantOperationList = GrantOperation[]; 688 export type GrantTokenList = GrantTokenType[]; 689 export type GrantTokenType = string; 690 export interface ImportKeyMaterialRequest { 691 /** 692 * The identifier of the CMK to import the key material into. The CMK's Origin must be EXTERNAL. A valid identifier is the unique key ID or the Amazon Resource Name (ARN) of the CMK. Examples: Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab 693 */ 694 KeyId: KeyIdType; 695 /** 696 * The import token that you received in the response to a previous GetParametersForImport request. It must be from the same response that contained the public key that you used to encrypt the key material. 697 */ 698 ImportToken: CiphertextType; 699 /** 700 * The encrypted key material to import. It must be encrypted with the public key that you received in the response to a previous GetParametersForImport request, using the wrapping algorithm that you specified in that request. 701 */ 702 EncryptedKeyMaterial: CiphertextType; 703 /** 704 * The time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. You must omit this parameter when the ExpirationModel parameter is set to KEY_MATERIAL_DOES_NOT_EXPIRE. Otherwise it is required. 705 */ 706 ValidTo?: DateType; 707 /** 708 * Specifies whether the key material expires. The default is KEY_MATERIAL_EXPIRES, in which case you must include the ValidTo parameter. When this parameter is set to KEY_MATERIAL_DOES_NOT_EXPIRE, you must omit the ValidTo parameter. 709 */ 710 ExpirationModel?: ExpirationModelType; 711 } 712 export interface ImportKeyMaterialResponse { 713 } 714 export type KeyIdType = string; 715 export type KeyList = KeyListEntry[]; 716 export interface KeyListEntry { 717 /** 718 * Unique identifier of the key. 719 */ 720 KeyId?: KeyIdType; 721 /** 722 * ARN of the key. 723 */ 724 KeyArn?: ArnType; 725 } 726 export interface KeyMetadata { 727 /** 728 * The twelve-digit account ID of the AWS account that owns the CMK. 729 */ 730 AWSAccountId?: AWSAccountIdType; 731 /** 732 * The globally unique identifier for the CMK. 733 */ 734 KeyId: KeyIdType; 735 /** 736 * The Amazon Resource Name (ARN) of the CMK. For examples, see AWS Key Management Service (AWS KMS) in the Example ARNs section of the AWS General Reference. 737 */ 738 Arn?: ArnType; 739 /** 740 * The date and time when the CMK was created. 741 */ 742 CreationDate?: DateType; 743 /** 744 * Specifies whether the CMK is enabled. When KeyState is Enabled this value is true, otherwise it is false. 745 */ 746 Enabled?: BooleanType; 747 /** 748 * The description of the CMK. 749 */ 750 Description?: DescriptionType; 751 /** 752 * The cryptographic operations for which you can use the CMK. Currently the only allowed value is ENCRYPT_DECRYPT, which means you can use the CMK for the Encrypt and Decrypt operations. 753 */ 754 KeyUsage?: KeyUsageType; 755 /** 756 * The state of the CMK. For more information about how key state affects the use of a CMK, see How Key State Affects the Use of a Customer Master Key in the AWS Key Management Service Developer Guide. 757 */ 758 KeyState?: KeyState; 759 /** 760 * The date and time after which AWS KMS deletes the CMK. This value is present only when KeyState is PendingDeletion, otherwise this value is omitted. 761 */ 762 DeletionDate?: DateType; 763 /** 764 * The time at which the imported key material expires. When the key material expires, AWS KMS deletes the key material and the CMK becomes unusable. This value is present only for CMKs whose Origin is EXTERNAL and whose ExpirationModel is KEY_MATERIAL_EXPIRES, otherwise this value is omitted. 765 */ 766 ValidTo?: DateType; 767 /** 768 * The source of the CMK's key material. When this value is AWS_KMS, AWS KMS created the key material. When this value is EXTERNAL, the key material was imported from your existing key management infrastructure or the CMK lacks key material. 769 */ 770 Origin?: OriginType; 771 /** 772 * Specifies whether the CMK's key material expires. This value is present only when Origin is EXTERNAL, otherwise this value is omitted. 773 */ 774 ExpirationModel?: ExpirationModelType; 775 } 776 export type KeyState = "Enabled"|"Disabled"|"PendingDeletion"|"PendingImport"|string; 777 export type KeyUsageType = "ENCRYPT_DECRYPT"|string; 778 export type LimitType = number; 779 export interface ListAliasesRequest { 780 /** 781 * When paginating results, specify the maximum number of items to return in the response. If additional items exist beyond the number you specify, the Truncated element in the response is set to true. This value is optional. If you include a value, it must be between 1 and 100, inclusive. If you do not include a value, it defaults to 50. 782 */ 783 Limit?: LimitType; 784 /** 785 * Use this parameter only when paginating results and only in a subsequent request after you receive a response with truncated results. Set it to the value of NextMarker from the response you just received. 786 */ 787 Marker?: MarkerType; 788 } 789 export interface ListAliasesResponse { 790 /** 791 * A list of key aliases in the user's account. 792 */ 793 Aliases?: AliasList; 794 /** 795 * When Truncated is true, this value is present and contains the value to use for the Marker parameter in a subsequent pagination request. 796 */ 797 NextMarker?: MarkerType; 798 /** 799 * A flag that indicates whether there are more items in the list. If your results were truncated, you can use the Marker parameter to make a subsequent pagination request to retrieve more items in the list. 800 */ 801 Truncated?: BooleanType; 802 } 803 export interface ListGrantsRequest { 804 /** 805 * When paginating results, specify the maximum number of items to return in the response. If additional items exist beyond the number you specify, the Truncated element in the response is set to true. This value is optional. If you include a value, it must be between 1 and 100, inclusive. If you do not include a value, it defaults to 50. 806 */ 807 Limit?: LimitType; 808 /** 809 * Use this parameter only when paginating results and only in a subsequent request after you receive a response with truncated results. Set it to the value of NextMarker from the response you just received. 810 */ 811 Marker?: MarkerType; 812 /** 813 * A unique identifier for the customer master key. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 814 */ 815 KeyId: KeyIdType; 816 } 817 export interface ListGrantsResponse { 818 /** 819 * A list of grants. 820 */ 821 Grants?: GrantList; 822 /** 823 * When Truncated is true, this value is present and contains the value to use for the Marker parameter in a subsequent pagination request. 824 */ 825 NextMarker?: MarkerType; 826 /** 827 * A flag that indicates whether there are more items in the list. If your results were truncated, you can use the Marker parameter to make a subsequent pagination request to retrieve more items in the list. 828 */ 829 Truncated?: BooleanType; 830 } 831 export interface ListKeyPoliciesRequest { 832 /** 833 * A unique identifier for the customer master key. This value can be a globally unique identifier, a fully specified ARN to either an alias or a key, or an alias name prefixed by "alias/". Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Alias ARN Example - arn:aws:kms:us-east-1:123456789012:alias/MyAliasName Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 Alias Name Example - alias/MyAliasName 834 */ 835 KeyId: KeyIdType; 836 /** 837 * When paginating results, specify the maximum number of items to return in the response. If additional items exist beyond the number you specify, the Truncated element in the response is set to true. This value is optional. If you include a value, it must be between 1 and 1000, inclusive. If you do not include a value, it defaults to 100. Currently only 1 policy can be attached to a key. 838 */ 839 Limit?: LimitType; 840 /** 841 * Use this parameter only when paginating results and only in a subsequent request after you receive a response with truncated results. Set it to the value of NextMarker from the response you just received. 842 */ 843 Marker?: MarkerType; 844 } 845 export interface ListKeyPoliciesResponse { 846 /** 847 * A list of policy names. Currently, there is only one policy and it is named "Default". 848 */ 849 PolicyNames?: PolicyNameList; 850 /** 851 * When Truncated is true, this value is present and contains the value to use for the Marker parameter in a subsequent pagination request. 852 */ 853 NextMarker?: MarkerType; 854 /** 855 * A flag that indicates whether there are more items in the list. If your results were truncated, you can use the Marker parameter to make a subsequent pagination request to retrieve more items in the list. 856 */ 857 Truncated?: BooleanType; 858 } 859 export interface ListKeysRequest { 860 /** 861 * When paginating results, specify the maximum number of items to return in the response. If additional items exist beyond the number you specify, the Truncated element in the response is set to true. This value is optional. If you include a value, it must be between 1 and 1000, inclusive. If you do not include a value, it defaults to 100. 862 */ 863 Limit?: LimitType; 864 /** 865 * Use this parameter only when paginating results and only in a subsequent request after you receive a response with truncated results. Set it to the value of NextMarker from the response you just received. 866 */ 867 Marker?: MarkerType; 868 } 869 export interface ListKeysResponse { 870 /** 871 * A list of keys. 872 */ 873 Keys?: KeyList; 874 /** 875 * When Truncated is true, this value is present and contains the value to use for the Marker parameter in a subsequent pagination request. 876 */ 877 NextMarker?: MarkerType; 878 /** 879 * A flag that indicates whether there are more items in the list. If your results were truncated, you can use the Marker parameter to make a subsequent pagination request to retrieve more items in the list. 880 */ 881 Truncated?: BooleanType; 882 } 883 export interface ListRetirableGrantsRequest { 884 /** 885 * When paginating results, specify the maximum number of items to return in the response. If additional items exist beyond the number you specify, the Truncated element in the response is set to true. This value is optional. If you include a value, it must be between 1 and 100, inclusive. If you do not include a value, it defaults to 50. 886 */ 887 Limit?: LimitType; 888 /** 889 * Use this parameter only when paginating results and only in a subsequent request after you receive a response with truncated results. Set it to the value of NextMarker from the response you just received. 890 */ 891 Marker?: MarkerType; 892 /** 893 * The retiring principal for which to list grants. To specify the retiring principal, use the Amazon Resource Name (ARN) of an AWS principal. Valid AWS principals include AWS accounts (root), IAM users, federated users, and assumed role users. For examples of the ARN syntax for specifying a principal, see AWS Identity and Access Management (IAM) in the Example ARNs section of the Amazon Web Services General Reference. 894 */ 895 RetiringPrincipal: PrincipalIdType; 896 } 897 export type MarkerType = string; 898 export type NumberOfBytesType = number; 899 export type OriginType = "AWS_KMS"|"EXTERNAL"|string; 900 export type PendingWindowInDaysType = number; 901 export type PlaintextType = Buffer|Uint8Array|Blob|string; 902 export type PolicyNameList = PolicyNameType[]; 903 export type PolicyNameType = string; 904 export type PolicyType = string; 905 export type PrincipalIdType = string; 906 export interface PutKeyPolicyRequest { 907 /** 908 * A unique identifier for the CMK. Use the CMK's unique identifier or its Amazon Resource Name (ARN). For example: Unique ID: 1234abcd-12ab-34cd-56ef-1234567890ab ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab 909 */ 910 KeyId: KeyIdType; 911 /** 912 * The name of the key policy. This value must be default. 913 */ 914 PolicyName: PolicyNameType; 915 /** 916 * The key policy to attach to the CMK. If you do not set BypassPolicyLockoutSafetyCheck to true, the policy must meet the following criteria: It must allow the principal making the PutKeyPolicy request to make a subsequent PutKeyPolicy request on the CMK. This reduces the likelihood that the CMK becomes unmanageable. For more information, refer to the scenario in the Default Key Policy section in the AWS Key Management Service Developer Guide. The principal(s) specified in the key policy must exist and be visible to AWS KMS. When you create a new AWS principal (for example, an IAM user or role), you might need to enforce a delay before specifying the new principal in a key policy because the new principal might not immediately be visible to AWS KMS. For more information, see Changes that I make are not always immediately visible in the IAM User Guide. The policy size limit is 32 KiB (32768 bytes). 917 */ 918 Policy: PolicyType; 919 /** 920 * A flag to indicate whether to bypass the key policy lockout safety check. Setting this value to true increases the likelihood that the CMK becomes unmanageable. Do not set this value to true indiscriminately. For more information, refer to the scenario in the Default Key Policy section in the AWS Key Management Service Developer Guide. Use this parameter only when you intend to prevent the principal making the request from making a subsequent PutKeyPolicy request on the CMK. The default value is false. 921 */ 922 BypassPolicyLockoutSafetyCheck?: BooleanType; 923 } 924 export interface ReEncryptRequest { 925 /** 926 * Ciphertext of the data to re-encrypt. 927 */ 928 CiphertextBlob: CiphertextType; 929 /** 930 * Encryption context used to encrypt and decrypt the data specified in the CiphertextBlob parameter. 931 */ 932 SourceEncryptionContext?: EncryptionContextType; 933 /** 934 * A unique identifier for the customer master key used to re-encrypt the data. This value can be a globally unique identifier, a fully specified ARN to either an alias or a key, or an alias name prefixed by "alias/". Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Alias ARN Example - arn:aws:kms:us-east-1:123456789012:alias/MyAliasName Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 Alias Name Example - alias/MyAliasName 935 */ 936 DestinationKeyId: KeyIdType; 937 /** 938 * Encryption context to be used when the data is re-encrypted. 939 */ 940 DestinationEncryptionContext?: EncryptionContextType; 941 /** 942 * A list of grant tokens. For more information, see Grant Tokens in the AWS Key Management Service Developer Guide. 943 */ 944 GrantTokens?: GrantTokenList; 945 } 946 export interface ReEncryptResponse { 947 /** 948 * The re-encrypted data. If you are using the CLI, the value is Base64 encoded. Otherwise, it is not encoded. 949 */ 950 CiphertextBlob?: CiphertextType; 951 /** 952 * Unique identifier of the key used to originally encrypt the data. 953 */ 954 SourceKeyId?: KeyIdType; 955 /** 956 * Unique identifier of the key used to re-encrypt the data. 957 */ 958 KeyId?: KeyIdType; 959 } 960 export interface RetireGrantRequest { 961 /** 962 * Token that identifies the grant to be retired. 963 */ 964 GrantToken?: GrantTokenType; 965 /** 966 * A unique identifier for the customer master key associated with the grant. This value can be a globally unique identifier or a fully specified ARN of the key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 967 */ 968 KeyId?: KeyIdType; 969 /** 970 * Unique identifier of the grant to be retired. The grant ID is returned by the CreateGrant function. Grant ID Example - 0123456789012345678901234567890123456789012345678901234567890123 971 */ 972 GrantId?: GrantIdType; 973 } 974 export interface RevokeGrantRequest { 975 /** 976 * A unique identifier for the customer master key associated with the grant. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 977 */ 978 KeyId: KeyIdType; 979 /** 980 * Identifier of the grant to be revoked. 981 */ 982 GrantId: GrantIdType; 983 } 984 export interface ScheduleKeyDeletionRequest { 985 /** 986 * The unique identifier for the customer master key (CMK) to delete. To specify this value, use the unique key ID or the Amazon Resource Name (ARN) of the CMK. Examples: Unique key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab To obtain the unique key ID and key ARN for a given CMK, use ListKeys or DescribeKey. 987 */ 988 KeyId: KeyIdType; 989 /** 990 * The waiting period, specified in number of days. After the waiting period ends, AWS KMS deletes the customer master key (CMK). This value is optional. If you include a value, it must be between 7 and 30, inclusive. If you do not include a value, it defaults to 30. 991 */ 992 PendingWindowInDays?: PendingWindowInDaysType; 993 } 994 export interface ScheduleKeyDeletionResponse { 995 /** 996 * The unique identifier of the customer master key (CMK) for which deletion is scheduled. 997 */ 998 KeyId?: KeyIdType; 999 /** 1000 * The date and time after which AWS KMS deletes the customer master key (CMK). 1001 */ 1002 DeletionDate?: DateType; 1003 } 1004 export interface UpdateAliasRequest { 1005 /** 1006 * String that contains the name of the alias to be modified. The name must start with the word "alias" followed by a forward slash (alias/). Aliases that begin with "alias/aws" are reserved. 1007 */ 1008 AliasName: AliasNameType; 1009 /** 1010 * Unique identifier of the customer master key to be mapped to the alias. This value can be a globally unique identifier or the fully specified ARN of a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 You can call ListAliases to verify that the alias is mapped to the correct TargetKeyId. 1011 */ 1012 TargetKeyId: KeyIdType; 1013 } 1014 export interface UpdateKeyDescriptionRequest { 1015 /** 1016 * A unique identifier for the customer master key. This value can be a globally unique identifier or the fully specified ARN to a key. Key ARN Example - arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 Globally Unique Key ID Example - 12345678-1234-1234-1234-123456789012 1017 */ 1018 KeyId: KeyIdType; 1019 /** 1020 * New description for the key. 1021 */ 1022 Description: DescriptionType; 1023 } 1024 export type WrappingKeySpec = "RSA_2048"|string; 1025 /** 1026 * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version. 1027 */ 1028 export type apiVersion = "2014-11-01"|"latest"|string; 1029 export interface ClientApiVersions { 1030 /** 1031 * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version. 1032 */ 1033 apiVersion?: apiVersion; 1034 } 1035 export type ClientConfiguration = ServiceConfigurationOptions & ClientApiVersions; 1036 } 1037 export = KMS;