8.3

CVE-2025-31498: c-ares Use After Free

CVSS: 8.3v4.0HighDeferred
AliasesALPINE-CVE-2025-31498RHSA-2025:4461RHSA-2025:7426
Published 08-04-2025Last modified 08-04-2025

Vulnerability summary

CVE-2025-31498 is a high (CVSS 8.3) Use After Free vulnerability in c-ares. EPSS estimates a 0.59% chance of exploitation in the next 30 days, higher than 47.1% of scored vulnerabilities.

Overall risk
33/100
0100
Medium · default modelHow is this calculated?
CVSS score
8.3/10
010
High · v4.0 (CVE.org)
EPSS score
0.59%
0%100%
Low · +0.01 pp in 30 days
KEVNot listedIn no KEV catalog
RansomwareNone recordedNo known use recorded
Public exploits0No public exploits recorded

Advisory lineage

Upstream 0 · Downstream 5 · Related 3

Timeline

  1. 08-04-2025
    PublishedVulnerability first disclosed.
  2. 08-04-2025
    Last modifiedVulnerability information updated.

Description

c-ares is an asynchronous resolver library. From 1.32.3 through 1.34.4, there is a use-after-free in read_answers() when process_answer() may re-enqueue a query either due to a DNS Cookie Failure or when the upstream server does not properly support EDNS, or possibly on TCP queries if the remote closed the connection immediately after a response. If there was an issue trying to put that new transaction on the wire, it would close the connection handle, but read_answers() was still expecting the connection handle to be available to possibly dequeue other responses. In theory a remote attacker might be able to trigger this by flooding the target with ICMP UNREACHABLE packets if they also control the upstream nameserver and can return a result with one of those conditions, this has been untested. Otherwise only a local attacker might be able to change system behavior to make send()/write() return a failure condition. This vulnerability is fixed in 1.34.5.

CVSS metrics

6 scores · 6 sources · 2 versions

EPSS trend

Probability

0.59%

Chance of exploitation in the next 30 days

Percentile

47%

Versus all other CVEs

30-day change

+0.01 pp

From 0.58% on 19-09-2026

19-09-202619-10-2026
EPSS score
0.59%

Known exploited

Compare KEV catalogs

Not in any of the 3 tracked catalogs.

Public exploits

0 found

No public exploits indexed.

Weaknesses

CWE · root cause

Affected systems

Redhat16 products
  • nodejs< 1:20.19.1-1.module+el8.10.0+23054+5431297f | < 1:20.19.1-1.module+el9.6.0+23053+4195b0b2 | < 1:22.15.0-1.el10_0 | < 1:20.18.2-2.module+el9.4.0+23089+aaa18a20
  • nodejs-debuginfo< 1:20.19.1-1.module+el8.10.0+23054+5431297f | < 1:20.19.1-1.module+el9.6.0+23053+4195b0b2 | < 1:22.15.0-1.el10_0 | < 1:20.18.2-2.module+el9.4.0+23089+aaa18a20
  • nodejs-debugsource< 1:20.19.1-1.module+el8.10.0+23054+5431297f | < 1:20.19.1-1.module+el9.6.0+23053+4195b0b2 | < 1:20.18.2-2.module+el9.4.0+23089+aaa18a20
  • nodejs-devel< 1:20.19.1-1.module+el8.10.0+23054+5431297f | < 1:20.19.1-1.module+el9.6.0+23053+4195b0b2 | < 1:22.15.0-1.el10_0 | < 1:20.18.2-2.module+el9.4.0+23089+aaa18a20
  • nodejs-docs< 1:20.19.1-1.module+el8.10.0+23054+5431297f | < 1:20.19.1-1.module+el9.6.0+23053+4195b0b2 | < 1:22.15.0-1.el10_0 | < 1:20.18.2-2.module+el9.4.0+23089+aaa18a20
Alpine1 product
  • c-ares< 1.34.5-r0
C-ares1 product
Debian1 product
  • c-ares< 1.34.5-1
Opensuse1 product
  • c-ares&distro=openSUSE Tumbleweed< 1.34.5-1.1
Ubuntu1 product
  • c-ares< 1.34.4-2.1ubuntu0.1

6 vendors · 21 products

References

23 links
Show all 23 references