Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TLS #1

Open
baracoder opened this issue Jul 9, 2013 · 2 comments
Open

TLS #1

baracoder opened this issue Jul 9, 2013 · 2 comments

Comments

@baracoder
Copy link

Would it be possible to combine json-over-tcp with tls?

I have made a dirty solution for myself by replacing net.Server with tls.Server and the connection event with secureConnection but this breaks plain TCP

@unsetbit
Copy link
Contributor

unsetbit commented Jul 9, 2013

Hmm, it wasn't designed with TLS in mind, but there's no reason why it can't be used with it.

The protocol.js file is the one that does the heavy lifting and it's abstracted to the level that it just cares about streams, it has no dependencies to the 'net' package.

Server.js and socket.js are simple wrappers on the 'net' package server and connection, so you could create similar wrappers for the 'tls' server and connection and wire them to protocol.js in a similar fashion. I haven't looked at the tls api, if it's derived off of the tcp api, it may be better to just abstract out server.js and socket.js to accept any object that conforms to that api instead of creating additional files. Let me know if you have any questions on how to go about doing that.

@mauris
Copy link

mauris commented May 5, 2019

Looks like this project was done way back, but this issue #1 and project has inspired me with the Madtom implementation. See https://github.com/mauris/madtom

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants