summaryrefslogtreecommitdiffstats
path: root/msc/MSC_Tests.ttcn
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2020-08-19 13:49:05 +0000
committerlaforge <laforge@osmocom.org>2020-08-25 11:41:25 +0000
commit14d0b13f5f33bfb8c2ab7e05fe10316e7bf11a93 (patch)
tree6dbda66fdf47cde72e63cbeaa188f7c111ccbbb3 /msc/MSC_Tests.ttcn
parent13737fbb5dbd6a04676b56a4c3de1938baac9124 (diff)
msc: add TC_paging_response_[it]msi_unknown
These uncover crashes of current osmo-msc master, when a Paging Response contains an unknown mobile identity. Hence run them last. The crash is fixed by osmo-msc Ia2c8fa745cfab17ed7114d433f625ddc02ae7b11 Related: OS#4724 Related: Ia2c8fa745cfab17ed7114d433f625ddc02ae7b11 (osmo-msc) Change-Id: I40496bbccbbd9c496cfa57df49e26f124a2b1554
Diffstat (limited to 'msc/MSC_Tests.ttcn')
-rw-r--r--msc/MSC_Tests.ttcn46
1 files changed, 46 insertions, 0 deletions
diff --git a/msc/MSC_Tests.ttcn b/msc/MSC_Tests.ttcn
index ee4ea05..2a9b23a 100644
--- a/msc/MSC_Tests.ttcn
+++ b/msc/MSC_Tests.ttcn
@@ -709,6 +709,50 @@ testcase TC_cmserv_tmsi_unknown() runs on MTC_CT {
vc_conn.done;
}
+/* Send Paging Response for IMSI that has never performed LU before */
+friend function f_tc_paging_response_imsi_unknown(charstring id, BSC_ConnHdlrPars pars)
+runs on BSC_ConnHdlr {
+ f_init_handler(pars);
+
+ var MobileIdentityLV mi := valueof(ts_MI_IMSI_LV(g_pars.imsi));
+ var BSSMAP_IE_CellIdentifier cell_id := valueof(ts_CellId_CGI('262'H, '42'H, 23, 42));
+ var PDU_ML3_MS_NW l3_info := valueof(ts_PAG_RESP(mi));
+
+ /* Send BSSAP_Conn_Req with COMPL L3 INFO to MSC */
+ f_cl3_or_initial_ue(l3_info);
+
+ /* The Paging Response gets rejected by a direct Clear Command */
+ f_expect_clear();
+}
+testcase TC_paging_response_imsi_unknown() runs on MTC_CT {
+ var BSC_ConnHdlr vc_conn;
+ f_init();
+ vc_conn := f_start_handler(refers(f_tc_paging_response_imsi_unknown), 58, verify_cell_id := false);
+ vc_conn.done;
+}
+
+/* Send Paging Response for TMSI that has never performed LU before */
+friend function f_tc_paging_response_tmsi_unknown(charstring id, BSC_ConnHdlrPars pars)
+runs on BSC_ConnHdlr {
+ f_init_handler(pars);
+
+ var MobileIdentityLV mi := valueof(ts_MI_TMSI_LV('59111111'O));
+ var BSSMAP_IE_CellIdentifier cell_id := valueof(ts_CellId_CGI('262'H, '42'H, 23, 42));
+ var PDU_ML3_MS_NW l3_info := valueof(ts_PAG_RESP(mi));
+
+ /* Send BSSAP_Conn_Req with COMPL L3 INFO to MSC */
+ f_cl3_or_initial_ue(l3_info);
+
+ /* The Paging Response gets rejected by a direct Clear Command */
+ f_expect_clear();
+}
+testcase TC_paging_response_tmsi_unknown() runs on MTC_CT {
+ var BSC_ConnHdlr vc_conn;
+ f_init();
+ vc_conn := f_start_handler(refers(f_tc_paging_response_tmsi_unknown), 59, verify_cell_id := false);
+ vc_conn.done;
+}
+
friend function f_tc_lu_and_mo_call(charstring id, BSC_ConnHdlrPars pars) runs on BSC_ConnHdlr {
f_init_handler(pars);
@@ -6329,6 +6373,8 @@ control {
execute( TC_invalid_mgcp_crash() );
execute( TC_mm_id_resp_no_identity() );
execute( TC_lu_and_expire_while_paging() );
+ execute( TC_paging_response_imsi_unknown() );
+ execute( TC_paging_response_tmsi_unknown() );
}