websocket problems

 
Post new topic   Reply to topic    Aprelium Forum Index -> General Questions
View previous topic :: View next topic  
Author Message
sands
-


Joined: 28 Jun 2018
Posts: 4

PostPosted: Tue Jun 30, 2020 4:01 pm    Post subject: websocket problems Reply with quote

hey, i have a queestion about websockets...
i'm using abyss x2, wersion 2.14.

i made backend for websocket,
connected it to reverse proxy and it fails after handshake.

handshake goes like this:
client sends request:

GET /x HTTP/1.1
Host: x.x.x.x:1001
Connection: Upgrade
Pragma: no-cache
Cache-Control: no-cache
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.116 Safari/537.36
Upgrade: websocket
Origin: https://www.mydomain.si
Sec-WebSocket-Version: 13
Accept-Language: en-US,en;q=0.9,sl-SI;q=0.8,sl;q=0.7,si;q=0.6,da;q=0.5
Sec-WebSocket-Key: 6t+OSoZWgUnJ56JCSSMHXg==
Sec-WebSocket-Extensions: permessage-deflate; client_max_window_bits
Sec-WebSocket-Protocol: protocolOne
X-Forwarded-Host: ws.mydomain.si
X-Forwarded-Server: ws.mydomain.si
X-Forwarded-Proto: https
X-Forwarded-Port: 443
X-Forwarded-For: x.x.x.x
X-Real-IP: x.x.x.x


ws server answers to client:

HTTP/1.1 101 Switching Protocols
Upgrade: WebSocket
Connection: Upgrade
Sec-WebSocket-Accept: sTH/MrwZNa58okwg1nAsSDeOK14=
Sec-WebSocket-Protocol: protocolOne
Sec-WebSocket-Extensions: permessage-deflate

clients creates connection but when data is starting to flow it is gibberish...

it seems like compression is used and i get compressed data.
i tried everything (turning compression of, on www and ws hosts ... but it just does not work. After handshake i cannot get clear data to my WS server.
Back to top View user's profile Send private message
sands
-


Joined: 28 Jun 2018
Posts: 4

PostPosted: Wed Jul 01, 2020 10:25 am    Post subject: websocket problems Reply with quote

solved.. worked all night: i thought data will bi in plain text, but it is fragmented and it must be decoded. If anyone is interested in building webSocketServers ... contact me :D
Back to top View user's profile Send private message
admin
Site Admin


Joined: 03 Mar 2002
Posts: 1295

PostPosted: Mon Jul 06, 2020 6:06 pm    Post subject: Re: websocket problems Reply with quote

sands wrote:
solved.. worked all night: i thought data will bi in plain text, but it is fragmented and it must be decoded. If anyone is interested in building webSocketServers ... contact me :D


Out of curiosity, what language and WebSockets library have you used?
_________________
Follow @abyssws on Twitter
Subscribe to our newsletter
_________________
Forum Administrator
Aprelium - https://aprelium.com
Back to top View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> General Questions All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group