CryptoAuthLib v3.7.6
Microchip CryptoAuthentication Library
 
Loading...
Searching...
No Matches
calib_config_check.h File Reference

Consistency checks for configuration options. More...

Macros

#define CALIB_SHA204_EN   DEFAULT_ENABLED
 
#define CALIB_SHA206_EN   DEFAULT_ENABLED
 
#define CALIB_ECC108_EN   DEFAULT_DISABLED
 
#define CALIB_ECC508_EN   DEFAULT_ENABLED
 
#define CALIB_ECC608_EN   DEFAULT_ENABLED
 
#define CALIB_ECC204_EN   DEFAULT_ENABLED
 
#define CALIB_TA010_EN   DEFAULT_ENABLED
 
#define CALIB_SHA104_EN   DEFAULT_ENABLED
 
#define CALIB_SHA105_EN   DEFAULT_ENABLED
 
#define CALIB_FULL_FEATURE   (CALIB_SHA204_EN || CALIB_ECC108_EN || CALIB_ECC508_EN || CALIB_ECC608_EN)
 
#define CALIB_ECC_SUPPORT   (CALIB_ECC108_EN || CALIB_ECC508_EN || CALIB_ECC608_EN || CALIB_ECC204_EN || CALIB_TA010_EN)
 
#define CALIB_CA2_SUPPORT   (CALIB_ECC204_EN || CALIB_TA010_EN || CALIB_SHA104_EN || CALIB_SHA105_EN)
 
#define CALIB_CA2_CERT_SUPPORT   (CALIB_ECC204_EN || CALIB_TA010_EN)
 
#define CALIB_SHA206_ONLY   (CALIB_SHA206_EN && !(CALIB_FULL_FEATURE || ATCA_CA2_SUPPORT))
 
#define DEFAULT_CA_MAX_PACKET_SIZE   (198u)
 
#define CA_MAX_PACKET_SIZE   (DEFAULT_CA_MAX_PACKET_SIZE)
 
#define CALIB_AES_EN   (ATCAB_AES_EN && CALIB_ECC608_EN)
 
#define CALIB_AES_GCM_EN   (ATCAB_AES_GCM_EN && CALIB_AES_EN && CALIB_ECC608_EN)
 
#define CALIB_CHECKMAC_EN   (ATCAB_CHECKMAC_EN && (CALIB_FULL_FEATURE || CALIB_SHA105_EN))
 
#define CALIB_COUNTER_EN   (ATCAB_COUNTER_EN && (CALIB_ECC_SUPPORT || CALIB_SHA104_EN || CALIB_SHA105_EN))
 
#define CALIB_DELETE_EN   (DEFAULT_DISABLED)
 
#define CALIB_DERIVEKEY_EN   (ATCAB_DERIVEKEY_EN && (CALIB_FULL_FEATURE || CALIB_SHA206_EN))
 
#define CALIB_ECDH_EN   (ATCAB_ECDH_EN && (CALIB_ECC508_EN || CALIB_ECC608_EN))
 
#define CALIB_ECDH_ENC_EN   (ATCAB_ECDH_ENC_EN && (CALIB_ECC508_EN || CALIB_ECC608_EN))
 
#define CALIB_GENDIG_EN   (ATCAB_GENDIG_EN && (CALIB_FULL_FEATURE || CALIB_SHA105_EN))
 
#define CALIB_GENDIVKEY_EN   (ATCAB_GENDIG_EN && CALIB_SHA105_EN)
 
#define CALIB_GENKEY_EN   (ATCAB_GENKEY_EN && CALIB_ECC_SUPPORT)
 
#define CALIB_GENKEY_MAC_EN   (ATCAB_GENKEY_MAC_EN && CALIB_ECC_SUPPORT)
 
#define CALIB_HMAC_EN   (ATCAB_HMAC_EN && (CALIB_SHA204_EN || CALIB_ECC108_EN || CALIB_ECC508_EN))
 
#define CALIB_INFO_LATCH_EN   ATCAB_INFO_LATCH_EN
 
#define CALIB_KDF_EN   (ATCAB_KDF_EN && CALIB_ECC608_EN)
 
#define CALIB_LOCK_EN   (ATCAB_LOCK_EN && CALIB_FULL_FEATURE)
 
#define CALIB_LOCK_CA2_EN   (ATCAB_LOCK_EN && ATCA_CA2_SUPPORT)
 
#define CALIB_MAC_EN   (ATCAB_MAC_EN && (CALIB_FULL_FEATURE || CALIB_SHA206_EN || CALIB_SHA104_EN))
 
