Skip to content

feat(mcp): Phase 3 — auth preflight#362

Open
erishforG wants to merge 1 commit into
release/1.0from
feat/auto-mcp-auth-phase3
Open

feat(mcp): Phase 3 — auth preflight#362
erishforG wants to merge 1 commit into
release/1.0from
feat/auto-mcp-auth-phase3

Conversation

@erishforG

Copy link
Copy Markdown
Owner

무엇

MCP tools/call dispatch boundary에 GitHub 필수 도구용 auth preflight를 추가했습니다.

Refs #294. v1.0 MCP auth/sandbox 트랙의 다음 Phase로, GitHub-backed tool이 토큰 없이 실제 handler로 넘어가기 전에 표준 MCP error envelope를 반환하도록 계약을 고정합니다.

변경

  • requires_github 도구가 delegated GitHub token 없이 호출되면 AUTH_REQUIRED MCP tool error 반환
  • error detail에 필요한 scope intent 포함
  • 토큰이 있으면 기존 dispatch path로 진행되는 단위 테스트 추가
  • stdio smoke fixture에 auth-required recording case 추가

다음 Phase 힌트

  • delegated token에 scope metadata를 붙여 INSUFFICIENT_SCOPE preflight를 구현
  • repo path sandbox preflight를 tools/call arguments parsing 직후에 추가

리스크

Low. 변경은 src/mcp/tests/mcp/ fixture에만 제한되며, 기존 CLI surface와 git/worktree 로직은 건드리지 않았습니다.

롤백

이 PR 커밋을 revert하면 기존 tools/call dispatch behavior로 돌아갑니다.

Test plan

  • cargo build --quiet
  • cargo test --quiet
  • cargo fmt --check
  • cargo clippy --all-targets -- -D warnings

@erishforG

Refs #294

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@erishforG erishforG added the auto-improvement Daily auto-generated improvement PR/issue label Jun 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-improvement Daily auto-generated improvement PR/issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant