Commit Graph

146 Commits

Author SHA1 Message Date
Daniel Willmann 2073c41997 HACK: Workaround buggy mgw newline parser
Change-Id: Ic16dfe6c2452b2dc3e9560b0fa6bdd67fb59b2fe
2018-01-17 18:01:00 +01:00
Daniel Willmann 1fb6e4cc91 bsc: CRCX is answered with (malformed) ACK
Change-Id: I09c1ed467e95be236e0758d6a9c8bbef405c02eb
2018-01-17 15:29:17 +01:00
Daniel Willmann 4886ae6d0c bsc: Reply to CRCX with ACK
Change-Id: Ieaea431a99241d8844b915e1b46b77c79fff24df
2018-01-17 15:29:17 +01:00
Daniel Willmann f667613772 bsc: Register expect criteria for MGCP CRCX
Change-Id: I466df816eef9863bf1664e785b996c0697dc04e3
2018-01-17 15:29:17 +01:00
Daniel Willmann b381ca2e85 MGCP_CodecPort: Receive MGCP command or response
If we act as MGW we need to accept MGCP commands sent to us as well

Change-Id: I895cfb688a2923b278828f5ae918c73fda18636d
2018-01-17 13:25:58 +01:00
Harald Welte 3da3379ef8 HACK: Work around IPA CCM bug in OsmoBSC
OsmoBSC has some misunderstanding about how IPA CCM works and hence
we need to work around this until that bug is fixed in OsmoBSC.

See https://osmocom.org/issues/2718

Change-Id: I304535d28a165f76a0a140dc0a15dd81a9db28c8
Related: OS#2718
2018-01-17 13:12:20 +01:00
Daniel Willmann 61157015ee Add MGCP_Emulation
Change-Id: I5245be2b44e98e1c74b9519c610564667b980a67
2018-01-17 13:12:19 +01:00
Daniel Willmann d47106b337 BSSMAP_Emulation: Initialize ExpectTable before use
The assignment_fr_* tests now go through to the point where the BSC
sends a CRCX to the mgw.

Change-Id: Ic5a128861ae7b1a4cf8158e43c59c52ebd2a20ba
2018-01-17 13:12:19 +01:00
Daniel Willmann 17f970fc65 RSL_Emulation: Initialize the ConnectionTable
By default all the elements in the conn table seem to be considered
<unbound>.
f_cid_create() manages to set ra, ra_fn and comp_ref in the
ConnectionData element, but checking for
ispresent(ConnectionTable[i].ra) still returns false while
log(ConnectionTable[i].ra) returns 23. Setting every optional element to
omit as f_cid_clear() does before using the connection table seems to
solve this issue.

The assignment_fr_* tests now continue after receiving the Immediate
Assignment, but still fail after receiving the CM Service Request.

Change-Id: I24205425c5b6ae5b8a0f6288ba89ea5a1dc4669d
2018-01-17 13:11:57 +01:00
Stefan Sperling 6d9309b8a4 Fix f_enc_mcc_mnc() to return a properly encoded MCC/MNC triple octet.
With help from Daniel Willmann.

Change-Id: I99a5317e425d15acd463aa94c683676cacd54e0b
Related: OS#2754
2018-01-11 14:43:16 +00:00
Harald Welte 474fd7d11a Add a MNCC Socket implementation for TTCN-3
Change-Id: I8c334d4c2e630b2b779e73404c44a8df3278c614
2018-01-03 21:09:35 +01:00
Harald Welte 35bb716610 Add comments with short module description on top of each file
Change-Id: Id934d7a763b619d52cbec7de439b3708225b81f3
2018-01-03 21:09:29 +01:00
Harald Welte df32723446 GSUP Support and first test against OsmoHLR
Change-Id: Idd7a6aca1ab193da39294f49a3adc4c1cd7cecff
2017-12-28 23:17:24 +01:00
Harald Welte 8098164721 RTP_Emulation: Integrate IuUP support
Change-Id: I46de7fb9c324654275a27aa5f8c1be70340e3229
2017-12-25 00:03:07 +01:00
Harald Welte 3f6f48f4c1 RTP_Emulation: Add RtpemConfig / RTPEM_configure() call
Change-Id: Ie60b750fc009a3d8aa044e4fd450873aa19086bb
2017-12-25 00:00:58 +01:00
Harald Welte 46a38f1669 RTP_Emulation: Fix calculation of timer + timestamp increment
Change-Id: I3ba0d31ad571f42721f208a40f7dcbd8fb2c6e88
2017-12-25 00:00:58 +01:00
Harald Welte 8a4d3954b6 RTP_Emulation: Fix encoding of timestamp; int2bit counts in bits!
Change-Id: I8e8b8faff362536c46b188eb9bbb77bf0ceb866d
2017-12-25 00:00:58 +01:00
Harald Welte c676c68de6 Add 3GPP TS 25.415 IuUP encoder/decoder
Change-Id: Ie04438d8ec2b796e9e56b1937fa024a5299457dd
2017-12-25 00:00:58 +01:00
Harald Welte 73cd271a56 BSC_Tests: Implement ecnryption related procedures
Let's verify the operation of the CIPHERING MODE COMMAND as issued
by MSC, performed by BSC and implemented by simulated BTS/MS.

