crypto/EcdhMask carries the Jubjub key agreement inline, so a consumer that needs several masks from one shared secret (the Field pad in #735) cannot reach the shared point without going through encrypt.
Move the key agreement into its own crypto/Ecdh module: deriveShared (sender side, owns the identity-key and zero-ephemeral guards), recoverShared (recipient side), and a SharedSecret struct. EcdhMask.encrypt / decrypt delegate to it and keep their ciphertexts unchanged.
Prerequisite for #735.
PR: #866
crypto/EcdhMaskcarries the Jubjub key agreement inline, so a consumer that needs several masks from one shared secret (theFieldpad in #735) cannot reach the shared point without going throughencrypt.Move the key agreement into its own
crypto/Ecdhmodule:deriveShared(sender side, owns the identity-key and zero-ephemeral guards),recoverShared(recipient side), and aSharedSecretstruct.EcdhMask.encrypt/decryptdelegate to it and keep their ciphertexts unchanged.Prerequisite for #735.
PR: #866