Skip to content

Commit

Permalink
Merge pull request #660 from /issues/659-spring-security-api
Browse files Browse the repository at this point in the history
Fix #659: Replace Spring Security deprecated API
  • Loading branch information
banterCZ authored Sep 4, 2023
2 parents badd09e + 5e4a615 commit cb405d5
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
import org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer;
import org.springframework.security.web.SecurityFilterChain;

/**
Expand All @@ -44,8 +45,8 @@ public SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
return http
.authorizeHttpRequests(authorize -> authorize
.anyRequest().anonymous())
.httpBasic().disable()
.csrf().disable()
.httpBasic(AbstractHttpConfigurer::disable)
.csrf(AbstractHttpConfigurer::disable)
.build();
}

Expand Down

0 comments on commit cb405d5

Please sign in to comment.