lynxis lazus has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42824?usp=email )

Change subject: stp: tcap-loadshare: add TC_tcap_loadshare_m3ua_to_ipa_udts
......................................................................

stp: tcap-loadshare: add TC_tcap_loadshare_m3ua_to_ipa_udts

If a TCAP message arrives which is:
* not a TCAP Begin or Abort (e.g. a TCAP Continue)
* not in the TCAP session cache/tracking
* not have a dTID for a registered TCAP Add Range

The tcap load-share will reject this message with a UDTS

Related: SYS#8061
Change-Id: I181b25aedfd70d156c08197d361560b6d055e65a
---
M stp/STP_Tests_TCAP.ttcn
1 file changed, 50 insertions(+), 0 deletions(-)

Approvals:
  daniel: Looks good to me, but someone else must approve
  Jenkins Builder: Verified
  pespin: Looks good to me, approved




diff --git a/stp/STP_Tests_TCAP.ttcn b/stp/STP_Tests_TCAP.ttcn
index d7c45dc..d443690 100644
--- a/stp/STP_Tests_TCAP.ttcn
+++ b/stp/STP_Tests_TCAP.ttcn
@@ -841,6 +841,55 @@
        setverdict(pass);
 }

+/* Test UDTS rejection with TCAP load-sharing
+ * If a TCAP message arrives which is:
+ * * not a TCAP Begin or Abort (e.g. a TCAP Continue)
+ * * not in the TCAP session cache/tracking
+ * * not have a dTID for a registered TCAP Add Range
+ *  The tcap load-share will reject this message with a UDTS
+ */
+testcase TC_tcap_loadshare_m3ua_to_ipa_udts() runs on TCAP_CT {
+       var template (value) IPA_EXT_TCAP_ROUTING_Message tcap_rt_msg;
+       var template (value) TCMessage tcap_msg;
+       var Misc_Helpers.ro_charstring tcap_asps := { "asp-m3ua-loadshare-0-0",
+                                                     "asp-m3ua-loadshare-0-1",
+                                                     "asp-ipa-loadshare-0-0",
+                                                     "asp-ipa-loadshare-0-1" };
+       var TCAP_CT_Configurations tcap_configs := 
tcap_build_configs(tcap_asps);
+
+       f_init_tcap(tcap_configs);
+       f_tcap_loadshare_register(2, 0, 99, 3, 100, 199);
+
+       /* Transmit a TCAP Continue outside of the range which should rejected 
with a UDTS */
+       tcap_msg := ts_TCAP_Continue(int2oct(198, 4), int2oct(202, 4));
+       f_asp_tx_tcap(tcap_msg, 0);
+
+       /* expect a UDTS */
+       var template (present) TCAP_N_NOTICE_ind exp_sccp_utds :=
+               tr_TCAP_N_NOTICE_ind(g_tcap[0].sccp_addr_own,
+                                    g_tcap[0].sccp_addr_peer,
+                                    3, /* Subsystem failure */
+                                    tcap_msg);
+       timer T := 5.0;
+       T.start;
+       alt {
+       [] SCCP_TCAP[0].receive(exp_sccp_utds) {
+               log("Received UTDS via TCAP[0] ASP");
+               }
+       [] SCCP_TCAP[1].receive(exp_sccp_utds) {
+               log("Received UTDS via TCAP[1] ASP");
+               }
+       [] T.timeout {
+               setverdict(fail, __SCOPE__, "(): Timeout waiting for SCCP UTDS 
/ TCAP message");
+               Misc_Helpers.f_shutdown(__BFILE__, __LINE__);
+               }
+       }
+
+       setverdict(pass);
+}
+
+
+
 /* TODO: test TCAP Abort message is used.
  * TODO: test TCAP Begin+End message is used.
  * TODO: test TCAP GlobalTitles ISD
@@ -863,6 +912,7 @@
        execute( TC_tcap_loadshare_ipa_tcap_range_success_pc_ssn2() );
        execute( TC_tcap_loadshare_ipa_tcap_range_fail_pc_ssn_overlap() );
        execute( TC_tcap_loadshare_ipa_tcap_norange() );
+       execute( TC_tcap_loadshare_m3ua_to_ipa_udts() );
 }



--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/42824?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: I181b25aedfd70d156c08197d361560b6d055e65a
Gerrit-Change-Number: 42824
Gerrit-PatchSet: 2
Gerrit-Owner: lynxis lazus <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <[email protected]>
Gerrit-Reviewer: laforge <[email protected]>
Gerrit-Reviewer: lynxis lazus <[email protected]>
Gerrit-Reviewer: pespin <[email protected]>

Reply via email to