Skip to content

Changes

Started by Oliver Smith
Started 3 mo 12 days ago
Queued 5 ms
Took 3 min 8 sec on build4-deb12build-ansible
ngap: Fix deviation in ASN1 from TS 38.413 version 17.5.0

I originally copied the ASN1 files from https://forge.etsi.org/rep/int/5g-core/ngap.git
directory ttcn/LibNGAP/lib/asn1, commit fa43d01e202379a969e991a9454d9c6c6930b5b5.

Apparently one file contained a deviation from the 3GPP content and it
was also fixed in ngap.git in 47e7239dd80f2f12a4cbcdd7977ca0a32356f3be.

I found out this problem when trying to use this ASN1 file to generate
new libfftranscode, which then failed to properly decode
DownlinkNASTransport due to the deviation.

Change-Id: I7d127998ea162a392f3381ebb1d198ad3c783a56
Pau Espin Pedrol at
library/ngap: Use titan native APER enc/dec

Related: OS#6490
Change-Id: I07b604fbd5d3665fdb48c4193ab58cffa7dd709a
Pau Espin Pedrol at
Cosmetic: deps/Makefile: update comments

Remove the part about caching logic of docker containers, as most
testsuites don't use docker-playground anymore. The main reason for
using commits here is that we have exact commits when doing regression
testing.

Replace the verbose license header with the SPDX version while at it.

Change-Id: I7eddc64aeab20292922ba013221679dfe952ff45
Oliver Smith at
5gc: Support PDU Session Establishment procedure

This commit adds initial support to issue a successful PDU Session
Establishment procedure towards the 5GC, getting a ready-to-use GTPU
session with IPv4 addr + TEID + UE IP address.

commit has to our nas.git fork is updated in order to have multiple
fixes and improvements needed to have everything working fine.

Related: SYS#7073
Change-Id: If0769afd07a4bae7778d7a7c347cebaa5909b5f8
Pau Espin Pedrol at
Split GTPv1U out of GTPv2_Emulation

GTPv1U and GTPv2C are 2 different protocols, working on 2 different
ports, on 2 different sockets.
Hence, it makes no sense to put them together, since some tests may want
to use only the control-plane, others may want to use the user-plane,
etc.
Morevoer, GTPv1U can be used together with both GTPv2C anf GTPv1C.

This commit also fixes the confusion where TEIC and TEID were not
properly separated in GTPv2_Emulation.

Change-Id: Ia45307107753294c6761cb588f0ab769821eb213
Pau Espin Pedrol at
GTP1vU_Emulation: Make UECUPS support optional

Some users may/do want to use the simple UDP/GTPU socket mode, so they
don't need to depend on all UECUPS code.

Change-Id: I3b4671d8e637f70f790b08ed8e3b5145e7a95703
Pau Espin Pedrol at
gbproxy: Drop unneeded GTP dependencies

Change-Id: Id282bf63ae4abe8f2e97d84146db1f48198dacf7
Pau Espin Pedrol at
GTPv1U_Emulation: support multiple client ports per GTP1U_ConnHdlr

This feature is already present in GTP1U code of GTP_Emulation.
That part of the code will be removed and ported to use
GTPv1U_Emulation, so we need to also support this feature here.

Change-Id: I10ce33f30a2da5159f8040725df619844a71d6bc
Pau Espin Pedrol at
5gc: Rework init code

* Move T_Guard to MTC, there's no need to have multiple of them (one per
  ConnHdlr).
* Call f_init_handler() internally so it doesn't need to be called by
  each ConnHdlr test.
* Change function attribute friend to private

Change-Id: I71e5d552a6c0089345982a403285f66a92397413
Pau Espin Pedrol at
5gc: C5G_Tests.cfg: Set module name of multiple module params

Change-Id: I936240af988d4727516b5722dd360a907d70eee7
Pau Espin Pedrol at
Move ConnHdlr logic to its own file

Similar to what we do in other testsuites, since we start to have
considrable amount of logic.

Change-Id: If7edf8ee63c71fbf949e2d340cf3881fd8e3ba41
Pau Espin Pedrol at
pgw: Move to library/ high level APIs to run commands over UECUPS

This way the code can be reused by other testsuites more easily.

Change-Id: I49c98fd423e47e16ddfb9ae4612b18db21ca3fa4
Pau Espin Pedrol at
pgw: Use templates to generate UECUPS commands

This way if commands are extended with optional fields, we don't need to
update these since default params in templates will take care of it.

Related: SYS#7073
Depends: osmo-uecups.git Change-Id If524b0a122d1217fcd39e4633835a1a7d0620c7a
Change-Id: I4de6623318fe2abf9807702251fe420eb14de2cc
Pau Espin Pedrol at
5gc: Introduce test TC_register_ping4

osmo-uecups is used to set up a GTPv1U tundev with the PDU session
params configured over NGAP/NAS, similar to what is already done in
PGW_Tests.

Depends: osmo-uecups.git Change-Id I6262c3dfbf774b361aadf0aa53ce09b5fdc38da4
Change-Id: I66737a94eedcf4184aa59bbbd7cc700d1e9d1521
Pau Espin Pedrol at
library/ngap: Fix wrong procedureCode in PDUSessionResourceReleaseCommand templates

Change-Id: Ia4b0cacf8e3f859820d4b5e23d73f38bb5b7fbfd
Pau Espin Pedrol at
testenv: Dockerfile: use debian archive for deb10 libssl pkg

As Debian 10 is EOL, this debian 10 package we are still using here to
make mongodb work is getting removed from the mirrors. Currently some
still have it, some have deleted it already. Use the archive instead.

Related: docker-playground Ia447d850d38c662aac567aa88685d984c0b42238
Change-Id: I1a81e8e1485c810396f1714e6ef0485878fab6ec
Oliver Smith at
testenv: Add $install_dir/usr/bin to $PATH

When building programs from source, don't look only in $install_dir/bin,
but also in $install_dir/usr/bin for the binaries. osmo-s1gw installs to
usr/bin with recent changes and other programs may do this too.

Related: osmo-s1gw I5681ca103daf1c497218b4513b0ca97b1aae03d3
Change-Id: I8d652dba94bbd44217a3034ac012b6568941347d
Oliver Smith at
s1gw/testenv: adjust to use new launcher script

osmo-s1gw now gets started through a launcher script.

Depends: osmo-s1gw I5681ca103daf1c497218b4513b0ca97b1aae03d3
Change-Id: Ief1579154bf46b9bc2551535ede3e1f14456d65d
Oliver Smith at
testenv: podman: add libnftables-dev

This is required for building osmo-s1gw from source in podman,
otherwise:

  /home/user/.cache/osmo-ttcn3-testenv/podman/make3/osmo-s1gw/default/lib/enftables/c_src/enftables.c:16:10: fatal error: nftables/libnftables.h: No such file or directory
     16 | #include <nftables/libnftables.h>
        |          ^~~~~~~~~~~~~~~~~~~~~~~~
  compilation terminated.

Change-Id: I0ae94f73f0875048d9a71d1582627e57e60425c6
Oliver Smith at
library/ngap: Support passing optional NAS-PDU to PDUSessionResourceReleaseCommand

Change-Id: I5f516f33824a83c0eaeb2c0decd82409b786867e
Pau Espin Pedrol at
NGAP_Functions.ttcn: Fix wrong offset of NGAP_ID_pair in uEContextReleaseCommand

Change-Id: I2302bebf75530f574a7fe2647b1eafcc4d5fd7df
Pau Espin Pedrol at
5gc: Implement PDU Session Release procedure

Related: SYS#7073
Change-Id: If79cb0c97008e7a9885bb548a3d2e67e41ba170f
Pau Espin Pedrol at
library: Comment out debugging for NGAP/5G-NAS

The current NGAP and 5G auth code is now working fine, so disable debug
logging. Keep it commented out so it can be re-enabled at any time if
some related topic needs to be debugged (will eventually happen).

Change-Id: I4250766644742f0fd11ca5e24b1a1a581dc81b4b
Pau Espin Pedrol at
5gc: Introduce test TC_ng_register_ping4_256

open5gs-dbctl tool is called in batches of multiple IMSIs to speed up
setup, since each call takes fractions of seconds to complete.
mongosh called by open5gs-dbctl actually uses quite a lot of CPU and RAM
resources, hence limit the amount of parallel runs to a fair amount (eg.
running the 256 of them in parallel froze my workstation with 16GB of
RAM).

Change-Id: I7282fa3c1a474c4b7dceeb5e358547dcdbd1fea6
Pau Espin Pedrol at
5gc: Introduce test TC_periodic_registration_updating

Related: SYS#7073
Change-Id: I63da25a3927cb459563d4325adc690beb8a67451
Pau Espin Pedrol at
{S1AP,NGAP}_Emulation: Fix indentation

Change-Id: Ifb2e4e3fc2d3ef4a76f2b0e906b12d0f740e9cdd
Pau Espin Pedrol at
{S1AP,NGAP}_Emulation: Fix using the value of an optional field containing omit

This was triggered in NGAP_Emulation during run of C5G_Tests complete
testusite, when running TC_ng_register_ping4_256.

Titan apparently doesn't like using a field set as omit in a field of a
record during match().

Same fix is applied for S1AP_Emulation since they basically use the same
logic.

