-
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.
SDLS-EP blue book interoperability testing - spacecraft side;
- Loading branch information
Showing
86 changed files
with
29,866 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Copyright (C) 2009 - 2017 National Aeronautics and Space Administration. All Foreign Rights are Reserved to the U.S. Government. | ||
# | ||
# This software is provided "as is" without any warranty of any, kind either express, implied, or statutory, including, but not | ||
# limited to, any warranty that the software will conform to, specifications any implied warranties of merchantability, fitness | ||
# for a particular purpose, and freedom from infringement, and any warranty that the documentation will conform to the program, or | ||
# any warranty that the software will be error free. | ||
# | ||
# In no event shall NASA be liable for any damages, including, but not limited to direct, indirect, special or consequential damages, | ||
# arising out of, resulting from, or in any way connected with the software or its documentation. Whether or not based upon warranty, | ||
# contract, tort or otherwise, and whether or not loss was sustained from, or arose out of the results of, or use of, the software, | ||
# documentation or services provided hereunder | ||
# | ||
# ITC Team | ||
# NASA IV&V | ||
# [email protected] | ||
|
||
cmake_minimum_required(VERSION 2.6.4) | ||
project(CRYPTO C) | ||
|
||
include_directories(fsw/public_inc) | ||
|
||
# The shared OSAL and cFE include directories should always be used | ||
# Note that this intentionally does NOT include PSP-specific includes, just the generic | ||
include_directories(${CFECORE_SOURCE_DIR}/src/inc) | ||
include_directories(${CFEPSP_SOURCE_DIR}/fsw/inc) | ||
|
||
aux_source_directory(fsw/src LIB_SRC_FILES) | ||
|
||
# Create the app module | ||
add_cfe_app(crypto ${LIB_SRC_FILES}) | ||
|
||
# Add libgcrypt | ||
target_link_libraries(crypto libgcrypt) |
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,2 +1,6 @@ | ||
# CryptoLib | ||
|
||
Provide a software-only solution using the CCSDS Space Data Link Security Protocol - Extended Procedures (SDLS-EP) to secure communications between a spacecraft running the core Flight System (cFS) and a ground station. | ||
|
||
In order to build crypto the following must be installed assuming Ubuntu 18.04 LTS: | ||
* `sudo apt install libgpg-error-dev:i386 libgcrypt20-dev:i386` |
Binary file not shown.
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
nasa@ccsds-nasa:~/cFS_SDLS/support$ python TO_SLE_Link.py | ||
ready for data... | ||
|
||
Length = "1145" | ||
sent: 0x"7f04000056000000000f0031020218000001001a0080ffff0004b10000404307ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff00000039000000000000000000000000000000000000000000000000010000009d6d" to STS_SLE | ||
|
||
Length = "1145" | ||
sent: 0x"7f04000056000000000f0031030318220001001a000000000000000000000000000000000000000000000000000000000000000000000080ffff0004b10000404307ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff000000390000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007ff00000039000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000100d955" to STS_SLE | ||
|
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 |
---|---|---|
@@ -0,0 +1,125 @@ | ||
# Copyright (C) 2009 - 2017 National Aeronautics and Space Administration. All Foreign Rights are Reserved to the U.S. Government. | ||
# | ||
# This software is provided "as is" without any warranty of any, kind either express, implied, or statutory, including, but not | ||
# limited to, any warranty that the software will conform to, specifications any implied warranties of merchantability, fitness | ||
# for a particular purpose, and freedom from infringement, and any warranty that the documentation will conform to the program, or | ||
# any warranty that the software will be error free. | ||
# | ||
# In no event shall NASA be liable for any damages, including, but not limited to direct, indirect, special or consequential damages, | ||
# arising out of, resulting from, or in any way connected with the software or its documentation. Whether or not based upon warranty, | ||
# contract, tort or otherwise, and whether or not loss was sustained from, or arose out of the results of, or use of, the software, | ||
# documentation or services provided hereunder | ||
# | ||
# ITC Team | ||
# NASA IV&V | ||
# [email protected] | ||
|
||
############################################################################### | ||
# File: CFS Application Makefile | ||
############################################################################### | ||
# | ||
# Subsystem produced by this makefile. | ||
# | ||
APPTARGET = crypto | ||
|
||
# | ||
# Entry Point for task | ||
# | ||
ENTRY_PT = crypto_Init | ||
|
||
# | ||
# Object files required to build subsystem. | ||
# | ||
OBJS = itc_aes128.o | ||
OBJS += itc_gcm128.o | ||
OBJS += itc_cmac128.o | ||
OBJS += crypto.o | ||
OBJS += crypto_print.o | ||
|
||
# | ||
# Source files required to build subsystem; used to generate dependencies. | ||
# As long as there are no assembly files this can be automated. | ||
# | ||
SOURCES = $(OBJS:.o=.c) | ||
|
||
|
||
## | ||
## Specify extra C Flags needed to build this subsystem | ||
## | ||
LOCAL_COPTS = -Wfatal-errors -Werror -Wall -Wextra -Wstrict-prototypes | ||
|
||
|
||
## | ||
## EXEDIR is defined here, just in case it needs to be different for a custom | ||
## build | ||
## | ||
EXEDIR=../exe | ||
|
||
## | ||
## Certain OSs and Application Loaders require the following option for | ||
## Shared libraries. Currently only needed for vxWorks 5.5 and RTEMS. | ||
## For each shared library that this app depends on, you need to have an | ||
## entry like the following: | ||
## -R../tst_lib/tst_lib.elf | ||
## | ||
SHARED_LIB_LINK = -lgcrypt | ||
|
||
######################################################################## | ||
# Should not have to change below this line, except for customized | ||
# Mission and cFE directory structures | ||
######################################################################## | ||
|
||
# | ||
# Set build type to CFE_APP. This allows us to | ||
# define different compiler flags for the cFE Core and Apps. | ||
# | ||
BUILD_TYPE = CFE_APP | ||
|
||
## | ||
## Include all necessary cFE make rules | ||
## Any of these can be copied to a local file and | ||
## changed if needed. | ||
## | ||
## | ||
## cfe-config.mak contains PSP and OS selection | ||
## | ||
include ../cfe/cfe-config.mak | ||
## | ||
## debug-opts.mak contains debug switches | ||
## | ||
include ../cfe/debug-opts.mak | ||
## | ||
## compiler-opts.mak contains compiler definitions and switches/defines | ||
## | ||
include $(CFE_PSP_SRC)/$(PSP)/make/compiler-opts.mak | ||
|
||
## | ||
## Setup the include path for this subsystem | ||
## The OS specific includes are in the build-rules.make file | ||
## | ||
## If this subsystem needs include files from another app, add the path here. | ||
## | ||
INCLUDE_PATH = \ | ||
-I$(OSAL_SRC)/inc \ | ||
-I$(CFE_CORE_SRC)/inc \ | ||
-I$(CFE_PSP_SRC)/inc \ | ||
-I$(CFE_PSP_SRC)/$(PSP)/inc \ | ||
-I$(CFS_APP_SRC)/inc \ | ||
-I$(CFS_APP_SRC)/$(APPTARGET)/fsw/src \ | ||
-I$(CFS_MISSION_INC) \ | ||
-I../cfe/inc \ | ||
-I../inc | ||
|
||
## | ||
## Define the VPATH make variable. | ||
## This can be modified to include source from another directory. | ||
## If there is no corresponding app in the cfs-apps directory, then this can be discarded, or | ||
## if the mission chooses to put the src in another directory such as "src", then that can be | ||
## added here as well. | ||
## | ||
VPATH = $(CFS_APP_SRC)/$(APPTARGET)/fsw/src | ||
|
||
## | ||
## Include the common make rules for building a cFE Application | ||
## | ||
include $(CFE_CORE_SRC)/make/app-rules.mak |
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 |
---|---|---|
@@ -0,0 +1,57 @@ | ||
/* Copyright (C) 2009 - 2017 National Aeronautics and Space Administration. All Foreign Rights are Reserved to the U.S. Government. | ||
This software is provided "as is" without any warranty of any, kind either express, implied, or statutory, including, but not | ||
limited to, any warranty that the software will conform to, specifications any implied warranties of merchantability, fitness | ||
for a particular purpose, and freedom from infringement, and any warranty that the documentation will conform to the program, or | ||
any warranty that the software will be error free. | ||
In no event shall NASA be liable for any damages, including, but not limited to direct, indirect, special or consequential damages, | ||
arising out of, resulting from, or in any way connected with the software or its documentation. Whether or not based upon warranty, | ||
contract, tort or otherwise, and whether or not loss was sustained from, or arose out of the results of, or use of, the software, | ||
documentation or services provided hereunder | ||
ITC Team | ||
NASA IV&V | ||
[email protected] | ||
*/ | ||
#ifndef _crypto_h_ | ||
#define _crypto_h_ | ||
|
||
/* | ||
** Crypto Includes | ||
*/ | ||
#include "cfe.h" | ||
#include "itc_aes128.h" | ||
#include "itc_gcm128.h" | ||
#include "crypto_config.h" | ||
#include "crypto_events.h" | ||
#include "crypto_structs.h" | ||
#include "crypto_print.h" | ||
|
||
#include <gcrypt.h> | ||
|
||
#define CRYPTO_LIB_MAJOR_VERSION 1 | ||
#define CRYPTO_LIB_MINOR_VERSION 2 | ||
#define CRYPTO_LIB_REVISION 0 | ||
#define CRYPTO_LIB_MISSION_REV 0 | ||
|
||
/* | ||
** Prototypes | ||
*/ | ||
// Initialization | ||
extern int32 crypto_LibInit(void); | ||
// Telecommand (TC) | ||
extern int32 Crypto_TC_ApplySecurity(char* ingest, int* len_ingest); | ||
extern int32 Crypto_TC_ProcessSecurity(char* ingest, int* len_ingest); | ||
// Telemetry (TM) | ||
extern int32 Crypto_TM_ApplySecurity(char* ingest, int* len_ingest); | ||
extern int32 Crypto_TM_ProcessSecurity(char* ingest, int* len_ingest); | ||
// Advanced Orbiting Systems (AOS) | ||
extern int32 Crypto_AOS_ApplySecurity(char* ingest, int* len_ingest); | ||
extern int32 Crypto_AOS_ProcessSecurity(char* ingest, int* len_ingest); | ||
// Security Functions | ||
extern int32 Crypto_ApplySecurity(char* ingest, int* len_ingest); | ||
extern int32 Crypto_ProcessSecurity(char* ingest, int* len_ingest); | ||
|
||
|
||
#endif |
Oops, something went wrong.