Skip to content

Commit

Permalink
[BE] 조약조건 추가 및 쿠키 명시적 삭제 제거 (#725)
Browse files Browse the repository at this point in the history
* [BE] 세션 사용을 쿠키로 대체 (#706)

* feat: 스켈줄러 매치 에러 보완

* fix: 로그인 확인 로직 필터링 제외

* feat: 세션 사용 필터 삭제

* feat: 세션을 쿠키로 대체

---------

Co-authored-by: lemone <[email protected]>

* [BE] 쿠키 도메인 설정 통일화  (#712)

* feat: 스켈줄러 매치 에러 보완

* fix: 로그인 확인 로직 필터링 제외

* feat: 세션 사용 필터 삭제

* feat: 세션을 쿠키로 대체

* feat: 쿠키 도메인 설정 통일

* test: 상태 코드 수정

* [BE] 쿠키 도메인 서브 도메인까지 허용하도록 수정  (#718)

* [BE] 운영서버 배포  (#690)

* [BE] 데이터소스 관련 환경변수 분리 (#663) (#664)

* refactor: todo patch시 pair_room_id 사라지는 문제 해결

* fix: jwt NPE 핸들링

* fix: Sgin in NPE 핸들링

* fix: alllow header에 content tpye 추가

* fix: Timer update 테스트 오류 수정

* chore: 로그 심기

* fix: preflight 옵션 filter 제외

* chore: 로그 뽑기

* fix: 로그인 체크 필터링  제거

* feat: 데이터 소스 분리

* chore: 데이터 소스 CD/TEST 분리

* chore: 데이터 소스 분리로 인한 컴포즈 변경

* chore: 데이터 소스 분리로 인한 컴포즈 변경

* chore: 데이터 소스 분리로 인한 컴포즈 변경1

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: Sunguk Yang (Kelly) <[email protected]>

* chore: be cd script 변경

* feat: 엑세스 코드 생성 전략 수정 (#670)

* feat: 엑세스 코드 생성 전략 수정 (#670) (#671)

* Be/feature/pray (#672)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* Be/dev (#673)

* feat: 엑세스 코드 생성 전략 수정 (#670)

* Be/feature/pray (#672)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* Be/feature/pray (#674)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* refactor: member entity accessToken 컬럼 크기를 1000으로 변경

* refactor: pairroom entity accessToken 컬럼 크기를 1000으로 변경

* fix: entity 설정 원복

* feat: 엑세스 코드 생성 전략 수정

* feat: 스켈줄러 매치 에러 보완 (#678)

* [BE] 스케줄러 로깅 문제 보완  (#679)

* feat: 엑세스 코드 생성 전략 수정 (#670)

* Be/feature/pray (#672)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* feat: 스켈줄러 매치 에러 보완 (#678)

* style: 로그 제거

* refactor: check 시 쿠키 값 필수 조건 해제

* [BE] TEST DB 소스 변경 (#686) (#687)

* [BE] 테스트 서버 배포 (#689)

* style: 로그 제거

* [BE] TEST DB 소스 변경 (#686)

* refactor: stop 및 pause 메서드 리팩터링

* feat: 타이머가 실행 중에 다시 실행될 수 없게 조건문 추가

* feat: 타이머가 실행 중일 때만 종료할 수 있게 조건 추가

* refactor: TimerEntity 찾을 때 pairRoom id 대신 PairRoomEntity로 넘기기

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: lemone <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: lemone <[email protected]>

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: Sunguk Yang (Kelly) <[email protected]>
Co-authored-by: lemone <[email protected]>
Co-authored-by: lemone <[email protected]>

* [BE] 운영서버 배포 (#694)

* [BE] 데이터소스 관련 환경변수 분리 (#663) (#664)

* refactor: todo patch시 pair_room_id 사라지는 문제 해결

* fix: jwt NPE 핸들링

* fix: Sgin in NPE 핸들링

* fix: alllow header에 content tpye 추가

* fix: Timer update 테스트 오류 수정

* chore: 로그 심기

* fix: preflight 옵션 filter 제외

* chore: 로그 뽑기

* fix: 로그인 체크 필터링  제거

* feat: 데이터 소스 분리

* chore: 데이터 소스 CD/TEST 분리

* chore: 데이터 소스 분리로 인한 컴포즈 변경

* chore: 데이터 소스 분리로 인한 컴포즈 변경

* chore: 데이터 소스 분리로 인한 컴포즈 변경1

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: Sunguk Yang (Kelly) <[email protected]>

* chore: be cd script 변경

* feat: 엑세스 코드 생성 전략 수정 (#670)

* feat: 엑세스 코드 생성 전략 수정 (#670) (#671)

* Be/feature/pray (#672)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* Be/dev (#673)

* feat: 엑세스 코드 생성 전략 수정 (#670)

* Be/feature/pray (#672)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* Be/feature/pray (#674)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* refactor: member entity accessToken 컬럼 크기를 1000으로 변경

* refactor: pairroom entity accessToken 컬럼 크기를 1000으로 변경

* fix: entity 설정 원복

* feat: 엑세스 코드 생성 전략 수정

* feat: 스켈줄러 매치 에러 보완 (#678)

* [BE] 스케줄러 로깅 문제 보완  (#679)

* feat: 엑세스 코드 생성 전략 수정 (#670)

* Be/feature/pray (#672)

* feat: 엑세스 코드 생성 전략 수정

* feat: 엑세스 코드 생성 전략 수정

* feat: 스켈줄러 매치 에러 보완 (#678)

* style: 로그 제거

* refactor: check 시 쿠키 값 필수 조건 해제

* [BE] TEST DB 소스 변경 (#686) (#687)

* [BE] 테스트 서버 배포 (#689)

* style: 로그 제거

* [BE] TEST DB 소스 변경 (#686)

* refactor: stop 및 pause 메서드 리팩터링

* feat: 타이머가 실행 중에 다시 실행될 수 없게 조건문 추가

* feat: 타이머가 실행 중일 때만 종료할 수 있게 조건 추가

* refactor: TimerEntity 찾을 때 pairRoom id 대신 PairRoomEntity로 넘기기

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: lemone <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: lemone <[email protected]>

* [BE] 테스트 서버 배포 (#693)

* style: 로그 제거

* [BE] TEST DB 소스 변경 (#686)

* refactor: stop 및 pause 메서드 리팩터링

* feat: 타이머가 실행 중에 다시 실행될 수 없게 조건문 추가

* feat: 타이머가 실행 중일 때만 종료할 수 있게 조건 추가

* refactor: TimerEntity 찾을 때 pairRoom id 대신 PairRoomEntity로 넘기기

* [BE] 클라이언트 에러 로그 없애기 (#692)

* feat: 스켈줄러 매치 에러 보완

* fix: 로그인 확인 로직 필터링 제외

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: lemone <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: lemone <[email protected]>

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: Sunguk Yang (Kelly) <[email protected]>
Co-authored-by: lemone <[email protected]>
Co-authored-by: lemone <[email protected]>

* [BE] 테스트 서버 배포 (#713)

* [BE] 세션 사용을 쿠키로 대체 (#706)

* feat: 스켈줄러 매치 에러 보완

* fix: 로그인 확인 로직 필터링 제외

* feat: 세션 사용 필터 삭제

* feat: 세션을 쿠키로 대체

---------

Co-authored-by: lemone <[email protected]>

* [BE] 쿠키 도메인 설정 통일화  (#712)

* feat: 스켈줄러 매치 에러 보완

* fix: 로그인 확인 로직 필터링 제외

* feat: 세션 사용 필터 삭제

* feat: 세션을 쿠키로 대체

* feat: 쿠키 도메인 설정 통일

* test: 상태 코드 수정

---------

Co-authored-by: Sunguk Yang (Kelly) <[email protected]>
Co-authored-by: lemone <[email protected]>

* fix: 쿠키 서브 도메인까지 허용하도록 수정

* refactor: 개행 삭제

---------

Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: Sunguk Yang (Kelly) <[email protected]>
Co-authored-by: lemone <[email protected]>
Co-authored-by: lemone <[email protected]>

* [BE] 멤버 테이블 제약조건 추가 (#724)

* fix: 멤버 테이블 제약조건 추가

* fix: 임시 쿠키 명시적 만료 제거

---------

Co-authored-by: lemone <[email protected]>
Co-authored-by: reddevilmidzy <[email protected]>
Co-authored-by: Redddy <[email protected]>
Co-authored-by: Sunguk Yang (Kelly) <[email protected]>
Co-authored-by: lemone <[email protected]>
  • Loading branch information
6 people authored Oct 8, 2024
1 parent ce2534f commit 0cc1a4f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
import site.coduo.member.service.AuthService;
import site.coduo.member.service.MemberService;
import site.coduo.member.service.dto.SignInServiceResponse;
import site.coduo.member.service.dto.auth.AccessTokenCookie;
import site.coduo.member.service.dto.auth.SignInCheckResponse;
import site.coduo.member.service.dto.auth.SignInCookie;
import site.coduo.member.service.dto.auth.SignInWebResponse;
Expand All @@ -38,7 +37,6 @@ public class AuthController implements AuthControllerDocs {
@GetMapping("/sign-out")
public ResponseEntity<Void> signOut(@CookieValue(name = SIGN_IN_COOKIE_NAME) final String signInToken) {
final ResponseCookie expire = SignInCookie.expire(PRODUCT_DOMAIN);

return ResponseEntity.ok()
.header(HttpHeaders.SET_COOKIE, expire.toString())
.build();
Expand All @@ -61,10 +59,9 @@ public ResponseEntity<SignInWebResponse> signInCallback(
) {
final SignInServiceResponse serviceResponse = authService.createSignInToken(encryptedAccessToken);
final ResponseCookie signInCookie = new SignInCookie(serviceResponse.token()).generate(PRODUCT_DOMAIN);
final ResponseCookie expireTemporaryAccessToken = AccessTokenCookie.expire(PRODUCT_DOMAIN);

return ResponseEntity.ok()
.header(HttpHeaders.SET_COOKIE, signInCookie.toString(), expireTemporaryAccessToken.toString())
.header(HttpHeaders.SET_COOKIE, signInCookie.toString())
.body(SignInWebResponse.of(serviceResponse));
}

Expand Down
4 changes: 2 additions & 2 deletions backend/src/main/java/site/coduo/member/domain/Member.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ public class Member extends BaseTimeEntity {
@Column(name = "ID", nullable = false)
private Long id;

@Column(name = "ACCESS_TOKEN", nullable = false)
@Column(name = "ACCESS_TOKEN", nullable = false, unique = true)
private String accessToken;

@Column(name = "PROVIDER_LOGIN_ID", nullable = false)
private String loginId;

@Column(name = "PROVIDER_USER_ID", nullable = false)
@Column(name = "PROVIDER_USER_ID", nullable = false, unique = true)
private String userId;

@Column(name = "PROFILE_IMAGE")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ public static ResponseCookie expire(final String domain) {
public ResponseCookie generate(final String domain) {
return ResponseCookie.from(TEMPORARY_ACCESS_TOKEN_COOKIE_NAME)
.value(accessToken)
.maxAge(Duration.ofMinutes(10))
.httpOnly(true)
.secure(true)
.domain(domain)
Expand Down

0 comments on commit 0cc1a4f

Please sign in to comment.