Skip to content

Commit

Permalink
feat: permit all origins and methods
Browse files Browse the repository at this point in the history
  • Loading branch information
svifty7 committed Nov 18, 2024
1 parent aade951 commit fa1d7d2
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions src/main/java/club/ttg/dnd5/config/SecurityConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -64,15 +64,10 @@ public BCryptPasswordEncoder passwordEncoder(){

CorsConfiguration getCorsConfigurer(final HttpServletRequest httpServletRequest) {
var corsConfiguration = new CorsConfiguration();
corsConfiguration.setAllowedOrigins(
List.of(
"https://ttg.club/",
"https://dev.ttg.club/"
)
);
corsConfiguration.setAllowedMethods(List.of("GET", "POST", "PUT", "DELETE", "OPTIONS"));
corsConfiguration.setAllowedOrigins(List.of("*"));
corsConfiguration.setAllowedMethods(List.of("*"));
corsConfiguration.setAllowedHeaders(List.of("*"));
corsConfiguration.setAllowCredentials(true);
corsConfiguration.setAllowCredentials(false);
return corsConfiguration;
}
}

0 comments on commit fa1d7d2

Please sign in to comment.