A high-severity security vulnerability has been discovered in Python’s asyncio module on Windows, potentially allowing attackers to write data beyond the boundaries of an allocated memory buffer.
The flaw, tracked as CVE-2026-3298, was publicly disclosed on April 21, 2026, by Python security developer Seth Larson via the official Python security announcement mailing list.
The vulnerability exists in the sock_recvfrom_into() method of asyncio.ProactorEventLoop, a Windows-specific event loop implementation used for asynchronous I/O operations.
The root cause is a missing boundary check on the data buffer when the optional nbytes parameter is used.
When a network response exceeds the pre-allocated buffer size, Python fails to enforce a size limit, allowing the excess data to overwrite adjacent memory regions.
This class of bug, known as an out-of-bounds (OOB) write, is particularly dangerous because it can lead to memory corruption, application crashes, or potentially arbitrary code execution depending on what memory is overwritten.
This vulnerability is Windows-only. Linux, macOS, and other Unix-based platforms use a different event loop backend (SelectorEventLoop) and are completely unaffected.
Windows users running Python applications that rely on asyncio-based networking, especially those using sock_recvfrom_into() with the nbytes argument, are at risk.
The vulnerability is especially relevant for:
The Python security team rated this vulnerability as HIGH severity. Out-of-bounds write bugs are frequently exploited in memory corruption attacks, and their presence in a widely used standard library component like asyncio significantly raises the risk profile for production Windows deployments.
A fix has already been submitted to the CPython repository via GitHub Pull Request #148809. The patch introduces the missing boundary check, ensuring received data cannot exceed the buffer size defined by the nbytes parameter.
Python users on Windows should:
asyncio.ProactorEventLoop is the default event loop on Windows since Python 3.8, making this vulnerability relevant across a broad range of modern Python deployments.
Developers building network-facing applications on Windows are strongly encouraged to prioritize this patch.
Follow us on Google News, LinkedIn, and X to Get Instant Updates and Set GBH as a Preferred Source in Google.
More than 20,000 malicious Cloudflare Pages subdomains used by Help TDS, a longstanding traffic distribution…
A suspected China-nexus espionage group exploited a critical zero-day in BeyondTrust Remote Support, tracked as…
A critical unauthenticated OS command injection flaw in Collabora Online's built-in CODE Server app for…
A likely Russian-speaking threat actor used hundreds of AI agents to exploit PaperCut NG/MF servers,…
Microsoft and international partners have disrupted infrastructure supporting CoGUI. This phishing kit Proofpoint says generates…
Researchers at pwn.ai used an AI-assisted research harness to find a critical Linux kernel networking…