pub unsafe extern "C" fn esp_aes_xts_setkey_dec(
    ctx: *mut esp_aes_xts_context,
    key: *const c_uchar,
    keybits: c_uint
) -> c_int
Expand description

\brief This function prepares an XTS context for decryption and sets the decryption key.

\param ctx The AES XTS context to which the key should be bound. \param key The decryption key. This is comprised of the XTS key1 concatenated with the XTS key2. \param keybits The size of \p key passed in bits. Valid options are:

  • 256 bits (each of key1 and key2 is a 128-bit key)
  • 512 bits (each of key1 and key2 is a 256-bit key)

\return \c 0 on success. \return #MBEDTLS_ERR_AES_INVALID_KEY_LENGTH on failure.