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 -----
  • November
  • 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

November 2026

  • 1 participants
  • 714 discussions
[M] Change in osmo-remsim[master]: Introduce osmo-remsim-client-socket
by laforge 18 Nov '26

18 Nov '26
laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-remsim/+/43742?usp=email ) Change subject: Introduce osmo-remsim-client-socket ...................................................................... Introduce osmo-remsim-client-socket Add new remsim client with socket interface. It is similar to the osmo-remsim-client-shell, but it uses a unix socket instead of stdin and stdout to exchange APDUs. The coding is binary instead of hex string. Related: SYS#8159 Change-Id: I9eddb60e4e7c3191ca2b340690416b53005f714f --- M .gitignore M configure.ac M debian/control A debian/osmo-remsim-client-socket.install M src/client/Makefile.am M src/client/client.h M src/client/remsim_client_main.c A src/client/user_socket.c 8 files changed, 216 insertions(+), 1 deletion(-) Approvals: Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve laforge: Looks good to me, approved diff --git a/.gitignore b/.gitignore index 5a5118b..758ae30 100644 --- a/.gitignore +++ b/.gitignore @@ -33,6 +33,7 @@ src/client/osmo-remsim-client-reader_conf src/client/osmo-remsim-client-shell +src/client/osmo-remsim-client-socket src/client/osmo-remsim-client-st2 src/bankd/pcsc_test src/bankd/osmo-remsim-bankd @@ -42,7 +43,6 @@ deps debian/tmp -debian/osmo-remsim-* debian/libosmo-rspro0 debian/libosmo-rspro-dev debian/*.substvars diff --git a/configure.ac b/configure.ac index a49c79b..04040b2 100644 --- a/configure.ac +++ b/configure.ac @@ -91,6 +91,15 @@ AM_CONDITIONAL(BUILD_CLIENT_IFDHANDLER, test "x$osmo_ac_build_client_ifdhandler" = "xyes") AC_SUBST(BUILD_CLIENT_IFDHANDLER) +AC_ARG_ENABLE([remsim-client-socket], [AS_HELP_STRING([--disable-remsim-client-socket], + [Build osmo-remsim-client-socket])], + [osmo_ac_build_client_socket="$enableval"],[osmo_ac_build_client_socket="yes"]) +if test "$osmo_ac_build_client_socket" = "yes"; then + AC_DEFINE(BUILD_CLIENT_SOCKET, 1, [Define if we want to build osmo-remsim-client-socket]) +fi +AM_CONDITIONAL(BUILD_CLIENT_SOCKET, test "x$osmo_ac_build_client_socket" = "xyes") +AC_SUBST(BUILD_CLIENT_SOCKET) + AC_CONFIG_MACRO_DIR([m4]) diff --git a/debian/control b/debian/control index 9351cc5..1110f6b 100644 --- a/debian/control +++ b/debian/control @@ -89,6 +89,14 @@ The remsim-client-shell is for manually interacting with a remote SIM card via remsim-bankd + remsim-server. It's mostly a test/debug tool. +Package: osmo-remsim-client-socket +Architecture: any +Multi-Arch: same +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Osmocom Remote SIM - Socket Client + The remsim-client-socket is similar to remsim-client-shell, but uses a + unix socket instead of stdin and stdout to exchange APDUs. + Package: libifd-osmo-remsim-client0 Architecture: any Multi-Arch: same diff --git a/debian/osmo-remsim-client-socket.install b/debian/osmo-remsim-client-socket.install new file mode 100644 index 0000000..195a7c5 --- /dev/null +++ b/debian/osmo-remsim-client-socket.install @@ -0,0 +1 @@ +usr/bin/osmo-remsim-client-socket diff --git a/src/client/Makefile.am b/src/client/Makefile.am index 5ddd58f..844ad79 100644 --- a/src/client/Makefile.am +++ b/src/client/Makefile.am @@ -65,4 +65,18 @@ $(NULL) endif +if BUILD_CLIENT_SOCKET +bin_PROGRAMS += osmo-remsim-client-socket + +osmo_remsim_client_socket_SOURCES = user_socket.c remsim_client_main.c +osmo_remsim_client_socket_CPPFLAGS = -DSOCKET_SUPPORT +osmo_remsim_client_socket_CFLAGS = $(AM_CFLAGS) +osmo_remsim_client_socket_LDADD = $(builddir)/libremsim_client_common.la \ + $(top_builddir)/src/libosmo-rspro.la \ + $(OSMONETIF_LIBS) \ + $(OSMOGSM_LIBS) \ + $(OSMOCORE_LIBS) \ + $(NULL) +endif + noinst_HEADERS = client.h diff --git a/src/client/client.h b/src/client/client.h index 6ec94b7..9ab0b03 100644 --- a/src/client/client.h +++ b/src/client/client.h @@ -92,6 +92,13 @@ bool presence_valid; bool presence_pol; } simtrace; + +#ifdef SOCKET_SUPPORT + /* only valid for socket client */ + struct { + char *name; + } socket; +#endif }; struct bankd_client { diff --git a/src/client/remsim_client_main.c b/src/client/remsim_client_main.c index c3f36d6..935e25e 100644 --- a/src/client/remsim_client_main.c +++ b/src/client/remsim_client_main.c @@ -39,6 +39,9 @@ #ifdef SIMTRACE_SUPPORT " -Z --set-sim-presence <0-1> Define the presence pin behaviour (only supported on some boards)\n" #endif +#ifdef SOCKET_SUPPORT + " -S --socket-name PATH Unix socket name\n" +#endif #ifdef USB_SUPPORT " -V --usb-vendor VENDOR_ID\n" " -P --usb-product PRODUCT_ID\n" @@ -69,6 +72,9 @@ { "atr-ignore-rspro", 0, 0, 'r' }, { "event-script", 1, 0, 'e' }, {" disable-color", 0, 0, 'L' }, +#ifdef SOCKET_SUPPORT + { "socket-name", 1, 0, 'S' }, +#endif #ifdef USB_SUPPORT { "usb-vendor", 1, 0, 'V' }, { "usb-product", 1, 0, 'P' }, @@ -85,6 +91,9 @@ #ifdef SIMTRACE_SUPPORT "Z:" #endif +#ifdef SOCKET_SUPPORT + "S:" +#endif #ifdef USB_SUPPORT "V:P:C:I:S:A:H:" #endif @@ -140,6 +149,11 @@ cfg->simtrace.presence_pol = atoi(optarg); break; #endif +#ifdef SOCKET_SUPPORT + case 'S': + osmo_talloc_replace_string(cfg, &cfg->socket.name, optarg); + break; +#endif #ifdef USB_SUPPORT case 'V': cfg->usb.vendor_id = strtol(optarg, NULL, 16); diff --git a/src/client/user_socket.c b/src/client/user_socket.c new file mode 100644 index 0000000..483d4c4 --- /dev/null +++ b/src/client/user_socket.c @@ -0,0 +1,162 @@ +#include <errno.h> +#include <unistd.h> +#include <sys/socket.h> +#include <sys/un.h> +#include <osmocom/core/select.h> +#include <osmocom/core/socket.h> + +#include "client.h" + +/* This is a remsim-client with a unix socket to exchange APDUs. */ + +struct socket_state { + struct osmo_fd ofd; + struct sockaddr_un addr; + socklen_t addr_len; + struct bankd_client *bc; +}; + +/*********************************************************************** + * stdin frontend code to remsim-client + ***********************************************************************/ + +int frontend_request_card_insert(struct bankd_client *bc) +{ + LOGP(DMAIN, LOGL_INFO, "SIM inserted\n"); + return 0; +} + +int frontend_request_card_remove(struct bankd_client *bc) +{ + LOGP(DMAIN, LOGL_INFO, "SIM removed\n"); + return 0; +} + +int frontend_request_sim_remote(struct bankd_client *bc) +{ + return 0; +} + +int frontend_request_sim_local(struct bankd_client *bc) +{ + return 0; +} + +int frontend_request_modem_reset(struct bankd_client *bc) +{ + return 0; +} + +int frontend_handle_card2modem(struct bankd_client *bc, const uint8_t *data, size_t len) +{ + struct socket_state *ss = bc->data; + int rc; + + OSMO_ASSERT(data); + + LOGP(DMAIN, LOGL_DEBUG, "APDU response %s\n", osmo_hexdump(data, len)); + + rc = sendto(ss->ofd.fd, data, len, 0, (struct sockaddr *)&ss->addr, ss->addr_len); + if (rc < 0) { + LOGP(DMAIN, LOGL_ERROR, "Failed to write to socket (errno = %d).\n", errno); + return rc; + } + + return 0; +} + +int frontend_handle_set_atr(struct bankd_client *bc, const uint8_t *data, size_t len) +{ + struct socket_state *ss = bc->data; + int rc; + + OSMO_ASSERT(data); + + /* Ignore the locally generated ATR. */ + if (len <= 2) + return 0; + + LOGP(DMAIN, LOGL_DEBUG, "SET_ATR %s\n", osmo_hexdump(data, len)); + + rc = sendto(ss->ofd.fd, data, len, 0, (struct sockaddr *)&ss->addr, ss->addr_len); + if (rc < 0) { + LOGP(DMAIN, LOGL_ERROR, "Failed to write to socket (errno = %d).\n", errno); + return rc; + } + return 0; +} + +int frontend_handle_slot_status(struct bankd_client *bc, const SlotPhysStatus_t *sts) +{ + return 0; +} + +int frontend_append_script_env(struct bankd_client *bc, char **env, int idx, size_t max_env) +{ + return idx; +} + + +/*********************************************************************** + * Incoming command from the user application (stdin shell in our case) + ***********************************************************************/ + +/* call-back function for socket read. */ +static int socket_fd_cb(struct osmo_fd *ofd, unsigned int what) +{ + struct socket_state *ss = ofd->data; + struct frontend_tpdu ftpdu; + uint8_t buf[1024]; + int rc; + + OSMO_ASSERT(what & OSMO_FD_READ); + + ss->addr_len = sizeof(ss->addr); + rc = recvfrom(ss->ofd.fd, buf, sizeof(buf), 0, (struct sockaddr *)&ss->addr, &ss->addr_len); + if (rc < 0) { + LOGP(DMAIN, LOGL_ERROR, "Failed to read from socket (errno = %d).\n", errno); + return rc; + } + if (rc == 0) { + /* Ignore empty frame. */ + return 0; + } + + LOGP(DMAIN, LOGL_DEBUG, "APDU request %s\n", osmo_hexdump(buf, rc)); + ftpdu.buf = buf; + ftpdu.len = rc; + osmo_fsm_inst_dispatch(ss->bc->main_fi, MF_E_MDM_TPDU, &ftpdu); + + return 0; +} + +/* main function */ +int client_user_main(struct bankd_client *bc) +{ + struct client_config *cfg = bc->cfg; + struct socket_state ss; + int rc; + + memset(&ss, 0, sizeof(ss)); + ss.bc = bc; + bc->data = &ss; + + if (!cfg->socket.name) { + LOGP(DMAIN, LOGL_ERROR, "No socket name specified.\n"); + return -1; + } + rc = osmo_sock_unix_init(SOCK_DGRAM, 0, cfg->socket.name, OSMO_SOCK_F_BIND); + if (rc < 0) { + LOGP(DMAIN, LOGL_ERROR, "Failed to create socket with name '%s' (errno = %d).\n", + cfg->socket.name, errno); + return -1; + } + osmo_fd_setup(&ss.ofd, rc, OSMO_FD_READ, &socket_fd_cb, &ss, 0); + + rc = osmo_fd_register(&ss.ofd); + if (rc < 0) + return rc; + + while (1) + osmo_select_main(0); +} -- To view, visit https://gerrit.osmocom.org/c/osmo-remsim/+/43742?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-remsim Gerrit-Branch: master Gerrit-Change-Id: I9eddb60e4e7c3191ca2b340690416b53005f714f Gerrit-Change-Number: 43742 Gerrit-PatchSet: 8 Gerrit-Owner: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: lynxis <lynxis(a)fe80.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-remsim[master]: Add osmo-remsim-client-socket usage to documentation
by laforge 18 Nov '26

