Skip to content

Commit

Permalink
Additional config
Browse files Browse the repository at this point in the history
  • Loading branch information
NyorJa committed Sep 27, 2023
1 parent b170d07 commit b7ef6c4
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ public class SecurityConfiguration {
public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Exception {
http.authorizeHttpRequests((auth) -> auth
.requestMatchers("/*/delete").hasRole("ADMIN")
.requestMatchers("/admin").hasRole("ADMIN"));
.requestMatchers("/admin").hasRole("ADMIN")
.anyRequest().authenticated());
http.formLogin((form) -> form.loginPage("/login").permitAll());
http.logout(LogoutConfigurer::permitAll);
return http.build();
Expand Down

0 comments on commit b7ef6c4

Please sign in to comment.