step1:首先ApplicationUserDetailsService需要实现UserDetailsService接口(在 org.springframework.security.core.userdetails里面),实现获取用户Details信息的回调函数,必须要实现 loadUserByUsername方法,注意这里的User实现了UserDetails,CredentialsContainer,User类里面的参数分别有: password,username,authorities