CVE-2026-22689: Bypass Websocket Origin Check

The application configures a WebSocket upgrader to bypass origin validation by unconditionally returning 'true' in 'CheckOrigin'. This exposes the WebSocket server to Cross-Site WebSocket Hijacking (CSWSH). Remove the 'CheckOrigin' field to enforce the default same-origin policy, or implement strict comparison of the 'Origin' header against a whitelist of tr

Provally CuratedPublic repositoryHighMedium confidenceVerifiedApache-2.0Go
greprules fetch cve-2026-22689-bypass-websocket-origin-check --engine opengrep

Description

The application configures a WebSocket upgrader to bypass origin validation by unconditionally returning 'true' in 'CheckOrigin'. This exposes the WebSocket server to Cross-Site WebSocket Hijacking (CSWSH). Remove the 'CheckOrigin' field to enforce the default same-origin policy, or implement strict comparison of the 'Origin' header against a whitelist of tr