Get-CAAuthorizationToken is throwing error #296
-
Describe the bugusing powershelltool for some CI scripts since a while Everything was working fine but suddenly Error message
Expected BehaviorConsidering we are logged in with AWS SSO
It was working before but stop working lately Current Behaviorto facilitate the repro
Giving following error
Reproduction StepsChecking with version 4.1.164 is success
Checking with latest is Failed
Possible SolutionNo response Additional Information/ContextNo response AWS Tools for PowerShell version usedAWS.Tools.Installer 1.0.2.4 PowerShell version usedName Value PSVersion 7.0.12 Operating System and versionWindows 10 |
Beta Was this translation helpful? Give feedback.
Replies: 10 comments 2 replies
-
Based on sample .NET code at Single sign-on (SSO) with the AWS SDK for .NET,
@rjacquemin Please confirm the following:
Thanks, |
Beta Was this translation helpful? Give feedback.
-
See an example of the aws sso profile config
yes I can confirm 4.1.164 is working like before |
Beta Was this translation helpful? Give feedback.
-
Hi @rjacquemin, Good afternoon. If we follow the steps properly, the issue is not reproducible in the latest AWS Tools for PowerShell version. The issue occurs if
Few points to notice:
Thanks, |
Beta Was this translation helpful? Give feedback.
-
This issue has not received a response in 5 days. If you want to keep this issue open, please just leave a comment below and auto-close will be canceled. |
Beta Was this translation helpful? Give feedback.
-
yes we are installing AWS CLI on the docker image so the docker have access to the sso credentials
But it was working fine before
will check those maybe can give us more info |
Beta Was this translation helpful? Give feedback.
-
what is the checking the official doc we are talking about |
Beta Was this translation helpful? Give feedback.
-
@rjacquemin Thanks, |
Beta Was this translation helpful? Give feedback.
-
Hi there, Issue is pretty easy to reproduce - see post before Let me know if you need more information |
Beta Was this translation helpful? Give feedback.
-
Hello! Reopening this discussion to make it searchable. |
Beta Was this translation helpful? Give feedback.
Hi @rjacquemin,
Good afternoon.
If we follow the steps properly, the issue is not reproducible in the latest AWS Tools for PowerShell version. The issue occurs if
aws sso login
command is not executed before callingGet-CAAuthorizationToken
. For testing, I did not use the said Docker image, instead I tested it locally. Here is the screenshot:Get-CAAuthorizationToken
without executingaws sso login
. Got the said error reported by you.aws sso login
and approved the login in the web browser.Get-CAAuthorizationToken
. It ran successfully.Few points to notice:
Get-CAAuthorizationToken
in the said docker image. Do you have AWS CLI in…