🇰🇷 한글 설명
wolfictl의 git 인증 문제로 인해 GITHUB_TOKEN 환경변수가 github.com이 아닌 다른 원격 저장소로 전송될 수 있습니다. git-checkout 지시문이나 wolfictl update 명령어 실행 시 GITHUB_TOKEN이 설정되어 있으면 악의적인 git 저장소에 토큰이 노출될 수 있습니다. 버전 0.16.10에서 패치되었습니다.
💡 쉬운 설명
wolfictl 도구가 당신의 GitHub 접근 권한을 신뢰하지 않은 서버로 보낼 수 있는 문제입니다. 악의적인 git 저장소를 사용하면 당신의 GitHub 계정이 해킹당할 수 있습니다.
🇺🇸 원문 (English)
wolfictl is a command line tool for working with Wolfi. A git authentication issue in versions prior to 0.16.10 allows a local user’s GitHub token to be sent to remote servers other than `github.com`. Most git-dependent functionality in wolfictl relies on its own `git` package, which contains centralized logic for implementing interactions with git repositories. Some of this functionality requires authentication in order to access private repositories. A central function `GetGitAuth` looks for a GitHub token in the environment variable `GITHUB_TOKEN` and returns it as an HTTP basic auth object to be used with the `github.com/go-git/go-git/v5` library. Most callers (direct or indirect) of `GetGitAuth` use the token to authenticate to github.com only; however, in some cases callers were passing this authentication without checking that the remote git repository was hosted on github.com. This behavior has existed in one form or another since commit 0d06e1578300327c212dda26a5ab31d09352b9d0 - committed January 25, 2023. This impacts anyone who ran the `wolfictl check update` commands with a Melange configuration that included a `git-checkout` directive step that referenced a git repository not hosted on github.com. This also impacts anyone who ran `wolfictl update <url>` with a remote URL outside of github.com. Additionally, these subcommands must have run with the `GITHUB_TOKEN` environment variable set to a valid GitHub token. Users should upgrade to version 0.16.10 to receive a patch.
📍 영향받는 시스템
wolfictl 버전 0.16.10 이전 모든 버전
⚔️ 공격 벡터
GITHUB_TOKEN 환경변수가 설정된 상태에서 github.com이 아닌 다른 git 저장소를 wolfictl check update나 wolfictl update 명령어에서 참조할 때 발생
🛡️ 대응 방법
wolfictl을 0.16.10 이상으로 업그레이드
🔧 검증 코드
표시된 버전이 0.16.10 이상이면 패치된 상태, 그 이하면 취약한 상태입니다
wolfictl --version 2>/dev/null | grep -oE '[0-9]+\.[0-9]+\.[0-9]+'