websocket-driver-ruby: Denial of service via malformed Host header
Published 21 Jul 2026 · Updated 2 Nov 2026
Is your project on an affected websocket-driver?
Look after several Rails or Ruby apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Affected package
- Affected
- <0.8.2
- Fixed in
- 0.8.2
bundle update --conservative websocket-driver # Gemfile: '>= 0.8.2'Details
Impact
If this library is used to implement a WebSocket server on top of a TCP server, by using the WebSocket::Driver.server() method, then a client can cause the server to crash by sending a Host header that is not a valid host[:port] string. When this happens, a URI::InvalidURIError exception is raised which is not caught, and this can cause the server process to crash if the application does not catch the error from the parse() method itself.
Patches
The issue has been patched in version 0.8.2 by making the request parser catch URI::InvalidURIError and enter an error state if the Host header is malformed. This means the request is considered invalid and should not establish a WebSocket connection.
Workarounds
No known workarounds exist.
Acknowledgements
This issue was discovered and reported by Pranjali Thakur, DepthFirst Security Research Team.
Is GHSA-2x63-gw47-w4mm in any of your client repos?
Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected websocket-driver, and gives you the command that fixes it.
More advisories for websocket-driver
- MediumCVE-2026-54465websocket-driver: Memory exhaustion in HTTP header parser · 15 Jul 2026
- MediumCVE-2026-54464websocket-driver: Resource limit bypass via message compression · 15 Jul 2026
- MediumCVE-2026-54463websocket-driver: Memory exhaustion via abuse of protocol length headers · 15 Jul 2026
References
- Linkgithub.com/faye/websocket-driver-ruby/security/advisories/GHSA-2x63-gw47-w4mm
- Advisorynvd.nist.gov/vuln/detail/CVE-2026-61666
- Linkgithub.com/faye/websocket-driver-ruby/commit/7d6fd87759a2fdc83590d3b49ffa661dc53fa128
- Packagegithub.com/faye/websocket-driver-ruby
- Linkgithub.com/rubysec/ruby-advisory-db/blob/a58f1d0a3343e85cef597970f2c5458dcfbaf909/gems/websocket-driver/CVE-2026-61666.yml
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.