Skip to content

Commit da2dc72

Browse files
committed
[refactor/#350] Spring Security 권장사항 반영
1 parent 18bf55f commit da2dc72

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

resource-server/src/main/java/com/inhabas/api/config/WebSecurityConfig.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -125,12 +125,7 @@ public CorsConfigurationSource corsConfigurationSource() {
125125

126126
@Bean
127127
public WebSecurityCustomizer webSecurityCustomizer() {
128-
return (web) -> {
129-
// 동적 API는 필터 체인을 타게 두고, 정적 리소스만 완전히 무시
130-
for (String pattern : AUTH_WHITELIST_STATIC) {
131-
web.ignoring().requestMatchers(new AntPathRequestMatcher(pattern));
132-
}
133-
};
128+
return (web) -> {};
134129
}
135130

136131
@Bean
@@ -163,6 +158,8 @@ public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Excepti
163158
// Swagger 및 공개 경로는 필터 체인은 타되 인가만 면제
164159
.requestMatchers(pathMatchers(AUTH_WHITELIST_SWAGGER))
165160
.permitAll()
161+
.requestMatchers(pathMatchers(AUTH_WHITELIST_STATIC))
162+
.permitAll()
166163
.requestMatchers(pathMatchers(AUTH_WHITELIST_PATH))
167164
.permitAll()
168165
// GET 공개 엔드포인트들

0 commit comments

Comments
 (0)