Commit Graph

3516 Commits

Author SHA1 Message Date
Pau Espin a990b1bb60 mgw: Set osmux bind-ip(-v6) VTY configs
Until now we forgot to properly configure the osmux socket local ip, but
that was fine because 0.0.0.0 was taken as a default.
With addition of IPv6, this changed, and the socket is not bound unless
an IP address is set (to allow conditional use of IPv4, IPv6 or both).

Depends: osmo-mgw.git Change-Id I446cd7da217e9f4a74995d7784ae55dcc60a29b7
Change-Id: I4e0ea11ae7e55da600aec56bebf694f3ba0f7b72
2022-10-04 18:21:47 +02:00
Pau Espin 5fa8f781c3 ggsn: Fix TC_gy_charging_volume_quota_threshold expectations
in Diameter, the CC-Input/Output direction is defined as follows in
RFC4006:
"""
8.24.  CC-Input-Octets AVP

The CC-Input-Octets AVP (AVP Code 412) is of type Unsigned64 and
contains the number of requested, granted, or used octets that can
be/have been received from the end user.

8.25.  CC-Output-Octets AVP

The CC-Output-Octets AVP (AVP Code 414) is of type Unsigned64 and
contains the number of requested, granted, or used octets that can
be/have been sent to the end user.
"""

So:
* 3GPP uplink is from end user to PGW, and hence 'CC-Input-Octets'
* 3GPP downlink is to end user to PGW, and hence 'CC-Output-Octets'

This test started failing a few days ago since a bug was recently
fixed in open5gs which was swapping the counters in open5gs-upfd:
https://github.com/open5gs/open5gs/pull/1793
f72a1edc6e

Change-Id: I2f64649ce70d85634f14b84eff98731f7711cbad
2022-10-03 14:00:02 +02:00
Vadim Yanitskiy b34f5a9c37 pcu: osmo-pcu.cfg: update GSMTAP Um logging configuration
Change-Id: Ia53f59da04fd30f055ee3a6a46e9afb5ecd48162
2022-10-02 14:48:57 +07:00
Pau Espin 581e1062f1 hnbgw: Add missing results to expected-results.xml
Change-Id: I26ccbaa2b071af981bf707b41bc26fb86de62d77
2022-09-27 15:59:54 +02:00
Pau Espin acf4f225bd hnbgw: Introduce test TC_hnb_register_duplicate_reuse_sctp_assoc
Change-Id: I09ce08917b590ecd6fdf93f8b564a0d53900c871
2022-09-27 14:33:40 +02:00
Neels Hofmeyr 2d29274f32 add upf/ to test osmo-upf
So far testing only PFCP interaction without real GTP traffic.

Related: SYS#5599
Change-Id: If67819dea785597841f21d8c444cb4866cfde571
2022-09-20 13:32:16 +02:00
Pau Espin cd6077f538 bsc: Test assignment of non-AMR codec with Osmux enabled
Change-Id: I31ea10963bdf61b2e070ed6ac3257b872245f724
2022-09-19 20:53:43 +02:00
Vadim Yanitskiy 3998c03df3 BSC_Tests: fix AMR tests matching RSL MultiRate configuration IE
The RSL_IE_MultirateCfg was implemented and added to union RSL_IE_Body
in [1].  Before this change, this IE was decoded as RSL_LV (basically
an octetstring).  Now this IE is decoded as RSL_IE_MultirateCfg, while
some AMR tests still expect RSL_LV.  Let them use RSL_IE_MultirateCfg.

Change-Id: I40dab41d5dc5d14e358ba5a070ce174e7d8d4a4b
Fixes: [1] I0a5ddce570c0fd70f096d897b0b609d20b552ff7
2022-09-14 18:19:28 +07:00
Vadim Yanitskiy 8b18937eef BSC_Tests: f_assignment_codec(): log the actual value on mismatch
Change-Id: I437c1e796b00bfae41620f05ef8f15c8db8ca3d9
2022-09-14 17:48:38 +07:00
Vadim Yanitskiy 9e0139ba6d library/RSL_Types: account lengthof params in ts_RSL_MultirateCfg
In TTCN-3 it's not possible to store templates in records, so in
f_assignment_codec() we match received RSL_IE_MR_CONFIG against the
value (not template!) stored in g_pars.expect_mr_conf_ie.

