I try to encode and decode plaintext using aws kms encrypt and decrypt.But it showing a following error:
aws [options] <command> <subcommand> [<subcommand> ...] [parameters]
To see help text, you can run:
aws help
aws <command> help
aws <command> \<subcommand> help
**Unknown options: --decode, >, ExampleEncryptedFile.txt, base64"**
Commands which i used:
**aws kms encrypt --key-id 1234abcd-12ab-34cd-56ef-1234567890ab --
plaintext mysecretpassword --output text --query
CiphertextBlob | base64 --decode > ExampleEncryptedFile**
If i use like the below it works:
**aws kms encrypt --key-id 1234abcd-12ab-34cd-56ef-1234567890ab --
plaintext fileb://ExamplePlaintextFile --output text --query
CiphertextBlob**
Decode also facing issue like: **InvalidCiphertextException error**
Thanks in advance!