common-fate / granted

The easiest way to access your cloud.
https://granted.dev
MIT License
964 stars 91 forks source link

InvalidClientTokenId: The security token included in the request is invalid. #516

Closed tomjohnburton closed 9 months ago

tomjohnburton commented 9 months ago

I have tried everything to get granted to work on machine. I know it's possible because my colleague is using it with no issues. I have imported my credentials to the keystore but whenever I try to assume another profile it give me this error

[✘] operation error STS: AssumeRole, https response error StatusCode: 403, RequestID: cba85d41-5ccc-45c3-8f05-1901a87447f2, api error InvalidClientTokenId: The security token included in the request is invalid.

I have deleted my .aws/credentials file

I am on granted v0.18.0

aws-cli/2.13.19

My config file looks like this

[profile Perseverance]
role_arn       = arn:aws:iam::***:role/OrganizationAccountAccessRole
source_profile = default
region         = eu-central-1
output         = json

[profile flip]
region = eu-central-1
output = json
credential_process = granted credential-process --profile=flip
tomjohnburton commented 9 months ago

Not sure what I did but after starting again from scratch I got it to work