@aws-sdk/client-kms 3.72.0 → 3.73.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/README.md +4 -1
- package/dist-cjs/KMS.js +30 -0
- package/dist-cjs/commands/GenerateMacCommand.js +36 -0
- package/dist-cjs/commands/VerifyMacCommand.js +36 -0
- package/dist-cjs/commands/index.js +2 -0
- package/dist-cjs/models/models_0.js +60 -3
- package/dist-cjs/protocols/Aws_json1_1.js +194 -2
- package/dist-es/KMS.js +30 -0
- package/dist-es/commands/GenerateMacCommand.js +39 -0
- package/dist-es/commands/VerifyMacCommand.js +39 -0
- package/dist-es/commands/index.js +2 -0
- package/dist-es/models/models_0.js +46 -0
- package/dist-es/protocols/Aws_json1_1.js +225 -1
- package/dist-types/KMS.d.ts +256 -219
- package/dist-types/KMSClient.d.ts +8 -3
- package/dist-types/commands/CancelKeyDeletionCommand.d.ts +1 -1
- package/dist-types/commands/CreateAliasCommand.d.ts +2 -2
- package/dist-types/commands/CreateGrantCommand.d.ts +2 -2
- package/dist-types/commands/CreateKeyCommand.d.ts +44 -40
- package/dist-types/commands/DecryptCommand.d.ts +7 -7
- package/dist-types/commands/DeleteAliasCommand.d.ts +1 -1
- package/dist-types/commands/DeleteImportedKeyMaterialCommand.d.ts +1 -1
- package/dist-types/commands/DescribeKeyCommand.d.ts +6 -8
- package/dist-types/commands/DisableKeyCommand.d.ts +2 -3
- package/dist-types/commands/DisableKeyRotationCommand.d.ts +3 -3
- package/dist-types/commands/EnableKeyCommand.d.ts +1 -1
- package/dist-types/commands/EnableKeyRotationCommand.d.ts +3 -3
- package/dist-types/commands/EncryptCommand.d.ts +8 -26
- package/dist-types/commands/GenerateDataKeyCommand.d.ts +13 -15
- package/dist-types/commands/GenerateDataKeyPairCommand.d.ts +12 -11
- package/dist-types/commands/GenerateDataKeyPairWithoutPlaintextCommand.d.ts +10 -11
- package/dist-types/commands/GenerateDataKeyWithoutPlaintextCommand.d.ts +21 -24
- package/dist-types/commands/GenerateMacCommand.d.ts +55 -0
- package/dist-types/commands/GetKeyRotationStatusCommand.d.ts +2 -2
- package/dist-types/commands/GetParametersForImportCommand.d.ts +7 -7
- package/dist-types/commands/GetPublicKeyCommand.d.ts +2 -2
- package/dist-types/commands/ImportKeyMaterialCommand.d.ts +8 -8
- package/dist-types/commands/ListGrantsCommand.d.ts +1 -1
- package/dist-types/commands/ListRetirableGrantsCommand.d.ts +1 -1
- package/dist-types/commands/ReEncryptCommand.d.ts +8 -9
- package/dist-types/commands/ReplicateKeyCommand.d.ts +8 -4
- package/dist-types/commands/RetireGrantCommand.d.ts +4 -5
- package/dist-types/commands/RevokeGrantCommand.d.ts +1 -1
- package/dist-types/commands/ScheduleKeyDeletionCommand.d.ts +1 -1
- package/dist-types/commands/SignCommand.d.ts +3 -3
- package/dist-types/commands/TagResourceCommand.d.ts +2 -2
- package/dist-types/commands/UntagResourceCommand.d.ts +2 -2
- package/dist-types/commands/UpdateAliasCommand.d.ts +2 -2
- package/dist-types/commands/UpdateKeyDescriptionCommand.d.ts +1 -1
- package/dist-types/commands/UpdatePrimaryRegionCommand.d.ts +2 -3
- package/dist-types/commands/VerifyCommand.d.ts +2 -2
- package/dist-types/commands/VerifyMacCommand.d.ts +56 -0
- package/dist-types/commands/index.d.ts +2 -0
- package/dist-types/models/models_0.d.ts +323 -114
- package/dist-types/protocols/Aws_json1_1.d.ts +6 -0
- package/dist-types/ts3.4/KMS.d.ts +10 -0
- package/dist-types/ts3.4/KMSClient.d.ts +4 -2
- package/dist-types/ts3.4/commands/GenerateMacCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/VerifyMacCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/index.d.ts +2 -0
- package/dist-types/ts3.4/models/models_0.d.ts +81 -1
- package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +6 -0
- package/package.json +1 -1
|
@@ -28,6 +28,7 @@ import { GenerateDataKeyCommandInput, GenerateDataKeyCommandOutput } from "./com
|
|
|
28
28
|
import { GenerateDataKeyPairCommandInput, GenerateDataKeyPairCommandOutput } from "./commands/GenerateDataKeyPairCommand";
|
|
29
29
|
import { GenerateDataKeyPairWithoutPlaintextCommandInput, GenerateDataKeyPairWithoutPlaintextCommandOutput } from "./commands/GenerateDataKeyPairWithoutPlaintextCommand";
|
|
30
30
|
import { GenerateDataKeyWithoutPlaintextCommandInput, GenerateDataKeyWithoutPlaintextCommandOutput } from "./commands/GenerateDataKeyWithoutPlaintextCommand";
|
|
31
|
+
import { GenerateMacCommandInput, GenerateMacCommandOutput } from "./commands/GenerateMacCommand";
|
|
31
32
|
import { GenerateRandomCommandInput, GenerateRandomCommandOutput } from "./commands/GenerateRandomCommand";
|
|
32
33
|
import { GetKeyPolicyCommandInput, GetKeyPolicyCommandOutput } from "./commands/GetKeyPolicyCommand";
|
|
33
34
|
import { GetKeyRotationStatusCommandInput, GetKeyRotationStatusCommandOutput } from "./commands/GetKeyRotationStatusCommand";
|
|
@@ -54,8 +55,9 @@ import { UpdateCustomKeyStoreCommandInput, UpdateCustomKeyStoreCommandOutput } f
|
|
|
54
55
|
import { UpdateKeyDescriptionCommandInput, UpdateKeyDescriptionCommandOutput } from "./commands/UpdateKeyDescriptionCommand";
|
|
55
56
|
import { UpdatePrimaryRegionCommandInput, UpdatePrimaryRegionCommandOutput } from "./commands/UpdatePrimaryRegionCommand";
|
|
56
57
|
import { VerifyCommandInput, VerifyCommandOutput } from "./commands/VerifyCommand";
|
|
57
|
-
|
|
58
|
-
export declare type
|
|
58
|
+
import { VerifyMacCommandInput, VerifyMacCommandOutput } from "./commands/VerifyMacCommand";
|
|
59
|
+
export declare type ServiceInputTypes = CancelKeyDeletionCommandInput | ConnectCustomKeyStoreCommandInput | CreateAliasCommandInput | CreateCustomKeyStoreCommandInput | CreateGrantCommandInput | CreateKeyCommandInput | DecryptCommandInput | DeleteAliasCommandInput | DeleteCustomKeyStoreCommandInput | DeleteImportedKeyMaterialCommandInput | DescribeCustomKeyStoresCommandInput | DescribeKeyCommandInput | DisableKeyCommandInput | DisableKeyRotationCommandInput | DisconnectCustomKeyStoreCommandInput | EnableKeyCommandInput | EnableKeyRotationCommandInput | EncryptCommandInput | GenerateDataKeyCommandInput | GenerateDataKeyPairCommandInput | GenerateDataKeyPairWithoutPlaintextCommandInput | GenerateDataKeyWithoutPlaintextCommandInput | GenerateMacCommandInput | GenerateRandomCommandInput | GetKeyPolicyCommandInput | GetKeyRotationStatusCommandInput | GetParametersForImportCommandInput | GetPublicKeyCommandInput | ImportKeyMaterialCommandInput | ListAliasesCommandInput | ListGrantsCommandInput | ListKeyPoliciesCommandInput | ListKeysCommandInput | ListResourceTagsCommandInput | ListRetirableGrantsCommandInput | PutKeyPolicyCommandInput | ReEncryptCommandInput | ReplicateKeyCommandInput | RetireGrantCommandInput | RevokeGrantCommandInput | ScheduleKeyDeletionCommandInput | SignCommandInput | TagResourceCommandInput | UntagResourceCommandInput | UpdateAliasCommandInput | UpdateCustomKeyStoreCommandInput | UpdateKeyDescriptionCommandInput | UpdatePrimaryRegionCommandInput | VerifyCommandInput | VerifyMacCommandInput;
|
|
60
|
+
export declare type ServiceOutputTypes = CancelKeyDeletionCommandOutput | ConnectCustomKeyStoreCommandOutput | CreateAliasCommandOutput | CreateCustomKeyStoreCommandOutput | CreateGrantCommandOutput | CreateKeyCommandOutput | DecryptCommandOutput | DeleteAliasCommandOutput | DeleteCustomKeyStoreCommandOutput | DeleteImportedKeyMaterialCommandOutput | DescribeCustomKeyStoresCommandOutput | DescribeKeyCommandOutput | DisableKeyCommandOutput | DisableKeyRotationCommandOutput | DisconnectCustomKeyStoreCommandOutput | EnableKeyCommandOutput | EnableKeyRotationCommandOutput | EncryptCommandOutput | GenerateDataKeyCommandOutput | GenerateDataKeyPairCommandOutput | GenerateDataKeyPairWithoutPlaintextCommandOutput | GenerateDataKeyWithoutPlaintextCommandOutput | GenerateMacCommandOutput | GenerateRandomCommandOutput | GetKeyPolicyCommandOutput | GetKeyRotationStatusCommandOutput | GetParametersForImportCommandOutput | GetPublicKeyCommandOutput | ImportKeyMaterialCommandOutput | ListAliasesCommandOutput | ListGrantsCommandOutput | ListKeyPoliciesCommandOutput | ListKeysCommandOutput | ListResourceTagsCommandOutput | ListRetirableGrantsCommandOutput | PutKeyPolicyCommandOutput | ReEncryptCommandOutput | ReplicateKeyCommandOutput | RetireGrantCommandOutput | RevokeGrantCommandOutput | ScheduleKeyDeletionCommandOutput | SignCommandOutput | TagResourceCommandOutput | UntagResourceCommandOutput | UpdateAliasCommandOutput | UpdateCustomKeyStoreCommandOutput | UpdateKeyDescriptionCommandOutput | UpdatePrimaryRegionCommandOutput | VerifyCommandOutput | VerifyMacCommandOutput;
|
|
59
61
|
export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__HttpHandlerOptions>> {
|
|
60
62
|
/**
|
|
61
63
|
* The HTTP handler to use. Fetch in browser and Https in Nodejs.
|
|
@@ -190,7 +192,10 @@ export interface KMSClientResolvedConfig extends KMSClientResolvedConfigType {
|
|
|
190
192
|
* download and install them, see <a href="http://aws.amazon.com/tools/">Tools for Amazon Web
|
|
191
193
|
* Services</a>.</p>
|
|
192
194
|
* </note>
|
|
193
|
-
* <p>We recommend that you use the Amazon Web Services SDKs to make programmatic API calls to KMS
|
|
195
|
+
* <p>We recommend that you use the Amazon Web Services SDKs to make programmatic API calls to KMS. </p>
|
|
196
|
+
* <p>If you need to use FIPS 140-2 validated cryptographic modules when communicating with
|
|
197
|
+
* Amazon Web Services, use the FIPS endpoint in your preferred Amazon Web Services Region. For more information about the
|
|
198
|
+
* available FIPS endpoints, see <a href="https://docs.aws.amazon.com/general/latest/gr/kms.html#kms_region">Service endpoints</a> in the Key Management Service topic of the <i>Amazon Web Services General Reference</i>.</p>
|
|
194
199
|
* <p>Clients must support TLS (Transport Layer Security) 1.0. We recommend TLS 1.2. Clients
|
|
195
200
|
* must also support cipher suites with Perfect Forward Secrecy (PFS) such as Ephemeral
|
|
196
201
|
* Diffie-Hellman (DHE) or Elliptic Curve Ephemeral Diffie-Hellman (ECDHE). Most modern systems
|
|
@@ -12,7 +12,7 @@ export interface CancelKeyDeletionCommandOutput extends CancelKeyDeletionRespons
|
|
|
12
12
|
* <p>For more information about scheduling and canceling deletion of a KMS key, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/deleting-keys.html">Deleting KMS keys</a> in the
|
|
13
13
|
* <i>Key Management Service Developer Guide</i>.</p>
|
|
14
14
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
15
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
15
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
16
16
|
* <p>
|
|
17
17
|
* <b>Cross-account
|
|
18
18
|
* use</b>: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account.</p>
|
|
@@ -9,7 +9,7 @@ export interface CreateAliasCommandOutput extends __MetadataBearer {
|
|
|
9
9
|
/**
|
|
10
10
|
* <p>Creates a friendly name for a KMS key. </p>
|
|
11
11
|
* <note>
|
|
12
|
-
* <p>Adding, deleting, or updating an alias can allow or deny permission to the KMS key. For details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/abac.html">
|
|
12
|
+
* <p>Adding, deleting, or updating an alias can allow or deny permission to the KMS key. For details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/abac.html">ABAC in KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
13
13
|
* </note>
|
|
14
14
|
* <p>You can use an alias to identify a KMS key in the KMS console, in the <a>DescribeKey</a> operation and in <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations">cryptographic operations</a>, such as <a>Encrypt</a> and
|
|
15
15
|
* <a>GenerateDataKey</a>. You can also change the KMS key that's associated with
|
|
@@ -24,7 +24,7 @@ export interface CreateAliasCommandOutput extends __MetadataBearer {
|
|
|
24
24
|
* <p>This operation does not return a response. To get the alias that you created, use the
|
|
25
25
|
* <a>ListAliases</a> operation.</p>
|
|
26
26
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
27
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
27
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
28
28
|
* <p>
|
|
29
29
|
* <b>Cross-account use</b>: No. You cannot perform this operation on an alias in a different Amazon Web Services account.</p>
|
|
30
30
|
*
|
|
@@ -13,7 +13,7 @@ export interface CreateGrantCommandOutput extends CreateGrantResponse, __Metadat
|
|
|
13
13
|
* grants are considered along with key policies and IAM policies. Grants are often used for
|
|
14
14
|
* temporary permissions because you can create one, use its permissions, and delete it without
|
|
15
15
|
* changing your key policies or IAM policies. </p>
|
|
16
|
-
* <p>For detailed information about grants, including grant terminology, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/grants.html">
|
|
16
|
+
* <p>For detailed information about grants, including grant terminology, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/grants.html">Grants in KMS</a> in the
|
|
17
17
|
* <i>
|
|
18
18
|
* <i>Key Management Service Developer Guide</i>
|
|
19
19
|
* </i>. For examples of working with grants in several
|
|
@@ -38,7 +38,7 @@ export interface CreateGrantCommandOutput extends CreateGrantResponse, __Metadat
|
|
|
38
38
|
* </li>
|
|
39
39
|
* </ul>
|
|
40
40
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
41
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
41
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
42
42
|
* <p>
|
|
43
43
|
* <b>Cross-account use</b>: Yes.
|
|
44
44
|
* To perform this operation on a KMS key in a different Amazon Web Services account, specify the key
|
|
@@ -8,53 +8,53 @@ export interface CreateKeyCommandOutput extends CreateKeyResponse, __MetadataBea
|
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
10
|
* <p>Creates a unique customer managed <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#kms-keys">KMS key</a> in your Amazon Web Services account and
|
|
11
|
-
* Region
|
|
11
|
+
* Region. </p>
|
|
12
|
+
* <p>In addition to the required parameters, you can use the optional parameters to specify a key policy, description, tags, and other useful elements for any key type.</p>
|
|
12
13
|
* <note>
|
|
13
14
|
* <p>KMS is replacing the term <i>customer master key (CMK)</i> with <i>KMS key</i> and <i>KMS key</i>. The concept has not changed. To prevent breaking changes, KMS is keeping some variations of this term.</p>
|
|
14
15
|
* </note>
|
|
15
16
|
*
|
|
16
|
-
* <p>You can use the <code>CreateKey</code> operation to create symmetric or asymmetric KMS
|
|
17
|
-
* keys.</p>
|
|
18
|
-
* <ul>
|
|
19
|
-
* <li>
|
|
20
|
-
* <p>
|
|
21
|
-
* <b>Symmetric KMS keys</b> contain a 256-bit symmetric key
|
|
22
|
-
* that never leaves KMS unencrypted. To use the KMS key, you must call KMS. You can use
|
|
23
|
-
* a symmetric KMS key to encrypt and decrypt small amounts of data, but they are typically
|
|
24
|
-
* used to generate <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#data-keys">data keys</a> and <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#data-key-pairs">data keys pairs</a>. For details,
|
|
25
|
-
* see <a>GenerateDataKey</a> and <a>GenerateDataKeyPair</a>.</p>
|
|
26
|
-
* </li>
|
|
27
|
-
* <li>
|
|
28
|
-
* <p>
|
|
29
|
-
* <b>Asymmetric KMS keys</b> can contain an RSA key pair or an
|
|
30
|
-
* Elliptic Curve (ECC) key pair. The private key in an asymmetric KMS key never leaves KMS
|
|
31
|
-
* unencrypted. However, you can use the <a>GetPublicKey</a> operation to download
|
|
32
|
-
* the public key so it can be used outside of KMS. KMS keys with RSA key pairs can be used
|
|
33
|
-
* to encrypt or decrypt data or sign and verify messages (but not both). KMS keys with ECC
|
|
34
|
-
* key pairs can be used only to sign and verify messages.</p>
|
|
35
|
-
* </li>
|
|
36
|
-
* </ul>
|
|
37
|
-
* <p>For information about symmetric and asymmetric KMS keys, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html">Using Symmetric and Asymmetric KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
38
|
-
*
|
|
39
17
|
*
|
|
40
18
|
* <p>To create different types of KMS keys, use the following guidance:</p>
|
|
41
19
|
*
|
|
42
20
|
* <dl>
|
|
21
|
+
* <dt>Symmetric encryption KMS key</dt>
|
|
22
|
+
* <dd>
|
|
23
|
+
* <p>To create a symmetric encryption KMS key, you aren't required to specify any parameters. The default value for
|
|
24
|
+
* <code>KeySpec</code>, <code>SYMMETRIC_DEFAULT</code>, and the default value for
|
|
25
|
+
* <code>KeyUsage</code>, <code>ENCRYPT_DECRYPT</code>, create a symmetric encryption KMS key.</p>
|
|
26
|
+
* <p>If you need a key for basic encryption and decryption or you
|
|
27
|
+
* are creating a KMS key to protect your resources in an Amazon Web Services service, create a symmetric encryption KMS key. The key material in a symmetric encryption key never leaves KMS unencrypted. You can use a symmetric encryption KMS key to encrypt and decrypt data up to 4,096 bytes, but they are typically used to generate data keys and data keys pairs. For details, see <a>GenerateDataKey</a> and <a>GenerateDataKeyPair</a>.</p>
|
|
28
|
+
* <p> </p>
|
|
29
|
+
* </dd>
|
|
43
30
|
* <dt>Asymmetric KMS keys</dt>
|
|
44
31
|
* <dd>
|
|
45
32
|
* <p>To create an asymmetric KMS key, use the <code>KeySpec</code> parameter to specify
|
|
46
33
|
* the type of key material in the KMS key. Then, use the <code>KeyUsage</code> parameter
|
|
47
34
|
* to determine whether the KMS key will be used to encrypt and decrypt or sign and verify.
|
|
48
35
|
* You can't change these properties after the KMS key is created.</p>
|
|
36
|
+
* <p>Asymmetric KMS keys contain an RSA key pair or an Elliptic Curve (ECC) key pair. The private key in an asymmetric
|
|
37
|
+
* KMS key never leaves AWS KMS unencrypted. However, you can use the <a>GetPublicKey</a> operation to download the public key
|
|
38
|
+
* so it can be used outside of AWS KMS. KMS keys with RSA key pairs can be used to encrypt or decrypt data or sign and verify messages (but not both).
|
|
39
|
+
* KMS keys with ECC key pairs can be used only to sign and verify messages.
|
|
40
|
+
* For information about asymmetric KMS keys, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html">Asymmetric KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
49
41
|
* <p> </p>
|
|
50
42
|
* </dd>
|
|
51
|
-
* <dt>
|
|
43
|
+
* <dt>HMAC KMS key</dt>
|
|
52
44
|
* <dd>
|
|
53
|
-
* <p>
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
*
|
|
45
|
+
* <p>To create an HMAC KMS key, set the <code>KeySpec</code> parameter to a
|
|
46
|
+
* key spec value for HMAC KMS keys. Then set the <code>KeyUsage</code> parameter to
|
|
47
|
+
* <code>GENERATE_VERIFY_MAC</code>. You must set the key usage even though
|
|
48
|
+
* <code>GENERATE_VERIFY_MAC</code> is the only valid key usage value for HMAC KMS keys.
|
|
49
|
+
* You can't change these properties after the KMS key is created.</p>
|
|
50
|
+
* <p>HMAC KMS keys are symmetric keys that never leave KMS unencrypted. You can use
|
|
51
|
+
* HMAC keys to generate (<a>GenerateMac</a>) and verify (<a>VerifyMac</a>) HMAC codes for messages up to 4096 bytes.</p>
|
|
52
|
+
* <p>HMAC KMS keys are not supported in all Amazon Web Services Regions. If you try to create an HMAC
|
|
53
|
+
* KMS key in an Amazon Web Services Region in which HMAC keys are not supported, the
|
|
54
|
+
* <code>CreateKey</code> operation returns an
|
|
55
|
+
* <code>UnsupportedOperationException</code>. For a list of Regions in which HMAC KMS keys
|
|
56
|
+
* are supported, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html">HMAC keys in
|
|
57
|
+
* KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
58
58
|
* <p> </p>
|
|
59
59
|
* </dd>
|
|
60
60
|
* <dt>Multi-Region primary keys</dt>
|
|
@@ -66,38 +66,42 @@ export interface CreateKeyCommandOutput extends CreateKeyResponse, __MetadataBea
|
|
|
66
66
|
* and key material as a primary key, but in a different Amazon Web Services Region, use the <a>ReplicateKey</a> operation. To change a replica key to a primary key, and its
|
|
67
67
|
* primary key to a replica key, use the <a>UpdatePrimaryRegion</a>
|
|
68
68
|
* operation.</p>
|
|
69
|
+
* <p>You can create multi-Region KMS keys for all supported KMS key types: symmetric
|
|
70
|
+
* encryption KMS keys, HMAC KMS keys, asymmetric encryption KMS keys, and asymmetric
|
|
71
|
+
* signing KMS keys. You can also create multi-Region keys with imported key material.
|
|
72
|
+
* However, you can't create multi-Region keys in a custom key store.</p>
|
|
69
73
|
* <p>This operation supports <i>multi-Region keys</i>, an KMS feature that lets you create multiple
|
|
70
74
|
* interoperable KMS keys in different Amazon Web Services Regions. Because these KMS keys have the same key ID, key
|
|
71
75
|
* material, and other metadata, you can use them interchangeably to encrypt data in one Amazon Web Services Region and decrypt
|
|
72
|
-
* it in a different Amazon Web Services Region without re-encrypting the data or making a cross-Region call. For more information about multi-Region keys, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html">
|
|
73
|
-
* <p>You can create symmetric and asymmetric multi-Region keys and multi-Region keys with
|
|
74
|
-
* imported key material. You cannot create multi-Region keys in a custom key store.</p>
|
|
76
|
+
* it in a different Amazon Web Services Region without re-encrypting the data or making a cross-Region call. For more information about multi-Region keys, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html">Multi-Region keys in KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
75
77
|
* <p> </p>
|
|
76
78
|
* </dd>
|
|
77
79
|
* <dd>
|
|
78
|
-
* <p>To import your own key material, begin by creating a symmetric KMS key with no key
|
|
80
|
+
* <p>To import your own key material, begin by creating a symmetric encryption KMS key with no key
|
|
79
81
|
* material. To do this, use the <code>Origin</code> parameter of <code>CreateKey</code>
|
|
80
82
|
* with a value of <code>EXTERNAL</code>. Next, use <a>GetParametersForImport</a> operation to get a public key and import token, and use the public key to encrypt
|
|
81
83
|
* your key material. Then, use <a>ImportKeyMaterial</a> with your import token
|
|
82
84
|
* to import the key material. For step-by-step instructions, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html">Importing Key Material</a> in the <i>
|
|
83
85
|
* <i>Key Management Service Developer Guide</i>
|
|
84
|
-
* </i
|
|
85
|
-
*
|
|
86
|
+
* </i>.</p>
|
|
87
|
+
* <p>This feature supports only symmetric encryption KMS keys, including multi-Region symmetric encryption KMS keys. You cannot import key
|
|
88
|
+
* material into any other type of KMS key.</p>
|
|
86
89
|
* <p>To create a multi-Region primary key with imported key material, use the
|
|
87
90
|
* <code>Origin</code> parameter of <code>CreateKey</code> with a value of
|
|
88
91
|
* <code>EXTERNAL</code> and the <code>MultiRegion</code> parameter with a value of
|
|
89
|
-
* <code>True</code>. To create replicas of the multi-Region primary key, use the <a>ReplicateKey</a> operation. For more information about multi-Region keys, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html">
|
|
92
|
+
* <code>True</code>. To create replicas of the multi-Region primary key, use the <a>ReplicateKey</a> operation. For more information about multi-Region keys, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-overview.html">Multi-Region keys in KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
90
93
|
* <p> </p>
|
|
91
94
|
* </dd>
|
|
92
95
|
* <dt>Custom key store</dt>
|
|
93
96
|
* <dd>
|
|
94
|
-
* <p>To create a symmetric KMS key in a <a href="https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html">custom key store</a>, use the
|
|
97
|
+
* <p>To create a symmetric encryption KMS key in a <a href="https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html">custom key store</a>, use the
|
|
95
98
|
* <code>CustomKeyStoreId</code> parameter to specify the custom key store. You must also
|
|
96
99
|
* use the <code>Origin</code> parameter with a value of <code>AWS_CLOUDHSM</code>. The
|
|
97
100
|
* CloudHSM cluster that is associated with the custom key store must have at least two active
|
|
98
101
|
* HSMs in different Availability Zones in the Amazon Web Services Region. </p>
|
|
99
|
-
* <p>
|
|
100
|
-
*
|
|
102
|
+
* <p>Custom key stores support only symmetric encryption KMS keys. You cannot create an
|
|
103
|
+
* HMAC KMS key or an asymmetric KMS key in a custom key store. For information about
|
|
104
|
+
* custom key stores in KMS see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html">Custom key stores in KMS</a> in
|
|
101
105
|
* the <i>
|
|
102
106
|
* <i>Key Management Service Developer Guide</i>
|
|
103
107
|
* </i>.</p>
|
|
@@ -36,15 +36,15 @@ export interface DecryptCommandOutput extends DecryptResponse, __MetadataBearer
|
|
|
36
36
|
* </p>
|
|
37
37
|
* </li>
|
|
38
38
|
* </ul>
|
|
39
|
-
* <p>You can use this operation to decrypt ciphertext that was encrypted under a symmetric or
|
|
40
|
-
* asymmetric KMS key. When the KMS key is asymmetric, you must specify the KMS key and the
|
|
41
|
-
* encryption algorithm that was used to encrypt the ciphertext. For information about
|
|
42
|
-
* <p>The Decrypt operation also decrypts ciphertext that was encrypted outside of KMS by the
|
|
43
|
-
* public key in an KMS asymmetric KMS key. However, it cannot decrypt ciphertext produced by
|
|
39
|
+
* <p>You can use this operation to decrypt ciphertext that was encrypted under a symmetric encryption KMS key or an
|
|
40
|
+
* asymmetric encryption KMS key. When the KMS key is asymmetric, you must specify the KMS key and the
|
|
41
|
+
* encryption algorithm that was used to encrypt the ciphertext. For information about asymmetric KMS keys, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html">Asymmetric KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
42
|
+
* <p>The <code>Decrypt</code> operation also decrypts ciphertext that was encrypted outside of KMS by the
|
|
43
|
+
* public key in an KMS asymmetric KMS key. However, it cannot decrypt symmetric ciphertext produced by
|
|
44
44
|
* other libraries, such as the <a href="https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/">Amazon Web Services
|
|
45
45
|
* Encryption SDK</a> or <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html">Amazon S3 client-side encryption</a>.
|
|
46
46
|
* These libraries return a ciphertext format that is incompatible with KMS.</p>
|
|
47
|
-
* <p>If the ciphertext was encrypted under a symmetric KMS key, the <code>KeyId</code>
|
|
47
|
+
* <p>If the ciphertext was encrypted under a symmetric encryption KMS key, the <code>KeyId</code>
|
|
48
48
|
* parameter is optional. KMS can get this information from metadata that it adds to the
|
|
49
49
|
* symmetric ciphertext blob. This feature adds durability to your implementation by ensuring
|
|
50
50
|
* that authorized users can decrypt ciphertext decades after it was encrypted, even if they've
|
|
@@ -63,7 +63,7 @@ export interface DecryptCommandOutput extends DecryptResponse, __MetadataBearer
|
|
|
63
63
|
* policies</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
64
64
|
* <p>Applications in Amazon Web Services Nitro Enclaves can call this operation by using the <a href="https://github.com/aws/aws-nitro-enclaves-sdk-c">Amazon Web Services Nitro Enclaves Development Kit</a>. For information about the supporting parameters, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/services-nitro-enclaves.html">How Amazon Web Services Nitro Enclaves use KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
65
65
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
66
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
66
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
67
67
|
* <p>
|
|
68
68
|
* <b>Cross-account
|
|
69
69
|
* use</b>: Yes. To perform this operation with a KMS key in a different Amazon Web Services account, specify
|
|
@@ -9,7 +9,7 @@ export interface DeleteAliasCommandOutput extends __MetadataBearer {
|
|
|
9
9
|
/**
|
|
10
10
|
* <p>Deletes the specified alias. </p>
|
|
11
11
|
* <note>
|
|
12
|
-
* <p>Adding, deleting, or updating an alias can allow or deny permission to the KMS key. For details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/abac.html">
|
|
12
|
+
* <p>Adding, deleting, or updating an alias can allow or deny permission to the KMS key. For details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/abac.html">ABAC in KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
13
13
|
* </note>
|
|
14
14
|
* <p>Because an alias is not a property of a KMS key, you can delete and change the aliases of
|
|
15
15
|
* a KMS key without affecting the KMS key. Also, aliases do not appear in the response from the
|
|
@@ -16,7 +16,7 @@ export interface DeleteImportedKeyMaterialCommandOutput extends __MetadataBearer
|
|
|
16
16
|
* <p>After you delete key material, you can use <a>ImportKeyMaterial</a> to reimport
|
|
17
17
|
* the same key material into the KMS key.</p>
|
|
18
18
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
19
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
19
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
20
20
|
* <p>
|
|
21
21
|
* <b>Cross-account use</b>: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account.</p>
|
|
22
22
|
*
|
|
@@ -12,10 +12,7 @@ export interface DescribeKeyCommandOutput extends DescribeKeyResponse, __Metadat
|
|
|
12
12
|
* key</a> or an <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk">Amazon Web Services managed key</a>.</p>
|
|
13
13
|
* <p>This detailed information includes the key ARN, creation date (and deletion date, if
|
|
14
14
|
* applicable), the key state, and the origin and expiration date (if any) of the key material.
|
|
15
|
-
* It includes fields, like <code>KeySpec</code>, that help you distinguish
|
|
16
|
-
* asymmetric KMS keys. It also provides information that is particularly important to asymmetric
|
|
17
|
-
* keys, such as the key usage (encryption or signing) and the encryption algorithms or signing
|
|
18
|
-
* algorithms that the KMS key supports. For KMS keys in custom key stores, it includes
|
|
15
|
+
* It includes fields, like <code>KeySpec</code>, that help you distinguish different types of KMS keys. It also displays the key usage (encryption, signing, or generating and verifying MACs) and the algorithms that the KMS key supports. For KMS keys in custom key stores, it includes
|
|
19
16
|
* information about the custom key store, such as the key store ID and the CloudHSM cluster ID. For
|
|
20
17
|
* multi-Region keys, it displays the primary key and all related replica keys. </p>
|
|
21
18
|
* <p>
|
|
@@ -37,10 +34,11 @@ export interface DescribeKeyCommandOutput extends DescribeKeyResponse, __Metadat
|
|
|
37
34
|
* <p>Key policies and grants on the KMS key. To get this information, use <a>GetKeyPolicy</a> and <a>ListGrants</a>.</p>
|
|
38
35
|
* </li>
|
|
39
36
|
* </ul>
|
|
40
|
-
* <p>
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
37
|
+
* <p>In general, <code>DescribeKey</code> is a non-mutating operation. It returns data about
|
|
38
|
+
* KMS keys, but doesn't change them. However, Amazon Web Services services use <code>DescribeKey</code> to
|
|
39
|
+
* create <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk">Amazon Web Services
|
|
40
|
+
* managed keys</a> from a <i>predefined Amazon Web Services alias</i> with no key
|
|
41
|
+
* ID.</p>
|
|
44
42
|
* <p>
|
|
45
43
|
* <b>Cross-account use</b>: Yes. To perform this operation with a KMS key in a different Amazon Web Services account, specify
|
|
46
44
|
* the key ARN or alias ARN in the value of the <code>KeyId</code> parameter.</p>
|
|
@@ -9,12 +9,11 @@ export interface DisableKeyCommandOutput extends __MetadataBearer {
|
|
|
9
9
|
/**
|
|
10
10
|
* <p>Sets the state of a KMS key to disabled. This change temporarily prevents use of the KMS
|
|
11
11
|
* key for <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations">cryptographic operations</a>. </p>
|
|
12
|
-
* <p>For more information about how key state affects the use of a KMS key, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
13
|
-
* key</a> in the <i>
|
|
12
|
+
* <p>For more information about how key state affects the use of a KMS key, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>
|
|
14
13
|
* <i>Key Management Service Developer Guide</i>
|
|
15
14
|
* </i>.</p>
|
|
16
15
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
17
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
16
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
18
17
|
* <p>
|
|
19
18
|
* <b>Cross-account use</b>: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account.</p>
|
|
20
19
|
*
|
|
@@ -8,10 +8,10 @@ export interface DisableKeyRotationCommandOutput extends __MetadataBearer {
|
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
10
|
* <p>Disables <a href="https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html">automatic
|
|
11
|
-
* rotation of the key material</a> for the specified symmetric KMS key.</p>
|
|
12
|
-
* <p> You cannot enable automatic rotation of <a href="https://docs.aws.amazon.com/kms/latest/developerguide/
|
|
11
|
+
* rotation of the key material</a> for the specified symmetric encryption KMS key.</p>
|
|
12
|
+
* <p> You cannot enable automatic rotation of <a href="https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html">asymmetric KMS keys</a>, <a href="https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html">HMAC KMS keys</a>, KMS keys with <a href="https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html">imported key material</a>, or KMS keys in a <a href="https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html">custom key store</a>. To enable or disable automatic rotation of a set of related <a href="https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-manage.html#multi-region-rotate">multi-Region keys</a>, set the property on the primary key. </p>
|
|
13
13
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
14
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
14
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
15
15
|
* <p>
|
|
16
16
|
* <b>Cross-account
|
|
17
17
|
* use</b>: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account.</p>
|
|
@@ -10,7 +10,7 @@ export interface EnableKeyCommandOutput extends __MetadataBearer {
|
|
|
10
10
|
* <p>Sets the key state of a KMS key to enabled. This allows you to use the KMS key for
|
|
11
11
|
* <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#cryptographic-operations">cryptographic operations</a>. </p>
|
|
12
12
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
13
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
13
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
14
14
|
* <p>
|
|
15
15
|
* <b>Cross-account
|
|
16
16
|
* use</b>: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account.</p>
|
|
@@ -8,10 +8,10 @@ export interface EnableKeyRotationCommandOutput extends __MetadataBearer {
|
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
10
|
* <p>Enables <a href="https://docs.aws.amazon.com/kms/latest/developerguide/rotate-keys.html">automatic rotation
|
|
11
|
-
* of the key material</a> for the specified symmetric KMS key.</p>
|
|
12
|
-
* <p>You cannot enable automatic rotation of <a href="https://docs.aws.amazon.com/kms/latest/developerguide/
|
|
11
|
+
* of the key material</a> for the specified symmetric encryption KMS key.</p>
|
|
12
|
+
* <p>You cannot enable automatic rotation of <a href="https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html">asymmetric KMS keys</a>, <a href="https://docs.aws.amazon.com/kms/latest/developerguide/hmac.html">HMAC KMS keys</a>, KMS keys with <a href="https://docs.aws.amazon.com/kms/latest/developerguide/importing-keys.html">imported key material</a>, or KMS keys in a <a href="https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html">custom key store</a>. To enable or disable automatic rotation of a set of related <a href="https://docs.aws.amazon.com/kms/latest/developerguide/multi-region-keys-manage.html#multi-region-rotate">multi-Region keys</a>, set the property on the primary key.</p>
|
|
13
13
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
14
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
14
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
15
15
|
* <p>
|
|
16
16
|
* <b>Cross-account
|
|
17
17
|
* use</b>: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account.</p>
|
|
@@ -7,31 +7,13 @@ export interface EncryptCommandInput extends EncryptRequest {
|
|
|
7
7
|
export interface EncryptCommandOutput extends EncryptResponse, __MetadataBearer {
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* <p>Encrypts plaintext
|
|
11
|
-
*
|
|
12
|
-
* <
|
|
13
|
-
*
|
|
14
|
-
* <p>You can encrypt small amounts of arbitrary data, such as a personal identifier or
|
|
15
|
-
* database password, or other sensitive information. </p>
|
|
16
|
-
* </li>
|
|
17
|
-
* <li>
|
|
18
|
-
* <p>You can use the <code>Encrypt</code> operation to move encrypted data from one Amazon Web Services
|
|
19
|
-
* Region to another. For example, in Region A, generate a data key and use the plaintext key
|
|
20
|
-
* to encrypt your data. Then, in Region A, use the <code>Encrypt</code> operation to encrypt
|
|
21
|
-
* the plaintext data key under a KMS key in Region B. Now, you can move the encrypted data
|
|
22
|
-
* and the encrypted data key to Region B. When necessary, you can decrypt the encrypted data
|
|
23
|
-
* key and the encrypted data entirely within in Region B.</p>
|
|
24
|
-
* </li>
|
|
25
|
-
* </ul>
|
|
26
|
-
*
|
|
27
|
-
* <p>You don't need to use the <code>Encrypt</code> operation to encrypt a data key. The <a>GenerateDataKey</a> and <a>GenerateDataKeyPair</a> operations return a
|
|
10
|
+
* <p>Encrypts plaintext of up to 4,096 bytes using a KMS key. You can use a symmetric or
|
|
11
|
+
* asymmetric KMS key with a <code>KeyUsage</code> of <code>ENCRYPT_DECRYPT</code>.</p>
|
|
12
|
+
* <p>You can use this operation to encrypt small amounts of arbitrary data, such as a personal identifier or
|
|
13
|
+
* database password, or other sensitive information. You don't need to use the <code>Encrypt</code> operation to encrypt a data key. The <a>GenerateDataKey</a> and <a>GenerateDataKeyPair</a> operations return a
|
|
28
14
|
* plaintext data key and an encrypted copy of that data key.</p>
|
|
29
15
|
*
|
|
30
|
-
* <p>
|
|
31
|
-
* encryption operation. The KMS key must have a <code>KeyUsage</code> value of
|
|
32
|
-
* <code>ENCRYPT_DECRYPT.</code> To find the <code>KeyUsage</code> of a KMS key, use the <a>DescribeKey</a> operation. </p>
|
|
33
|
-
*
|
|
34
|
-
* <p>If you use a symmetric KMS key, you can use an encryption context to add additional
|
|
16
|
+
* <p>If you use a symmetric encryption KMS key, you can use an encryption context to add additional
|
|
35
17
|
* security to your encryption operation. If you specify an <code>EncryptionContext</code> when
|
|
36
18
|
* encrypting data, you must specify the same encryption context (a case-sensitive exact match)
|
|
37
19
|
* when decrypting the data. Otherwise, the request to decrypt fails with an
|
|
@@ -41,7 +23,7 @@ export interface EncryptCommandOutput extends EncryptResponse, __MetadataBearer
|
|
|
41
23
|
* algorithm must be compatible with the KMS key type.</p>
|
|
42
24
|
* <important>
|
|
43
25
|
* <p>When you use an asymmetric KMS key to encrypt or reencrypt data, be sure to record the KMS key and encryption algorithm that you choose. You will be required to provide the same KMS key and encryption algorithm when you decrypt the data. If the KMS key and algorithm do not match the values used to encrypt the data, the decrypt operation fails.</p>
|
|
44
|
-
* <p>You are not required to supply the key ID and encryption algorithm when you decrypt with symmetric KMS keys because KMS stores this information in the ciphertext blob. KMS cannot store metadata in ciphertext generated with asymmetric keys. The standard format for asymmetric key ciphertext does not include configurable fields.</p>
|
|
26
|
+
* <p>You are not required to supply the key ID and encryption algorithm when you decrypt with symmetric encryption KMS keys because KMS stores this information in the ciphertext blob. KMS cannot store metadata in ciphertext generated with asymmetric keys. The standard format for asymmetric key ciphertext does not include configurable fields.</p>
|
|
45
27
|
* </important>
|
|
46
28
|
*
|
|
47
29
|
*
|
|
@@ -49,7 +31,7 @@ export interface EncryptCommandOutput extends EncryptResponse, __MetadataBearer
|
|
|
49
31
|
* encryption algorithm that you choose.</p>
|
|
50
32
|
* <ul>
|
|
51
33
|
* <li>
|
|
52
|
-
* <p>Symmetric KMS keys</p>
|
|
34
|
+
* <p>Symmetric encryption KMS keys</p>
|
|
53
35
|
* <ul>
|
|
54
36
|
* <li>
|
|
55
37
|
* <p>
|
|
@@ -104,7 +86,7 @@ export interface EncryptCommandOutput extends EncryptResponse, __MetadataBearer
|
|
|
104
86
|
* </li>
|
|
105
87
|
* </ul>
|
|
106
88
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
107
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
89
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
108
90
|
* <p>
|
|
109
91
|
* <b>Cross-account use</b>: Yes.
|
|
110
92
|
* To perform this operation with a KMS key in a different Amazon Web Services account, specify
|
|
@@ -7,33 +7,31 @@ export interface GenerateDataKeyCommandInput extends GenerateDataKeyRequest {
|
|
|
7
7
|
export interface GenerateDataKeyCommandOutput extends GenerateDataKeyResponse, __MetadataBearer {
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* <p>
|
|
11
|
-
* plaintext copy of the data key and a copy that is encrypted under a
|
|
12
|
-
*
|
|
13
|
-
*
|
|
10
|
+
* <p>Returns a unique symmetric data key for use outside of KMS. This operation returns a
|
|
11
|
+
* plaintext copy of the data key and a copy that is encrypted under a symmetric encryption KMS
|
|
12
|
+
* key that you specify. The bytes in the plaintext key are random; they are not related to the caller or the KMS
|
|
13
|
+
* key. You can use the plaintext key to encrypt your data outside of KMS and store the
|
|
14
|
+
* encrypted data key with the encrypted data.</p>
|
|
14
15
|
*
|
|
15
|
-
* <p>
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
* KMS key, use the <a>DescribeKey</a> operation. You must also specify the length of
|
|
22
|
-
* the data key. Use either the <code>KeySpec</code> or <code>NumberOfBytes</code> parameters
|
|
23
|
-
* (but not both). For 128-bit and 256-bit data keys, use the <code>KeySpec</code> parameter. </p>
|
|
16
|
+
* <p>To generate a data key, specify the symmetric encryption KMS key that will be used to
|
|
17
|
+
* encrypt the data key. You cannot use an asymmetric KMS key to encrypt data keys. To get the
|
|
18
|
+
* type of your KMS key, use the <a>DescribeKey</a> operation. You must also specify
|
|
19
|
+
* the length of the data key. Use either the <code>KeySpec</code> or <code>NumberOfBytes</code>
|
|
20
|
+
* parameters (but not both). For 128-bit and 256-bit data keys, use the <code>KeySpec</code>
|
|
21
|
+
* parameter. </p>
|
|
24
22
|
*
|
|
25
23
|
* <p>To get only an encrypted copy of the data key, use <a>GenerateDataKeyWithoutPlaintext</a>. To generate an asymmetric data key pair, use
|
|
26
24
|
* the <a>GenerateDataKeyPair</a> or <a>GenerateDataKeyPairWithoutPlaintext</a> operation. To get a cryptographically secure
|
|
27
25
|
* random byte string, use <a>GenerateRandom</a>.</p>
|
|
28
26
|
*
|
|
29
|
-
* <p>You can use
|
|
27
|
+
* <p>You can use an optional encryption context to add additional security to the encryption
|
|
30
28
|
* operation. If you specify an <code>EncryptionContext</code>, you must specify the same
|
|
31
29
|
* encryption context (a case-sensitive exact match) when decrypting the encrypted data key.
|
|
32
30
|
* Otherwise, the request to decrypt fails with an <code>InvalidCiphertextException</code>. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context">Encryption Context</a> in the
|
|
33
31
|
* <i>Key Management Service Developer Guide</i>.</p>
|
|
34
32
|
* <p>Applications in Amazon Web Services Nitro Enclaves can call this operation by using the <a href="https://github.com/aws/aws-nitro-enclaves-sdk-c">Amazon Web Services Nitro Enclaves Development Kit</a>. For information about the supporting parameters, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/services-nitro-enclaves.html">How Amazon Web Services Nitro Enclaves use KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
35
33
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
36
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
34
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
37
35
|
* <p>
|
|
38
36
|
* <b>How to use your data
|
|
39
37
|
* key</b>
|
|
@@ -7,19 +7,20 @@ export interface GenerateDataKeyPairCommandInput extends GenerateDataKeyPairRequ
|
|
|
7
7
|
export interface GenerateDataKeyPairCommandOutput extends GenerateDataKeyPairResponse, __MetadataBearer {
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* <p>
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
10
|
+
* <p>Returns a unique asymmetric data key pair for use outside of KMS. This operation returns
|
|
11
|
+
* a plaintext public key, a plaintext private key, and a copy of the private key that is
|
|
12
|
+
* encrypted under the symmetric encryption KMS key you specify. You can use the data key pair to
|
|
13
|
+
* perform asymmetric cryptography and implement digital signatures outside of KMS. The bytes
|
|
14
|
+
* in the keys are random; they not related to the caller or to the KMS key that is used to encrypt the
|
|
15
|
+
* private key. </p>
|
|
14
16
|
*
|
|
15
17
|
* <p>You can use the public key that <code>GenerateDataKeyPair</code> returns to encrypt data
|
|
16
18
|
* or verify a signature outside of KMS. Then, store the encrypted private key with the data.
|
|
17
19
|
* When you are ready to decrypt data or sign a message, you can use the <a>Decrypt</a> operation to decrypt the encrypted private key.</p>
|
|
18
20
|
*
|
|
19
|
-
* <p>To generate a data key pair, you must specify a symmetric KMS key to encrypt
|
|
20
|
-
* key in a data key pair. You cannot use an asymmetric KMS key or a KMS key in a
|
|
21
|
-
* store. To get the type and origin of your KMS key, use the <a>DescribeKey</a>
|
|
22
|
-
* operation. </p>
|
|
21
|
+
* <p>To generate a data key pair, you must specify a symmetric encryption KMS key to encrypt
|
|
22
|
+
* the private key in a data key pair. You cannot use an asymmetric KMS key or a KMS key in a
|
|
23
|
+
* custom key store. To get the type and origin of your KMS key, use the <a>DescribeKey</a> operation. </p>
|
|
23
24
|
* <p>Use the <code>KeyPairSpec</code> parameter to choose an RSA or Elliptic Curve (ECC) data
|
|
24
25
|
* key pair. KMS recommends that your use ECC key pairs for signing, and use RSA key pairs for
|
|
25
26
|
* either encryption or signing, but not both. However, KMS cannot enforce any restrictions on
|
|
@@ -35,18 +36,18 @@ export interface GenerateDataKeyPairCommandOutput extends GenerateDataKeyPairRes
|
|
|
35
36
|
*
|
|
36
37
|
* <p>
|
|
37
38
|
* <code>GenerateDataKeyPair</code> returns a unique data key pair for each request. The
|
|
38
|
-
* bytes in the keys are not related to the caller or the KMS key that is used to encrypt the
|
|
39
|
+
* bytes in the keys are random; they are not related to the caller or the KMS key that is used to encrypt the
|
|
39
40
|
* private key. The public key is a DER-encoded X.509 SubjectPublicKeyInfo, as specified in
|
|
40
41
|
* <a href="https://tools.ietf.org/html/rfc5280">RFC 5280</a>. The private key is a
|
|
41
42
|
* DER-encoded PKCS8 PrivateKeyInfo, as specified in <a href="https://tools.ietf.org/html/rfc5958">RFC 5958</a>.</p>
|
|
42
43
|
*
|
|
43
|
-
* <p>You can use
|
|
44
|
+
* <p>You can use an optional encryption context to add additional security to the encryption
|
|
44
45
|
* operation. If you specify an <code>EncryptionContext</code>, you must specify the same
|
|
45
46
|
* encryption context (a case-sensitive exact match) when decrypting the encrypted data key.
|
|
46
47
|
* Otherwise, the request to decrypt fails with an <code>InvalidCiphertextException</code>. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context">Encryption Context</a> in the
|
|
47
48
|
* <i>Key Management Service Developer Guide</i>.</p>
|
|
48
49
|
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
49
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key
|
|
50
|
+
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key states of KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
50
51
|
* <p>
|
|
51
52
|
* <b>Cross-account
|
|
52
53
|
* use</b>: Yes. To perform this operation with a KMS key in a different Amazon Web Services account, specify
|