Vulnerability Description
CGI.escape_html in Ruby before 2.7.5 and 3.x before 3.0.3 has an integer overflow and resultant buffer overflow via a long string on platforms (such as Windows) where size_t and long have different numbers of bytes. This also affects the CGI gem before 0.3.1 for Ruby.
CVSS Score
CRITICAL
Affected Products
| Vendor | Product | Versions |
|---|---|---|
| Ruby-Lang | Cgi | < 0.3.1 |
| Ruby-Lang | Ruby | >= 3.0.0, < 3.0.3 |
| Fedoraproject | Fedora | 34 |
Related Weaknesses (CWE)
References
- https://hackerone.com/reports/1328463Permissions RequiredThird Party Advisory
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedorapro
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedorapro
- https://security-tracker.debian.org/tracker/CVE-2021-41816Third Party Advisory
- https://security.gentoo.org/glsa/202401-27
- https://security.netapp.com/advisory/ntap-20220303-0006/Third Party Advisory
- https://www.ruby-lang.org/en/news/2021/11/24/buffer-overrun-in-cgi-escape_html-cExploitVendor Advisory
- https://hackerone.com/reports/1328463Permissions RequiredThird Party Advisory
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedorapro
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedorapro
- https://security-tracker.debian.org/tracker/CVE-2021-41816Third Party Advisory
- https://security.gentoo.org/glsa/202401-27
- https://security.netapp.com/advisory/ntap-20220303-0006/Third Party Advisory
- https://www.ruby-lang.org/en/news/2021/11/24/buffer-overrun-in-cgi-escape_html-cExploitVendor Advisory
FAQ
What is CVE-2021-41816?
CVE-2021-41816 is a vulnerability with a CVSS score of 9.8 (CRITICAL). CGI.escape_html in Ruby before 2.7.5 and 3.x before 3.0.3 has an integer overflow and resultant buffer overflow via a long string on platforms (such as Windows) where size_t and long have different nu...
How severe is CVE-2021-41816?
CVE-2021-41816 has been rated CRITICAL with a CVSS base score of 9.8/10. This is considered a critical vulnerability requiring immediate attention.
Is there a patch for CVE-2021-41816?
Check the references section above for vendor advisories and patch information. Affected products include: Ruby-Lang Cgi, Ruby-Lang Ruby, Fedoraproject Fedora.