UsernamePasswordAuthenticationTo

2020-07-28  本文已影响0人  zjkdifvpwlkqumn

UsernamePasswordAuthenticationToken
里面有UserDetails【principal】,credentials,authorities

UserDetails-里面有账号密码

UsernamePasswordAuthenticationToken authentication =
new UsernamePasswordAuthenticationToken(userDetails, null, userDetails.getAuthorities());

authentication.setDetails(new WebAuthenticationDetailsSource().buildDetails(request));
WebAuthenticationDetailsSource是干啥的?

上一篇 下一篇

猜你喜欢

热点阅读