-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
CryptoLib#164 - TM Multiple Packets and Pre-allocation of SA
- Loading branch information
Showing
103 changed files
with
3,200 additions
and
3,130 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,17 @@ | ||
# | ||
# Metadata | ||
# | ||
.vagrant | ||
.vscode | ||
.idea | ||
vgcore* | ||
**core | ||
|
||
# | ||
# Packages and Build Files | ||
# | ||
__pycache__ | ||
*.dat | ||
*.so | ||
build | ||
build* | ||
venv | ||
*.dat | ||
.vscode | ||
__pycache__ | ||
|
||
#CMake.gitignore | ||
CMakeLists.txt.user | ||
CMakeCache.txt | ||
CMakeFiles | ||
CMakeScripts | ||
Testing | ||
Makefile | ||
cmake_install.cmake | ||
install_manifest.txt | ||
compile_commands.json | ||
CTestTestfile.cmake | ||
cmake-build-debug | ||
**.cbp | ||
_deps | ||
|
||
DartConfiguration.tcl | ||
|
||
install | ||
vgcore* | ||
core.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,43 +15,42 @@ | |
# NASA IV&V | ||
# [email protected] | ||
|
||
|
||
#cmake_minimum_required(VERSION 2.6.4) | ||
cmake_minimum_required(VERSION 3.14.0) | ||
project(CRYPTO C) | ||
|
||
# | ||
# Define Build Flags | ||
# The default value is captured in line, change with flag `-DXYZ=1` | ||
# For flags with the same prefix, one or more may be enabled | ||
# | ||
option(CODECOV "Code Coverage" OFF) | ||
option(CRYPTO_LIBGCRYPT "Cryptography Module - Libgcrypt" ON) | ||
option(CRYPTO_KMC "Cryptography Module - KMC" OFF) | ||
option(DEBUG "Debug" OFF) | ||
option(KEY_CUSTOM "Key Module - Custom" OFF) | ||
option(KEY_INTERNAL "Key Module - Internal" ON) | ||
option(KEY_KMC "Key Module - KMC OFF") | ||
option(SA_INTERNAL "Security Association - Internal" ON) | ||
option(SA_MARIADB "Security Association - MariaDB" OFF) | ||
option(SUPPORT "Support" OFF) | ||
option(SYSTEM_INSTALL "SystemInstall" OFF) | ||
option(TEST "Test" OFF) | ||
option(TEST_ENC "Tests - Encryption" OFF) | ||
|
||
OPTION(DEBUG "Debug" OFF) # Disabled by default, enable with: -DDEBUG=ON | ||
OPTION(MYSQL "Mysql" OFF) # Disabled by default, enable with: -DMYSQL=ON | ||
OPTION(LIBGCRYPT "Libgcrypt" ON) # Enabled by default, disable with: -DLIBGCRYPT=OFF | ||
OPTION(KMCCRYPTO "KmcCrypto" OFF) # Disabled by default, enable with: -DKMCCRYPTO=ON | ||
OPTION(ENCTEST "Encryption-Tests" OFF) # Disabled by default, enable with: -DENCTEST=ON | ||
OPTION(CODECOV "Code-Coverage" OFF) # Disabled by default, enable with: -DCODECOV=ON | ||
OPTION(SYSTEM_INSTALL "SystemInstall" OFF) #Disabled by default, enable with: -DSYSTEM_INSTALL=ON | ||
OPTION(KMC_MDB_RH "KMC-MDB-RedHat-Integration-Testing" OFF) #Disabled by default, enable with: -DKMC_MDB_RH=ON | ||
OPTION(KMC_MDB_DB "KMC-MDB-Debian-Integration-Testing" OFF) #Disabled by default, enable with: -DKMC_MDB_DB=ON | ||
|
||
# | ||
# Build Flag Logic | ||
# | ||
if(CODECOV) | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fprofile-arcs -ftest-coverage") | ||
endif() | ||
|
||
set(CMAKE_INSTALL_RPATH "$ORIGIN/../lib") | ||
set(CMAKE_INSTALL_PREFIX ${PROJECT_SOURCE_DIR}/install) | ||
|
||
IF(CRYPTO_SUBMODULE_INSTALL) #If building CryptoLib as a submodule of another build system (EG, JPL KMC, Nasa NOS3, etc...) | ||
set(CMAKE_INSTALL_PREFIX ${CRYPTO_SUBMODULE_INSTALL}) | ||
ENDIF() | ||
|
||
IF(SYSTEM_INSTALL) | ||
set(CMAKE_INSTALL_PREFIX /usr/local) | ||
ENDIF() | ||
|
||
|
||
IF(DEBUG) | ||
ADD_DEFINITIONS(-DDEBUG -DOCF_DEBUG -DFECF_DEBUG -DSA_DEBUG -DPDU_DEBUG -DCCSDS_DEBUG -DTC_DEBUG -DMAC_DEBUG -DTM_DEBUG) | ||
if(DEBUG) | ||
add_definitions(-DDEBUG -DOCF_DEBUG -DFECF_DEBUG -DSA_DEBUG -DPDU_DEBUG -DCCSDS_DEBUG -DTC_DEBUG -DMAC_DEBUG -DTM_DEBUG) | ||
add_compile_options(-ggdb) | ||
ENDIF(DEBUG) | ||
|
||
IF(ENCTEST) | ||
ADD_DEFINITIONS(-DENCTEST) | ||
ENDIF(ENCTEST) | ||
endif() | ||
|
||
IF(KMC_MDB_RH) | ||
ADD_DEFINITIONS(-DKMC_MDB_RH) | ||
|
@@ -61,38 +60,36 @@ IF(KMC_MDB_DB) | |
ADD_DEFINITIONS(-DKMC_MDB_DB) | ||
ENDIF(KMC_MDB_DB) | ||
|
||
if(CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME) | ||
include(CTest) | ||
enable_testing() | ||
if(SYSTEM_INSTALL) | ||
set(CMAKE_INSTALL_PREFIX /usr/local) | ||
elseif(NOT DEFINED CFE_SYSTEM_PSPNAME) | ||
# Not cFE / cFS | ||
set(CMAKE_INSTALL_RPATH "$ORIGIN/../lib") | ||
set(CMAKE_INSTALL_PREFIX ${PROJECT_SOURCE_DIR}/install) | ||
endif() | ||
|
||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pthread -Wall -Wextra -Werror -g -O0") | ||
|
||
if(CODECOV) | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fprofile-arcs -ftest-coverage") | ||
if(TEST_ENC) | ||
# Can't run an additional set of tests without `TEST` enabled | ||
set(TEST ON) | ||
endif() | ||
|
||
include_directories(include) | ||
|
||
# The shared OSAL and cFE include directories should always be used | ||
# Note that this intentionally does NOT include PSP-specific includes, just the generic | ||
# Only include cFS/NOS3 directories if env var is defined | ||
if(DEFINED ENV{CFECORE_SOURCE_DIR}) #if ${CFECORE_SOURCE_DIR} is set, expect cFS build infrastructure to be in place. | ||
include_directories(${CFECORE_SOURCE_DIR}/src/inc) | ||
include_directories(${CFEPSP_SOURCE_DIR}/fsw/inc) | ||
ADD_DEFINITIONS(-DNOS3) | ||
else() | ||
#pass | ||
if(TEST) | ||
include(CTest) | ||
enable_testing() | ||
endif() | ||
|
||
if(NOT DEFINED ${PROJECT_BINARY_DIR}) | ||
set(PROJECT_BINARY_DIR ${CMAKE_CURRENT_SOURCE_DIR}/build) | ||
endif() | ||
# | ||
# Project Specifics | ||
# | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Werror -g -O0") | ||
|
||
include_directories(include) | ||
add_subdirectory(src) | ||
|
||
if((CMAKE_PROJECT_NAME STREQUAL PROJECT_NAME OR MYPROJECT_BUILD_TESTING) AND BUILD_TESTING) | ||
add_subdirectory(test) | ||
if(SUPPORT) | ||
add_subdirectory(support) | ||
endif() | ||
|
||
add_subdirectory(util) | ||
if(TEST) | ||
add_subdirectory(test) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,11 @@ | ||
ignore: | ||
- "util/src_util/process_security.c" | ||
- "util/src_util/ut_mysql_tls_connection.c" | ||
- "util/src_util/ut_mysql_m_tls_connection.c" | ||
- "util/src_util/ut_kmc_crypto.c" | ||
- "util/src_util/ut_kmc_crypto_aes_cmac.c" | ||
- "util/src_util/apply_security.c" | ||
- "util/src_util/crypto_sequence.c" | ||
- "util/include/utest.h" | ||
- "util/core/shared_util.c" | ||
- "src/src_main/crypto_print.c" | ||
- "src/src_feature_stubs/cryptography_kmc_stub/cryptography_interface_kmc.stub.c" | ||
- "src/src_feature_stubs/mysql_stub/sadb_routine_mariadb.stub.c" | ||
- "src/crypto/kmc/*" | ||
- "src/crypto/kmc_stub/*" | ||
- "src/crypto/libgcrypt_stub/*" | ||
- "src/sa/internal_stub/*" | ||
- "src/sa/mariadb/*" | ||
- "src/sa/mariadb_stub/*" | ||
- "src/sa/sadb_mariadb_sql/*" | ||
- "src/sa/test_sadb_mariadb_sql/*" | ||
- "support/*" | ||
- "test/*" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.