1
0
forked from QPQ-AG/enoise

Revert "Update enacl dep and fix some minor details (#1)"

This reverts commit 479ec70870.
This commit is contained in:
Ulf Wiger
2025-03-29 20:57:45 +01:00
parent 479ec70870
commit 91916908a0
5 changed files with 16 additions and 9 deletions
+2 -1
View File
@@ -65,7 +65,8 @@ rekey(Cipher, K) ->
-spec encrypt(Cipher :: enoise_cipher_state:noise_cipher(),
Key :: binary(), Nonce :: non_neg_integer(),
Ad :: binary(), PlainText :: binary()) -> binary().
Ad :: binary(), PlainText :: binary()) ->
binary() | {error, term()}.
encrypt('ChaChaPoly', K, N, Ad, PlainText) ->
Nonce = <<0:32, N:64/little-unsigned-integer>>,
enacl:aead_chacha20poly1305_ietf_encrypt(PlainText, Ad, Nonce, K);