
LPE exploit for CVE-2026-31431 CopyFail. Compatible with Python 3.9.
The public Copy Fail exploit wasn't compaitble with python 3.9, this one is.
The original was modifed by replacing the unavailable os.splice() with a lightweight ctypes polyfill.
THIS SOFTWARE IS PROVIDED FOR EDUCATIONAL AND AUTHORIZED SECURITY RESEARCH PURPOSES ONLY.
By downloading, using, or viewing this code, you agree to the following:
You are solely responsible for your actions and any consequences that arise from using this code.
CVE-2026-31431 ("Copy Fail") is a logic flaw in the Linux kernel's authencesn cryptographic template (part of the AF_ALG interface). It allows any unprivileged local user to perform a controlled 4-byte write into the page cache of any readable file.
git clone https://github.com/w3llr00t3d/CVE-2026-31431-PoC.git
cd CVE-2026-31431-PoC
chmod +x poc.py
python3 poc.py