(core): Synth always fails if configured AWS creds are expired
See original GitHub issueDescribe the bug
If I have AWS credentials in my .aws/credentials
file that are expired, cdk synth
will not work, regardless of whether it needs to perform API calls.
Expected Behavior
cdk synth
works regardless of AWS credentials if no AWS API calls required
Current Behavior
Error on synth with expired AWS credentials:
The security token included in the request is expired
The same works fine if I have no configured AWS credentials at all.
Reproduction Steps
cdk init sample-app
Have expired credentials configured in ~/.aws/credentials
cdk synth
- Error
rm ~/.aws/credentials
cdk synth
- Succeeds
Possible Solution
No response
Additional Information/Context
The fact that synth works fine without any credentials at all confirms that this is a bug.
CDK CLI Version
2.41.0
Framework Version
No response
Node.js Version
18.9.0
OS
Linux
Language
Typescript, Python, .NET, Java, Go
Language Version
No response
Other information
No response
Issue Analytics
- State:
- Created a year ago
- Comments:7 (5 by maintainers)
Top Results From Across the Web
Troubleshoot AWS STS security token expired errors when ...
Example output using expired credentials: "An error occurred (ExpiredToken) when calling the ListBuckets operation: The provided token has ...
Read more >The security token included in the request is expired
aws /configure and was trying to configure from that but what I didn't realize is I had another pair of credentials AWS_SESSION_TOKEN ...
Read more >Never put AWS temporary credentials in the ... - Ben Kehoe
We need to talk about how AWS credential configuration works. ... An error occurred (ExpiredToken) when calling the GetCallerIdentity ...
Read more >model d patches
WELSH'S SYNTHESIZER COOKBOOK patches for Behringer Model D Poly D Pro-1 ... To post on Towson Patch, simply reset your password if you...
Read more >aws expired token
So the Access token expired error, will be seen when the KC Plug-In service is ... Loading AWS SSO credentials with the AWS...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Fixed by https://github.com/aws/aws-cdk/pull/22861
⚠️COMMENT VISIBILITY WARNING⚠️
Comments on closed issues are hard for our team to see. If you need more assistance, please either tag a team member or open a new issue that references this one. If you wish to keep having a conversation with other community members under this issue feel free to do so.