Heap-based Buffer Overflow Affecting nginx package, versions [1.0.0,1.30.2)[1.31.0,1.31.1)


Severity

Recommended
0.0
critical
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
9.96% (96th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Heap-based Buffer Overflow vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-UNMANAGED-NGINX-16873871
  • published24 May 2026
  • disclosed22 May 2026
  • creditMufeed VH, Nebula Security, Vexera AI

Introduced: 22 May 2026

CVE-2026-9256  (opens in a new tab)
CWE-122  (opens in a new tab)

How to fix?

Upgrade nginx to version 1.30.2, 1.31.1 or higher.

Overview

Affected versions of this package are vulnerable to Heap-based Buffer Overflow in the ngx_http_rewrite_module when a rewrite directive uses a regex pattern with distinct, overlapping Perl-Compatible Regular Expression (PCRE) captures and a replacement string that references multiple such captures in a redirect or arguments context. An attacker can cause a heap buffer overflow in the worker process, potentially leading to process restart or remote code execution by sending crafted HTTP requests. This is only exploitable if Address Space Layout Randomization (ASLR) is disabled or the attacker can bypass ASLR.

CVSS Base Scores

version 4.0
version 3.1