Because of that, the length field is not being calculated by TITAN
for us, so we need to calculate it in ts_RSL_MultirateCfg ourselves.
Automatic length calculation only works during encoding/decoding
and when matching against a receive template.

Change-Id: I595be86d69913ba25e965a5a5c6977e00c342e60
2022-09-14 17:48:38 +07:00
Neels Hofmeyr bacb74f241 hnbgw: test PS RAB Ass both with and without PFCP
Add mp_enable_pfcp_tests. When true, osmo-hnbgw-with-pfcp.cfg needs to
be used.

Related: I39b9632f8524a9f3455c1a2d7611bfe8ba07c2fd (osmo-hnbgw)
Related: I02b60941343000a4618e95f56326bec170c32bfe (docker-playground)
Related: SYS#6093
Change-Id: I511e758807e0512c18f3f9e0a8c4699b9a3f5992
2022-09-14 10:42:36 +00:00
Vadim Yanitskiy 0345d20778 library/RSL_Types: add params argument to ts_RSL_MultirateCfg
Change-Id: Ia85339a9c268abc84f9b4228f8d418f1dac786e6
2022-09-14 16:47:18 +07:00
Vadim Yanitskiy b9bf00f96a BSC_Tests: fix TC_assignment_osmux_cn: use c_mr_conf_5_90
Currently this testcase fails:

  RSL MR CONFIG IE does not match expectation.
  Expected: { other := { len := 2, payload := '2804'O } }

Change-Id: Icc5381eccb924803b1117b46d2b4c47cee6dabd7
2022-09-14 16:47:18 +07:00
Vadim Yanitskiy 36fe958279 BSC_Tests: use c_mr_conf_5_90 in TC_assignment_codec_amr_startmode_cruft
This way it's easier to see that the only difference from other
tests using c_mr_conf_5_90 is the ICMI field set to false.

Change-Id: If7b491fa55a9366520c2d665a700c5badb187fae
2022-09-14 16:47:18 +07:00
Vadim Yanitskiy 5949470f1a BSC_Tests: cosmetic: s/mr_conf_amr_5_90/c_mr_conf_5_90/
* This is a global constant, so prefix with 'c_' for consistency.
* The RSL_IE_MultirateCfg is all about AMR, remove redundant 'amr'.

Change-Id: I72405b7139fcfd0dbe90afc469ed4db71b43a87c
2022-09-14 16:47:18 +07:00
Vadim Yanitskiy f14e696656 library/RSL_Types: s/amr_codec_modes/codec_modes/ in RSL_IE_MultirateCfg
The RSL MultiRate configuration IE is all about AMR (Adaptive Multi
Rate) codec, so there is no need for 'amr_' prefix in field names.

Change-Id: If63ee50e8681ad4e0a202f142f2fca2268d55079
2022-09-14 16:47:18 +07:00
Vadim Yanitskiy fcce70596a BTS_Tests[_VAMOS]: use default param values for ts_RSL_MultirateCfg
There is no real need to pass the multi-rate parameters explicitly
in each invocation of ts_RSL_MultirateCfg.  The exact multi-rate
configuration does not matter in scope of BTS specific tests.

Change-Id: I24117af8c5b7b11fe4b8f24fca5279ad97b46fab
2022-09-14 16:47:18 +07:00
Vadim Yanitskiy 4d85208f01 fixup: bsc: Add testscase & infra to validate Osmux support BTS<->BSC
The per-BTS VTY command 'osmux (on|off|only)' was added to osmo-bsc.git
recently, and is not available in -latest yet.  Use it conditionally.

Change-Id: Id501d3f4b5eb18b096d8baffcb5f38e583f7a3d8
Fixes: I6e82eb9d995de988b812001e1c4cf6923509de66
2022-09-14 16:44:15 +07:00
Pau Espin 39bfa0298b bts: Add testscase & infra to validate Osmux support BTS<->BSC
Related: SYS#5987
Change-Id: I1af23c7a60b05edc3b544f1fea0023f48e89f7a7
2022-09-13 11:20:11 +00:00
Pau Espin 29c6dfb46d bsc: Add testscase & infra to validate Osmux support BTS<->BSC
New TC_assignment_osmux_bts is added which tests Osmux used only
BTS<->BSC.
Existing TC_assignment_osmux is renamed to TC_assignment_osmux_cn,
and a new TC_assignment_osmux is added which tests using Osmux on both
sides (towards BTS and CN).

