
[SpringSecurity] 인증 과정 뜯어보기
·
백엔드/SpringSecurity
UsernamePasswordAuthenticationFilter란우리가 로그인을 시도할 때 Security에서 기본적으로 동작하는 Filter이다.Security에서 디폴트로 제공하고 만약 SecurityFilterChain을 커스텀한다면 제공해주지 않는다.즉, 우리가 주로 커스텀 해야하는 Filter라는 뜻이다.AuthenticationFilter 구조AuthenticationFilter의 기본 호출 구조이다.호출 순서는 다음과 같다AuthenticationFilter호출UsernamePasswordAuthenticationToken (비인증) 생성AuthenticationManager.authenticate(token) 호출구현체인 ProviderManager 호출ProviderManager 는 A..