Changeset View
Changeset View
Standalone View
Standalone View
head/sys/opencrypto/cryptodev.h
Show First 20 Lines • Show All 127 Lines • ▼ Show 20 Lines | |||||
#define CAMELLIA_BLOCK_LEN 16 | #define CAMELLIA_BLOCK_LEN 16 | ||||
#define CHACHA20_NATIVE_BLOCK_LEN 64 | #define CHACHA20_NATIVE_BLOCK_LEN 64 | ||||
#define EALG_MAX_BLOCK_LEN CHACHA20_NATIVE_BLOCK_LEN /* Keep this updated */ | #define EALG_MAX_BLOCK_LEN CHACHA20_NATIVE_BLOCK_LEN /* Keep this updated */ | ||||
/* IV Lengths */ | /* IV Lengths */ | ||||
#define ARC4_IV_LEN 1 | #define ARC4_IV_LEN 1 | ||||
#define AES_GCM_IV_LEN 12 | #define AES_GCM_IV_LEN 12 | ||||
#define AES_CCM_IV_LEN 12 | |||||
#define AES_XTS_IV_LEN 8 | #define AES_XTS_IV_LEN 8 | ||||
#define AES_XTS_ALPHA 0x87 /* GF(2^128) generator polynomial */ | #define AES_XTS_ALPHA 0x87 /* GF(2^128) generator polynomial */ | ||||
/* Min and Max Encryption Key Sizes */ | /* Min and Max Encryption Key Sizes */ | ||||
#define NULL_MIN_KEY 0 | #define NULL_MIN_KEY 0 | ||||
#define NULL_MAX_KEY 256 /* 2048 bits, max key */ | #define NULL_MAX_KEY 256 /* 2048 bits, max key */ | ||||
#define DES_MIN_KEY 8 | #define DES_MIN_KEY 8 | ||||
#define DES_MAX_KEY DES_MIN_KEY | #define DES_MAX_KEY DES_MIN_KEY | ||||
▲ Show 20 Lines • Show All 55 Lines • ▼ Show 20 Lines | |||||
#define CRYPTO_SHA2_224_HMAC 32 | #define CRYPTO_SHA2_224_HMAC 32 | ||||
#define CRYPTO_RIPEMD160 33 | #define CRYPTO_RIPEMD160 33 | ||||
#define CRYPTO_SHA2_224 34 | #define CRYPTO_SHA2_224 34 | ||||
#define CRYPTO_SHA2_256 35 | #define CRYPTO_SHA2_256 35 | ||||
#define CRYPTO_SHA2_384 36 | #define CRYPTO_SHA2_384 36 | ||||
#define CRYPTO_SHA2_512 37 | #define CRYPTO_SHA2_512 37 | ||||
#define CRYPTO_POLY1305 38 | #define CRYPTO_POLY1305 38 | ||||
#define CRYPTO_AES_CCM_CBC_MAC 39 /* auth side */ | #define CRYPTO_AES_CCM_CBC_MAC 39 /* auth side */ | ||||
#define CRYPTO_ALGORITHM_MAX 39 /* Keep updated - see below */ | #define CRYPTO_AES_CCM_16 40 /* cipher side */ | ||||
#define CRYPTO_ALGORITHM_MAX 40 /* Keep updated - see below */ | |||||
#define CRYPTO_ALGO_VALID(x) ((x) >= CRYPTO_ALGORITHM_MIN && \ | #define CRYPTO_ALGO_VALID(x) ((x) >= CRYPTO_ALGORITHM_MIN && \ | ||||
(x) <= CRYPTO_ALGORITHM_MAX) | (x) <= CRYPTO_ALGORITHM_MAX) | ||||
/* Algorithm flags */ | /* Algorithm flags */ | ||||
#define CRYPTO_ALG_FLAG_SUPPORTED 0x01 /* Algorithm is supported */ | #define CRYPTO_ALG_FLAG_SUPPORTED 0x01 /* Algorithm is supported */ | ||||
#define CRYPTO_ALG_FLAG_RNG_ENABLE 0x02 /* Has HW RNG for DH/DSA */ | #define CRYPTO_ALG_FLAG_RNG_ENABLE 0x02 /* Has HW RNG for DH/DSA */ | ||||
#define CRYPTO_ALG_FLAG_DSA_SHA 0x04 /* Can do SHA on msg */ | #define CRYPTO_ALG_FLAG_DSA_SHA 0x04 /* Can do SHA on msg */ | ||||
▲ Show 20 Lines • Show All 360 Lines • Show Last 20 Lines |