Kestrel
대시보드로 돌아가기
CVE-2026-59185HIGH· 8.5GHSA대응게시일: 2026. 09. 09.수정일: 2026. 09. 09.

Identrail Cross-tenant IDOR: Client-supplied GitHub App installation_id is bound to the caller's workspace without ownership verification

위협 신호 · CVSS · EPSS · KEV

정기 패치· 높은 악용 신호 없음
CVSS
8.5high

이론적 심각도 점수

EPSS

예측 데이터 없음

KEV
미등재

실측 악용 기록 없음

권장 대응 기한60일 이내CISA SSVC 기준

계획된 패치 주기 내 조치(60일 이내)

외부 노출· KEV 미등재 · 자동화 어려움 · 부분 영향 · 외부 노출

CVSS 벡터 · 메트릭

악용 경로
공격 벡터네트워크
공격 복잡도낮음
필요 권한낮음
사용자 상호작용불필요
범위변경
영향
기밀성 영향높음
무결성 영향낮음
가용성 영향없음
버전별 점수
CVSS 3.18.5HIGH
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:L/A:N

상세 설명

Summary

identrail's GitHub App connection-completion endpoint binds a fully client-supplied installation_id to the caller's workspace without verifying that the installation belongs to, or was installed by, the workspace that initiated the connect flow. identrail then mints a GitHub App installation access token for the supplied installation_id using the app's own JWT, so an authenticated tenant can link any other identrail customer's GitHub App installation into their own workspace and read that victim organization's private repositories.

Affected code (default-on path, no feature flag)

  • Route: internal/api/router.go:3590POST /v1/workspaces/:workspace_id/projects/:project_id/github/connect/complete. installation_id is read from the JSON body or the attacker-controlled X-GitHub-Installation-ID header (router.go:3582-3588).
  • Service: internal/api/github_connect.go:781 CompleteGitHubConnection. The state token IS rigorously bound to the caller's scope (github_connect.go:818: if stateRecord.TenantID != scope.TenantID || stateRecord.WorkspaceID != project.WorkspaceID || stateRecord.ProjectID != project.ProjectID { ... }), but the only check on installation_id is request.InstallationID <= 0 (:794). The raw client value is persisted as the workspace's connection (:840).
  • Cross-tenant read primitive: internal/connectors/github/repositories.go:39 ListInstallationRepositoriesinternal/connectors/github/app.go:170 mints a token via POST /app/installations/{installationId}/access_tokens signed with the App JWT, succeeding for any installation where identrail's app is installed.

The feature-flagged V2 path CompleteGitHubConnector (github_connect.go:447, default off) shares the gap and is additionally weaker (matches pending connector by state value alone with no caller-scope re-check); a single fix should cover both.

Intent proof

The code binds state to {TenantID, WorkspaceID, ProjectID} and re-verifies it at completion (:818), demonstrating it understands binding is required. The asymmetry — state bound, installation_id unbound — is the missed check.

Exploitation

  1. Attacker is any authenticated identrail tenant; they call StartGitHubConnection for their own workspace and receive a state.
  2. Attacker calls the completion route with {state: <their state>, installation_id: V} where V is a victim org's identrail GitHub App installation id (installation ids are not secret — they appear in post-install redirect URLs, webhook payloads, the org's GitHub App settings, and are enumerable integers).
  3. CompleteGitHubConnection accepts (state matches attacker scope), ListInstallationRepositories(V) mints a token for V and lists the victim org's private repos, and the connection is persisted under the attacker's workspace.
  4. Attacker now reads the victim org's private repository inventory and can drive posture scans/repo reads via their own workspace.

Impact: cross-tenant disclosure of another customer organization's private GitHub repositories and metadata.

Remediation

Bind installation_id with the same rigor as state: capture it from GitHub's signed post-install redirect (setup_url/callback_url) and pin it to the pending state at start time, and/or after minting verify the installation's account matches the org the initiating workspace is authorized for.

AI 심층 분석

공격 시나리오 · 재현 가능한 PoC 페이로드 · 즉시 적용 가능한 차단 패치를 한 번에 받아 보세요. 보안 운영팀이 그대로 점검·티켓팅에 쓸 수 있는 형태로 정리해 드립니다.