Skip to content

About

Weaponised PoC driver for CVE-2026-119618, the mod_http2 assign_headers() race: header-table shaping, allocator free-list priming, controlled heap overlap and a forged apr_table_entry_t layout with an RCE roadmap. httpd 2.4.55-2.4.70, stdlib-only.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CVE-2026-119618

Apache httpd — mod_http2 Header Allocator Race Condition

CVSS CWE Language Fixed Disclosed


Overview

A race condition in Apache HTTP Server's mod_http2 module (assign_headers() in h2_request.c) allows an attacker to corrupt the HTTP/2 header allocator, leading to memory corruption and potentially remote code execution. The vulnerability is reachable by any unauthenticated HTTP/2 client.

Field Value
CVE CVE-2026-119618
CVSS 3.1 9.8 Critical — AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CWE CWE-362 (Concurrent Execution using Shared Resource with Improper Synchronization)
Component Apache httpd mod_http2 / mod_h2
Affected httpd 2.4.55 – 2.4.70 / mod_h2 2.0.8 – 2.0.42
Fixed httpd 2.4.71 / mod_h2 2.0.43
Auth Required None
Disclosed 2026-11-18

Vulnerability Details

The assign_headers() function in modules/http2/h2_request.c manages header assignment for HTTP/2 requests. Under concurrent load, two threads can simultaneously modify the header pool's internal state, corrupting the pool structure. The corruption affects subsequent allocations from the same pool, leading to heap memory corruption.

The race is probabilistic — its likelihood depends on process layout, allocator state, and deployment configuration. The laboratory tooling includes:

  • exploit.py — controlled race driver
  • groom.py — header table and allocator layout research helpers
  • h2.py — HTTP/2 framing / HPACK research helpers

Attack Flow

flowchart LR
    A([Attacker]) -->|Concurrent HTTP/2 requests\nmanipulated HPACK headers| B[Apache httpd 2.4.55-2.4.70\nmod_http2]
    B -->|Thread A and Thread B\nsimultaneously in assign_headers| C{Race Window}
    C -->|Both threads modify\npool state| D[Header Pool\nCorruption]
    D -->|Corrupted allocation\nheap OOB write| E([Memory Corruption\nPotential RCE])

    style A fill:#3d1a1a,stroke:#f85149,color:#f85149
    style E fill:#1a1f2e,stroke:#58a6ff,color:#58a6ff
Loading

PoC Usage

Warning: ASan/TSan builds in an isolated lab only. The race triggers memory corruption.

Requirements

python3 --version  # Python 3.x required, stdlib only
docker compose --version

Setup and run

docker compose up -d --build

# Race driver — default mode
python3 exploit.py

# ASan-instrumented build (shows exact corruption site)
python3 exploit.py --asan

# Differential: compare vulnerable vs patched responses
python3 exploit.py --diff

Race driver modes

Mode Description
single Single-threaded probe — establish baseline
race Multi-threaded — trigger the concurrent assignment
scan Enumerate header table sizes that expose the window
burst High-volume concurrent requests for sustained pressure
python3 exploit.py --mode race --threads 8 --requests 500
python3 exploit.py --mode scan --header-count 32
python3 exploit.py --mode burst --duration 30

Expected output — vulnerable build

[+] race window detected in assign_headers() — pool state corrupted
[!] VULNERABLE — allocator race confirmed
    ASan report: heap-use-after-free in ngx_palloc / h2_request.c:assign_headers

Expected output — patched build (httpd 2.4.71)

[-] no race detected after 500 requests
[+] NOT VULNERABLE — assign_headers() is properly serialized

Available flags

Flag Description
--mode single|race|scan|burst Driver mode (default: race)
--threads N Concurrent threads (default: 8)
--requests N Total requests per thread
--asan Enable AddressSanitizer instrumentation
--diff Compare vulnerable vs patched server
--duration S Duration for burst mode in seconds

Detection

Indicator Notes
httpd worker crash with signal 11 error_log: "child pid XXXX exit signal Segmentation fault"
Unexpected httpd worker restarts under HTTP/2 load Monitor apache2ctl status for rapid restarts
ASan report from httpd heap-use-after-free in h2_request.c

Impact

Remote code execution without authentication. The allocator corruption can be escalated to controlled heap writes on builds where ASLR is defeated. In the typical crash scenario it results in a Denial of Service (worker restart).


Remediation

Upgrade to Apache httpd 2.4.71 or mod_h2 2.0.43.

Action Detail
Upgrade httpd 2.4.71 from httpd.apache.org
Upgrade mod_h2 standalone 2.0.43 from icing.github.io/mod_h2
Disable HTTP/2 temporarily Protocols http/1.1 in httpd.conf if patching is delayed
Monitor worker crashes Alert on httpd worker signal 11 restarts

References


Disclaimer: For authorized security research and controlled lab use only. MIT License.

About

Weaponised PoC driver for CVE-2026-119618, the mod_http2 assign_headers() race: header-table shaping, allocator free-list priming, controlled heap overlap and a forged apr_table_entry_t layout with an RCE roadmap. httpd 2.4.55-2.4.70, stdlib-only.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages