Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-102360 Overview
CVE-2026-102360 is an out-of-bounds read vulnerability [CWE-125] in the lib0 JavaScript library's binary decoder. The flaw affects lib0 versions 0.2.1 through 0.2.117 and 1.0.0-rc.1 through 1.0.0-rc.32. The readUint8Array function fails to validate the wire-supplied length against the decoder's buffer view. An unauthenticated remote peer can supply an oversized length prefix and receive adjacent process memory contents. Exposed data may include other tenants' document content, personal data, and live bearer session tokens. The vulnerability is patched in versions 0.2.118 and 1.0.0-rc.33.
Critical Impact
Unauthenticated remote attackers can read adjacent process memory containing session tokens, credentials, and tenant data from any host running vulnerable lib0 versions.
Affected Products
- lib0 versions 0.2.1 through 0.2.117
- lib0 versions 1.0.0-rc.1 through 1.0.0-rc.32
- Downstream consumers of lib0 (including Yjs-based collaborative applications)
Discovery Timeline
- 2026-09-29 - CVE-2026-102360 published to NVD
- 2026-09-30 - Last updated in NVD database
Technical Details for CVE-2026-102360
Vulnerability Analysis
The lib0 library provides low-level binary encoding and decoding primitives used by Yjs and related collaborative frameworks. The readUint8Array function in decoding.js accepts a length parameter derived from attacker-controlled wire data. Without a bounds check, the function constructs a Uint8Array view over the underlying buffer starting at the current position with the supplied length.
When the requested length exceeds the remaining buffer, the returned view spans memory beyond the decoded message. Because JavaScript ArrayBuffer instances back onto contiguous heap memory, the disclosed region may contain data from prior allocations. In server-side Node.js deployments, this includes fragments of other requests, session tokens, and cached document state.
The vulnerability becomes exploitable when consumer applications echo, store, or re-serve the decoded value. Collaborative editing servers that broadcast document updates to peers effectively hand the leaked memory back to the attacker over the wire.
Root Cause
The root cause is a missing bounds check in readUint8Array. The function trusted the caller-supplied len argument, which originates from decoded binary protocol fields. No comparison was made against decoder.arr.length - decoder.pos before instantiating the Uint8Array view.
Attack Vector
An attacker who can send bytes to any endpoint that feeds a lib0 decoder can trigger the read. This includes pre-authentication code paths such as initial WebSocket handshakes and document sync messages. The attacker crafts a message with an inflated length prefix and reads the returned buffer, either directly in the response or after the server rebroadcasts the state.
// Patched code in src/decoding.js (lib0)
export const readUint8Array = (decoder, len) => {
if (len < 0 || len > decoder.arr.length - decoder.pos) {
throw errorUnexpectedEndOfArray
}
const view = new Uint8Array(decoder.arr.buffer, decoder.pos + decoder.arr.byteOffset, len)
decoder.pos += len
return view
}
// Source: https://github.com/dmonad/lib0/commit/c4c9db0b41346a33aff31a51f1f09c3a17757f10
Detection Methods for CVE-2026-102360
Indicators of Compromise
- Inbound binary protocol messages containing length prefixes that exceed the enclosing frame size.
- Anomalous outbound responses from collaborative sync endpoints containing high-entropy data or fragments resembling JWTs, cookies, or JSON payloads unrelated to the current document.
- WebSocket sessions from unauthenticated peers issuing malformed sync messages followed by immediate disconnects.
Detection Strategies
- Perform dependency inventory scans to identify installed versions of lib0 and transitive dependents such as Yjs, y-websocket, and y-protocols.
- Instrument the readUint8Array code path in non-production environments to log length arguments exceeding remaining buffer size.
- Inspect network telemetry for oversized Uint8Array length prefixes in Yjs sync messages before they reach the decoder.
Monitoring Recommendations
- Monitor process memory patterns and outbound message sizes on collaborative editing servers for unexpected growth.
- Alert on errorUnexpectedEndOfArray exceptions once patched, which indicate attempted exploitation.
- Review Software Bill of Materials (SBOM) output for the lib0 package across build pipelines and container images.
How to Mitigate CVE-2026-102360
Immediate Actions Required
- Upgrade lib0 to version 0.2.118 or 1.0.0-rc.33 across all applications and container images.
- Rebuild and redeploy any downstream package that bundles lib0, including Yjs-based servers and clients.
- Rotate bearer tokens, session cookies, and any secrets that may have resided in process memory on exposed servers.
Patch Information
The fix adds an explicit bounds check to readUint8Array that throws errorUnexpectedEndOfArray when the requested length is negative or exceeds the remaining buffer. The patch is available in the GitHub Security Advisory GHSA-r5c8-rf4w-qrq8 and applied in the decoding.js commit.
Workarounds
- Place an authenticated reverse proxy or WebSocket gateway in front of collaborative endpoints to prevent unauthenticated peers from reaching the decoder.
- Enforce strict message-size limits at the transport layer to reject frames whose declared length fields exceed the physical payload size.
- Isolate collaborative editing workloads into per-tenant processes so that leaked memory cannot cross tenant boundaries.
# Upgrade lib0 to a patched release
npm install lib0@0.2.118
# or for release-candidate consumers
npm install lib0@1.0.0-rc.33
# Verify installed version
npm ls lib0
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

