Commit 3824b1be authored by garciay's avatar garciay
Browse files

Bug fixed validating Security with Commsignia

parent 85e1745a
...@@ -802,9 +802,12 @@ module ItsDenm_TpFunctions { ...@@ -802,9 +802,12 @@ module ItsDenm_TpFunctions {
f_utTriggerEvent(m_utTriggerEvent(v_situation)); f_utTriggerEvent(m_utTriggerEvent(v_situation));
f_awaitDenMessage(mw_denmInd(mw_anyDenmPdu), v_denmInd); f_awaitDenMessage(mw_denmInd(mw_anyDenmPdu), v_denmInd);
v_timestampIts := f_getCurrentTime(); v_timestampIts := f_getCurrentTime();
//log("v_timestampIts: ", v_timestampIts);
v_actionId := v_denmInd.msgIn.denm.management.actionID; v_actionId := v_denmInd.msgIn.denm.management.actionID;
v_referenceTime1 := v_denmInd.msgIn.denm.management.referenceTime; v_referenceTime1 := v_denmInd.msgIn.denm.management.referenceTime;
//log("v_referenceTime1: ", v_referenceTime1);
v_diff := v_timestampIts - v_referenceTime1; v_diff := v_timestampIts - v_referenceTime1;
//log("v_diff: ", v_diff);
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success); f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
// Test Body // Test Body
...@@ -827,7 +830,9 @@ module ItsDenm_TpFunctions { ...@@ -827,7 +830,9 @@ module ItsDenm_TpFunctions {
) -> value v_denmInd { ) -> value v_denmInd {
tc_ac.stop; tc_ac.stop;
v_timestampIts := f_getCurrentTime(); v_timestampIts := f_getCurrentTime();
//log("v_timestampIts: ", v_timestampIts);
v_msgtimestamp := v_denmInd.msgIn.denm.management.referenceTime; v_msgtimestamp := v_denmInd.msgIn.denm.management.referenceTime;
//log("v_msgtimestamp: ", v_msgtimestamp);
if ( ( ( v_timestampIts + v_diff ) > v_msgtimestamp ) and ( v_msgtimestamp > v_referenceTime1 ) ) { if ( ( ( v_timestampIts + v_diff ) > v_msgtimestamp ) and ( v_msgtimestamp > v_referenceTime1 ) ) {
log("*** " & testcasename() & ": PASS: Successfully received expected DENM. ***"); log("*** " & testcasename() & ": PASS: Successfully received expected DENM. ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success); f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
...@@ -1535,8 +1540,7 @@ module ItsDenm_TpFunctions { ...@@ -1535,8 +1540,7 @@ module ItsDenm_TpFunctions {
const float c_upperRepetitionInterval := int2float(c_repetitionInterval)*1.05; const float c_upperRepetitionInterval := int2float(c_repetitionInterval)*1.05;
// Local variables // Local variables
var template (value) SituationContainer v_situation := m_situation(CauseCodeType_vehicleBreakdown_, VehicleBreakdownSubCauseCode_unavailable_); var template (value) SituationContainer v_situation := m_situation(CauseCodeType_vehicleBreakdown_, VehicleBreakdownSubCauseCode_unavailable_);
var template (present) DenmInd v_expectedDenmInd := var template (present) DenmInd v_expectedDenmInd := mw_denmInd(mw_denmPdu(mw_denm( mw_denmMgmtCon( mw_actionId, -, -, c_validityDuration))));
mw_denmInd(mw_denmPdu(mw_denm( mw_denmMgmtCon( mw_actionId, -, -, c_validityDuration))));
var ActionID v_actionId; var ActionID v_actionId;
var DenmInd v_denmInd; var DenmInd v_denmInd;
// Local timers // Local timers
...@@ -2924,7 +2928,7 @@ module ItsDenm_TpFunctions { ...@@ -2924,7 +2928,7 @@ module ItsDenm_TpFunctions {
function f_DEN_MSRV_BO_08_01 () runs on ItsDenm { function f_DEN_MSRV_BO_08_01 () runs on ItsDenm {
f_DEN_MSRV_BO_08_XX( f_DEN_MSRV_BO_08_XX(
"CERT_TS_DENM_01", "CERT_TS_DENM_BO_01_AT",
m_situation(CauseCodeType_trafficCondition_, TrafficConditionSubCauseCode_unavailable_) m_situation(CauseCodeType_trafficCondition_, TrafficConditionSubCauseCode_unavailable_)
); );
} }
...@@ -2932,7 +2936,7 @@ module ItsDenm_TpFunctions { ...@@ -2932,7 +2936,7 @@ module ItsDenm_TpFunctions {
function f_DEN_MSRV_BO_08_02 () runs on ItsDenm { function f_DEN_MSRV_BO_08_02 () runs on ItsDenm {
f_DEN_MSRV_BO_08_XX( f_DEN_MSRV_BO_08_XX(
"CERT_TS_DENM_02", "CERT_TS_DENM_BO_02_AT",
m_situation(CauseCodeType_accident_, AccidentSubCauseCode_unavailable_) m_situation(CauseCodeType_accident_, AccidentSubCauseCode_unavailable_)
); );
} }
...@@ -2980,6 +2984,7 @@ module ItsDenm_TpFunctions { ...@@ -2980,6 +2984,7 @@ module ItsDenm_TpFunctions {
); );
f_sleep(1.0); f_sleep(1.0);
vc_utEvents := {};
// instruct adapter to use p_certName to sign message // instruct adapter to use p_certName to sign message
if(e_success != f_acTriggerSecEvent(m_acEnableSecurity(p_certName))) { if(e_success != f_acTriggerSecEvent(m_acEnableSecurity(p_certName))) {
...@@ -3025,7 +3030,7 @@ module ItsDenm_TpFunctions { ...@@ -3025,7 +3030,7 @@ module ItsDenm_TpFunctions {
function f_DEN_MSRV_BO_09_01 () runs on ItsDenm { function f_DEN_MSRV_BO_09_01 () runs on ItsDenm {
f_DEN_MSRV_BO_09_XX( f_DEN_MSRV_BO_09_XX(
"CERT_TS_DENM_01", "CERT_TS_DENM_BO_01_AT",
m_situation(CauseCodeType_trafficCondition_, TrafficConditionSubCauseCode_unavailable_), m_situation(CauseCodeType_trafficCondition_, TrafficConditionSubCauseCode_unavailable_),
m_situation(CauseCodeType_trafficCondition_, TrafficConditionSubCauseCode_trafficJamIncreasing_) m_situation(CauseCodeType_trafficCondition_, TrafficConditionSubCauseCode_trafficJamIncreasing_)
); );
...@@ -3034,7 +3039,7 @@ module ItsDenm_TpFunctions { ...@@ -3034,7 +3039,7 @@ module ItsDenm_TpFunctions {
function f_DEN_MSRV_BO_09_02 () runs on ItsDenm { function f_DEN_MSRV_BO_09_02 () runs on ItsDenm {
f_DEN_MSRV_BO_09_XX( f_DEN_MSRV_BO_09_XX(
"CERT_TS_DENM_02", "CERT_TS_DENM_BO_02_AT",
m_situation(CauseCodeType_accident_, AccidentSubCauseCode_unavailable_), m_situation(CauseCodeType_accident_, AccidentSubCauseCode_unavailable_),
m_situation(CauseCodeType_accident_, AccidentSubCauseCode_multiVehicleAccident_) m_situation(CauseCodeType_accident_, AccidentSubCauseCode_multiVehicleAccident_)
); );
......
...@@ -1526,36 +1526,36 @@ module AtsSecurity_TestCases { ...@@ -1526,36 +1526,36 @@ module AtsSecurity_TestCases {
* Config Id: CF01 * Config Id: CF01
* Initial conditions: * Initial conditions:
* </pre> * </pre>
* with * with
* the IUT being in the 'authorized' state * the IUT being in the 'authorized' state
* and the IUT is configured to send more than one CAM per second * and the IUT is configured to send more than one CAM per second
* and the IUT having already sent a CAM * and the IUT having already sent a CAM
* containing header_fields['signer_info'].signer.type * containing header_fields['signer_info'].signer.type
* indicating 'certificate' * indicating 'certificate'
* at TIME_1 * at TIME_1
* and the IUT having received a SecuredMessage * and the IUT having received a SecuredMessage
* containing header_fields['request_unrecognized_certificate'] * containing header_fields['request_unrecognized_certificate']
* containing digests * containing digests
* containing HashedId3 value (HASH1) * containing HashedId3 value (HASH1)
* referencing to the AA certificate * referencing to the AA certificate
* at TIME_2 (TIME_1 < TIME_2 < TIME_1+1sec) * at TIME_2 (TIME_1 < TIME_2 < TIME_1+1sec)
* and the IUT having received a SecuredMessage * and the IUT having received a SecuredMessage
* containing header_fields['signer_info'].signer.type * containing header_fields['signer_info'].signer.type
* indicating 'certificate_chain' * indicating 'certificate_chain'
* containing AA certificate * containing AA certificate
* having HashedId3 value of HASH1 * having HashedId3 value of HASH1
* at TIME_3 (TIME_2 < TIME_3 < TIME_2+0.1sec) * at TIME_3 (TIME_2 < TIME_3 < TIME_2+0.1sec)
* ensure that * ensure that
* when * when
* the IUT is requested to send a CAM * the IUT is requested to send a CAM
* at TIME_3 (TIME_1 < TIME_2 < TIME_3 < TIME_1+1sec) * at TIME_3 (TIME_1 < TIME_2 < TIME_3 < TIME_1+1sec)
* then * then
* the IUT sends a SecuredMessage * the IUT sends a SecuredMessage
* and containing header_fields['signer_info'] * and containing header_fields['signer_info']
* containing signer * containing signer
* containing type * containing type
* indicating 'digest' * indicating 'digest'
* or indicating 'certificate' * or indicating 'certificate'
* *
* @see ETSI TS 103 096-2 v1.3.3 TP_SEC_ITSS_SND_CAM_09_02_BV * @see ETSI TS 103 096-2 v1.3.3 TP_SEC_ITSS_SND_CAM_09_02_BV
* @reference ETSI TS 103 097 [1], clause 7.1 * @reference ETSI TS 103 097 [1], clause 7.1
...@@ -1618,7 +1618,7 @@ module AtsSecurity_TestCases { ...@@ -1618,7 +1618,7 @@ module AtsSecurity_TestCases {
f_sendSecuredCam( f_sendSecuredCam(
cc_taCert_A1, cc_taCert_A1,
omit, omit,
e_certificate_chain e_certificate_chain
); );
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success); f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
...@@ -1641,18 +1641,18 @@ module AtsSecurity_TestCases { ...@@ -1641,18 +1641,18 @@ module AtsSecurity_TestCases {
log("*** " & testcasename() & ": FAIL: CAM retransmition with unexpected certificate_chain ***"); log("*** " & testcasename() & ": FAIL: CAM retransmition with unexpected certificate_chain ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
[] geoNetworkingPort.receive( [] geoNetworkingPort.receive(
mw_geoNwInd( mw_geoNwInd(
mw_geoNwSecPdu( mw_geoNwSecPdu(
mdw_securedMessage_CAMs mdw_securedMessage_CAMs
))) { ))) {
log("*** " & testcasename() & ": INFO: CAM retransmission w/o certificate chain ***"); log("*** " & testcasename() & ": INFO: CAM retransmission w/o certificate chain ***");
repeat; repeat;
} }
[] t_maxTransInterval.timeout { [] t_maxTransInterval.timeout {
tc_ac.stop; tc_ac.stop;
log("*** " & testcasename() & ": PASS: Generation of CAM messages including certificate chain was successfully skipped ***"); log("*** " & testcasename() & ": PASS: Generation of CAM messages including certificate chain was successfully skipped ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
} }
[] tc_ac.timeout { [] tc_ac.timeout {
...@@ -1793,19 +1793,20 @@ module AtsSecurity_TestCases { ...@@ -1793,19 +1793,20 @@ module AtsSecurity_TestCases {
log("*** " & testcasename() & ": PASS: Generation time within certificate validity ***"); log("*** " & testcasename() & ": PASS: Generation time within certificate validity ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
} else if (f_getCertificateValidityRestriction(v_certificate, e_time_start_and_duration, v_validity) == true) { } else if (f_getCertificateValidityRestriction(v_certificate, e_time_start_and_duration, v_validity) == true) {
if (PICS_PLUGTEST_VERSION) { if (PICS_PLUGTEST_VERSION) {
log("*** " & testcasename() & ": FAIL: Usage of time_start_and_duration is forbidden in TS103097 v1.2.5 ***"); log("*** " & testcasename() & ": FAIL: Usage of time_start_and_duration is forbidden in TS103097 v1.2.5 ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
if ((v_generationTime >= (v_validity.validity.time_start_and_duration.start_validity * 1000000)) and if ((v_generationTime >= (v_validity.validity.time_start_and_duration.start_validity * 1000000)) and
(v_generationTime < (f_duration2time(v_validity.validity.time_start_and_duration.duration_) * 1000000)) (v_generationTime < (f_duration2time(v_validity.validity.time_start_and_duration.duration_) * 1000000))
) { ) {
log("*** " & testcasename() & ": PASS: Generation time within certificate validity ***"); log("*** " & testcasename() & ": PASS: Generation time within certificate validity ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
} }
} else {
log("*** " & testcasename() & ": FAIL: Generation time not within certificate validity ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
log("*** " & testcasename() & ": FAIL: Generation time not within certificate validity ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
[] geoNetworkingPort.receive( [] geoNetworkingPort.receive(
mw_geoNwInd( mw_geoNwInd(
...@@ -2008,100 +2009,100 @@ module AtsSecurity_TestCases { ...@@ -2008,100 +2009,100 @@ module AtsSecurity_TestCases {
f_poNeighbour(); f_poNeighbour();
f_cf01Down(); f_cf01Down();
} // End of testcase TC_SEC_ITSS_SND_CAM_14_01_BV } // End of testcase TC_SEC_ITSS_SND_CAM_14_01_BV
/** /**
* @desc Check that the secured CAM contains only the trailer field of type signature * @desc Check that the secured CAM contains only the trailer field of type signature
* and no other trailer fields * and no other trailer fields
* <pre> * <pre>
* Pics Selection: PICS_GN_SECURITY PICS_PLUGTEST_VERSION * Pics Selection: PICS_GN_SECURITY PICS_PLUGTEST_VERSION
* Config Id: CF01 * Config Id: CF01
* Initial conditions: * Initial conditions:
* with * with
* the IUT being in the 'authorized' state * the IUT being in the 'authorized' state
* ensure that * ensure that
* when * when
* the IUT is requested to send a CAM * the IUT is requested to send a CAM
* then * then
* the IUT sends a SecuredMessage * the IUT sends a SecuredMessage
* containing trailer_fields * containing trailer_fields
* containing trailer_fields[0] * containing trailer_fields[0]
* containing type * containing type
* indicating 'signature' * indicating 'signature'
* and not containing any other items * and not containing any other items
   
* </pre> * </pre>
* *
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_SND_CAM_15_01_BV * @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_SND_CAM_15_01_BV
* @reference ETSI TS 103 097 [1], clause 7.1 * @reference ETSI TS 103 097 [1], clause 7.1
*/ */
testcase TC_SEC_ITSS_SND_CAM_15_01_BV() runs on ItsGeoNetworking system ItsSecSystem { testcase TC_SEC_ITSS_SND_CAM_15_01_BV() runs on ItsGeoNetworking system ItsSecSystem {
// Local variables // Local variables
const integer c_nbVerification := 3; const integer c_nbVerification := 3;
var integer v_nbVerification := 0; var integer v_nbVerification := 0;
var GeoNetworkingInd v_geoNwInd; var GeoNetworkingInd v_geoNwInd;
var SignerInfo v_signerInfo; var SignerInfo v_signerInfo;
var Certificate v_certificate; var Certificate v_certificate;
var boolean v_certificateReceived := false; var boolean v_certificateReceived := false;
// Test control // Test control
if (not(PICS_GN_SECURITY)) { if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***"); log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop; stop;
} }
if (not(PICS_PLUGTEST_VERSION)) { if (not(PICS_PLUGTEST_VERSION)) {
log("*** " & testcasename() & ":ERROR: 'PICS_PLUGTEST_VERSION' required for executing the TC ***"); log("*** " & testcasename() & ":ERROR: 'PICS_PLUGTEST_VERSION' required for executing the TC ***");
stop; stop;
} }
// Test component configuration // Test component configuration
f_cf01Up(); f_cf01Up();
// Test adapter configuration // Test adapter configuration
// Preamble // Preamble
f_prNeighbour(); f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success); f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
// Test Body // Test Body
tc_ac.start; tc_ac.start;
alt { alt {
[] geoNetworkingPort.receive( [] geoNetworkingPort.receive(
mw_geoNwInd( mw_geoNwInd(
mw_geoNwSecPdu( mw_geoNwSecPdu(
mdw_securedMessage_CAMs(?, ?, mdw_securedMessage_CAMs(?, ?,
superset(mw_trailer_field_signature, superset(mw_trailer_field_signature,
mw_trailer_field mw_trailer_field
))))){ ))))){
tc_ac.stop; tc_ac.stop;
log("*** " & testcasename() & ": FAIL: CAM received with more then one trailer fields"); log("*** " & testcasename() & ": FAIL: CAM received with more then one trailer fields");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
[] geoNetworkingPort.receive( [] geoNetworkingPort.receive(
mw_geoNwInd( mw_geoNwInd(
mw_geoNwSecPdu( mw_geoNwSecPdu(
mdw_securedMessage_CAMs(?, ?, mdw_securedMessage_CAMs(?, ?,
{ mw_trailer_field_signature } { mw_trailer_field_signature }
)))){ )))){
tc_ac.stop; tc_ac.stop;
log("*** " & testcasename() & ": INFO: CAM message with signature trailer received ***"); log("*** " & testcasename() & ": INFO: CAM message with signature trailer received ***");
v_nbVerification := v_nbVerification + 1; v_nbVerification := v_nbVerification + 1;
if (v_nbVerification < c_nbVerification) { if (v_nbVerification < c_nbVerification) {
tc_ac.start; tc_ac.start;
repeat; repeat;
} }
} }
[] tc_ac.timeout { [] tc_ac.timeout {
log("*** " & testcasename() & ": INCONC: Expected CAM not received ***"); log("*** " & testcasename() & ": INCONC: Expected CAM not received ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_timeout); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_timeout);
} }
} // End of 'alt' statement } // End of 'alt' statement
log("*** " & testcasename() & ": PASS: All CAMs received with correct trailer fields count"); log("*** " & testcasename() & ": PASS: All CAMs received with correct trailer fields count");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
// Postamble // Postamble
f_poNeighbour(); f_poNeighbour();
f_cf01Down(); f_cf01Down();
} // End of testcase TC_SEC_ITSS_SND_CAM_15_01_BV } // End of testcase TC_SEC_ITSS_SND_CAM_15_01_BV
/** /**
...@@ -2682,10 +2683,10 @@ module AtsSecurity_TestCases { ...@@ -2682,10 +2683,10 @@ module AtsSecurity_TestCases {
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
} else if (v_cert.validity_restrictions[v_counter].type_ == e_time_start_and_duration) { } else if (v_cert.validity_restrictions[v_counter].type_ == e_time_start_and_duration) {
if (PICS_PLUGTEST_VERSION){ if (PICS_PLUGTEST_VERSION){
log("*** " & testcasename() & ": FAIL: Usage of time_start_and_duration is not allowed in TS103097 v1.2.5"); log("*** " & testcasename() & ": FAIL: Usage of time_start_and_duration is not allowed in TS103097 v1.2.5");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
v_startTime := v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.start_validity * 1000000; v_startTime := v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.start_validity * 1000000;
v_duration := f_duration2time(v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.duration_) * 1000000; v_duration := f_duration2time(v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.duration_) * 1000000;
if (not match(v_generationTime, Time64:(v_startTime .. v_duration))){ if (not match(v_generationTime, Time64:(v_startTime .. v_duration))){
...@@ -3263,25 +3264,25 @@ module AtsSecurity_TestCases { ...@@ -3263,25 +3264,25 @@ module AtsSecurity_TestCases {
* Config Id: CF01 * Config Id: CF01
* Initial conditions: * Initial conditions:
* with * with
* the IUT being in the 'authorized' state * the IUT being in the 'authorized' state
* ensure that * ensure that
* when * when
* the IUT is requested to send DENM * the IUT is requested to send DENM
* then * then
* the IUT sends a SecuredMessage * the IUT sends a SecuredMessage
* containing trailer_fields * containing trailer_fields
* containing trailer_fields[0] * containing trailer_fields[0]
* containing type * containing type
* indicating 'signature' * indicating 'signature'
* and not containing other items * and not containing other items
* </pre> * </pre>
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_SND_DENM_09_01_BV * @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_SND_DENM_09_01_BV
* @reference ETSI TS 103 097 [1], clause 7.2 * @reference ETSI TS 103 097 [1], clause 7.2
*/ */
testcase TC_SEC_ITSS_SND_DENM_09_01_BV() runs on ItsGeoNetworking system ItsSecSystem { testcase TC_SEC_ITSS_SND_DENM_09_01_BV() runs on ItsGeoNetworking system ItsSecSystem {
// Local variables // Local variables
const integer c_nbVerification := 3; const integer c_nbVerification := 3;
var integer v_nbVerification := 0; var integer v_nbVerification := 0;
var ItsDenm v_denmComponent; var ItsDenm v_denmComponent;
// Test control // Test control
...@@ -3290,10 +3291,10 @@ module AtsSecurity_TestCases { ...@@ -3290,10 +3291,10 @@ module AtsSecurity_TestCases {
stop; stop;
} }
   
if (not(PICS_PLUGTEST_VERSION)) { if (not(PICS_PLUGTEST_VERSION)) {
log("*** " & testcasename() & ":ERROR: 'PICS_PLUGTEST_VERSION' required for executing the TC ***"); log("*** " & testcasename() & ":ERROR: 'PICS_PLUGTEST_VERSION' required for executing the TC ***");
stop; stop;
} }
// Test component configuration // Test component configuration
f_cf01Up(); f_cf01Up();
...@@ -3306,26 +3307,26 @@ module AtsSecurity_TestCases { ...@@ -3306,26 +3307,26 @@ module AtsSecurity_TestCases {
// Test Body // Test Body
tc_ac.start; tc_ac.start;
alt { alt {
[] geoNetworkingPort.receive( [] geoNetworkingPort.receive(
mw_geoNwInd( mw_geoNwInd(
mw_geoNwSecPdu( mw_geoNwSecPdu(
mdw_securedMessage_DENMs(?, ?, { mdw_securedMessage_DENMs(?, ?, {
mw_trailer_field_signature mw_trailer_field_signature
}) })
))){ ))){
tc_ac.stop; tc_ac.stop;
log("*** " & testcasename() & ": INFO: DENM message with signature trailer received ***"); log("*** " & testcasename() & ": INFO: DENM message with signature trailer received ***");
v_nbVerification := v_nbVerification + 1; v_nbVerification := v_nbVerification + 1;
if (v_nbVerification < c_nbVerification) { if (v_nbVerification < c_nbVerification) {
tc_ac.start; tc_ac.start;
repeat; repeat;
} }
} }
   
[] geoNetworkingPort.receive( [] geoNetworkingPort.receive(
mw_geoNwInd( mw_geoNwInd(
mw_geoNwSecPdu( mw_geoNwSecPdu(
mdw_securedMessage_DENMs(?, ?, {}) mdw_securedMessage_DENMs(?, ?, {})
))) { ))) {
tc_ac.stop; tc_ac.stop;
log("*** " & testcasename() & ": FAIL: DENM message with NO trailer fields received ***"); log("*** " & testcasename() & ": FAIL: DENM message with NO trailer fields received ***");
...@@ -3335,8 +3336,8 @@ module AtsSecurity_TestCases { ...@@ -3335,8 +3336,8 @@ module AtsSecurity_TestCases {
[] geoNetworkingPort.receive( [] geoNetworkingPort.receive(
mw_geoNwInd( mw_geoNwInd(
mw_geoNwSecPdu( mw_geoNwSecPdu(
mdw_securedMessage_DENMs(?, ?, mdw_securedMessage_DENMs(?, ?,
superset( mw_trailer_field, ? ) superset( mw_trailer_field, ? )
)))) { )))) {
tc_ac.stop; tc_ac.stop;
log("*** " & testcasename() & ": FAIL: DENM message with more than one trailer field received ***"); log("*** " & testcasename() & ": FAIL: DENM message with more than one trailer field received ***");
...@@ -3897,10 +3898,10 @@ module AtsSecurity_TestCases { ...@@ -3897,10 +3898,10 @@ module AtsSecurity_TestCases {
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
} else if (v_cert.validity_restrictions[v_counter].type_ == e_time_start_and_duration) { } else if (v_cert.validity_restrictions[v_counter].type_ == e_time_start_and_duration) {
if (PICS_PLUGTEST_VERSION){ if (PICS_PLUGTEST_VERSION){
log("*** " & testcasename() & ": FAIL: Usage of time_start_and_duration is not allowed in TS103097 v1.2.5"); log("*** " & testcasename() & ": FAIL: Usage of time_start_and_duration is not allowed in TS103097 v1.2.5");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }
v_startTime := v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.start_validity * 1000000; v_startTime := v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.start_validity * 1000000;
v_duration := f_duration2time(v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.duration_) * 1000000; v_duration := f_duration2time(v_cert.validity_restrictions[v_counter].validity.time_start_and_duration.duration_) * 1000000;
if (v_generationTime < v_startTime or (v_startTime + v_duration) > v_endTime ) { if (v_generationTime < v_startTime or (v_startTime + v_duration) > v_endTime ) {
...@@ -4935,10 +4936,10 @@ module AtsSecurity_TestCases { ...@@ -4935,10 +4936,10 @@ module AtsSecurity_TestCases {
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error); f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
} }