POST /auth/login reveals account existence, role and lock state
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 55/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- typescript
- Ambito
- authentication
Direzione di ricerca
Start at the POST /auth/login handler and follow the role, lock-state, and password checks; the issue does not name files or tests. Compare the behavior with the fix for #328 and the later changes in #425 and #494. Done means all login failures return the same 401 message and details, with specific reasons logged server-side and lock information shown only after a correct password.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
POST /auth/login returns a different error for each account state, so anyone can tell whether an email is registered, which role it has and whether it's locked, without knowing the password. details says "User not found", "Account locked until …", "Retries exceeded, account locked for …", "User does not have admin privileges" or "User is not a participant", and message changes to "Incorrect Permissions" for the two role cases. Both login pages show details to the user.
#328 fixed this for #226 by returning "Invalid credentials provided" for an unknown email and a wrong password alike. #425 split that check again when it added the role checks, and #494 added the lock checks. Both run before the password check.
Fix: return the same 401 message and details for every login failure, and log the specific reason on the server instead. If a locked user needs to know about the lock, show it only after a correct password. #963 is the same problem on password reset.
Related: #226, #963.
- Lingua principale
- TypeScript
- Stelle
- 4
- Fork
- 0
- Merge medio
- 14h 50m
- PR unite (30g)
- 5
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di Garvan-Data-Science-Platform/ctrl
-
Difficoltà 1/5 1-3 ore Idoneità per principianti 82/100
-
admin-client backend bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
-
backend bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
Garvan-Data-Science-Platform/ctrl#970 · 1 commento ·
-
backend bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
backend bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
Tutte le issue di Garvan-Data-Science-Platform/ctrl
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
wormhole-foundation/wormhole#5062 ·
I maintainer di solito rispondono entro 1 giorno
-
internal os specific
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
frostney/GocciaScript#1688 ·
I maintainer di solito rispondono entro 1 giorno
-
integration:hermes
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
vectorize-io/hindsight#5592 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
vercel/streamdown#673 · 1 reazione ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
apache/rocketmq-dashboard#6712 ·
I maintainer di solito rispondono entro 3 giorni