lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

October 2026

  • 1 participants
  • 1245 discussions
[XS] Change in osmo-ttcn3-hacks[master]: RSPDefinitions_Templates: fix profileManagementOperation value
by dexter 16 Oct '26

16 Oct '26
Attention is currently required from: jolly. dexter has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43876?usp=email ) Change subject: RSPDefinitions_Templates: fix profileManagementOperation value ...................................................................... Patch Set 2: (1 comment) File library/euicc/RSPDefinitions_Templates.ttcn: https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43876/comment/4505618a_6f8b… : PS1, Line 639: profileManagementOperation := '1'B, /* notificationInstall */ > I see that 4 bits are used to define all NotificationEvent bit string. […] I also thought that '1000'B would be correct, but the decoder would decode '1000'B to '1'B, this created an asymmetry between the tr_ and the ts_ template. That is why I have changed it. The meaning is not altered by this. It still means "bit 1 is set, all others are 0". I think the reason why it behaves that way is that the bit string length is not fixed. The spec could extend the bis string at any time and to be backward compatible and to save bandwidth, the bit string may always be shorter. Regarding the ASN.1 definition: Only one bit shall be set to 1 - that is still fulfilled. -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43876?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I05c333ecd4f750bd4ae94863696144b2b5b0f036 Gerrit-Change-Number: 43876 Gerrit-PatchSet: 2 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: jolly <andreas(a)eversberg.eu> Gerrit-Attention: jolly <andreas(a)eversberg.eu> Gerrit-Comment-Date: Fri, 16 Oct 2026 07:48:57 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: jolly <andreas(a)eversberg.eu>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: RSPDefinitions_Templates: add tr/ts_profileInstallationResultData_err
by dexter 16 Oct '26

16 Oct '26
Attention is currently required from: jolly. dexter has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43877?usp=email ) Change subject: RSPDefinitions_Templates: add tr/ts_profileInstallationResultData_err ...................................................................... Patch Set 2: (2 comments) Commit Message: https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43877/comment/fa577a5e_ea1a… : PS1, Line 9: We already have a tr/ts_profileInstallationResultData temlate > typo Done File library/euicc/RSPDefinitions_Templates.ttcn: https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43877/comment/703864b5_db81… : PS1, Line 674: profileManagementOperation := '1'B, /* notificationInstall */ > Same as i mentioned in a previous patch. Bit string need to be checked. (see reply in the other patch) btw.: I also didn't expect that the encoders/decoders behaves that way, it's probably also a specialty of the TTCN3 ASN.1 compiler. -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43877?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Ib927cdea65adc633a8e4b93739f894b4adabffb5 Gerrit-Change-Number: 43877 Gerrit-PatchSet: 2 Gerrit-Owner: dexter <pmaier(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: jolly <andreas(a)eversberg.eu> Gerrit-Attention: jolly <andreas(a)eversberg.eu> Gerrit-Comment-Date: Fri, 16 Oct 2026 07:48:57 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: jolly <andreas(a)eversberg.eu>
1 0
0 0
[XS] Change in osmo-ttcn3-hacks[master]: 5gc,hss,pcrf: remove mongodb when done
by osmith 16 Oct '26

16 Oct '26
osmith has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43901?usp=email ) Change subject: 5gc,hss,pcrf: remove mongodb when done ...................................................................... 5gc,hss,pcrf: remove mongodb when done Fix that each of these jobs leaves a "db" directory in the logs dir, that is the whole mongodb database. In case of 5gc it is 300 MiB in size, which with daily job runs quickly turns into several GiB on the jenkins server where build artifacts are stored. Example db dir: https://jenkins.osmocom.org/jenkins/job/ttcn3-5gc-test-ogs/ws/logs/db/db/ Change-Id: I0f6ebaa45e1cada1e1141c127999db6f181ee066 --- M 5gc/testenv.cfg M hss/testenv_open5gs.cfg M pcrf/testenv.cfg 3 files changed, 3 insertions(+), 0 deletions(-) Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved diff --git a/5gc/testenv.cfg b/5gc/testenv.cfg index 2008d9a..27199cb 100644 --- a/5gc/testenv.cfg +++ b/5gc/testenv.cfg @@ -7,6 +7,7 @@ [db] prepare=mkdir db +clean=rm -rf db program=mongod --config mongod.conf setup=create_test_subscribers.sh copy=mongod.conf diff --git a/hss/testenv_open5gs.cfg b/hss/testenv_open5gs.cfg index 79ccede..79b6ec3 100644 --- a/hss/testenv_open5gs.cfg +++ b/hss/testenv_open5gs.cfg @@ -4,6 +4,7 @@ [db] prepare=mkdir db +clean=rm -rf db program=mongod --config mongod.conf setup=create_test_subscribers.sh copy=mongod.conf diff --git a/pcrf/testenv.cfg b/pcrf/testenv.cfg index 221e4a9..487f618 100644 --- a/pcrf/testenv.cfg +++ b/pcrf/testenv.cfg @@ -4,6 +4,7 @@ [db] prepare=mkdir db +clean=rm -rf db program=mongod --config mongod.conf setup=create_test_subscribers.sh copy=mongod.conf -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43901?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I0f6ebaa45e1cada1e1141c127999db6f181ee066 Gerrit-Change-Number: 43901 Gerrit-PatchSet: 3 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: testenv: optionally compress big ttcn3 logs
by osmith 16 Oct '26

16 Oct '26
osmith has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43896?usp=email ) Change subject: testenv: optionally compress big ttcn3 logs ...................................................................... testenv: optionally compress big ttcn3 logs Use pigz (parallel implementation of gzip) to compress logs bigger than 1 MiB if TESTENV_COMPRESS_BIG_LOGS=1 is set, which will be the case in jenkins. This saves a lot of space in the build artifacts. I decided to not compress small log files because it can be useful to quickly open them in the browser. Related: OS#7105 Change-Id: I0766f6236f023ea8e3329c1364c9ee048e00c6d0 --- M _testenv/README.md M _testenv/data/podman/Dockerfile A _testenv/data/scripts/log_compress.sh M _testenv/testenv/testsuite.py 4 files changed, 31 insertions(+), 0 deletions(-) Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved pespin: Looks good to me, but someone else must approve diff --git a/_testenv/README.md b/_testenv/README.md index f10d349..4f53724 100644 --- a/_testenv/README.md +++ b/_testenv/README.md @@ -226,6 +226,11 @@ available but doesn't work in podman. QEMU runs a bit slower when this is set. +* `TESTENV_COMPRESS_BIG_LOGS`: + When set to 1, compress `.merged` ttcn3 log files that are bigger than 1 MiB + with `gz`. This is used in jenkins to reduce job artifact sizes. Requires + `pigz` to be installed when running without `--podman`. + ### Environment variables set by testenv Testenv sets the following variables while running shell commands from diff --git a/_testenv/data/podman/Dockerfile b/_testenv/data/podman/Dockerfile index 6a1a42a..f808433 100644 --- a/_testenv/data/podman/Dockerfile +++ b/_testenv/data/podman/Dockerfile @@ -74,6 +74,7 @@ netcat-openbsd \ pax-utils \ pcscd \ + pigz \ pkg-config \ procps \ psmisc \ diff --git a/_testenv/data/scripts/log_compress.sh b/_testenv/data/scripts/log_compress.sh new file mode 100755 index 0000000..3e142ad --- /dev/null +++ b/_testenv/data/scripts/log_compress.sh @@ -0,0 +1,13 @@ +#!/bin/sh -e +# Compress big log files (OS#7105) +min=1000000 # ~ 1 MiB + +for i in *.merged; do + size="$(stat -c"%s" "$i")" + + if [ $size -lt $min ]; then + continue + fi + + pigz -9 "$i" +done diff --git a/_testenv/testenv/testsuite.py b/_testenv/testenv/testsuite.py index 52886cf..fc1716f 100644 --- a/_testenv/testenv/testsuite.py +++ b/_testenv/testenv/testsuite.py @@ -97,6 +97,17 @@ testenv.cmd.run(cmd, cwd=cwd, env=builddir_env) +def compress_big_log_files(cfg): + cwd = os.path.join(testenv.testdir.testdir, "testsuite") + + if os.getenv("TESTENV_COMPRESS_BIG_LOGS") != "1": + return + + logging.info("Compressing big log files") + cmd = os.path.join(testenv.data_dir, "scripts/log_compress.sh") + testenv.cmd.run(cmd, cwd=cwd, env=builddir_env) + + def get_junit_logs(topdir): pattern = os.path.join(topdir, "**", "junit-*.log") return glob.glob(pattern, recursive=True) @@ -192,6 +203,7 @@ merge_log_files(cfg) format_log_files(cfg) + compress_big_log_files(cfg) if testenv.args.bisect and not check_testsuite_successful(): raise testenv.NoTraceException("Testsuite failed!") -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43896?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I0766f6236f023ea8e3329c1364c9ee048e00c6d0 Gerrit-Change-Number: 43896 Gerrit-PatchSet: 2 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-ttcn3-hacks[master]: PFCP_Templates: Avoid enum2int() conversion in Outer_Header_Removal
by pespin 15 Oct '26

