Skip to content

Commit

Permalink
update doc - chacha20poly1305_memory + gcm_memory
Browse files Browse the repository at this point in the history
  • Loading branch information
karel-m committed Oct 29, 2018
1 parent 9a1131d commit 7d85676
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions doc/crypt.tex
Original file line number Diff line number Diff line change
Expand Up @@ -2305,6 +2305,9 @@ \subsection{One--Shot Packet}
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
message tag. The definition of the variables is the same as it is for all the manual functions.

IMPORTANT NOTICE: for \textit{direction == GCM\_DECRYPT} the caller has to fill \textit{tag} and \textit{taglen} with expected
tag value. The \textit{gcm\_memory} in decrypt mode validates the \textit{tag} value and returns \textit{CRYPT\_ERROR} on mismatch.

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.

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

IMPORTANT NOTICE: for \textit{direction == CHACHA20POLY1305\_DECRYPT} the caller has to fill \textit{tag} and \textit{taglen} with expected
tag value. The \textit{chacha20poly1305\_memory} in decrypt mode validates the \textit{tag} value and returns \textit{CRYPT\_ERROR} on mismatch.

\chapter{One-Way Cryptographic Hash Functions}
\mysection{Core Functions}
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
Expand Down

0 comments on commit 7d85676

Please sign in to comment.