During the OAuth2 login flow, when the user has 2FA enabled, the LoginFlow may be in a weird state
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
- Área
- authentication
Línea de trabajo
Reproduce el flujo de inicio de sesión OAuth2 descrito en el issue e inspecciona el LoginFlow devuelto después del paso de email/contraseña, especialmente refresh y requested_aal. Revisa ory/elements/src/react-components/ory/user-auth-card.tsx alrededor de la línea 129 y determina el comportamiento esperado para el paso aal2; se considera terminado cuando el estado del flujo y el paso de autenticación mostrado coinciden.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Preflight checklist
- I could not find a solution in the existing issues, docs, nor discussions.
- I agree to follow this project's Code of Conduct.
- I have read and am following this repository's Contribution Guidelines.
- I have joined the Ory Community Slack.
- I am signed up to the Ory Security Patch Newsletter.
Ory Network Project
dazzling-chandrasekhar-msru5m4b1c
Describe the bug
During the OAuth2 flow, after submitting the email/password, the user is redirected to a URL similar to the following: https://account-flows-test.bonfirehub.com/self-service/login/browser?aal=aal2&login_challenge=[…]&return_to=https%3A%2F%2Fdazzling-chandrasekhar-msru5m4b1c.projects.oryapis.com%2Foauth2%2Fauth%3F[...], which looks correct.
But the LoginFlow returned by Ory from that request has both "requested_aal": "aal2" AND "refresh": true.
I’m not sure why refresh is true here. It is causing an issue for us because when refresh is true, our code attempts to look up the user’s current session (the one we are refreshing) so we can display the email address of the account the user is logged in as.
But in this case, the session lookup fails (I believe with a 403, Session has a lower AAL than required for the identity error).
All that said, is "refresh": true expected here? Or is it a bug?
In ory/elements, the UserAuthCard will display "Confirm it's you" instead of "Two-Factor Authentication" in this scenario.
https://github.com/ory/elements/blob/main/src/react-components/ory/user-auth-card.tsx#L129
May be related to https://github.com/ory/kratos/discussions/2742
Reproducing the bug
Start the OAuth2 Login flow with a user that has 2FA enabled. After submitting email/password, the user should be redirected to the page where the user submits the 2FA code. If you inspect the LoginFlow object, it should have both refresh: true and requested_aal: 'aal2'.
Relevant log output
No response
Relevant configuration
No response
Version
Ory Network
On which operating system are you observing this issue?
Ory Network
In which environment are you deploying?
Ory Network
Additional Context
No response
- Lenguaje dominante
- Shell
- Estrellas
- 95
- Forks
- 7
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una 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 ory/network
-
feat
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 38/100
-
Updating native registration flow with OIDC ID token for existing identity returns breaking responseAbiertobug
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
-
Ory Account Experience (hosted UI) registration trait setup via creation of registration flowAbiertofeat
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
-
selfservice.flows.login.style reverts to identifier_first despite explicitly setting passwordAbiertobug
Dificultad 4/5 3-5 días Aptitud para principiantes 30/100
Todos los issues de ory/network
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
bioconda/bioconda-recipes#70401 ·
Los mantenedores suelen responder en 2 días
-
Bisect issue233186Abiertobisect
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
dtcxzyw/llvm-bisect-service#548 ·
-
area/agent status/need-triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
google-gemini/gemini-cli#29811 ·
Los mantenedores suelen responder en 2 días
-
keypunchAbierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
amnezia-vpn/amnezia-client#3297 · 1 comentario ·
Los mantenedores suelen responder en 1 día