18 Nov '26
laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-remsim/+/43815?usp=email ) ( 7 is the latest approved patch-set. No files were changed between the latest approved patch-set and the submitted one. )Change subject: Add osmo-remsim-client-socket usage to documentation ...................................................................... Add osmo-remsim-client-socket usage to documentation Change-Id: Ia52628a99229e615093b80748696d5849d6f0f05 --- M doc/manuals/chapters/remsim-client.adoc 1 file changed, 48 insertions(+), 0 deletions(-) Approvals: Jenkins Builder: Verified pespin: Looks good to me, approved diff --git a/doc/manuals/chapters/remsim-client.adoc b/doc/manuals/chapters/remsim-client.adoc index f5d5550..d7e2a27 100644 --- a/doc/manuals/chapters/remsim-client.adoc +++ b/doc/manuals/chapters/remsim-client.adoc @@ -216,6 +216,7 @@ *osmo-remsim-client-shell* [...] +[#osmo-remsim-client-shell-options] ==== OPTIONS *-h, --help*:: @@ -264,6 +265,53 @@ The program continues in this loop (read command APDU as hex-dump from stdin; provide response on stdout) until it is terminated by Ctrl+C or by other means. +== osmo-remsim-client-socket + +The osmo-remsim-client-socket is similar to osmo-remsim-client-shell, but uses a Unix socket instead of stdin and +stdout to exchange APDUs. + +This allows applications to access a remote SIM without implementing the RSPro protocol. The application must +implement a Unix socket client. + +=== Running + +osmo-remsim-client-socket currently has the following command-line options: + +==== SYNOPSIS + +*osmo-remsim-client-shell* -S PATH [...] + +==== OPTIONS + +All options of <<osmo-remsim-client-shell-options, osmo-remsim-client-shell>> apply to osmo-remsim-client-socket. +Additionally the following option is available: + +*-S, --socket-name PATH*:: + Specify the Unix socket name. An application connects to this socket to exchange APDUs. + +==== Examples + +.remsim-server is at 192.168.11.10; we are client 23 slot 0 +---- +./osmo-remsim-client-socket -i 192.168.11.10 -c 23 -S /tmp/remsim_c23_s0 +DRSPRO INFO ../rspro_client_fsm.c:454 RSPRO_CLIENT(bankd){REESTABLISH}: Creating TCP connection to server at 192.168.11.10:9999 +DRSPRO NOTICE ../rspro_client_fsm.c:145 RSPRO_CLIENT(bankd){REESTABLISH}: RSPRO link to 192.168.11.10:9999 UP +DMAIN INFO user_socket.c:25 SIM inserted +DMAIN NOTICE main_fsm.c:280 CLIENT_MAIN(main){OPERATIONAL}: Rx setAtrReq(3b9f96801f878031e073fe211b674a4c753034054ba9) +DMAIN INFO user_socket.c:79 SET_ATR 3b 9f 96 80 1f 87 80 31 e0 73 fe 21 1b 67 4a 4c 75 30 34 05 4b a9 +DMAIN INFO main_fsm.c:339 CLIENT_MAIN(main){OPERATIONAL}: Tx tpduModemToCard (0070000001) +DMAIN NOTICE main_fsm.c:268 CLIENT_MAIN(main){OPERATIONAL}: Rx tpduCardToModem(019000) +DMAIN INFO user_socket.c:57 APDU response 01 90 00 +... +---- + +* The SET_ATR is performed by osmo-remsim-bankd to inform the Unix socket client about the ATR of the real remote card. +* The `0070000001` is a command TPDU sent by the socket client +* The `019000` is a response TPDU provided by the remote card in response to the command + +The program continues in this loop (exchange APDUs between remote card and Unix socket client) +until it is terminated by Ctrl+C or by other means. + == libifd_remsim_client This is a remsim-client implemented as so-called `ifd_handler`, i.e. a card reader driver -- To view, visit https://gerrit.osmocom.org/c/osmo-remsim/+/43815?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-remsim Gerrit-Branch: master Gerrit-Change-Id: Ia52628a99229e615093b80748696d5849d6f0f05 Gerrit-Change-Number: 43815 Gerrit-PatchSet: 8 Gerrit-Owner: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[M] Change in osmo-remsim[master]: Introduce osmo-remsim-client-socket
by laforge 18 Nov '26

18 Nov '26
Attention is currently required from: jolly, lynxis. laforge has posted comments on this change by jolly. ( https://gerrit.osmocom.org/c/osmo-remsim/+/43742?usp=email ) Change subject: Introduce osmo-remsim-client-socket ...................................................................... Patch Set 8: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-remsim/+/43742?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-remsim Gerrit-Branch: master Gerrit-Change-Id: I9eddb60e4e7c3191ca2b340690416b53005f714f Gerrit-Change-Number: 43742 Gerrit-PatchSet: 8 Gerrit-Owner: jolly <andreas(a)eversberg.eu> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: lynxis <lynxis(a)fe80.eu> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: lynxis <lynxis(a)fe80.eu> Gerrit-Attention: jolly <andreas(a)eversberg.eu> Gerrit-Comment-Date: Wed, 18 Nov 2026 14:36:01 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[XS] Change in docker-playground[master]: gerrit: upload to registry.osmocom.org
by laforge 18 Nov '26

18 Nov '26
laforge has submitted this change. ( https://gerrit.osmocom.org/c/docker-playground/+/44136?usp=email ) Change subject: gerrit: upload to registry.osmocom.org ...................................................................... gerrit: upload to registry.osmocom.org As discussed with Harald, let's move this to registry.osmocom.org. Change-Id: I34486624f8a57de2fd68bcc1fd85234ecc07f17c --- M gerrit/Makefile 1 file changed, 1 insertion(+), 1 deletion(-) Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve diff --git a/gerrit/Makefile b/gerrit/Makefile index 0a3f0e8..ab61c14 100644 --- a/gerrit/Makefile +++ b/gerrit/Makefile @@ -1,3 +1,3 @@ -IMAGE=registry.sysmocom.de/gerrit +IMAGE=registry.osmocom.org/gerrit include ../make/Makefile -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/44136?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I34486624f8a57de2fd68bcc1fd85234ecc07f17c Gerrit-Change-Number: 44136 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[XS] Change in docker-playground[master]: gerrit: upload to registry.osmocom.org
by laforge 18 Nov '26

18 Nov '26
Attention is currently required from: osmith. laforge has posted comments on this change by osmith. ( https://gerrit.osmocom.org/c/docker-playground/+/44136?usp=email ) Change subject: gerrit: upload to registry.osmocom.org ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/docker-playground/+/44136?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: docker-playground Gerrit-Branch: master Gerrit-Change-Id: I34486624f8a57de2fd68bcc1fd85234ecc07f17c Gerrit-Change-Number: 44136 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: osmith <osmith(a)sysmocom.de> Gerrit-Comment-Date: Wed, 18 Nov 2026 14:35:42 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[XS] Change in osmo-msc[master]: codec mapping: add support for compressed CSD
by laforge 18 Nov '26

18 Nov '26
Attention is currently required from: falconia. laforge has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/osmo-msc/+/44046?usp=email ) Change subject: codec mapping: add support for compressed CSD ...................................................................... Patch Set 5: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/44046?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-msc Gerrit-Branch: master Gerrit-Change-Id: I97964ef7edeab3bb29300adb03a8374725eb2a1e Gerrit-Change-Number: 44046 Gerrit-PatchSet: 5 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Attention: falconia <falcon(a)freecalypso.org> Gerrit-Comment-Date: Wed, 18 Nov 2026 14:35:16 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[S] Change in osmo-msc[master]: mgw: add type selection between rtpbridge and transcoder
by laforge 18 Nov '26

18 Nov '26
Attention is currently required from: falconia, neels, pespin. laforge has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/osmo-msc/+/44002?usp=email ) Change subject: mgw: add type selection between rtpbridge and transcoder ...................................................................... Patch Set 5: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/44002?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-msc Gerrit-Branch: master Gerrit-Change-Id: I095ab75b65f57583ab7f579ba419bbfbfa686afa Gerrit-Change-Number: 44002 Gerrit-PatchSet: 5 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de> Gerrit-CC: pespin <pespin(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Attention: falconia <falcon(a)freecalypso.org> Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de> Gerrit-Comment-Date: Wed, 18 Nov 2026 14:35:00 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[S] Change in osmo-bsc[master]: mgw: add vty option to send X-Side with CRCX
by laforge 18 Nov '26

18 Nov '26
laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/44050?usp=email ) Change subject: mgw: add vty option to send X-Side with CRCX ...................................................................... mgw: add vty option to send X-Side with CRCX When OsmoBSC operates with IP-based BTS and AoIP-based MSC, it requests rtpbridge/* endpoints from its associated MGW and sends 2 CRCX commands to each such endpoint, one for AoIP side and one for Abis side. Since a similar change in OsmoMSC, we now have ability to add X-Side extension parameter to each CRCX command, indicating which side of rtpbridge is being connected. Add vty option to send these X-Side extension lines, with "AoIP" and "Abis" as side names for BSC-associated rtpbridge endpoints. Standard OsmoMGW ignores these X-Side extension lines, but they are still potentially useful in some scenarios: 1) They aid debugging via packet capture, making it clearly visible in pcap which CRCX and which resulting ConnectionId corresponds to which side of the BSC; 2) Some network operators may wish to replace osmo-mgw with their own custom implementations, and some implementors of such alternative MGWs for OsmoBSC and OsmoMSC strongly prefer to have a known association of each MGCP connection to a specific side from initial CRCX onward. Depends: I713147d6567fb30de09b2272478d717093d6170e (osmo-mgw.git) Change-Id: I8e561dcf06028f8fd5cd154c075c984b4c744738 --- M TODO-RELEASE M include/osmocom/bsc/gsm_data.h M src/osmo-bsc/bsc_subscr_conn_fsm.c M src/osmo-bsc/bsc_vty.c M src/osmo-bsc/lchan_rtp_fsm.c 5 files changed, 39 insertions(+), 1 deletion(-) Approvals: Jenkins Builder: Verified laforge: Looks good to me, approved pespin: Looks good to me, but someone else must approve diff --git a/TODO-RELEASE b/TODO-RELEASE index 510eed7..5f331ea 100644 --- a/TODO-RELEASE +++ b/TODO-RELEASE @@ -9,3 +9,4 @@ #library what description / commit summary line libosmo-sigtran >2.3.0 OSMO_SCCP_REL_REASON_NSU_*, libosmo-sigtran >2.3.0 OSMO_SCCP_RETURN_REASON_*, osmo_sccp_return_reason_name() +libosmo-mgcp-client >1.16.0 x_side[] in struct mgcp_conn_peer diff --git a/include/osmocom/bsc/gsm_data.h b/include/osmocom/bsc/gsm_data.h index cb19536..99387ed 100644 --- a/include/osmocom/bsc/gsm_data.h +++ b/include/osmocom/bsc/gsm_data.h @@ -1079,6 +1079,10 @@ /* Timer definitions, the same for all MGW pool members */ struct osmo_tdef *tdefs; + + /* Should we send X-Side extension parameter line to our + * attached MGW, telling it which CRCX is for A vs Abis? */ + bool indicate_side; } mgw; /* Remote BSS resolution sevice (CTRL iface) */ diff --git a/src/osmo-bsc/bsc_subscr_conn_fsm.c b/src/osmo-bsc/bsc_subscr_conn_fsm.c index 4ea0053..99ca8dc 100644 --- a/src/osmo-bsc/bsc_subscr_conn_fsm.c +++ b/src/osmo-bsc/bsc_subscr_conn_fsm.c @@ -842,8 +842,11 @@ } verb = MGCP_VERB_MDCX; - } else + } else { verb = MGCP_VERB_CRCX; + if (bsc_gsmnet->mgw.indicate_side) + OSMO_STRLCPY_ARRAY(mgw_info.x_side, "AoIP"); + } gscon_ensure_mgw_endpoint(conn, for_lchan->activate.info.msc_assigned_cic, for_lchan); diff --git a/src/osmo-bsc/bsc_vty.c b/src/osmo-bsc/bsc_vty.c index e9dabf9..6cead87 100644 --- a/src/osmo-bsc/bsc_vty.c +++ b/src/osmo-bsc/bsc_vty.c @@ -2731,6 +2731,9 @@ vty_out(vty, " bts-setup-ramping-step-interval %d%s", bsc_gsmnet->bts_setup_ramp.step_interval, VTY_NEWLINE); + if (bsc_gsmnet->mgw.indicate_side) + vty_out(vty, " mgw indicate-side%s", VTY_NEWLINE); + return CMD_SUCCESS; } @@ -3217,6 +3220,28 @@ return CMD_SUCCESS; } +DEFUN_USRATTR(cfg_bsc_mgw_side, + cfg_bsc_mgw_side_cmd, + X(BSC_VTY_ATTR_NEW_LCHAN), + "mgw indicate-side", + MGCP_CLIENT_MGW_STR + "Send X-Side extension parameter with CRCX commands\n") +{ + bsc_gsmnet->mgw.indicate_side = true; + return CMD_SUCCESS; +} + +DEFUN_USRATTR(cfg_bsc_no_mgw_side, + cfg_bsc_no_mgw_side_cmd, + X(BSC_VTY_ATTR_NEW_LCHAN), + "no mgw indicate-side", + NO_STR MGCP_CLIENT_MGW_STR + "Send X-Side extension parameter with CRCX commands\n") +{ + bsc_gsmnet->mgw.indicate_side = false; + return CMD_SUCCESS; +} + DEFUN(bts_unblock_setup_ramping, bts_unblock_setup_ramping_cmd, "bts " BTS_NR_VTY_ARG_VAL " unblock-setup-ramping", @@ -3731,6 +3756,8 @@ install_element(BSC_NODE, &cfg_bsc_no_bts_setup_ramping_cmd); install_element(BSC_NODE, &cfg_bsc_bts_setup_ramping_step_size_cmd); install_element(BSC_NODE, &cfg_bsc_bts_setup_ramping_step_interval_cmd); + install_element(BSC_NODE, &cfg_bsc_mgw_side_cmd); + install_element(BSC_NODE, &cfg_bsc_no_mgw_side_cmd); install_node(&msc_node, config_write_msc); install_element(MSC_NODE, &cfg_net_msc_ncc_cmd); diff --git a/src/osmo-bsc/lchan_rtp_fsm.c b/src/osmo-bsc/lchan_rtp_fsm.c index 4d0217b..d88a7ba 100644 --- a/src/osmo-bsc/lchan_rtp_fsm.c +++ b/src/osmo-bsc/lchan_rtp_fsm.c @@ -196,6 +196,9 @@ break; } + if (bsc_gsmnet->mgw.indicate_side) + OSMO_STRLCPY_ARRAY(crcx_info.x_side, "Abis"); + osmo_mgcpc_ep_ci_request(lchan->mgw_endpoint_ci_bts, MGCP_VERB_CRCX, &crcx_info, fi, LCHAN_RTP_EV_MGW_ENDPOINT_AVAILABLE, LCHAN_RTP_EV_MGW_ENDPOINT_ERROR, 0); -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/44050?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I8e561dcf06028f8fd5cd154c075c984b4c744738 Gerrit-Change-Number: 44050 Gerrit-PatchSet: 1 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
[S] Change in osmo-bsc[master]: mgw: add vty option to send X-Side with CRCX
by laforge 18 Nov '26

