Java Code Examples for org.springframework.security.config.annotation.authentication.builders.authenticationmanagerbuilder#userDetailsService()
The following examples show how to use
org.springframework.security.config.annotation.authentication.builders.authenticationmanagerbuilder#userDetailsService() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SpringWebConfig.java From we-cmdb with Apache License 2.0 | 5 votes |
@Override protected void configure(final AuthenticationManagerBuilder auth) throws Exception { if (!securityProperties.isEnabled()) { auth.userDetailsService(userDetailsService).passwordEncoder(new BypassPasswordEncoder()); } else if (AuthenticationType.lOCAL.getCode().equalsIgnoreCase(securityProperties.getAuthenticationProvider())) { auth.userDetailsService(userDetailsService); } else { super.configure(auth); } }
Example 2
Source File: SecurityConfiguration.java From gemini with Apache License 2.0 | 5 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { /* auth.inMemoryAuthentication() .withUser("manzi").password(passwordEncoder().encode("cane")).authorities("ROLE_USER");*/ auth.userDetailsService(userDetailsService); }
Example 3
Source File: SecurityConfig.java From spring-boot-cookbook with Apache License 2.0 | 5 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userDetailsService); // auth.inMemoryAuthentication() // .withUser("admin").password("admin").roles("ADMIN", "USER") // .and() // .withUser("user").password("user").roles("USER"); }
Example 4
Source File: DemoApplicationConfiguration.java From activiti-examples with Apache License 2.0 | 4 votes |
@Override @Autowired public void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(myUserDetailsService()); }
Example 5
Source File: AppSecurityModelD.java From Spring-5.0-Cookbook with MIT License | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userDetailsService); auth.eraseCredentials(false); }
Example 6
Source File: WebSecurityConfig.java From itweet-boot with Apache License 2.0 | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(customUserService()); //user Details Service验证 }
Example 7
Source File: JdbcSecurityConfiguration.java From pro-spring-boot with Apache License 2.0 | 4 votes |
@Override public void init(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(this.userDetailsService); }
Example 8
Source File: SecurityAutoConfiguration.java From activiti6-boot2 with Apache License 2.0 | 4 votes |
@Override public void init(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService( userDetailsService()); }
Example 9
Source File: SecurityConfiguration.java From OAuth-2.0-Cookbook with MIT License | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userDetailsService); }
Example 10
Source File: SecurityConfig.java From building-microservices with Apache License 2.0 | 4 votes |
@Override public void init(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(this.userDetailsService); }
Example 11
Source File: SecurityConfiguration.java From OAuth-2.0-Cookbook with MIT License | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userDetailsService); }
Example 12
Source File: SecurityConfig.java From oauth2-blog with MIT License | 4 votes |
@Autowired public void globalUserDetails(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(new DefaultUserDetailsService(userRepository)); }
Example 13
Source File: ApplicationConfiguration.java From spring-rest-black-market with MIT License | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(customUserDetailsService); }
Example 14
Source File: SecurityConfiguration.java From oauth2lab with MIT License | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userDetailsService); }
Example 15
Source File: WebSecurityConfig.java From pivotal-bank-demo with Apache License 2.0 | 4 votes |
@Autowired public void configureGlobal(AuthenticationManagerBuilder auth) throws Exception { auth.authenticationProvider(customAuthenticationProvider); auth.userDetailsService(customCredentialsService); }
Example 16
Source File: SecurityConfiguration.java From OAuth-2.0-Cookbook with MIT License | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(users); }
Example 17
Source File: WebSecurityConfig.java From cf-SpringBootTrader with Apache License 2.0 | 4 votes |
@Autowired public void configureGlobal(AuthenticationManagerBuilder auth) throws Exception { auth.authenticationProvider(customAuthenticationProvider); auth.userDetailsService(customCredentialsService); }
Example 18
Source File: StatelessAuthenticationSecurityConfig.java From boot-stateless-social with MIT License | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userService); }
Example 19
Source File: SecurityConfig.java From Vaadin4Spring-MVP-Sample-SpringSecurity with Apache License 2.0 | 4 votes |
@Override protected void configure(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userDetailsService); }
Example 20
Source File: AuthenticationConfiguration.java From java-microservice with MIT License | 4 votes |
@Override public void init(AuthenticationManagerBuilder auth) throws Exception { auth.userDetailsService(userDetailsService()); }