Compare commits

...

4 Commits

Author SHA1 Message Date
Oliver Smith 67d1c27ea1 Bump version: 1.9.1.1-11e513 → 1.9.2
Change-Id: I10cee768b1c02ee81dc489a455d19eef8e5c0790
2023-05-26 14:46:59 +02:00
Oliver Smith 11e5131f05 systemd: depend on networking-online.target
Related: SYS#6400
Change-Id: I9c0cc0779f9ddb7520a565668b7cde07c6ad55d8
2023-05-26 14:46:36 +02:00
Oliver Smith 779dd053ec Bump version: 1.9.0.1-1ed5 → 1.9.1
Change-Id: Ib4d196f47adc9d2efb179f3bbbcc949b98a326ab
2023-02-08 11:08:47 +01:00
Vadim Yanitskiy 1ed5fbf657 fix bsc_vty_go_parent(): add missing case for MGW_NODE
A new VTY node was added in commit [1], but bsc_vty_go_parent() was
not updated.  Because of that, commands following the MGW node may
crash osmo-bsc.  In the example below:

  network
   network country code 901
   mobile network code 70
   ...
   mgw 0
    remote-ip 127.0.0.1
    local-ip 127.0.0.1
   periodic location update 30

the 'periodic location update 30' will trigger a segfault:

  (gdb) bt
  #0  0x00005555555dfc09 in cfg_net_per_loc_upd ()
  #1  0x00007ffff7af6c3f in cmd_execute_command_strict () from /usr/local/lib/libosmovty.so.9
  #2  0x00007ffff7af6f1c in config_from_file () from /usr/local/lib/libosmovty.so.9
  #3  0x00007ffff7afd4e1 in vty_read_config_filep () from /usr/local/lib/libosmovty.so.9
  #4  0x00007ffff7afe375 in vty_read_config_file () from /usr/local/lib/libosmovty.so.9
  #5  0x0000555555579616 in bsc_network_configure ()
  #6  0x000055555557a352 in main ()

because vty->index would be NULL after returning from the MGW node.

Fix this by adding the missing case to bsc_vty_go_parent().

Change-Id: Id3050ff7e2402c33ee76c7bf0cc83603c0cc6dfc
Fixes: [1] 8d22e68706
(cherry picked from commit 57800ec48e)
2023-02-08 11:06:35 +01:00
3 changed files with 20 additions and 0 deletions

View File

@ -1,6 +1,8 @@
[Unit]
Description=Osmocom Base Station Controller (BSC)
Wants=osmo-mgw.service
After=network-online.target
Wants=network-online.target
[Service]
Type=simple

13
debian/changelog vendored
View File

@ -1,3 +1,16 @@
osmo-bsc (1.9.2) unstable; urgency=medium
* systemd: depend on networking-online.target
-- Oliver Smith <osmith@sysmocom.de> Fri, 26 May 2023 14:46:58 +0200
osmo-bsc (1.9.1) unstable; urgency=medium
[ Vadim Yanitskiy ]
* fix bsc_vty_go_parent(): add missing case for MGW_NODE
-- Oliver Smith <osmith@sysmocom.de> Wed, 08 Feb 2023 11:08:46 +0100
osmo-bsc (1.9.0) unstable; urgency=medium
[ Philipp Maier ]

View File

@ -518,6 +518,11 @@ static int bsc_vty_go_parent(struct vty *vty)
vty->node = CONFIG_NODE;
vty->index = NULL;
break;
case MGW_NODE:
vty->node = GSMNET_NODE;
vty->index = bsc_gsmnet;
vty->index_sub = NULL;
break;
case BTS_NODE:
vty->node = GSMNET_NODE;
{