Session not cleared if user uses Back after logout
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 35/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Stack tecnológico
- react, typescript
- Área
- authentication, frontend
Línea de trabajo
Comienza reproduciendo la secuencia de inicio de sesión, cierre de sesión y retroceso del navegador en Chrome con auth0-react v2.2.1 y React 17.0.2, comparando el uso normal con las herramientas de desarrollo abiertas y con la auth0-react sample app. Rastrea la configuración de Auth0Provider y el callback de navegación que se muestran en el informe; se considera terminado cuando pulsar Back después del cierre de sesión no puede restaurar un estado autenticado de la aplicación y el comportamiento de actualización sigue siendo correcto.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Checklist
- The issue can be reproduced in the auth0-react sample app (or N/A).
- I have looked into the Readme, Examples, and FAQ and have not found a suitable solution or answer.
- I have looked into the API documentation and have not found a suitable solution or answer.
- I have searched the issues and have not found a suitable solution or answer.
- I have searched the Auth0 Community forums and have not found a suitable solution or answer.
- I agree to the terms within the Auth0 Code of Conduct.
Description
After calling logout the user is redirect back to our login page, but if they go back with their browser they can get back into the application and perform authenticated actions. Calling refresh at any time throws them out of the application, and the auth0 logs show a successful logout.
To add more mystery to this, it does not happen consistently. For example, if the developer tools are open in the browser, the problem goes away and going back throws the user onto the login screen.
Reproduction
- login
- logout
- press back
- find yourself logged in again.
It seems to be mitigated by having the developer tools open, but is pretty much consistent in normal use. Also unable to replicate it on a localhost dev build.
Additional context
This is our auth provider
const onRedirectCallback = (appState?: AppState) => {
navigate(appState?.returnTo || window.location.pathname);
};
...
<Auth0Provider
domain={config.auth0.domain}
clientId={config.auth0.clientId}
authorizationParams={{
redirect_uri: window.location.origin,
audience: config.auth0.audience,
}}
onRedirectCallback={onRedirectCallback}
useRefreshTokens
cacheLocation={config.auth0.cacheLocation} // undefined expect for e2e tests
>
auth0-react version
v2.2.1
React version
17.0.2
Which browsers have you tested in?
Chrome
- Lenguaje dominante
- TypeScript
- Estrellas
- 990
- Forks
- 294
- Merge medio
- 21 h 12 min
- PR fusionados (30 d)
- 31
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de auth0/auth0-react
-
Users getting logged out with "Unsuccessful Refresh Token exchange, reused refresh token detected"Abiertobug
Dificultad 4/5 3-5 días Aptitud para principiantes 38/100
auth0/auth0-react#929 · 16 comentarios · 1 reacción ·
Los mantenedores suelen responder en 1 día
Todos los issues de auth0/auth0-react
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
melgarafael/DeskcommCRM#1812 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
prisma/prisma-cli#309 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
gregwebs/pi-quota-dispatcher#26 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
openwatersio/slackwater.xyz#124 ·
Los mantenedores suelen responder en 1 día
-
agent-reported area/browser area/docs documentation good first issue hacktoberfest help wanted P2
Dificultad 1/5 Menos de una hora Aptitud para principiantes 90/100
Los mantenedores suelen responder en 2 días