Change-Id: I4812c2e9eeeadc26ad057cd8019f7570e4a16155
Pau Espin Pedrol at
{S1AP,NGAP}_Emulation: Simplify lookup code

Simplify code matching IDs. Explicitly test, log and exit function
called with both IDs passed as "omit".

Change-Id: I02f33c191d131c6325f3608ceec80be6f036aa84
Pau Espin Pedrol at
NGAP_Templates: Fixes and improvements for UEContextReleaseComplete

The existing templates for UEContextReleaseComplete were completelly
wrong, probably due to copy-paste when introducing them. This commit
fixes all those problems and allows passing optional parameters.

* procedureCode was wrong
* Criticality of several fields was wrong
* Type of resource list was wrong, and marked as mandatory while it was
  optional.

Change-Id: I50da7cd4cb15d8e6b2c68b21a4e4be93e3973593
Pau Espin Pedrol at
5gc: Implement UE-initiated de-registration procedure

Change-Id: Iab438d5a7cc5f2ba58943e4568c1fb5e5f41f99d
Related: SYS#7073
Pau Espin Pedrol at
testenv: osmo_dev: remove unused limit_section arg

Remove the unused limit_section argument in testenv.osmo_dev.make(). The
idea was to use osmo-dev to build programs where no packages are
available when using --binary-packages, but this didn't work because
when using --binary-packages, we must install all package dependencies
from the binary repository (so testing nightly / latest use the expected
library versions). Nowadays this use case is handled by
podman_install.from_source_* functions without using osmo-dev.

Change-Id: Ib09ffd0e269c58acd431bdbb5cc7cdcec2d36359
Oliver Smith at
testenv/osmo-dev: split get_targets to own func

Split the code for getting osmo-dev targets into a separate function, so
this can be reused in the next patch.

Change-Id: I2bd7c05102ca472614289870957cdca335c01eaf
Oliver Smith at
testenv: pass targets to osmo-dev's gen_makefile

Pass the targets we are about to build to osmo-dev's gen_makefile
script. This has two advantages:

1) Check early if a target isn't known by the current osmo-dev version,
   displaying a useful error to the user instead of just failing during
   make later on:

     ERROR: filter_projects_deps_targets: can't find project osmo-new-project in projects_deps!

     [testenv] gen_makefile.py from osmo-dev failed!
     [testenv] Your osmo-dev.git clone might be outdated, try:
     [testenv] $ git -C /home/user/code/osmo-dev pull

2) Parsing the generated Makefile when running "make" after generating
   it doesn't cause a noticable delay anymore. On my machine (with many
   Osmocom git repos cloned in osmo-dev's src dir) it went from several
   seconds to instantly.

Depends: osmo-dev I89bb60e94dd03606dbba5a3609d5e1a95993af5b
Change-Id: Ib2d8802b305f145d27aab3c1cc3129709b93d93d
Oliver Smith at
Makefile: add 'clean-logs' target

When running tests manually I oftentimes end up with hundreds of
*.log files in testsuite directories.  The present patch adds a
convenience target for removing them.

Change-Id: Id0597f9eeea9e128ce38a2b19f2126c729e71ffd
Vadim Yanitskiy at
msc: add TC_silent_call_{start_stop,active_conn}

This patch adds testcases for the silent-call feature:

* MSC_Tests.TC_silent_call_start_stop
  Test starting and stopping silent call via the VTY.
* MSC_Tests.TC_silent_call_active_conn
  Test initiating a silent call while there's an active connection.
  The MSC is expected to be smart and reject such an attempt.

Change-Id: I3ef22fbb5a05f69cc8aea7f42e05f6e1d6c4a8b6
Related: osmo-msc.git I93913d189800d71f82c013b6e946bd63db362f65
Related: osmo-msc.git I52b3be26c61cadacc4783b5c324809ecd6906b36
Vadim Yanitskiy at
testenv: Dockerfile: fix Suites: stable-backports

Using "stable-backports" broke now that Debian 13 is out. Use
"bookworm-backports" instead.

Fix for:
  E: The value 'bookworm-backports' is invalid for APT::Default-Release as such a release is not available in the sources

Change-Id: Icc46b6dc2493806dc12f0ff442abd70fe5b48eb8
Oliver Smith at
ngap: Add missing mandatory IE Cause to m_n2_UEContextReleaseRequest

Change-Id: Ib7d87f957e469a23448e35fd82a697d1698c7da7
Pau Espin Pedrol at
ngap: Add template for UEContextReleaseReq without PDU Session List

That's the only optional IE in the message. Add a separate template to
be able to transmit with that IE set, similar to what's already done in
m_n2_InitialContextSetupRequest_withPDUSessionList().

Change-Id: I0f1a549103b70bcd373dcd4c688761d3eeef10a6
Pau Espin Pedrol at
5gc: Obtain amf_id from NGAP_Emulation

This will be needed in a follow-up commit in order to be able to
transmit UE Context Release Request.

Change-Id: I49cb6d7fe9f18734c49bb49ecceb671e8122ce88
Pau Espin Pedrol at
5gc: Place PDU Session params into its own subrecord

This way we properly split between layers, plus the fact that we'll
probably want to hold several concurrent pdu sessions in each UE in the
future.

Change-Id: Ibb0c8d3f0901d53e4aa75855e602234410fd00f9
Pau Espin Pedrol at
5gc: Add tests for UE release context request procedure

Change-Id: Icaaeb2923fdcaba47a72ed0aedc5661f68c03774
Pau Espin Pedrol at
5gc: Add helper to get incremental PTI field

Change-Id: I9d32024b58799bbd3ef547cdc73ee73d7f7275d2
Pau Espin Pedrol at
GSUP Templates: fix empty destination_name in GSUP ISD/UL

The destination_name TLV should be either set with a valid name
or not present, but a field with length 0 shouldn't be used.

Change-Id: Ia89b5a82665e407fa578e5209fbcde0676326df0
lynxis at
GSUP_Templates: ts_GSUP_UL_REQ: add template scopes

Allow to omit the source_name TLV in GSUP UL Request.
The whole ts_GSUP_UL_REQ must resolve to a value.

Change-Id: I250960a1e1c19dfa1efa81f6bbc93efa07cb225c
lynxis at
GSUP_Templates: fix whitespace issues

Change-Id: I03be75063a71153bd2881afd1d741454c508fada
lynxis at
BSSGP_ConnHdlr: f_service_request: allow to define if a Service Accept is expected

A SecurityModeCommand is defined as an implicit Service Accept when the UE
is in PMM_IDLE (meaning, having no Iu signalling connection)

Change-Id: I5c190db28263c530a8eea188bf570a58eaffdd4d
lynxis at
MSC Tests: add TC_gsup_lu_and_det: do a LU, Detach and expect GSUP MS Purge

Currently the MSC/VLR doesn't inform the HLR when a MS detaches.

Change-Id: I9e87537efc2c921fa860539a706316ed410b45d5
lynxis at
ngap: Fix wrong IE Id in m_n2_PDUSessionResourceModifyResponse()

Change-Id: I13547e548e5323fe54340393cbe9f333f10c5969
Pau Espin Pedrol at
Makefile: DIR_clean_template: clean depends on Makefile

Change-Id: I4934f345f4a1d54fa939143d46033c1ef6751aba
Vadim Yanitskiy at
NGAP_Templates: Introduce generic NGSetupFailure template f_mw_n2_NGSetupFailure()

Use one template containing all possible optional IEs instead of having
different templates containing optional subsets.

Change-Id: I39302624212b907a5267b8104176c2bbb96bd2ae
Pau Espin Pedrol at
NGAP_Templates: Improve InitialContextSetupRequest template

That message has tons of optional fields. Better have 1 big generic
template than dozens of different templates.

Change-Id: Ib87221455ebc9f59ab0810b28a6509cdcecc81c7
Pau Espin Pedrol at
testenv: install curl backport only for bookworm

Change-Id: Ifeeea010fb13bfd65e1d3659a3c43fc4acf07795
Oliver Smith at
Cosmetic: testenv: make builddir_env more readable

Change-Id: I7bbd14bd91c97bc37a163018217b104ace0e1a53
Oliver Smith at
msc: also execute evil USSD tests for -latest

osmo-msc v1.14.0 is out, so we can safely execute these tests.

Change-Id: Ia603bcf434a4092c5fc347300b755be92820ed3e
laforge at
testenv: use separate cache dirs per distro

Change-Id: I0f1c05bb4d8cfababc24477976abf8a0baa3daba
Oliver Smith at
testenv: init podman: add --distro arg

Allow building the podman image for another distribution. This was
mostly implemented already, but due to the missing --distro argument for
"./testenv.py init podman" it could not be used yet.

Change-Id: Iff59b5d403e88046a3f98438394e1e02a36e7c0a
Oliver Smith at
testenv: debian 13: fix installing libgcc

Use a wildcard to install the proper libgcc-*-dev package (libgcc-11-dev
for debian bookworm, libgcc-13-dev for trixie).

Change-Id: I9992d8cf8cd68a9e3ec9178909e0766dbd5d12ad
Oliver Smith at
testenv: debian 13: fix installing eclipse-titan

Use the current debian version instead of hardcoding Debian_12.