15 Oct '26
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43883?usp=email ) Change subject: PFCP_Templates: Avoid enum2int() conversion in Outer_Header_Removal ...................................................................... PFCP_Templates: Avoid enum2int() conversion in Outer_Header_Removal The type uses a integer, so better use integer too, otherwise the tr_ template cannot be passed wildcards due to the enum2int() call. Change-Id: I17a97301308af0e77e5693e7dba36d0a07504b0e --- M library/PFCP_Templates.ttcn M s1gw/S1GW_ConnHdlr.ttcn M smf/SMF_Session_CT.ttcn M upf/UPF_Tests.ttcn 4 files changed, 25 insertions(+), 25 deletions(-) Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved osmith: Looks good to me, but someone else must approve diff --git a/library/PFCP_Templates.ttcn b/library/PFCP_Templates.ttcn index 7f3a3b3..bf48224 100644 --- a/library/PFCP_Templates.ttcn +++ b/library/PFCP_Templates.ttcn @@ -1098,29 +1098,29 @@ udp_port := * } -type enumerated e_PFCP_Outer_Header_Removal { - GTP_U_UDP_IPV4 (0), - GTP_U_UDP_IPV6 (1), - UDP_IPV4 (2), - UDP_IPV6 (3), - IPV4 (4), - IPV6 (5), - GTP_U_UDP_IP (6), - VLAN_S_TAG (7), - S_TAG_AND_C_TAG (8) -}; +/* 8.2.64 Outer Header Removal */ +const integer PFCP_OHR_GTP_U_UDP_IPV4 := 0; +const integer PFCP_OHR_GTP_U_UDP_IPV6 := 1; +const integer PFCP_OHR_UDP_IPV4 := 2; +const integer PFCP_OHR_UDP_IPV6 := 3; +const integer PFCP_OHR_IPV4 := 4; +const integer PFCP_OHR_IPV6 := 5; +const integer PFCP_OHR_GTP_U_UDP_IP := 6; +const integer PFCP_OHR_VLAN_S_TAG := 7; +const integer PFCP_OHR_S_TAG_AND_C_TAG := 8; template (value) Outer_Header_Removal -ts_PFCP_Outer_Header_Removal(e_PFCP_Outer_Header_Removal ohr) := { - elementIdentifier := 95, - lengthIndicator := 0, - ohc_description := enum2int(ohr) +ts_PFCP_Outer_Header_Removal(template (value) integer ohr) := { + elementIdentifier := 95, + lengthIndicator := 0, + ohc_description := ohr } + template (present) Outer_Header_Removal -tr_PFCP_Outer_Header_Removal(e_PFCP_Outer_Header_Removal ohr) := { - elementIdentifier := 95, - lengthIndicator := ?, - ohc_description := enum2int(ohr) +tr_PFCP_Outer_Header_Removal(template (present) integer ohr := ?) := { + elementIdentifier := 95, + lengthIndicator := ?, + ohc_description := ohr } template (value) Forwarding_Parameters diff --git a/s1gw/S1GW_ConnHdlr.ttcn b/s1gw/S1GW_ConnHdlr.ttcn index 98ad911..24dacce 100644 --- a/s1gw/S1GW_ConnHdlr.ttcn +++ b/s1gw/S1GW_ConnHdlr.ttcn @@ -1092,7 +1092,7 @@ var template (present) Create_PDR pdr1; var template (present) Create_PDR pdr2; - ohr := tr_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4); + ohr := tr_PFCP_Outer_Header_Removal(PFCP_OHR_GTP_U_UDP_IPV4); pdr1 := tr_PFCP_Create_PDR(pdr_id := 1, /* -- for Core -> Access */ pdi := tr_PFCP_PDI(PFCP_Src_Iface_CORE), ohr := ohr, diff --git a/smf/SMF_Session_CT.ttcn b/smf/SMF_Session_CT.ttcn index 162b5f1..9120c55 100644 --- a/smf/SMF_Session_CT.ttcn +++ b/smf/SMF_Session_CT.ttcn @@ -411,7 +411,7 @@ sdf_filter_list := { tr_PFCP_SDF_Filter(fd := '1'B, flow_description := flow_description) }, source_interface_type := tr_PFCP_ThreeGPP_Interface_Type(11 /* N3 3GPP Access */)), - ohr := tr_PFCP_Outer_Header_Removal(GTP_U_UDP_IP), + ohr := tr_PFCP_Outer_Header_Removal(PFCP_OHR_GTP_U_UDP_IP), far_id := 3) , * } diff --git a/upf/UPF_Tests.ttcn b/upf/UPF_Tests.ttcn index 0fcef8a..c26925d 100644 --- a/upf/UPF_Tests.ttcn +++ b/upf/UPF_Tests.ttcn @@ -604,7 +604,7 @@ PFCP_Src_Iface_ACCESS, local_F_TEID := ts_PFCP_F_TEID_choose_v4(), network_instance := ts_PFCP_Network_Instance(src_netinst)), - ts_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4), + ts_PFCP_Outer_Header_Removal(PFCP_OHR_GTP_U_UDP_IPV4), far_id ) ) @@ -671,7 +671,7 @@ src_iface, local_F_TEID := ts_PFCP_F_TEID_choose_v4(), network_instance := ts_PFCP_Network_Instance(src_netinst)), - ts_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4), + ts_PFCP_Outer_Header_Removal(PFCP_OHR_GTP_U_UDP_IPV4), far_id ) ) @@ -704,7 +704,7 @@ src_iface, local_F_TEID := ts_PFCP_F_TEID_choose_v4(), network_instance := ts_PFCP_Network_Instance(src_netinst)), - ts_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4), + ts_PFCP_Outer_Header_Removal(PFCP_OHR_GTP_U_UDP_IPV4), far_id ) ) @@ -752,7 +752,7 @@ ts_PFCP_PDI( PFCP_Src_Iface_CP_FUNCTION, local_F_TEID := ts_PFCP_F_TEID_choose_v4('17'O)), - ts_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4), + ts_PFCP_Outer_Header_Removal(PFCP_OHR_GTP_U_UDP_IPV4), far_id ) ) -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43883?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I17a97301308af0e77e5693e7dba36d0a07504b0e Gerrit-Change-Number: 43883 Gerrit-PatchSet: 3 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-ttcn3-hacks[master]: PFCP_Templates: Avoid enum2int() conversion in Src/Dst_Iface
by pespin 15 Oct '26

