MCUX CLNS
MCUX Crypto Library Normal Secure
mcuxClSession_Types.h
Go to the documentation of this file.
1 /*--------------------------------------------------------------------------*/
2 /* Copyright 2020-2023 NXP */
3 /* */
4 /* NXP Confidential. This software is owned or controlled by NXP and may */
5 /* only be used strictly in accordance with the applicable license terms. */
6 /* By expressly accepting such terms or by downloading, installing, */
7 /* activating and/or otherwise using the software, you are agreeing that */
8 /* you have read, and that you agree to comply with and are bound by, such */
9 /* license terms. If you do not agree to be bound by the applicable license */
10 /* terms, then you may not retain, install, activate or otherwise use the */
11 /* software. */
12 /*--------------------------------------------------------------------------*/
13 
19 #ifndef MCUXCLSESSION_TYPES_H_
20 #define MCUXCLSESSION_TYPES_H_
21 
22 #include <mcuxClCore_Platform.h>
24 #include <mcuxCsslFlowProtection.h>
25 
26 #ifdef MCUXCL_FEATURE_SESSION_HAS_RANDOM
27 #include <mcuxClRandom_Types.h>
28 #endif /* MCUXCL_FEATURE_SESSION_HAS_RANDOM */
29 
30 /**********************************************
31  * CONSTANTS
32  **********************************************/
44 #define MCUXCLSESSION_STATUS_OK ((mcuxClSession_Status_t) 0xE8E8E8E8u )
45 #define MCUXCLSESSION_STATUS_ERROR ((mcuxClSession_Status_t) 0xE8E88E8Eu )
46 
52 #define MCUXCLSESSION_RTF_UPDATE_TRUE ((mcuxClSession_Rtf_t) 0xF0F00F0Fu )
53 #define MCUXCLSESSION_RTF_UPDATE_FALSE ((mcuxClSession_Rtf_t) 0x0F0F0F0Fu )
54  /* mcuxClSession_Constants */
60 
61 
62 /**********************************************
63  * TYPEDEFS
64  **********************************************/
75 typedef uint32_t mcuxClSession_Status_t;
76 
80 typedef MCUX_CSSL_FP_PROTECTED_TYPE(mcuxClSession_Status_t) mcuxClSession_Status_Protected_t;
81 
85 typedef uint32_t mcuxClSession_Rtf_t;
86 
90 typedef struct mcuxClSession_WorkArea
91 {
92  uint32_t * buffer;
93  uint32_t size;
94  uint32_t used;
95  uint32_t dirty;
97 
102 {
103  uint32_t securityCounter;
105 
106 
111 {
114 #ifdef MCUXCL_FEATURE_SESSION_HAS_RANDOM
115  mcuxClRandom_Config_t randomCfg;
116 #endif /* MCUXCL_FEATURE_SESSION_HAS_RANDOM */
118  uint8_t *pRtf;
120 
125 
126  /* mcuxClSession_Types */
130 
131 #endif /* MCUXCLSESSION_TYPES_H_ */
mcuxClSession_Rtf_t rtf
Configuration of the RTF.
Definition: mcuxClSession_Types.h:117
Type for mcuxClSession security context.
Definition: mcuxClSession_Types.h:101
uint32_t securityCounter
Security counter.
Definition: mcuxClSession_Types.h:103
Type definitions of mcuxClRandom component.
mcuxClSession_Descriptor_t *const mcuxClSession_Handle_t
Type for mcuxClSession Handle.
Definition: mcuxClSession_Types.h:124
struct mcuxClSession_Descriptor mcuxClSession_Descriptor_t
Type for mcuxClSession Descriptor.
mcuxClSession_WorkArea_t cpuWa
Workarea for the CPU.
Definition: mcuxClSession_Types.h:112
uint32_t size
Size of the workarea buffer in words (uint32_t)
Definition: mcuxClSession_Types.h:93
uint32_t mcuxClSession_Rtf_t
Type for mcuxClSession RTF configuration flags.
Definition: mcuxClSession_Types.h:85
Definition of function identifiers for the flow protection mechanism.
Random config structure.
Definition: mcuxClRandom_Types.h:100
uint32_t * buffer
Pointer to the starting address of the workarea buffer.
Definition: mcuxClSession_Types.h:92
Type for mcuxClSession workareas flags.
Definition: mcuxClSession_Types.h:90
typedef MCUX_CSSL_FP_PROTECTED_TYPE(mcuxClSession_Status_t) mcuxClSession_Status_Protected_t
Deprecated type for mcuxClSession protected status codes.
Definition: mcuxCsslFlowProtection_example.c:137
uint32_t mcuxClSession_Status_t
Type for mcuxClSession status codes.
Definition: mcuxClSession_Types.h:75
Provides the API for the CSSL flow protection mechanism.
struct mcuxClSession_SecurityContext mcuxClSession_SecurityContext_t
Type for mcuxClSession security context.
uint32_t dirty
Maximum used portion of the workarea buffer in words (uint32_t)
Definition: mcuxClSession_Types.h:95
Type for mcuxClSession Descriptor.
Definition: mcuxClSession_Types.h:110
uint32_t used
Used portion of the workarea buffer in words (uint32_t)
Definition: mcuxClSession_Types.h:94
mcuxClSession_WorkArea_t pkcWa
Workarea for the PKC.
Definition: mcuxClSession_Types.h:113
struct mcuxClSession_WorkArea mcuxClSession_WorkArea_t
Type for mcuxClSession workareas flags.