Change-Id: I56be4e3e72a1ad4590e904f9a48d90aa635c9980
Oliver Smith at
testenv: check for --distro without --podman

The --distro option only makes sense with --podman, complain if it is
used without --podman.

Change-Id: I1b7b26320c65d498a1e812f85f0b98eda95be783
Oliver Smith at
testenv: check value of --distro early

Make sure that the value for --distro is supported early on, instead of
only checking it if --binary-repo is set while trying to add the binary
repository.

Change-Id: I37493f26d71e70a19f4a19b3bbda972c03c84905
Oliver Smith at
testenv: add debian:trixie

Change-Id: Ib62851960724c17f9adddf54a2fc39adef911d32
Oliver Smith at
testenv: enable_binary_repo: configure apt pin

Add an apt-pin to ensure packages from the Osmocom repositories get
preferred over Debian's packages. I just ran into this with osmo-mgw,
where we have 1.4.0 in osmocom:latest and Debian 13 has 1.14.0+dfsg1-2,
which counts as higher version. This results in the wrong package being
selected, and also in an error later on when trying to install related
debug packages from our repository:

  The following packages have unmet dependencies:
   osmo-mgw-dbgsym : Depends: osmo-mgw (= 1.14.0) but 1.14.0+dfsg1-2 is to be installed

Change-Id: I3a45de277bbd5299c8b840680b56b52a8731caa4
Oliver Smith at
testenv: set default distro to debian:trixie

Related: OS#6826
Change-Id: Ib9c5dafaa7b17e435f61fbedfd92393c0a767f34
Oliver Smith at
testenv: qemu: ignore builtin modules

In debian 13, the virtio_pci kernel module is now builtin. Adjust the
code paths that add kernel modules to the initramfs and load them to
ignore builtin modules.

This fixes the ttcn3-ggsn-test-kernel-latest job job, which currently
fails with:

  + modprobe -a --dry-run --show-depends --set-version=6.12.41+deb13-amd64 virtio_net virtio_pci
  + sort -u
  + cut -d   -f 2
  + local files=virtio_pci
  /lib/modules/6.12.41+deb13-amd64/kernel/drivers/net/net_failover.ko.xz
  /lib/modules/6.12.41+deb13-amd64/kernel/drivers/net/virtio_net.ko.xz
  /lib/modules/6.12.41+deb13-amd64/kernel/net/core/failover.ko.xz
  + qemu_initrd_add_file virtio_pci /lib/modules/6.12.41+deb13-amd64/kernel/drivers/net/net_failover.ko.xz /lib/modules/6.12.41+deb13-amd64/kernel/drivers/net/virtio_net.ko.xz /lib/modules/6.12.41+deb13-amd64/kernel/net/core/failover.ko.xz /usr/lib/modules/6.12.41+deb13-amd64/modules.alias
  + local i
  + local cp=cp --no-dereference --recursive --parents
  + cp --no-dereference --recursive --parents virtio_pci <https://jenkins.osmocom.org/jenkins/job/ttcn3-ggsn-test-kernel-latest/1665/artifact/logs/osmo_ggsn_v4_only/ggsn/_initrd>
  cp: cannot stat 'virtio_pci': No such file or directory

Change-Id: Ied8acf18d0a1f47fac805619d15896918a365ff2
Oliver Smith at
testenv: fix TESTENV_INSTALL_DIR for --binary-repo

When --binary-repo is set, "/" must be used as install directory,
without any suffix for the distribution.

Fix for:
  realpath: /-debian-trixie/usr/lib/osmo-s1gw: No such file or directory

Fixes: 2152d512 ("testenv: use separate cache dirs per distro")
Change-Id: I1e1ca65fd6a7d77c751dd7138015ff474f8ae576
Oliver Smith at
testenv: fix missing hasattr check

Fix that commands without a --distro argument ("./testenv.py init osmo-dev"
and "./testenv.py clean") fail with:

  AttributeError: 'Namespace' object has no attribute 'distro'

Fixes: 8d21add6 ("testenv: check for --distro without --podman")
Change-Id: I138fda5f5807588428bba4eb1593b887fe7357c9
Oliver Smith at
testenv: use separate install dir for --asan

The --asan flag builds all Osmocom components with address sanitizer
enabled. Use a separate install dir from the non-asan version to ensure
we don't end up with using non-asan versions. (A separate make dir is
already used.)

Bump make_dir_version to avoid having markers for already installed
binaries / libraries in the make dir, which are invalid now for
asan-builds as we switched the install dir.

Fixes: c3657172 ("testenv: add run --asan")
Change-Id: Ic75452b75d4c3ee8045b68353830b5532e1ce90e
Oliver Smith at
ranap: Support Tx GlobalRNC-ID during RANAP RESET (ACK)

This commit doesn't affect the behavior of any existing testsuite yet,
it only updates the templates and adds a RanOps param to be able to pass
a GlobalRNC-Id to RAN_Emulation.

A follow-up commit will change SGSN_Tests to append GlobalRNC-Id to
RANAP Reset when sending towards SGSN, since it's mandatory for an RNC
to set it according to 3GPP TS 25.413 8.26.2.2.

Change-Id: I0628e412bdff6ed8eefe9051ec351fbd1d0b634f
Pau Espin Pedrol at
Include GlobalRNC-ID IE during Tx RANAP Reset towards SGSN

An RNC shall include this IE during RANAP Reset, as specified in
3GPP TS 25.413 8.26.2.2.

Change-Id: Ic16817a2064fa87b80a81b07868005069d67aec2
Pau Espin Pedrol at
testenv: don't use all RAM in 5gc testsuite build

When building the 5gc testsuite with as many parallel jobs as CPU cores
are available (the default), on at least Pau's and my system, all RAM
gets consumed and the system becomes unusable. On other systems, an
out-of-memory killer might kill the compiler, which is also not great.
This can currently only be avoided if the user remembers to pass "-j4"
to testenv, to ensure that only 4 jobs run in parallel.

Add a new max_jobs_per_gb_ram= option to 5gc/testenv.cfg. Set it to 0.3,
so on e.g. systems with 15 GiB of RAM, we get 4 jobs as maximum.

Change-Id: I1b9c9a2e3fa244337342e95457ac6d3a8caa0ae6
Oliver Smith at
sgsn: Add suport to obtain statsd output

It will be used in a follow-up commit in TC_stat_rnc_sctp_disconnected.

This new test infrastructure can still be used with osmo-sgsn latest
since it already initialized the statsd VTY commands despite having no
osmo_stats in use.

Change-Id: Ic86ce75ea700d05fc65fcea3cdab7b7eaac12069
Pau Espin Pedrol at
sgsn: TC_stat_bsc_sctp_disconnected: validate using StatsD

Similar to what we alreay do in counterpart
MSC_Tests_iu.TC_stat_bsc_sctp_disconnected.

Related: OS#3403
Depends: osmo-sgsn.git Change-Id I51b5227d92027f1251dc4debbbf59737e7c1a9ba
Change-Id: I1ff8c51a73556357c5a5e97bc2a0edec30f1cf03
Pau Espin Pedrol at
library/SGsAP_CodecPort: Properly fill in ASP_Send record

Otherwise it showed up as unbound and errors about wrong protocol showed
up. According to osmo-msc code ppid 0 is expected, so set it.

Change-Id: I6434a6522af3cae35824df5931ad5c33d79c505b
Pau Espin Pedrol at
mme: Rename GTP related functions

Better express what they are about. For instance, they only work on
GTPC, not GTPU.

Change-Id: I84b25b2c64f2d5b473e08949e8501dc5dae5b393
Pau Espin Pedrol at
mme: Introduce f_init() helper

Change-Id: I89f0dfb9c79c3edb7b42751a76f36a983da59c1d
Pau Espin Pedrol at
mme: Move g_Tguard to MTC_CT

There's no need to have Tguard per ConnHdlr, one in the MTC_CT is enough
and simpler to handle.

Furthermore, it allows to early arm it, in case something fails during
f_init().

Change-Id: I8b766ad83030ac5c92fe64b7ea2df35468b23fc0
Pau Espin Pedrol at
mme: Call f_init_handler() inside f_start_handler_with_pars()

Change-Id: I9d05c340b173cbab08bbd066d7261341d902d455
Pau Espin Pedrol at
mme: Split ConnHdlr to its own file

Change-Id: I322e679fa252388649b897a13d2d4a325212a71a
Pau Espin Pedrol at
Add templates for S1AP Handover procedure

These templates include handover preperation and resource allocation for
S1 handover procedure. It supports mandatory information elements only
at this time.

Related: SYS#7309
Change-Id: Ib8b8aee0665a4f6644287b802f5e941bd82128f6
Vadim Yanitskiy at
S1GW tests: Add test cases for S1 handover procedure

The test cases expect the handover preparation and resource allocation
to be passed on correctly with expected modifcation of E-RABs.

Related: SYS#7309
Change-Id: Id349c84749f7e897defa8cfd2ecd2c1f2fb52fc7
Vadim Yanitskiy at
mme: Set EPS Attach Type to valid value 'EPS Attach'

Previous value 0 is unused, see TS 3GPP TS 24.301 9.9.3.11.

Change-Id: I7b0c028620ee1ff6b819cce95b39fb93a70d4106
Pau Espin Pedrol at
asterisk/gen_links.sh: fix broken symlink

There exist two files named `PIPEasp_Templates.ttcn`:

* library/PIPEasp_Templates.ttcn
* deps/titan.TestPorts.PIPEasp/demo/PIPEasp_Templates.ttcn

We use our own one from the library, not the demo one.

In `asterisk/gen_links.sh` we first create a broken symlink, and then
overwrite it with a valid symlink to `library/PIPEasp_Templates.ttcn`.
This should not be a problem, since `gen_links.inc.sh` is calling ln
with flags `-sf`, yet we saw a build failure in Jenkins:

https://jenkins.osmocom.org/jenkins/view/TTCN3/job/ttcn3-asterisk-ims-ue-test/559/consoleText

------
> [3/5] RUN TTCN3-DOCKER-PREPARE "master" asterisk:
0.463 '/ttcn3-dumpcap-stop.sh' -> '/osmo-ttcn3-hacks/ttcn3-dumpcap-stop.sh'
0.463 + ln -sv /osmo-ttcn3-hacks/ttcn3-tcpdump-stop.sh /ttcn3-tcpdump-stop.sh
0.464 '/ttcn3-tcpdump-stop.sh' -> '/osmo-ttcn3-hacks/ttcn3-tcpdump-stop.sh'
0.465 + ln -sv /osmo-ttcn3-hacks/_scripts /_scripts
0.466 '/_scripts' -> '/osmo-ttcn3-hacks/_scripts'
0.466 + make asterisk
0.581 (cd asterisk && ./gen_links.sh && ./regen_makefile.sh)
0.627 ttcn3_makefilegen: error: Cannot find any source file for argument `PIPEasp_Templates.ttcn'.
0.631 ttcn3_makefilegen: warning: TTCN-3 preprocessing (option `-p') is enabled,
                                  but no TTCN-3 files to be preprocessed were given for the Makefile.
0.632 make: *** [Makefile:131: _build/asterisk/Makefile] Error 1
------

Change-Id: Id79bd056716c34c4de02aba68caab95d185e6e48
Vadim Yanitskiy at
mme: Mark GTP and diameter emulations alive

Change-Id: I53851dc981e9395e025cd5d2fb0122bea49564ee
Pau Espin Pedrol at
library/s1ap: Support receiving UEContextModificationRequest

Change-Id: Iadb80eea7281b3bdf3359b0e2956e18bdb208207
Pau Espin Pedrol at
mme: Add missing tests to expected-results.xml

Change-Id: I9fbe1dd102268558f4b360dc8e870117e4e17096
Pau Espin Pedrol at
library/NAS_EPS_Templates.ttcn: Add templates to handle CS Fallback related procedures

These will be used to test MT CS call over SGsAP in MME_Tests_SGsAP.

Change-Id: If8884224e353a9883200c84d737e63c3a3ca9b33
Pau Espin Pedrol at
s1ap/S1AP_Templates.ttcn: Add templates to handle CS Fallback related procedures

These will be used to test MT CS call over SGsAP in MME_Tests_SGsAP.

Change-Id: I87fa7d988bec90ccade2f40ac4d2a0924059058e
Pau Espin Pedrol at
msc: CC SETUP MT speech: verify bearer capabilities

Verify that the MSC sends the bearer capability IE from 3GPP TS 24.008 §
D.1.2 for speech in the network to MS direction, instead of allowing
e.g. what osmo-msc master and latest release currently do:

- Filling out radio channel requirement the same way as the MS to
   Network direction, which is wrong for the Network to MS direction:
   "Bits 6 and 7 are spare bits. The sending side (i.e. the network)
   shall set bit 7 to value 0 and bit 6 to value 1." (3GPP TS 24.008
   Table 10.5.102)

