-
Notifications
You must be signed in to change notification settings - Fork 237
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Invalid WebSocket frame: RSV2 and RSV3 must be clear #908
Comments
Thanks for reporting! Would you like to send a Pull Request to address this issue? |
Also a unit test would be amazing. |
I can reliably crash mercurius locally with the following snippet:
Hopefully will help us finding a resolution! |
I think I got it.
in https://github.com/fastify/fastify-websocket/blob/master/index.js#L63 I'll work on a PR later. |
I've opened a PR on |
@mcollina thank you for merging the PR. |
The |
@mcollina the PR is ready ❤️ |
This was fixed in |
I just figured out the issue still happen in some scenarios. Will dig more tomorrow, but I'm able to crash my server defining the protocol, e.g.:
|
Good afternoon,
I'm writing to report an important websocket issue.
I would have loved to send a PR, but the reality of the facts is that so far I've not been able to even reproduce the issue.
I'm sure this is going to be useful for someone else and we can find some workaround together.
Impact
The server crash with:
I believe this started happening since an upgrade to
node 18
.Preliminary Analysis
Digging over the internet, I found some recent resources that well describe what happens.
Recent conversation on
websocket/ws issue 1354
.Recent workaround on trpc 2522.
Summary: it looks like some safari browsers are buggy and set some bits without negotiating them with the server.
If the workaround on trpc actually works, I'm not sure why this would not be enough:
https://github.com/mercurius-js/mercurius/blob/master/lib/subscription-client.js#L86
The text was updated successfully, but these errors were encountered: