title: Cannot connect to secure socket.io server : ERR_SSL_PROTOCOL_ERROR
body: <p>I'm trying to use <a href="http://socket.io/" rel="noreferrer">socket.io</a> with existing application. My application runs on <a href="https://somedomain.com" rel="noreferrer">https://somedomain.com</a>. Its using this code to connect to socket io server:</p>
  
  <pre><code> var socket = io('https://localhost:3456/');
    socket.on('connect', function () {
      socket.send('hi');
  
      socket.on('message', function (msg) {
        // my msg
      });
    });
  </code></pre>
  
  <p>My socket.io server has this code to listen to incoming connections:</p>
  
  <pre><code>var io = require('socket.io').listen(3456);
  
  io.sockets.on('connection', function(socket) {
      console.log("dupa");
      socket.on('message', function() {});
      socket.on('disconnect', function() {});
  });
  </code></pre>
  
  <p>dupa is never displayed on server side and in Chrome browser console I receive:</p>
  
  <pre><code>GET https://localhost:3456/socket.io/?EIO=3&amp;transport=polling&amp;t=1412901063154-0 net::ERR_SSL_PROTOCOL_ERROR 
  </code></pre>
  
  <p>How can I get this possibly working?</p>