-
Notifications
You must be signed in to change notification settings - Fork 0
[FEAT] 모임에서 공개할 API 설정 #79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -128,6 +128,14 @@ private boolean isPublicEndpoint(HttpServletRequest request) { | |||||||||
| return true; | ||||||||||
| } | ||||||||||
|
|
||||||||||
| if ("GET".equals(method) && pathMatcher.match("/api/v1/groups/**", path)) { | ||||||||||
| return true; | ||||||||||
| } | ||||||||||
|
|
||||||||||
| if ("GET".equals(method) && pathMatcher.match("/api/v1/group", path)) { | ||||||||||
| return true; | ||||||||||
| } | ||||||||||
|
|
||||||||||
|
Comment on lines
+135
to
+138
|
||||||||||
| if ("GET".equals(method) && pathMatcher.match("/api/v1/group", path)) { | |
| return true; | |
| } | |
| Original file line number | Diff line number | Diff line change | ||
|---|---|---|---|---|
|
|
@@ -30,7 +30,9 @@ public SecurityFilterChain filterChain(HttpSecurity http) throws Exception { | |||
|
|
||||
| http | ||||
| .authorizeHttpRequests((auth) -> auth | ||||
| .requestMatchers(HttpMethod.GET, "/api/v1/users/*").permitAll() | ||||
| .requestMatchers(HttpMethod.GET, "/api/v1/users/*").permitAll() | ||||
| .requestMatchers(HttpMethod.GET, "/api/v1/groups/**").permitAll() | ||||
| .requestMatchers(HttpMethod.GET, "/api/v1/groups").permitAll() | ||||
|
||||
| .requestMatchers(HttpMethod.GET, "/api/v1/groups").permitAll() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The path pattern
/api/v1/groupappears to be a typo and doesn't match the pattern in SecurityConfig which uses/api/v1/groups. This inconsistency means the filter logic won't align with the security configuration, potentially causing authentication issues. Change this to/api/v1/groupsto match the SecurityConfig pattern, or remove this check as it would be redundant with the/**pattern on line 131.