Skip to content

Cross-domain secure websockets fails (protocol mismatch) #195

@nmbhat

Description

@nmbhat

I'm using socket.io in a Google Chrome extension and when trying to make a secure socket connection to my server from the extension, I get a handshake error:
Error during WebSocket handshake: location mismatch: wss://<domain.com>/socket.io/websocket != ws://<domain.com>/socket.io/websocket

Currently I am opening the socket on the client side with:
var socket = new io.Socket('<domain.com>', {port: 443, secure: true, rememberTransport: true});

Opening a secure websocket on a web page originating from the same domain works fine -- e.g. the included ssl-chat example works.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions