General definitions for cryptographic algorithms. More...
#include "os_port.h"
#include "crypto_config.h"
#include "crypto_legacy.h"
#include "cpu_endian.h"
#include "error.h"
Go to the source code of this file.
Data Structures | |
struct | DataChunk |
Data chunk descriptor. More... | |
struct | HashAlgo |
Common interface for hash algorithms. More... | |
struct | CipherAlgo |
Common interface for encryption algorithms. More... | |
struct | KemAlgo |
Common interface for key encapsulation mechanisms (KEM) More... | |
struct | _PrngAlgo |
Common interface for pseudo-random number generators (PRNG) More... | |
Typedefs | |
typedef error_t(* | HashAlgoCompute) (const void *data, size_t length, uint8_t *digest) |
typedef void(* | HashAlgoInit) (void *context) |
typedef void(* | HashAlgoUpdate) (void *context, const void *data, size_t length) |
typedef void(* | HashAlgoFinal) (void *context, uint8_t *digest) |
typedef void(* | HashAlgoFinalRaw) (void *context, uint8_t *digest) |
typedef error_t(* | CipherAlgoInit) (void *context, const uint8_t *key, size_t keyLen) |
typedef void(* | CipherAlgoEncryptStream) (void *context, const uint8_t *input, uint8_t *output, size_t length) |
typedef void(* | CipherAlgoDecryptStream) (void *context, const uint8_t *input, uint8_t *output, size_t length) |
typedef void(* | CipherAlgoEncryptBlock) (void *context, const uint8_t *input, uint8_t *output) |
typedef void(* | CipherAlgoDecryptBlock) (void *context, const uint8_t *input, uint8_t *output) |
typedef void(* | CipherAlgoDeinit) (void *context) |
typedef error_t(* | KemAlgoGenerateKeyPair) (const PrngAlgo *prngAlgo, void *prngContext, uint8_t *pk, uint8_t *sk) |
typedef error_t(* | KemAlgoEncapsulate) (const PrngAlgo *prngAlgo, void *prngContext, uint8_t *ct, uint8_t *ss, const uint8_t *pk) |
typedef error_t(* | KemAlgoDecapsulate) (uint8_t *ss, const uint8_t *ct, const uint8_t *sk) |
typedef error_t(* | PrngAlgoInit) (void *context) |
typedef error_t(* | PrngAlgoSeed) (void *context, const uint8_t *input, size_t length) |
typedef error_t(* | PrngAlgoAddEntropy) (void *context, uint_t source, const uint8_t *input, size_t length, size_t entropy) |
typedef error_t(* | PrngAlgoRead) (void *context, uint8_t *output, size_t length) |
typedef void(* | PrngAlgoDeinit) (void *context) |
Enumerations | |
enum | CipherAlgoType { CIPHER_ALGO_TYPE_STREAM = 0, CIPHER_ALGO_TYPE_BLOCK = 1 } |
Encryption algorithm type. More... | |
enum | CipherMode { CIPHER_MODE_NULL = 0, CIPHER_MODE_STREAM = 1, CIPHER_MODE_ECB = 2, CIPHER_MODE_CBC = 3, CIPHER_MODE_CFB = 4, CIPHER_MODE_OFB = 5, CIPHER_MODE_CTR = 6, CIPHER_MODE_CCM = 7, CIPHER_MODE_GCM = 8, CIPHER_MODE_CHACHA20_POLY1305 = 9 } |
Cipher operation modes. More... | |
Detailed Description
General definitions for cryptographic algorithms.
License
SPDX-License-Identifier: GPL-2.0-or-later
Copyright (C) 2010-2024 Oryx Embedded SARL. All rights reserved.
This file is part of CycloneCRYPTO Open.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- Version
- 2.4.4
Definition in file crypto.h.
Macro Definition Documentation
◆ _U16
◆ _U32
◆ _U64
◆ _U8
◆ AES_SUPPORT
◆ ARIA_SUPPORT
◆ ASN1_SUPPORT
◆ BASE64_SUPPORT
◆ BASE64URL_SUPPORT
◆ BCRYPT_SUPPORT
◆ BLAKE2B160_SUPPORT
◆ BLAKE2B256_SUPPORT
◆ BLAKE2B384_SUPPORT
◆ BLAKE2B512_SUPPORT
◆ BLAKE2B_SUPPORT
◆ BLAKE2S128_SUPPORT
◆ BLAKE2S160_SUPPORT
◆ BLAKE2S224_SUPPORT
◆ BLAKE2S256_SUPPORT
◆ BLAKE2S_SUPPORT
◆ BLOWFISH_SUPPORT
◆ CAMELLIA_SUPPORT
◆ CAST128_SUPPORT
◆ CAST256_SUPPORT
◆ CBC_SUPPORT
◆ CCM_SUPPORT
◆ CFB_SUPPORT
◆ CHACHA20_POLY1305_SUPPORT
◆ CHACHA_SUPPORT
◆ CMAC_SUPPORT
◆ CONCAT_KDF_SUPPORT
◆ CRYPTO_SELECT_16
◆ CRYPTO_SELECT_32
◆ CRYPTO_SELECT_64
◆ CRYPTO_SELECT_8
◆ CRYPTO_STATIC_MEM_SUPPORT
◆ CRYPTO_TEST_EQ_16
◆ CRYPTO_TEST_EQ_32
◆ CRYPTO_TEST_EQ_8
◆ CRYPTO_TEST_GT_16
◆ CRYPTO_TEST_GT_32
◆ CRYPTO_TEST_GT_8
◆ CRYPTO_TEST_GTE_16
◆ CRYPTO_TEST_GTE_32
◆ CRYPTO_TEST_GTE_8
◆ CRYPTO_TEST_LT_16
◆ CRYPTO_TEST_LT_32
◆ CRYPTO_TEST_LT_8
◆ CRYPTO_TEST_LTE_16
◆ CRYPTO_TEST_LTE_32
◆ CRYPTO_TEST_LTE_8
◆ CRYPTO_TEST_NEQ_16
◆ CRYPTO_TEST_NEQ_32
◆ CRYPTO_TEST_NEQ_8
◆ CRYPTO_TEST_NZ_16
◆ CRYPTO_TEST_NZ_32
◆ CRYPTO_TEST_NZ_8
◆ CRYPTO_TEST_Z_16
◆ CRYPTO_TEST_Z_32
◆ CRYPTO_TEST_Z_8
◆ cryptoAllocMem
#define cryptoAllocMem | ( | size | ) | osAllocMem(size) |
◆ cryptoFreeMem
◆ CSHAKE_SUPPORT
◆ CTR_SUPPORT
◆ CYCLONE_CRYPTO_MAJOR_VERSION
◆ CYCLONE_CRYPTO_MINOR_VERSION
◆ CYCLONE_CRYPTO_REV_NUMBER
◆ CYCLONE_CRYPTO_VERSION_STRING
◆ DES3_SUPPORT
◆ DES_SUPPORT
◆ DH_SUPPORT
◆ DSA_SUPPORT
◆ EC_SUPPORT
◆ ECB_SUPPORT
◆ ECDH_SUPPORT
◆ ECDSA_SUPPORT
◆ GCM_SUPPORT
◆ GMAC_SUPPORT
◆ HKDF_SUPPORT
◆ HMAC_SUPPORT
◆ IDEA_SUPPORT
◆ KECCAK_SUPPORT
◆ KMAC_SUPPORT
◆ MARS_SUPPORT
◆ MD2_SUPPORT
◆ MD4_SUPPORT
◆ MD5_CRYPT_SUPPORT
◆ MD5_SUPPORT
◆ MLKEM1024_SUPPORT
◆ MLKEM512_SUPPORT
◆ MLKEM768_SUPPORT
◆ MPI_ASM_SUPPORT
◆ MPI_SUPPORT
◆ OFB_SUPPORT
◆ OID_SUPPORT
◆ PBKDF_SUPPORT
◆ PEM_SUPPORT
◆ PKCS5_SUPPORT
◆ POLY1305_SUPPORT
◆ PRESENT_SUPPORT
◆ PrngAlgo
◆ RADIX64_SUPPORT
◆ RC2_SUPPORT
◆ RC4_SUPPORT
◆ RC6_SUPPORT
◆ RIPEMD128_SUPPORT
◆ RIPEMD160_SUPPORT
◆ ROL16
◆ ROL32
◆ ROL64
◆ ROL8
◆ ROR16
◆ ROR32
◆ ROR64
◆ ROR8
◆ RSA_SUPPORT
◆ SALSA20_SUPPORT
◆ SCRYPT_SUPPORT
◆ SEED_SUPPORT
◆ SERPENT_SUPPORT
◆ SHA1_SUPPORT
◆ SHA224_SUPPORT
◆ SHA256_SUPPORT
◆ SHA384_SUPPORT
◆ SHA3_224_SUPPORT
◆ SHA3_256_SUPPORT
◆ SHA3_384_SUPPORT
◆ SHA3_512_SUPPORT
◆ SHA512_224_SUPPORT
◆ SHA512_256_SUPPORT
◆ SHA512_SUPPORT
◆ SHA_CRYPT_SUPPORT
◆ SHAKE_SUPPORT
◆ SHL16
◆ SHL32
◆ SHL64
◆ SHL8
◆ SHR16
◆ SHR32
◆ SHR64
◆ SHR8
◆ SIV_SUPPORT
◆ SM3_SUPPORT
◆ SM4_SUPPORT
◆ SNTRUP761_SUPPORT
◆ TEA_SUPPORT
◆ TIGER_SUPPORT
◆ TRIVIUM_SUPPORT
◆ TWOFISH_SUPPORT
◆ WHIRLPOOL_SUPPORT
◆ X509_SUPPORT
◆ XCBC_MAC_SUPPORT
◆ XTEA_SUPPORT
◆ XTS_SUPPORT
◆ YARROW_SUPPORT
◆ ZUC_SUPPORT
Typedef Documentation
◆ CipherAlgoDecryptBlock
typedef void(* CipherAlgoDecryptBlock) (void *context, const uint8_t *input, uint8_t *output) |
◆ CipherAlgoDecryptStream
typedef void(* CipherAlgoDecryptStream) (void *context, const uint8_t *input, uint8_t *output, size_t length) |
◆ CipherAlgoDeinit
◆ CipherAlgoEncryptBlock
typedef void(* CipherAlgoEncryptBlock) (void *context, const uint8_t *input, uint8_t *output) |
◆ CipherAlgoEncryptStream
typedef void(* CipherAlgoEncryptStream) (void *context, const uint8_t *input, uint8_t *output, size_t length) |
◆ CipherAlgoInit
typedef error_t(* CipherAlgoInit) (void *context, const uint8_t *key, size_t keyLen) |
◆ HashAlgoCompute
◆ HashAlgoFinal
typedef void(* HashAlgoFinal) (void *context, uint8_t *digest) |
◆ HashAlgoFinalRaw
typedef void(* HashAlgoFinalRaw) (void *context, uint8_t *digest) |
◆ HashAlgoInit
◆ HashAlgoUpdate
◆ KemAlgoDecapsulate
typedef error_t(* KemAlgoDecapsulate) (uint8_t *ss, const uint8_t *ct, const uint8_t *sk) |
◆ KemAlgoEncapsulate
◆ KemAlgoGenerateKeyPair
◆ PrngAlgoAddEntropy
◆ PrngAlgoDeinit
◆ PrngAlgoInit
◆ PrngAlgoRead
◆ PrngAlgoSeed
Enumeration Type Documentation
◆ CipherAlgoType
enum CipherAlgoType |
◆ CipherMode
enum CipherMode |