- Sending a speech list in the Network to MS direction, which seems to
   be allowed in theory and MS are supposed to ignore it (end of Table
   10.5.103) but causes bugs in some MS in practice. Therefore it is
   better to ensure that osmo-msc does not send it (OS#6656).

Implement this in f_mt_call_complete(), which gets used e.g. by
TC_lu_and_mt_call.

Depends: osmo-msc I7046e9244fd9d4301ee2c4df1147a619f753739c
Related: OS#6657, OS#6655, OS#6656
Change-Id: I8fd33cf2f7fb8a1c34851ecf54fccddd2efd0536
Oliver Smith at
Add optonal e-RAB lists to HANDOVER messages

These lists are required to test release of e-RABs during handover
prparation and indication of failed e-RABS during handover resource
allocation.

New templates for the new lists and list items are added.

Related: SYS#7309
Change-Id: I78d2fa8e72bb672674727a01d5c5a9aaf31cab7b
jolly at
S1GW: Add test case to test release of e-RABs during handover preperation

HANDOVER COMMAND allows e-EABs to be forwarded or to be released. The
test provides two lists and expects osmo-s1gw to release only those
e-RABs that are included int the "E-RABs to Release List" IE.

Related: SYS#7309
Change-Id: Ic70ba19c0a6e349f63aae124607d075b6d19e779
jolly at
S1GW: Add test case to test release of failed e-RABs during handover resource allocation

HANDOVER REQUEST ACKNOWLEDGE indicates admitted and failed eRABs. The
test provides two lists and expects osmo-s1gw to release only those
e-RABs that are included int the "E-RABs Failed to Setup List" IE.

Related: SYS#7309
Change-Id: Ic14f560ae16b8386e58ac85f8af53b19d7c7a5c9
jolly at
SGsAP_Emulation: Introduce proper support for server-mode

Prior to this commit, only initial (not really useful) SCTP server-mode
support existed in SGsAP_Emulation.
This is basically because MSC_Tests uses the SCTP client-mode, and
MME_Tests_SGsAP were not yet in a fully working state.

In server-mode, we have a conn_id for the listening socket and a conn_id
for the accepted socket; track them properly.
Moreover, in server node we definetly need some sort of event to wait
for the client to connect; introduce it.
Based on existing work in Iuh_Emulation.

Change-Id: Iccf4ac96c56e947529f0ffc06428e2325a115d50
Pau Espin Pedrol at
mme: Initial working state for MME_Tests_SGsAP.ttcn tests

MME_Tests_SGsAP.ttcn tests were introduced to the repository many years
ago (~2019), but they were mostly WIP and were never run as part of the
regular testsuite.

This commit reworks and extends previous work to get them up to date
with current MME_Tests and makes most of them passing.

TC_sgsap_alert_* tests are still in WIP and will be fixed in follow-up
work.

Related: OS#6850
Change-Id: If07f1a67eb4213985da82afec94adb08786a0980
Pau Espin Pedrol at
mme: Store and check {mme,enb}_ue_id over S1AP

* Generate a different enb_ue_id based on imsi_suffix, and store it
  during startup of ConnHdlr.
* Validate the MME sends the expected message to the expected enb_ue_id.
* Store the mme_ue_id and validate also that MME keeps using it.

A new procedure is added to S1AP_Emulation, similar to what already
exists in NGAP_Emulation, to obtain the mme_ue_id allocated by the peer.
This is needed because upon rx of DL NAS Transport messages we only
receive the upper layer NAS decoded in the Connhdlr, so we can't store
and track the MME ID early enough.

Change-Id: I62902db3851f48ce9f80cb1cc84797735c0091de
Pau Espin Pedrol at
mme: Introduce test TC_s1ap_tau_periodic

Change-Id: I261c3421f6a082e0d610ece4cc96d3e031022891
Pau Espin Pedrol at
mme: Fix implementation of TC_sgsap_alert*

Change-Id: I717c6f153ae77874170bf03e7a6c7bb628d12dba
Pau Espin Pedrol at
*/osmo-*.cfg: make stderr logging consistent

Use the following options for stderr logging in all config, to make the
output consistent and readable (e.g. no hex categories, no long paths to
source files at the end of log lines). Use the same order of parameters
in all files.

  log stderr
   logging filter all 1
   logging color 1
   logging timestamp 1
   logging print extended-timestamp 1
   logging print file basename last
   logging print category 1
   logging print category-hex 0
   logging print level 1

Related: OS#6272
Change-Id: I229cce244719b3ce61afb6df33fe0ca20dc22456
laforge at
es2p_Types_JSON: add ES2p JSON encoder/decoder

This patch adds ES2p encoder/decoder functions.

Change-Id: Ic6e230bdd0b2c43a5183cd1f53b930e6f3c53e66
Related: SYS#7339
laforge at
es12_Types_JSON: add ES12 JSON encoder/decoder

This patch adds ES12 encoder/decoder functions.

Related: SYS#7339
Change-Id: I875cbb3a6dab6ac1eac5df1199f6fb71738a744e
laforge at
stp: define PC for IPA ASP peers

This allows explicitly matching what's configured in osmo-stp's
"routing-key" & "point-code override dpc" VTY configs for each AS.
This in turn makes the osmo-stp cfg file easy to understand by looking
at the peer's (TTCN3) configuration.

There's no need to configure "point-code override opc" in the osmo-stp
since by default the PC declared in the routing-key is used to apply an
OPC on incoming messages over an IPA ASP.

Once we have the PC available in the TTCN3 config file, we can use it
inside IPA<->M3UA test to put the value in generated M3UA messages
(there's no visible changes in IPA ones because ofc the IPA signalling
doesn't include the PC in the messages).

Change-Id: I9cca2f4dd38e03ab1d259ffafd904b8890778883
Pau Espin Pedrol at
cosmetic: RANAP_CodecPort.ttcn: Fix trailing whitespace

Change-Id: Ibad0a23cfc15dd9d9a03e78ca64eb26b4ecee6d8
Pau Espin Pedrol at
Introduce TCAP asn enc/dec

ASN.1 files obtained from libosmo-asn1-tcap.git
a92fd1a6206832b626aa2a5c841b890ca37e4bd0.

Related: SYS#5423
Change-Id: Iae7f92cde02e5da966966bc95f9b74feec51958d
Pau Espin Pedrol at
tcap: Add initial templates

Change-Id: Ibc471733554c75b7c494b2bd4126232dd8c0553c
Pau Espin Pedrol at
smlc: Remove unneeded RAN_Adapter.ttcnpp from gen_links.sh

Change-Id: I332c09c65a9dba40bca2851eb34cd3edf8da8727
Pau Espin Pedrol at
sgsn: Remove unnedeed redefinition of RAN_Configurations

This is already defined in the same way in RAN_Adapter.ttcn, where
record RAN_Configuration is also defined.

Change-Id: Ia2193c2b7e71eb544e6aba75326babd28962a0f9
Pau Espin Pedrol at
Move RAN_Configurations module parameter definition to *_Tests.default

This way we can easily tweak values, which usually involve other
programs' config like osmo-stp, without needing to recompile ttcn-3.
Furthermore, we avoid ending up in the situation where the .ttcn file
contains invalid data which is always overridden in .default, like it
happened in MSC_Tests.ttcn.

Change-Id: Id7e77a2ecf68520a853dc35fe0013a0611e744a1
Pau Espin Pedrol at
*/gen_links.sh: fix wrong SDP_EncDec.cc symlink

SDP_EncDec.cc is not in titan.Libraries.TCCUsefulFunctions, it is in
titan.ProtocolModules.SDP. The gen_links.sh scripts had instructions to
symlink both the wrong and right location of SDP_EncDec.cc, and most of
the time the right location would be symlinked.

When the wrong location was symlinked, the next command
regen_makefile.sh would fail with:

  ttcn3_makefilegen: error: Cannot find any source file for argument `SDP_EncDec.cc'.

Change-Id: I5799ee04b9897fb58a92cf222bcffbf97275d7c1
Oliver Smith at
*/gen_links: remove TCCOpenSecurity_Functions.hh

The file TCCOpenSecurity_Functions.hh does not exist in a fresh clone of
titan.Libraries.TCCUsefulFunctions. Currently it only gets created after
gen_links.sh ran, created the symlink (to the not yet existing file) and
then ttcn3_compiler writes to it. Adjust the gen_links files to not
create this broken symlink.

Related: https://gitlab.eclipse.org/eclipse/titan/titan.Libraries.TCCUsefulFunctions/-/tree/master/src
Change-Id: Idab86fa1deb0256737167767ee7f5f2b36018df4
Oliver Smith at
buildsystem/gen_links: catch broken symlinks

Tweak gen_links() to verify that each symlink target exists. If the
target does not exist, abort with an error:

  ERROR in msc/gen_links.sh:

    File not found:
      ../deps/titan.Libraries.TCCUsefulFunctions/src/TCCOpenSecurity_Functions.hh

    Section:
      DIR=../deps/titan.Libraries.TCCUsefulFunctions/src
      FILES="…TCCOpenSecurity_Functions.hh…"
      gen_links $DIR $FILES

This is slightly slower than the previous approach (which did not check
if the symlink target exists). But this prevents adding subtle bugs
that may not trigger every time (see 520ac3ab ("*/gen_links.sh: fix
wrong SDP_EncDec.cc symlink")).

Change-Id: I0da0ec30e5eaf65d0348e22900a5ee006dee9e44
Oliver Smith at
testenv: run daemons with 'ulimit -c unlimited'

Prepare to support getting core files without having systemd-coredump
installed, as we plan to uninstall it from the jenkins servers to make
retrieving coredumps for other jobs feasible again.

When starting daemons, set the maximum core file size to unlimited.
Otherwise it might be at 0, resulting in no core files getting
generated.

I have considered using resource.setrlimit() on the python process
instead, but this wouldn't work when spawning the daemons inside the
podman container.

Change-Id: Ideaf0386c8d6111c2634f276f926e976023ff511
Oliver Smith at
testenv: coredump: support core_pattern=core

Support getting core files from a typical core_pattern=core where the
coredump just gets stored in the current working dir, instead of always
retrieving it from coredumpctl. This is what we will use with jenkins in
the future, as it makes getting core files in other jobs easier. Remove
support for the custom testenv-coredump-helper code that isn't needed
anymore.

Change-Id: Ia765b01432e4cb4cd36c45de874b966e3ebf55bc
Oliver Smith at
testenv: add empty lines around backtrace

Make the backtrace stand out visually from the rest of the logs.

Change-Id: Icd75379a875b72ddf3364895bc6a0afc57d2901e
Oliver Smith at
library/HTTP_Adapter: do not hard-code 'Content-Type'

* Do not send `Content-Type` when request contains no body.
** This is wrong and some servers would reject such a request.
* Allow passing custom `Content-Type` to
** `f_http_tx_request()` and
** `f_http_transact()`.
* Use `application/json` by default.

Change-Id: Ie35ffc56b4fedc0b4d8c4a689a2232b515b7b326
Vadim Yanitskiy at
hnbgw: fix missing TC_sccp_cr_limit() from control section

fixup for f2c95021e, add TC_sccp_cr_limit() to the control{ } section.

Related: f2c95021e
Related: Ia68dad973ef18513b52f5accb5264c557c7295ea
Change-Id: I0604d937fc909fa66f2a8668c2f6926a269b2b42
Neels Hofmeyr at
smdpp: es9p testsuite

Implemented parts conform to sgp 23 v1.13-v1.15
Certs are from https://www.gsma.com/solutions-and-impact/technologies/esim/wp-content/uploads/2021/07/SGP.26_v1.5-17-July-2025_files_v3.zip
the invalid ones are generated using smdpp/generate_all_test_certificates.py

Change-Id: I3ba163d9155a3b019214dbccc3c8031dfd7deb6b
smdpp/smdpp_Tests_Functions.cc smdpp/sgp26/DPtls/CERT_S_SM_DP2_TLS.csr.cnf smdpp/sgp26/DPpb/SK_S_SM_DP2pb_ECDSA_NIST.pem smdpp/sgp26/DPtls/PK_S_SM_DP8_TLS.pem smdpp/sgp26/EUM/PK_EUM_ECDSA_NIST.pem smdpp/sgp26/CertificateIssuer/CERT_CI_ECDSA_NIST.pem smdpp/sgp26/DPtls/PK_S_SM_DP_TLS_NIST.pem .checkpatch.conf smdpp/sgp26/DPauth/CERT_S_SM_DPauth_ECDSA_NIST.der smdpp/sgp26/eUICC/PK_EUICC_ECDSA_NIST.pem smdpp/sgp26/DPauth/PK_S_SM_DPauth_ECDSA_NIST.pem smdpp/sgp26/DPpb/PK_S_SM_DP2pb_ECDSA_NIST.pem smdpp/InvalidTestCases/CERT_UNKNOWN_CI_ECDSA_NIST.der smdpp/sgp26/DPauth/SK_S_SM_DPauth_ECDSA_BRP.pem smdpp/sgp26/DPpb/CERT_S_SM_DP2pb_ECDSA_NIST.der smdpp/.clang-format smdpp/rsp_client.cpp Makefile smdpp/sgp26/DPpb/PK_S_SM_DPpb_ECDSA_NIST.pem smdpp/sgp26/DPtls/SK_S_SM_DP_TLS_BRP.pem smdpp/helpers.h smdpp/sgp26/DPauth/PK_S_SM_DPauth_ECDSA_BRP.pem smdpp/InvalidTestCases/CERT_EUICC_ECDSA_NIST_EXPIRED.der smdpp/sgp26/EUM/CERT_EUM_ECDSA_BRP.der smdpp/InvalidTestCases/CERT_EUM_ECDSA_NIST_EXPIRED.der smdpp/sgp26/DPauth/PK_S_SM_DP2auth_ECDSA_BRP.pem smdpp/sgp26/EUM/EUM-ext.cnf smdpp/smdpp_Tests.ttcn smdpp/sgp26/DPtls/CERT_S_SM_DP2_TLS.ext.cnf smdpp/gen_links.sh smdpp/InvalidTestCases/CERT_EUM_ECDSA_NIST_UNKNOWN_CI.der smdpp/smdpp_Tests.cfg smdpp/sgp26/EUM/EUM-csr.cnf smdpp/InvalidTestCases/CERT_EUICC_ECDSA_NIST_UNMATCHED_EID.der smdpp/sgp26/DPtls/CERT_S_SM_DP_TLS_BRP.der smdpp/InvalidTestCases/CERT_EUICC_ECDSA_NIST_INVALID_EID.pem smdpp/sgp26/DPauth/CERT_S_SM_DPauth_ECDSA_BRP.der smdpp/sgp26/DPtls/CERT_S_SM_DP8_TLS.ext.cnf smdpp/bsp_crypto.cpp smdpp/sgp26/DPtls/PK_S_SM_DP4_TLS.pem smdpp/sgp26/DPpb/CERT_S_SM_DPpb_ECDSA_BRP.der smdpp/sgp26/DPpb/SK_S_SM_DP2pb_ECDSA_BRP.pem smdpp/sgp26/DPtls/CERT_S_SM_DP8_TLS.csr.cnf smdpp/sgp26/DPtls/CERT_S_SM_DP2_TLS.der smdpp/generate_all_test_certificates.py smdpp/package.yml smdpp/sgp26/CertificateIssuer/SK_CI_ECDSA_BRP.pem smdpp/sgp26/CertificateIssuer/CERT_CI_ECDSA_BRP.pem smdpp/sgp26/DPtls/CERT_S_SM_DP_TLS.csr.cnf smdpp/sgp26/eUICC/PK_EUICC_ECDSA_BRP.pem smdpp/sgp26/DPpb/CERT_S_SM_DPpb_ECDSA_NIST.der smdpp/sgp26/eUICC/SK_EUICC_ECDSA_NIST.pem smdpp/sgp26/DPauth/CERT_S_SM_DP2auth_ECDSA_BRP.der smdpp/sgp26/DPtls/CERT_S_SM_DP4_TLS.ext.cnf smdpp/sgp26/eUICC/SK_EUICC_ECDSA_BRP.pem smdpp/sgp26/DPtls/CERT_S_SM_DP4_TLS.csr.cnf smdpp/sgp26/EUM/SK_EUM_ECDSA_BRP.pem smdpp/sgp26/DPpb/PK_S_SM_DP2pb_ECDSA_BRP.pem smdpp/sgp26/DPtls/CERT_S_SM_DP4_TLS.der smdpp/sgp26/CertificateIssuer/SK_CI_ECDSA_NIST.pem smdpp/bsp_crypto.h smdpp/InvalidTestCases/CERT_EUICC_ECDSA_NIST_UNMATCHED_EID.pem smdpp/sgp26/DPauth/SK_S_SM_DP2auth_ECDSA_NIST.pem smdpp/sgp26/EUM/PK_EUM_ECDSA_BRP.pem smdpp/sgp26/DPtls/CERT_S_SM_DP_TLS_NIST.der smdpp/sgp26/DPauth/SK_S_SM_DP2auth_ECDSA_BRP.pem smdpp/sgp26/DPpb/SK_S_SM_DPpb_ECDSA_BRP.pem smdpp/sgp26/DPauth/SK_S_SM_DPauth_ECDSA_NIST.pem smdpp/sgp26/DPtls/PK_S_SM_DP2_TLS_NIST.pem smdpp/sgp26/DPtls/SK_S_SM_DP2_TLS_NIST.pem smdpp/sgp26/EUM/CERT_EUM_ECDSA_NIST.der smdpp/regen_makefile.sh smdpp/sgp26/DPauth/PK_S_SM_DP2auth_ECDSA_NIST.pem smdpp/sgp26/DPpb/CERT_S_SM_DP2pb_ECDSA_BRP.der smdpp/sgp26/eUICC/CERT_EUICC_ECDSA_BRP.der smdpp/sgp26/DPauth/CERT_S_SM_DP2auth_ECDSA_NIST.der smdpp/sgp26/eUICC/eUICC-ext.cnf smdpp/sgp26/CertificateIssuer/CERT_CI_ECDSA_NIST.der smdpp/sgp26/DPpb/SK_S_SM_DPpb_ECDSA_NIST.pem smdpp/InvalidTestCases/CERT_EUICC_ECDSA_NIST_INVALID_EID.der smdpp/sgp26/CertificateIssuer/CERT_CI_ECDSA_BRP.der smdpp/sgp26/CertificateIssuer/CI-csr.cnf smdpp/InvalidTestCases/CERT_EUICC_ECDSA_NIST_INVALID.der smdpp/sgp26/DPtls/SK_S_SM_DP_TLS_NIST.pem smdpp/sgp26/DPtls/CERT_S_SM_DP_TLS.ext.cnf smdpp/sgp26/DPtls/SK_S_SM_DP8_TLS.pem smdpp/sgp26/eUICC/CERT_EUICC_ECDSA_NIST.der smdpp/sgp26/EUM/SK_EUM_ECDSA_NIST.pem smdpp/smdpp_Tests.default smdpp/sgp26/DPtls/SK_S_SM_DP4_TLS.pem smdpp/logger.h smdpp/sgp26/DPtls/CERT_S_SM_DP8_TLS.der smdpp/sgp26/eUICC/eUICC-csr.cnf smdpp/sgp26/DPpb/PK_S_SM_DPpb_ECDSA_BRP.pem smdpp/InvalidTestCases/CERT_EUM_ECDSA_NIST_INVALID.der smdpp/sgp26/DPtls/PK_S_SM_DP_TLS_BRP.pem
ewild at
smdpp: es9p pure asn1 support

Can be used instead of the json layer.

Change-Id: I1d824931bd6513d2320ba30df0f8193cd8352863
ewild at
fixup for SCCP_MAX_OPTIONAL_DATA changing to 128

Change-Id: I2fdafa88be1f25c90c7e1a34423a25aa7f5bff5c
laforge at
s1gw: track eNB connection, fail immediately on loss

Change-Id: I34a3d30270f1236908643b60fc8abe590a780b89
laforge at
s1gw: implement the REST interface client

OsmoS1GW implements a custom (non-standard) REST interface, primarily
intended for state introspection.  The interface is specified using
OpenAPI, with the specification available in osmo-s1gw.git.

Change-Id: Ic6e8b46b7de4fb72139b017fc9a9c83f92fc1541
Related: SYS#7066
laforge at
ttcn3-tcpdump-start: fix default TTCN3_PCAP_PATH

Fix that manually running testsuites (as described in README.md) would
unsucessfully attempt to start dumpcap for 10s before running each test:

  NOTE: unable to use dumpcap due to missing permissions in /tmp
  Warning: Named pipe already exists: /tmp/cmderr
  sudo -n /usr/bin/tcpdump -U -s 1520 -n -i any -w "/tmp/smdpp_Tests.TC_rsp_complete_flow.pcap" >/tmp/smdpp_Tests.TC_rsp_complete_flow.pcap.stdout 2>/tmp/cmderr &
  Waiting for packet dumper to start... 0
  Waiting for packet dumper to start... 1
  Waiting for packet dumper to start... 2
  Waiting for packet dumper to start... 3
  Waiting for packet dumper to start... 4
  Waiting for packet dumper to start... 5
  Waiting for packet dumper to start... 6
  Waiting for packet dumper to start... 7
  Waiting for packet dumper to start... 8
  Waiting for packet dumper to start... 9
  Packet dumper didn't start filling pcap file after 10 seconds!!!

This happens because /tmp is owned by root and not by the user running
ttcn3-tcpdump-start. Put the pcaps in /tmp/pcap by default instead of
/tmp and create this directory as the current user if it does not exist.
This also prevents cluttering /tmp.

Note that this is only relevant when manually running the testsuites and
not setting TTCN3_PCAP_PATH, e.g. testenv sets this variable already.

Change-Id: I1eb80d7f9e8dd491387e4d1da9b4ac6ac5cb7dc5
Oliver Smith at
testenv: add a --fast argument

The ttcn3-{tcpdump,dumpcap}-*.sh scripts can easily spend 5s or more for
each test with:
* Waiting until the pcap gets created.
* Waiting until pcap size does not increase anymore after the test.
* Saving the talloc report.

Add --fast to skip all this, to allow running a whole testsuite
significantly faster locally to check for regressions. Developers can
then still run failing tests again without --fast to get the pcap and
talloc reports.

Change-Id: Ief3488293e5c5c1a1c98244f80ffd56eadb040c5
Oliver Smith at
Makefile: ctags: include *.cc/*.hh files

Also generate tags for *.cc/*.hh files.  In order to avoid generating
tags for generated source files, limit the search scope for `find`.

Change-Id: Iab28b36ea6bb6ece45d1834dfc04be489da39ea2
Vadim Yanitskiy at
RAN_{Emulation,Adapter}: Split transport type from transport client/server mode

The RAN_Transport is used to identify the stack of protocols in use up
to SCCP. The client/server mode is some extra independent information.
For instance, RAN_Emulation doesn't really use it while RAN_Adapter
does, since the later is the one in charge of setting up the lower layer
socket connection.

Change-Id: Ib2e7d029bd7eb59cc6f3b3a28bc417f00d3fed9c
Pau Espin Pedrol at
SCCP_Adapter: Allow configuring ipa_ccm_pars in SCCPLite transport

This is needed for instance to set ipa_unit_id, which must match the AS
name configured at the STP.

Change-Id: I16e1f5d0c40c03330642b2781dc6ddae81d821b2
Pau Espin Pedrol at
testenv: add --install-package

Add an option to quickly install packages in the container. This is
useful when making a new SUT run with osmo-ttcn3-hacks and figuring out
which packages need to be installed to make the build pass (without
rebuilding the whole container for each missing dependency). It can also
be used to quickly install additional debugging tools (strace, valgrind,
etc.). A cache for the deb files is already getting mounted inside the
container.

Change-Id: Ie54817e6c0334a224a612521beb378537c10d39d
Oliver Smith at
sgsn/SGSN_Tests_SNS.cfg: adjust to recent changes

Fix this error:
  Error: Error message was received from HC at 10.0.2.100 [10.0.2.100]: Error while setting parameter field 'SGSN_Tests.mp_ranap_cfg[0].sctp_addr' to '{ 23908, "127.0.0.103", 2905, "127.0.0.200" }': Non existent field name in type @RAN_Adapter.RAN_Configuration: sctp_addr

Fixes: 0cdd73a8 ("Split SCCP_Adapter out of RAN_Adapter")
Change-Id: I62a1188aa3346fda3f0674296629ade51a02088f
Oliver Smith at
testenv: set PYTHONUNBUFFERED=1

Prepare to run PyHSS, which needs this variable to be set or else no log
messages are printed. This problem exists with potentially all python
scripts that testenv would run, so set the env var for all commands.

Change-Id: I155f7c7bd9b985094e36fee6c6a2acfe556f580d
Oliver Smith at
hlr: add HLR_IMPL_PYHSS

Prepare to run the HLR testsuite against PyHSS.

Related: OS#6862
Change-Id: I0989374d777aabf5afaf224faeb0cb2ff4e603e6
Oliver Smith at
hlr: don't test OsmoHLR-only features with PyHSS

Proxy, mslookup and creating subscriber on demand are not implemented in
PyHSS, so don't test these features when testing PyHSS.

Related: OS#6862
Change-Id: I0c4905dd3f73abfe9f7cc77fc045368b9499aade
Oliver Smith at
hlr: add MSC to ccm_pars.name

Fix an immediate disconnect from pyHSS:
  [ERROR] 127.0.0.1:9999: Role not found in tags. 'sgsn' or 'msc' must appear in one of there tags: TYPE, UNIT, UNITNAME. Closing connection.

Related: OS#6862
Change-Id: I1813e49ec286892c1a637deb99908903613696aa
Oliver Smith at
hlr: add initial testenv_pyhss.cfg

With this patch and fixes in PyHSS, the first test cases are passing:
https://github.com/nickvsnetworking/pyhss/pull/257

Tests passing:
* TC_gsup_sai_err_invalid_imsi
* TC_gsup_ul_unknown_imsi
* TC_gsup_sai_err_unknown_imsi
* TC_gsup_purge_unknown

Related: OS#6862
Depends: osmo-ci Ic7acd3ca654580aa8e5a52f162f5c9042fc7d09f
Change-Id: I7a7e709ec02a9bf44343fff4df2861dfe4e1a761
Oliver Smith at
hlr: fix error msg in f_count_auth_tuples

Log expected_auth_tuples instead of mp_default_num_auth_tuples,
otherwise we get bogus messages such as:

  Did not received expected number of auth tuples. Expected 5 but received 5

Change-Id: Icc0e3118f0cf113ed8784a9f22d3d2ccbf47cf76
Oliver Smith at
hlr: wrap f_vty_subscr_create and _delete

Add wrappers as f_subscr_create/_delete (without _vty), and only use the
VTY implementation for OsmoHLR. This is in preparation for implementing
a different method for PyHSS in a follow-up patch.

Avoid passing the VTY parameter by splitting each function into a normal
variant that runs on test_CT, and a _HCH variant that runs on
HLR_ConnHdlr.

Change-Id: I6aafa118645346fd709c56de1e38771ed4de93b7
Oliver Smith at
Allow matching tr_GTP2C_CreateSessionReq with any tEID

Related: SYS#7635
Change-Id: I6fe3ba9f24bd0615e70ffe515c5b8c907ca8a494
jolly at
Fix length indicators in tr_NAS_ActDefEpsBearCtxReq

Related: SYS#7635
Change-Id: Ibce4b56c479fb5e31ee1f7871eab168facfef94e
jolly at
library/s1ap: Add support for E_RABSetupRequest

Related: SYS#7635
Change-Id: I4593bb8a7845b4b1dd10866fca47f473bd585cf6
jolly at
library/NAS_EPS_Templates: Add Emergency Number List templates

Change-Id: Ied3d8f56f84302617edc1cf3017a2866c6dbbd96
jolly at
MME-Tests: Add tests for emergency cappability indication

When an attachment is accepted, MME indicates the capability of
emergency calls, if and only if configured in MME's configuration file.
The emergency numbers that are configured are also indicated.

The tests check if the indications follow the configuration and are
correctly encoded.

Related: SYS#7635
Change-Id: I3d84486dd3826d0f60a3c06693118e36b01ecd2b
jolly at
MME-Tests: Add test for emergency bearer setup

When the UE makes an emergency call, it requests emergency bearer to be
established. The configured emergency bearer will be established.

The test checks if the emergency bearer is established and the APN
name matches the configured APN name.

Related: SYS#7635
Change-Id: I2a81defc96bcebdf1a4ec765278ca502800cbe46
jolly at
smdpp_Tests: fix sourcecode formatting, remove line breaks

Change-Id: I50175cd2989d6bfbe220c33e73a1724166ca548f
Related: SYS#7339
pmaier@sysmocom.de at
smdpp_Tests: rename smdp_server_url to smdp_server_fqdn

The member name "smdp_server_url" is technically not correct as the
content is an FQDN. Let's rename it to "smdp_server_fqdn".

Let's also put a comment in which we explain why FQDN is hardcoded
and not available as configurable module parameter.

Related: SYS#7339
Change-Id: I0224c838a368656821fff6014b0df7eb49466b0a
pmaier@sysmocom.de at
smdpp_Tests: make ES9+ and ES2+ ports configurable

Change-Id: I17f2713088c583bec26a0a8cdff40c796e0a490b
Related: SYS#7339
pmaier@sysmocom.de at
smdpp_Tests: simplify generation of smdpp_ConnHdlrPars (NIST vs. BRP)

When we call f_init_pars() it will return a record with default parameters.
However, those parameters are only a suitable default when the NIST curve
is used. For the brainpool curve we will have to modify returned result.

Let's simlify this by adding a parameter to f_init_pars() that allows us to
switch between the defaults for NIST and BRP as needed.

Realated: SYS#7339
Change-Id: Ied4ffa6ff4b3efbbcfc9204ce8f21ea7ca4becf5
pmaier@sysmocom.de at
hlr: pyhss: create/delete subscribers

Run the PyHSS API service, and fill it with a default APN on startup.
Having one APN entry in the database is required for creating
subscribers.

Talk to the API service for creating and deleting subscribers. Do this
with a new script pyhss_api_helper.py. Deleting subscribers requires
reading JSON returned from the server (to get the AUC and subscriber ID
from the IMSI). I have first attempted to do this via HTTP_Adapter
instead of using a helper script, but this was a lot more complex and
would have required to have the JSON structure in the TTCN3 files. The
eim testsuite also runs an external script for REST requests.

With this change and additional fixes in PyHSS, more tests pass:
* HLR_Tests.TC_gsup_sai
* HLR_Tests.TC_gsup_sai_num_auth_vectors
* HLR_Tests.TC_gsup_ul
* HLR_Tests.TC_gsup_purge_cs
* HLR_Tests.TC_gsup_purge_ps

Related: OS#6862
Change-Id: Ic924dabbc813459f73d6646ee17b79cb11d39a76
Oliver Smith at
Update key for Osmocom OBS

Change-Id: Id72581dc1cffb9d43dfc56aa16f2b1b9baf9c04f
Oliver Smith at
mme: add missing MME_Tests_emergency.cfg

Fix for:
  install: cannot stat '…/mme/MME_Tests_emergency.cfg': No such file or directory

(Config added by Andreas, commit message by Oliver)

Fixes: a8eb4c70 ("MME-Tests: Add tests for emergency cappability indication")
Change-Id: Id282981a735f9f5e29f957dc395210f5e785bff3
Oliver Smith at
smdpp_tests: extend comment with hint on CA cert locations

Let's extend the comment around mp_es2plus_server_host and mention that
CA certfiicates should be made availablein /etc/ssl/certs. In case the
CA certificate is not present in /etc/ssl/certs, libcurl will refuse
to connect.

Change-Id: I58d4f35c8493a9f9531da8d7c565760a08101e35
Related: SYS#7339
pmaier@sysmocom.de at
testenv: fix wrong exception name

Fix for:
  AttributeError: module 'testenv' has no attribute 'NoTraceError'

Change-Id: I800bccf63feb590069f80684474ca2d700ae697e
Oliver Smith at
ES2Plus_Tests: cleanup/add module parameters

The ES2Plus_Tests only have minimal configuration options. Let's remove
hardcoded options and replace them with module parameters. Let's also
document the module parameters.

Change-Id: Ib8e128e4af8e819799c4d7ea3e6a36189462f382
Related: SYS#7339
pmaier@sysmocom.de at
ES2Plus_Tests: fix typo

Related: SYS#7339
Change-Id: I510a879042977b6ef1cd19e5a66fceeefa42e0c1
pmaier@sysmocom.de at
smdpp_Tests: move module parameter up

The module parameters are somewhere in the middle of the module
code. Let's put them to the top to make it easier to find them.

Change-Id: I8d0fae934e48eb55d78bfa904be064c2613930a8
Related: SYS#7339
pmaier@sysmocom.de at
ES2Plus_Tests: remove unused module parameter

Change-Id: I98921155d74209ffe97d6981a1d65a4424ef918c
Related: SYS#7339
pmaier@sysmocom.de at
ES2Plus_Tests: remove obvious comment

Change-Id: I30564ecd89f32ea1830ef1f3bbfcddc4b3f585c4
Related: SYS#7339
pmaier@sysmocom.de at
ES2Plus_Tests: move [TESTPORT_PARAMETERS] up

We normally have the [TESTPORT_PARAMETERS] right below [LOGGING]

Change-Id: If0d5ba0dc8d5b1f07215d6ac8c02a36253c200f6
Related: SYS#7339
pmaier@sysmocom.de at
smdpp_Tests.cfg: remove unused testport parameters

The testsuite uses a custom libcurl based sublayer that handles all
the HTTP related tasks. Let's remove the HTTP_server_port related
testport parameters.

Change-Id: If58675f4243250381d407722c52e8e2384aa4f22
Related: SYS#7339
pmaier@sysmocom.de at
ES2Plus_Tests: improve error messages when setting verdict in f_init_es2plus

It is not enough to say something has failed, it is also important
to say what exactly and what for.

Related: SYS#7339
Change-Id: I1a4aa85e3b1950eae0f910a14a95afa8e16c9cf6
pmaier@sysmocom.de at
ES2Plus_Tests: add "es2plus" prefix to module parameter

Let's prefix the module parameters to make it easier to understand
their purpose.

Related: SYS#7339
Change-Id: Idda9f287177cb1dce66bbef410bb1b7085f55b4d
pmaier@sysmocom.de at
ES2Plus_Tests: rename mp_es2plus_server_host to _fqdn

Let's rename the module parameter mp_es2plus_server_host to
mp_es2plus_server_fqdn. The reason for this is that the suffix "host"
suggests that one may use an arbitrary hostname or IP address. In
this case this is in fact not true. The FQDN must match the hostname
of the SSL server certificate. Apart from that GSMA SGP.22 always
uses the word "FQDN" in their specs.

Change-Id: Idedfcce4d013c32f43307e159c45854a1e6a049b
Related: SYS#7339
pmaier@sysmocom.de at
ES2Plus_Tests.cfg: remove unhelpful comment

There is no benefit for the user from this comment. The port number
also is often a custom parameter that depends on the actual setup.

Change-Id: Ic7b2d9d665feee211d6dedcf9068a6ce3c993aaf
Related: SYS#7339
pmaier@sysmocom.de at
ES2Plus_Tests.cfg: comment out parameters in config file.

The code in ES2Plus_Tests.ttcn already provides safe defaults, so we
do not have to repeat those defaults again in ES2Plus_Tests.cfg.

So let's comment out the parameters. This way we kenn keep them for
illustrative purposes, so that users can use the config file as a
helpful template for the most basic settings.

Related: SYS#7339
Change-Id: I5677222305d847ba3ac1cdafecdc942ece80aa8c
pmaier@sysmocom.de at
smdpp_Tests.cfg: comment out parameters in config file.

The code in smdpp_Tests.ttcn already provides safe defaults, so we
do not have to repeat those defaults again in smdpp_Tests.cfg.

So let's comment out the parameters. This way we kenn keep them for
illustrative purposes, so that users can use the config file as a
helpful template for the most basic settings.

Related: SYS#7339
Change-Id: I981b683da0312799c2e5b24ac57cd838b071f955
pmaier@sysmocom.de at
smdpp_Tests: remove excess newline

Related: SYS#7339
Change-Id: Ice4d472eadf259204a4a849273bccbca8728f2ec
pmaier@sysmocom.de at
smdpp_Tests/ES2Plus_Tests: move ES2+ code to smdpp_Tests.ttcn

In smdp_Tests.ttcn, the ES9+ and ES2+ interface are intermingled. This
is a problem since ES2+ and ES9+ are two independed interfaces and they
may use different certificates and may even be reachable under a different
FQDN from a different network interface.

To untable ES2+ and ES9+ we can move the ES2+ code from ES2Plus_Tests.ttcn
to smdpp_Tests.ttcn. Since ES2Plus_Tests.ttcn inherits from smdpp_Tests.ttcn
the ES2+ code will still be available to ES2Plus_Tests.ttcn.

This change will add the flexibility of ES2Plus_Tests.ttcn to
smdpp_Tests.ttcn. This means we can now freely configure the FQDN and the
certificates used with ES2+.

Related: SYS#7339
Change-Id: Ib59568379a9d454ea99d66550d6da8fd203681db
pmaier@sysmocom.de at
smdpp_Tests: add comments to mp_es9plus_server_port_ module parameters

Let's add an explanatory comment to mp_es9plus_server_port_nist and
mp_es9plus_server_port_brp

Related: SYS#7339
Change-Id: I7e3f0292256b21a75da5b756ee9af6ec58318de1
pmaier@sysmocom.de at
smdp_Tests: remove custom_tls_cert module parameters

The module parameters mp_use_custom_tls_cert and mp_custom_tls_cert_path
are no longer needed, so let's remove them.

Change-Id: Ie37da6986410b663378531f4f0d50d95b3068964
Related: SYS#7339
pmaier@sysmocom.de at
smdpp_Tests: improve messages when setting verdict in f_init_es9plus

It is important to tell that the failure happend in the context of the
ES9+ initialization.

Related: SYS#7339
Change-Id: I6b55d0bb6d5bd698241a990cf8388adc68a99543
pmaier@sysmocom.de at
smdpp_Tests: rename f_rsp_client_init to f_init_es9plus

We already have an init function for ES2+ that is called f_init_es2plus,
let's rename f_rsp_client_init to maintain consistency.

Related: SYS#7339
Change-Id: I865b9dfc3597f9a962225880b7a5cda838b8377e
pmaier@sysmocom.de at
smdpp_Tests: fix typo

Related: SYS#7339
Change-Id: I8c2dc134f78b2780641a82baf0cebbb3ffbf9150
pmaier@sysmocom.de at
smdpp_Tests: fix sourcecode formatting

Related: SYS#7339
Change-Id: Id7edf94858a952b22bd8b86957a05b18968e085e
pmaier@sysmocom.de at
bsc: TC_lcs_loc_req_without_smlc: new test

Related: SYS#7714
Depends: osmo-bsc Ie8a66f9decf9fff602f7fecfb71a78fab900066f
Change-Id: I1cd7a7658b21d3eb04443a15ffd5ddf09b466af5
Oliver Smith at
smdpp_Tests: optimize calling of f_init_esXplus

When we call the f_init_esXplus functions we always check the return
code to see if the initialization went ok. However in both functions
we already set the verdict and in the ES2+ variant of the functions
we already stop the MTC. Let's optimize the function calls so that
we only call the function without checking the return code. Let's
do all the error handling and the stopping of the MTC in inside
f_init_esXplus.

Related: SYS#7339
Change-Id: I64fc5a7eddd6c5aee8ce85dbfe56c076f3372f3d
pmaier@sysmocom.de at
IPA: Introduce new OSMO extension TCAP_ROUTING

TCAP_ROUTING is an extension to IPA/SCCP where
the node can requests to receive only certain TCAP traffic
to support loadsharing.

Related: SYS#5423
Change-Id: Ibfcf633f7bd8773f557901fdff7580f5879391a1
lynxis at
library: TCAP: ts_TCAP_UNITDATA_req: allow to define the returnOption

TCAP loadsharing will use RETURN_OPTION_ON_ERROR option to
test UDTS when no TCAP ranges matches.

Related: SYS#5423
Change-Id: Ie4f6d9e02f65687c3158cae41f28aa30b95f85f8
lynxis at
library: TCAP: add tr_TCAP_N_NOTICE_ind

A SCCP UTDS will be passed to the TCAP layer as TCAP_N_NOTICE_ind.
Will be used by utds testsing of tcap loadsharing.

Related: SYS#5423
Change-Id: I002afabb8e827dc35cd9f4e37a6970d91600ee37
lynxis at
stp: Introduce STP_Tests_TCAP

The network topology and test infrastructure already allows testing TCAP forwarding
at STP over IPA<->IPA, M3UA<->IPA and M3UA<->M3UA.

Co-authored-by: Alexander Couzens <lynxis@fe80.eu>
Related: SYS#5423
Change-Id: I4340bdf126118c66af861f5a447e90883783920e
lynxis at
hlr: testenv: fix running pyhss from debian pkg

Move the run_in_venv.sh script that is only used by pyhss from the
generic location _testenv/data/scripts/run_in_venv.sh to
hlr/pyhss/run_in_venv.sh and hardcode the path
/opt/venvs/pyhss/bin/activate in there when running from binary
packages. This is the path used in the binary package in the Osmocom
OBS, the default path from dh_virtualenv. The package doesn't install
pyhss_gsup etc. to /usr/bin, as these are usually not meant to be
directly started without the systemd services that have the
/opt/venvs/pyhss path hardcoded.

Also put 'export PYHSS_CONFIG=config.yaml' in there, now that
the script is pyhss specific.

Related: https://dh-virtualenv.readthedocs.io/en/1.2.1/usage.html
Change-Id: I0cdf1a9f220ddd2ef0866d0d11d1e3f6056a1cba
Oliver Smith at