Skip to content

Commit

Permalink
Update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
bassages committed Aug 1, 2023
1 parent f9c638c commit af2adbd
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/main/java/nl/homeserver/config/WebSecurityConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.http.SessionCreationPolicy;
import org.springframework.security.web.SecurityFilterChain;
import org.springframework.security.web.util.matcher.AntPathRequestMatcher;

import static org.springframework.http.HttpStatus.RESET_CONTENT;
import static org.springframework.security.config.Customizer.withDefaults;
Expand Down Expand Up @@ -47,8 +48,13 @@ public SecurityFilterChain filterChain(final HttpSecurity http) throws Exception
authorizeHttpRequests
.requestMatchers(EndpointRequest.to("status", "info")).permitAll()
.requestMatchers(PathRequest.toStaticResources().atCommonLocations()).permitAll()
.requestMatchers("/", "/*.html", "/*.js", "/*.css", "/assets/**").permitAll()
.requestMatchers(Paths.LOGIN).permitAll()
.requestMatchers(
new AntPathRequestMatcher("/"),
new AntPathRequestMatcher("/*.html"),
new AntPathRequestMatcher("/*.js"),
new AntPathRequestMatcher("/*.css"),
new AntPathRequestMatcher("/assets/**")).permitAll()
.requestMatchers(new AntPathRequestMatcher(Paths.LOGIN)).permitAll()
.anyRequest().authenticated()
)
.rememberMe((rememberMe) ->
Expand Down

0 comments on commit af2adbd

Please sign in to comment.