Token Invalid Error when Using AWS CLI

0

Hi, this might be a less intelligent question but I have my AWS account in Isengar, I copied the temporary credential including AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY AWS_SESSION_TOKEN to CloudDesktop/Mac, it gives me the error "The security token included in the request is invalid" when I use AWS CLI.

AWS
已提问 1 年前2811 查看次数
1 回答
0
已接受的回答

Here are a few things you can try to troubleshoot the issue:

  1. Check the region: Make sure that the region you're using in the AWS CLI command matches the region of the temporary credentials.

  2. Check the IAM user permissions: Make sure that the IAM user associated with the temporary credentials has the necessary permissions to perform the action you're trying to do.

  3. Check the time on the CloudDesktop/Mac: Make sure the time on the CloudDesktop/Mac is in sync with the time on the Internet. Sometimes, the temporary credentials are time-sensitive, and if the time on your computer is off, the credentials will not work.

  4. Try to use the session token: when you use the AWS CLI command, make sure to use the session token to authenticate as well.

  5. Check the credentials path: Make sure that the credentials are saved in the default location, or if you have defined a path in your AWS CLI configuration file.

已回答 1 年前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则