reconfigured test case for eia sec matching

master
David Rupprecht 5 years ago committed by Andre Puschmann
parent bb97d7d199
commit 4ff70b6008

@ -230,7 +230,7 @@ void nas::init(usim_interface_nas* usim_, rrc_interface_nas* rrc_, gw_interface_
nas_log->error("Empty EIA list. Select at least one EIA algorithm.\n"); nas_log->error("Empty EIA list. Select at least one EIA algorithm.\n");
} }
for (std::vector<uint8_t>::const_iterator it = cap_list.begin(); it != cap_list.end(); ++it) { for (std::vector<uint8_t>::const_iterator it = cap_list.begin(); it != cap_list.end(); ++it) {
if (*it != 0 && *it < 3) { if (*it != 0 && *it < 4) {
eia_caps[*it] = true; eia_caps[*it] = true;
} else { } else {
nas_log->error("EIA%d is not a valid EIA algorithm.\n", *it); nas_log->error("EIA%d is not a valid EIA algorithm.\n", *it);
@ -243,7 +243,7 @@ void nas::init(usim_interface_nas* usim_, rrc_interface_nas* rrc_, gw_interface_
nas_log->error("Empty EEA list. Select at least one EEA algorithm.\n"); nas_log->error("Empty EEA list. Select at least one EEA algorithm.\n");
} }
for (std::vector<uint8_t>::const_iterator it = cap_list.begin(); it != cap_list.end(); ++it) { for (std::vector<uint8_t>::const_iterator it = cap_list.begin(); it != cap_list.end(); ++it) {
if (*it < 3) { if (*it < 4) {
eea_caps[*it] = true; eea_caps[*it] = true;
} else { } else {
nas_log->error("EEA%d is not a valid EEA algorithm.\n", *it); nas_log->error("EEA%d is not a valid EEA algorithm.\n", *it);

@ -228,8 +228,8 @@ int security_command_test()
{ {
srsue::nas nas(&nas_log); srsue::nas nas(&nas_log);
nas_args_t cfg; nas_args_t cfg;
cfg.eia = "1,2"; cfg.eia = "1,2,3";
cfg.eea = "0,1,2"; cfg.eea = "0,1,2,3";
nas.init(&usim, &rrc_dummy, &gw, cfg); nas.init(&usim, &rrc_dummy, &gw, cfg);
rrc_dummy.init(&nas); rrc_dummy.init(&nas);

Loading…
Cancel
Save