🇰🇷 한글 설명
Argos core 패키지 6.2.1 미만 버전에서 CI 환경 변수인 GITHUB_HEAD_REF 또는 ARGOS_BRANCH를 통해 조작된 값이 명령 실행 함수에 전달되는 취약점이 존재합니다. 공격자가 풀 리퀘스트의 브랜치 이름에 쉘 메타문자를 포함할 경우, CI 러너의 권한으로 임의의 명령을 실행하여 비밀 정보를 탈취하거나 빌드 결과물을 변조할 수 있습니다.
💡 쉬운 설명
해커가 브랜치 이름을 특수하게 만들어 CI 시스템에 명령을 내릴 수 있는 보안 구멍이 발견되었습니다. 이를 통해 회사의 중요한 비밀번호를 훔치거나 프로그램 설치 파일을 몰래 바꿀 수 있습니다.
🇺🇸 원문 (English)
Argos JavaScript provides official Argos SDKs for JavaScript. Prior to Argos core package version 6.2.1, attacker-controlled CI branch or ref values from GITHUB_HEAD_REF or ARGOS_BRANCH can flow through config.branch and getMergeBaseCommitSha() when hasRemoteContentAccess is false. The gitFetch() and gitMergeBase() functions in packages/core/src/ci-environment/git.ts interpolate these values into execSync() command strings executed by /bin/sh -c, so shell metacharacters in a pull-request branch name can execute arbitrary commands with the Argos upload process privileges on the CI runner. Successful exploitation can expose CI secrets, alter build artifacts, or compromise the runner. This issue is fixed in Argos core package version 6.2.1.
📍 영향받는 시스템
Argos core package version < 6.2.1
⚔️ 공격 벡터
조작된 브랜치 이름을 포함한 Pull Request를 통해 CI 환경 변수를 주입하여 쉘 명령 실행
🛡️ 대응 방법
Argos core 패키지를 버전 6.2.1 이상으로 업데이트하십시오.
🔧 검증 코드
출력된 버전 번호가 6.2.1 미만이면 취약한 상태이며, 6.2.1 이상이면 안전합니다.
npm list @argos/core 2>/dev/null | grep -E '@argos/core@'