Change-Id: Ibc06bd2177c63837a794a0ca1f54ebef17499e78
2017-12-17 13:24:39 +01:00
Harald Welte 15166144ae L3_Templates: Add ts_RRM_ModeModifyAck template
Change-Id: Iec607577aff1c65cb208c20a4c4169b5b4569892
2017-12-17 13:24:39 +01:00
Harald Welte 71b5ec8c57 RSL_Types: Fix message type of ts_RSL_IPA_MDCX_ACK()
Change-Id: I8ce0c96d66c3027d68542b3f58d9a732fb42517d
2017-12-17 13:24:39 +01:00
Harald Welte 7794d5b7ea RSL_Types: Handle IPA specific messages in tr_RSL_MsgTypeDR()
They all are related to a dedicated channel and carry a channel number
as first information element.

Change-Id: Ic3fdc029a96c34a9d2d9ec669b789526c8325637
2017-12-17 13:24:39 +01:00
Harald Welte f307500caa RSL_Types: Fix RSL Message Type enumerated definition
Change-Id: I9096f8a579ee245fb193e0fd53144056bc4a23a8
2017-12-17 13:24:39 +01:00
Harald Welte 624f963393 BSC_Tests: Prepare for tests based on {RSL,BSSMAP}_Emulation
The existing tests were implemented directly on top of the BSSMAP
and RSL CodecPorts.  If we loop in the RSL_Emulation and
BSSMAP_Emulation components, we can properly multiplex/demultiplex
multiple MS (radio channels) on both the RSL and the MSC (SCCP
connection) side.

In order to have a single component that handles both the RSL and the
BSSAP side of a given channel/subscriber/call, we introduce the concept
of BSSMAP "Expects", where the test csse can register the L3 INFO that
it sends in the RLL ESTablish INDication on the RSL side, so the BSSMAP
handler cna route the BSC-originated SCCP connection with that L3 INFO
back to the same component.  This is a bit inspired "in spirit" of the
"expect" mechanism of netfilter connection tracking.

Change-Id: I71f777cd4f290422fa68897952b6505875e35f0e
2017-12-17 13:24:35 +01:00
Harald Welte 004f5fbca3 BSSMAP_Emulation: use BSSAP_CodecPort
So far, BSSMAP_Emulation used the SCCPasp_SP_PORT directly, explicitly
calling BSSAP encode/decode functions while processing the primitives.

Let's clean this up and use the BSSAP_CodecPort which has meanwhile
been developed as a dual-faced port that can be stacked between SCCPasp
and the user to avoid any manual encode/decode function calls.

Change-Id: Icded789d18f3469f74e16f552df2c7ac44ac4294
2017-12-17 11:04:32 +01:00
Harald Welte f1b64e208f BSC_Tests: Ensure MSC passes SpeechCodecList in AoIP ASSIGNMENT
Change-Id: I66deffc50b5adcc8707747c0baa2e65ee36bf18e
2017-12-15 14:56:48 +01:00
Harald Welte 235ebf1b9c BSC_Tests: Add whole bunch of new assignment tests
Change-Id: Ia7304f2e2265c2ebd92575a9403b082579397656
2017-12-15 14:19:10 +01:00
Harald Welte 4bf5fc97fb BSSMAP_Templates: Define various ASSIGNMENT related templates/constants
Change-Id: Id4f98120dbedf1a4fd5fb34df0d638eb08d7c3cb
2017-12-15 14:19:10 +01:00
Harald Welte b69533d153 BSSMAP_Templates: Define enum with 08.08 cause values
Change-Id: I2fc122a510403d0da8da04ca323687065347c96a
2017-12-15 14:19:10 +01:00
Harald Welte cfe2c962a7 BSC_Tests: Add TC_outbound_connect to test if BSC rejects inbound SCCP connections
Change-Id: Ie9087df9ff9b48c8be242b1ae66cbca936b07121
2017-12-15 14:19:10 +01:00
Harald Welte cc7e4dc40e BSSMAP_Templates: Enable use for AoIP, not just E1-CIC
Change-Id: I421ade4ae1c0c19c9c2b1172cdcf8d6c4cd55205
2017-12-15 14:19:10 +01:00
Harald Welte 9958a4d7c8 RSL_Types: Add various IPA / Abis-IP specific IEs + templates
Change-Id: I683e7c23b217a993e0d8f079e5bf1a10403420bb
2017-12-15 14:19:10 +01:00
Harald Welte 16a4adfa5f BSC_Tests: Add TC_assignment_cic_only (AoIP Assign. must fail with only CIC)
Change-Id: Iee7202841ad8466a65b5d54679262be100863e39
2017-12-15 14:19:10 +01:00
Harald Welte a8ed906866 BSC_Tests / RSL_Types: Add enumerated for RSL Cause value
this looks much more human-readable in the logs...

