Vulnerability · Published Jun 20, 2025 · Assigned by GitHub_M

CVE-2025-48945pycares has a Use-After-Free Vulnerability

High 8.2

In plain English

A high-severity use-after-free in aiodns from aio-libs. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.5% (higher than 42% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 4.0)8.2High
Exploit odds (30 days)0.5%top 58.1% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

pycares is a Python module which provides an interface to c-ares. c-ares is a C library that performs DNS requests and name resolutions asynchronously. Prior to version 4.9.0, pycares is vulnerable to a use-after-free condition that occurs when a Channel object is garbage collected while DNS queries are still pending. This results in a fatal Python error and interpreter crash. The vulnerability has been fixed in pycares 4.9.0 by implementing a safe channel destruction mechanism.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12pycaresno fix listedDEBIAN-CVE-2025-48945
Debian:13pycaresno fix listedDEBIAN-CVE-2025-48945
Debian:14pycares4.9.0-1DEBIAN-CVE-2025-48945
PyPIpycares4.9.0GHSA-5qpg-rh4j-qp35
Ubuntu:22.04:LTSpycaresno fix listedUBUNTU-CVE-2025-48945
Ubuntu:24.04:LTSpycaresno fix listedUBUNTU-CVE-2025-48945
Ubuntu:25.10pycaresno fix listedUBUNTU-CVE-2025-48945
Ubuntu:26.04:LTSpycaresno fix listedUBUNTU-CVE-2025-48945
Ubuntu:26.10pycaresno fix listedUBUNTU-CVE-2025-48945

Affected products (as reported)

VendorProductVersions
aio-libs aiodns < 4.9.0

Weakness: CWE-416 · Vector: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

References