Loading...
Searching...
No Matches
crypto_types.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2021 HAW Hamburg
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
20#ifndef PSA_CRYPTO_PSA_CRYPTO_TYPES_H
21#define PSA_CRYPTO_PSA_CRYPTO_TYPES_H
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27#include <stdint.h>
28
33typedef enum {
34 PSA_CRYPTO_DRIVER_DECRYPT,
35 PSA_CRYPTO_DRIVER_ENCRYPT
37
46typedef uint32_t psa_algorithm_t;
47
58typedef uint8_t psa_dh_family_t;
59
70typedef uint8_t psa_ecc_family_t;
71
104
109
116typedef uint32_t psa_key_id_t;
117
154typedef uint32_t psa_key_lifetime_t;
155
190typedef uint32_t psa_key_location_t;
191
230typedef uint8_t psa_key_persistence_t;
231
246typedef uint16_t psa_key_type_t;
247
251typedef uint32_t psa_key_usage_t;
252
256typedef uint16_t psa_key_bits_t;
257
258/* These are all temporarily defined as some numeric type to prevent errors at compile time.*/
290
321
329typedef int32_t psa_status_t;
330
362
465
497
498#ifdef __cplusplus
499}
500#endif
501
502#endif /* PSA_CRYPTO_PSA_CRYPTO_TYPES_H */
int32_t psa_status_t
Function return status.
uint32_t psa_key_id_t
Key identifier.
uint8_t psa_key_persistence_t
Encoding of key persistence levels.
uint16_t psa_key_bits_t
Public interfaces use size_t, but internally we use a smaller type.
uint32_t psa_key_location_t
Encoding of key location indicators.
uint16_t psa_key_type_t
Encoding of a key type.
uint32_t psa_key_lifetime_t
Encoding of key lifetimes.
uint32_t psa_key_usage_t
Encoding of permitted usage on a key.
uint16_t psa_key_derivation_step_t
Encoding of the step of a key derivation.
uint32_t psa_algorithm_t
Encoding of a cryptographic algorithm.
psa_encrypt_or_decrypt_t
For encrypt-decrypt functions, whether the operation is an encryption or a decryption.
uint8_t psa_ecc_family_t
The type of PSA elliptic curve family identifiers.
uint8_t psa_dh_family_t
The type of PSA finite-field Diffie-Hellman group family identifiers.
Structure storing an AEAD operation context.
Structure storing a cipher operation context.
Structure containing a hash context and algorithm.
Structure storing key attributes.
Structure storing a key derivation context.
Structure storing a MAC operation context.