77import org .springframework .core .annotation .Order ;
88import org .springframework .core .env .Environment ;
99import org .springframework .security .authentication .AuthenticationManager ;
10- import org .springframework .security .config .Customizer ;
1110import org .springframework .security .config .annotation .authentication .configuration .AuthenticationConfiguration ;
1211import org .springframework .security .config .annotation .web .builders .HttpSecurity ;
1312import org .springframework .security .config .annotation .web .configuration .EnableWebSecurity ;
2726@ EnableWebSecurity
2827@ RequiredArgsConstructor
2928public class SecurityConfig {
30- private final AuthenticationConfiguration authenticationConfiguration ;
31-
32- private final JwtService jwtService ;
33-
34- private final JwtExceptionFilter jwtExceptionFilter ;
35-
36- private final Environment environment ;
37-
3829 // 공통적으로 허용되는 URL 패턴
3930 private static final String [] COMMON_WHITELIST_URLS = {
4031 "/h2-console/**" ,
@@ -44,9 +35,9 @@ public class SecurityConfig {
4435 "/actuator/prometheus" ,
4536 "/api/auth/v2/apple/**" ,
4637 "/api/auth/v2/kakao/**" ,
47- "/api/members/nickname/exists"
38+ "/api/members/nickname/exists" ,
39+ "/api/app/version/ios"
4840 };
49-
5041 // 개발 환경에서만 추가로 허용되는 URL 패턴
5142 private static final String [] DEV_WHITELIST_URLS = {
5243 "/swagger-ui/**" ,
@@ -57,6 +48,10 @@ public class SecurityConfig {
5748 "/configuration/ui" ,
5849 "/v3/api-docs/**"
5950 };
51+ private final AuthenticationConfiguration authenticationConfiguration ;
52+ private final JwtService jwtService ;
53+ private final JwtExceptionFilter jwtExceptionFilter ;
54+ private final Environment environment ;
6055
6156 @ Bean
6257 @ Order (0 )
@@ -87,7 +82,7 @@ protected SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
8782
8883 http
8984 .csrf (AbstractHttpConfigurer ::disable )
90- .formLogin (Customizer . withDefaults () )
85+ .formLogin (AbstractHttpConfigurer :: disable )
9186 .sessionManagement ((sessionManagement ) ->
9287 sessionManagement .sessionCreationPolicy (SessionCreationPolicy .STATELESS )
9388 // 세션을 사용하지 않는다고 설정함
@@ -98,6 +93,7 @@ protected SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
9893 authorizeRequests
9994 .requestMatchers (
10095 AntPathRequestMatcher .antMatcher ("/api/members/nickname/exists" ),
96+ AntPathRequestMatcher .antMatcher ("/api/app/version/ios" ),
10197 AntPathRequestMatcher .antMatcher ("/h2-console/**" )
10298 ).permitAll ()
10399 .requestMatchers (
0 commit comments