CVE-2023-31137: MaraDNS Integer Underflow Vulnerability in DNS Packet Decompression

Published May 9, 2023
·
Updated

MaraDNS is open-source software that implements the Domain Name System (DNS). In version 3.5.0024 and prior, a remotely exploitable integer underflow vulnerability in the DNS packet decompression function allows an attacker to cause a Denial of Service by triggering an abnormal program termination. The vulnerability exists in the decompgetrddata function within the Decompress.c file. When handling a DNS packet with an Answer RR of qtype 16 (TXT record) and any qclass, if the rdlength is smaller than rdata, the result of the line Decompress.c:886 is a negative number len = rdlength - total;. This value is then passed to the decompappendbytes function without proper validation, causing the program to attempt to allocate a massive chunk of memory that is impossible to allocate. Consequently, the program exits with an error code of 64, causing a Denial of Service. One proposed fix for this vulnerability is to patch Decompress.c:887 by breaking if(len <= 0), which has been incorporated in version 3.5.0036 via commit bab062bde40b2ae8a91eecd522e84d8b993bab58.

Affected Software

14 affected componentsFixes available
debian/maradns<=2.0.13-1.4, <=2.0.13-1.2
2.0.13-1.4+deb11u12.0.13-1.5
ubuntu/maradns<2.0.13-1.4+
2.0.13-1.4+
ubuntu/maradns<2.0.13-1ubuntu0.1~
2.0.13-1ubuntu0.1~
ubuntu/maradns<2.0.13-1.2ubuntu0.1~
2.0.13-1.2ubuntu0.1~
ubuntu/maradns<2.0.13-1.4+
2.0.13-1.4+
ubuntu/maradns<2.0.13-1.4+
2.0.13-1.4+
debian/maradns<=2.0.13-1.2
2.0.13-1.2+deb10u12.0.13-1.4+deb11u12.0.13-1.6
MaraDNS MaraDNS<=3.5.0024
MaraDNS MaraDNS<3.4.10
MaraDNS MaraDNS>=3.5.0001<3.5.0036
Fedoraproject Fedora=37
Fedoraproject Fedora=38
Debian Debian Linux=10.0
Debian Debian Linux=11.0

Event History

May 9, 2023
CVE Published
via Ubuntu·12:00 AM
CVE Published
via MITRE·01:56 PM
Data Sourced
via MITRE·01:56 PM
DescriptionSeverityWeakness
Jan 12, 2024
Data Sourced
via Launchpad·12:18 AM
Description

Parent advisories

This vulnerability appears in the following advisories.

Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2023-31137?

CVE-2023-31137 is classified as a high severity vulnerability due to its potential to cause Denial of Service.

2

How do I fix CVE-2023-31137?

To fix CVE-2023-31137, update MaraDNS to version 3.5.0036 or later.

3

Which versions of MaraDNS are affected by CVE-2023-31137?

MaraDNS versions 3.5.0024 and earlier are affected by CVE-2023-31137.

4

Can CVE-2023-31137 be exploited remotely?

Yes, CVE-2023-31137 can be exploited remotely by an attacker.

5

What type of attack does CVE-2023-31137 facilitate?

CVE-2023-31137 facilitates Denial of Service attacks against the DNS service.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203