🔍 CVE-2024-21583

4.1
CVSS Score
MEDIUM
2024-07-19
2026-04-15 00:35
✅ 완료

🇰🇷 한글 설명

Gitpod의 여러 컴포넌트에서 세션 쿠키 '_gitpod_io_jwt2_'가 __Host- 접두사를 포함하지 않아 발생하는 Cookie Tossing 취약점입니다. 서브도메인을 제어하는 공격자가 쿠키 값을 변조하여 피해자의 작업을 공격자의 세션으로 실행되게 할 수 있습니다. main-gha.27122 버전 이상으로 업그레이드 필요합니다.

💡 쉬운 설명

Gitpod의 로그인 정보를 담은 쿠키가 보호되지 않아서, 공격자가 쉽게 위조할 수 있습니다. 공격자가 당신의 GitHub 계정을 자신의 Gitpod으로 연결하는 등의 행동을 대신 실행할 수 있습니다.

🇺🇸 원문 (English)

Versions of the package github.com/gitpod-io/gitpod/components/server/go/pkg/lib before main-gha.27122; versions of the package github.com/gitpod-io/gitpod/components/ws-proxy/pkg/proxy before main-gha.27122; versions of the package github.com/gitpod-io/gitpod/install/installer/pkg/components/auth before main-gha.27122; versions of the package github.com/gitpod-io/gitpod/install/installer/pkg/components/public-api-server before main-gha.27122; versions of the package github.com/gitpod-io/gitpod/install/installer/pkg/components/server before main-gha.27122; versions of the package @gitpod/gitpod-protocol before 0.1.5-main-gha.27122 are vulnerable to Cookie Tossing due to a missing __Host- prefix on the _gitpod_io_jwt2_ session cookie. This allows an adversary who controls a subdomain to set the value of the cookie on the Gitpod control plane, which can be assigned to an attacker’s own JWT so that specific actions taken by the victim (such as connecting a new Github organization) are actioned by the attackers session.

📍 영향받는 시스템

Gitpod server, ws-proxy, auth, public-api-server 컴포넌트; @gitpod/gitpod-protocol npm 패키지; 모두 main-gha.27122 버전 이전

⚔️ 공격 벡터

서브도메인 제어 권한이 있는 공격자가 __Host- 접두사가 없는 _gitpod_io_jwt2_ 쿠키를 변조하여 피해자의 작업을 가로챔

🛡️ 대응 방법

모든 Gitpod 컴포넌트 및 gitpod-protocol 패키지를 main-gha.27122 이상으로 즉시 업그레이드

🔧 검증 코드

명령어 실행 후 'Patched'가 출력되면 안전, 'Vulnerable'이 출력되거나 아무것도 나오지 않으면 __Host- 접두사가 없어 취약점이 있는 상태입니다.

Shell / Script
curl -sI https://gitpod.instance.domain 2>/dev/null | grep -i 'set-cookie' | grep '_gitpod_io_jwt2_' | grep -q '__Host-' && echo 'Patched' || echo 'Vulnerable'

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:N/A:N

💻 영향받는 소프트웨어

Git