Bug: Handle GitHub OAuth Access Denied Error #7
Labels
↗️ medium priority
This issue is crucial
🐛 bug
Something isn't working
✨ enhancement
New feature or request
When using GitHub OAuth for authentication in our application, users may encounter an "access_denied" error if they deny our application access, leading to dead blank screen (see screenshot). This error needs to be handled gracefully to provide a good user experience and guide users on how to resolve the issue.
Solution:
Error Detection: Implement error detection logic in the OAuth callback handler to identify the "access_denied" error.
Error Handling: When the "access_denied" error is detected, display a user-friendly message to inform the user that their access has been denied and provide guidance on how to proceed.
Logging: Log the error details for debugging and monitoring purposes.
Redirect: Optionally, provide a redirect mechanism to allow the user to retry the authentication process or navigate back to a previous page.
Example Error Details:
http://localhost:4321/api/github/oauth/callback?error=access_denied&error_description=The+user+has+denied+your+application+access.&error_uri=https%3A%2F%2Fdocs.github.com%2Fapps%2Fmanaging-oauth-apps%2Ftroubleshooting-authorization-request-errors%2F%23access-denied&state=path%3A%2Fsandbox%7Credirect%3Atrue
access_denied
The user has denied your application access.
path:/sandbox|redirect:true
Acceptance Criteria:
Related Tasks:
Additional Notes:
The text was updated successfully, but these errors were encountered: