CryptoSys API Library Manual
 
Aead.Authenticate Method
 Authenticate additional data using tag 
Syntax
[C#]
public static bool Authenticate(
	byte[] key,
	byte[] nonce,
	byte[] aad,
	byte[] tag,
	Aead.Algorithm alg
)
[VB.NET]
Public Shared Function Authenticate ( _
	key As Byte(), _
	nonce As Byte(), _
	aad As Byte(), _
	tag As Byte(), _
	alg As Aead.Algorithm _
) As Boolean
Parameters
  - key
 
  - Key of exact length for given algorithm (16 or 32 bytes).
 
  - nonce
 
  - Nonce of exact length for given algorithm (currently always 12 bytes)
 
  - aad
 
  - Data to be authenticated
 
  - tag
 
  - Tag value
 
  - alg
 
  - Type: Aead.Algorithm
AEAD algorithm to use 
Return Value
True if authentication is valid; false if failed or an error occurred.
Remarks
Use General.ErrorCode to find the code of the last error. This is equivalent to Aead.Decrypt with a zero-length ciphertext input.
[Contents] [Index]