Created
October 28, 2021 20:47
-
-
Save Voronenko/e805b384d58b20fc4dcfb1a7fac56ee0 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
An error occurred (InvalidClientTokenId) when calling the ListAccountAliases operation: The security token included in the request is invalid. | |
Run the sts get-session-token AWS CLI command, replacing the variables with information from your account, resources, and MFA device: | |
$ aws sts get-session-token --serial-number arn-of-the-mfa-device --token-code code-from-token | |
You receive an output with temporary credentials and an expiration time (by default, 12 hours) similar to the following: | |
{ | |
"Credentials": { | |
"SecretAccessKey": "secret-access-key", | |
"SessionToken": "temporary-session-token", | |
"Expiration": "expiration-date-time", | |
"AccessKeyId": "access-key-id" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment