From 7e3fb4a378135d20e9f66ec7c13a2763d4af7dfd Mon Sep 17 00:00:00 2001 From: HyuckJuneHong Date: Tue, 12 Sep 2023 14:59:49 +0900 Subject: [PATCH 1/2] =?UTF-8?q?[JT-65]=20hotfix:=20deploy=20=EB=B9=88?= =?UTF-8?q?=EC=B9=B8=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/jtoon-deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/jtoon-deploy.yml b/.github/workflows/jtoon-deploy.yml index ebe80070..a4d23856 100644 --- a/.github/workflows/jtoon-deploy.yml +++ b/.github/workflows/jtoon-deploy.yml @@ -19,7 +19,7 @@ jobs: run: | VERSION=$(grep -o -E "v[0-9]+\.[0-9]+\.[0-9]+" <<< "${{ github.event.head_commit.message }}") echo "VERSION=${VERSION}" >> $GITHUB_ENV - + - name: Github release 자동생성 uses: action-pack/github-release@v2 env: From 5bac0b8041196e4b8f52fd4a70203e5f9cb7911d Mon Sep 17 00:00:00 2001 From: HyuckJuneHong Date: Tue, 12 Sep 2023 15:23:49 +0900 Subject: [PATCH 2/2] =?UTF-8?q?[JT-65]=20hotfix:=20=ED=9A=8C=EC=9B=90=20?= =?UTF-8?q?=EB=93=B1=EB=A1=9D/=EB=A1=9C=EA=B7=B8=EC=9D=B8=20=EA=B2=BD?= =?UTF-8?q?=EB=A1=9C=20=ED=95=84=ED=84=B0=20=EB=AC=B4=EC=8B=9C=20=EB=B0=8F?= =?UTF-8?q?=20=EA=B2=BD=EB=A1=9C=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../jtoon/member/presentation/MemberController.java | 2 +- ...SecurityConfiguration.java => SecurityConfig.java} | 11 ++++++++++- 2 files changed, 11 insertions(+), 2 deletions(-) rename module-application/src/main/java/com/devtoon/jtoon/security/config/{WebSecurityConfiguration.java => SecurityConfig.java} (89%) diff --git a/module-application/src/main/java/com/devtoon/jtoon/member/presentation/MemberController.java b/module-application/src/main/java/com/devtoon/jtoon/member/presentation/MemberController.java index d74ce7d0..c9d03122 100644 --- a/module-application/src/main/java/com/devtoon/jtoon/member/presentation/MemberController.java +++ b/module-application/src/main/java/com/devtoon/jtoon/member/presentation/MemberController.java @@ -22,7 +22,7 @@ public class MemberController { private final MemberService memberService; - @PostMapping + @PostMapping("/sign-up") @ResponseStatus(HttpStatus.CREATED) public void signUp(@RequestBody @Valid SignUpReq signUpReq) { memberService.createMember(signUpReq); diff --git a/module-application/src/main/java/com/devtoon/jtoon/security/config/WebSecurityConfiguration.java b/module-application/src/main/java/com/devtoon/jtoon/security/config/SecurityConfig.java similarity index 89% rename from module-application/src/main/java/com/devtoon/jtoon/security/config/WebSecurityConfiguration.java rename to module-application/src/main/java/com/devtoon/jtoon/security/config/SecurityConfig.java index 2c49feed..0a650da6 100644 --- a/module-application/src/main/java/com/devtoon/jtoon/security/config/WebSecurityConfiguration.java +++ b/module-application/src/main/java/com/devtoon/jtoon/security/config/SecurityConfig.java @@ -4,6 +4,7 @@ import org.springframework.context.annotation.Configuration; import org.springframework.security.config.annotation.web.builders.HttpSecurity; import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity; +import org.springframework.security.config.annotation.web.configuration.WebSecurityCustomizer; import org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer; import org.springframework.security.config.http.SessionCreationPolicy; import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder; @@ -17,12 +18,13 @@ import com.devtoon.jtoon.security.filter.JwtAuthenticationFilter; import com.devtoon.jtoon.security.handler.OAuth2FailureHandler; import com.devtoon.jtoon.security.handler.OAuth2SuccessHandler; + import lombok.RequiredArgsConstructor; @Configuration @RequiredArgsConstructor @EnableWebSecurity -public class WebSecurityConfiguration { +public class SecurityConfig { private final HandlerExceptionResolver handlerExceptionResolver; private final JwtService jwtService; @@ -35,6 +37,13 @@ public PasswordEncoder encoder() { return new BCryptPasswordEncoder(); } + @Bean + public WebSecurityCustomizer webSecurityCustomizer() { + return web -> web.ignoring() + .requestMatchers("/members/sign-up") + .requestMatchers("/login"); + } + @Bean public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Exception { http