summaryrefslogtreecommitdiff
path: root/lib/POE/Component/Client/WebSocket.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/POE/Component/Client/WebSocket.pm')
-rw-r--r--lib/POE/Component/Client/WebSocket.pm5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/POE/Component/Client/WebSocket.pm b/lib/POE/Component/Client/WebSocket.pm
index 8f5ff3c..642ac64 100644
--- a/lib/POE/Component/Client/WebSocket.pm
+++ b/lib/POE/Component/Client/WebSocket.pm
@@ -433,7 +433,10 @@ sub _socket_birth {
my ($kernel, $socket, $sockid, $heap) = @_[KERNEL, ARG0, ARG3, HEAP];
if ( uc($heap->{uri}->{scheme}) eq 'WSS' ) {
- $heap->{_state}->{sslfilter} = POE::Filter::SSL->new(client=>1);
+ $heap->{_state}->{sslfilter} = POE::Filter::SSL->new(
+ client => 1,
+ sni => $heap->{uri}->{host},
+ );
$heap->{filters}->{output} = POE::Filter::Stackable->new(Filters => [ $heap->{_state}->{sslfilter} ]);
$heap->{filters}->{input} = POE::Filter::Stackable->new(Filters => [ $heap->{_state}->{sslfilter} ]);