Skip to content
OpenAdvisories
Unscored Public exploit CVE-2021-42717 EUVD-2021-29677GHSA-w3vf-7fpc-9fww

ModSecurity 3.x through 3.0.5 mishandles excessively nested JSON objects. Crafted JSON objects with nesting tens-of-thousands deep could re…

Published Dec 7, 2021 · Updated Aug 4, 2024 · Assigned by mitre

Description

ModSecurity 3.x through 3.0.5 mishandles excessively nested JSON objects. Crafted JSON objects with nesting tens-of-thousands deep could result in the web server being unable to service legitimate requests. Even a moderately large (e.g., 300KB) HTTP request can occupy one of the limited NGINX worker processes for minutes and consume almost all of the available CPU on the machine. Modsecurity 2 is similarly vulnerable: the affected versions include 2.8.0 through 2.9.4.

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 modsecurity 3.0.6-1 —
Debian 14 modsecurity-apache 2.9.5-1 —
Debian 13 modsecurity 3.0.6-1 —
Debian 13 modsecurity-apache 2.9.5-1 —
Debian 12 modsecurity 3.0.6-1 —
Debian 12 modsecurity-apache 2.9.5-1 —
Debian 11 modsecurity-apache 2.9.3-3+deb11u1 DSA-5023-1
Debian 10 modsecurity-apache 2.9.3-1+deb10u1 DSA-5023-1
Show 1 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Debian 9 modsecurity-apache 2.9.1-2+deb9u1 DLA-3031-1
ReleasePackageFixed inAdvisory
Ubuntu 26.10 modsecurity No fix yet —
Ubuntu 26.04 LTS modsecurity No fix yet —
Ubuntu 25.10 modsecurity No fix yet —
Ubuntu 24.04 LTS modsecurity No fix yet —
Ubuntu 22.04 LTS modsecurity No fix yet —
Show 5 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu 20.04 LTS modsecurity No fix yet —
Ubuntu 20.04 LTS modsecurity-apache 2.9.3-1ubuntu0.1 USN-6370-1
Ubuntu Pro 22.04 LTS modsecurity-apache 2.9.5-1ubuntu0.1~esm1 USN-6370-1
Ubuntu Pro 18.04 LTS modsecurity-apache 2.9.2-1ubuntu0.1~esm1 USN-6370-1
Ubuntu Pro 16.04 LTS modsecurity-apache 2.9.0-1ubuntu0.1~esm1 USN-6370-1
Ubuntu Pro 14.04 LTS modsecurity-apache 2.7.7-2ubuntu0.1~esm1 USN-6370-1
ReleasePackageFixed inAdvisory
SUSE Package Hub 15 SP5 modsecurity 3.0.10-bp155.3.3.1 openSUSE-SU-2023:0257-1
SUSE Package Hub 15 SP4 modsecurity 3.0.10-bp154.2.3.1 openSUSE-SU-2023:0269-1
ReleasePackageFixed inAdvisory
openSUSE Leap 15.5 modsecurity 3.0.10-bp155.3.3.1 openSUSE-SU-2023:0257-1
openSUSE Leap 15.4 modsecurity 3.0.10-bp154.2.3.1 openSUSE-SU-2023:0269-1

Azure Linux

ReleasePackageFixed inAdvisory
Azure Linux 3 mod_security 2.9.7-8 —

Public exploits

Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.

Third-party code, not reviewed by us. Public PoCs are sometimes fake or contain malware. Read the code first and run it only in an isolated lab, against systems you are authorised to test.

GitHub 1 repository

Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.

Advisories 9

References