Open robdefeo opened 3 years ago
Is your feature request related to a problem? Please describe. Ephemeral key is not hashed in https://github.com/mailchain/mailchain/blob/f85c09ea74722525db86ce90aac433a9e729af6f/crypto/cipher/nacl/encrypter.go#L32 This is because if it is not hashed, we do not know how to prove any security property and there may be attacks against the scheme.
Describe the solution you'd like Libsodium provides an example https://github.com/jedisct1/libsodium/blob/master/src/libsodium/crypto_box/curve25519xsalsa20poly1305/box_curve25519xsalsa20poly1305.c#L45
Is your feature request related to a problem? Please describe. Ephemeral key is not hashed in https://github.com/mailchain/mailchain/blob/f85c09ea74722525db86ce90aac433a9e729af6f/crypto/cipher/nacl/encrypter.go#L32 This is because if it is not hashed, we do not know how to prove any security property and there may be attacks against the scheme.
Describe the solution you'd like Libsodium provides an example https://github.com/jedisct1/libsodium/blob/master/src/libsodium/crypto_box/curve25519xsalsa20poly1305/box_curve25519xsalsa20poly1305.c#L45