fix: 애플(iCloud) 캘린더 연동을 JWT+쿠키 방식으로 재정렬 (#54) - #55
Merged
Conversation
애플 연동만 앱이 채택하지 않은 Supabase Auth 중심 설계 위에 구현되어 일반 로그인(커스텀 JWT) 유저는 connect에서 401, profiles FK 미충족으로 저장 실패했다. 구글/네이버와 동일하게 HttpOnly 쿠키 저장으로 전환한다. - src/lib/caldav/connection-cookie.ts 신설: 앱 전용 암호를 AES-256-GCM으로 암호화해 icloud_connection 쿠키에 저장/조회/삭제 - icloud 라우트 5개(connect/calendars/events·query/create/disconnect)에서 requireSession+Supabase 제거, 쿠키 기반으로 전환 - events 라우트 계약 calendarId(UUID) → calendarUrl로 변경 - calendar/status: Supabase/세션 게이트 제거, 쿠키 존재로 판단 (구글 분기도 빈 테이블 조회로 깨져 있어 함께 수정) - .env.example에 ENCRYPTION_SECRET 추가 (배포에 필수) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Caution Review failedPull request was closed or merged during review Summary by CodeRabbit릴리스 노트
WalkthroughSupabase 세션 의존을 제거하고 HttpOnly 쿠키 기반 저장으로 iCloud 캘린더 연동 전체를 재정렬. connection-cookie 모듈로 암호화된 인증정보 관리, 모든 API의 입력을 calendarUrl(https) 기반으로 변경, 상태/캘린더/이벤트 조회/생성 라우트 통합. ChangesiCloud CalDAV 쿠키 기반 저장 전환
🎯 2 (Simple) | ⏱️ ~12 minutes
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🚀 작업 내용 (What)
src/lib/caldav/connection-cookie.ts신설: 앱 전용 암호를 AES-256-GCM 암호화 후 쿠키 저장/조회/삭제requireSession+Supabase 제거 → 쿠키 기반 전환calendarId(UUID) →calendarUrl(호출부 없어 안전)calendar/status를 쿠키 조회로 전환 (구글 분기도 빈 테이블 조회로 깨져 있어 함께 수정).env.example에ENCRYPTION_SECRET추가📣 핵심 변경 이유 (Why)
profilesFK 위반으로 동작 불가였음ENCRYPTION_SECRET(64 hex) 환경변수 등록 필수. 없으면 연동 시 서버 오류 발생.🔗 관련 이슈 (Issue)
Close #54
🤖 Generated with Claude Code