ionic-team / ionic-team/demo-authconnect-auth0

Stops working when user is blocked after getting initial login success

Open
#4 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
27
Forks
12
PR merge metrics
No merged PRs in 30d

Description

Steps to reproduce
1. Login into App using any unblocked user.
2. After successfull login, block the user.
3.When existing token expires , try to refresh token by going to any other page so that Auth Guard code calls isAuthenticated method.
4. Auth guard doesn't redirect to login page and following error shows up. Tried to catch the error but unable to handle it.

{status: 403, url: "https://******.auth0.com/oauth/token", headers: {…}, error: "{"error":"invalid_grant","error_description":"user is blocked"}"}
error: "{"error":"invalid_grant","error_description":"user is blocked"}"
headers: {date: "Fri, 17 Apr 2020 21:13:25 GMT", content-length: "63", server: "nginx", okhttp-selected-protocol: "h2", x-auth0-requestid: "3a668e8912e163f42157", …}
status: 403

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the flow with an initially unblocked user, then inspect the Auth Guard's isAuthenticated call and token-refresh handling. Confirm that an Auth0 403 invalid_grant error for a blocked user redirects to the login page instead of surfacing the raw error.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
authentication
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.