-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cognitoidentityprovider initiate_auth with "USER_PASSWORD_AUTH" Errors when searching for additional credentials #815
Comments
Have you tried with anonymous credentials? |
Hi @DyfanJones, thanks for the reply! I attempted to initialize the client with anonymous credentials according to documentation which suggests a logical value:
This results in a "400 Bad Request" error, with the Amazon error type "Unknown Operation Exception".
|
Sorry about that, not sure what is going on. I will have to set up cognito to understand what is causing the issue. |
I have found the bug. We accidentally removed all remotes::install_github("dyfanjones/paws/paws.common", ref = "anonymous_cred") library(paws)
svc <- cognitoidentityprovider(config(credentials(anonymous = T), region = "us-east-1"))
resp <- svc$initiate_auth(
ClientId = "YOUR CLIENT ID",
AuthFlow = "USER_PASSWORD_AUTH",
AuthParameters = list(
USERNAME = "YOUR USER NAME",
PASSWORD = "YOUR PASSWORD"
)
) For extra context: Let me know if this fix works for you. |
Yes, this does the trick! Thank you for the solution and the clarification. Really appreciate your time. |
Hello!
Note that I am struggling to create a full reprex because I can't share the clientId/credential information for authentication.
I have a user pool in AWS cognito that has USER_PASSWORD_AUTH enabled. I know this is configured correctly because I am able to authenticate through Python using only USERNAME and PASSWORD AuthParameters. Here is my Python code that runs fine:
I need to write up an authentication flow in R as well but am receiving the following errors when running this code:
with options("paws.log_level" = 3L) enabled:
It seems like the authflow is being ignored if these files/credentials are still being searched for. Am I missing something basic?
The text was updated successfully, but these errors were encountered: