I brought a wss://
server up using websocat
:
websocat -E -t -v --pkcs12-der=q.pkcs12 wss-listen:0.0.0.0:8443 mirror:
And on the client I am running this command to establish a secure WebSocket connection:
websocat wss://<server-ip>:8443
I can send text using this setup and whatever I send gets echoed back. But now I want to send files on the wss://
connection. How do I do that?
This is how I am sending files using ws://
and it's working fine.
Server:
websocat -s -v 0.0.0.0:8765 > received.txt
Client:
websocat -b ws://<server-ip>:8765 < testfile.txt
I tried something like this:
Server:
websocat -E -t -v --pkcs12-der=q.pkcs12 wss-listen:0.0.0.0:8443 writefile:received.txt
Client:
websocat -E -t wss://echo.websocket.org:8443 < testfile.txt
But I am getting this error:
websocat: WebSocketError: I/O failure
websocat: error running
Any help regarding how do I do it with wss://
connection will really help. Thanks.
If it's not achievable using websocat, then what other tool I can use to bring up a wss://
server and send files to it?
websocat
tool?" probably as described underwebsocat
Issue #20 - "How to transfer text and binary data in one connection?"websocat
, then what other tool I can use?", I recommend to usenetcat
. See in example Sending file vianetcat
.netcat
clients communicate over SSL? and many others ...