@aws-sdk/client-kms 3.35.0 → 3.36.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 +14 -0
- package/README.md +8 -7
- package/dist-cjs/KMS.js +8 -8
- package/dist-cjs/KMSClient.js +8 -8
- package/dist-cjs/commands/CancelKeyDeletionCommand.js +6 -5
- package/dist-cjs/commands/ConnectCustomKeyStoreCommand.js +3 -4
- package/dist-cjs/commands/CreateAliasCommand.js +11 -8
- package/dist-cjs/commands/CreateCustomKeyStoreCommand.js +0 -1
- package/dist-cjs/commands/CreateGrantCommand.js +14 -12
- package/dist-cjs/commands/CreateKeyCommand.js +16 -15
- package/dist-cjs/commands/DecryptCommand.js +24 -22
- package/dist-cjs/commands/DeleteAliasCommand.js +11 -8
- package/dist-cjs/commands/DeleteCustomKeyStoreCommand.js +10 -12
- package/dist-cjs/commands/DeleteImportedKeyMaterialCommand.js +5 -7
- package/dist-cjs/commands/DescribeCustomKeyStoresCommand.js +4 -5
- package/dist-cjs/commands/DescribeKeyCommand.js +12 -11
- package/dist-cjs/commands/DisableKeyCommand.js +5 -5
- package/dist-cjs/commands/DisableKeyRotationCommand.js +2 -2
- package/dist-cjs/commands/DisconnectCustomKeyStoreCommand.js +6 -5
- package/dist-cjs/commands/EnableKeyCommand.js +4 -3
- package/dist-cjs/commands/EnableKeyRotationCommand.js +2 -2
- package/dist-cjs/commands/EncryptCommand.js +14 -13
- package/dist-cjs/commands/GenerateDataKeyCommand.js +15 -13
- package/dist-cjs/commands/GenerateDataKeyPairCommand.js +15 -14
- package/dist-cjs/commands/GenerateDataKeyPairWithoutPlaintextCommand.js +16 -14
- package/dist-cjs/commands/GenerateDataKeyWithoutPlaintextCommand.js +11 -10
- package/dist-cjs/commands/GenerateRandomCommand.js +2 -2
- package/dist-cjs/commands/GetKeyPolicyCommand.js +0 -1
- package/dist-cjs/commands/GetKeyRotationStatusCommand.js +2 -2
- package/dist-cjs/commands/GetParametersForImportCommand.js +7 -9
- package/dist-cjs/commands/GetPublicKeyCommand.js +7 -6
- package/dist-cjs/commands/ImportKeyMaterialCommand.js +13 -14
- package/dist-cjs/commands/ListAliasesCommand.js +13 -11
- package/dist-cjs/commands/ListGrantsCommand.js +2 -3
- package/dist-cjs/commands/ListKeyPoliciesCommand.js +3 -4
- package/dist-cjs/commands/ListKeysCommand.js +1 -3
- package/dist-cjs/commands/ListResourceTagsCommand.js +0 -1
- package/dist-cjs/commands/ListRetirableGrantsCommand.js +7 -7
- package/dist-cjs/commands/PutKeyPolicyCommand.js +0 -1
- package/dist-cjs/commands/ReEncryptCommand.js +33 -28
- package/dist-cjs/commands/ReplicateKeyCommand.js +5 -6
- package/dist-cjs/commands/RetireGrantCommand.js +7 -6
- package/dist-cjs/commands/RevokeGrantCommand.js +1 -3
- package/dist-cjs/commands/ScheduleKeyDeletionCommand.js +19 -16
- package/dist-cjs/commands/SignCommand.js +10 -10
- package/dist-cjs/commands/TagResourceCommand.js +6 -5
- package/dist-cjs/commands/UntagResourceCommand.js +3 -4
- package/dist-cjs/commands/UpdateAliasCommand.js +15 -12
- package/dist-cjs/commands/UpdateCustomKeyStoreCommand.js +17 -18
- package/dist-cjs/commands/UpdateKeyDescriptionCommand.js +3 -4
- package/dist-cjs/commands/UpdatePrimaryRegionCommand.js +1 -2
- package/dist-cjs/commands/VerifyCommand.js +5 -6
- package/dist-cjs/endpoints.js +0 -1
- package/dist-cjs/index.js +0 -1
- package/dist-cjs/models/index.js +0 -1
- package/dist-cjs/models/models_0.js +0 -1
- package/dist-cjs/pagination/Interfaces.js +0 -1
- package/dist-cjs/pagination/ListAliasesPaginator.js +0 -1
- package/dist-cjs/pagination/ListGrantsPaginator.js +0 -1
- package/dist-cjs/pagination/ListKeyPoliciesPaginator.js +0 -1
- package/dist-cjs/pagination/ListKeysPaginator.js +0 -1
- package/dist-cjs/protocols/Aws_json1_1.js +0 -1
- package/dist-cjs/runtimeConfig.browser.js +2 -3
- package/dist-cjs/runtimeConfig.js +3 -4
- package/dist-cjs/runtimeConfig.native.js +0 -1
- package/dist-cjs/runtimeConfig.shared.js +0 -1
- package/dist-es/KMS.js +0 -1
- package/dist-es/KMSClient.js +0 -1
- package/dist-es/commands/CancelKeyDeletionCommand.js +0 -1
- package/dist-es/commands/ConnectCustomKeyStoreCommand.js +0 -1
- package/dist-es/commands/CreateAliasCommand.js +0 -1
- package/dist-es/commands/CreateCustomKeyStoreCommand.js +0 -1
- package/dist-es/commands/CreateGrantCommand.js +0 -1
- package/dist-es/commands/CreateKeyCommand.js +0 -1
- package/dist-es/commands/DecryptCommand.js +0 -1
- package/dist-es/commands/DeleteAliasCommand.js +0 -1
- package/dist-es/commands/DeleteCustomKeyStoreCommand.js +0 -1
- package/dist-es/commands/DeleteImportedKeyMaterialCommand.js +0 -1
- package/dist-es/commands/DescribeCustomKeyStoresCommand.js +0 -1
- package/dist-es/commands/DescribeKeyCommand.js +0 -1
- package/dist-es/commands/DisableKeyCommand.js +0 -1
- package/dist-es/commands/DisableKeyRotationCommand.js +0 -1
- package/dist-es/commands/DisconnectCustomKeyStoreCommand.js +0 -1
- package/dist-es/commands/EnableKeyCommand.js +0 -1
- package/dist-es/commands/EnableKeyRotationCommand.js +0 -1
- package/dist-es/commands/EncryptCommand.js +0 -1
- package/dist-es/commands/GenerateDataKeyCommand.js +0 -1
- package/dist-es/commands/GenerateDataKeyPairCommand.js +0 -1
- package/dist-es/commands/GenerateDataKeyPairWithoutPlaintextCommand.js +0 -1
- package/dist-es/commands/GenerateDataKeyWithoutPlaintextCommand.js +0 -1
- package/dist-es/commands/GenerateRandomCommand.js +0 -1
- package/dist-es/commands/GetKeyPolicyCommand.js +0 -1
- package/dist-es/commands/GetKeyRotationStatusCommand.js +0 -1
- package/dist-es/commands/GetParametersForImportCommand.js +0 -1
- package/dist-es/commands/GetPublicKeyCommand.js +0 -1
- package/dist-es/commands/ImportKeyMaterialCommand.js +0 -1
- package/dist-es/commands/ListAliasesCommand.js +0 -1
- package/dist-es/commands/ListGrantsCommand.js +0 -1
- package/dist-es/commands/ListKeyPoliciesCommand.js +0 -1
- package/dist-es/commands/ListKeysCommand.js +0 -1
- package/dist-es/commands/ListResourceTagsCommand.js +0 -1
- package/dist-es/commands/ListRetirableGrantsCommand.js +0 -1
- package/dist-es/commands/PutKeyPolicyCommand.js +0 -1
- package/dist-es/commands/ReEncryptCommand.js +0 -1
- package/dist-es/commands/ReplicateKeyCommand.js +0 -1
- package/dist-es/commands/RetireGrantCommand.js +0 -1
- package/dist-es/commands/RevokeGrantCommand.js +0 -1
- package/dist-es/commands/ScheduleKeyDeletionCommand.js +0 -1
- package/dist-es/commands/SignCommand.js +0 -1
- package/dist-es/commands/TagResourceCommand.js +0 -1
- package/dist-es/commands/UntagResourceCommand.js +0 -1
- package/dist-es/commands/UpdateAliasCommand.js +0 -1
- package/dist-es/commands/UpdateCustomKeyStoreCommand.js +0 -1
- package/dist-es/commands/UpdateKeyDescriptionCommand.js +0 -1
- package/dist-es/commands/UpdatePrimaryRegionCommand.js +0 -1
- package/dist-es/commands/VerifyCommand.js +0 -1
- package/dist-es/endpoints.js +0 -1
- package/dist-es/index.js +0 -1
- package/dist-es/models/index.js +0 -1
- package/dist-es/models/models_0.js +0 -1
- package/dist-es/pagination/Interfaces.js +0 -1
- package/dist-es/pagination/ListAliasesPaginator.js +0 -1
- package/dist-es/pagination/ListGrantsPaginator.js +0 -1
- package/dist-es/pagination/ListKeyPoliciesPaginator.js +0 -1
- package/dist-es/pagination/ListKeysPaginator.js +0 -1
- package/dist-es/protocols/Aws_json1_1.js +0 -1
- package/dist-es/runtimeConfig.browser.js +1 -2
- package/dist-es/runtimeConfig.js +2 -3
- package/dist-es/runtimeConfig.native.js +0 -1
- package/dist-es/runtimeConfig.shared.js +0 -1
- package/dist-types/KMS.d.ts +396 -334
- package/dist-types/KMSClient.d.ts +8 -7
- package/dist-types/commands/CancelKeyDeletionCommand.d.ts +6 -4
- package/dist-types/commands/ConnectCustomKeyStoreCommand.d.ts +3 -3
- package/dist-types/commands/CreateAliasCommand.d.ts +11 -7
- package/dist-types/commands/CreateGrantCommand.d.ts +14 -11
- package/dist-types/commands/CreateKeyCommand.d.ts +16 -14
- package/dist-types/commands/DecryptCommand.d.ts +24 -21
- package/dist-types/commands/DeleteAliasCommand.d.ts +11 -7
- package/dist-types/commands/DeleteCustomKeyStoreCommand.d.ts +10 -11
- package/dist-types/commands/DeleteImportedKeyMaterialCommand.d.ts +5 -6
- package/dist-types/commands/DescribeCustomKeyStoresCommand.d.ts +4 -4
- package/dist-types/commands/DescribeKeyCommand.d.ts +12 -10
- package/dist-types/commands/DisableKeyCommand.d.ts +5 -4
- package/dist-types/commands/DisableKeyRotationCommand.d.ts +2 -1
- package/dist-types/commands/DisconnectCustomKeyStoreCommand.d.ts +6 -4
- package/dist-types/commands/EnableKeyCommand.d.ts +4 -2
- package/dist-types/commands/EnableKeyRotationCommand.d.ts +2 -1
- package/dist-types/commands/EncryptCommand.d.ts +14 -12
- package/dist-types/commands/GenerateDataKeyCommand.d.ts +15 -12
- package/dist-types/commands/GenerateDataKeyPairCommand.d.ts +15 -13
- package/dist-types/commands/GenerateDataKeyPairWithoutPlaintextCommand.d.ts +16 -13
- package/dist-types/commands/GenerateDataKeyWithoutPlaintextCommand.d.ts +11 -9
- package/dist-types/commands/GenerateRandomCommand.d.ts +2 -1
- package/dist-types/commands/GetKeyRotationStatusCommand.d.ts +2 -1
- package/dist-types/commands/GetParametersForImportCommand.d.ts +7 -8
- package/dist-types/commands/GetPublicKeyCommand.d.ts +7 -5
- package/dist-types/commands/ImportKeyMaterialCommand.d.ts +13 -13
- package/dist-types/commands/ListAliasesCommand.d.ts +13 -10
- package/dist-types/commands/ListGrantsCommand.d.ts +2 -2
- package/dist-types/commands/ListKeyPoliciesCommand.d.ts +3 -3
- package/dist-types/commands/ListKeysCommand.d.ts +1 -2
- package/dist-types/commands/ListRetirableGrantsCommand.d.ts +7 -6
- package/dist-types/commands/ReEncryptCommand.d.ts +33 -27
- package/dist-types/commands/ReplicateKeyCommand.d.ts +5 -5
- package/dist-types/commands/RetireGrantCommand.d.ts +7 -5
- package/dist-types/commands/RevokeGrantCommand.d.ts +1 -2
- package/dist-types/commands/ScheduleKeyDeletionCommand.d.ts +19 -15
- package/dist-types/commands/SignCommand.d.ts +10 -9
- package/dist-types/commands/TagResourceCommand.d.ts +6 -4
- package/dist-types/commands/UntagResourceCommand.d.ts +3 -3
- package/dist-types/commands/UpdateAliasCommand.d.ts +15 -11
- package/dist-types/commands/UpdateCustomKeyStoreCommand.d.ts +17 -17
- package/dist-types/commands/UpdateKeyDescriptionCommand.d.ts +3 -3
- package/dist-types/commands/UpdatePrimaryRegionCommand.d.ts +1 -1
- package/dist-types/commands/VerifyCommand.d.ts +5 -5
- package/dist-types/models/models_0.d.ts +296 -249
- package/dist-types/ts3.4/KMS.d.ts +396 -334
- package/dist-types/ts3.4/KMSClient.d.ts +8 -7
- package/dist-types/ts3.4/commands/CancelKeyDeletionCommand.d.ts +6 -4
- package/dist-types/ts3.4/commands/ConnectCustomKeyStoreCommand.d.ts +3 -3
- package/dist-types/ts3.4/commands/CreateAliasCommand.d.ts +11 -7
- package/dist-types/ts3.4/commands/CreateGrantCommand.d.ts +14 -11
- package/dist-types/ts3.4/commands/CreateKeyCommand.d.ts +16 -14
- package/dist-types/ts3.4/commands/DecryptCommand.d.ts +24 -21
- package/dist-types/ts3.4/commands/DeleteAliasCommand.d.ts +11 -7
- package/dist-types/ts3.4/commands/DeleteCustomKeyStoreCommand.d.ts +10 -11
- package/dist-types/ts3.4/commands/DeleteImportedKeyMaterialCommand.d.ts +5 -6
- package/dist-types/ts3.4/commands/DescribeCustomKeyStoresCommand.d.ts +4 -4
- package/dist-types/ts3.4/commands/DescribeKeyCommand.d.ts +12 -10
- package/dist-types/ts3.4/commands/DisableKeyCommand.d.ts +5 -4
- package/dist-types/ts3.4/commands/DisableKeyRotationCommand.d.ts +2 -1
- package/dist-types/ts3.4/commands/DisconnectCustomKeyStoreCommand.d.ts +6 -4
- package/dist-types/ts3.4/commands/EnableKeyCommand.d.ts +4 -2
- package/dist-types/ts3.4/commands/EnableKeyRotationCommand.d.ts +2 -1
- package/dist-types/ts3.4/commands/EncryptCommand.d.ts +14 -12
- package/dist-types/ts3.4/commands/GenerateDataKeyCommand.d.ts +15 -12
- package/dist-types/ts3.4/commands/GenerateDataKeyPairCommand.d.ts +15 -13
- package/dist-types/ts3.4/commands/GenerateDataKeyPairWithoutPlaintextCommand.d.ts +16 -13
- package/dist-types/ts3.4/commands/GenerateDataKeyWithoutPlaintextCommand.d.ts +11 -9
- package/dist-types/ts3.4/commands/GenerateRandomCommand.d.ts +2 -1
- package/dist-types/ts3.4/commands/GetKeyRotationStatusCommand.d.ts +2 -1
- package/dist-types/ts3.4/commands/GetParametersForImportCommand.d.ts +7 -8
- package/dist-types/ts3.4/commands/GetPublicKeyCommand.d.ts +7 -5
- package/dist-types/ts3.4/commands/ImportKeyMaterialCommand.d.ts +13 -13
- package/dist-types/ts3.4/commands/ListAliasesCommand.d.ts +13 -10
- package/dist-types/ts3.4/commands/ListGrantsCommand.d.ts +2 -2
- package/dist-types/ts3.4/commands/ListKeyPoliciesCommand.d.ts +3 -3
- package/dist-types/ts3.4/commands/ListKeysCommand.d.ts +1 -2
- package/dist-types/ts3.4/commands/ListRetirableGrantsCommand.d.ts +7 -6
- package/dist-types/ts3.4/commands/ReEncryptCommand.d.ts +33 -27
- package/dist-types/ts3.4/commands/ReplicateKeyCommand.d.ts +5 -5
- package/dist-types/ts3.4/commands/RetireGrantCommand.d.ts +7 -5
- package/dist-types/ts3.4/commands/RevokeGrantCommand.d.ts +1 -2
- package/dist-types/ts3.4/commands/ScheduleKeyDeletionCommand.d.ts +19 -15
- package/dist-types/ts3.4/commands/SignCommand.d.ts +10 -9
- package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +6 -4
- package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +3 -3
- package/dist-types/ts3.4/commands/UpdateAliasCommand.d.ts +15 -11
- package/dist-types/ts3.4/commands/UpdateCustomKeyStoreCommand.d.ts +17 -17
- package/dist-types/ts3.4/commands/UpdateKeyDescriptionCommand.d.ts +3 -3
- package/dist-types/ts3.4/commands/UpdatePrimaryRegionCommand.d.ts +1 -1
- package/dist-types/ts3.4/commands/VerifyCommand.d.ts +5 -5
- package/dist-types/ts3.4/models/models_0.d.ts +296 -249
- package/package.json +33 -30
- package/dist-cjs/KMS.js.map +0 -1
- package/dist-cjs/KMSClient.js.map +0 -1
- package/dist-cjs/commands/CancelKeyDeletionCommand.js.map +0 -1
- package/dist-cjs/commands/ConnectCustomKeyStoreCommand.js.map +0 -1
- package/dist-cjs/commands/CreateAliasCommand.js.map +0 -1
- package/dist-cjs/commands/CreateCustomKeyStoreCommand.js.map +0 -1
- package/dist-cjs/commands/CreateGrantCommand.js.map +0 -1
- package/dist-cjs/commands/CreateKeyCommand.js.map +0 -1
- package/dist-cjs/commands/DecryptCommand.js.map +0 -1
- package/dist-cjs/commands/DeleteAliasCommand.js.map +0 -1
- package/dist-cjs/commands/DeleteCustomKeyStoreCommand.js.map +0 -1
- package/dist-cjs/commands/DeleteImportedKeyMaterialCommand.js.map +0 -1
- package/dist-cjs/commands/DescribeCustomKeyStoresCommand.js.map +0 -1
- package/dist-cjs/commands/DescribeKeyCommand.js.map +0 -1
- package/dist-cjs/commands/DisableKeyCommand.js.map +0 -1
- package/dist-cjs/commands/DisableKeyRotationCommand.js.map +0 -1
- package/dist-cjs/commands/DisconnectCustomKeyStoreCommand.js.map +0 -1
- package/dist-cjs/commands/EnableKeyCommand.js.map +0 -1
- package/dist-cjs/commands/EnableKeyRotationCommand.js.map +0 -1
- package/dist-cjs/commands/EncryptCommand.js.map +0 -1
- package/dist-cjs/commands/GenerateDataKeyCommand.js.map +0 -1
- package/dist-cjs/commands/GenerateDataKeyPairCommand.js.map +0 -1
- package/dist-cjs/commands/GenerateDataKeyPairWithoutPlaintextCommand.js.map +0 -1
- package/dist-cjs/commands/GenerateDataKeyWithoutPlaintextCommand.js.map +0 -1
- package/dist-cjs/commands/GenerateRandomCommand.js.map +0 -1
- package/dist-cjs/commands/GetKeyPolicyCommand.js.map +0 -1
- package/dist-cjs/commands/GetKeyRotationStatusCommand.js.map +0 -1
- package/dist-cjs/commands/GetParametersForImportCommand.js.map +0 -1
- package/dist-cjs/commands/GetPublicKeyCommand.js.map +0 -1
- package/dist-cjs/commands/ImportKeyMaterialCommand.js.map +0 -1
- package/dist-cjs/commands/ListAliasesCommand.js.map +0 -1
- package/dist-cjs/commands/ListGrantsCommand.js.map +0 -1
- package/dist-cjs/commands/ListKeyPoliciesCommand.js.map +0 -1
- package/dist-cjs/commands/ListKeysCommand.js.map +0 -1
- package/dist-cjs/commands/ListResourceTagsCommand.js.map +0 -1
- package/dist-cjs/commands/ListRetirableGrantsCommand.js.map +0 -1
- package/dist-cjs/commands/PutKeyPolicyCommand.js.map +0 -1
- package/dist-cjs/commands/ReEncryptCommand.js.map +0 -1
- package/dist-cjs/commands/ReplicateKeyCommand.js.map +0 -1
- package/dist-cjs/commands/RetireGrantCommand.js.map +0 -1
- package/dist-cjs/commands/RevokeGrantCommand.js.map +0 -1
- package/dist-cjs/commands/ScheduleKeyDeletionCommand.js.map +0 -1
- package/dist-cjs/commands/SignCommand.js.map +0 -1
- package/dist-cjs/commands/TagResourceCommand.js.map +0 -1
- package/dist-cjs/commands/UntagResourceCommand.js.map +0 -1
- package/dist-cjs/commands/UpdateAliasCommand.js.map +0 -1
- package/dist-cjs/commands/UpdateCustomKeyStoreCommand.js.map +0 -1
- package/dist-cjs/commands/UpdateKeyDescriptionCommand.js.map +0 -1
- package/dist-cjs/commands/UpdatePrimaryRegionCommand.js.map +0 -1
- package/dist-cjs/commands/VerifyCommand.js.map +0 -1
- package/dist-cjs/endpoints.js.map +0 -1
- package/dist-cjs/index.js.map +0 -1
- package/dist-cjs/models/index.js.map +0 -1
- package/dist-cjs/models/models_0.js.map +0 -1
- package/dist-cjs/pagination/Interfaces.js.map +0 -1
- package/dist-cjs/pagination/ListAliasesPaginator.js.map +0 -1
- package/dist-cjs/pagination/ListGrantsPaginator.js.map +0 -1
- package/dist-cjs/pagination/ListKeyPoliciesPaginator.js.map +0 -1
- package/dist-cjs/pagination/ListKeysPaginator.js.map +0 -1
- package/dist-cjs/protocols/Aws_json1_1.js.map +0 -1
- package/dist-cjs/runtimeConfig.browser.js.map +0 -1
- package/dist-cjs/runtimeConfig.js.map +0 -1
- package/dist-cjs/runtimeConfig.native.js.map +0 -1
- package/dist-cjs/runtimeConfig.shared.js.map +0 -1
- package/dist-es/KMS.js.map +0 -1
- package/dist-es/KMSClient.js.map +0 -1
- package/dist-es/commands/CancelKeyDeletionCommand.js.map +0 -1
- package/dist-es/commands/ConnectCustomKeyStoreCommand.js.map +0 -1
- package/dist-es/commands/CreateAliasCommand.js.map +0 -1
- package/dist-es/commands/CreateCustomKeyStoreCommand.js.map +0 -1
- package/dist-es/commands/CreateGrantCommand.js.map +0 -1
- package/dist-es/commands/CreateKeyCommand.js.map +0 -1
- package/dist-es/commands/DecryptCommand.js.map +0 -1
- package/dist-es/commands/DeleteAliasCommand.js.map +0 -1
- package/dist-es/commands/DeleteCustomKeyStoreCommand.js.map +0 -1
- package/dist-es/commands/DeleteImportedKeyMaterialCommand.js.map +0 -1
- package/dist-es/commands/DescribeCustomKeyStoresCommand.js.map +0 -1
- package/dist-es/commands/DescribeKeyCommand.js.map +0 -1
- package/dist-es/commands/DisableKeyCommand.js.map +0 -1
- package/dist-es/commands/DisableKeyRotationCommand.js.map +0 -1
- package/dist-es/commands/DisconnectCustomKeyStoreCommand.js.map +0 -1
- package/dist-es/commands/EnableKeyCommand.js.map +0 -1
- package/dist-es/commands/EnableKeyRotationCommand.js.map +0 -1
- package/dist-es/commands/EncryptCommand.js.map +0 -1
- package/dist-es/commands/GenerateDataKeyCommand.js.map +0 -1
- package/dist-es/commands/GenerateDataKeyPairCommand.js.map +0 -1
- package/dist-es/commands/GenerateDataKeyPairWithoutPlaintextCommand.js.map +0 -1
- package/dist-es/commands/GenerateDataKeyWithoutPlaintextCommand.js.map +0 -1
- package/dist-es/commands/GenerateRandomCommand.js.map +0 -1
- package/dist-es/commands/GetKeyPolicyCommand.js.map +0 -1
- package/dist-es/commands/GetKeyRotationStatusCommand.js.map +0 -1
- package/dist-es/commands/GetParametersForImportCommand.js.map +0 -1
- package/dist-es/commands/GetPublicKeyCommand.js.map +0 -1
- package/dist-es/commands/ImportKeyMaterialCommand.js.map +0 -1
- package/dist-es/commands/ListAliasesCommand.js.map +0 -1
- package/dist-es/commands/ListGrantsCommand.js.map +0 -1
- package/dist-es/commands/ListKeyPoliciesCommand.js.map +0 -1
- package/dist-es/commands/ListKeysCommand.js.map +0 -1
- package/dist-es/commands/ListResourceTagsCommand.js.map +0 -1
- package/dist-es/commands/ListRetirableGrantsCommand.js.map +0 -1
- package/dist-es/commands/PutKeyPolicyCommand.js.map +0 -1
- package/dist-es/commands/ReEncryptCommand.js.map +0 -1
- package/dist-es/commands/ReplicateKeyCommand.js.map +0 -1
- package/dist-es/commands/RetireGrantCommand.js.map +0 -1
- package/dist-es/commands/RevokeGrantCommand.js.map +0 -1
- package/dist-es/commands/ScheduleKeyDeletionCommand.js.map +0 -1
- package/dist-es/commands/SignCommand.js.map +0 -1
- package/dist-es/commands/TagResourceCommand.js.map +0 -1
- package/dist-es/commands/UntagResourceCommand.js.map +0 -1
- package/dist-es/commands/UpdateAliasCommand.js.map +0 -1
- package/dist-es/commands/UpdateCustomKeyStoreCommand.js.map +0 -1
- package/dist-es/commands/UpdateKeyDescriptionCommand.js.map +0 -1
- package/dist-es/commands/UpdatePrimaryRegionCommand.js.map +0 -1
- package/dist-es/commands/VerifyCommand.js.map +0 -1
- package/dist-es/endpoints.js.map +0 -1
- package/dist-es/index.js.map +0 -1
- package/dist-es/models/index.js.map +0 -1
- package/dist-es/models/models_0.js.map +0 -1
- package/dist-es/pagination/Interfaces.js.map +0 -1
- package/dist-es/pagination/ListAliasesPaginator.js.map +0 -1
- package/dist-es/pagination/ListGrantsPaginator.js.map +0 -1
- package/dist-es/pagination/ListKeyPoliciesPaginator.js.map +0 -1
- package/dist-es/pagination/ListKeysPaginator.js.map +0 -1
- package/dist-es/protocols/Aws_json1_1.js.map +0 -1
- package/dist-es/runtimeConfig.browser.js.map +0 -1
- package/dist-es/runtimeConfig.js.map +0 -1
- package/dist-es/runtimeConfig.native.js.map +0 -1
- package/dist-es/runtimeConfig.shared.js.map +0 -1
- package/jest.config.js +0 -4
- package/src/KMS.ts +0 -4019
- package/src/KMSClient.ts +0 -516
- package/src/commands/CancelKeyDeletionCommand.ts +0 -106
- package/src/commands/ConnectCustomKeyStoreCommand.ts +0 -156
- package/src/commands/CreateAliasCommand.ts +0 -148
- package/src/commands/CreateCustomKeyStoreCommand.ts +0 -144
- package/src/commands/CreateGrantCommand.ts +0 -154
- package/src/commands/CreateKeyCommand.ts +0 -210
- package/src/commands/DecryptCommand.ts +0 -173
- package/src/commands/DeleteAliasCommand.ts +0 -138
- package/src/commands/DeleteCustomKeyStoreCommand.ts +0 -150
- package/src/commands/DeleteImportedKeyMaterialCommand.ts +0 -128
- package/src/commands/DescribeCustomKeyStoresCommand.ts +0 -148
- package/src/commands/DescribeKeyCommand.ts +0 -172
- package/src/commands/DisableKeyCommand.ts +0 -109
- package/src/commands/DisableKeyRotationCommand.ts +0 -119
- package/src/commands/DisconnectCustomKeyStoreCommand.ts +0 -145
- package/src/commands/EnableKeyCommand.ts +0 -98
- package/src/commands/EnableKeyRotationCommand.ts +0 -119
- package/src/commands/EncryptCommand.ts +0 -210
- package/src/commands/GenerateDataKeyCommand.ts +0 -189
- package/src/commands/GenerateDataKeyPairCommand.ts +0 -169
- package/src/commands/GenerateDataKeyPairWithoutPlaintextCommand.ts +0 -169
- package/src/commands/GenerateDataKeyWithoutPlaintextCommand.ts +0 -172
- package/src/commands/GenerateRandomCommand.ts +0 -103
- package/src/commands/GetKeyPolicyCommand.ts +0 -103
- package/src/commands/GetKeyRotationStatusCommand.ts +0 -131
- package/src/commands/GetParametersForImportCommand.ts +0 -130
- package/src/commands/GetPublicKeyCommand.ts +0 -139
- package/src/commands/ImportKeyMaterialCommand.ts +0 -158
- package/src/commands/ListAliasesCommand.ts +0 -134
- package/src/commands/ListGrantsCommand.ts +0 -140
- package/src/commands/ListKeyPoliciesCommand.ts +0 -117
- package/src/commands/ListKeysCommand.ts +0 -119
- package/src/commands/ListResourceTagsCommand.ts +0 -129
- package/src/commands/ListRetirableGrantsCommand.ts +0 -137
- package/src/commands/PutKeyPolicyCommand.ts +0 -108
- package/src/commands/ReEncryptCommand.ts +0 -180
- package/src/commands/ReplicateKeyCommand.ts +0 -172
- package/src/commands/RetireGrantCommand.ts +0 -139
- package/src/commands/RevokeGrantCommand.ts +0 -139
- package/src/commands/ScheduleKeyDeletionCommand.ts +0 -145
- package/src/commands/SignCommand.ts +0 -132
- package/src/commands/TagResourceCommand.ts +0 -140
- package/src/commands/UntagResourceCommand.ts +0 -138
- package/src/commands/UpdateAliasCommand.ts +0 -153
- package/src/commands/UpdateCustomKeyStoreCommand.ts +0 -167
- package/src/commands/UpdateKeyDescriptionCommand.ts +0 -118
- package/src/commands/UpdatePrimaryRegionCommand.ts +0 -160
- package/src/commands/VerifyCommand.ts +0 -118
- package/src/endpoints.ts +0 -62
- package/src/index.ts +0 -56
- package/src/models/index.ts +0 -1
- package/src/models/models_0.ts +0 -4742
- package/src/pagination/Interfaces.ts +0 -8
- package/src/pagination/ListAliasesPaginator.ts +0 -55
- package/src/pagination/ListGrantsPaginator.ts +0 -55
- package/src/pagination/ListKeyPoliciesPaginator.ts +0 -59
- package/src/pagination/ListKeysPaginator.ts +0 -55
- package/src/protocols/Aws_json1_1.ts +0 -7632
- package/src/runtimeConfig.browser.ts +0 -41
- package/src/runtimeConfig.native.ts +0 -17
- package/src/runtimeConfig.shared.ts +0 -17
- package/src/runtimeConfig.ts +0 -46
- package/tsconfig.es.json +0 -10
- package/tsconfig.json +0 -33
- package/tsconfig.types.json +0 -9
|
@@ -1,210 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { KMSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KMSClient";
|
|
15
|
-
import { CreateKeyRequest, CreateKeyResponse } from "../models/models_0";
|
|
16
|
-
import { deserializeAws_json1_1CreateKeyCommand, serializeAws_json1_1CreateKeyCommand } from "../protocols/Aws_json1_1";
|
|
17
|
-
|
|
18
|
-
export interface CreateKeyCommandInput extends CreateKeyRequest {}
|
|
19
|
-
export interface CreateKeyCommandOutput extends CreateKeyResponse, __MetadataBearer {}
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* <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 Region.</p>
|
|
23
|
-
* <note>
|
|
24
|
-
* <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>
|
|
25
|
-
* </note>
|
|
26
|
-
*
|
|
27
|
-
* <p>You can use the <code>CreateKey</code> operation to create symmetric or asymmetric KMS keys.</p>
|
|
28
|
-
* <ul>
|
|
29
|
-
* <li>
|
|
30
|
-
* <p>
|
|
31
|
-
* <b>Symmetric KMS keys</b> contain a 256-bit symmetric key that
|
|
32
|
-
* never leaves KMS unencrypted. To use the KMS key, you must call KMS. You can use a
|
|
33
|
-
* symmetric KMS key to encrypt and decrypt small amounts of data, but they are typically used to
|
|
34
|
-
* generate <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#data-keys">data
|
|
35
|
-
* keys</a> and <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#data-key-pairs">data keys pairs</a>. For details,
|
|
36
|
-
* see <a>GenerateDataKey</a> and <a>GenerateDataKeyPair</a>.</p>
|
|
37
|
-
* </li>
|
|
38
|
-
* <li>
|
|
39
|
-
* <p>
|
|
40
|
-
* <b>Asymmetric KMS keys</b> can contain an RSA key pair or an
|
|
41
|
-
* Elliptic Curve (ECC) key pair. The private key in an asymmetric KMS key never leaves KMS
|
|
42
|
-
* unencrypted. However, you can use the <a>GetPublicKey</a> operation to download
|
|
43
|
-
* the public key so it can be used outside of KMS. KMS keys with RSA key pairs can be used to
|
|
44
|
-
* encrypt or decrypt data or sign and verify messages (but not both). KMS keys with ECC key
|
|
45
|
-
* pairs can be used only to sign and verify messages.</p>
|
|
46
|
-
* </li>
|
|
47
|
-
* </ul>
|
|
48
|
-
* <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>
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
* <p>To create different types of KMS keys, use the following guidance:</p>
|
|
52
|
-
*
|
|
53
|
-
* <dl>
|
|
54
|
-
* <dt>Asymmetric KMS keys</dt>
|
|
55
|
-
* <dd>
|
|
56
|
-
* <p>To create an asymmetric KMS key, use the <code>KeySpec</code> parameter to specify
|
|
57
|
-
* the type of key material in the KMS key. Then, use the <code>KeyUsage</code> parameter
|
|
58
|
-
* to determine whether the KMS key will be used to encrypt and decrypt or sign and verify.
|
|
59
|
-
* You can't change these properties after the KMS key is created.</p>
|
|
60
|
-
* <p> </p>
|
|
61
|
-
* </dd>
|
|
62
|
-
* <dt>Symmetric KMS keys</dt>
|
|
63
|
-
* <dd>
|
|
64
|
-
* <p>When creating a symmetric KMS key, you don't need to specify the
|
|
65
|
-
* <code>KeySpec</code> or <code>KeyUsage</code> parameters. The default value for
|
|
66
|
-
* <code>KeySpec</code>, <code>SYMMETRIC_DEFAULT</code>, and the default value for
|
|
67
|
-
* <code>KeyUsage</code>, <code>ENCRYPT_DECRYPT</code>, are the only valid values for
|
|
68
|
-
* symmetric KMS keys. </p>
|
|
69
|
-
* <p> </p>
|
|
70
|
-
* </dd>
|
|
71
|
-
* <dt>Multi-Region primary keys</dt>
|
|
72
|
-
* <dt>Imported key material</dt>
|
|
73
|
-
* <dd>
|
|
74
|
-
* <p>To create a multi-Region <i>primary key</i> in the local Amazon Web Services Region,
|
|
75
|
-
* use the <code>MultiRegion</code> parameter with a value of <code>True</code>. To create
|
|
76
|
-
* a multi-Region <i>replica key</i>, that is, a KMS key with the same key ID and
|
|
77
|
-
* 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
|
|
78
|
-
* primary key to a replica key, use the <a>UpdatePrimaryRegion</a>
|
|
79
|
-
* operation.</p>
|
|
80
|
-
* <p>This operation supports <i>multi-Region keys</i>, an KMS feature that lets you create multiple
|
|
81
|
-
* interoperable KMS keys in different Amazon Web Services Regions. Because these KMS keys have the same key ID, key
|
|
82
|
-
* material, and other metadata, you can use them interchangeably to encrypt data in one Amazon Web Services Region and decrypt
|
|
83
|
-
* 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">Using multi-Region keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
84
|
-
* <p>You can create symmetric and asymmetric multi-Region keys and multi-Region keys with
|
|
85
|
-
* imported key material. You cannot create multi-Region keys in a custom key store.</p>
|
|
86
|
-
* <p> </p>
|
|
87
|
-
* </dd>
|
|
88
|
-
* <dd>
|
|
89
|
-
* <p>To import your own key material, begin by creating a symmetric KMS key with no key
|
|
90
|
-
* material. To do this, use the <code>Origin</code> parameter of <code>CreateKey</code>
|
|
91
|
-
* 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
|
|
92
|
-
* your key material. Then, use <a>ImportKeyMaterial</a> with your import token
|
|
93
|
-
* 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>
|
|
94
|
-
* <i>Key Management Service Developer Guide</i>
|
|
95
|
-
* </i>. You
|
|
96
|
-
* cannot import the key material into an asymmetric KMS key.</p>
|
|
97
|
-
* <p>To create a multi-Region primary key with imported key material, use the
|
|
98
|
-
* <code>Origin</code> parameter of <code>CreateKey</code> with a value of
|
|
99
|
-
* <code>EXTERNAL</code> and the <code>MultiRegion</code> parameter with a value of
|
|
100
|
-
* <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">Using multi-Region keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
101
|
-
* <p> </p>
|
|
102
|
-
* </dd>
|
|
103
|
-
* <dt>Custom key store</dt>
|
|
104
|
-
* <dd>
|
|
105
|
-
* <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
|
|
106
|
-
* <code>CustomKeyStoreId</code> parameter to specify the custom key store. You must also
|
|
107
|
-
* use the <code>Origin</code> parameter with a value of <code>AWS_CLOUDHSM</code>. The
|
|
108
|
-
* CloudHSM cluster that is associated with the custom key store must have at least two active
|
|
109
|
-
* HSMs in different Availability Zones in the Amazon Web Services Region. </p>
|
|
110
|
-
* <p>You cannot create an asymmetric KMS key in a custom key store. For information about
|
|
111
|
-
* custom key stores in KMS see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/custom-key-store-overview.html">Using Custom Key Stores</a> in
|
|
112
|
-
* the <i>
|
|
113
|
-
* <i>Key Management Service Developer Guide</i>
|
|
114
|
-
* </i>.</p>
|
|
115
|
-
* </dd>
|
|
116
|
-
* </dl>
|
|
117
|
-
* <p>
|
|
118
|
-
* <b>Cross-account use</b>: No. You cannot use this operation to
|
|
119
|
-
* create a KMS key in a different Amazon Web Services account.</p>
|
|
120
|
-
*
|
|
121
|
-
* <p>
|
|
122
|
-
* <b>Required permissions</b>: <a href="https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html">kms:CreateKey</a> (IAM policy). To use the
|
|
123
|
-
* <code>Tags</code> parameter, <a href="https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html">kms:TagResource</a> (IAM policy). For examples and information about related
|
|
124
|
-
* permissions, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/iam-policies.html#iam-policy-example-create-key">Allow a user to create KMS keys</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
125
|
-
* <p>
|
|
126
|
-
* <b>Related operations:</b>
|
|
127
|
-
* </p>
|
|
128
|
-
* <ul>
|
|
129
|
-
* <li>
|
|
130
|
-
* <p>
|
|
131
|
-
* <a>DescribeKey</a>
|
|
132
|
-
* </p>
|
|
133
|
-
* </li>
|
|
134
|
-
* <li>
|
|
135
|
-
* <p>
|
|
136
|
-
* <a>ListKeys</a>
|
|
137
|
-
* </p>
|
|
138
|
-
* </li>
|
|
139
|
-
* <li>
|
|
140
|
-
* <p>
|
|
141
|
-
* <a>ScheduleKeyDeletion</a>
|
|
142
|
-
* </p>
|
|
143
|
-
* </li>
|
|
144
|
-
* </ul>
|
|
145
|
-
* @example
|
|
146
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
147
|
-
* ```javascript
|
|
148
|
-
* import { KMSClient, CreateKeyCommand } from "@aws-sdk/client-kms"; // ES Modules import
|
|
149
|
-
* // const { KMSClient, CreateKeyCommand } = require("@aws-sdk/client-kms"); // CommonJS import
|
|
150
|
-
* const client = new KMSClient(config);
|
|
151
|
-
* const command = new CreateKeyCommand(input);
|
|
152
|
-
* const response = await client.send(command);
|
|
153
|
-
* ```
|
|
154
|
-
*
|
|
155
|
-
* @see {@link CreateKeyCommandInput} for command's `input` shape.
|
|
156
|
-
* @see {@link CreateKeyCommandOutput} for command's `response` shape.
|
|
157
|
-
* @see {@link KMSClientResolvedConfig | config} for command's `input` shape.
|
|
158
|
-
*
|
|
159
|
-
*/
|
|
160
|
-
export class CreateKeyCommand extends $Command<CreateKeyCommandInput, CreateKeyCommandOutput, KMSClientResolvedConfig> {
|
|
161
|
-
// Start section: command_properties
|
|
162
|
-
// End section: command_properties
|
|
163
|
-
|
|
164
|
-
constructor(readonly input: CreateKeyCommandInput) {
|
|
165
|
-
// Start section: command_constructor
|
|
166
|
-
super();
|
|
167
|
-
// End section: command_constructor
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
/**
|
|
171
|
-
* @internal
|
|
172
|
-
*/
|
|
173
|
-
resolveMiddleware(
|
|
174
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
175
|
-
configuration: KMSClientResolvedConfig,
|
|
176
|
-
options?: __HttpHandlerOptions
|
|
177
|
-
): Handler<CreateKeyCommandInput, CreateKeyCommandOutput> {
|
|
178
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
179
|
-
|
|
180
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
181
|
-
|
|
182
|
-
const { logger } = configuration;
|
|
183
|
-
const clientName = "KMSClient";
|
|
184
|
-
const commandName = "CreateKeyCommand";
|
|
185
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
186
|
-
logger,
|
|
187
|
-
clientName,
|
|
188
|
-
commandName,
|
|
189
|
-
inputFilterSensitiveLog: CreateKeyRequest.filterSensitiveLog,
|
|
190
|
-
outputFilterSensitiveLog: CreateKeyResponse.filterSensitiveLog,
|
|
191
|
-
};
|
|
192
|
-
const { requestHandler } = configuration;
|
|
193
|
-
return stack.resolve(
|
|
194
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
195
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
196
|
-
handlerExecutionContext
|
|
197
|
-
);
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
private serialize(input: CreateKeyCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
201
|
-
return serializeAws_json1_1CreateKeyCommand(input, context);
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<CreateKeyCommandOutput> {
|
|
205
|
-
return deserializeAws_json1_1CreateKeyCommand(output, context);
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
// Start section: command_body_extra
|
|
209
|
-
// End section: command_body_extra
|
|
210
|
-
}
|
|
@@ -1,173 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { KMSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KMSClient";
|
|
15
|
-
import { DecryptRequest, DecryptResponse } from "../models/models_0";
|
|
16
|
-
import { deserializeAws_json1_1DecryptCommand, serializeAws_json1_1DecryptCommand } from "../protocols/Aws_json1_1";
|
|
17
|
-
|
|
18
|
-
export interface DecryptCommandInput extends DecryptRequest {}
|
|
19
|
-
export interface DecryptCommandOutput extends DecryptResponse, __MetadataBearer {}
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* <p>Decrypts ciphertext that was encrypted by a KMS key using any of
|
|
23
|
-
* the following operations:</p>
|
|
24
|
-
* <ul>
|
|
25
|
-
* <li>
|
|
26
|
-
* <p>
|
|
27
|
-
* <a>Encrypt</a>
|
|
28
|
-
* </p>
|
|
29
|
-
* </li>
|
|
30
|
-
* <li>
|
|
31
|
-
* <p>
|
|
32
|
-
* <a>GenerateDataKey</a>
|
|
33
|
-
* </p>
|
|
34
|
-
* </li>
|
|
35
|
-
* <li>
|
|
36
|
-
* <p>
|
|
37
|
-
* <a>GenerateDataKeyPair</a>
|
|
38
|
-
* </p>
|
|
39
|
-
* </li>
|
|
40
|
-
* <li>
|
|
41
|
-
* <p>
|
|
42
|
-
* <a>GenerateDataKeyWithoutPlaintext</a>
|
|
43
|
-
* </p>
|
|
44
|
-
* </li>
|
|
45
|
-
* <li>
|
|
46
|
-
* <p>
|
|
47
|
-
* <a>GenerateDataKeyPairWithoutPlaintext</a>
|
|
48
|
-
* </p>
|
|
49
|
-
* </li>
|
|
50
|
-
* </ul>
|
|
51
|
-
* <p>You can use this operation to decrypt ciphertext that was encrypted under a symmetric or
|
|
52
|
-
* asymmetric KMS key. When the KMS key is asymmetric, you must specify the KMS key and the encryption
|
|
53
|
-
* algorithm that was used to encrypt the ciphertext. 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>
|
|
54
|
-
* <p>The Decrypt operation also decrypts ciphertext that was encrypted outside of KMS by the
|
|
55
|
-
* public key in an KMS asymmetric KMS key. However, it cannot decrypt ciphertext produced by other
|
|
56
|
-
* libraries, such as the <a href="https://docs.aws.amazon.com/encryption-sdk/latest/developer-guide/">Amazon Web Services Encryption
|
|
57
|
-
* SDK</a> or <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingClientSideEncryption.html">Amazon S3 client-side encryption</a>. These libraries return a ciphertext format that
|
|
58
|
-
* is incompatible with KMS.</p>
|
|
59
|
-
* <p>If the ciphertext was encrypted under a symmetric KMS key, the <code>KeyId</code> parameter is
|
|
60
|
-
* optional. KMS can get this information from metadata that it adds to the symmetric
|
|
61
|
-
* ciphertext blob. This feature adds durability to your implementation by ensuring that
|
|
62
|
-
* authorized users can decrypt ciphertext decades after it was encrypted, even if they've lost
|
|
63
|
-
* track of the key ID. However, specifying the KMS key is always recommended as a best practice.
|
|
64
|
-
* When you use the <code>KeyId</code> parameter to specify a KMS key, KMS only uses the KMS key you
|
|
65
|
-
* specify. If the ciphertext was encrypted under a different KMS key, the <code>Decrypt</code>
|
|
66
|
-
* operation fails. This practice ensures that you use the KMS key that you intend.</p>
|
|
67
|
-
* <p>Whenever possible, use key policies to give users permission to call the
|
|
68
|
-
* <code>Decrypt</code> operation on a particular KMS key, instead of using IAM policies.
|
|
69
|
-
* Otherwise, you might create an IAM user policy that gives the user <code>Decrypt</code>
|
|
70
|
-
* permission on all KMS keys. This user could decrypt ciphertext that was encrypted by KMS keys in other
|
|
71
|
-
* accounts if the key policy for the cross-account KMS key permits it. If you must use an IAM policy
|
|
72
|
-
* for <code>Decrypt</code> permissions, limit the user to particular KMS keys or particular trusted
|
|
73
|
-
* accounts. For details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/iam-policies.html#iam-policies-best-practices">Best practices for IAM policies</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
74
|
-
* <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>
|
|
75
|
-
* <p>The KMS key that you use for this operation must be in a compatible key state. For
|
|
76
|
-
* details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-state.html">Key state: Effect on your KMS key</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
77
|
-
* <p>
|
|
78
|
-
* <b>Cross-account use</b>: Yes. To perform this operation with a KMS key in a different Amazon Web Services account, specify
|
|
79
|
-
* the key ARN or alias ARN in the value of the <code>KeyId</code> parameter. </p>
|
|
80
|
-
*
|
|
81
|
-
* <p>
|
|
82
|
-
* <b>Required permissions</b>: <a href="https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html">kms:Decrypt</a> (key policy)</p>
|
|
83
|
-
* <p>
|
|
84
|
-
* <b>Related operations:</b>
|
|
85
|
-
* </p>
|
|
86
|
-
* <ul>
|
|
87
|
-
* <li>
|
|
88
|
-
* <p>
|
|
89
|
-
* <a>Encrypt</a>
|
|
90
|
-
* </p>
|
|
91
|
-
* </li>
|
|
92
|
-
* <li>
|
|
93
|
-
* <p>
|
|
94
|
-
* <a>GenerateDataKey</a>
|
|
95
|
-
* </p>
|
|
96
|
-
* </li>
|
|
97
|
-
* <li>
|
|
98
|
-
* <p>
|
|
99
|
-
* <a>GenerateDataKeyPair</a>
|
|
100
|
-
* </p>
|
|
101
|
-
* </li>
|
|
102
|
-
* <li>
|
|
103
|
-
* <p>
|
|
104
|
-
* <a>ReEncrypt</a>
|
|
105
|
-
* </p>
|
|
106
|
-
* </li>
|
|
107
|
-
* </ul>
|
|
108
|
-
* @example
|
|
109
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
110
|
-
* ```javascript
|
|
111
|
-
* import { KMSClient, DecryptCommand } from "@aws-sdk/client-kms"; // ES Modules import
|
|
112
|
-
* // const { KMSClient, DecryptCommand } = require("@aws-sdk/client-kms"); // CommonJS import
|
|
113
|
-
* const client = new KMSClient(config);
|
|
114
|
-
* const command = new DecryptCommand(input);
|
|
115
|
-
* const response = await client.send(command);
|
|
116
|
-
* ```
|
|
117
|
-
*
|
|
118
|
-
* @see {@link DecryptCommandInput} for command's `input` shape.
|
|
119
|
-
* @see {@link DecryptCommandOutput} for command's `response` shape.
|
|
120
|
-
* @see {@link KMSClientResolvedConfig | config} for command's `input` shape.
|
|
121
|
-
*
|
|
122
|
-
*/
|
|
123
|
-
export class DecryptCommand extends $Command<DecryptCommandInput, DecryptCommandOutput, KMSClientResolvedConfig> {
|
|
124
|
-
// Start section: command_properties
|
|
125
|
-
// End section: command_properties
|
|
126
|
-
|
|
127
|
-
constructor(readonly input: DecryptCommandInput) {
|
|
128
|
-
// Start section: command_constructor
|
|
129
|
-
super();
|
|
130
|
-
// End section: command_constructor
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
/**
|
|
134
|
-
* @internal
|
|
135
|
-
*/
|
|
136
|
-
resolveMiddleware(
|
|
137
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
138
|
-
configuration: KMSClientResolvedConfig,
|
|
139
|
-
options?: __HttpHandlerOptions
|
|
140
|
-
): Handler<DecryptCommandInput, DecryptCommandOutput> {
|
|
141
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
142
|
-
|
|
143
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
144
|
-
|
|
145
|
-
const { logger } = configuration;
|
|
146
|
-
const clientName = "KMSClient";
|
|
147
|
-
const commandName = "DecryptCommand";
|
|
148
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
149
|
-
logger,
|
|
150
|
-
clientName,
|
|
151
|
-
commandName,
|
|
152
|
-
inputFilterSensitiveLog: DecryptRequest.filterSensitiveLog,
|
|
153
|
-
outputFilterSensitiveLog: DecryptResponse.filterSensitiveLog,
|
|
154
|
-
};
|
|
155
|
-
const { requestHandler } = configuration;
|
|
156
|
-
return stack.resolve(
|
|
157
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
158
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
159
|
-
handlerExecutionContext
|
|
160
|
-
);
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
private serialize(input: DecryptCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
164
|
-
return serializeAws_json1_1DecryptCommand(input, context);
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<DecryptCommandOutput> {
|
|
168
|
-
return deserializeAws_json1_1DecryptCommand(output, context);
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
// Start section: command_body_extra
|
|
172
|
-
// End section: command_body_extra
|
|
173
|
-
}
|
|
@@ -1,138 +0,0 @@
|
|
|
1
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
2
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
3
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
4
|
-
import {
|
|
5
|
-
FinalizeHandlerArguments,
|
|
6
|
-
Handler,
|
|
7
|
-
HandlerExecutionContext,
|
|
8
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
9
|
-
MetadataBearer as __MetadataBearer,
|
|
10
|
-
MiddlewareStack,
|
|
11
|
-
SerdeContext as __SerdeContext,
|
|
12
|
-
} from "@aws-sdk/types";
|
|
13
|
-
|
|
14
|
-
import { KMSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../KMSClient";
|
|
15
|
-
import { DeleteAliasRequest } from "../models/models_0";
|
|
16
|
-
import {
|
|
17
|
-
deserializeAws_json1_1DeleteAliasCommand,
|
|
18
|
-
serializeAws_json1_1DeleteAliasCommand,
|
|
19
|
-
} from "../protocols/Aws_json1_1";
|
|
20
|
-
|
|
21
|
-
export interface DeleteAliasCommandInput extends DeleteAliasRequest {}
|
|
22
|
-
export interface DeleteAliasCommandOutput extends __MetadataBearer {}
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* <p>Deletes the specified alias. </p>
|
|
26
|
-
* <note>
|
|
27
|
-
* <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">Using ABAC in KMS</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
28
|
-
* </note>
|
|
29
|
-
* <p>Because an alias is not a property of a KMS key, you can delete and change the aliases of a KMS key without affecting the KMS key. Also, aliases do not appear in the response from the <a>DescribeKey</a> operation. To get the aliases of all KMS keys, use the <a>ListAliases</a> operation. </p>
|
|
30
|
-
* <p>Each KMS key can have multiple aliases. To change the alias of a KMS key, use <a>DeleteAlias</a> to delete the current alias and <a>CreateAlias</a> to
|
|
31
|
-
* create a new alias. To associate an existing alias with a different KMS key,
|
|
32
|
-
* call <a>UpdateAlias</a>.</p>
|
|
33
|
-
* <p>
|
|
34
|
-
* <b>Cross-account use</b>: No. You cannot perform this operation on an alias in a different Amazon Web Services account.</p>
|
|
35
|
-
* <p>
|
|
36
|
-
* <b>Required permissions</b>
|
|
37
|
-
* </p>
|
|
38
|
-
* <ul>
|
|
39
|
-
* <li>
|
|
40
|
-
* <p>
|
|
41
|
-
* <a href="https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html">kms:DeleteAlias</a> on the alias (IAM policy).</p>
|
|
42
|
-
* </li>
|
|
43
|
-
* <li>
|
|
44
|
-
* <p>
|
|
45
|
-
* <a href="https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html">kms:DeleteAlias</a> on the KMS key (key policy).</p>
|
|
46
|
-
* </li>
|
|
47
|
-
* </ul>
|
|
48
|
-
* <p>For details, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/kms-alias.html#alias-access">Controlling access to aliases</a> in the <i>Key Management Service Developer Guide</i>.</p>
|
|
49
|
-
* <p>
|
|
50
|
-
* <b>Related operations:</b>
|
|
51
|
-
* </p>
|
|
52
|
-
* <ul>
|
|
53
|
-
* <li>
|
|
54
|
-
* <p>
|
|
55
|
-
* <a>CreateAlias</a>
|
|
56
|
-
* </p>
|
|
57
|
-
* </li>
|
|
58
|
-
* <li>
|
|
59
|
-
* <p>
|
|
60
|
-
* <a>ListAliases</a>
|
|
61
|
-
* </p>
|
|
62
|
-
* </li>
|
|
63
|
-
* <li>
|
|
64
|
-
* <p>
|
|
65
|
-
* <a>UpdateAlias</a>
|
|
66
|
-
* </p>
|
|
67
|
-
* </li>
|
|
68
|
-
* </ul>
|
|
69
|
-
* @example
|
|
70
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
71
|
-
* ```javascript
|
|
72
|
-
* import { KMSClient, DeleteAliasCommand } from "@aws-sdk/client-kms"; // ES Modules import
|
|
73
|
-
* // const { KMSClient, DeleteAliasCommand } = require("@aws-sdk/client-kms"); // CommonJS import
|
|
74
|
-
* const client = new KMSClient(config);
|
|
75
|
-
* const command = new DeleteAliasCommand(input);
|
|
76
|
-
* const response = await client.send(command);
|
|
77
|
-
* ```
|
|
78
|
-
*
|
|
79
|
-
* @see {@link DeleteAliasCommandInput} for command's `input` shape.
|
|
80
|
-
* @see {@link DeleteAliasCommandOutput} for command's `response` shape.
|
|
81
|
-
* @see {@link KMSClientResolvedConfig | config} for command's `input` shape.
|
|
82
|
-
*
|
|
83
|
-
*/
|
|
84
|
-
export class DeleteAliasCommand extends $Command<
|
|
85
|
-
DeleteAliasCommandInput,
|
|
86
|
-
DeleteAliasCommandOutput,
|
|
87
|
-
KMSClientResolvedConfig
|
|
88
|
-
> {
|
|
89
|
-
// Start section: command_properties
|
|
90
|
-
// End section: command_properties
|
|
91
|
-
|
|
92
|
-
constructor(readonly input: DeleteAliasCommandInput) {
|
|
93
|
-
// Start section: command_constructor
|
|
94
|
-
super();
|
|
95
|
-
// End section: command_constructor
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
/**
|
|
99
|
-
* @internal
|
|
100
|
-
*/
|
|
101
|
-
resolveMiddleware(
|
|
102
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
103
|
-
configuration: KMSClientResolvedConfig,
|
|
104
|
-
options?: __HttpHandlerOptions
|
|
105
|
-
): Handler<DeleteAliasCommandInput, DeleteAliasCommandOutput> {
|
|
106
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
107
|
-
|
|
108
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
109
|
-
|
|
110
|
-
const { logger } = configuration;
|
|
111
|
-
const clientName = "KMSClient";
|
|
112
|
-
const commandName = "DeleteAliasCommand";
|
|
113
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
114
|
-
logger,
|
|
115
|
-
clientName,
|
|
116
|
-
commandName,
|
|
117
|
-
inputFilterSensitiveLog: DeleteAliasRequest.filterSensitiveLog,
|
|
118
|
-
outputFilterSensitiveLog: (output: any) => output,
|
|
119
|
-
};
|
|
120
|
-
const { requestHandler } = configuration;
|
|
121
|
-
return stack.resolve(
|
|
122
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
123
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
124
|
-
handlerExecutionContext
|
|
125
|
-
);
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
private serialize(input: DeleteAliasCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
129
|
-
return serializeAws_json1_1DeleteAliasCommand(input, context);
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<DeleteAliasCommandOutput> {
|
|
133
|
-
return deserializeAws_json1_1DeleteAliasCommand(output, context);
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
// Start section: command_body_extra
|
|
137
|
-
// End section: command_body_extra
|
|
138
|
-
}
|