# CVE-2026-3298: Python CPython out-of-bounds write in asyncio sock_recvfrom_into on Windows

Source: https://junglewise.ai/threats/cve-2026-3298-python-cpython-out-of-bounds-write-in-asyncio-sock-recvfrom-into  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-04-21. Updated: 2026-07-31  
License: CC BY 4.0 with a link back

CVE-2026-3298 · Severity: info · CVSS 8.8 · Published 2026-04-21

A security vulnerability has been identified in Python's 'asyncio' library specifically affecting Windows systems. The flaw exists in a networking component used to receive data into a pre-allocated buffer; if an attacker sends more data than the buffer can hold, it can cause the application to crash or potentially allow for unauthorized memory modification. This could impact the reliability and security of Windows-based Python applications that handle network communications.

Technologies: [Python Software Foundation CPython](https://junglewise.ai/threats/technologies/cpython). Vendors: [Python Software Foundation](https://junglewise.ai/threats/vendors/python-software-foundation).

## Quick answers

**Is CVE-2026-3298 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-3298 being exploited in the wild.

**How severe is CVE-2026-3298?** Informational severity, with a CVSS score of 8.8, published 21 April 2026.

**Which products and versions are affected?** Python Software Foundation CPython < 3.13.14, 3.14.0a1 < 3.14.5rc1, 3.15.0a1 < 3.15.0b1.

**Is there a fix for CVE-2026-3298?** A patch was published on 2026-04-21: Fix merged into CPython main branch Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-3298 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-3298?** Check whether you run Python Software Foundation CPython at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

An out-of-bounds (OOB) write vulnerability (CWE-787) exists in CPython's 'asyncio' module on Windows platforms. The vulnerability is located in the 'sock_recvfrom_into()' method of the 'ProacterEventLoop' class. When the 'nbytes' parameter is utilized, the implementation fails to validate that the incoming data size does not exceed the provided buffer's capacity. A remote attacker can exploit this by sending a network packet larger than the expected buffer size, resulting in a heap-based buffer overflow. This can lead to application crashes (denial of service) or potentially arbitrary code execution. The issue is specific to the Windows 'overlapped' I/O implementation and does not affect Unix-like platforms. Patches have been merged into CPython versions 3.13, 3.14, and 3.15.

## Affected products

- Python Software Foundation CPython < 3.13.14, 3.14.0a1 < 3.14.5rc1, 3.15.0a1 < 3.15.0b1

## Timeline

- 2026-04-20: disclosed: Issue reported and PR opened on GitHub
- 2026-04-21: patched: Fix merged into CPython main branch
- 2026-04-21: advisory: Official security announcement sent to python-announce list

## References

- [https://github.com/python/cpython/commit/1274766d3c29007ab77245a72abbf8dce2a9db4d](https://github.com/python/cpython/commit/1274766d3c29007ab77245a72abbf8dce2a9db4d)
- [https://github.com/python/cpython/commit/27522b7d6e6588f03e61099dd858cd5a9314e2f2](https://github.com/python/cpython/commit/27522b7d6e6588f03e61099dd858cd5a9314e2f2)
- [https://github.com/python/cpython/commit/95633d2aad4721e25e4dfd9f43dfb6e1edcbd741](https://github.com/python/cpython/commit/95633d2aad4721e25e4dfd9f43dfb6e1edcbd741)
- [https://github.com/python/cpython/issues/148808](https://github.com/python/cpython/issues/148808)
- [https://github.com/python/cpython/pull/148809](https://github.com/python/cpython/pull/148809)
- [https://mail.python.org/archives/list/security-announce@python.org/thread/KWTPIQBOOOUNQP7UFSLBI437NJDFLA3F/](https://mail.python.org/archives/list/security-announce@python.org/thread/KWTPIQBOOOUNQP7UFSLBI437NJDFLA3F/)

## Related threats

- [Python gzip/tarfile/zipfile CLI module shadowing via sys.path](https://junglewise.ai/threats/cve-2026-115791-when-tarfile-or-zipfile-command-line-interface-cli-is-used-to)
- [Python CPython quadratic complexity in xml.etree XPath index predicates](https://junglewise.ai/threats/cve-2026-6879-python-cpython-quadratic-complexity-in-xml-etree-xpath-index)
- [Python CPython CPU denial of service in html.parser.HTMLParser](https://junglewise.ai/threats/cve-2026-15308-python-cpython-cpu-denial-of-service-in-html-parser-htmlparser)
- [Python CPython improper permission preservation in tarfile.extract](https://junglewise.ai/threats/cve-2026-4360-python-cpython-improper-permission-preservation-in-tarfile-extract)
- [Python CPython infinite loop in tarfile streaming mode](https://junglewise.ai/threats/cve-2026-11972-python-cpython-infinite-loop-in-tarfile-streaming-mode)