#define CALIB_NONCE_EN   (ATCAB_NONCE_EN && (CALIB_FULL_FEATURE || CALIB_CA2_SUPPORT))
 
#define CALIB_PRIVWRITE_EN   (ATCAB_PRIVWRITE_EN && (CALIB_ECC108_EN || CALIB_ECC508_EN || CALIB_ECC608_EN))
 
#define CALIB_RANDOM_EN   (ATCAB_RANDOM_EN && CALIB_FULL_FEATURE)
 
#define CALIB_READ_EN   (ATCAB_READ_EN && (CALIB_FULL_FEATURE || CALIB_SHA206_EN))
 
#define CALIB_READ_CA2_EN   (ATCAB_READ_EN && CALIB_CA2_SUPPORT)
 
#define CALIB_READ_ENC_EN   (ATCAB_READ_ENC_EN && CALIB_FULL_FEATURE)
 
#define CALIB_SECUREBOOT_EN   (ATCAB_SECUREBOOT_EN && CALIB_ECC608_EN)
 
#define CALIB_SECUREBOOT_MAC_EN   (ATCAB_SECUREBOOT_MAC_EN && CALIB_ECC608_EN)
 
#define CALIB_SELFTEST_EN   (ATCAB_SELFTEST_EN && (CALIB_ECC608_EN || CALIB_CA2_SUPPORT))
 
#define CALIB_SHA_EN   (ATCAB_SHA_EN && (CALIB_FULL_FEATURE || CALIB_CA2_SUPPORT))
 
#define CALIB_SHA_HMAC_EN   (ATCAB_SHA_HMAC_EN && CALIB_ECC_SUPPORT)
 
#define CALIB_SHA_CONTEXT_EN   (ATCAB_SHA_CONTEXT_EN && CALIB_ECC608_EN)
 
#define CALIB_SIGN_EN   (ATCAB_SIGN_EN && (CALIB_ECC108_EN || CALIB_ECC508_EN || CALIB_ECC608_EN))
 
#define CALIB_SIGN_CA2_EN   (ATCAB_SIGN_EN && (CALIB_ECC204_EN || CALIB_TA010_EN))
 
#define CALIB_SIGN_INTERNAL_EN   (ATCAB_SIGN_INTERNAL_EN && CALIB_SIGN_EN)
 
#define CALIB_UPDATEEXTRA_EN   (ATCAB_UPDATEEXTRA_EN && CALIB_FULL_FEATURE)
 
#define CALIB_VERIFY_EN   (ATCAB_VERIFY_EN && (CALIB_ECC108_EN || CALIB_ECC508_EN || CALIB_ECC608_EN))
 
#define CALIB_VERIFY_MAC_EN   (ATCAB_VERIFY_MAC_EN && CALIB_ECC608_EN)
 
#define CALIB_VERIFY_EXTERN_EN   (ATCAB_VERIFY_EXTERN_EN && CALIB_VERIFY_EN)
 
#define CALIB_VERIFY_STORED_EN   (ATCAB_VERIFY_STORED_EN && CALIB_VERIFY_EN)
 
#define CALIB_VERIFY_VALIDATE_EN   (ATCAB_VERIFY_VALIDATE_EN && CALIB_VERIFY_EN)
 
#define CALIB_WRITE_EN   (ATCAB_WRITE_EN && (CALIB_FULL_FEATURE || CALIB_SHA206_EN))
 
#define CALIB_WRITE_ENC_EN   (ATCAB_WRITE_ENC_EN && CALIB_FULL_FEATURE)
 
#define CALIB_WRITE_CA2_EN   (ATCAB_WRITE_EN && CALIB_CA2_SUPPORT)
 

Detailed Description

Consistency checks for configuration options.

Macro Definition Documentation

◆ CALIB_INFO_LATCH_EN

#define CALIB_INFO_LATCH_EN   ATCAB_INFO_LATCH_EN

Supported API's: calib_info_get_latch calib_info_set_latch

ECC204 specific api: calib_info_lock_status

◆ CALIB_LOCK_CA2_EN

#define CALIB_LOCK_CA2_EN   (ATCAB_LOCK_EN && ATCA_CA2_SUPPORT)

Enable CALIB_LOCK_CA2_EN which enables the lock command for the ecc204 and ta010 devices

Supported API's: calib_lock

◆ CALIB_LOCK_EN

#define CALIB_LOCK_EN   (ATCAB_LOCK_EN && CALIB_FULL_FEATURE)

Enable CALIB_LOCK_EN to enable the lock commands for the classic cryptoauth parts

