Change in ...osmo-ttcn3-hacks[master]: sgsn: extend f_routing_area_update() to support Iu

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

lynxis lazus gerrit-no-reply at lists.osmocom.org
Wed Sep 11 10:20:22 UTC 2019


lynxis lazus has submitted this change and it was merged. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/15396 )

Change subject: sgsn: extend f_routing_area_update() to support Iu
......................................................................

sgsn: extend f_routing_area_update() to support Iu

Allow Iu tests to use f_routing_area_update()

Change-Id: Ic03952a04c00a4fc437ef39c5ee046549c122c8b
---
M sgsn/SGSN_Tests.ttcn
1 file changed, 27 insertions(+), 5 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, approved



diff --git a/sgsn/SGSN_Tests.ttcn b/sgsn/SGSN_Tests.ttcn
index 501bec8..6de9987 100644
--- a/sgsn/SGSN_Tests.ttcn
+++ b/sgsn/SGSN_Tests.ttcn
@@ -2360,22 +2360,44 @@
 	f_cleanup();
 }
 
-private function f_routing_area_update(RoutingAreaIdentificationV ra, integer bssgp := 0) runs on BSSGP_ConnHdlr {
+friend function f_routing_area_update(RoutingAreaIdentificationV ra, integer bssgp := 0) runs on BSSGP_ConnHdlr {
 	var PDU_L3_SGSN_MS l3_mt;
+	var PDU_DTAP_PS_MT mt;
+	var template OCT4 p_tmsi := omit;
 
+	if (is_iu(bssgp)) {
+		p_tmsi := g_pars.p_tmsi;
+	}
 	/* then send RAU */
-	f_send_l3(ts_GMM_RAU_REQ(f_mi_get_lv(), GPRS_UPD_T_RA, g_pars.ra, false, omit, omit), bssgp);
+	f_send_l3(ts_GMM_RAU_REQ(f_mi_get_lv(), GPRS_UPD_T_RA, g_pars.ra, false, omit, omit, p_tmsi), bssgp);
 	alt {
-	[] BSSGP[bssgp].receive(tr_GMM_RAU_ACCEPT) -> value l3_mt {
+	[is_gb(bssgp)] BSSGP[bssgp].receive(tr_GMM_RAU_ACCEPT) -> value l3_mt {
 		f_process_rau_accept(l3_mt.msgs.gprs_mm.routingAreaUpdateAccept, bssgp);
 		f_send_l3(ts_GMM_RAU_COMPL, bssgp);
 		setverdict(pass);
 		}
-	[] BSSGP[bssgp].receive(tr_GMM_RAU_REJECT) {
+	[is_iu(bssgp)] BSSAP.receive(tr_PDU_DTAP_PS_MT(tr_GMM_RAU_ACCEPT)) -> value mt {
+		f_process_rau_accept(mt.dtap.msgs.gprs_mm.routingAreaUpdateAccept, bssgp);
+		f_send_l3(ts_GMM_RAU_COMPL, bssgp);
+		setverdict(pass);
+		}
+
+	[is_gb(bssgp)] BSSGP[bssgp].receive(tr_GMM_RAU_REJECT) {
 		setverdict(fail, "Unexpected RAU Reject");
 		mtc.stop;
 		}
-	[] BSSGP[bssgp].receive { repeat; }
+	[is_iu(bssgp)] BSSAP.receive(tr_PDU_DTAP_PS_MT(tr_GMM_RAU_REJECT)) {
+		setverdict(fail, "Unexpected RAU Reject");
+		mtc.stop;
+		}
+
+	[is_iu(bssgp)] BSSAP.receive(tr_RANAP_SecurityModeCmd(uia_algs := ?, uia_key := oct2bit(g_pars.vec.ik),
+								key_sts := ?)) {
+			var IntegrityProtectionAlgorithm uia_chosen := 0; /* 0 = standard_UMTS_integrity_algorithm_UIA1 */
+			BSSAP.send(ts_RANAP_SecurityModeComplete(uia_chosen));
+		}
+	[is_gb(bssgp)] BSSGP[bssgp].receive { repeat; }
+	[is_iu(bssgp)] BSSAP.receive { repeat; }
 	}
 }
 

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/15396
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ic03952a04c00a4fc437ef39c5ee046549c122c8b
Gerrit-Change-Number: 15396
Gerrit-PatchSet: 7
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: lynxis lazus <lynxis at fe80.eu>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190911/d1ba8d71/attachment.htm>


More information about the gerrit-log mailing list