Attention is currently required from: jolly.
Hello Jenkins Builder, dexter, osmith,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43372?usp=email
to look at the new patch set (#7).
The following approvals got outdated and were removed:
Verified+1 by Jenkins Builder
The change is no longer submittable: Verified is unsatisfied now.
Change subject: IPAd: A test to verify proper session cancellation by eUICC
......................................................................
IPAd: A test to verify proper session cancellation by eUICC
When an error occurs (PepareDownloadRequest is rejected in this case),
expect the IPAd to cancel the session towards the eUICC and also towards
the eIM.
Related: SYS#8101
Change-Id: I9776cd88d332b74c1f627cc284d214e0be251b0a
---
M ipad/IPAd_Tests.ttcn
M library/euicc/RSPDefinitions_Templates.ttcn
M library/euicc/RSPDefinitions_Types.ttcn
3 files changed, 90 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/72/43372/7
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43372?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I9776cd88d332b74c1f627cc284d214e0be251b0a
Gerrit-Change-Number: 43372
Gerrit-PatchSet: 7
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: jolly <andreas(a)eversberg.eu>
jolly has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43275?usp=email )
(
4 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.
)Change subject: IPAd: Add test to verify the correct setting of Device Capabilites
......................................................................
IPAd: Add test to verify the correct setting of Device Capabilites
Specify Device Capabilities via command line option and expect them in
the TERMINAL CAPABILIES message towards eUICC.
Related: SYS#8101
Change-Id: I72d2235d3a9f287ea2af2fae3a83ffe6e54fec44
---
M ipad/IPAd_Tests.ttcn
1 file changed, 25 insertions(+), 3 deletions(-)
Approvals:
laforge: Looks good to me, but someone else must approve
jolly: Looks good to me, approved
osmith: Looks good to me, but someone else must approve
Jenkins Builder: Verified
diff --git a/ipad/IPAd_Tests.ttcn b/ipad/IPAd_Tests.ttcn
index 2ba50e3..f591495 100644
--- a/ipad/IPAd_Tests.ttcn
+++ b/ipad/IPAd_Tests.ttcn
@@ -317,8 +317,10 @@
/* Handle the opening of logical channel 1 and the selection of the ISD-R */
private function f_es10x_init(boolean iot := true,
- boolean eim_init := true) runs on IPAd_ConnHdlr {
+ boolean eim_init := true,
+ OCT1 dev_capa := '00'O) runs on IPAd_ConnHdlr {
var charstring eim_fqdn := mp_esipa_ip & ":" & int2str(mp_esipa_port);
+ var octetstring term_capa;
/* If we decide not to use vpcd, then we must not initialize anything here */
if (mp_use_vpcd == false) {
@@ -329,10 +331,12 @@
* (For RSP Device see also: 3GPP TS 102.221, section 11.1.19.2.4 and SGP.22, section 3.4.2)
* (For IoT Device see also: SGP.32, section 3.8.2) */
if (iot) {
- f_vpcd_exp(tr_VPCD_DATA('80AA000008A906830107840101'O));
+ term_capa := '80AA000008A906830107840101'O;
} else {
- f_vpcd_exp(tr_VPCD_DATA('80AA000005A903830107'O));
+ term_capa := '80AA000005A903830107'O;
}
+ term_capa[9] := term_capa[9] or4b dev_capa[0];
+ f_vpcd_exp(tr_VPCD_DATA(term_capa));
f_vpcd_send(ts_VPCD_DATA('9000'O));
/* Expect a MANAGE CHANNEL request that opens logical channel 1 */
@@ -936,6 +940,23 @@
setverdict(pass);
}
+/* A testcase to verify if the given device capabilities are set (the lower 3 bits are always set). */
+private function f_TC_set_device_capabilities(charstring id) runs on IPAd_ConnHdlr {
+ f_exec_ipad("-D 0xF1");
+ f_es10x_init(dev_capa := 'F1'O);
+ f_stop_ipad();
+ setverdict(pass);
+}
+testcase TC_set_device_capabilities() runs on MTC_CT {
+ var charstring id := testcasename();
+ var IPAd_ConnHdlrPars pars := f_init_pars();
+ var IPAd_ConnHdlr vc_conn;
+ f_init(id);
+ vc_conn := f_start_handler(refers(f_TC_set_device_capabilities), pars);
+ vc_conn.done;
+ setverdict(pass);
+}
+
control {
execute ( TC_proc_indirect_prfle_dwnld() );
execute ( TC_proc_euicc_pkg_dwnld_exec() );
@@ -948,6 +969,7 @@
execute ( TC_func_dis_emerg_prfle() );
execute ( TC_func_get_conn_params() );
execute ( TC_func_get_conn_params_error() );
+ execute ( TC_set_device_capabilities() );
}
}
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43275?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I72d2235d3a9f287ea2af2fae3a83ffe6e54fec44
Gerrit-Change-Number: 43275
Gerrit-PatchSet: 7
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
jolly has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43269?usp=email )
(
6 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.
)Change subject: IPAd: Add test for function ES10b.ExecuteFallbackMechanism
......................................................................
IPAd: Add test for function ES10b.ExecuteFallbackMechanism
Related: SYS#8101
Change-Id: I66745a24e227ac5c638f6dc5228f7f3fbe2deea1
---
M ipad/IPAd_Tests.ttcn
M library/euicc/SGP32Definitions_Templates.ttcn
M library/euicc/SGP32Definitions_Types.ttcn
3 files changed, 70 insertions(+), 8 deletions(-)
Approvals:
dexter: Looks good to me, approved
osmith: Looks good to me, but someone else must approve
Jenkins Builder: Verified
diff --git a/ipad/IPAd_Tests.ttcn b/ipad/IPAd_Tests.ttcn
index d93297b..a126dd5 100644
--- a/ipad/IPAd_Tests.ttcn
+++ b/ipad/IPAd_Tests.ttcn
@@ -297,23 +297,27 @@
/* Expect a pre-defined request (optional), and send a pre-defined response. This is a shortcut that only works in case
* the response does not depend on the request. */
-private function f_vpcd_transceive(octetstring response, octetstring expected_request := ''O) runs on IPAd_ConnHdlr {
+private function f_vpcd_transceive(octetstring response,
+ octetstring expected_request := ''O) runs on IPAd_ConnHdlr return octetstring {
+ var octetstring request;
/* In case we do not use the VPCD (because we have some other kind of eUICC emulation or even a real card
* present), we just skip. */
if (mp_use_vpcd == false) {
- return;
+ return ''O;
}
- f_vpcd_store_data(expected_request);
+ request := f_vpcd_store_data(expected_request);
f_vpcd_store_data_final_ack(lengthof(response));
if (response != ''O) {
f_vpcd_get_response_multi(response);
}
+ return request;
}
/* Handle the opening of logical channel 1 and the selection of the ISD-R */
-private function f_es10x_init(boolean iot := true) runs on IPAd_ConnHdlr {
+private function f_es10x_init(boolean iot := true,
+ boolean eim_init := true) runs on IPAd_ConnHdlr {
var charstring eim_fqdn := mp_esipa_ip & ":" & int2str(mp_esipa_port);
/* If we decide not to use vpcd, then we must not initialize anything here */
@@ -342,11 +346,14 @@
/* Expect the IPAd to query the eID from the eUICC */
f_vpcd_transceive(enc_GetEuiccDataResponse(valueof(ts_getEuiccDataResponse)), 'BF3E035C015A'O);
- /* Expect the IPAd to query the eIM configuration data from the eUICC */
- f_vpcd_transceive(enc_GetEimConfigurationDataResponse(valueof(ts_getEimConfigurationDataResponse(eim_fqdn))), 'BF5500'O);
+ /* Not all tests expect IPAd to query eUICC data and notfications before talking to eIM. */
+ if (eim_init) {
+ /* Expect the IPAd to query the eIM configuration data from the eUICC */
+ f_vpcd_transceive(enc_GetEimConfigurationDataResponse(valueof(ts_getEimConfigurationDataResponse(eim_fqdn))), 'BF5500'O);
- /* Expect the IPAd to query the eUICC for pending notifications, we respond with an empty list */
- f_vpcd_transceive(enc_RetrieveNotificationsListResponse(valueof(ts_retrieveNotificationsListResponse_empty)), 'BF2B00'O);
+ /* Expect the IPAd to query the eUICC for pending notifications, we respond with an empty list */
+ f_vpcd_transceive(enc_RetrieveNotificationsListResponse(valueof(ts_retrieveNotificationsListResponse_empty)), 'BF2B00'O);
+ }
}
/* Handle the closing of logical channel 1 */
@@ -761,12 +768,39 @@
setverdict(pass);
}
+/* A testcase to tigger the 'execute fallback mechanism' via ES10b interface */
+private function f_TC_func_exec_fallback_mech(charstring id) runs on IPAd_ConnHdlr {
+ f_exec_ipad("execute-fallback-mechanism");
+ f_es10x_init(eim_init := false);
+
+ var octetstring asn := f_vpcd_transceive(enc_ExecuteFallbackMechanismResponse(valueof(ts_executeFallbackMechanismResponse(0))), ''O);
+ var ExecuteFallbackMechanismRequest req := dec_ExecuteFallbackMechanismRequest(asn);
+ if (not match(req, tr_executeFallbackMechanismRequest())) {
+ setverdict(fail, "Unexpected ES10b request: ", req);
+ }
+
+ f_es10x_close();
+ f_stop_ipad();
+
+ setverdict(pass);
+}
+testcase TC_func_exec_fallback_mech() runs on MTC_CT {
+ var charstring id := testcasename();
+ var IPAd_ConnHdlrPars pars := f_init_pars();
+ var IPAd_ConnHdlr vc_conn;
+ f_init(id);
+ vc_conn := f_start_handler(refers(f_TC_func_exec_fallback_mech), pars);
+ vc_conn.done;
+ setverdict(pass);
+}
+
control {
execute ( TC_proc_indirect_prfle_dwnld() );
execute ( TC_proc_euicc_pkg_dwnld_exec() );
execute ( TC_proc_euicc_pkg_dwnld_exec_rollback() );
execute ( TC_proc_euicc_data_req() );
execute ( TC_get_eim_pkg_req_rej() );
+ execute ( TC_func_exec_fallback_mech() );
}
}
diff --git a/library/euicc/SGP32Definitions_Templates.ttcn b/library/euicc/SGP32Definitions_Templates.ttcn
index 7bd36bd..a3e5914 100644
--- a/library/euicc/SGP32Definitions_Templates.ttcn
+++ b/library/euicc/SGP32Definitions_Templates.ttcn
@@ -1631,6 +1631,24 @@
}
}
+/* GSMA SGP.32, section 5.9.20 */
+template (present) ExecuteFallbackMechanismRequest
+tr_executeFallbackMechanismRequest(template (present) boolean refreshFlag := ?) := {
+ refreshFlag := refreshFlag
+}
+template (value) ExecuteFallbackMechanismRequest
+ts_executeFallbackMechanismRequest(template (value) boolean refreshFlag := false) := {
+ refreshFlag := refreshFlag
+}
+template (present) ExecuteFallbackMechanismResponse
+tr_executeFallbackMechanismResponse(template (present) integer errorCode := ?) := {
+ executeFallbackMechanismResult := errorCode
+}
+template (value) ExecuteFallbackMechanismResponse
+ts_executeFallbackMechanismResponse(template (value) integer errorCode := 127) := {
+ executeFallbackMechanismResult := errorCode
+}
+
/* GSMA SGP.32, section 5.9.4 */
template (present) AddInitialEimResponse
tr_addInitialEimResponse := {
diff --git a/library/euicc/SGP32Definitions_Types.ttcn b/library/euicc/SGP32Definitions_Types.ttcn
index c344823..4dc53f9 100644
--- a/library/euicc/SGP32Definitions_Types.ttcn
+++ b/library/euicc/SGP32Definitions_Types.ttcn
@@ -48,4 +48,14 @@
external function enc_ProfileRollbackResponse(in ProfileRollbackResponse msg) return octetstring
with { extension "prototype(convert) encode(BER:BER_ENCODE_DER)" };
+external function dec_ExecuteFallbackMechanismRequest(in octetstring stream) return ExecuteFallbackMechanismRequest
+with { extension "prototype(convert) decode(BER:BER_ACCEPT_ALL)" };
+external function enc_ExecuteFallbackMechanismRequest(in ExecuteFallbackMechanismRequest msg) return octetstring
+with { extension "prototype(convert) encode(BER:BER_ENCODE_DER)" };
+
+external function dec_ExecuteFallbackMechanismResponse(in octetstring stream) return ExecuteFallbackMechanismResponse
+with { extension "prototype(convert) decode(BER:BER_ACCEPT_ALL)" };
+external function enc_ExecuteFallbackMechanismResponse(in ExecuteFallbackMechanismResponse msg) return octetstring
+with { extension "prototype(convert) encode(BER:BER_ENCODE_DER)" };
+
}
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43269?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I66745a24e227ac5c638f6dc5228f7f3fbe2deea1
Gerrit-Change-Number: 43269
Gerrit-PatchSet: 7
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: jolly <andreas(a)eversberg.eu>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>