vegas-credentials icon indicating copy to clipboard operation
vegas-credentials copied to clipboard

Handle STS errors more gracefully

Open aripalo opened this issue 2 years ago • 0 comments

If user configures invalid values (such as too long duration_seconds) then STS will return an error. This error is not processed and instead the end-user receives the following error with a stack trace:

Error when retrieving credentials from custom-process: panic: operation error STS: AssumeRole, https response error StatusCode: 400, RequestID: ****************************, api error ValidationError: The requested DurationSeconds exceeds the MaxSessionDuration set for this role.

goroutine 1 [running]:
github.com/aripalo/vegas-credentials/internal/credentials.(*Credentials).New(***********, {*********, ******})

This does not "break" anything per se but it's not a nice user experience.

aripalo avatar May 09 '22 00:05 aripalo