Bash: aws-sts

aws-sts takes the marginally-useful JSON output from the aws sts command and generates shell code that can be fed into eval.

Useful for those of use with MFA enabled on our accounts. In an MFA CLI environment, your ACCESS_KEY_ID and SECRET_ACCESS_KEY are only useful for getting a session token from the AWS Security Token Service. It’s this token (actually a temporary key, secret key and session token) that you can then use to talk to the AWS CLI.

The CLI aws sts command takes a bunch of MFA information and spits out JSON that

Full documentation is in the index for the public_scripts project, available here:


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.