Related: SYS#5987
Change-Id: I6e82eb9d995de988b812001e1c4cf6923509de66
2022-09-13 11:20:11 +00:00
Pau Espin f0b9fa0574 hnbgw: Introduce test TC_hnb_reregister_reuse_sctp_assoc
Change-Id: I7386bd4e786daf2688a68ab174a9d4f0b093a741
2022-09-12 21:28:15 +02:00
Pau Espin 83a4961753 hnbgw: Start only needed amount of HNBs emulations
Change-Id: Id0e1c7423f016989de997e2be10516f4413ac245
2022-09-12 21:11:05 +02:00
Pau Espin bcf135a0d0 bts: Fix BTS_Tests_VAMOS tests using AMR
Recent commit forgot to add the required new params to VAMOS tests.

Fixes: 091c530555
Change-Id: Ia382e200b51a7ddb99dc2583b538432740fd298c
2022-09-08 13:24:29 +02:00
Pau Espin 5bd8e88195 Osmux_Emulation: Add DATA port
Similar to what's already present in RTPEM_Emulation, this allows tests
to retrieve the Osmux messages received.

Related: OS#5987
Change-Id: Id9aa3a0a02ef5a5e39b4df8a1c165f35255829ab
2022-09-07 11:29:14 +02:00
Pau Espin 091c530555 bts: Test AMR in TC_speech_rtp_tch{h,f}()
Related: SYS#5987
Requires: osmocom-bb.git Ib80be434c06d07b3611bd18ae25dff8b14a7aad9 (trxcon)
Change-Id: I8cf7792a00b0a858f6a02bf5cb0d283484b820eb
2022-09-07 11:28:19 +02:00
Pau Espin 1a8f8f8ab6 library/AMR: Add RTP AMR helper structs and functions
Change-Id: I40cd999badeeefa38a393af9008d8ce047e3c778
2022-09-07 11:28:03 +02:00
Pau Espin 440e1dcb34 bts: Pass AMR codec info over L1CTL and RSL
Related: SYS#5987
Depends: osmocom-bb.git Change-Id Ia20bc96e39726a919a556c83c8be48cb31af7331
Change-Id: I3db7f6a4b7819b16ada83862f2a5409db4fa21f9
2022-09-07 10:46:17 +02:00
Pau Espin 71ed463957 Move AMR defintions out of OSMUX_Types to its own file
This way they can be used without the need to import OSMUX related
modules.

Change-Id: I0edfbb7359516ba77180afab18c3e1ffb2d0c927
2022-09-07 10:46:17 +02:00
Pau Espin f7634dc706 BSC: Implement RSL_IE_MultirateCfg and use it in BSC_Tests
Change-Id: I0a5ddce570c0fd70f096d897b0b609d20b552ff7
2022-09-07 10:46:13 +02:00
Pau Espin 8539312f8f cosmetic: RSL_Types: Fix trailing whitespace
Change-Id: I664cc5a00240a308df5ed36feafe0779be152ec0
2022-09-02 17:57:11 +02:00
Pau Espin 17da32340e cosmetic: L1CTL: Fix trailing whitespace
Change-Id: I9d0446c21e1331c426bca0dad434f32de0ff0d38
2022-09-02 17:06:31 +02:00
Vadim Yanitskiy 095b32d497 bts: update expected-results.xml
Change-Id: Ifcd8601d1aadce78a1b0a0ed814ae9e77e8497aa
2022-08-30 19:46:15 +07:00
Vadim Yanitskiy 5f6dd352ea BSC_Tests: fix race conditions in TC_chan_alloc_algo_ass_dynamic
In cases a), b), c), d), and e) we're sending one or more Measurement
Reports via the A-bis/RSL, and then immediately triggering a traffic
channel assignment by calling f_TC_chan_alloc_algo(), which sends an
Assignment Request via the A interface.

