Skip to content

Commit

Permalink
Merge pull request #285 from nasa/274-rc-131
Browse files Browse the repository at this point in the history
274 rc 131
  • Loading branch information
rjbrown2 committed Aug 28, 2024
2 parents 65c8710 + 3f515f6 commit 86f790e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ option(MC_CUSTOM_PATH "Custom Monitoring and Control path" OFF)
option(MC_DISABLED "Monitoring and Control - Disabled" OFF)
option(MC_INTERNAL "Monitoring and Control - Internal" ON)
option(SA_CUSTOM "Security Association - Custom" OFF)
option(SA_CUSTOM_PATH "Custion Security Association Path" OFF)
option(SA_CUSTOM_PATH "Custom Security Association Path" OFF)
option(SA_INTERNAL "Security Association - Internal" ON)
option(SA_MARIADB "Security Association - MariaDB" OFF)
option(SUPPORT "Support" OFF)
Expand Down
2 changes: 2 additions & 0 deletions include/crypto_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@
#define RESET
#endif

// Managed Parameters Size
#define GVCID_MAN_PARAM_SIZE 250

// Max Frame Size
#define TC_MAX_FRAME_SIZE 1024
Expand Down
4 changes: 2 additions & 2 deletions src/core/crypto_config.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ CryptoConfig_t crypto_config;
CryptographyKmcCryptoServiceConfig_t* cryptography_kmc_crypto_config = NULL;
CamConfig_t* cam_config = NULL;

GvcidManagedParameters_t gvcid_managed_parameters_array[250]; //Arbitrary 250 for now.
GvcidManagedParameters_t gvcid_managed_parameters_array[GVCID_MAN_PARAM_SIZE];
int gvcid_counter = 0;
GvcidManagedParameters_t gvcid_null_struct = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
GvcidManagedParameters_t current_managed_parameters_struct = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
Expand Down Expand Up @@ -532,7 +532,7 @@ int32_t Crypto_Config_Cam(uint8_t cam_enabled, char* cookie_file_path, char* key
int32_t Crypto_Config_Add_Gvcid_Managed_Parameters(GvcidManagedParameters_t gvcid_managed_parameters_struct)
{
int32_t status = CRYPTO_LIB_SUCCESS;
if (gvcid_counter > 250)
if (gvcid_counter > GVCID_MAN_PARAM_SIZE)
{
status = CRYPTO_LIB_ERR_EXCEEDS_MANAGED_PARAMETER_MAX_LIMIT;
}
Expand Down

0 comments on commit 86f790e

Please sign in to comment.