TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Simple NaCL/libsodium-based TLS replacement

1 pointsby ciprian_craciunabout 5 years ago

1 comment

ciprian_craciunabout 5 years ago
This encryption protocol is meant as a simpler replacement for TLS in the context of the `gemini:&#x2F;&#x2F;` protocol (<a href="https:&#x2F;&#x2F;gemini.circumlunar.space&#x2F;" rel="nofollow">https:&#x2F;&#x2F;gemini.circumlunar.space&#x2F;</a>), a newer `gopher:&#x2F;&#x2F;` alternative, which basically provides a simpler HTTP `GET`-only alternative.<p>Simpler means both &quot;simpler to implement&quot; (only having `libsodium` as a dependency) and &quot;simpler to comprehend&quot;. (However it can be used for any other message-based protocol, not strictly request-reply.)<p>I&#x27;m submitting it here in the hope that anyone with a strong cryptographic background can provide some insight into any weaknesses or improvements. (Or alternatively pointers where I could ask this question.)<p>Please note that I have limited cryptography experience, but I am well aware that &quot;rolling your own crypto&quot; is an extremely stupid idea. However I didn&#x27;t &quot;invent&quot; any new cryptographic primitives, but instead relied heavily on what `libsodium` provides. Moreover I&#x27;ve looked at both the Noise protocol and CurveCP and I think I got 25% of their internal workings and properties. :)<p>I think the best solution would have been Noise_XX, however implementing the full protocol is quite involving, thus it doesn&#x27;t check the &quot;simpler to implement&quot; (and neither &quot;simpler to comprehend&quot;) checkbox.<p>There is also a Python-based proof-of-concept that implements the above protocol:<p>* <a href="https:&#x2F;&#x2F;github.com&#x2F;cipriancraciun&#x2F;gemini-experiments&#x2F;blob&#x2F;master&#x2F;nacl&#x2F;sources&#x2F;transport.py" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;cipriancraciun&#x2F;gemini-experiments&#x2F;blob&#x2F;ma...</a><p>* <a href="https:&#x2F;&#x2F;github.com&#x2F;cipriancraciun&#x2F;gemini-experiments&#x2F;blob&#x2F;master&#x2F;nacl&#x2F;sources&#x2F;crypto.py" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;cipriancraciun&#x2F;gemini-experiments&#x2F;blob&#x2F;ma...</a><p>Thanks, Ciprian.