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-46331 — CVE-2026-46331 act_pedit page-cache corruption exploit, with Alpine PIE fix | Kitploit
Tools/GitHubGitHub/yanxinwu946/cve-2026-46331
Privilege EscalationExploit FrameworksVulnerability AnalysisExploitationShellcodePayload DevelopmentContainer EscapeBinary Exploitation
GitHubyanxinwu946/cve-2026-46331

CVE-2026-46331

CVE-2026-46331 act_pedit page-cache corruption exploit, with Alpine PIE fix

View Repository
441 month 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

PACKET_EDIT_MEME - CVE-2026-46331

net/sched act_pedit partial-COW page-cache corruption (culprit 899ee91156e5, present v5.18 .. fixed v7.1-rc7). packet_edit_meme.c turns it into unprivileged local root: a userns CAP_NET_ADMIN child overwrites the cached ELF metadata of a setuid-root binary with setgid(0)+setuid(0)+execve("/bin/sh") shellcode.

root@kitploit:~
make
./packet_edit_meme
./packet_edit_meme --ubuntu   # AppArmor-gated Ubuntu: aa-exec bypass first

Targets

DistroKernelFlagResult
RHEL 10.06.12.0(none)ROOT
Debian 13 trixie6.12.90+deb13.1(none)ROOT
Ubuntu 24.04.46.17.0-22--ubuntuROOT
Alpine edge7.0.10-0-stable(none)ROOT

Alpine PIE fix

Alpine Linux (musl) compiles PIE executables where the executable PT_LOAD segment starts at file offset ≥ 0x1000 — beyond the pedit TCP header offset limit of 511 bytes. The ELF header and program headers occupy the first read-only PT_LOAD (file offset 0). This adapted exploit:

  1. Makes page 0 executable by adding PF_X to the first PT_LOAD's p_flags field at file offset 0xB4 (phdr[2] + 4).

  2. Splits the shellcode to avoid corrupting critical LOAD program headers:

    • e_entry → 0x28 (an e_shoff field the kernel does not check at exec time).
    • Trampoline at file offset 0x28: a 5-byte jmp 0x1C8.
    • Shellcode at file offset 0x1C8, overwriting PT_NOTE program headers that the kernel ignores during exec.
  3. Auto-discovers the target at runtime via find / -xdev -type f -perm -4000 -user root instead of hardcoding paths. The first world-readable setuid-root ELF binary found is used — Alpine's /bin/su (-> /bin/bbsuid, ) is skipped automatically because it cannot be opened.

Ubuntu AppArmor gate

Ubuntu denies unconfined unprivileged userns via two sysctls:

root@kitploit:~
kernel.apparmor_restrict_unprivileged_userns       # denies unconfined userns creation
kernel.apparmor_restrict_unprivileged_unconfined   # forces unconfined change_profile to STACK,
                                                   # so an aa-exec permissive profile cannot
                                                   # shed the userns restriction

--ubuntu re-execs via aa-exec -p {trinity,chrome,flatpak} (profiles that carry a userns, rule).

Ubuntuusernsunconfinedaa-exec bypass
24.04.410WORKS
26.0411CLOSED

Build dependencies

A static x86_64-linux-gnu cross-compiler:

root@kitploit:~
# Debian / Ubuntu
apt install gcc-x86-64-linux-gnu

# Alpine
apk add gcc musl-dev
Download Tool
---s--x--x