CVE-2025-48945
pycares has a Use-After-Free Vulnerability
- State
- Published
- Severity
- 8.2 High
- Published
- Jun 20, 2025
- Updated
- Jun 20, 2025
- Reserved
- May 28, 2025
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.
Scores
| CVSS | Score | Vector | Source |
|---|---|---|---|
| 4.0 | 8.2 High | 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 | GitHub_M |
Weaknesses
- CWE-416 Use After Free
Affected Products
| Product | Versions |
|---|---|
aiodnsaio-libs |
|
References
- https://github.com/saghul/pycares/security/advisories/GHSA-5qpg-rh4j-qp35
- https://github.com/aio-libs/aiodns/commit/f259a6e3650555157af53ac2b39f2ff545321d55
- https://github.com/saghul/pycares/commit/ebfd7d71eb8e74bc1057a361ea79a5906db510d4
- https://github.com/aio-libs/aiodns/releases/tag/v3.5.0
- https://github.com/saghul/pycares/releases/tag/v4.9.0
Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.