{"id":"GHSA-3rp8-rxj8-mvjw","kind":"vulnerability","aliases":["GHSA-3rp8-rxj8-mvjw"],"related":[],"title":"WebSocket max_msg_size bypass via integer overflow","description":"### Summary\n\nThe `max_msg_size` check in the WebSocket reader added the declared frame length to the size of the partial message already buffered. In the C extension this addition is 64-bit arithmetic, so a declared length close to 2**63 overflowed and the check passed.\n\n### Impact\n\nAn attacker could bypass `max_msg_size` and cause unbounded memory use by streaming an oversized WebSocket message after a small non-final fragment.\n\n### Workaround\n\nIf unable to upgrade, the Python reader is unaffected and can be used with `AIOHTTP_NO_EXTENSIONS=1`.\n\n---\n\nPatch: https://github.com/aio-libs/aiohttp/commit/8cfbe9abe5e11b84006a10f9bdf82bf607671dab","summary":"aiohttp's WebSocket reader in its C extension miscalculates the size check for a declared frame length, so a very large declared length passes the max_msg_size limit. An attacker can stream an oversized message after a small non-final fragment and drive the server into unbounded memory use.","severity":"high","cvss":7.5,"epss":null,"exploited":false,"exploited_at":null,"products":[{"name":"aiohttp","fixed":["3.14.4"],"affected":"<= 3.14.3","ecosystem":"pypi"}],"ecosystems":["pypi"],"tags":["aiohttp","cwe-770","package","python","self-hosted","websocket"],"not_affected_if":["no-websocket-endpoints","patched-3.14.4","python-reader-only"],"how_to_check":"- Check the installed version with `pip show aiohttp`; versions at or below `3.14.3` are affected.\n- Check whether the C extension is in use: if `AIOHTTP_NO_EXTENSIONS` is not set, the C reader is active.\n- Check whether the app accepts WebSocket connections from untrusted clients.","fix":"- aiohttp: move to `3.14.4`\n- Workaround from the advisory: set `AIOHTTP_NO_EXTENSIONS=1` to use the Python reader, which is stated to be unaffected.","status":"open","published_at":"2026-11-08T18:20:46+00:00","first_seen_at":"2026-11-09T22:53:22+00:00","triaged_at":"2026-11-09T22:54:19+00:00","updated_at":"2026-11-09T22:54:19+00:00","category":"package","confidence":0.8,"triage":{"at":"2026-11-09T22:54:19Z","model":"claude-haiku-5-5","output":{"fix":"- aiohttp: move to `3.14.4`\n- Workaround from the advisory: set `AIOHTTP_NO_EXTENSIONS=1` to use the Python reader, which is stated to be unaffected.","reach":"internet","title":"aiohttp: integer overflow lets WebSocket messages bypass the size limit","impact":"medium","summary":"aiohttp's WebSocket reader in its C extension miscalculates the size check for a declared frame length, so a very large declared length passes the max_msg_size limit. An attacker can stream an oversized message after a small non-final fragment and drive the server into unbounded memory use.","audience":"developers","category":"package","nicknames":[],"who_cares":["aiohttp","python","websocket","self-hosted"],"confidence":0.8,"fix_status":"available","needs_auth":"unknown","worst_case":"Attacker drives unbounded server memory use via oversized WebSocket messages.","analyst_note":"","how_to_check":"- Check the installed version with `pip show aiohttp`; versions at or below `3.14.3` are affected.\n- Check whether the C extension is in use: if `AIOHTTP_NO_EXTENSIONS` is not set, the C reader is active.\n- Check whether the app accepts WebSocket connections from untrusted clients.","plain_action":"","product_name":"","needs_analyst":false,"not_affected_if":["no-websocket-endpoints","python-reader-only","patched-3.14.4"],"who_is_affected":"Any application that runs aiohttp as a WebSocket server or accepts WebSocket messages from clients and relies on max_msg_size to limit memory use. The flaw is in the C extension path; applications that only make outbound client calls or do not expose WebSocket endpoints are less exposed. Teams running the pure Python reader are stated to be unaffected.","user_interaction":"no","product_ecosystem":"","needs_special_setup":"no","severity_if_unknown":"high"},"cost_usd":0.000816,"input_tokens":4776,"output_tokens":677,"severity_before":"high"},"analyst_status":null,"analyst_note":null,"search":"'-770':22B '/aio-libs/aiohttp/commit/8cfbe9abe5e11b84006a10f9bdf82bf607671dab':175C '1':171C '2':120C '3rp8':11A,16A '63':121C '64':111C 'add':90C 'addit':109C 'aiohttp':19A,20B,29B,168C 'alreadi':102C 'arithmet':113C 'attack':59B,129C 'bit':112C 'buffer':103C 'bypass':5A,131C 'c':35B,106C 'caus':136C 'check':40B,85C,125C 'close':118C 'could':130C 'cwe':21B 'declar':43B,50B,92C,116C 'drive':73B 'extens':36B,107C,170C 'final':70B,151C 'fragment':71B,152C 'frame':44B,93C 'ghsa':10A,15A 'ghsa-3rp8-rxj8-mvjw':9A,14A 'github.com':174C 'github.com/aio-libs/aiohttp/commit/8cfbe9abe5e11b84006a10f9bdf82bf607671dab':173C 'host':27B 'impact':127C 'integ':7A 'larg':49B 'length':45B,51B,94C,117C 'limit':57B 'max':2A,54B,82C,132C 'memori':78B,138C 'messag':64B,101C,145C 'miscalcul':37B 'msg':3A,55B,83C,133C 'mvjw':13A,18A 'non':69B,150C 'non-fin':68B,149C 'overflow':8A,122C 'overs':63B,143C 'packag':23B 'partial':100C 'pass':52B,126C 'patch':172C 'python':24B,159C 'reader':32B,89C,160C 'rxj8':12A,17A 'self':26B 'self-host':25B 'server':75B 'size':4A,39B,56B,84C,97C,134C 'small':67B,148C 'stream':61B,141C 'summari':80C 'unabl':155C 'unaffect':162C 'unbound':77B,137C 'upgrad':157C 'use':79B,139C,166C 'via':6A 'websocket':1A,28B,31B,88C,144C 'workaround':153C","nicknames":[],"mitigations":[],"who_affected":"Any application that runs aiohttp as a WebSocket server or accepts WebSocket messages from clients and relies on max_msg_size to limit memory use. The flaw is in the C extension path; applications that only make outbound client calls or do not expose WebSocket endpoints are less exposed. Teams running the pure Python reader are stated to be unaffected.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"developers","plain_action":null,"pkeys":["aiohttp"],"ptokens":["aiohttp"],"labels":["aiohttp","cwe770","high","package","pypi","python","selfhosted","websocket"],"campaign_type":null,"search_a":"'3rp8':11A,16A 'aiohttp':19A 'bypass':5A 'ghsa':10A,15A 'ghsa-3rp8-rxj8-mvjw':9A,14A 'integ':7A 'max':2A 'msg':3A 'mvjw':13A,18A 'overflow':8A 'rxj8':12A,17A 'size':4A 'via':6A 'websocket':1A","search_b":"'-770':22B 'aiohttp':20B,29B 'attack':59B 'c':35B 'check':40B 'cwe':21B 'declar':43B,50B 'drive':73B 'extens':36B 'final':70B 'fragment':71B 'frame':44B 'host':27B 'larg':49B 'length':45B,51B 'limit':57B 'max':54B 'memori':78B 'messag':64B 'miscalcul':37B 'msg':55B 'non':69B 'non-fin':68B 'overs':63B 'packag':23B 'pass':52B 'python':24B 'reader':32B 'self':26B 'self-host':25B 'server':75B 'size':39B,56B 'small':67B 'stream':61B 'unbound':77B 'use':79B 'websocket':28B,31B","search_c":"'/aio-libs/aiohttp/commit/8cfbe9abe5e11b84006a10f9bdf82bf607671dab':175C '1':171C '2':120C '63':121C '64':111C 'add':90C 'addit':109C 'aiohttp':168C 'alreadi':102C 'arithmet':113C 'attack':129C 'bit':112C 'buffer':103C 'bypass':131C 'c':106C 'caus':136C 'check':85C,125C 'close':118C 'could':130C 'declar':92C,116C 'extens':107C,170C 'final':151C 'fragment':152C 'frame':93C 'github.com':174C 'github.com/aio-libs/aiohttp/commit/8cfbe9abe5e11b84006a10f9bdf82bf607671dab':173C 'impact':127C 'length':94C,117C 'max':82C,132C 'memori':138C 'messag':101C,145C 'msg':83C,133C 'non':150C 'non-fin':149C 'overflow':122C 'overs':143C 'partial':100C 'pass':126C 'patch':172C 'python':159C 'reader':89C,160C 'size':84C,97C,134C 'small':148C 'stream':141C 'summari':80C 'unabl':155C 'unaffect':162C 'unbound':137C 'upgrad':157C 'use':139C,166C 'websocket':88C,144C 'workaround':153C","cause_entry":null,"cause_path":null,"disclosures_checked_at":null,"first_public_at":"2026-11-08T18:20:46+00:00","kev":null,"cvss_vector":null,"cvss_by":null,"poc_count":0,"sources":[{"source":"ghsa-repo","external_id":"GHSA-3rp8-rxj8-mvjw","url":"https://github.com/aio-libs/aiohttp/security/advisories/GHSA-3rp8-rxj8-mvjw","severity":"high","published_at":"2026-11-08T18:20:46+00:00","modified_at":"2026-11-08T18:20:46+00:00","first_seen_at":"2026-11-09T22:53:22+00:00","fetched_at":"2026-11-09T22:53:22+00:00","note":null}],"documents":[{"id":110559,"url":"https://github.com/aio-libs/aiohttp/security/advisories/GHSA-3rp8-rxj8-mvjw","title":"Maintainer's advisory: github.com","kind":"vendor","source":"ghsa-repo","publisher":"vendor","text":null,"published_at":null,"relation":"advisory","confidence":null,"note":"Maintainer's advisory: github.com"}],"disclosures":[],"exploit_sources":[],"notice":"Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai"}