Change-Id: I2bc3de37a3059cc16c6293df45e5c4d620422502
2017-12-14 09:46:01 +01:00
Harald Welte 5d1a2209f2 bsc: Run three virtual BTSs (2 in one lac, 1 in another)
This allows us to verify if the BSC pages *only* where it is supposed
to page based on the cell identity list in the 08.08 PAGING.

Change-Id: I53ffe44279a7b83e045b3fdb25da64529955d457
2017-12-13 19:51:29 +01:00
Harald Welte 067d66ed5b Add RTP_Emulation (stream source/sink) on top of RTP_CodecPort
Change-Id: Ic0750bdc025cd6f16094843550429d976fb44f4f
2017-12-13 17:24:03 +01:00
Harald Welte 1a9b35dd3e Add missing RTP_CodecPort_CtrlFunct TTCN and C++ files
Change-Id: Ic5499a0b5f635a93214cbb5e641d2fd8d37f38d6
2017-12-13 15:42:31 +01:00
Harald Welte 152c38c765 move RTP_CodecPort.ttcn to library
Change-Id: I67343f016757c23a85db6b526b6f60476e91ffc3
2017-12-13 13:19:26 +01:00
Harald Welte 16979760b2 Osmocom_CTRL_Types.ttcn: workaround to compile on TITAN 6.1.0
I have no clue why, but this seems to work?

Change-Id: I49750709e50d16a9fabec3e754ae8381832e6104
2017-12-13 00:46:31 +01:00
Harald Welte 4c5ef5b3e1 IPA_Types: Add ts_PDU_IPA (selftest fixup 2017-12-12 15:53:40 +01:00
Harald Welte 735dd07b38 RSL_Types: Work around (perceived) shortcoming of TITAN RAW encoder 2017-12-12 14:55:17 +01:00
Harald Welte 3e6ad89a2b IPA_Emulation: Call f_IPL4_setGetMsgLen for both client and server
So far, only the IPA client was instructing the IPL4asp to use
the message-desegmentation function.  The server didn't use it, leading
to inconsistent behaviour.
2017-12-12 14:39:46 +01:00
Harald Welte 72cecfa26c BSSMAP_Templates: Add templates for various PAGING options 2017-12-11 19:51:00 +01:00
Harald Welte 51d74101b8 RSL_Types: Fix coding of RSL_IE_ChanNeeded and matching if PAGING_CMD 2017-12-10 23:05:02 +01:00
Harald Welte fdfa046803 Osmocom_CTRL: Fix matching on incoming trap; avoid generating error verdicts in functions 2017-12-10 18:09:40 +01:00
Harald Welte 346658df4b BSSAP_CodecPort: respondingAddress is optional in BSSAP_N_DISCONNECT_ind 2017-12-10 14:10:25 +01:00
Harald Welte 510a287a5e BSSAP_CodecPort: Don't dereference optional fields unconditionally 2017-12-10 13:48:17 +01:00
Harald Welte e8a5ab1122 RSL_Types: New tr_RSL_REL_REQ and tr_RSL_DEACT_SACCH templates 2017-12-09 22:34:57 +01:00
Harald Welte 6efa8e3940 RSL_Types: Fix RSL_IE_Cause (missing length octet) 2017-12-09 22:34:06 +01:00
Harald Welte cfa79adb83 BSSMAP_Templates: Add tr_BSSMAP_ClearRequest 2017-12-09 22:33:47 +01:00