Changes

no edit summary
Line 59: Line 59:     
=MAC=
 
=MAC=
For AES-CCM encryption, the output MAC is written to outputbufptr+(outputbuf_size-16). For AES-CCM decryption, the input MAC is located at inputbufptr+(inputbuf_size-16). For AES-CCM decryption when the calculated MAC is invalid, error-code 0xC9010401 is returned.
+
For AES-CCM encryption, the output MAC is written to outputbufptr+(totaldatasize). For AES-CCM decryption, the input MAC is located at inputbufptr+(totalassocdata+totaldatasize). For AES-CCM decryption when the calculated MAC is invalid, error-code 0xC9010401 is returned.
    
=Description=
 
=Description=
 
This is similar to [[PSPXI:EncryptDecryptAes]], except this command is only used for AES-CCM. For AES-CCM encryption, the output buffer size must include the MAC, for AES-CCM decryption the input buffer size must include the MAC.
 
This is similar to [[PSPXI:EncryptDecryptAes]], except this command is only used for AES-CCM. For AES-CCM encryption, the output buffer size must include the MAC, for AES-CCM decryption the input buffer size must include the MAC.