Status/error codes of sxsymcrypt functions
STATUSCODES_API_FILE Macro
C
#define STATUSCODES_API_FILE
@file @copyright Copyright (c) 2019 Silex Insight. All Rights reserved.
The function or operation succeeded */
Waiting on the hardware to process this operation */
SX_ERR_HW_PROCESSING Macro
C
#define SX_ERR_HW_PROCESSING -1
No hardware available for a new operation. Retry later. */
No compatible hardware for this operation.
SX_ERR_INCOMPATIBLE_HW Macro
C
#define SX_ERR_INCOMPATIBLE_HW -3
This error occurs if the dedicated hardware to execute the operation is not present, or hardware is present and operation not supported by it.
Invalid authentication tag in authenticated decryption */
Hardware DMA error
SX_ERR_DMA_FAILED Macro
C
#define SX_ERR_DMA_FAILED -32
Fatal error that should never happen. Can be caused by invalid or wrong addresses, RAM corruption, a hardware or software bug or system corruption.
Fatal error, trying to call a function with an uninitialized object
SX_ERR_UNITIALIZED_OBJ Macro
C
#define SX_ERR_UNITIALIZED_OBJ -33
For example calling sx_aead_decrypt() with an sxaead object which has not been created yet with sx_aead_create_() function.
Fatal error, trying to call an AEAD or block cipher create function with an
SX_ERR_INVALID_KEYREF Macro
C
#define SX_ERR_INVALID_KEYREF -34
uninitialized or invalid key reference.
Examples: calling sx_blkcipher_create_aesecb() with a key reference which has not been initialized yet with sx_keyref_load_material() or sx_keyref_load_by_id() function, sx_keyref_load_material() was called with key NULL or size 0, or sx_keyref_load_by_id() was called with an invalid index ID.
Fatal error, trying to create instance with not enough memory */
Input or output buffer size too large */
SX_ERR_TOO_BIG Macro
C
#define SX_ERR_TOO_BIG -64
Input or output buffer size too small */
The given key size is not supported by the algorithm or the hardware */
SX_ERR_INVALID_KEY_SZ Macro
C
#define SX_ERR_INVALID_KEY_SZ -66
Input tag size is invalid */
Input nonce size is invalid */
SX_ERR_INVALID_NONCE_SIZE Macro
C
#define SX_ERR_INVALID_NONCE_SIZE -68
Too many feeds were inputed */
Input data size granularity is incorrect */
SX_ERR_WRONG_SIZE_GRANULARITY Macro
C
#define SX_ERR_WRONG_SIZE_GRANULARITY -70
Attempt to use HW keys with a mode that does not support HW keys */
Attempt to use a mode or engine that does not support context saving */
SX_ERR_CONTEXT_SAVING_NOT_SUPPORTED Macro
C
#define SX_ERR_CONTEXT_SAVING_NOT_SUPPORTED -72
Attempt to feed AAD after input data was fed */
Hardware cannot work anymore.
To recover, reset the hardware.