Home > other >  Is it possible to encrypt/decrypt a text with aws-encryption-sdk-python and using an asymmetric cust
Is it possible to encrypt/decrypt a text with aws-encryption-sdk-python and using an asymmetric cust

Time:09-22

Is it possible to encrypt/decrypt a text using an asymmetric customer key, stored in KMS, passing it to the encrypt and decrypt functions of the aws-encryption-sdk-python? I tried this but could not pass the encryption step, it raises an error:

An error ocurred (InvalidKeyUsageException) when calling the GenerateDataKey operation: You cannot generate a data key with an assymetric CMK.

CodePudding user response:

No there is no such way. From docs:

The AWS Encryption SDK supports only symmetric encryption KMS keys. You cannot use an asymmetric KMS key for encryption or signing in the AWS Encryption SDK.

  • Related