3 ms·
TCP and IP are not exactly trivial, though certainly much simpler than TLS. There's no shame in using a library for TLS, either.
by moonchild 6y ago
TCP and IP are not exactly trivial, though certainly much simpler than TLS. There's no shame in using a library for TLS, either.
- badsectoracula 6y agoSure but a socket interface is available pretty much universally and there is only one API per OS about it to access it, so no worries about breaking libraries or whatever - and really all OSes pretty much use the same API. TLS on the other hand has multiple implementations and the situation is different per OS. I'm not sure how stable the APIs are either or if you can release -say- a binary that can expect that the API will be there (like you can expect a socket API to be there). (and besides if for what you're doing you need to implement TCP/IP, requiring TLS is still additional work) I think Windows does have a stable TLS API, but TBH i'm not sure about macOS (though it isn't like macOS is the bastion of stability) and AFAIK Linux doesn't have anything like that. I guess you could use OpenSSL and assume it to be there. A library could fix, but it imposes several restrictions you may not want - like the language you'll use (e.g. i might want to use Free Pascal but only C libraries are available) or the compiler version (e.g. i might want to use C89 but only C99 libraries are available). It is largely philosophical, i'd expect something like a 'tiny web for hackers' to be implementable by one person easily. It might not be practical but then again, the practical perspective is to just stick with the web.
- sloum 6y agoSolderpunk, the originator of the gemini idea and main shepherd of its direction, has on his git repository examples of clients and servers in < 100 LOC: tildegit.org/solderpunk The original idea was that it should be something anyone can implement as a weekend project. Most major languages seem to have fairly stable TLS libs (I know from the current clients that Go, Rust, Python, and some version of Lisp - cant remember which - all do).