Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2026-31431-poc — An adapted version of the copy fail exploit to use parameters instead of dropping you into a root shell | Kitploit
Tools/GitHubGitHub/dennisdgr/cve-2026-31431-poc
Privilege EscalationExploit FrameworksVulnerability AnalysisExploitationBinary Exploitation
GitHubdennisdgr/cve-2026-31431-poc

CVE-2026-31431-poc

An adapted version of the copy fail exploit to use parameters instead of dropping you into a root shell

View Repository
13 months agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

Copy Fail Command PoC Wrapper

A small modified proof-of-concept wrapper for Copy Fail / CVE-2026-31431 that allows passing a custom command from the terminal instead of always launching an interactive root shell so it can be ran in an none interactive environment such as a web shell.

This project is based on the public Copy Fail research and PoC.


⚠️ Disclaimer

This repository is provided for educational, research, and defensive validation purposes only.

Only run this code on systems you own or have explicit permission to test.

This PoC may corrupt the in-memory page cache of a target binary such as /usr/bin/su.

Do not run this on production systems.


Background

Copy Fail, tracked as CVE-2026-31431, is a Linux kernel local privilege-escalation vulnerability involving the kernel crypto API, specifically the AF_ALG / algif_aead path.

At a high level, the bug can allow controlled writes into the page cache of readable files. Public demonstrations commonly target SUID binaries such as /usr/bin/su to gain root privileges.

This repository does not claim discovery of the vulnerability. It is a small modification/wrapper around the public PoC behavior to support a configurable command payload.


Credits

Full credit for the original research, vulnerability disclosure, and public PoC goes to the original authors and researchers:

  • THEORI Copy Fail PoC:
    https://github.com/theori-io/copy-fail-CVE-2026-31431

  • Official Copy Fail website:
    https://copy.fail/

  • Xint technical write-up:
    https://xint.io/blog/copy-fail-linux-distributions

Please read and reference the original material for the real vulnerability analysis.


What This Version Changes

The original public PoC is extremely compact and uses a fixed embedded payload.

This version adds:

  • command-line argument support
  • configurable command execution
  • clearer output while testing

Requirements

The target system must expose the required Linux crypto socket interfaces.

The PoC depends on:

  • Linux
  • Python 3
  • AF_ALG support
  • algif_aead support
  • vulnerable kernel version/configuration
  • readable target SUID binary, usually /usr/bin/su

Usage

Default verification:

root@kitploit:~
python3 CVE-2026-31431.py

This attempts to execute:

root@kitploit:~
id > /tmp/id.txt

Then verify:

root@kitploit:~
cat /tmp/id.txt

Custom command:

root@kitploit:~
python3 CVE-2026-31431.py -c 'ls -la /root'

Restoring /usr/bin/su

If you tested against /usr/bin/su, restore it after testing.

On Debian/Ubuntu:

root@kitploit:~
sudo apt install --reinstall util-linux

Notes

This repository is only a small adaptation of the public Copy Fail PoC behavior. The vulnerability research, root cause analysis, and original exploitation technique belong to the original researchers.

Again, props and credit to:

  • https://github.com/theori-io/copy-fail-CVE-2026-31431
  • https://copy.fail/
  • https://xint.io/blog/copy-fail-linux-distributions
Download Tool