Skip to content

Commit

Permalink
checking problem with cors
Browse files Browse the repository at this point in the history
  • Loading branch information
jimmy0006 committed Mar 30, 2024
1 parent 686edd8 commit 0fc5847
Showing 1 changed file with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,19 @@ public PasswordEncoder passwordEncoder() {
@Bean
public CorsConfigurationSource corsConfigurationSource() {
CorsConfiguration configuration = new CorsConfiguration();
configuration.setAllowCredentials(false);
configuration.setAllowedOrigins(Arrays.asList("https://alpha.poolc.org",
"https://server.poolc.kr", "http://localhost:3000","http://server.poolc.kr",
configuration.setAllowCredentials(true);
configuration.setAllowedOrigins(Arrays.asList(
"https://alpha.poolc.org", "http://localhost:3000",
"https://server.poolc.kr", "http://server.poolc.kr",
"http://poolc.kr","https://poolc.kr",
"https://poolc.org", "http://poolc.org",
"chrome-extension://doeamknhlolnflkmhbhkagganhjjbefe"
));
configuration.setAllowedHeaders(Arrays.asList("Authorization", "Cache-Control",
"Content-Type", "Accept", "Content-Length", "Accept-Encoding", "X-Requested-With"));
configuration.setAllowedHeaders(Arrays.asList(
// "Authorization", "Cache-Control",
// "Content-Type", "Accept", "Content-Length", "Accept-Encoding", "X-Requested-With"
"*"
));
configuration.setAllowedMethods(Arrays.asList("GET", "POST", "PUT", "DELETE", "OPTIONS", "HEAD"));
configuration.setMaxAge(3600L);

Expand Down

0 comments on commit 0fc5847

Please sign in to comment.