Skip to content

Commit

Permalink
Ensure that HTTP::WebSocket uses SNI, just like HTTP::Client.
Browse files Browse the repository at this point in the history
  • Loading branch information
bmmcginty authored and jhass committed Feb 16, 2018
1 parent 5d2fa25 commit 4f2e846
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/http/web_socket/protocol.cr
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ class HTTP::WebSocket::Protocol
else
context = tls
end
socket = OpenSSL::SSL::Socket::Client.new(socket, context: context, sync_close: true)
socket = OpenSSL::SSL::Socket::Client.new(socket, context: context, sync_close: true, hostname: host)
end
{% end %}

Expand Down

0 comments on commit 4f2e846

Please sign in to comment.