On May 29, 11:08 pm, dhruvbird <[email protected]> wrote:
> So, I'm using this
> filehttps://github.com/dhruvbird/node-xmpp-bosh/blob/master/src/starttls.jsto
> upgrade from a normal socket to a secure socket and am afraid that there
> might be a bug there. I couldn't any "standard library" method to do the
> same (similar to an HTTP upgrade). I haven't dug into the http client code
> to see if there are any parts of the std. lib. that do this already.
With recent versions of node (including 0.8.x) it's much easier. You
can simply pass in a socket to tls.connect like so:
var sock = new net.Socket();
// ...
tls.connect({ socket: sock }, function() {
// secure connection!
});
--
--
Job Board: http://jobs.nodejs.org/
Posting guidelines:
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en
---
You received this message because you are subscribed to the Google Groups
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.