-
-
Notifications
You must be signed in to change notification settings - Fork 94
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
Failed to provide user info: Request failed with status code 403 #46
Comments
Hmm. I’m on mobile at the moment, so I’ll have to take a look when I am at my desk later. It looks like we can improve the debug logs- it’s not clear where that error is coming from. It looks like the user information is being received correctly, though. |
Looks like it’s the get user emails call that is failing. |
ahh ok, thanks for looking at this so quickly (also on mobile). I will take another debug session today with improved logging and maybe extend Winston formatting also. |
Ok, took a look at this and you're right, it's the email GET and logging can also be improved a bit 😄 although I like the abstraction! I added a naive error handler to log all error from axios to pick up the response from Github And this is the Github response: Naive error handler https://github.com/island-is/github-cognito-openid-wrapper/blob/fix/logging/src/github.js#L21-L32 Edit 01 🤦🏼 don't tell me I have to install the app also and set permissions. Edit 02 |
Glad it was an easy fix! Do the setup instructions need to be updated? If you have time for a PR that puts debug logging around the github request / responses, I would happily accept it. |
Yup, I will update the README and continue with improving the logging here |
I want to start by saying, thanks for sharing!
So here is my issue.
Cognito is getting a 403 on the
/userinfo
endpoint so I am assuming the Bearer token is invalid for some reason. Is this a common misconfiguration issue maybe on my part?The
state
attribute is alsoundefined
there but since the state is optional I think that's ok.Here are the relevant debug logs with sensitive values
<retracted>
.edit
I think this is also relevant, and is weird since I'm getting the
sub
from Github in the claim.Also Ngrok is returing 400 back to the Cognito client but that's probably because the wrapper doesn't resolve correctly because of the 403.
The text was updated successfully, but these errors were encountered: