mirror of
https://github.com/nadoo/glider.git
synced 2025-02-23 01:15:41 +08:00
ws: remove the Sec-WebSocket-Protocol
header
This commit is contained in:
parent
aae2fc8256
commit
7c50915f20
@ -97,7 +97,6 @@ func (c *ClientConn) Handshake(host, path, origin string) error {
|
||||
buf.WriteString("Origin: http://" + origin + "\r\n")
|
||||
}
|
||||
buf.WriteString("Sec-WebSocket-Key: " + clientKey + "\r\n")
|
||||
buf.WriteString("Sec-WebSocket-Protocol: binary\r\n")
|
||||
buf.WriteString("Sec-WebSocket-Version: 13\r\n")
|
||||
buf.WriteString(("\r\n"))
|
||||
|
||||
|
@ -183,7 +183,6 @@ func (c *ServerConn) Handshake(host, path string) error {
|
||||
buf.WriteString("Upgrade: websocket\r\n")
|
||||
buf.WriteString("Connection: Upgrade\r\n")
|
||||
buf.WriteString("Sec-WebSocket-Accept: " + serverKey + "\r\n")
|
||||
buf.WriteString("Sec-WebSocket-Protocol: binary\r\n")
|
||||
buf.WriteString(("\r\n"))
|
||||
|
||||
_, err = c.Conn.Write(buf.Bytes())
|
||||
|
Loading…
Reference in New Issue
Block a user