[Udi <
udi.t...@gmail.com> (2013-02-13 22:15:54 UTC)]
> Is it posible to connect to my
socket.io server (listening to port 6060)
> with ssl?
I do it (on a different port) without any difficulty.
Here is my setup, heavily redacted:
var https=require("https"),
fs=require("fs"),
server=https.createServer(
{
key:fs.readFileSync("/some/where/cert/mydomain.key"),
cert:fs.readFileSync("/some/where/cert/mydomain.crt"),
ca:[fs.readFileSync("/some/where/cert/sub.class1.server.ca.pem"),
fs.readFileSync("/some/where/cert/ca.pem")]
}),
io=require("
socket.io").listen(server);
after which I set up sessions with
session.socket.io, add an express
app, and other stuff that seems irrelevant to the problem at hand,
ending with
server.listen(444,function(err) {
// error handling redacted
process.setuid("someuser");});
- Harald