REDHAT-BUG-2552352: Buffer Overflow
A vulnerability exists in NGINX Plus and NGINX Open Source when a location is configured that uses the alias directive together with rewrite and a set or return directive referencing the $requestfilename variable. Alternatively, the same result could be achieved when the $requestfilename variable is used in an access log format directive. An unauthenticated attacker along with conditions beyond their control can exploit this vulnerability by sending crafted HTTP requests. This may cause a heap buffer overflow in the NGINX worker process leading to a restart. Additionally, attackers can execute code on systems with Address Space Layout Randomization (ASLR) disabled or when the attacker can bypass ASLR.
Impact: This vulnerability may allow remote attackers to cause a denial-of-service (DoS) on the NGINX system or to possibly trigger a code execution. There is no control plane exposure; this is a data plane issue only.
Note: Software versions which have reached End of Technical Support (EoTS) are not evaluated.
Affected Software
Event History
Frequently Asked Questions
Which deployments are exposed to this issue?
NGINX Plus and NGINX Open Source deployments are affected only when a location uses the alias directive and $request_filename is referenced through rewrite with set or return, or through an access-log format directive. The issue affects the data plane only; there is no control-plane exposure.
Does exploitation require authentication or a privileged attacker position?
No. An unauthenticated attacker can send crafted HTTP requests, although exploitation also depends on conditions beyond the attacker’s control.
What is the practical impact of a successful attack?
The heap buffer overflow can cause the NGINX worker process to restart, resulting in denial of service. Code execution may also be possible where ASLR is disabled or where the attacker can bypass ASLR.
How can I determine whether my configuration is exposed?
Review NGINX location blocks for use of alias and check whether $request_filename is referenced in rewrite-related set or return directives. Also review access-log format directives for use of $request_filename in configurations that use alias locations.