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

Add "unsafe" API for complex features #40

Open
eth-r opened this issue Dec 23, 2017 · 0 comments
Open

Add "unsafe" API for complex features #40

eth-r opened this issue Dec 23, 2017 · 0 comments

Comments

@eth-r
Copy link

eth-r commented Dec 23, 2017

It seems that there are a number of features in Libsodium that can be useful in some situations, while posing additional risks to the unwary user, eg. keypair derivation from a known seed: #18

Additionally, the existing API in Saltine already includes some functions that should be regarded as dangerous (the Crypto.Saltine.Core.Stream undetectable malleability issue, and Crypto.Saltine.Core.ScalarMult which is really an advanced feature and public key derivation/key exchange should rather be exported as specific APIs using the functions from Libsodium so people don't feel the need to build their own from the primitives).

I've been working on my own fork on exposing all interesting parts of Libsodium in Crypto.Saltine.Unsafe.* modules and only leaving the safest and easiest functionality in Crypto.Saltine.Core.*, one addition being a high-level key exchange API which exports functions for the client and server to operate on an opaque SessionKeys type, using the correct key for sending+receiving under the hood. It's not directly pull-request-compatible due to breaking API changes but I think this would be a good approach to take towards version 1.0.0.0

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

1 participant