Skip to content

Commit

Permalink
[#316] Split PDU switch function
Browse files Browse the repository at this point in the history
  • Loading branch information
Donnie-Ice committed Sep 19, 2024
1 parent 3d1baa1 commit fdcf3ec
Show file tree
Hide file tree
Showing 3 changed files with 232 additions and 182 deletions.
4 changes: 4 additions & 0 deletions include/crypto.h
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,10 @@ void clean_akref(SecurityAssociation_t* sa);
// Determine Payload Data Unit
int32_t Crypto_Process_Extended_Procedure_Pdu(TC_t* tc_sdls_processed_frame, uint8_t* ingest);
int32_t Crypto_PDU(uint8_t* ingest, TC_t* tc_frame);
int32_t Crypto_SG_KEY_MGMT(uint8_t* ingest, TC_t* tc_frame);
int32_t Crypto_SG_SA_MGMT(uint8_t* ingest, TC_t* tc_frame);
int32_t Crypto_SEC_MON_CTRL(uint8_t* ingest);
int32_t Crypto_USER_DEFINED_CMD(uint8_t* ingest);

// Managed Parameter Functions
int32_t Crypto_Get_Managed_Parameters_For_Gvcid(uint8_t tfvn, uint16_t scid, uint8_t vcid,
Expand Down
8 changes: 8 additions & 0 deletions include/crypto_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,14 @@
#define ST_OK 0x00
#define ST_NOK 0xFF

// Protocol Data Unit (PDU)
// PDU Type
#define PDU_TYPE_COMMAND 0
#define PDU_TYPE_REPLY 1
// PDU User Flag
#define PDU_USER_FLAG_TRUE 1
#define PDU_USER_FLAG_FALSE 0

// Procedure Identification (PID)
// Service Group - Key Management
#define SG_KEY_MGMT 0x00 // 0b00
Expand Down
Loading

0 comments on commit fdcf3ec

Please sign in to comment.