AWSexit code > 0
An error occurred (ExpiredToken)
$An error occurred (ExpiredToken) when calling the GetCallerIdentity operation: The security token included in the request is expired
Analysis
Your temporary security credentials (usually from
aws sts get-session-token or a role assumption) have expired.Common Triggers
- ●Session timed out (typically after 1-12 hours).
- ●Local clock drift (rare but possible).
Debug Checks
- $Run
aws sts get-caller-identityto check current status.
Resolution
1
Re-authenticate with AWS (e.g.,
aws sso login or refresh your environment variables).2
Increase the session duration if possible.
Metadata
- Tool
- AWS
- Severity
- High
- Tags
- #aws#auth#session