Open APurraedleiaeu opened 6 months ago
Voting for Prioritization
Volunteering to Work on This Issue
I can confirm this behavior. I tried arbitrary older AWS provider versions (5.23.1, 4.67.0, 4.20.1, 3.76.1), they all behave the same.
Can confirm this is still an issue today, specifically with invalid_grant
response even though they are assigned on the console via Hosted UI
I am experiencing the same issue. The temporary solution is to edit the Hosted UI settings of the client and click save without changing any options. I will try to create a script to automate this process until the bug is resolved.
It seems that some details of the client configuration are not being correctly applied by Terraform.
Terraform Core Version
1.6.2
AWS Provider Version
5.31.0
Affected Resource(s)
App client with client_credential mode
Expected Behavior
Response to curl to get a token should be something like
{"access_token":"token","expires_in":3600,"token_type":"Bearer"}
Actual Behavior
But out of the box after Terraform ran, we are getting a
{"error":"invalid_grant"}
Relevant Error/Panic Output Snippet
No response
Terraform Configuration Files
Steps to Reproduce
Step to reproduce : Ressources deployed with Terraform:
App client
Request a token with, for example, a curl An app client deployed with Terraform is correctly setup but Cognito doesn't give any token.
Request a token with :
Debug Output
No response
Panic Output
No response
Important Factoids
This issue can be fixed by:
Only then, the curl returns a token. A new terraform plan is not showing any change to apply after that manual save.
References
No response
Would you like to implement a fix?
None