Skip to content

Commit d7eb57d

Browse files
authored
Merge pull request #248 from mosu-dev/develop-test
MOSU test: TestServer Whitelist 적용
2 parents 9ac88c1 + 399f435 commit d7eb57d

2 files changed

Lines changed: 11 additions & 3 deletions

File tree

src/main/java/life/mosu/mosuserver/global/filter/Whitelist.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ public enum Whitelist {
2121
SWAGGER_UI("/api/v1/swagger-ui", WhitelistMethod.ALL),
2222
VIRTUAL_ACCOUNT("/api/v1/virtual-account", WhitelistMethod.ALL),
2323
ADMISSION_TICKET("/api/v1/admission-ticket", WhitelistMethod.ALL),
24+
FILE("/api/v1/s3", WhitelistMethod.ALL),
2425

2526
// 정적 리소스
2627
CSS("/api/v1/css", WhitelistMethod.GET),
@@ -39,6 +40,16 @@ public enum Whitelist {
3940
EVENT("/api/v1/event", WhitelistMethod.GET),
4041
FAQ("/api/v1/faq", WhitelistMethod.GET),
4142
NOTICE("/api/v1/notice", WhitelistMethod.GET),
43+
USER_ID_CHECK("/api/v1/user/check-id", WhitelistMethod.GET),
44+
CUSTOMER_KEY_CHECK("/api/v1/user/customer-key", WhitelistMethod.GET),
45+
EXAM("/api/v1/exam", WhitelistMethod.GET),
46+
EXAM_AREAS("/api/v1/exam/areas", WhitelistMethod.GET),
47+
EXAM_ALL("/api/v1/exam/all", WhitelistMethod.GET),
48+
49+
//USER find-id
50+
USER_FIND_ID("/api/v1/user/me/find-id", WhitelistMethod.POST),
51+
//USER find-password
52+
USER_FIND_PASSWORD("/api/v1/user/me/find-password", WhitelistMethod.POST),
4253

4354
APPLICATION_GUEST("/api/v1/applications/guest", WhitelistMethod.ALL);
4455
private final String path;

src/main/java/life/mosu/mosuserver/presentation/exam/ExamController.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,13 @@ public ResponseEntity<ApiResponseWrapper<Void>> register(
3737
}
3838

3939
@GetMapping("/all")
40-
@PreAuthorize("isAuthenticated() and hasRole('ADMIN')")
4140
public ResponseEntity<ApiResponseWrapper<List<ExamResponse>>> getExams() {
4241
List<ExamResponse> response = examService.getExams();
4342
return ResponseEntity.ok(
4443
ApiResponseWrapper.success(HttpStatus.OK, "전체 시험 정보 조회 성공", response));
4544
}
4645

4746
@GetMapping
48-
@PreAuthorize("isAuthenticated() and hasRole('USER')")
4947
public ResponseEntity<ApiResponseWrapper<List<ExamResponse>>> getByArea(
5048
@RequestParam String areaName
5149
) {
@@ -55,7 +53,6 @@ public ResponseEntity<ApiResponseWrapper<List<ExamResponse>>> getByArea(
5553
}
5654

5755
@GetMapping("/areas")
58-
@PreAuthorize("isAuthenticated() and hasRole('USER')")
5956
public ResponseEntity<ApiResponseWrapper<List<String>>> getDistinctAreas() {
6057
List<String> response = examService.getDistinctAreas();
6158
return ResponseEntity.ok(

0 commit comments

Comments
 (0)