15 Oct '26
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43882?usp=email ) Change subject: PFCP_Templates: Avoid enum2int() conversion in Src/Dst_Iface ...................................................................... PFCP_Templates: Avoid enum2int() conversion in Src/Dst_Iface The type uses a integer, so better use integer too, otherwise the tr_ template cannot be passed wildcards due to the enum2int() call. Change-Id: I6ed23538660be5ca97df47e66c3b6ab60b39074f --- M library/PFCP_Templates.ttcn M s1gw/S1GW_ConnHdlr.ttcn M smf/SMF_Session_CT.ttcn M upf/UPF_Tests.ttcn 4 files changed, 64 insertions(+), 65 deletions(-) Approvals: fixeria: Looks good to me, approved osmith: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/library/PFCP_Templates.ttcn b/library/PFCP_Templates.ttcn index a85b075..7f3a3b3 100644 --- a/library/PFCP_Templates.ttcn +++ b/library/PFCP_Templates.ttcn @@ -805,27 +805,27 @@ ipv6_address := omit } -type enumerated e_PFCP_Src_Iface { - ACCESS (0), - CORE (1), - SGI_LAN_N6_LAN (2), - CP_FUNCTION (3), - x_5G_VN_INTERNAL (4) -}; +/* 8.2.2 Source Interface */ +const integer PFCP_Src_Iface_ACCESS := 0; +const integer PFCP_Src_Iface_CORE := 1; +const integer PFCP_Src_Iface_SGI_LAN_N6_LAN := 2; +const integer PFCP_Src_Iface_CP_FUNCTION := 3; +const integer PFCP_Src_Iface_x_5G_VN_INTERNAL := 4; template (value) Source_Interface -ts_PFCP_Src_Iface(e_PFCP_Src_Iface iface) := { - elementIdentifier := 20, - lengthIndicator := 0, - interfacevalue := enum2int(iface), - spare := '0000'B +ts_PFCP_Src_Iface(template (value) integer iface) := { + elementIdentifier := 20, + lengthIndicator := 0, + interfacevalue := iface, + spare := '0000'B } + template (present) Source_Interface -tr_PFCP_Src_Iface(e_PFCP_Src_Iface iface) := { - elementIdentifier := 20, - lengthIndicator := ?, - interfacevalue := enum2int(iface), - spare := ? +tr_PFCP_Src_Iface(template (present) integer iface := ?) := { + elementIdentifier := 20, + lengthIndicator := ?, + interfacevalue := iface, + spare := ? } template (value) UE_IP_Address ts_PFCP_UE_IP_Address_v4(OCT4 addr_v4, boolean is_destination := true) := { @@ -938,12 +938,12 @@ } template (value) PDI_IE -ts_PFCP_PDI(e_PFCP_Src_Iface src_iface, +ts_PFCP_PDI(template (value) integer src_iface, template (omit) F_TEID local_F_TEID := omit, template (omit) UE_IP_Address ue_addr_v4 := omit, template (omit) Network_Instance network_instance := omit) := { - elementIdentifier := 2, - lengthIndicator := 0, + elementIdentifier := 2, + lengthIndicator := 0, grouped_ie := { source_interface := ts_PFCP_Src_Iface(src_iface), local_F_TEID := local_F_TEID, @@ -958,7 +958,7 @@ } } template (present) PDI_IE -tr_PFCP_PDI(e_PFCP_Src_Iface src_iface, +tr_PFCP_PDI(template (present) integer src_iface := ?, template F_TEID local_F_TEID := *, template UE_IP_Address ue_addr_v4 := *, template Network_Instance network_instance := *, @@ -1050,28 +1050,27 @@ template (value) Apply_Action ts_PFCP_Apply_Action_BUFF := ts_PFCP_Apply_Action(buff := '1'B); template (present) Apply_Action tr_PFCP_Apply_Action_BUFF := tr_PFCP_Apply_Action(buff := '1'B); -type enumerated e_PFCP_Dest_Iface { - ACCESS (0), - CORE (1), - SGI_LAN_N6_LAN (2), - CP_FUNCTION (3), - LI_FUNCTION (4), - x_5G_VN_INTERNAL (5) -}; +/* 8.2.24 Destination Interface */ +const integer PFCP_Dest_Iface_ACCESS := 0; +const integer PFCP_Dest_Iface_CORE := 1; +const integer PFCP_Dest_Iface_SGI_LAN_N6_LAN := 2; +const integer PFCP_Dest_Iface_CP_FUNCTION := 3; +const integer PFCP_Dest_Iface_LI_FUNCTION := 4; +const integer PFCP_Dest_Iface_x_5G_VN_INTERNAL := 5; template (value) Destination_Interface -ts_PFCP_Destination_Interface(e_PFCP_Dest_Iface di) := { - elementIdentifier := 42, - lengthIndicator := 0, - interface_value := enum2int(di), - spare := '0000'B +ts_PFCP_Destination_Interface(template (value) integer di) := { + elementIdentifier := 42, + lengthIndicator := 0, + interface_value := di, + spare := '0000'B } template (present) Destination_Interface -tr_PFCP_Destination_Interface(e_PFCP_Dest_Iface di) := { - elementIdentifier := 42, - lengthIndicator := ?, - interface_value := enum2int(di), - spare := ? +tr_PFCP_Destination_Interface(template (present) integer di := ?) := { + elementIdentifier := 42, + lengthIndicator := ?, + interface_value := di, + spare := ? } template (value) Outer_Header_Creation @@ -1125,7 +1124,7 @@ } template (value) Forwarding_Parameters -ts_PFCP_Forwarding_Parameters(e_PFCP_Dest_Iface dest_iface, +ts_PFCP_Forwarding_Parameters(template (value) integer dest_iface, template (omit) Network_Instance network_instance := omit, template (omit) Redirect_Information redirect_information := omit, template (omit) Outer_Header_Creation ohc := omit, @@ -1149,7 +1148,7 @@ } } template (present) Forwarding_Parameters -tr_PFCP_Forwarding_Parameters(e_PFCP_Dest_Iface dest_iface, +tr_PFCP_Forwarding_Parameters(template (present) integer dest_iface := ?, template Network_Instance network_instance := *, template Redirect_Information redirect_information := *, template Outer_Header_Creation ohc := *, diff --git a/s1gw/S1GW_ConnHdlr.ttcn b/s1gw/S1GW_ConnHdlr.ttcn index 9c127d8..98ad911 100644 --- a/s1gw/S1GW_ConnHdlr.ttcn +++ b/s1gw/S1GW_ConnHdlr.ttcn @@ -1094,11 +1094,11 @@ ohr := tr_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4); pdr1 := tr_PFCP_Create_PDR(pdr_id := 1, /* -- for Core -> Access */ - pdi := tr_PFCP_PDI(CORE), + pdi := tr_PFCP_PDI(PFCP_Src_Iface_CORE), ohr := ohr, far_id := c_PFCP_FAR_ID_C2A); pdr2 := tr_PFCP_Create_PDR(pdr_id := 2, /* -- for Access -> Core */ - pdi := tr_PFCP_PDI(ACCESS), + pdi := tr_PFCP_PDI(PFCP_Src_Iface_ACCESS), ohr := ohr, far_id := c_PFCP_FAR_ID_A2C); @@ -1110,7 +1110,7 @@ ohc2 := tr_PFCP_Outer_Header_Creation_GTP_ipv4(erab.u2c.teid, f_inet_addr(erab.u2c.tla)); - fpars2 := tr_PFCP_Forwarding_Parameters(dest_iface := CORE, ohc := ohc2); + fpars2 := tr_PFCP_Forwarding_Parameters(dest_iface := PFCP_Dest_Iface_CORE, ohc := ohc2); far1 := tr_PFCP_Create_FAR(far_id := c_PFCP_FAR_ID_C2A, /* -- for Core -> Access */ aa := tr_PFCP_Apply_Action_DROP, diff --git a/smf/SMF_Session_CT.ttcn b/smf/SMF_Session_CT.ttcn index 58ee1c2..162b5f1 100644 --- a/smf/SMF_Session_CT.ttcn +++ b/smf/SMF_Session_CT.ttcn @@ -405,7 +405,7 @@ create_pdr := { *, tr_PFCP_Create_PDR(pdr_id := 4, - pdi := tr_PFCP_PDI(src_iface := ACCESS, + pdi := tr_PFCP_PDI(src_iface := PFCP_Src_Iface_ACCESS, local_F_TEID := tr_PFCP_F_TEID(?, ?, '1'B, '1'B, omit, omit, omit, ?), network_instance := tr_PFCP_Network_Instance(g_pars.apn), sdf_filter_list := { tr_PFCP_SDF_Filter(fd := '1'B, @@ -419,7 +419,7 @@ *, tr_PFCP_Create_FAR(far_id := 3, aa := tr_PFCP_Apply_Action(forw := '1'B), - fp := tr_PFCP_Forwarding_Parameters(dest_iface := CP_FUNCTION, + fp := tr_PFCP_Forwarding_Parameters(dest_iface := PFCP_Dest_Iface_CP_FUNCTION, ohc := tr_PFCP_Outer_Header_Creation_GTP_ipv4(?, f_inet_addr(mp_smf_hostname)))) , * } diff --git a/upf/UPF_Tests.ttcn b/upf/UPF_Tests.ttcn index 159ac83..0fcef8a 100644 --- a/upf/UPF_Tests.ttcn +++ b/upf/UPF_Tests.ttcn @@ -601,7 +601,7 @@ ts_PFCP_Create_PDR( pdr_id, ts_PFCP_PDI( - ACCESS, + PFCP_Src_Iface_ACCESS, local_F_TEID := ts_PFCP_F_TEID_choose_v4(), network_instance := ts_PFCP_Network_Instance(src_netinst)), ts_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4), @@ -614,7 +614,7 @@ ts_PFCP_Create_FAR( far_id, ts_PFCP_Apply_Action_FORW, - valueof(ts_PFCP_Forwarding_Parameters(CORE)) + valueof(ts_PFCP_Forwarding_Parameters(PFCP_Dest_Iface_CORE)) ) ) }; @@ -632,7 +632,7 @@ ts_PFCP_Create_PDR( pdr_id, ts_PFCP_PDI( - CORE, + PFCP_Src_Iface_CORE, ue_addr_v4 := ts_PFCP_UE_IP_Address_v4(f_inet_addr(ue_addr_v4), is_destination := true) ), far_id := far_id @@ -645,7 +645,7 @@ far_id, ts_PFCP_Apply_Action_FORW, valueof(ts_PFCP_Forwarding_Parameters( - dest_iface := ACCESS, + dest_iface := PFCP_Dest_Iface_ACCESS, ohc := ts_PFCP_Outer_Header_Creation_GTP_ipv4( remote_teid, gtp_dest_addr_v4) @@ -658,10 +658,10 @@ /* Add to r a rule set that forwards GTP from one tunnel to another, i.e. one direction of a tunmap */ private function f_ruleset_add_GTP_forw(inout PFCP_Ruleset r, integer pdr_id, - e_PFCP_Src_Iface src_iface, + integer src_iface, charstring src_netinst, integer far_id, - e_PFCP_Dest_Iface dest_iface, + integer dest_iface, F_TEID dest_remote_f_teid) { r.pdr := r.pdr & { valueof( @@ -692,10 +692,10 @@ /* Add to r a DROP rule from src_iface to dest_iface */ private function f_ruleset_add_GTP_drop(inout PFCP_Ruleset r, integer pdr_id, - e_PFCP_Src_Iface src_iface, + integer src_iface, charstring src_netinst, integer far_id, - e_PFCP_Dest_Iface dest_iface) { + integer dest_iface) { r.pdr := r.pdr & { valueof( ts_PFCP_Create_PDR( @@ -727,7 +727,7 @@ gtp.core.tunmap.far_id, ts_PFCP_Apply_Action_FORW, valueof(ts_PFCP_Update_Forwarding_Parameters( - ts_PFCP_Destination_Interface(CORE), + ts_PFCP_Destination_Interface(PFCP_Dest_Iface_CORE), ts_PFCP_Outer_Header_Creation_GTP_ipv4(gtp.core.tunmap.teid_r, f_inet_addr(gtp.core.tunmap.gtp_ip_r)) ) @@ -750,7 +750,7 @@ ts_PFCP_Create_PDR( pdr_id, ts_PFCP_PDI( - CP_FUNCTION, + PFCP_Src_Iface_CP_FUNCTION, local_F_TEID := ts_PFCP_F_TEID_choose_v4('17'O)), ts_PFCP_Outer_Header_Removal(GTP_U_UDP_IPV4), far_id @@ -762,7 +762,7 @@ ts_PFCP_Create_FAR( far_id, ts_PFCP_Apply_Action_FORW, - valueof(ts_PFCP_Forwarding_Parameters(ACCESS)) + valueof(ts_PFCP_Forwarding_Parameters(PFCP_Dest_Iface_ACCESS)) ) ) }; @@ -776,7 +776,7 @@ ts_PFCP_Create_PDR( pdr_id, ts_PFCP_PDI( - CP_FUNCTION, + PFCP_Src_Iface_CP_FUNCTION, local_F_TEID := ts_PFCP_F_TEID_choose_v4('2a'O)), far_id := far_id ) @@ -787,7 +787,7 @@ ts_PFCP_Create_FAR( far_id, ts_PFCP_Apply_Action_FORW, - valueof(ts_PFCP_Forwarding_Parameters(ACCESS)) + valueof(ts_PFCP_Forwarding_Parameters(PFCP_Dest_Iface_ACCESS)) ) ) }; @@ -826,28 +826,28 @@ if (core_gtp_known) { f_ruleset_add_GTP_forw(rules, pdr_id := gtp.access.pdr_id, - src_iface := ACCESS, + src_iface := PFCP_Src_Iface_ACCESS, src_netinst := netinst_access, far_id := gtp.core.tunmap.far_id, - dest_iface := CORE, + dest_iface := PFCP_Dest_Iface_CORE, dest_remote_f_teid := valueof(ts_PFCP_F_TEID_ipv4(gtp.core.tunmap.teid_r, f_inet_addr(gtp.core.tunmap.gtp_ip_r)))); } else { /* The Core remote GTP will follow in a Session Modification, for now set Core->Access to DROP */ f_ruleset_add_GTP_drop(rules, pdr_id := gtp.access.pdr_id, - src_iface := ACCESS, + src_iface := PFCP_Src_Iface_ACCESS, src_netinst := netinst_access, far_id := gtp.core.tunmap.far_id, - dest_iface := CORE); + dest_iface := PFCP_Dest_Iface_CORE); } /* Core to Access */ f_ruleset_add_GTP_forw(rules, pdr_id := gtp.core.tunmap.pdr_id, - src_iface := CORE, + src_iface := PFCP_Src_Iface_CORE, src_netinst := netinst_core, far_id := gtp.access.far_id, - dest_iface := ACCESS, + dest_iface := PFCP_Dest_Iface_ACCESS, dest_remote_f_teid := valueof(ts_PFCP_F_TEID_ipv4(gtp.access.teid_r, f_inet_addr(gtp.access.gtp_ip_r)))); return rules; -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43882?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I6ed23538660be5ca97df47e66c3b6ab60b39074f Gerrit-Change-Number: 43882 Gerrit-PatchSet: 5 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: PFCP_Templates: Avoid int2oct() conversion in PFCP_Create_PDR
by pespin 15 Oct '26

15 Oct '26
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43884?usp=email ) Change subject: PFCP_Templates: Avoid int2oct() conversion in PFCP_Create_PDR ...................................................................... PFCP_Templates: Avoid int2oct() conversion in PFCP_Create_PDR The type uses a OCT2, so better use integer too, otherwise the tr_ template cannot be passed wildcards due to the int2oct() call. Change-Id: Ie4eeb8df5a55dc0b47ebdff0a256d57031eb35df --- M library/PFCP_Templates.ttcn M s1gw/S1GW_ConnHdlr.ttcn M smf/SMF_Session_CT.ttcn M upf/UPF_Tests.ttcn 4 files changed, 25 insertions(+), 24 deletions(-) Approvals: Jenkins Builder: Verified osmith: Looks good to me, but someone else must approve fixeria: Looks good to me, approved diff --git a/library/PFCP_Templates.ttcn b/library/PFCP_Templates.ttcn index bf48224..c02ec10 100644 --- a/library/PFCP_Templates.ttcn +++ b/library/PFCP_Templates.ttcn @@ -1280,17 +1280,18 @@ } } +/* 8.2.36 PDR ID */ template (value) PDR_ID ts_PFCP_PDR_ID(template (value) OCT2 pdr_id) := { - elementIdentifier := 56, - lengthIndicator := 0, - rule_id := pdr_id + elementIdentifier := 56, + lengthIndicator := 0, + rule_id := pdr_id } template (present) PDR_ID -tr_PFCP_PDR_ID(template (present) OCT2 pdr_id) := { - elementIdentifier := 56, - lengthIndicator := ?, - rule_id := pdr_id +tr_PFCP_PDR_ID(template (present) OCT2 pdr_id := ?) := { + elementIdentifier := 56, + lengthIndicator := ?, + rule_id := pdr_id } template (value) Precedence @@ -1307,14 +1308,14 @@ } template (value) Create_PDR -ts_PFCP_Create_PDR(integer pdr_id, +ts_PFCP_Create_PDR(template (value) OCT2 pdr_id, template (value) PDI_IE pdi, template (omit) Outer_Header_Removal ohr := omit, template (value) LIN4_BO_LAST far_id) := { - elementIdentifier := 1, - lengthIndicator := 0, + elementIdentifier := 1, + lengthIndicator := 0, grouped_ie := { - pdr_id := ts_PFCP_PDR_ID(int2oct(pdr_id, 2)), + pdr_id := ts_PFCP_PDR_ID(pdr_id), precedence := ts_PFCP_Precedence(0), pdi := pdi, outer_header_removal := ohr, @@ -1325,14 +1326,14 @@ } } template (present) Create_PDR -tr_PFCP_Create_PDR(integer pdr_id, +tr_PFCP_Create_PDR(template (present) OCT2 pdr_id := ?, template (present) PDI_IE pdi := ?, template Outer_Header_Removal ohr := *, template (present) LIN4_BO_LAST far_id := ?) := { - elementIdentifier := 1, - lengthIndicator := ?, + elementIdentifier := 1, + lengthIndicator := ?, grouped_ie := { - pdr_id := tr_PFCP_PDR_ID(int2oct(pdr_id, 2)), + pdr_id := tr_PFCP_PDR_ID(pdr_id), precedence := tr_PFCP_Precedence(?), pdi := pdi, outer_header_removal := ohr, diff --git a/s1gw/S1GW_ConnHdlr.ttcn b/s1gw/S1GW_ConnHdlr.ttcn index 24dacce..9a045b2 100644 --- a/s1gw/S1GW_ConnHdlr.ttcn +++ b/s1gw/S1GW_ConnHdlr.ttcn @@ -1093,11 +1093,11 @@ var template (present) Create_PDR pdr2; ohr := tr_PFCP_Outer_Header_Removal(PFCP_OHR_GTP_U_UDP_IPV4); - pdr1 := tr_PFCP_Create_PDR(pdr_id := 1, /* -- for Core -> Access */ + pdr1 := tr_PFCP_Create_PDR(pdr_id := int2oct(1, 2), /* -- for Core -> Access */ pdi := tr_PFCP_PDI(PFCP_Src_Iface_CORE), ohr := ohr, far_id := c_PFCP_FAR_ID_C2A); - pdr2 := tr_PFCP_Create_PDR(pdr_id := 2, /* -- for Access -> Core */ + pdr2 := tr_PFCP_Create_PDR(pdr_id := int2oct(2, 2), /* -- for Access -> Core */ pdi := tr_PFCP_PDI(PFCP_Src_Iface_ACCESS), ohr := ohr, far_id := c_PFCP_FAR_ID_A2C); diff --git a/smf/SMF_Session_CT.ttcn b/smf/SMF_Session_CT.ttcn index 9120c55..e89fd0c 100644 --- a/smf/SMF_Session_CT.ttcn +++ b/smf/SMF_Session_CT.ttcn @@ -404,7 +404,7 @@ var template octetstring flow_description := '7065726D6974206F75742035382066726F6D20666630323A3A*2F31323820746F2061737369676E6564'O; // ("permit out 58 from ff02::*/128 to assigned"); create_pdr := { *, - tr_PFCP_Create_PDR(pdr_id := 4, + tr_PFCP_Create_PDR(pdr_id := int2oct(4, 2), pdi := tr_PFCP_PDI(src_iface := PFCP_Src_Iface_ACCESS, local_F_TEID := tr_PFCP_F_TEID(?, ?, '1'B, '1'B, omit, omit, omit, ?), network_instance := tr_PFCP_Network_Instance(g_pars.apn), diff --git a/upf/UPF_Tests.ttcn b/upf/UPF_Tests.ttcn index c26925d..a5c7cc9 100644 --- a/upf/UPF_Tests.ttcn +++ b/upf/UPF_Tests.ttcn @@ -599,7 +599,7 @@ r.pdr := r.pdr & { valueof( ts_PFCP_Create_PDR( - pdr_id, + int2oct(pdr_id, 2), ts_PFCP_PDI( PFCP_Src_Iface_ACCESS, local_F_TEID := ts_PFCP_F_TEID_choose_v4(), @@ -630,7 +630,7 @@ r.pdr := r.pdr & { valueof( ts_PFCP_Create_PDR( - pdr_id, + int2oct(pdr_id, 2), ts_PFCP_PDI( PFCP_Src_Iface_CORE, ue_addr_v4 := ts_PFCP_UE_IP_Address_v4(f_inet_addr(ue_addr_v4), is_destination := true) @@ -666,7 +666,7 @@ r.pdr := r.pdr & { valueof( ts_PFCP_Create_PDR( - pdr_id, + int2oct(pdr_id, 2), ts_PFCP_PDI( src_iface, local_F_TEID := ts_PFCP_F_TEID_choose_v4(), @@ -699,7 +699,7 @@ r.pdr := r.pdr & { valueof( ts_PFCP_Create_PDR( - pdr_id, + int2oct(pdr_id, 2), ts_PFCP_PDI( src_iface, local_F_TEID := ts_PFCP_F_TEID_choose_v4(), @@ -748,7 +748,7 @@ r.pdr := r.pdr & { valueof( ts_PFCP_Create_PDR( - pdr_id, + int2oct(pdr_id, 2), ts_PFCP_PDI( PFCP_Src_Iface_CP_FUNCTION, local_F_TEID := ts_PFCP_F_TEID_choose_v4('17'O)), @@ -774,7 +774,7 @@ r.pdr := r.pdr & { valueof( ts_PFCP_Create_PDR( - pdr_id, + int2oct(pdr_id, 2), ts_PFCP_PDI( PFCP_Src_Iface_CP_FUNCTION, local_F_TEID := ts_PFCP_F_TEID_choose_v4('2a'O)), -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43884?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Ie4eeb8df5a55dc0b47ebdff0a256d57031eb35df Gerrit-Change-Number: 43884 Gerrit-PatchSet: 4 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-ttcn3-hacks[master]: PFCP_Templates: Support passing PFCPSEReq_Flags IE to tr_PFCP_Session...
by pespin 15 Oct '26

15 Oct '26
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43879?usp=email ) Change subject: PFCP_Templates: Support passing PFCPSEReq_Flags IE to tr_PFCP_Session_Est_Req() ...................................................................... PFCP_Templates: Support passing PFCPSEReq_Flags IE to tr_PFCP_Session_Est_Req() titan.ProtocolModules.PFCP is updated to upstream master since the type PFCPSEReq_Flags was just merged in upstrean [1]. [1] https://gitlab.eclipse.org/eclipse/titan/titan.ProtocolModules.PFCP_v15.1.0… Change-Id: Idc7fc117d25940f9e032dc347141a2fada57c912 --- M deps/Makefile M library/PFCP_Templates.ttcn 2 files changed, 21 insertions(+), 4 deletions(-) Approvals: osmith: Looks good to me, approved fixeria: Looks good to me, but someone else must approve Jenkins Builder: Verified diff --git a/deps/Makefile b/deps/Makefile index ad0f260..78e57d9 100644 --- a/deps/Makefile +++ b/deps/Makefile @@ -111,7 +111,7 @@ titan.ProtocolModules.SUA_commit= R.5.A-5-gcf1137a titan.ProtocolModules.TCP_commit= R.3.A-5-g39e5f45 titan.ProtocolModules.UDP_commit= R.4.A-5-geea8aa3 -titan.ProtocolModules.PFCP_v15.1.0_commit= bdd91b0a255afdb737afe9084b8ebc7b3cabc5f6 +titan.ProtocolModules.PFCP_v15.1.0_commit= 3acaa9096b1309c9825c7b20a21b9ace810f9a3e titan.TestPorts.AF_PACKET_commit= 0.1-5-g89ebea6 titan.TestPorts.Common_Components.Socket-API_commit= R.6.A-6-gf4380d0 titan.TestPorts.Common_Components.Abstract_Socket_commit= R.9.B-4-gbd41994 diff --git a/library/PFCP_Templates.ttcn b/library/PFCP_Templates.ttcn index c02ec10..5eea706 100644 --- a/library/PFCP_Templates.ttcn +++ b/library/PFCP_Templates.ttcn @@ -598,6 +598,20 @@ validity_time_value := validity_time_value } +/* 8.2.136 PFCPSEReq-Flags */ +template (present) PFCPSEReq_Flags +tr_PFCPSEReq_Flags(template (present) BIT1 resti := ?, + template (present) BIT1 sumpc := ?, + template (present) BIT1 hrsbom := ?, + template (present) BIT1 epri := ?) := { + elementIdentifier := 186, + lengthIndicator := ?, + resti := resti, + sumpc := sumpc, + hrsbom := hrsbom, + epri := epri, + spare := ? +} template (value) PDU_PFCP ts_PDU_PFCP_ := { s_flag := '0'B, @@ -1431,7 +1445,8 @@ node_list := omit, up_inactivity_timer := omit, user_id := omit, - apn_dnn := omit + apn_dnn := omit, + pfcpSEReq_flags := omit } } } @@ -1441,7 +1456,8 @@ template (present) Create_PDR_list create_pdr := ?, template (present) Create_FAR_list create_far := ?, template Create_URR_list create_urr := *, - template PDN_Type pdn_type := *) + template PDN_Type pdn_type := *, + template PFCPSEReq_Flags pfcpSEReq_flags := *) modifies tr_PDU_PFCP_ := { seid := '0000000000000000'O, /* shall be set to 0 as per 7.2.2.4.2 */ message_body := { @@ -1458,7 +1474,8 @@ node_list := *, up_inactivity_timer := *, user_id := *, - apn_dnn := * + apn_dnn := *, + pfcpSEReq_flags := pfcpSEReq_flags } } } -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43879?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: Idc7fc117d25940f9e032dc347141a2fada57c912 Gerrit-Change-Number: 43879 Gerrit-PatchSet: 5 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-ttcn3-hacks[master]: smf: TC_pfcp_heartbeat_timeout: Expect Delete Bearer Request
by pespin 15 Oct '26

15 Oct '26
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43886?usp=email ) Change subject: smf: TC_pfcp_heartbeat_timeout: Expect Delete Bearer Request ...................................................................... smf: TC_pfcp_heartbeat_timeout: Expect Delete Bearer Request This is expected to work once [1] is fixed with [2]. [1] https://github.com/open5gs/open5gs/issues/4860 [2] https://github.com/open5gs/open5gs/pull/4863 Change-Id: I5d55801923533b36ca2a1a573f1205281809f76d --- M library/GTPv2_Templates.ttcn M smf/SMF_Session_CT_4G.ttcn M smf/SMF_Tests.ttcn 3 files changed, 85 insertions(+), 14 deletions(-) Approvals: Jenkins Builder: Verified osmith: Looks good to me, but someone else must approve fixeria: Looks good to me, approved diff --git a/library/GTPv2_Templates.ttcn b/library/GTPv2_Templates.ttcn index 31ec999..6f8b0cb 100644 --- a/library/GTPv2_Templates.ttcn +++ b/library/GTPv2_Templates.ttcn @@ -1355,6 +1355,27 @@ privateExtension := omit }}); +template (present) PDU_GTPCv2 +tr_GTP2C_DeleteBearerReq(template (present) OCT4 d_teid := ?, + template (present) OCT3 seq := ?, + template EPS_BearerID_List bearer_id_list := *, + template GTP2C_Cause cause := *) := +tr_PDU_GTP2C(d_teid, seq, { + deleteBearerRequest := { + epsBearerIdentity := bearer_id_list, + bearerContextGrouped := *, + procedureTransactionID := *, + protocolConfigOptions := *, + csid := *, + cause := tr_GTP2C_Cause(cause), + indicationFlags := *, + loadControlInformationGrouped := *, + overloadControlInformationGrouped := *, + nBIFOMContainer := *, + extendedProtocolConfigOptions := *, + privateExtension := * + }}); + template (value) PDU_GTPCv2 ts_GTP2C_DeleteBearerReq(template (value) OCT4 d_teid, template (value) integer proc_trans_id, @@ -1401,6 +1422,31 @@ privateExtension := * }}); +template (value) PDU_GTPCv2 +ts_GTP2C_DeleteBearerResp(template (value) OCT4 d_teid, + template (value) OCT3 seq, + template (value) uint4_t bearer_id, + template (value) GTP2C_Cause cause) := +ts_PDU_GTP2C(d_teid, seq, '64'O, { + deleteBearerResponse := { + cause := ts_GTP2C_Cause(cause, '0'B), + linkedBearerIdentity := ts_GTP2C_EpsBearerId(bearer_id), + bearerContextGrouped := omit, + recovery := omit, + csid := omit, + protocolConfigOptions := omit, + uE_TimeZone := omit, + uLI := omit, + uLITimestamp := omit, + trustedWLANAccessNetworkIdentifier := omit, + tWANIdentifierTimestamp := omit, + overloadControlInformationGrouped := omit, + iP_Addr := omit, + portNumber := omit, + nBIFOMContainer := omit, + privateExtension := omit + }}); + /* 8.18 */ template (value) ServingNetwork ts_GTP2C_ServingNetwork(template (value) hexstring mcc, diff --git a/smf/SMF_Session_CT_4G.ttcn b/smf/SMF_Session_CT_4G.ttcn index ba230cb..9ea12f8 100644 --- a/smf/SMF_Session_CT_4G.ttcn +++ b/smf/SMF_Session_CT_4G.ttcn @@ -145,7 +145,8 @@ } [] DIAMETER[DIA_Gy].receive(PDU_DIAMETER:?) -> value g_rx_gy { Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail, - log2str("Received unexpected DIAMETER Gy", g_rx_gy)); + log2str("Received unexpected DIAMETER Gy ", g_rx_gy, + " vs exp ", f_tr_DIA_Gy_CCR_sess(req_type := req_type))); } } @@ -448,4 +449,34 @@ f_delete_session(fteid_c_ie, tx_cause, exp_cause, expect_pfcp, expect_diameter); } +altstep as_s5s8_delete_bearer_req(boolean expect_diameter := true) runs on SMF_Session_CT { + var PDU_GTPCv2 rx_pdu; + [] GTP2.receive(tr_GTP2C_DeleteBearerReq(d_teid := g_pars.teic_local, + seq := ?, + bearer_id_list := ?, + cause := Reactivation_Required)) -> value rx_pdu { + var template (value) PDU_GTPCv2 tx_pdu; + tx_pdu := ts_GTP2C_DeleteBearerResp(g_pars.teic_remote, + rx_pdu.sequenceNumber, + rx_pdu.gtpcv2_pdu.deleteBearerRequest.epsBearerIdentity[0].ePS_Bearer_ID_Value, Request_accepted); + GTP2.send(tx_pdu); + + if (is_s2b_iface() and DIAMETER[DIA_S6b].checkstate("Connected") and expect_diameter) { + as_DIA_S6b_STR(); + } + + if (DIAMETER[DIA_Gx].checkstate("Connected") and expect_diameter) { + as_DIA_Gx_CCR(TERMINATION_REQUEST); + } + if (DIAMETER[DIA_Gy].checkstate("Connected") and expect_diameter) { + as_DIA_Gy_CCR(TERMINATION_REQUEST); + } + setverdict(pass); + } + [] GTP2.receive(PDU_GTPCv2:?) -> value rx_pdu { + Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail, + log2str("Received unexpected GTPV2C ", rx_pdu)); + } +} + } diff --git a/smf/SMF_Tests.ttcn b/smf/SMF_Tests.ttcn index a3e5c14..6d7f020 100644 --- a/smf/SMF_Tests.ttcn +++ b/smf/SMF_Tests.ttcn @@ -595,13 +595,14 @@ f_s5s8_create_session(); f_prometheus_expect(valueof(t_Metrics_Expect(1, 1)), wait_converge := true); - /* Wait for IUT to detect peer went down after Heartbeat timeout, ie. wait for a 2nd ASSOC SETUP REQ - * after Heartbeat timeout: - * TODO: Handle tear down indication towards SGW-C (s5/s8c), PCRF (Gx) and OCS (Gy) */ + /* Wait for IUT to detect peer went down after Heartbeat timeout, ie. wait for sessions + * being released and another ASSOC SETUP REQ to attempt re-association: */ + as_s5s8_delete_bearer_req(); + PFCP.receive(tr_PFCP_Assoc_Setup_Req()) -> value m; deactivate(d); activate(as_pfcp_handle_heartbeat_req(rts, do_repeat := true)); - f_prometheus_expect(valueof(t_Metrics_Expect(0, 1)), wait_converge := true); + f_prometheus_expect(valueof(t_Metrics_Expect(0, 0)), wait_converge := true); PFCP.send(ts_PFCP_Assoc_Setup_Resp(m.sequence_number, ts_PFCP_Node_ID_ipv4(f_inet_addr(mp_pfcp_ip_local)), ts_PFCP_Cause(PFCP_Cause_REQUEST_ACCEPTED), @@ -610,15 +611,8 @@ vtime := '1'B))); /* After we answer the ASSOC SETUP RESP, IUT detects peer up: */ - /* FIXME: https://github.com/open5gs/open5gs/issues/4860 - * Instead of the commented line below, since open5gs-smfd is not tearing down the session, - * then delete the session to avoid leaving it dandling and open5gs-smfd trying to restore it (PFCP Sess Est Req) - * on other tests executed afterwards and making them fail due to unexpected msg received: - */ - // f_prometheus_expect(valueof(t_Metrics_Expect(1, 0)), wait_converge := true); - // setverdict(pass); - f_s5s8_delete_session(omit, Request_accepted); - setverdict(fail, "https://github.com/open5gs/open5gs/issues/4860"); + f_prometheus_expect(valueof(t_Metrics_Expect(1, 0)), wait_converge := true); + setverdict(pass); } testcase TC_pfcp_heartbeat_timeout() runs on SMF_Test_CT { var SMF_Session_CT vc_conn; -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43886?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I5d55801923533b36ca2a1a573f1205281809f76d Gerrit-Change-Number: 43886 Gerrit-PatchSet: 2 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-ttcn3-hacks[master]: smf: Introduce test TC_pfcp_heartbeat_recovery_timestamp
by pespin 15 Oct '26

15 Oct '26
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43880?usp=email ) Change subject: smf: Introduce test TC_pfcp_heartbeat_recovery_timestamp ...................................................................... smf: Introduce test TC_pfcp_heartbeat_recovery_timestamp Change-Id: I15ad5c295fc47ed9f38b91b6392b674bd0b4c4d7 --- M smf/SMF_Session_CT.ttcn M smf/SMF_Tests.ttcn M smf/expected-results.xml 3 files changed, 75 insertions(+), 4 deletions(-) Approvals: Jenkins Builder: Verified osmith: Looks good to me, but someone else must approve fixeria: Looks good to me, approved diff --git a/smf/SMF_Session_CT.ttcn b/smf/SMF_Session_CT.ttcn index e89fd0c..5eab61b 100644 --- a/smf/SMF_Session_CT.ttcn +++ b/smf/SMF_Session_CT.ttcn @@ -392,11 +392,12 @@ return rx; } -function f_Session_tr_PFCP_Session_Est_Req() runs on SMF_Session_CT return template (present) PDU_PFCP +function f_Session_tr_PFCP_Session_Est_Req(boolean exp_sess_restoration := false) runs on SMF_Session_CT return template (present) PDU_PFCP { var template (present) Create_PDR_list create_pdr := ?; var template (present) Create_FAR_list create_far := ?; var template Create_URR_list create_urr := *; + var template PFCPSEReq_Flags pfcpSEReq_flags := *; if (g_pars.pfcp_pars.pdn_type == c_PFCP_PDN_Type_IPv6 or g_pars.pfcp_pars.pdn_type == c_PFCP_PDN_Type_IPv4v6) { @@ -435,17 +436,39 @@ }; } + if (exp_sess_restoration) { + pfcpSEReq_flags := tr_PFCPSEReq_Flags(resti := '1'B); + } + return tr_PFCP_Session_Est_Req(create_pdr := create_pdr, create_far := create_far, create_urr := create_urr, - pdn_type := tr_PFCP_PDN_Type(g_pars.pfcp_pars.pdn_type)); + pdn_type := tr_PFCP_PDN_Type(g_pars.pfcp_pars.pdn_type), + pfcpSEReq_flags := pfcpSEReq_flags); } -altstep as_pfcp_sess_est_req() +altstep as_pfcp_sess_est_req(boolean exp_sess_restoration := false) runs on SMF_Session_CT { - var template (present) PDU_PFCP exp_req := f_Session_tr_PFCP_Session_Est_Req(); + var template (present) PDU_PFCP exp_req := f_Session_tr_PFCP_Session_Est_Req(exp_sess_restoration := exp_sess_restoration); var PDU_PFCP req; [] PFCP.receive(exp_req) -> value req { + var PFCP_Session_Establishment_Request sreq := req.message_body.pfcp_session_establishment_request; + if (exp_sess_restoration) { + /* "NOTE 4: The UP function shall accept the CP function allocated GTP-U + * F-TEID and/or UE IP address in the PFCP Session Establishment Request + * message with the RESTI flag set to "1", if the requested GTP-U F-TEID + * and/or UE IP address are available." */ + for (var integer i := 0; i < lengthof(sreq.create_PDR_list); i := i + 1) { + var template (present) Create_PDR exp_pdr; + exp_pdr := tr_PFCP_Create_PDR(pdr_id := ?, + pdi := tr_PFCP_PDI(src_iface := ?, + local_F_TEID := ?)); + if (not match(sreq.create_PDR_list[i], exp_pdr)){ + Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail, + log2str("Got CreatePDR ", sreq.create_PDR_list[i], " vs exp ", exp_pdr)); + } + } + } f_pfcp_sess_est_resp(req); } } diff --git a/smf/SMF_Tests.ttcn b/smf/SMF_Tests.ttcn index 6d7f020..3a6b1d6 100644 --- a/smf/SMF_Tests.ttcn +++ b/smf/SMF_Tests.ttcn @@ -625,6 +625,52 @@ } +/* Validate IUT detects PFCP Heartbeat Recovery Timestamp change and recovers from it restoring + * existing subscriber connections: */ +private function f_TC_pfcp_heartbeat_recovery_timestamp() runs on SMF_Session_CT { + var PDU_PFCP m; + var integer rts := f_PFCPEM_get_recovery_timestamp(); + + f_prometheus_expect(valueof(t_Metrics_Expect(1, 0)), wait_converge := true); + + f_PFCPEM_subscribe_bcast(); + as_pfcp_handle_heartbeat_req(rts); + + f_s5s8_create_session(); + f_prometheus_expect(valueof(t_Metrics_Expect(1, 1)), wait_converge := true); + + rts := rts + 1; + as_pfcp_handle_heartbeat_req(rts); + activate(as_pfcp_handle_heartbeat_req(rts, do_repeat := true)); + + /* Wait for IUT to detect during rx of Heartbeat Response that peer restarted, ie. wait for a + * 2nd ASSOC SETUP REQ after Heartbeat timeout: */ + PFCP.receive(tr_PFCP_Assoc_Setup_Req()) -> value m; + + f_prometheus_expect(valueof(t_Metrics_Expect(0, 1)), wait_converge := true); + PFCP.send(ts_PFCP_Assoc_Setup_Resp(m.sequence_number, + ts_PFCP_Node_ID_ipv4(f_inet_addr(mp_pfcp_ip_local)), + ts_PFCP_Cause(PFCP_Cause_REQUEST_ACCEPTED), + rts, + up_function_features := ts_PFCP_UP_Function_Features(ftup := '1'B, + vtime := '1'B))); + + /* IUT restores existing subscriber connections */ + as_pfcp_sess_est_req(exp_sess_restoration := true); + + f_s5s8_delete_session(omit, Request_accepted); + setverdict(pass); +} +testcase TC_pfcp_heartbeat_recovery_timestamp() runs on SMF_Test_CT { + var SMF_Session_CT vc_conn; + var SessionPars pars := f_SessionPars(800); + g_pfcp_answer_heartbeat_req := false; + f_init(guard_timeout := 60.0); + vc_conn := f_start_handler(refers(f_TC_pfcp_heartbeat_recovery_timestamp), pars); + vc_conn.done; + f_shutdown(); +} + /* create an IPv4 session from 5G AMF, then delete it again */ private function f_TC_n11_createSession_deleteSession() runs on SMF_Session_CT { var PrometheusExpects expects0 := valueof({ @@ -727,6 +773,7 @@ execute( TC_s2b_createSession_v4_apco() ); execute( TC_pfcp_heartbeat_timeout() ); + execute( TC_pfcp_heartbeat_recovery_timestamp() ); execute( TC_n11_createSession_deleteSession() ); execute( TC_n11_createSession_deleteSession_ipv6() ); diff --git a/smf/expected-results.xml b/smf/expected-results.xml index 1deaf2c..aab8202 100644 --- a/smf/expected-results.xml +++ b/smf/expected-results.xml @@ -13,6 +13,7 @@ <testcase classname='SMF_Tests' name='TC_s2b_createSession_v4_noapco' time='MASKED'/> <testcase classname='SMF_Tests' name='TC_s2b_createSession_v4_apco' time='MASKED'/> <testcase classname='SMF_Tests' name='TC_pfcp_heartbeat_timeout' time='MASKED'/> + <testcase classname='SMF_Tests' name='TC_pfcp_heartbeat_recovery_timestamp' time='MASKED'/> <testcase classname='SMF_Tests' name='TC_n11_createSession_deleteSession' time='MASKED'/> <testcase classname='SMF_Tests' name='TC_n11_createSession_deleteSession_ipv6' time='MASKED'/> <testcase classname='SMF_Tests' name='TC_n11_createSession_deleteSession_ipv4v6' time='MASKED'/> -- To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/43880?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-ttcn3-hacks Gerrit-Branch: master Gerrit-Change-Id: I15ad5c295fc47ed9f38b91b6392b674bd0b4c4d7 Gerrit-Change-Number: 43880 Gerrit-PatchSet: 7 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • ...
  • 125
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.