VAITP Dataset

← Back to the dataset

CVE-2026-77528

Compressed WS frames can bypass payload limit, causing resource exhaustion.

  • CVSS 5.3
  • CWE-409
  • Resource Management
  • Remote

Autobahn Python is a WebSocket and WAMP implementation for Python that supports Twisted and asyncio. Prior to 26.7.1, WebSocket endpoints that accept permessage-deflate and rely on maxMessagePayloadSize enforce that limit against the compressed frame length before inflation but do not recheck the decompressed message size before delivery. A remote unauthenticated client can send a valid compressed frame below the configured wire-size limit that expands beyond the application message limit, causing oversized data to be allocated, joined, validated, and passed to application callbacks. This can create resource-exhaustion pressure, but the advisory does not establish confidentiality or integrity impact. This issue is fixed in version 26.7.1.

CVSS base score
5.3
Published
2026-09-18
OWASP
A05 Security Misconfiguration
Orthogonal defect classification
Checking
Code defect classification
Missing Check
Category
Resource Management
Subcategory
Resource Exhaustion
Accessibility scope
Remote
Impact
Denial of Service (DoS)
Affected component
Autobahn Python
Fixed by upgrading
Yes

Solution

Upgrade Autobahn Python to version 26.7.1 (or newer).

Vulnerable code sample

import asyncio
from autobahn.asyncio.websocket import WebSocketServerFactory, WebSocketServerProtocol

class EchoProtocol(WebSocketServerProtocol):
    # VULNERABLE: missing decompressed size check
    async def onMessage(self, payload, isBinary):
        await self.sendMessage(payload, isBinary)

def start_server():
    factory = WebSocketServerFactory("ws://localhost:9000")
    factory.maxMessagePayloadSize = 1024 * 1024  # 1 MiB
    factory.protocol = EchoProtocol
    loop = asyncio.get_event_loop()
    coro = loop.create_server(factory, '0.0.0.0', 9000)
    server = loop.run_until_complete(coro)
    loop.run_forever()

Patched code sample

import asyncio
from autobahn.asyncio.websocket import WebSocketServerFactory, WebSocketServerProtocol

class EchoProtocol(WebSocketServerProtocol):
    # FIX: enforce payload size after inflation
    async def onMessage(self, payload, isBinary):
        if len(payload) > self.factory.maxMessagePayloadSize:
            await self.sendClose(1009, "Message too big")
            return
        await self.sendMessage(payload, isBinary)

def start_server():
    factory = WebSocketServerFactory("ws://localhost:9000")
    factory.maxMessagePayloadSize = 1024 * 1024  # 1 MiB
    factory.protocol = EchoProtocol
    loop = asyncio.get_event_loop()
    coro = loop.create_server(factory, '0.0.0.0', 9000)
    server = loop.run_until_complete(coro)
    loop.run_forever()

Published fix

Public sources link this CVE to the changes below. The code samples above were generated to illustrate the defect; these links lead to the code the project actually changed.

  • Fix 1909 (#1916) (crossbario/autobahn-python)
    src/autobahn/websocket/interfaces.py · IWebSocketClientChannelFactory.setProtocolOptions, src/autobahn/websocket/interfaces.py · IWebSocketServerChannelFactory.setProtocolOptions, src/autobahn/websocket/protocol.py · WebSocketProtocol.onFrameData

Cite this entry

@misc{vaitp:cve202677528,
  title        = {{Compressed WS frames can bypass payload limit, causing resource exhaustion.}},
  author       = {Bogaerts, Fr\'ed\'eric and Ivaki, Naghmeh and Fonseca, Jos\'e},
  year         = {2026},
  note         = {VAITP Python Vulnerability Dataset, entry CVE-2026-77528},
  howpublished = {\url{https://netpack.pt/vaitp/vulnerability/CVE-2026-77528/}}
}

Download this entry as JSON Download the whole dataset

Introducing the "VAITP dataset": a specialized repository of Python vulnerabilities and patches, meticulously compiled for the use of the security research community. As Python's prominence grows, understanding and addressing potential security vulnerabilities become crucial. Crafted by and for the cybersecurity community, this dataset offers a valuable resource for researchers, analysts, and developers to analyze and mitigate the security risks associated with Python. Through the comprehensive exploration of vulnerabilities and corresponding patches, the VAITP dataset fosters a safer and more resilient Python ecosystem, encouraging collaborative advancements in programming security.

The supreme art of war is to subdue the enemy without fighting.

Sun Tzu – “The Art of War”

:: Shaping the future through research and ingenuity ::

Before you use the VAITP AI models

Please read and accept the following disclaimer:

By choosing "I understand and accept", you acknowledge that you understand and agree to these terms.