Skip to content

http: "upgrade" event not triggered with a Firefox client #588

@silverwind

Description

@silverwind

Below packet from a Firefox client doesn't trigger an "upgrade" event. I've tested two different websocket libraries so far which aren't able to handshake when running on io.js but are able to do on node 0.10.35. Also, Chrome seems unaffected, so I suspect something in the packet itself triggering this bug.

Packet from Wireshark:

Frame 98: 559 bytes on wire (4472 bits), 559 bytes captured (4472 bits)
Raw packet data
Internet Protocol Version 4, Src: 127.0.0.1 (127.0.0.1), Dst: 127.0.0.1 (127.0.0.1)
Transmission Control Protocol, Src Port: 3258 (3258), Dst Port: 8989 (8989), Seq: 1, Ack: 1, Len: 519
Hypertext Transfer Protocol
    GET / HTTP/1.1\r\n
    Host: localhost:8989\r\n
    User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:35.0) Gecko/20100101 Firefox/35.0\r\n
    Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8\r\n
    Accept-Language: en-US,en;q=0.5\r\n
    Accept-Encoding: gzip, deflate\r\n
    Sec-WebSocket-Version: 13\r\n
    Origin: http://localhost:8989\r\n
    Sec-WebSocket-Key: LCDSLtOtfufP3W706y+1bw==\r\n
    Cookie: s=tJTkrO8mlzGBz/K3HUzcf3TnS5pJbfAJJ8FtzPznnCA=\r\n
    Connection: keep-alive, Upgrade\r\n
    Pragma: no-cache\r\n
    Cache-Control: no-cache\r\n
    Upgrade: websocket\r\n
    \r\n
    [Full request URI: http://localhost:8989/]
    [HTTP request 1/1]

Metadata

Metadata

Assignees

No one assigned

    Labels

    confirmed-bugIssues with confirmed bugs.httpIssues or PRs related to the http subsystem.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions