Berildocs GitHub

Memory cards

WebSocket handshakes skip the same-origin policy

confidence: highupdated: 2026-11-24status: activewebwebsocketorigin

Claim#

The upgrade handler authenticates the cookie but not the Origin, or accepts a token in the query.

Test#

Open a socket from a cross-origin page with the victim cookie. Send one privileged message.

Proof#

A cross-origin socket performs an authenticated action.

Failure modes#

A socket that requires a token in the first message may still be safe. Check message auth.