Replies: 2 comments 3 replies
-
Yes, after using the key exchange API, you can use any AEAD with the shared keys.
But using the key exchange API is more versatile and easier to use correctly (since you get two keys, for each direction). |
Beta Was this translation helpful? Give feedback.
-
Yes, it is more flexible to use the key exchange API, However, I have some questions if you don't mind : Since both keys computed in the key exchange API are the same (opposite way Rx/Tx), means that the sender can always decrypt the message, which means that a compromise on one end (Alice) can decrypt the message that was sent (to Bob). Something interesting i got recommended from someone, the Noise One-Way K pattern , looks a great fit for such idea. |
Beta Was this translation helpful? Give feedback.
-
I am trying to achieve public key cryptography (authenticated) with XChaCha20-Poly1305.
is there a way to use XChaCha20-Poly1305 in the
crypto_box_easy
function?Or should i just use the Key Exchange API to compute a shared key between two parties (Alice and Bob), and then pass the key to the
crypto_secretstream_xchacha20poly1305
function?thanks.
Beta Was this translation helpful? Give feedback.
All reactions