I'm building a Web socket server, however, for testing purposes, I'd like Chrome or Firefox or any other browser to send the message fragmented so I can test my implementation.
I've tried even sending 100K text data and the FIN flag is always set to 1 and the opcode is TEXT.
Is there a way to manually trigger fragmented frames? Any client out there with more flexibility?
The Javascript WebSocket API does not expose this option. I recently ran into the same frustration when some more modern browsers (A Chromium derivative) was unpredictably sending fragmented WebSocket frames.
For testing I rolled my own TCP client sending pre-calculated fragmented WebSocket frames. Not ideal, but it got the job done, and AFAIK there's no alternative yet.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With