Repository navigation
fix: PR 일괄 승인·병합 요청에서 repo_owner를 필수로 처리 - #71
Open
parkhojeong wants to merge 2 commits into
Open
parkhojeong wants to merge 2 commits into
parkhojeong wants to merge 2 commits into
Conversation
parkhojeong
marked this pull request as ready for review
November 22, 2026 02:29
DaleSeo
reviewed
Nov 22, 2026
DaleSeo
left a comment
Member
There was a problem hiding this comment.
호정님, 포크 실행 로그까지 따라가서 원인을 깔끔하게 정리해 주셔서 감사해요. 작은 제안 드렸습니다.
| try { | ||
| const data = await request.json(); | ||
| const repoOwner = data.repo_owner || "DaleStudy"; | ||
| const repoOwner = data.repo_owner; |
Member
There was a problem hiding this comment.
요청 본문을 신뢰하는 대신 GitHub Actions OIDC 토큰을 검증하고, 토큰의 repository_owner 클레임으로 소유자를 확인하는 건 어떨까요?
Suggested change
| const repoOwner = data.repo_owner; | |
| const repoOwner = claims.repository_owner; |
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.
문제
Worker가
repo_owner가 빠진 일괄 승인·병합 요청도 DaleStudy 저장소에 대한 요청으로 처리합니다. 발생 경위원인
/approve-prs와/merge-prs의 공통 요청 파서가 조직을 검사하기 전에 누락된 소유자를DaleStudy로 채웁니다. 이 때문에 소유자를 생략한 요청도 조직 검사를 통과합니다.해결
repo_owner의 기본값을 제거합니다. 소유자가 누락되면 400을 반환하고,DaleStudy이외의 값은 기존 조직 검사에서 403으로 거절합니다.소유자 누락, 포크 소유자,
DaleStudy세 경우를 검증했고 전체 테스트 166개가 통과했습니다. 원본 워크플로가repo_owner를 보내도록 변경한 뒤 이 Worker를 배포합니다. 먼저 반영할 워크플로 PR