Skip to content
This repository has been archived by the owner on Apr 30, 2021. It is now read-only.

No way to add custom handshake headers #38

Open
jef-sure opened this issue Aug 27, 2016 · 3 comments
Open

No way to add custom handshake headers #38

jef-sure opened this issue Aug 27, 2016 · 3 comments

Comments

@jef-sure
Copy link
Contributor

I need to set "Sec-WebSocket-Extensions" header.

@plicease
Copy link
Contributor

It doesn't seem to be well documented, but there is this code in t/draft-ietf-hybi-17/request.t, which sets a custom header:

    my $req = Protocol::WebSocket::Request->new(
        host   => 'server.example.com',
        origin => 'http://example.com',
        resource_name => '/chat',
        key           => 'dGhlIHNhbXBsZSBub25jZQ==',
        headers => ['X-Foo' => 'bar']
    );

@jef-sure
Copy link
Contributor Author

jef-sure commented Oct 25, 2016

Does it work for Protocol::WebSocket::Handshake::Server ? @vti already told me that it lacks needed method.

@plicease
Copy link
Contributor

ah may not. I am only using this for the client.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants