summaryrefslogtreecommitdiffstats
path: root/msc
AgeCommit message (Collapse)AuthorFilesLines
2018-09-26bsc: inter-BSC HO: add TC_ho_out_of_this_bsc, TC_ho_into_this_bscNeels Hofmeyr1-6/+0
Add f_gen_handover_req() like f_gen_ass_req(), to match AoIP or SCCPlite requirements. For incoming HO, MSC_ConnHdlr needs to know the SCCP addresses to expect the incoming SCCP Connection from MSC to BSC. Add 'handover' section to TestHdlrParams, and pass in the addresses from test_CT via that. In osmo-bsc.cfg, add a remote neighbor config, so that the VTY command 'handover any to arfcn 123 bsic any' can trigger an outgoing inter-BSC HO. Add various BSSMAP handover templates to BSSMAP_Templates.ttcn. Add RR Ho Command template to L3_Templates.ttcn. Move ts_BSSAP_Conn_Req() from msc/BSC_ConnectionHandler.ttcn to library/BSSMAP_Emulation.ttcn, so we can also model an SCCP Connection Request in BSC_Tests.ttcn (this time from MSC to BSC). Add the two new tests to bsc/expected-results.xml. Related: OS#2283 Change-Id: Id22852d4be7f127d827e7a8beeec55db27c07f03
2018-09-25ensure well-formed config filesHarald Welte2-60/+60
Change-Id: I09eedd3cda993b9fabfdcf7caf0b3a050eaad9b1
2018-09-25MSC_Tests: Reply to Classmark Req in TC_lu_imsi_auth_tmsi_encr_3_1_no_cmDaniel Willmann1-0/+4
After osmo-msc I73c7cb6a86624695bd9c0f59abb72e2fdc655131, osmo-msc sends a BSSMAP Classmark Request if encounters a missing Classmark, which is the case during LU when A5/3 is enabled. Fix this test by answering the Classmark Request, if any. Change-Id: I25578c050b7e105ed71b064891d4cd418ee30fcf
2018-09-06update expected resultsNeels Hofmeyr1-15/+9
Change-Id: I32c29e62ca317937db771f8fb1540bb1fe9da2ab
2018-08-21MSC_Tests: Reliably pass TC_cr_before_resetDaniel Willmann1-0/+2
I was able to reproduce the sporadic cr_before_reset failures by running both osmo-{stp,msc}-master with --cpus 0.1. In that case the first test run would fail for me because no BSSMAP RESET ACK was seen. Sleeping some seconds before sending the messages will make sure all components are connected. Note: TC_cr_before_reset is the first test executed in control so this seems to be why it sometimes fails in jenkins. Change-Id: Id745470231950e0a284f8c231246d3719f7617cc
2018-08-14fix expectations of TC_lu_imsi_reject and TC_lu_imsi_timeout_gsupStefan Sperling1-2/+0
These tests were expecting two ClearCommands, but the MSC will only send one. Remove redundant calls to f_expect_clear() outside of the alt step. The expected ClearCommand is received inside the alt step. Change-Id: I77f189d9050a06fe6eac457312285cf173c842d5
2018-08-07move USSD_Helpers.ttcn to libraryHarald Welte2-79/+1
We want to use those also from the HLR_Tests, not just from MSC_Tests. Change-Id: I22be6c03d85dc6d6a8266b5ebce5d0c69c0551ed
2018-08-07Call f_bssap_start in TC_cr_before_resetDaniel Willmann1-0/+2
This function starts the SCCP component which will relay the BSSAP messages to/from port SCCP_SP_PORT which is connected to BSSAP_DIRECT. Ticket: OS#3286 Change-Id: Icee085d5fe610061c85d7fe7cf62cbccd8cfa556
2018-07-30msc/USSD: introduce TC_lu_and_mo_ussd_mo_releaseVadim Yanitskiy2-0/+99
The idea of this test case is to check the reaction of OsmoMSC on MS-initiated release during an active transaction. In other words, when the network is waiting for some response from a MS, subscriber can press the 'red button' in order to terminate this conversation. It is expected that the MSC would terminate the transaction as on DTAP interface, as on GSUP interface. Change-Id: I7936ed5072ed2ae02f039dc90a1fece1e7f70a70
2018-07-30msc/USSD: add test cases with network-initiaded SS/USSDVadim Yanitskiy2-0/+209
This change introduces two new test cases for network-initiaded USSD notification and network-initiaded USSD request, which are based on the existing SS/USSD related test cases. The idea of TC_lu_and_mt_ussd_notification is to verify that a network-initiaded USSD notification can arrive subscriber in IDLE mode using Paging procedure. The idea of TC_lu_and_mt_ussd_during_mt_call is to verify that a network-initiaded USSD notification can arrive subscriber in DEDICATED mode (in this case during a call) on a separate transaction. Change-Id: I073893c6e11be27e9e36f98f11c1491d0c173985
2018-07-30msc/USSD: expect and reply SS/USSD messages over GSUPVadim Yanitskiy1-40/+81
As we are about to finish the implementation of GSM TS 09.11, OsmoMSC will forward all SS/USSD messages over GSUP to HLR, and will expect responses back from HLR. The SS/USSD payload processing will be out of scope for OsmoMSC itself. Let's modify the existing test cases in order to expect and reply SS/USSD messages over GSUP protocol. Change-Id: I01de73aced6057328a121577a5a83bc2615fb2d4
2018-07-30msc/USSD: introduce common GSUP/DTAP matching functionsVadim Yanitskiy1-0/+42
In order to avoid code duplication in the upcoming test cases, let's introduce a few functions which basically do a GSUP/DTAP message matching within the alternative statement. Change-Id: I846c2d40a7c37afa8647e644673b4df905e3e116
2018-07-27detect VTY TELNET port connection failures (attempt #2)Stefan Sperling1-0/+1
Pass the CTRL_DETECT_CONNECTION_ESTABLISHMENT_RESULT parameter to the TELNET port by default. This allows tests to make progress into an error handling path if they are started while the osmo-* program they want to connect on VTY is not running. Observed with osmo-ggsn tests, where if the one test runs into a VTY connection failure the subsequent test would get stuck forever in a map() call on the VTY TELNET port. Teach the function f_vty_wait_for_prompt() about connection reports by the TELNET module. We may now receive an integer which represents the socket file descriptor for the telnet connection. This case was not handled by the previous change made in commit cb111b21aba1d5881da1a1d3f19754cbd15b3779. As a result, BSC tests started failing with "VTY Timeout for prompt" because the alt-statement in f_vty_wait_for_prompt() would not progress past the integer sitting on the VTY port's receive queue. Change-Id: I56925f93af6c55e93f3f417099db135744da6a40 Related: OS#3149
2018-07-27Revert "detect VTY TELNET port connection failures in TTCN3 tests"Neels Hofmeyr1-1/+0
With this patch, I see all ttcn3-bsc-tests failing with "Verdict: fail reason: VTY Timeout for prompt" This reverts commit cb111b21aba1d5881da1a1d3f19754cbd15b3779. Change-Id: I215d7ab5eee75cf6d3afaac760af64356c943140
2018-07-27detect VTY TELNET port connection failures in TTCN3 testsStefan Sperling1-0/+1
Pass the CTRL_DETECT_CONNECTION_ESTABLISHMENT_RESULT parameter to the TELNET port by default. This allows tests to make progress into an error handling path if they are started while the osmo-* program they want to connect on VTY is not running. Observed with osmo-ggsn tests, where if the one test runs into a VTY connection failure the subsequent test would get stuck forever in a map() call on the VTY TELNET port. Change-Id: I9acf7793d5d68aec6d087cff254a10d8b673dab1 Related: OS#3149
2018-07-26msc: Fix random error of TC_cl3_rnd_payloadDaniel Willmann1-1/+5
The random length for that test could go out of bounds leading to a Dynamic test case error when sending the message. The limiting field here is the lengthIndicator of PDU_BSSAP which includes the length of the PDU_BSSMAP mesageType, cellId as well as the layer3 info IE and lenght indicator additionally to the l3info payload. So maximum length for the payload can only be 240 bytes (if the cell ID is encoded in the longest possible way as BSSMAP_FIELD_LAC_RNC_CI). Change-Id: I7be33e261a11f03a80a6b770b6acf0a4be49b85b
2018-07-24introduce a TTCN3 test suite for SCCPStefan Sperling2-1/+3
This test suite acts as an SCCP server on top of M3UA. SCCP tests are run against the sccp_demo_user program which can be found in libosmo-sccp/examples. This program must be started in client mode: sccp_demo_user -c The SCCP test suite should then work out of the box with the provided SCCP_Tests.cfg file and this additional change to sccp_demo_user default point codes: https://gerrit.osmocom.org/#/c/libosmo-sccp/+/9652/ There is currently only one test, for the libosmo-sccp crash reported as issue OS#2666. The implementation of this test is currently using an ugly workaround due to shortcomings of the M3UA Emulation layer (see source code comments). Whether a better solution is feasible is still to be determined. The test requires a patch to the SCCP Protocol Emulation which has been submitted upstream: https://git.eclipse.org/r/#/c/124552/ Change-Id: I03f5e8b282a7396b45417495c88d8fb81b26cda8 Related: OS#2666
2018-07-24Reply to wildcard ep in CRCX with a concrete endpointDaniel Willmann1-0/+1
BSC_ConnectionHandler.ttcn:563 This helps TC_gsup_cancel which previously encountered a Dynamic test case error: Using the value of an optional field containing omit. The test still fails, but this time because it "Received unexpected BSSAP instead of CM SERV REJ". Change-Id: I9fedf2573487066b951804a328ba428d2189c4a4
2018-07-24Stop tests after failuresDaniel Willmann2-37/+59
Call mtc.stop after setverdict(fail), add reasons to most failures and fail with verdict error for internal errors. Change-Id: I9b618235939fa41160b9be6677b121963d3ec857
2018-07-20msc: add TC_mo_cc_bssmap_clear to catch OS#3062Neels Hofmeyr1-0/+43
The test currently crashes osmo-msc, which is fixed by I5c30e0f9545fb76615776ff6cc16b56aeb5b043a (osmo-msc). Related: OS#3062 Change-Id: Ic80646e1fba37bb6163ca3a7eead7980b4ad7a51
2018-06-25check for osmo-msc crash upon overlong IMSIStefan Sperling1-0/+3
Overlong IMSIs used to trigger an assertion failure in osmo-msc. This problem has been fixed but there was no test for it yet. A lazy way of testing for this problem is to send an overlong IMSI from an existing test which already verifies related behaviour and would fail if the MSC crashed: TC_lu_by_tmsi_noauth_unknown However, osmo-msc currently accepts overlong IMSIs and silently truncates them, so this change as-is currently breaks this test. But I would argue that osmo-msc's current behaviour is unreasonable anyway and have proposed a patch to change it: https://gerrit.osmocom.org/#/c/osmo-msc/+/9739/ With that patch applied to osmo-msc, this test keeps passing. Change-Id: I2c472bee76086f6c84ec684d2e58b3351ebc3147 Depends: I785c994f41a646d8d83d3d82f5a9ae6b572eb641 Related: OS#2864 Related: g#9739
2018-06-21msc/USSD: use more informative names for test casesVadim Yanitskiy2-11/+12
Let's explicitly indicate is a SS/USSD message MO or MT. Change-Id: I87f16f935f015dbd2ac2867d8ea5e155cc365e3f
2018-06-21msc/USSD: drop the TC_lu_and_ussd_wrong_code test caseVadim Yanitskiy2-55/+0
As we are about to finish the implementation of GSM TS 09.11, in our case it is 'SS/USSD over GSUP', OsmoMSC will not decide itself which USSD request-code is known, and which is wrong. Change-Id: Ic104a49bb2dce2127063bcef8443ee6b639c9f19
2018-06-14Add README.md file for several suitesPau Espin Pedrol1-0/+24
Content grabbed from [1] and converted to markdown as it's more probable to have it displayed correctly on popular git repo hosting platforms. Syntax for embedded graphviz taken from [2]. [1] http://git.gnumonks.org/laforge-slides/plain/2018/osmodevcon2018-ttcn3_test_suites/osmodevcon2018-ttcn3_test_suites.adoc [2] https://github.com/stlehmann/markdown-graphviz Change-Id: I9aad03e605569e9613665a7585d60bf308bcb54f
2018-06-12*.default: change logging filemask from ERROR | WARNING to += PARALLEL | ↵Alexander Couzens1-8/+8
VERDICTOP PARALLEL | VERDICTOP will log when the port is dying or when other components will change to fail. This helped to find a timeout in the SGSN tests where a function call message timed out. Change-Id: I770ac964dc37e2752e7d35e493f707b091c739b0
2018-06-10msc/USSD: test USSD-request during an active callVadim Yanitskiy2-0/+69
The idea of this testcase is to check if MSC can correctly handle a USSD-request during an active call. What we do here: 1) Perform Location Update 2) Establish a MT-call 3) Perform *#100# request 4) Release the call Change-Id: Ifa3cd1aeeb34ccf5864f78b76a88aaa6d5e51839
2018-06-10msc/USSD: add unknown request code testcaseVadim Yanitskiy2-0/+55
The idea of this testcase is to check reaction of the network on reception of USSD request with unknown/unhandled request code. It is not clearly defined by the GSM specs, how the network should react in such cases, but looking at GSM TS 04.80, section 4.3.2 "Error types description", the UnexpectedDataValue error looks suitable. Commercial networks also use this error when an unknown request code is sent. Change-Id: I6a3fcaafc37972a38c13722f0b511ea5e1e3fbd8
2018-06-06USSD_Helpers.ttcn: add f_USSD_FACILITY_IE_RETURN_ERRORVadim Yanitskiy1-0/+15
Change-Id: I9f2b526cb67224cab81364cec34efd42bbb44327
2018-06-02msc/USSD: add single *#100# request testcaseVadim Yanitskiy2-0/+65
In this testcase we perform LUR, then request our own number and then expect the response with matching MSISDN. Change-Id: I82450c6f48f6c17bc33e0ec6c91f2a73e44793ad
2018-06-02msc/BSC_ConnectionHandler.ttcn: add EST_TYPE_SS_ACT for SS/USSDVadim Yanitskiy1-1/+5
Change-Id: If439e7c082b435d7f668065c9f8e3bdfa941dcc5
2018-06-02msc: introduce USSD helper functionsVadim Yanitskiy2-0/+64
Change-Id: Ic528b968a9bc7c12e8395364e895400aa016c8f5
2018-06-02msc: import GSM 7-bit coding functionsVadim Yanitskiy2-1/+2
Change-Id: Ie8dd865d0c4c64827284c737d431e6c87b3d0847
2018-06-01sync TTCN3 MSC test config with docker-playgroundStefan Sperling3-0/+149
Update MSC_Tests.default according to the current MSC_Tests.cfg used by docker-playground. Add osmo-msc.cfg and osmo-stp.cfg example configuration files. Allows the MSC tests to be run locally. Change-Id: Ia00f0315a5246c3ec55563ebd21a586aec8e4688
2018-06-01expect TC_establish_and_nothing to passStefan Sperling1-6/+1
The test case TC_establish_and_nothing is now passing. Update expected results list accordingly. Change-Id: I925fa4ad2e38e189cf5dd1ae76a24cdb9011fdc8 Related: OS#2879
2018-05-31msc: Add Encoder/Decoder for Supplementary ServicesHarald Welte2-2/+12
The many SS_* types depend on MAP, whcih in turn depends on ROSE. Add all of this to the MSC testsuite so we can do SS related testing. Change-Id: If5084decb5391736ab5cadd86adb2ffa78e7140f
2018-05-27BSSAP_Adapter: Split f_bssap_start() from f_bssap_init()Harald Welte1-0/+1
In non-handler mode, the SCCP emulation is currently started before there's a user registered to SCCP_SP_PORT. If the first BSSMAP package arrives from the network, then the SCCP_Emulation will crash as it cannot deliver the resulting SCCP user primitive to the user. Let's split start from initialization, so user code can still register something to SCCP_SP_PORT before starting SCCP_Emulation. Change-Id: I55c94f18531bb7e5369500dc90f4b0ff3a420774
2018-05-17MSC_Tests: Extend timeout waiting for Clear Cmd in TC_establish_and_nothingDaniel Willmann1-1/+1
This should fix the bogus failures we are seeing in this test. The pcap usually shows that the Clear Command does arrive after about 5 seconds, but sometimes the internal timer fires before that. Double the timeout of the test here. Change-Id: I998cfb52a3813dd9f76d3787e4d0d448752ec847
2018-05-16MSC_Tests: fix iterator in f_init()Philipp Maier1-1/+1
With f_init(), the user has the option to specifiy how many bsc instances should be created. A for loop then iterates over the prepared configurations and calls f_bssap_init(). The first parameter g_bssap is tied to index 0 constantly but should be tied to the iterator i. - use i instad of 0 as iterator for g_bssap Change-Id: I490bab70224d236ab576a2ea3863f6d0afd5f22a
2018-05-02update expected resultsNeels Hofmeyr1-49/+11
bsc: TC_assignment_sign fails with different message msc fixed: TC_lu_clear_request TC_emerg_call_imei_reject TC_cm_serv_req_vgcs_reject TC_cm_serv_req_vbs_reject TC_cm_serv_req_lcs_reject TC_cm_reest_req_reject TC_cl3_rnd_payload TC_lu_and_mt_sms new: TC_smpp_mo_sms TC_smpp_mt_sms sgsn fixed: TC_attach_umts_aka_gsm_sres Change-Id: Ie9ef25fb2081ebab7a2b08c06307fa391f8f747a
2018-04-17BSSAP_Adapter: Introduce transport over IPA/SCCPliteHarald Welte1-1/+1
In addition to the existing 3GPP AoIP stacking, allow BSSAP to run on top of a SCCPlite stacking. Implement both the server and the client role for IPA. Related: OS#2544 Change-Id: Ie844c4de62e0ef5d5c4c366185968211a7f6d676
2018-04-14msc: Add SMPP tests for MO + MT SMSHarald Welte2-2/+243
Change-Id: I5349559c7c3096533fb07fcf53f0a44ff7f6567f
2018-04-14msc: Add SMPP_Emulation + SMPP_TemplatesHarald Welte1-1/+1
Change-Id: I80efe16f603227694c6242d556ae77590271e4c6
2018-04-14msc: Add SMPP_CodecPortHarald Welte2-1/+2
Change-Id: I57640ccc5370d6820bc303003e162f27ddc9fcfd
2018-04-14msc: Fix console log levelsHarald Welte1-2/+4
In Change-Id I52a4c8118828c1605cf672889982f987568ad17d we introduced a name change for the SCCP/M3UA components, which meant that the log level configuration did no longer apply as intended. Change-Id: Iebdaf3446a81ea5f8310110f5cca2bdb3e552e3f
2018-04-14msc: Fix ti_flag mistake in f_mt_sms()Harald Welte1-1/+1
The L3 transaction-id in MT-SMS is allocated in the MSC, so any messages we expect from the MSC must carry c_TIF_ORIG. Change-Id: I6ea977a7662fdfc9c504f13ac5632ac20a04f522
2018-04-11bsc, msc: update expected resultsNeels Hofmeyr1-1/+8
Mark TC_paging_imsi_a_reset fixed. Add various new tests. Change-Id: Ib3a36efeb086fd995d7dad4e040f5a46b1b1ca0a
2018-04-11mask timestamps and source file nrs in expected-results.xml filesNeels Hofmeyr1-70/+70
Prepare for upcoming updates with concise diffs. Change-Id: Ic9f006aa8db1b477598605e0525faeb229b03641
2018-04-11fix build: don't clean out expected-results.log: rename to *.xmlNeels Hofmeyr1-0/+0
'make clean' as generated by ttcn3_makefilegen removes all *.log files, which of course cleans out expected-results.log, which should not happen. Since this is a junit XML file, rename the suffix to .xml. Change-Id: Ic334f6b758eef865e3a497aa430691a3ae696d25
2018-04-11MSC_Tests: fix TC_mo_crcx_ran_rejectPhilipp Maier2-81/+73
The testcase intentionally responds to the RAN sided CRCX with a garbeled message to cause the MGCP handlin inside the MSC to fail. The MSC is then expected not to perform further MGCP operations since it did not get a proper response to the first CRCX, so the specific endpoint name is not known, eventually preventing from doing an MDCX. However, the testcase responds to incoming DLCX commands, instead setting the verdict to fail. Also the altstep that dispatches the message after the errornous MGCP response unconditionally catches all BSSAP messages before entering the sub-altstep as_clear_cmd_compl_disc() that handles the clearing of the connection. Eventually the clear command is never received in this sub-altstep. - Make sure the verdict is set to fail when an MGCP message is received after the errornous response to the CRCX. - Remove the unconditional BSSAP.receive in order to be able to dispatch the clear command properly - Update the expected-results.log file Change-Id: I806491741d310e4410f6cb4ce0309235e9bf4300 Related: OS#2882
2018-04-09msc: Initial SMS testing (MO + MT SMS, successful case, no SMPP)Harald Welte2-1/+220
Change-Id: I707330454ffab87daebf22ba83e6ba2873996424