The above-mentioned messages are sent immediately all together, so it
may happen that the BSC handles the Assignment Request earlier than
the Measurement Report(s).  In this case there will be no RxLev
samples, so the BSC would fall-back to ascending allocation order.

Recently we saw this race condition actually happening on Jenkins:

https://jenkins.osmocom.org/jenkins/view/TTCN3/job/ttcn3-bsc-test-sccplite/1583/

Let's introduce an artificial delay before sending the Assignment
Request, so that the BSC has enough time to process received MRs.

Change-Id: I2fd6508488e935d208a7aba8e2f215b1cc14ad32
2022-08-29 15:39:06 +00:00
Vadim Yanitskiy 8b4e046b5d BTS_Tests: add TC_{chan_act,encr_cmd}_a54 to control
Both testcases were introduced in 2021 [1], however they're not
executed on Jenkins because they're not present in control section.

Fixes: [1] I38e8a1cf15eb41a621b457b39024283a767c94be
Change-Id: Iebf6d14321b54e7ef261443aece03296540ebe92
2022-08-27 19:24:32 +07:00
Daniel Willmann 28209ecdac hnbap: Use protocolExtensions := * in tr and omit in ts templates
Change-Id: Ic8f9afc9d74507f7d73f52cefc92ed1c2dc4b1bc
2022-08-24 13:57:52 +02:00
Daniel Willmann c79679a2de hnbgw: Add test to check for duplicate hnb registrations
Change-Id: Ib20d07ffabb91dfa82c212aaa363cafc7496bba8
Related: OS#6084
2022-08-24 10:06:34 +02:00
Daniel Willmann 6d2d8885c8 hnbap: Add tr_HNBAP_HNBRegisterReject
Change-Id: Ide006cac4fcdc062614f53fb95970feb51d63731
Related: OS#5656
2022-08-24 10:00:49 +02:00
Pau Espin 4d0886d77d OSMUX_Emulation: Add special error case for port events
This way it's easier to quickly spot there was a problem with the socket
connection.

Change-Id: I962bf4837a9e359576c42a51a9919891186c7100
2022-08-20 08:11:27 +00:00
Pau Espin ef046b39bf OSMUX_Emulation: Use Misc_Helpers.f_shutdown() everywhere
Change-Id: Id8f104a4123fcfbc96ab07f2e9343369946e3334
2022-08-20 08:11:27 +00:00
Vadim Yanitskiy d079b3fa33 deps: use titan.TestPorts.UDPasp from ECLIPSEGITLAB_REPOS
This change basically reverts [1].  Oliver's patch allowing to set
SO_REUSEADDR, which is needed for D-GSM mslookup mDNS testing, has
been merged upstream.  No need to depend on our own fork anymore.

Change-Id: Idf96a64f3d5f7928ed0fb81f4a91e469df3a9adc
Related: [1] Ie7e1c3dbd67dba9079a5768e442faffc936fd7fa
Related: SYS#4618
2022-08-18 12:37:27 +00:00
Neels Hofmeyr a56e8fdc2d hnbgw: test PS RAB GTP mapping
Related: SYS#5895
Change-Id: I93c4689ddc016eb4eb25f8cbdd0142936c6f972b
2022-08-16 15:42:51 +02:00
Neels Hofmeyr a2d1d7a211 add library/PFCP_*, deps/PFCP
Will soon be used by new subdir 'upf' (test osmo-upf),
and by 'hnbgw' (test GTP mapping via UPF).

Related: SYS#5599
Change-Id: I0723b931b3f755ea291bffa2f27c34ba446c2f2f
2022-08-16 13:42:10 +00:00
Neels Hofmeyr 13b83db5db update various expected-results.xml
Change-Id: I850b79526145307246bca40c70ed8e4d586d8c68
2022-08-12 02:31:23 +00:00
Neels Hofmeyr e81ef42d05 msc: f_tc_mt_t310: detect MNCC failure explicitly
Helped me find a failure cause: instead of T_guard timeout, immediately
show an unexpected MNCC event.

