Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tc process refactor #78

Merged
merged 24 commits into from
Mar 3, 2022
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
45a2250
Create Check_AntiReplay function, fix bug in Crypto_Window, reject ou…
dccutrig Feb 16, 2022
1320438
Minor typos
dccutrig Feb 16, 2022
17287d9
Add ARSN pointer to crypto_if, addiional mac_Close handles for returns
dccutrig Feb 22, 2022
befc08d
ut_tc_process stubs and cmake work
dccutrig Feb 14, 2022
74cbc88
Change all ARC/ARSN refs to ARSN, add ARSN TC_Process UTs
dccutrig Feb 23, 2022
ee38525
Add test cases to IV verify UTs
dccutrig Feb 23, 2022
e64cc3e
Add ARN test cases
dccutrig Feb 28, 2022
7585a01
Fix KMC warnings
dccutrig Feb 28, 2022
cf873cb
Create Check_AntiReplay function, fix bug in Crypto_Window, reject ou…
dccutrig Feb 16, 2022
7d6ee51
Minor typos
dccutrig Feb 16, 2022
698bdf4
Add ARSN pointer to crypto_if, addiional mac_Close handles for returns
dccutrig Feb 22, 2022
0e6f10c
ut_tc_process stubs and cmake work
dccutrig Feb 14, 2022
fa28b14
Change all ARC/ARSN refs to ARSN, add ARSN TC_Process UTs
dccutrig Feb 23, 2022
985ce18
Add test cases to IV verify UTs
dccutrig Feb 23, 2022
5f9ab52
Add ARN test cases
dccutrig Feb 28, 2022
bb31a3e
Fix KMC warnings
dccutrig Feb 28, 2022
fb0009c
Fix ACS as bytefield parsing from mariadb sadb queries and Crypto Ser…
IbraheemYSaleh Mar 1, 2022
cd92108
Merge mariadb from dev to branch
IbraheemYSaleh Mar 1, 2022
6eb6e80
Small bug fix, minor print statement update
dccutrig Mar 1, 2022
0fc0f93
Cleanup un-needed pointers, move Check ARSN/IV to crypto_tc, update y…
dccutrig Mar 2, 2022
6a165c0
Modify yaml build step
dccutrig Mar 2, 2022
b5fc902
Modify YAMLs
dccutrig Mar 2, 2022
ddbca50
Update UTs failing because IV checks are now working appropriately
dccutrig Mar 3, 2022
22fe01d
Add create_sadb.sql minor update from KG feedback
IbraheemYSaleh Mar 3, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev libmariadb-dev libmariadb-dev-compat

Expand All @@ -37,6 +40,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev libmariadb-dev libmariadb-dev-compat libcurl4-openssl-dev

Expand All @@ -60,6 +66,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev libmariadb-dev libmariadb-dev-compat libcurl4-openssl-dev

Expand All @@ -83,6 +92,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev libmariadb-dev libmariadb-dev-compat libcurl4-openssl-dev

Expand All @@ -106,6 +118,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev libmariadb-dev libmariadb-dev-compat libcurl4-openssl-dev

Expand All @@ -129,6 +144,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev libmariadb-dev libmariadb-dev-compat libcurl4-openssl-dev

Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/utest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev

Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Update
run: sudo apt-get update

- name: Install Dependencies
run: sudo apt-get install -y libgpg-error-dev libgcrypt20-dev python3 lcov

