
CVE-2026-34040의 실험실 재현: 초대형(>1MB) 요청 본문을 사용하여 Docker/Moby AuthZ 플러그인을 우회하고 호스트 액세스 권한이 있는 특권 컨테이너를 생성합니다.
KO: Docker(Moby)의 인가(AuthZ) 플러그인을 1MB를 초과하는 요청 본문으로 우회하는 취약점의 실습용 재현 프로젝트입니다. EN: A lab reproduction of a vulnerability that bypasses Docker (Moby) authorization (AuthZ) plugins using an oversized (>1MB) request body.
| Item | Value |
|---|---|
| CVE | CVE-2026-34040 |
| CVSS 3.1 | 8.8 (High) — CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
| CWE | CWE-288 (Authentication Bypass Using an Alternate Path or Channel), CWE-863 (Incorrect Authorization) |
| Affected | moby/moby < 29.3.1, docker/docker < 29.3.1, moby/moby/v2 < 2.0.0-beta.8 |
| Fixed in | 29.3.1, 2.0.0-beta.8 |
| Root cause | Incomplete fix for CVE-2024-41110 |
| Patch commit | moby/moby@e89edb1 |
KO: 공식 CVSS 벡터는
AV:L(로컬)입니다. 즉 평가 기준은 로컬 Docker API 접근(주로/var/run/docker.sock)을 가진 낮은 권한 사용자입니다. 이 PoC도 로컬 UNIX 소켓만 사용합니다. EN: The official CVSS vector isAV:L(Local). The rated scenario is a low-privileged user with local Docker API access (typically/var/run/docker.sock). This PoC uses the local UNIX socket only.
KO:
- 정상 크기 요청의 privileged 컨테이너 생성은 AuthZ 플러그인이 차단한다 (HTTP 403).
- 1MB를 초과하는 padding을 포함한 동일 요청은 AuthZ 검사를 우회한다.
- 우회된 요청은 Docker Daemon 처리 단계까지 도달하여 privileged 컨테이너를 만든다.
- privileged + 호스트 bind mount 조합으로 호스트 파일 읽기와 호스트 명령 실행을 데모할 수 있다.
EN:
- A normal-sized privileged container-create request is blocked by the AuthZ plugin (HTTP 403).
- The same request padded beyond 1MB bypasses the AuthZ check.
- The bypassed request reaches the Docker daemon and creates a privileged container.
- With privileged + host bind mount, host file read and host command execution can be demonstrated.
KO: 이 CVE 자체는 직접
/etc/shadow를 읽거나 RCE를 수행하지 않습니다. AuthZ가 막아야 할 Docker API 요청을 우회하는 것이 취약점의 본질이고, 이후 단계(파일 읽기, chroot, 명령 실행)는 Docker/Linux의 정상 기능을 악용하는 영향 데모입니다. EN: The CVE itself does not read/etc/shadowor perform RCE directly. The vulnerability is the bypass of a Docker API request that AuthZ should block; the later steps (file read, chroot, command execution) are impact demos that abuse normal Docker/Linux features.
.
├── README.md
├── poc.py # Working PoC (local UNIX socket only)
├── requirements.txt # Python standard library only
├── LICENSE
├── lab/
│ ├── authz.rego # OPA policy: blocks privileged + host-root bind
│ └── daemon.json # Registers the AuthZ plugin
└── docs/
├── concepts.md # 개념 / Concepts
├── lab-setup.md # 환경 구성 / Lab setup
├── how-it-works.md # 동작 원리 / How it works (source-level)
├── usage.md # 사용법 / Usage
├── troubleshooting.md # 문제 해결 / Troubleshooting
└── references.md # 참고 / References
KO: 이 PoC가 의미 있게 동작하려면 아래 조건이 모두 필요합니다. EN: All of the following are required for this PoC to be meaningful.
# 1) Pull the image used by the PoC
sudo docker pull alpine
# 2) Run the non-destructive bypass check
sudo python3 poc.py --mode check
Expected on a vulnerable target / 취약 대상에서의 기대 결과:
small request -> HTTP 403 (AuthZ blocks)
oversized request -> HTTP 201 or HTTP 404 (AuthZ bypassed; daemon processed it)
KO:
404 No such image도 우회 증거입니다. AuthZ가 차단(403)하지 않고 Docker Daemon의 이미지 확인 단계까지 도달했다는 뜻입니다. 발표/데모에서는 혼동을 줄이기 위해 미리alpine을 pull 하세요. EN: A404 No such imageis still evidence of bypass — the request passed AuthZ (not 403) and reached the daemon's image lookup. Pullalpinebeforehand to avoid confusion in a demo.
전체 사용법은 docs/usage.md 참고. / See docs/usage.md for full usage.
KO: 본인 소유 또는 명시적으로 허가받은 격리된 실습 환경에서만 사용하세요. 원격 Docker API, 제3자 서버, 운영 환경, 인터넷에 노출된 Docker endpoint를 대상으로 실행하지 마세요. 영향 데모 모드(
rce-proof,host-command,reverse-shell-local)는 명시적 확인 플래그가 있어야만 동작합니다. EN: Use only in an isolated lab you own or are explicitly authorized to test. Do not run against remote Docker APIs, third-party servers, production, or internet-exposed Docker endpoints. The impact-demo modes (rce-proof,host-command,reverse-shell-local) require an explicit confirmation flag.
See docs/references.md. / docs/references.md 참고.
| Condition | Required | Reason |
|---|
Local Docker API access (/var/run/docker.sock) | Yes | The PoC sends requests to the socket |
| AuthZ plugin enabled with a body-inspecting policy | Yes | The bypass target is the AuthZ check |
| Docker/Moby < 29.3.1 | Yes | Patched versions reject oversized bodies |
alpine image present locally | Recommended | Otherwise create returns 404 No such image |