Related: SYS#5066
Change-Id: I49a15142a4b6c51ca767a884c0574f96e01d7cb1
2022-08-12 02:30:54 +00:00
Neels Hofmeyr d8a4aee1c6 msc: f_tc_mt_t310: allow CRCX in either order
continued from Id0c98bc267daff352fc7db7712f967111970fd4d

Upcoming changes to osmo-msc move the CN side CRCX to an earlier point
in time, reversing that order. Introduce an 'interleave' to not care
about the ordering of MGCP and BSSAP messages.

Related: SYS#5066
Related: Ie433db1ba0c46d4b97538a969233c155cefac21c (osmo-msc)
Change-Id: I0ec348df08aa49ed58b3465de51b259fb74c0aea
2022-08-12 02:30:54 +00:00
Pau Espin 9b94149ef9 bsc: Set g_osmux_enabled_cn directly in the test
We want to add more options later on, and we don't want to be passing
all of them as params. Let's simply set the global fields directly in
the test and let f_init() use the confgured values.

Change-Id: I27b685c2c22cf876b5eba79cf8ad151a2643ecb1
2022-08-10 18:47:33 +00:00
Pau Espin f967afc2ec bsc: Rename s/use_osmux/use_osmux_cn/
That config is used to control the use of osmux between BSC<->MSC. Since
we'll add support for Osmux in BTS<->BSC, we want to test that in a
separate way. Let's rename it so that we can add a "use_osmux_bts" later
on.

Change-Id: I3bde4e6772c18043dd763d7747b5dbe40e0da3b8
2022-08-10 18:47:33 +00:00
Vadim Yanitskiy a2cd893d3d BTS_Tests: fix TC_rsl_ms_pwr_dyn_{up,ass_down,max}: reply received SACCH L1H
As was explained in [1], until recently we relied on trxcon sendig
dummy RR Measurement Reports with patched L1 SACCH Header values.
Now trxcon does not patch it for us, so we need to send Uplink
SACCH blocks with the correct L1H ourselves.

Revision 2 of [1] was successfully tested and proved to fix the
above-mentioned testcases.  However during code review I was asked
to make the statements sending Uplink SACCH blocks self-explanatory.

In revision 3 of [1] I modified the code to call f_send_meas_rep(),
which was introduced in [2], which as stated in the commit message
is using g_pars.l1_pars.{ms_power_level,ms_actual_ta} instead of
the values from received L1H.  Of course this does not work.

Add and use f_send_meas_rep_l1h(), which allows to send the given L1H.
Take a chance to add a log() statement, so that we can see what we Tx.

Change-Id: Ia79a0a7b06394bd34d0f40226cf40e6e8bd2ba35
Fixes: [1] I31dd6b9026d04403092256176f67785a0a6486ad
Related: [2] Ia5d0315e053702df5fa8dad8c6c66c11c9f3edcb
Related: OS#5635
2022-08-10 18:14:11 +07:00
Vadim Yanitskiy e2003d0c9c BTS_Tests: use f_send_meas_rep() in f_TC_ms_pwr_ctrl_{constant,pf_ewma}
Change-Id: Id80317d1e9de3873ab2d26470a3552b4f2b539b1
2022-08-10 17:38:07 +07:00
Vadim Yanitskiy 8a1685d549 BTS_Tests: populate SACCH cache in f_TC_ms_pwr_ctrl_{constant,pf_ewma}
There is a time window between activation of a dedicated channel and
receipt of a L1CTL_DATA_REQ with the first RR Measurement Report, in
which the L1 may need to start transmission on Uplink SACCH.

In this case the L1 is using a dummy SACCH block with hard-coded L1
SACCH header values and hard-coded Measurement Results.

Until recently we relied on implementation specific behavior of trxcon
patching the L1 SACCH header in hard-coded dummy SACCH block.  This
behavior was changed, so TC_ms_pwr_ctrl_{constant,pf_ewma} started to
fail.  Let's properly populate the SACCH cache to fix these TCs.

Change-Id: I89eb90815e86db466ea626f4c25f2634c1d942d5
Depends: osmocom-bb.git I0f467fc07cf844cc73465f235b36ba7d00788c9f
Related: OS#5635
2022-08-09 15:44:17 +00:00