Expand Down
1 change: 1 addition & 0 deletions include/crypto.h
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ int32_t Crypto_window(uint8_t* actual, uint8_t* expected, int length, int window
uint16_t Crypto_Calc_FECF(uint8_t* ingest, int len_ingest);
void Crypto_Calc_CRC_Init_Table(void);
uint16_t Crypto_Calc_CRC16(uint8_t* data, int size);
int32_t Crypto_Check_Anti_Replay(SecurityAssociation_t *sa_ptr, uint8_t *arsn, uint8_t *iv);

// Key Management Functions
int32_t Crypto_Key_OTAR(void);
Expand Down
10 changes: 5 additions & 5 deletions include/crypto_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@
#define SA_DELETE 0
// SA Additional Directives
#define SA_STATUS 8
#define SA_SETARC 9
#define SA_SETARCW 10
#define SA_SETARSN 9
#define SA_SETARSNW 10

// Key State Defines
#define KEY_PREACTIVE 0
Expand Down Expand Up @@ -116,8 +116,8 @@
#define SEGMENT_HDR_SIZE 1
#define ECS_SIZE 4 /* bytes */
#define ABM_SIZE 1024 // 20 /* bytes */
#define ARC_SIZE 20 /* total messages */
#define ARCW_SIZE 1 /* bytes */
#define ARSN_SIZE 20 /* total messages */
#define ARSNW_SIZE 1 /* bytes */
#define SN_SIZE 0
#define CHALLENGE_SIZE 16 /* bytes */
#define CHALLENGE_MAC_SIZE 16 /* bytes */
Expand Down Expand Up @@ -160,7 +160,7 @@

// TC Defines
#define TC_SH_SIZE 8 /* bits */
#define TC_SN_SIZE 0
#define TC_SN_SIZE 2
#define TC_SN_WINDOW 10 /* +/- value */
#define TC_PAD_SIZE 0
#define TC_FRAME_DATA_SIZE 1740 /* bytes */
Expand Down
4 changes: 3 additions & 1 deletion include/crypto_error.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
#define CRYPTO_LIB_ERR_UT_BYTE_MISMATCH (-10)
#define CRYPTO_LIB_ERR_NO_CONFIG (-11)
#define CRYPTO_LIB_ERR_INVALID_FECF (-12)
#define CRYPTO_LIB_ERR_BAD_ANTIREPLAY_WINDOW (-13)
#define CRYPTO_LIB_ERR_ARSN_OUTSIDE_WINDOW (-13)
#define CRYPTO_LIB_ERR_LIBGCRYPT_ERROR (-14)
#define CRYPTO_LIB_ERR_AUTHENTICATION_ERROR (-15)
#define CRYPTO_LIB_ERR_NULL_IV (-16)
Expand All @@ -73,5 +73,7 @@
#define CRYPTO_LIB_ERR_MAC_RETRIEVAL_ERROR (-20)
#define CRYPTO_LIB_ERR_MAC_VALIDATION_ERROR (-21)
#define CRYPTO_LIB_ERR_INVALID_HEADER (-22)
#define CRYPTO_LIB_ERR_IV_OUTSIDE_WINDOW (-23)
#define CRYPTO_LIB_ERR_NULL_ARSN (-24)

#endif //_crypto_error_h_
10 changes: 5 additions & 5 deletions include/crypto_structs.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,13 @@ typedef struct
uint8_t ecs_len : 8; // Encryption Cipher Suite Length
uint8_t* iv; // Initialization Vector
uint8_t acs_len : 8; // Authentication Cipher Suite Length
uint8_t acs : 8; // Authentication Cipher Suite (algorithm / mode ID)
uint8_t* acs; // Authentication Cipher Suite (algorithm / mode ID)
uint16_t abm_len : 16; // Authentication Bit Mask Length
uint8_t* abm; // Authentication Bit Mask (Primary Hdr. through Security Hdr.)
uint8_t arc_len : 8; // Anti-Replay Counter Length
uint8_t* arc; // Anti-Replay Counter
uint8_t arcw_len : 8; // Anti-Replay Counter Window Length
uint16_t arcw; // Anti-Replay Counter Window
uint8_t arsn_len : 8; // Anti-Replay Seq Num Length
uint8_t* arsn; // Anti-Replay Seq Num
uint8_t arsnw_len : 8; // Anti-Replay Seq Num Window Length
uint16_t arsnw; // Anti-Replay Seq Num Window

} SecurityAssociation_t;
#define SA_SIZE (sizeof(SecurityAssociation_t))
Expand Down
10 changes: 5 additions & 5 deletions src/crypto_sadb/sadb_mariadb_admin_scripts/create_sadb.sql
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ CREATE TABLE security_associations
,iv_len SMALLINT NOT NULL DEFAULT 12
,iv VARBINARY(20) NOT NULL DEFAULT X'000000000000000000000000' -- IV_SIZE=12
,acs_len SMALLINT NOT NULL DEFAULT 0
,acs SMALLINT NOT NULL DEFAULT 0
,acs VARBINARY(4) NOT NULL DEFAULT X'00'
,abm_len MEDIUMINT
,abm VARBINARY(1024) NOT NULL DEFAULT X'1111111111111111111111111111111111111111' -- ABM_SIZE=1024
,arc_len SMALLINT NOT NULL DEFAULT 0
,arc VARBINARY(20) NOT NULL DEFAULT X'0000000000000000000000000000000000000000' -- ARC_SIZE=20 , TBD why so large...
,arcw_len SMALLINT
,arcw SMALLINT NOT NULL DEFAULT 0 -- ARCW_SIZE=1
,arsn_len SMALLINT NOT NULL DEFAULT 0
,arsn VARBINARY(20) NOT NULL DEFAULT X'0000000000000000000000000000000000000000' -- ARSN_SIZE=20 , TBD why so large...
,arsnw_len SMALLINT
,arsnw SMALLINT NOT NULL DEFAULT 0 -- ARSNW_SIZE=1
);