Supported API's: calib_lock

◆ CALIB_READ_EN

#define CALIB_READ_EN   (ATCAB_READ_EN && (CALIB_FULL_FEATURE || CALIB_SHA206_EN))

Enable CALIB_READ_EN which enables the read commands

Supported API's: calib_read_zone

◆ CALIB_SHA_CONTEXT_EN

#define CALIB_SHA_CONTEXT_EN   (ATCAB_SHA_CONTEXT_EN && CALIB_ECC608_EN)

Requires: CALIB_SHA_BASE

Use the SHA command to compute an HMAC/SHA-256 operation

Supported API's: calib_sha_read_context

◆ CALIB_SHA_EN

#define CALIB_SHA_EN   (ATCAB_SHA_EN && (CALIB_FULL_FEATURE || CALIB_CA2_SUPPORT))

Enable CALIB_SHA_EN to compute a SHA-256 or HMAC/SHA-256 digest for general purpose use by the host system

Supported API's: calib_sha_base

◆ CALIB_SHA_HMAC_EN

#define CALIB_SHA_HMAC_EN   (ATCAB_SHA_HMAC_EN && CALIB_ECC_SUPPORT)

Requires: CALIB_SHA_HMAC CALIB_SHA_BASE

Use the SHA command to compute an HMAC/SHA-256 operation

Supported API's: calib_sha_hmac,calib_sha_hmac_init, calib_sha_hmac_update, calib_sha_hmac_finish

◆ CALIB_SIGN_CA2_EN

#define CALIB_SIGN_CA2_EN   (ATCAB_SIGN_EN && (CALIB_ECC204_EN || CALIB_TA010_EN))

Enable CALIB_SIGN_CA2_EN to generate a signature using the ECDSA algorithm

Supported API's: calib_sign_base

◆ CALIB_SIGN_EN

#define CALIB_SIGN_EN   (ATCAB_SIGN_EN && (CALIB_ECC108_EN || CALIB_ECC508_EN || CALIB_ECC608_EN))

Enable CALIB_SIGN_EN to generate a signature using the ECDSA algorithm

Supported API's: calib_sign

◆ CALIB_UPDATEEXTRA_EN

#define CALIB_UPDATEEXTRA_EN   (ATCAB_UPDATEEXTRA_EN && CALIB_FULL_FEATURE)

Enable CALIB_UPDATEEXTRA_EN to update the values of the two extra bytes within the configuration zone (bytes 84 and 85)

Supported API's: calib_updateextra

◆ CALIB_VERIFY_EN

#define CALIB_VERIFY_EN   (ATCAB_VERIFY_EN && (CALIB_ECC108_EN || CALIB_ECC508_EN || CALIB_ECC608_EN))

Enable CALIB_VERIFY_EN which takes an ECDSA [R,S] signature and verifies that it is correctly generated from a given message and public key. In all cases, the signature is an input to the command

Supported API's: calib_verify

◆ CALIB_VERIFY_MAC_EN

#define CALIB_VERIFY_MAC_EN   (ATCAB_VERIFY_MAC_EN && CALIB_ECC608_EN)

Requires: CALIB_NONCE_MODE_ENCODING CALIB_NONCE_BASE ATCAH_VERIFY_MAC ATCAC_SW_SHA2_256 CALIB_VERIFY

Executes verification command with verification MAC for the External or Stored Verify modes

Supported API's: calib_verify_extern_stored_mac, calib_verify_extern_mac, calib_verify_stored_mac

◆ CALIB_VERIFY_STORED_EN

#define CALIB_VERIFY_STORED_EN   (ATCAB_VERIFY_STORED_EN && CALIB_VERIFY_EN)

Requires: CALIB_NONCE_MODE_ENCODING CALIB_NONCE_BASE CALIB_VERIFY

Verifies a signature (ECDSA verify operation) with a public key stored in the device

Supported API's: calib_verify_stored

◆ CALIB_WRITE_ENC_EN

#define CALIB_WRITE_ENC_EN   (ATCAB_WRITE_ENC_EN && CALIB_FULL_FEATURE)

Requires: CALIB_NONCE_MODE_ENCODING CALIB_NONCE_BASE CALIB_READ_ZONE CALIB_GENDIG ATCAH_GENDIG ATCAH_WRITE_AUTH_MAC ATCAH_NONCE ATCAC_SW_SHA2_256 CALIB_WRITE ATCAH_GEN_SESSION_KEY

Performs an encrypted write of a 32 byte block into given slot

Supported API's: calib_write_enc