BAEL-2762 formating done for 2 space indenting
This commit is contained in:
parent
5421b1af95
commit
7bb1a28235
@ -14,27 +14,25 @@ public class BasicAuthConfiguration extends WebSecurityConfigurerAdapter {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void configure(AuthenticationManagerBuilder auth) throws Exception {
|
protected void configure(AuthenticationManagerBuilder auth) throws Exception {
|
||||||
PasswordEncoder encoder =
|
PasswordEncoder encoder = PasswordEncoderFactories.createDelegatingPasswordEncoder();
|
||||||
PasswordEncoderFactories.createDelegatingPasswordEncoder();
|
auth
|
||||||
|
.inMemoryAuthentication()
|
||||||
auth
|
.withUser("user")
|
||||||
.inMemoryAuthentication()
|
.password(encoder.encode("password"))
|
||||||
.withUser("user")
|
.roles("USER")
|
||||||
.password(encoder.encode("password"))
|
.and()
|
||||||
.roles("USER")
|
.withUser("admin")
|
||||||
.and()
|
.password(encoder.encode("admin"))
|
||||||
.withUser("admin")
|
.roles("USER", "ADMIN");
|
||||||
.password(encoder.encode("admin"))
|
|
||||||
.roles("USER", "ADMIN");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void configure(HttpSecurity http) throws Exception {
|
protected void configure(HttpSecurity http) throws Exception {
|
||||||
http
|
http
|
||||||
.authorizeRequests()
|
.authorizeRequests()
|
||||||
.anyRequest()
|
.anyRequest()
|
||||||
.authenticated()
|
.authenticated()
|
||||||
.and()
|
.and()
|
||||||
.httpBasic();
|
.httpBasic();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user