CVE-2026-115776: Twisted: Unauthenticated Remote Denial of Service in the Twisted IRC Server via an Unbounded Line Buffer

Published Oct 23, 2026
·
Updated

Summary

An unbounded-buffer vulnerability (CWE-770) in the Twisted words IRC server lets any unauthenticated remote client exhaust server memory. twisted.words.protocols.irc.IRC.dataReceived appends every received byte to a per-connection buffer and only removes data at a line feed, with no maximum length. Because IRC is a plain Protocol and not a LineReceiver, one connection that streams bytes without a line feed grows the buffer without bound and drives the whole single-threaded process to out-of-memory, dropping every user at once. The twistd words server inherits the method unchanged through IRCUser, and the data is buffered before any authentication.

Details

IRC.dataReceived keeps everything up to the last line feed in self.buffer:

python twisted/words/protocols/irc.py class IRC(protocol.Protocol): # not a LineReceiver, so no MAXLENGTH buffer = "" def dataReceived(self, data): if isinstance(data, bytes): data = data.decode("utf-8") lines = (self.buffer + data).split(LF) self.buffer = lines.pop() # no 3line feed -> whole input stays buffered ...

With no line feed in the data, lines.pop() returns the entire accumulated content to self.buffer, so it grows by every chunk and is never bounded; IRC defines no MAXLENGTH, no lineLengthExceeded, and no timeout, so the connection is never closed. The twistd words server protocol IRCUser subclasses IRC without overriding dataReceived, and the buffer is filled before any PASS, NICK, or USER, so no credentials are required.

Affected product: Twisted (twisted.words), twisted.words.protocols.irc.IRC and its subclass twisted.words.service.IRCUser Affected versions: 26.4.0 and earlier

PoC

On a standard Twisted words IRC server (the server twistd words runs, using IRCUser), an unauthenticated client opens a single TCP connection and continuously sends data that contains no line feed, never completing a line. Every chunk is appended to the connection's line buffer, and because no complete line is ever formed none of it is consumed, so the buffer grows by the full volume sent.

In a measured run against a real IRCFactory server, one unauthenticated connection sending 60 MB of line-feed-free data raised the server process resident memory from about 47 MB to 2966 MB (roughly 49 MB per MB sent) with the connection still open and no limit triggered. Sending the same volume as normal line-feed-terminated commands leaves memory flat, which isolates the cause to the missing line-length bound.

Impact

An unauthenticated remote denial of service from allocation without limits (CWE-770) leading to uncontrolled resource consumption (CWE-400). A single credential-free connection exhausts the memory of the whole twistd words process, and because one process serves every user, the crash drops all connections at once and the service stays down until it is restarted. The quadratic buffer copy reaches the same effect faster. There is no confidentiality or integrity impact and no code execution.

Other sources

Twisted is an event-based framework for internet applications, supporting Python 3.6+. Prior to 26.10.0rc1, twisted.words.protocols.irc.IRC.dataReceived retains all bytes received without a line feed in its per-connection buffer and applies no maximum line length. The twisted.words.service.IRCUser server subclass inherits this behavior, and buffering occurs before PASS, NICK, or USER authentication commands. An unauthenticated connection can continuously grow the buffer until the shared server process runs out of memory and drops all users. This issue is fixed in version 26.10.0rc1.

— MITRE

Affected Software

2 affected componentsFixes available
pypi/Twisted<26.10.0rc1
pip/twisted<=26.4.0
26.10.0rc1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade pip/Twisted to a version that resolves this vulnerability.

    Fixed in 26.10.0rc1
  2. Upgrade

    Upgrade Twisted to a version that resolves this vulnerability.

    Fixed in 26.10.0rc1

Event History

Oct 23, 2026
CVE Published
via MITRE·08:18 PM
Data Sourced
via MITRE·08:18 PM
DescriptionSeverityWeakness
Advisory Published
via GitHub·08:45 PM
Data Sourced
via GitHub·08:45 PM
DescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

Which deployments are exposed to this denial-of-service issue?

Deployments that use Twisted's IRC server functionality, specifically twisted.words.protocols.irc.IRC or the twisted.words.service.IRCUser server subclass, are affected before version 26.10.0rc1. The issue affects the server process because the buffer is maintained per connection but can exhaust memory shared by all users.

2

Does an attacker need an IRC account or valid credentials?

No. Buffering occurs before PASS, NICK, or USER authentication commands, so an unauthenticated remote connection can trigger the issue.

3

What traffic triggers the memory exhaustion?

An attacker can continuously send bytes without a line-feed character. The affected code retains those bytes in a per-connection buffer without enforcing a maximum line length, allowing the buffer to grow until the process runs out of memory.

4

What is the available remediation?

Upgrade Twisted to version 26.10.0rc1, which fixes the issue.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203