Newer
Older
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing payload_field
* containing type
* indicating 'signed'
* and containing data
* indicating length 0
* } then {
* the IUT discards the message
* }
* }
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_09_02_BO
testcase TC_SEC_ITSS_RCV_DENM_09_02_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GnNonSecuredPacket v_gnNonSecuredPacket;
var octetstring v_gnPayload;
var template (value) SecuredMessage v_securedMessage;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB); // Use NodeB
var template (value) SituationContainer v_situation := m_situation(CauseCodeType_vehicleBreakdown_, VehicleBreakdownSubCauseCode_unavailable_);
// Test adapter configuration
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
16048
16049
16050
16051
16052
16053
16054
16055
16056
16057
16058
16059
16060
16061
16062
16063
16064
16065
16066
16067
16068
16069
16070
16071
16072
16073
16074
16075
16076
16077
16078
16079
16080
16081
16082
16083
16084
16085
16086
16087
16088
16089
16090
// Test Body
v_gnNonSecuredPacket := valueof(
m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
vc_localSeqNumber,
f_getGeoBroadcastArea(
c_area1 // Select area1 (see ETSI TS 102 871-2 Clause 4.2 Configuration 1)
)));
// Add the DENM payload
v_gnNonSecuredPacket.payload := valueof(
f_adaptPayload_m(
bit2oct(
encvalue(
m_denmReq(
m_denmPdu(
m_denm(
m_denmMgmtCon(
m_tsActionId
),
v_situation,
m_denmLocation_zeroDelta
)))))));
// Encode it
v_gnPayload := bit2oct(
encvalue(
v_gnNonSecuredPacket
)
);
f_buildGnSecuredDenm(
v_securedMessage,
m_payload_signed(
''O
),
e_certificate_digest_with_sha256,
valueof(m_threeDLocation(
v_longPosVectorNodeB.latitude,
v_longPosVectorNodeB.longitude,
'0000'O
))
);
v_securedGnPdu := valueof(m_geoNwSecPdu(v_gnNonSecuredPacket, v_securedMessage));
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(v_securedGnPdu));
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
} // End of 'for' statement
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
}
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_09_02_BO
* @desc Check that IUT discards the Secured DENM containing payload of type 'unsecured'
* Initial conditions:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing payload_field
* containing type
* indicating 'unsecured'
* and containing data
* } then {
* the IUT discards the message
* }
* }
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_09_03_BO
testcase TC_SEC_ITSS_RCV_DENM_09_03_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GnNonSecuredPacket v_gnNonSecuredPacket;
var octetstring v_gnPayload;
var template (value) SecuredMessage v_securedMessage;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB); // Use NodeB
var template (value) SituationContainer v_situation := m_situation(CauseCodeType_vehicleBreakdown_, VehicleBreakdownSubCauseCode_unavailable_);
// Test adapter configuration
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
16165
16166
16167
16168
16169
16170
16171
16172
16173
16174
16175
16176
16177
16178
16179
16180
16181
16182
16183
16184
16185
16186
16187
16188
16189
16190
16191
16192
16193
16194
16195
16196
16197
16198
16199
16200
16201
16202
16203
16204
16205
16206
16207
// Test Body
v_gnNonSecuredPacket := valueof(
m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
vc_localSeqNumber,
f_getGeoBroadcastArea(
c_area1 // Select area1 (see ETSI TS 102 871-2 Clause 4.2 Configuration 1)
)));
// Add the DENM payload
v_gnNonSecuredPacket.payload := valueof(
f_adaptPayload_m(
bit2oct(
encvalue(
m_denmReq(
m_denmPdu(
m_denm(
m_denmMgmtCon(
m_tsActionId
),
v_situation,
m_denmLocation_zeroDelta
)))))));
// Encode it
v_gnPayload := bit2oct(
encvalue(
v_gnNonSecuredPacket
)
);
f_buildGnSecuredDenm(
v_securedMessage,
m_payload_unsecured(
v_gnPayload
),
e_certificate_digest_with_sha256,
valueof(m_threeDLocation(
v_longPosVectorNodeB.latitude,
v_longPosVectorNodeB.longitude,
'0000'O
))
);
v_securedGnPdu := valueof(m_geoNwSecPdu(v_gnNonSecuredPacket, v_securedMessage));
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(v_securedGnPdu));
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
} // End of 'for' statement
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
}
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_09_03_BO
* @desc Check that IUT discards the Secured DENM containing payload of type 'encrypted'
* Initial conditions:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing payload_field
* containing type
* indicating 'encrypted'
* and containing data
* } then {
* the IUT discards the message
* }
* }
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_09_04_BO
testcase TC_SEC_ITSS_RCV_DENM_09_04_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GnNonSecuredPacket v_gnNonSecuredPacket;
var octetstring v_gnPayload;
var template (value) SecuredMessage v_securedMessage;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB); // Use NodeB
var template (value) SituationContainer v_situation := m_situation(CauseCodeType_vehicleBreakdown_, VehicleBreakdownSubCauseCode_unavailable_);
// Test adapter configuration
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
16282
16283
16284
16285
16286
16287
16288
16289
16290
16291
16292
16293
16294
16295
16296
16297
16298
16299
16300
16301
16302
16303
16304
16305
16306
16307
16308
16309
16310
16311
16312
16313
16314
16315
16316
16317
16318
16319
16320
16321
16322
16323
16324
// Test Body
v_gnNonSecuredPacket := valueof(
m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
vc_localSeqNumber,
f_getGeoBroadcastArea(
c_area1 // Select area1 (see ETSI TS 102 871-2 Clause 4.2 Configuration 1)
)));
// Add the DENM payload
v_gnNonSecuredPacket.payload := valueof(
f_adaptPayload_m(
bit2oct(
encvalue(
m_denmReq(
m_denmPdu(
m_denm(
m_denmMgmtCon(
m_tsActionId
),
v_situation,
m_denmLocation_zeroDelta
)))))));
// Encode it
v_gnPayload := bit2oct(
encvalue(
v_gnNonSecuredPacket
)
);
f_buildGnSecuredDenm(
v_securedMessage,
m_payload_encrypted(
v_gnPayload
),
e_certificate_digest_with_sha256,
valueof(m_threeDLocation(
v_longPosVectorNodeB.latitude,
v_longPosVectorNodeB.longitude,
'0000'O
))
);
v_securedGnPdu := valueof(m_geoNwSecPdu(v_gnNonSecuredPacket, v_securedMessage));
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(v_securedGnPdu));
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
} // End of 'for' statement
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_09_04_BO
* @desc Check that IUT discards the Secured DENM containing payload of type 'signed_external'
* Initial conditions:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing payload_field
* containing type
* indicating 'signed_external'
* and containing data
* indicating length > 0
* } then {
* the IUT discards the message
* }
* }
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_09_05_BO
testcase TC_SEC_ITSS_RCV_DENM_09_05_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GnNonSecuredPacket v_gnNonSecuredPacket;
var octetstring v_gnPayload;
var template (value) SecuredMessage v_securedMessage;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB); // Use NodeB
var template (value) SituationContainer v_situation := m_situation(CauseCodeType_vehicleBreakdown_, VehicleBreakdownSubCauseCode_unavailable_);
// Test adapter configuration
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
16399
16400
16401
16402
16403
16404
16405
16406
16407
16408
16409
16410
16411
16412
16413
16414
16415
16416
16417
16418
16419
16420
16421
16422
16423
16424
16425
16426
16427
16428
16429
16430
16431
16432
16433
16434
16435
16436
16437
16438
16439
16440
16441
// Test Body
v_gnNonSecuredPacket := valueof(
m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
vc_localSeqNumber,
f_getGeoBroadcastArea(
c_area1 // Select area1 (see ETSI TS 102 871-2 Clause 4.2 Configuration 1)
)));
// Add the DENM payload
v_gnNonSecuredPacket.payload := valueof(
f_adaptPayload_m(
bit2oct(
encvalue(
m_denmReq(
m_denmPdu(
m_denm(
m_denmMgmtCon(
m_tsActionId
),
v_situation,
m_denmLocation_zeroDelta
)))))));
// Encode it
v_gnPayload := bit2oct(
encvalue(
v_gnNonSecuredPacket
)
);
f_buildGnSecuredDenm(
v_securedMessage,
m_payload_signed_external(
v_gnPayload
),
e_certificate_digest_with_sha256,
valueof(m_threeDLocation(
v_longPosVectorNodeB.latitude,
v_longPosVectorNodeB.longitude,
'0000'O
))
);
v_securedGnPdu := valueof(m_geoNwSecPdu(v_gnNonSecuredPacket, v_securedMessage));
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(v_securedGnPdu));
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
} // End of 'for' statement
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
}
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_09_05_BO
* @desc Check that IUT discards the Secured DENM containing exactly one non-empty payload of type 'signed_and_encrypted'
* Initial conditions:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing payload_field
* containing type
* indicating 'signed_and_encrypted'
* and containing data
* indicating length > 0
* } then {
* the IUT discards the message
* }
* }
* </pre>
*
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_09_06_BO
testcase TC_SEC_ITSS_RCV_DENM_09_06_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GnNonSecuredPacket v_gnNonSecuredPacket;
var octetstring v_gnPayload;
var template (value) SecuredMessage v_securedMessage;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB); // Use NodeB
var template (value) SituationContainer v_situation := m_situation(CauseCodeType_vehicleBreakdown_, VehicleBreakdownSubCauseCode_unavailable_);
// Test adapter configuration
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
16516
16517
16518
16519
16520
16521
16522
16523
16524
16525
16526
16527
16528
16529
16530
16531
16532
16533
16534
16535
16536
16537
16538
16539
16540
16541
16542
16543
16544
16545
16546
16547
16548
16549
16550
16551
16552
16553
16554
16555
16556
16557
16558
// Test Body
v_gnNonSecuredPacket := valueof(
m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
vc_localSeqNumber,
f_getGeoBroadcastArea(
c_area1 // Select area1 (see ETSI TS 102 871-2 Clause 4.2 Configuration 1)
)));
// Add the DENM payload
v_gnNonSecuredPacket.payload := valueof(
f_adaptPayload_m(
bit2oct(
encvalue(
m_denmReq(
m_denmPdu(
m_denm(
m_denmMgmtCon(
m_tsActionId
),
v_situation,
m_denmLocation_zeroDelta
)))))));
// Encode it
v_gnPayload := bit2oct(
encvalue(
v_gnNonSecuredPacket
)
);
f_buildGnSecuredDenm(
v_securedMessage,
m_payload_signed_and_encrypted(
v_gnPayload
),
e_certificate_digest_with_sha256,
valueof(m_threeDLocation(
v_longPosVectorNodeB.latitude,
v_longPosVectorNodeB.longitude,
'0000'O
))
);
v_securedGnPdu := valueof(m_geoNwSecPdu(v_gnNonSecuredPacket, v_securedMessage));
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(v_securedGnPdu));
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
} // End of 'for' statement
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_09_06_BO
* @desc Check that IUT discards the Secured DENM if the message does not contain the trailer field of type signature
* Expected behavior:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing trailer_fields
* not containing any instance of type TrailerField
* containing type
* indicating 'signature'
* } then {
* the IUT discards the message
* }
* }
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_10_01_BO
testcase TC_SEC_ITSS_RCV_DENM_10_01_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
// Test Body
v_securedGnPdu := f_sendSecuredDenm_Bo(cc_taCert_A, -, 0);
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
}
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_10_01_BO
* @desc Check that IUT discards the Secured DENM containing more than one instance of TrailerField of type 'signature'
* Expected behavior:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing trailer_fields[0].type
* containing type
* indicating 'signature'
* and containing trailer_fields[1].type
* containing type
* indicating 'signature'
* } then {
* the IUT discards the message
* }
* }
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_10_02_BO
testcase TC_SEC_ITSS_RCV_DENM_10_02_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
// Test Body
v_securedGnPdu := f_sendSecuredDenm_Bo(cc_taCert_A, -, 2);
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
}
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_10_02_BO
* @desc Check that the IUT discards Secured DENM containing signature that is not verified using the verification key from the certificate contained in the message's signer info
* Expected behavior:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing header_fields ['signer_info']
* containing certificate (CERT_TS_A_AT)
* containing subject_attributes['verification key'] (KEY)
* and containing trailer_fields[0]
* containing type
* indicating 'signature'
* and containing signature
* NOT verifiable using KEY
* } then {
* the IUT discards the message
* }
* }
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_11_01_BO
testcase TC_SEC_ITSS_RCV_DENM_11_01_BO() runs on ItsGeoNetworking system ItsSecSystem {
var integer i;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
// Test Body
v_securedGnPdu := f_sendSecuredDenm_Bo(
cc_taCert_A,
-,
1,
-,
e_certificate
);
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
}
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
}
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_11_01_BO
/**
* @desc Check that IUT discards the Secured DENM if the message contains trailer field of type 'signature' with reserved public key algorythms
* <pre>
* Pics Selection: PICS_GN_SECURITY
* Config Id: CF01
* Expected behavior:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing trailer_fields
* containing an instance of type TrailerField
* containing type
* indicating 'signature'
* and containing signature.algorithm
* indicating X_RESERVED_PK_ALGORYTHM
* } then {
* the IUT discards the message
* }
* }
* </pre>
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_11_02_BO
16824
16825
16826
16827
16828
16829
16830
16831
16832
16833
16834
16835
16836
16837
16838
16839
16840
16841
16842
16843
16844
16845
16846
16847
16848
16849
16850
16851
16852
16853
16854
16855
16856
*/
testcase TC_SEC_ITSS_RCV_DENM_11_02_BO() runs on ItsGeoNetworking system ItsSecSystem {
// Local variables
var integer i;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
// Test control
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
f_cf01Up();
// Test adapter configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
// Test Body
v_securedGnPdu := f_sendSecuredDenm_Bo(
cc_taCert_A,
-,
3
);
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
}
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
}
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_11_02_BO
/**
* @desc Check that IUT discards a Secured DENM if the signer certificate of the message contains the subject type 'enrolment_credential'
* <pre>
* Pics Selection: PICS_GN_SECURITY
* Config Id: CF01
* Expected behavior:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing header_fields['signer_info']
* containing signer
* containing type
* indicating 'certificate'
* containing certificate (CERT_TS_EC_A)
* containing subject_info.subject_type
* indicating 'enrolment_credentials'
* } then {
* the IUT discards the message
* }
* }
* </pre>
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_12_01_BO
*/
testcase TC_SEC_ITSS_RCV_DENM_12_01_BO() runs on ItsGeoNetworking system ItsSecSystem {
16903
16904
16905
16906
16907
16908
16909
16910
16911
16912
16913
16914
16915
16916
16917
16918
16919
16920
16921
16922
16923
16924
16925
16926
16927
16928
16929
16930
16931
16932
16933
16934
16935
// Local variables
var integer i;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
// Test control
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
f_cf01Up();
// Test adapter configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);
// Test Body
v_securedGnPdu := f_sendSecuredDenm(
cc_taCert_EC,
{
m_header_field_generation_time(1000 * f_getCurrentTime()), // In us
m_header_field_its_aid_DENM
},
e_certificate
);
f_sleep(PX_TNOAC);
v_sentRawPayload := f_adaptPayloadForUtInd_m(v_securedGnPdu.gnPacket.packet.payload);
for (i := 0; i < lengthof(vc_utInds) and not match(vc_utInds[i].rawPayload, v_sentRawPayload); i := i + 1) {
16937
16938
16939
16940
16941
16942
16943
16944
16945
16946
16947
16948
16949
16950
16951
16952
16953
16954
16955
16956
16957
16958
16959
16960
16961
16962
16963
}
if (i < lengthof(vc_utInds)) {
log("*** " & testcasename() & ": FAIL: GN was transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GN was not transmitted to upper layer ***");
f_selfOrClientSyncAndVerdictTestBody(c_tbDone, e_success);
}
// Postamble
f_poNeighbour();
f_cf01Down();
} // End of testcase TC_SEC_ITSS_RCV_DENM_12_01_BO
/**
* @desc Check that IUT discards a Secured DENM if the signer certificate of the message contains the subject type "authorization_authority"
* <pre>
* Pics Selection: PICS_GN_SECURITY
* Config Id: CF01
* Expected behavior:
* with {
* the IUT being in the 'authorized' state
* and the IUT current time is inside the time validity period of CERT_TS_A_AT
* }
* ensure that {
* when {
* the IUT is receiving a SecuredMessage (MSG_SEC_RCV_DENM_A)
* containing header_fields['signer_info']
* containing signer
* containing type
* indicating 'certificate'
* containing certificate (CERT_TS_A_AA)
* containing subject_info.subject_type
* indicating 'authorization_authority'
* } then {
* the IUT discards the message
* }
* }
* </pre>
* @see ETSI TS 103 096-2 v1.3.2 TP_SEC_ITSS_RCV_DENM_12_02_BO
16979
16980
16981
16982
16983
16984
16985
16986
16987
16988
16989
16990
16991
16992
16993
16994
16995
16996
16997
16998
16999
17000
*/
testcase TC_SEC_ITSS_RCV_DENM_12_02_BO() runs on ItsGeoNetworking system ItsSecSystem {
// Local variables
var integer i;
var GeoNetworkingPdu v_securedGnPdu;
var GnRawPayload v_sentRawPayload;
// Test control
if (not(PICS_GN_SECURITY)) {
log("*** " & testcasename() & ":ERROR: 'PICS_GN_SECURITY' required for executing the TC ***");
stop;
}
// Test component configuration
f_cf01Up();
// Test adapter configuration
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success);