create unique index if not exists main_spi on security_associations (spi,scid,vcid,tfvn,mapid);
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
USE sadb;

-- SCID 44 (MMT) Security Associations AES/GCM/NoPadding --
-- SA 1 - OPERATIONAL; ENC + AUTH - ARCW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-0
INSERT INTO security_associations (spi,ekid,sa_state,ecs,est,ast,shivf_len,stmacf_len,iv,abm_len,abm,arcw_len,arcw,arc_len,tfvn,scid,vcid,mapid)
VALUES (1,'kmc/test/key130',3,X'01',1,1,12,16,X'000000000000000000000001',19,X'00000000000000000000000000000000000000',1,5,0,0,44,0,0);

-- SA 2 - OPERATIONAL; ENC + AUTH - ARCW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-1
INSERT INTO security_associations (spi,ekid,sa_state,ecs,est,ast,shivf_len,stmacf_len,iv,abm_len,abm,arcw_len,arcw,arc_len,tfvn,scid,vcid,mapid)
VALUES (2,'kmc/test/key130',3,X'01',1,1,12,16,X'000000000000000000000001',19,X'00000000000000000000000000000000000000',1,5,0,0,44,1,0);

-- SA 3 - OPERATIONAL; ENC + AUTH - ARCW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-1
INSERT INTO security_associations (spi,ekid,sa_state,ecs,est,ast,shivf_len,stmacf_len,iv,abm_len,abm,arcw_len,arcw,arc_len,tfvn,scid,vcid,mapid)
VALUES (3,'kmc/test/key130',3,X'01',1,1,12,16,X'000000000000000000000001',19,X'00000000000000000000000000000000000000',1,5,0,0,44,2,0);

-- SA 4 - OPERATIONAL; AUTH Only - ARCW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-3
INSERT INTO security_associations (spi,ekid,sa_state,ecs,est,ast,shivf_len,stmacf_len,iv,abm_len,abm,arcw_len,arcw,arc_len,tfvn,scid,vcid,mapid)
VALUES (4,'kmc/test/key130',3,X'01',0,1,12,16,X'000000000000000000000001',1024,X'FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF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FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF',1,5,4,0,44,7,0);
USE sadb;
-- SCID 44 (MMT) Security Associations AES/GCM/NoPadding --
-- SA 1 - OPERATIONAL; ENC + AUTH - ARSNW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-0
INSERT INTO security_associations (spi,ekid,sa_state,ecs,est,ast,shivf_len,stmacf_len,iv,abm_len,abm,arsnw_len,arsnw,arsn_len,tfvn,scid,vcid,mapid)
VALUES (1,'kmc/test/key130',3,X'01',1,1,12,16,X'000000000000000000000001',19,X'00000000000000000000000000000000000000',1,5,0,0,44,0,0);
-- SA 2 - OPERATIONAL; ENC + AUTH - ARSNW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-1
INSERT INTO security_associations (spi,ekid,sa_state,ecs,est,ast,shivf_len,stmacf_len,iv,abm_len,abm,arsnw_len,arsnw,arsn_len,tfvn,scid,vcid,mapid)
VALUES (2,'kmc/test/key130',3,X'01',1,1,12,16,X'000000000000000000000001',19,X'00000000000000000000000000000000000000',1,5,0,0,44,1,0);
-- SA 3 - OPERATIONAL; ENC + AUTH - ARSNW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-1
INSERT INTO security_associations (spi,ekid,sa_state,ecs,est,ast,shivf_len,stmacf_len,iv,abm_len,abm,arsnw_len,arsnw,arsn_len,tfvn,scid,vcid,mapid)
VALUES (3,'kmc/test/key130',3,X'01',1,1,12,16,X'000000000000000000000001',19,X'00000000000000000000000000000000000000',1,5,0,0,44,2,0);
-- SA 4 - OPERATIONAL; AUTH Only - ARSNW:5; AES-GCM; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 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FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF',1,5,0,0,44,3,0);
-- SCID 44 (MMT) Security Associations AESCMAC Authentication Only --
-- SA 5 - OPERATIONAL; AUTH Only - ARSNW:5; None/AESCMAC ; IV:00...01; IV-len:12; MAC-len:16; Key-ID: 130, SCID 44, VC-7
INSERT INTO security_associations (spi,akid,sa_state,ecs,acs,est,ast,shivf_len,shsnf_len,stmacf_len,arsn,abm_len,abm,arsnw_len,arsnw,arsn_len,tfvn,scid,vcid,mapid)
VALUES (5,'kmc/test/key130',3,X'00',X'01',0,1,0,4,16,X'00000001',1024,X'FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF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