CVE-2026-124290

Net::Server versions through 2.018 for Perl allow CPU exhaustion via a read_until loop that keeps reading after the client disconnects

Published Nov 29, 2026 CVSS n/a EPSS < 1% KEV · Not listed
Description
Net::Server versions through 2.018 for Perl allow CPU exhaustion via a read_until loop that keeps reading after the client disconnects.

read_until reads one byte per iteration and leaves the loop only once it has the requested number of bytes or a match for the end pattern. Nothing checks the return value of read(), so once the peer has closed the connection every read returns 0 and the loop spins at full CPU. The TCP, UNIX and SSL protocol classes and Net::Server::INET share this loop. The SSLEAY protocol class is not affected.

Net::Server::HTTP reads every request header through read_until, so a client that connects and closes before ending its headers holds a worker at full CPU until timeout_header (15 seconds by default) fires. A stream of such short-lived connections keeps every worker busy. Other callers of read_until without their own timeout spin indefinitely.

Analysis

AI-generated

Technical impact

Net::Server implementations up to version 2.018 contain a flaw in the read_until routine. The routine reads one byte per loop iteration and exits only when a predefined number of bytes or a match pattern is encountered. Importantly, it never checks the result of the underlying read() call. When a client disconnects, subsequent read() calls return zero, yet the loop continues, consuming CPU at 100 % until a timeout occurs. Net::Server::HTTP parses request headers with read_until, meaning a client that connects and immediately closes the socket will tie up a worker process for the full timeout_header period (15 seconds by default). Repeated short-lived connections can therefore saturate all workers, effectively denying service to legitimate traffic. No other code paths in Net::Server::INET or the SSL classes are affected, and the SSLEAY protocol handler does not use the problematic loop.

Affected Systems

The vulnerability impacts Net::Server releases 2.018 and earlier, affecting the TCP, UNIX, and SSL protocol handler classes, as well as Net::Server::INET. Net::Server::HTTP, which uses read_until to read request headers, is particularly vulnerable. Systems that deploy these components—especially high‑traffic web or application servers built on Net::Server::HTTP or Net::Server::PSGI—could be exposed if they do not have the available patch applied.

Risk and Exploitability

No EPSS value has been published, and the vulnerability is not listed in the CISA KEV catalog, so publicly available exploitation data is absent. The CVSS score is not reported in the CVE record. Based on the description, it can be inferred that the attacker does not require authentication or elevated privileges; any entity able to open a TCP connection to the listening port can trigger the race. The flaw exploits the lack of read() result validation, a classic logic error (CWE‑835). Although the exploit probability remains undetermined, the fact that the loop can run indefinitely until a timeout allows an attacker to quickly exhaust CPU resources. This makes the risk significant for services that rely on Net::Server::HTTP or Net::Server::PSGI, especially under heavy or malicious load.

Remediation

Vendor Workaround

No fixed release is available. Apply the patch. For deployments that cannot apply the patch, run Net::Server::HTTP and Net::Server::PSGI behind a reverse proxy that forwards only complete requests, and set an alarm around other calls to read_until.


OpenCVE Recommended Actions

  • Apply the vendor patch CVE-2026-124290‑r1 to Net::Server 2.018 via the supplied patch file
  • If a patch cannot be applied immediately, place Net::Server::HTTP or Net::Server::PSGI behind a reverse proxy that accepts only complete request streams before forwarding to the backend
  • Reduce the timeout_header value in Net::Server::HTTP to a lower threshold and enable monitoring of CPU usage to detect sustained worker saturation

Generated by OpenCVE AI on November 30, 2026 at 01:51 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Description Net::Server versions through 2.018 for Perl allow CPU exhaustion via a read_until loop that keeps reading after the client disconnects. read_until reads one byte per iteration and leaves the loop only once it has the requested number of bytes or a match for the end pattern. Nothing checks the return value of read(), so once the peer has closed the connection every read returns 0 and the loop spins at full CPU. The TCP, UNIX and SSL protocol classes and Net::Server::INET share this loop. The SSLEAY protocol class is not affected. Net::Server::HTTP reads every request header through read_until, so a client that connects and closes before ending its headers holds a worker at full CPU until timeout_header (15 seconds by default) fires. A stream of such short-lived connections keeps every worker busy. Other callers of read_until without their own timeout spin indefinitely.
Title Net::Server versions through 2.018 for Perl allow CPU exhaustion via a read_until loop that keeps reading after the client disconnects
Weaknesses CWE-835
References

Subscriptions

No data.

Weaknesses
  • CWE-835

    Loop with Unreachable Exit Condition ('Infinite Loop')

Sources

Status
PUBLISHED
Assigner
CPANSec
Published
Updated
Nov 29, 2026, 11:28 PM
Reserved
Nov 7, 2026, 11:58 AM
Status
Received
Published
Nov 30, 2026, 12:17 AM
Modified
Nov 30, 2026, 12:17 AM