← Back to research

RESEARCH ARCHIVE / JUDOZI

Judozi

Modular Offensive Security Framework
Go 1.22+ Linux zero dependencies static binary modular architecture kernel privesc persistence recon interactive shell
23
kernel exploits
5.3MB
static binary
3
modules
0
dependencies

Overview

Judozi is a modular offensive security framework written in pure Go. It compiles to a single static binary with zero external dependencies, designed for environments where installing packages or toolchains is not an option. The framework uses a plugin-based module system where each module implements a common interface and is auto-discovered at startup.

The framework currently ships with three modules: kernel (automated privilege escalation), persistence (post-exploitation persistence mechanisms), and recon (system enumeration and reconnaissance). After successful privilege escalation, Judozi drops into an interactive shell session with full module access.

Architecture

Judozi Framework Architecture main.go CLI entry + interactive menu Module Registry auto-discovery | interface validation | dispatch kernel Privilege Escalation Kernel version detection Exploit DB matching (23 CVEs) Hybrid: compile or binary GCC-free fallback mode Auto mode: try all matching persistence Post Exploitation Requires root access Multiple techniques Install/remove modes Chains with kernel module Cleanup support recon Reconnaissance System enumeration Concurrent execution File output or stdout Timestamped reports Selective technique runs Interactive Shell

Every module implements the Module interface: Name(), Description(), Category(), and Run(args []string). The registry auto-discovers registered modules and dispatches execution based on CLI arguments or interactive selection. After a successful kernel exploit, the framework automatically transitions into an interactive shell with access to all modules.

Module Interface

// Every Judozi module implements this interface
type Module interface {
    Name()        string
    Description() string
    Category()    string
    Run(args []string) error
}

Kernel Module: Execution Pipeline

The kernel module is the primary attack module. It automates the entire privilege escalation workflow from kernel version detection through exploit selection, compilation or binary download, and execution.

Kernel Module: Exploit Execution Pipeline 1. Detect Read /proc/version Parse kernel version Detect architecture 2. Match Load exploits.json Filter by version range Filter by arch 3. Acquire Try GCC compile Fallback: download precompiled binary 4. Execute Run exploit binary Check for root Next if failed 5. Shell root # interactive Hybrid Execution: Compile vs. Binary Fallback Path A: GCC Available Download source (.c) from exploit DB Compile with specified flags gcc -Wall -o exploit source.c -static OR Path B: No GCC (Fallback) Download precompiled static binary from GitHub releases chmod +x binary && ./binary

Exploit Database

The kernel module ships with a JSON-based exploit database covering 23 CVEs across kernel versions 2.6.22 through 6.7.1. Each entry includes version range constraints, architecture support, source URLs, precompiled binary URLs, compilation commands, and execution instructions.

CVE Name Kernel Range Arch Category
CVE-2024-1086nf_tables UAF3.15.0 to 6.7.1amd64nftables, uaf
CVE-2023-3269StackRot6.1.0 to 6.4.0amd64maple-tree, uaf
CVE-2023-35829rkvdec UAF5.11.0 to 6.3.1amd64driver, uaf
CVE-2023-32233Netfilter nf_tables UAF3.13.0 to 6.3.1amd64nftables, uaf
CVE-2023-2640GameOver(lay)5.15.0 to 6.2.0amd64, arm64overlayfs, ubuntu
CVE-2023-0179nftables OOB Write5.5.0 to 6.2.0amd64nftables, oob
CVE-2022-34918Netfilter Heap Overflow5.8.0 to 5.18.8amd64nftables, heap
CVE-2022-2588DirtyCred3.6.0 to 5.19.1amd64route4, uaf
CVE-2022-1015nf_tables OOB Access5.12.0 to 5.17.0amd64nftables, oob
CVE-2022-0847DirtyPipe5.8.0 to 5.16.10amd64, arm64pipe, write-anywhere
CVE-2022-0185fsconfig Heap Overflow5.1.0 to 5.16.1amd64fsconfig, heap
CVE-2021-33909Sequoia3.16.0 to 5.13.3amd64filesystem, seq_file
CVE-2021-31440eBPF Bounds Tracking5.7.0 to 5.11.0amd64ebpf, verifier
CVE-2021-22555Netfilter xt_compat2.6.19 to 5.12.0amd64netfilter, oob-write
CVE-2021-3493OverlayFS Ubuntu3.13.0 to 5.10.99amd64, arm64overlayfs, ubuntu
CVE-2020-8835eBPF Verifier Bypass5.5.0 to 5.6.1amd64ebpf, verifier
CVE-2019-13272ptrace_link4.10.0 to 5.1.17amd64, arm64, 386ptrace, creds
CVE-2018-18955Nested User Namespace4.15.0 to 4.19.1amd64userns, idmap
CVE-2017-16995eBPF Arbitrary R/W4.4.0 to 4.14.7amd64ebpf, sign-extension
CVE-2017-7308AF_PACKET2.6.27 to 4.10.5amd64af_packet, heap-oob
CVE-2017-1000112UDP UFO4.4.0 to 4.12.6amd64udp, ufo
CVE-2016-5195DirtyCow2.6.22 to 4.8.2amd64, arm64, 386cow, race-condition
CVE-2016-0728Keyring Refcount3.8.0 to 4.4.0amd64keyring, refcount

Kernel Version Coverage

Exploit Coverage by Kernel Version 2.6 3.x 4.x 5.x 6.x 6.7 DirtyCow AF_PACKET ptrace_link DirtyPipe fsconfig nf_tables UAF (2024) Netfilter 32233 GameOver(lay) StackRot DirtyCred

Real World Testing

Judozi has been tested in production cloud environments, including Azure Container instances running kernel 5.15.0. The binary fallback system was validated in GCC-free environments: the framework detected 10 matching exploits, automatically downloaded precompiled binaries, and executed them without requiring any compiler toolchain on the target.

nextjs@container:/tmp$ uname -r
5.15.0-1102-azure

nextjs@container:/tmp$ ./judozi kernel -auto
[*] Kernel: 5.15.0
[+] Architecture: amd64
[+] Found 10 potential exploit(s)

[!] GCC not available, using binary fallback mode
[*] Downloading CVE-2024-1086...
[+] Binary downloaded successfully (166KB)
[*] Executing exploit...
[*] creating user namespace (CLONE_NEWUSER)...
[*] creating network namespace (CLONE_NEWNET)...

Project Structure

judozi/
├── cmd/judozi/
│   └── main.go              # CLI entry, module selection, shell dispatch
├── modules/
│   ├── kernel/              # Privilege escalation module
│   │   ├── kernel.go        # Module implementation
│   │   └── pkg/
│   │       ├── exploit/     # Download, compile, execute logic
│   │       ├── kernel/      # Version detection and parsing
│   │       ├── output/      # Colored terminal output
│   │       └── vulndb/      # Exploit database (exploits.json)
│   ├── persistence/         # Post-exploitation persistence
│   │   ├── persistence.go
│   │   └── techniques/
│   └── recon/               # System reconnaissance
│       ├── recon.go
│       └── techniques/
├── pkg/
│   ├── module/              # Module interface and registry
│   ├── shell/               # Interactive shell session
│   └── ui/                  # Terminal UI framework
├── go.mod
└── judozi                   # 5.3MB static binary