Skip to content

Commit 0ef27b3

Browse files
author
Jay Bryant
committed
Fix for #51
Update the code to avoid deprecated methods. Thanks for Steve Reisenberg for puzzling out the solution.
1 parent 3dc856d commit 0ef27b3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

complete/src/main/java/com/example/authenticatingldap/WebSecurityConfig.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ public class WebSecurityConfig {
1616
@Bean
1717
public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Exception {
1818
http
19-
.authorizeRequests()
19+
.authorizeHttpRequests((authorize) -> authorize
2020
.anyRequest().fullyAuthenticated()
21-
.and()
22-
.formLogin();
21+
)
22+
.formLogin(Customizer.withDefaults());
2323

2424
return http.build();
2525
}

0 commit comments

Comments
 (0)