Skip to content

Commit f0b77d3

Browse files
committed
update doc - chacha20poly1305_memory + gcm_memory
1 parent ad4b041 commit f0b77d3

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

doc/crypt.tex

+6
Original file line numberDiff line numberDiff line change
@@ -2305,6 +2305,9 @@ \subsection{One--Shot Packet}
23052305
This will initialize the GCM state with the given key, IV and AAD value then proceed to encrypt or decrypt the message text and store the final
23062306
message tag. The definition of the variables is the same as it is for all the manual functions.
23072307

2308+
IMPORTANT NOTICE: for \textit{direction == GCM\_DECRYPT} the caller has to fill \textit{tag} and \textit{taglen} with expected
2309+
tag value. The \textit{gcm\_memory} in decrypt mode validates the \textit{tag} value and returns \textit{CRYPT\_ERROR} on mismatch.
2310+
23082311
If you are processing many packets under the same key you shouldn't use this function as it invokes the pre--computation with each call.
23092312

23102313
\subsection{Example Usage}
@@ -2515,6 +2518,9 @@ \subsection{One--Shot Packet}
25152518
\textbf{CHACHA20POLY1305\_DECRYPT}) the message text and store the final message tag. The definition of the
25162519
variables is the same as it is for all the manual functions.
25172520

2521+
IMPORTANT NOTICE: for \textit{direction == CHACHA20POLY1305\_DECRYPT} the caller has to fill \textit{tag} and \textit{taglen} with expected
2522+
tag value. The \textit{chacha20poly1305\_memory} in decrypt mode validates the \textit{tag} value and returns \textit{CRYPT\_ERROR} on mismatch.
2523+
25182524
\chapter{One-Way Cryptographic Hash Functions}
25192525
\mysection{Core Functions}
25202526
Like the ciphers, there are hash core functions and a universal data type to hold the hash state called \textit{hash\_state}. To initialize hash

0 commit comments

Comments
 (0)