18 Nov '26
Attention is currently required from: falconia, fixeria. laforge has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/osmo-bsc/+/44050?usp=email ) Change subject: mgw: add vty option to send X-Side with CRCX ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/44050?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: I8e561dcf06028f8fd5cd154c075c984b4c744738 Gerrit-Change-Number: 44050 Gerrit-PatchSet: 1 Gerrit-Owner: falconia <falcon(a)freecalypso.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de> Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Attention: falconia <falcon(a)freecalypso.org> Gerrit-Comment-Date: Wed, 18 Nov 2026 14:34:04 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes
1 0
0 0
[XS] Change in libosmocore[master]: gsm: Add missing osmo_sai_name* symbols to libosmogsm.map
by pespin 18 Nov '26

18 Nov '26
pespin has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/44100?usp=email ) Change subject: gsm: Add missing osmo_sai_name* symbols to libosmogsm.map ...................................................................... gsm: Add missing osmo_sai_name* symbols to libosmogsm.map osmo_sai_name(), osmo_sai_name2(), osmo_sai_name_buf() and osmo_sai_name_c() are declared in gsm23003.h but were missing from libosmogsm.map, so they were not exported from the shared library. Change-Id: I1f1673129a569e3eb0bb221f3a706d9041a6e35e --- M src/gsm/libosmogsm.map 1 file changed, 4 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/src/gsm/libosmogsm.map b/src/gsm/libosmogsm.map index c57d286..88ee3ae 100644 --- a/src/gsm/libosmogsm.map +++ b/src/gsm/libosmogsm.map @@ -500,6 +500,10 @@ osmo_cgi_ps_name_buf; osmo_cgi_ps_name_c; osmo_cgi_ps_name2; +osmo_sai_name; +osmo_sai_name_buf; +osmo_sai_name_c; +osmo_sai_name2; osmo_rnc_id_name; osmo_rnc_id_name_buf; osmo_rnc_id_name_c; -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/44100?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I1f1673129a569e3eb0bb221f3a706d9041a6e35e Gerrit-Change-Number: 44100 Gerrit-PatchSet: 3 Gerrit-Owner: bucketking657 <joshuashilts(a)gmail.com> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de> Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • ...
  • 72
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.