$ ls tags/ / authentication
#authentication
2 posts
frontend
localStorage와 React 인증 상태의 단절
토큰을 localStorage에 쓰고 바로 navigate했더니 앱이 로딩에서 멈췄다. 인증 상태가 localStorage(출처)와 Context(화면이 보는 파생) 두 곳에 사는데, 출처만 바꾸고 파생을 안 깨운 탓이었다.
2026.05.06 3 min read react · context-api · authentication · localStorage
backend
로그인 한 번으로 끝나지 않는 인증 검사
인증을 전수 점검하다 같은 구멍이 반복해서 나왔다. 상태 검사는 로그인에만 있고 토큰은 그 검사보다 오래 산다. 정지된 계정이 refresh로 새 토큰을 받고, 검증 토큰은 평문으로 DB에 누웠다.
2026.04.02 3 min read backend · security · authentication · jwt · nestjs