Closed
Description
We started running into occasional Auth0 failures with "State doesn't match". After a day of banging my head against the wall, I think I have a pretty good idea of what's going on:
If a user simultaneously loads multiple pages while unauthenticated, the result is a race condition:
- Tab 1 updates
state
and redirects to OAuth - Tab 2 updates
state
and redirects to OAuth- Overwriting Tab 1
state
- Overwriting Tab 1
- Tab 1 callback fails due to state mismatch
- Tab 2 callback succeeds
This is pretty common when reopening a closed browser, for example.
Metadata
Metadata
Assignees
Labels
No labels