SpringBoot2.x整合Spring Security5,登錄報錯:There is no PasswordEncoder mapped for the id "null"

解決:html 在繼承了WebSecurityConfigurerAdapter的自定義類SecurityConfig上添加一個BCryptPasswordEncoder類型的PasswordEncoder 組件:java @EnableWebSecurity //@EnableWebSecurity中帶有@Configuration,因此這裏不用寫了 public class Security
相關文章
相關標籤/搜索