Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 1 | /* MGCP client interface to quagga VTY */ |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 2 | /* (C) 2016 by sysmocom s.m.f.c. GmbH <info@sysmocom.de> |
| 3 | * Based on OpenBSC interface to quagga VTY (libmsc/vty_interface_layer3.c) |
| 4 | * (C) 2009 by Harald Welte <laforge@gnumonks.org> |
| 5 | * (C) 2009-2011 by Holger Hans Peter Freyther |
| 6 | * All Rights Reserved |
| 7 | * |
| 8 | * This program is free software; you can redistribute it and/or modify |
Harald Welte | 220f487 | 2018-02-04 09:04:16 +0100 | [diff] [blame] | 9 | * it under the terms of the GNU General Public License as published by |
| 10 | * the Free Software Foundation; either version 2 of the License, or |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 11 | * (at your option) any later version. |
| 12 | * |
| 13 | * This program is distributed in the hope that it will be useful, |
| 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
Harald Welte | 220f487 | 2018-02-04 09:04:16 +0100 | [diff] [blame] | 16 | * GNU General Public License for more details. |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 17 | * |
Harald Welte | 220f487 | 2018-02-04 09:04:16 +0100 | [diff] [blame] | 18 | * You should have received a copy of the GNU General Public License |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 19 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 20 | * |
| 21 | */ |
| 22 | |
| 23 | #include <inttypes.h> |
| 24 | #include <stdlib.h> |
| 25 | #include <talloc.h> |
| 26 | |
| 27 | #include <osmocom/vty/command.h> |
Stefan Sperling | 2924825 | 2018-02-22 18:09:28 +0100 | [diff] [blame] | 28 | #include <osmocom/vty/misc.h> |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 29 | #include <osmocom/core/utils.h> |
| 30 | |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 31 | #include <osmocom/mgcp_client/mgcp_client.h> |
Philipp Maier | 3f2c15f | 2021-07-22 11:53:07 +0200 | [diff] [blame] | 32 | #include <osmocom/mgcp_client/mgcp_client_internal.h> |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 33 | |
Neels Hofmeyr | e6d8e91 | 2018-08-23 16:36:48 +0200 | [diff] [blame] | 34 | #define MGW_STR MGCP_CLIENT_MGW_STR |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 35 | |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 36 | void *global_mgcp_client_ctx = NULL; |
| 37 | struct mgcp_client_conf *global_mgcp_client_conf = NULL; |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 38 | |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 39 | DEFUN(cfg_mgw_local_ip, cfg_mgw_local_ip_cmd, |
Pau Espin Pedrol | 531470a | 2020-08-31 17:06:55 +0200 | [diff] [blame] | 40 | "mgw local-ip " VTY_IPV46_CMD, |
Neels Hofmeyr | 54dd4b3 | 2017-10-31 01:18:33 +0100 | [diff] [blame] | 41 | MGW_STR "local bind to connect to MGW from\n" |
Pau Espin Pedrol | 531470a | 2020-08-31 17:06:55 +0200 | [diff] [blame] | 42 | "local bind IPv4 address\n" |
| 43 | "local bind IPv6 address\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 44 | { |
Neels Hofmeyr | c3132fd | 2018-12-19 00:30:34 +0100 | [diff] [blame] | 45 | osmo_talloc_replace_string(global_mgcp_client_ctx, |
| 46 | (char**)&global_mgcp_client_conf->local_addr, |
| 47 | argv[0]); |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 48 | return CMD_SUCCESS; |
| 49 | } |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 50 | ALIAS_DEPRECATED(cfg_mgw_local_ip, cfg_mgcpgw_local_ip_cmd, |
| 51 | "mgcpgw local-ip A.B.C.D", |
| 52 | MGW_STR "local bind to connect to MGCP gateway with\n" |
| 53 | "local bind IP address\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 54 | |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 55 | DEFUN(cfg_mgw_local_port, cfg_mgw_local_port_cmd, |
| 56 | "mgw local-port <0-65535>", |
Neels Hofmeyr | 54dd4b3 | 2017-10-31 01:18:33 +0100 | [diff] [blame] | 57 | MGW_STR "local port to connect to MGW from\n" |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 58 | "local bind port\n") |
| 59 | { |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 60 | global_mgcp_client_conf->local_port = atoi(argv[0]); |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 61 | return CMD_SUCCESS; |
| 62 | } |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 63 | ALIAS_DEPRECATED(cfg_mgw_local_port, cfg_mgcpgw_local_port_cmd, |
| 64 | "mgcpgw local-port <0-65535>", |
| 65 | MGW_STR "local bind to connect to MGCP gateway with\n" |
| 66 | "local bind port\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 67 | |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 68 | DEFUN(cfg_mgw_remote_ip, cfg_mgw_remote_ip_cmd, |
Pau Espin Pedrol | 531470a | 2020-08-31 17:06:55 +0200 | [diff] [blame] | 69 | "mgw remote-ip " VTY_IPV46_CMD, |
Neels Hofmeyr | 54dd4b3 | 2017-10-31 01:18:33 +0100 | [diff] [blame] | 70 | MGW_STR "remote IP address to reach the MGW at\n" |
Pau Espin Pedrol | 531470a | 2020-08-31 17:06:55 +0200 | [diff] [blame] | 71 | "remote IPv4 address\n" |
| 72 | "remote IPv6 address\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 73 | { |
Neels Hofmeyr | c3132fd | 2018-12-19 00:30:34 +0100 | [diff] [blame] | 74 | osmo_talloc_replace_string(global_mgcp_client_ctx, |
| 75 | (char**)&global_mgcp_client_conf->remote_addr, |
| 76 | argv[0]); |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 77 | return CMD_SUCCESS; |
| 78 | } |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 79 | ALIAS_DEPRECATED(cfg_mgw_remote_ip, cfg_mgcpgw_remote_ip_cmd, |
| 80 | "mgcpgw remote-ip A.B.C.D", |
| 81 | MGW_STR "remote bind to connect to MGCP gateway with\n" |
| 82 | "remote bind IP address\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 83 | |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 84 | DEFUN(cfg_mgw_remote_port, cfg_mgw_remote_port_cmd, |
| 85 | "mgw remote-port <0-65535>", |
Neels Hofmeyr | 54dd4b3 | 2017-10-31 01:18:33 +0100 | [diff] [blame] | 86 | MGW_STR "remote port to reach the MGW at\n" |
| 87 | "remote port\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 88 | { |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 89 | global_mgcp_client_conf->remote_port = atoi(argv[0]); |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 90 | return CMD_SUCCESS; |
| 91 | } |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 92 | ALIAS_DEPRECATED(cfg_mgw_remote_port, cfg_mgcpgw_remote_port_cmd, |
| 93 | "mgcpgw remote-port <0-65535>", |
| 94 | MGW_STR "remote bind to connect to MGCP gateway with\n" |
| 95 | "remote bind port\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 96 | |
Neels Hofmeyr | 72bc8da | 2018-12-19 00:44:37 +0100 | [diff] [blame] | 97 | DEFUN_DEPRECATED(cfg_mgw_endpoint_range, cfg_mgw_endpoint_range_cmd, |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 98 | "mgw endpoint-range <1-65534> <1-65534>", |
Neels Hofmeyr | 72bc8da | 2018-12-19 00:44:37 +0100 | [diff] [blame] | 99 | MGW_STR "DEPRECATED: the endpoint range cannot be defined by the client\n" |
| 100 | "-\n" "-\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 101 | { |
Neels Hofmeyr | 72bc8da | 2018-12-19 00:44:37 +0100 | [diff] [blame] | 102 | vty_out(vty, "Please do not use legacy config 'mgw endpoint-range'" |
| 103 | " (the range can no longer be defined by the MGCP client)%s", |
| 104 | VTY_NEWLINE); |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 105 | return CMD_SUCCESS; |
| 106 | } |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 107 | ALIAS_DEPRECATED(cfg_mgw_endpoint_range, cfg_mgcpgw_endpoint_range_cmd, |
| 108 | "mgcpgw endpoint-range <1-65534> <1-65534>", |
| 109 | MGW_STR "usable range of endpoint identifiers\n" |
| 110 | "set first useable endpoint identifier\n" |
| 111 | "set the last useable endpoint identifier\n") |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 112 | |
Neels Hofmeyr | c0dcc3c | 2017-12-02 18:31:34 +0000 | [diff] [blame] | 113 | #define BTS_START_STR "First UDP port allocated for the BTS side\n" |
| 114 | #define UDP_PORT_STR "UDP Port number\n" |
Neels Hofmeyr | 72bc8da | 2018-12-19 00:44:37 +0100 | [diff] [blame] | 115 | DEFUN_DEPRECATED(cfg_mgw_rtp_bts_base_port, |
Neels Hofmeyr | c0dcc3c | 2017-12-02 18:31:34 +0000 | [diff] [blame] | 116 | cfg_mgw_rtp_bts_base_port_cmd, |
| 117 | "mgw bts-base <0-65534>", |
| 118 | MGW_STR |
Neels Hofmeyr | 72bc8da | 2018-12-19 00:44:37 +0100 | [diff] [blame] | 119 | "DEPRECATED: there is no explicit BTS side in current osmo-mgw\n" "-\n") |
Neels Hofmeyr | c0dcc3c | 2017-12-02 18:31:34 +0000 | [diff] [blame] | 120 | { |
Neels Hofmeyr | 72bc8da | 2018-12-19 00:44:37 +0100 | [diff] [blame] | 121 | vty_out(vty, "Please do not use legacy config 'mgw bts-base'" |
| 122 | " (there is no explicit BTS side in an MGW anymore)%s", |
| 123 | VTY_NEWLINE); |
Neels Hofmeyr | c0dcc3c | 2017-12-02 18:31:34 +0000 | [diff] [blame] | 124 | return CMD_SUCCESS; |
| 125 | } |
| 126 | ALIAS_DEPRECATED(cfg_mgw_rtp_bts_base_port, |
| 127 | cfg_mgcpgw_rtp_bts_base_port_cmd, |
| 128 | "mgcpgw bts-base <0-65534>", |
| 129 | MGW_STR |
| 130 | BTS_START_STR |
| 131 | UDP_PORT_STR) |
| 132 | |
Neels Hofmeyr | ac69ea9 | 2018-12-19 00:27:50 +0100 | [diff] [blame] | 133 | DEFUN(cfg_mgw_endpoint_domain_name, |
| 134 | cfg_mgw_endpoint_domain_name_cmd, |
| 135 | "mgw endpoint-domain NAME", |
| 136 | MGW_STR "Set the domain name to send in MGCP messages, e.g. the part 'foo' in 'rtpbridge/*@foo'.\n" |
| 137 | "Domain name, should be alphanumeric.\n") |
| 138 | { |
| 139 | if (osmo_strlcpy(global_mgcp_client_conf->endpoint_domain_name, argv[0], |
| 140 | sizeof(global_mgcp_client_conf->endpoint_domain_name)) |
| 141 | >= sizeof(global_mgcp_client_conf->endpoint_domain_name)) { |
| 142 | vty_out(vty, "%% Error: 'mgw endpoint-domain' name too long, max length is %zu: '%s'%s", |
| 143 | sizeof(global_mgcp_client_conf->endpoint_domain_name) - 1, argv[0], VTY_NEWLINE); |
| 144 | return CMD_WARNING; |
| 145 | } |
| 146 | return CMD_SUCCESS; |
| 147 | } |
| 148 | |
Philipp Maier | 3f2c15f | 2021-07-22 11:53:07 +0200 | [diff] [blame] | 149 | DEFUN(cfg_mgw_reset_ep_name, |
| 150 | cfg_mgw_reset_ep_name_cmd, |
| 151 | "mgw reset-endpoint NAME", |
| 152 | MGW_STR "Add an endpoint name that should be reset (DLCX) on connect to the reset-endpoint list," |
| 153 | "e.g. 'rtpbridge/*'\n" |
| 154 | "Endpoint name, e.g. 'rtpbridge/*' or 'ds/e1-0/s-3/su16-4'.\n") |
| 155 | { |
| 156 | int rc; |
| 157 | struct reset_ep *reset_ep; |
| 158 | |
| 159 | /* stop when the address is already in the list */ |
| 160 | llist_for_each_entry(reset_ep, &global_mgcp_client_conf->reset_epnames, list) { |
| 161 | if (strcmp(argv[0], reset_ep->name) == 0) { |
| 162 | vty_out(vty, "%% duplicate endpoint name configured ('%s')%s", argv[0], VTY_NEWLINE); |
| 163 | return CMD_WARNING; |
| 164 | } |
| 165 | } |
| 166 | |
| 167 | /* the domain name is not part of the actual endpoint name */ |
| 168 | if (strchr(argv[0], '@')) { |
| 169 | vty_out(vty, "%% the endpoint name must be given without domain name ('%s')%s", |
| 170 | argv[0], VTY_NEWLINE); |
| 171 | return CMD_WARNING; |
| 172 | } |
| 173 | |
| 174 | reset_ep = talloc_zero(global_mgcp_client_ctx, struct reset_ep); |
| 175 | OSMO_ASSERT(reset_ep); |
| 176 | |
| 177 | rc = osmo_strlcpy(reset_ep->name, argv[0], sizeof(reset_ep->name)); |
| 178 | if (rc >= sizeof(reset_ep->name)) { |
| 179 | vty_out(vty, "%% Error: 'mgw reset-endpoint' name too long, max length is %zu: '%s'%s", |
| 180 | sizeof(reset_ep->name) - 1, argv[0], VTY_NEWLINE); |
| 181 | talloc_free(reset_ep); |
| 182 | return CMD_WARNING; |
| 183 | } |
| 184 | |
| 185 | llist_add_tail(&reset_ep->list, &global_mgcp_client_conf->reset_epnames); |
| 186 | |
| 187 | return CMD_SUCCESS; |
| 188 | } |
| 189 | |
| 190 | DEFUN(cfg_mgw_no_reset_ep_name, |
| 191 | cfg_mgw_no_reset_ep_name_cmd, |
| 192 | "no mgw reset-endpoint NAME", |
| 193 | MGW_STR "remove an endpoint name from the reset-endpoint list, e.g. 'rtpbridge/*'\n" |
| 194 | "Endpoint name, e.g. 'rtpbridge/*' or 'ds/e1-0/s-3/su16-4'.\n") |
| 195 | { |
| 196 | struct reset_ep *reset_ep; |
| 197 | |
| 198 | llist_for_each_entry(reset_ep, &global_mgcp_client_conf->reset_epnames, list) { |
| 199 | if (strcmp(argv[0], reset_ep->name) == 0) { |
| 200 | llist_del(&reset_ep->list); |
| 201 | talloc_free(reset_ep); |
| 202 | return CMD_SUCCESS; |
| 203 | } |
| 204 | } |
| 205 | |
| 206 | vty_out(vty, "%% no such endpoint name configured ('%s')%s", argv[0], VTY_NEWLINE); |
| 207 | return CMD_WARNING; |
| 208 | } |
| 209 | |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 210 | int mgcp_client_config_write(struct vty *vty, const char *indent) |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 211 | { |
| 212 | const char *addr; |
| 213 | int port; |
Philipp Maier | 3f2c15f | 2021-07-22 11:53:07 +0200 | [diff] [blame] | 214 | struct reset_ep *reset_ep; |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 215 | |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 216 | addr = global_mgcp_client_conf->local_addr; |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 217 | if (addr) |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 218 | vty_out(vty, "%smgw local-ip %s%s", indent, addr, |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 219 | VTY_NEWLINE); |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 220 | port = global_mgcp_client_conf->local_port; |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 221 | if (port >= 0) |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 222 | vty_out(vty, "%smgw local-port %u%s", indent, |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 223 | (uint16_t)port, VTY_NEWLINE); |
| 224 | |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 225 | addr = global_mgcp_client_conf->remote_addr; |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 226 | if (addr) |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 227 | vty_out(vty, "%smgw remote-ip %s%s", indent, addr, |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 228 | VTY_NEWLINE); |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 229 | port = global_mgcp_client_conf->remote_port; |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 230 | if (port >= 0) |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 231 | vty_out(vty, "%smgw remote-port %u%s", indent, |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 232 | (uint16_t)port, VTY_NEWLINE); |
| 233 | |
Neels Hofmeyr | ac69ea9 | 2018-12-19 00:27:50 +0100 | [diff] [blame] | 234 | if (global_mgcp_client_conf->endpoint_domain_name[0]) |
| 235 | vty_out(vty, "%smgw endpoint-domain %s%s", indent, |
| 236 | global_mgcp_client_conf->endpoint_domain_name, VTY_NEWLINE); |
| 237 | |
Philipp Maier | 3f2c15f | 2021-07-22 11:53:07 +0200 | [diff] [blame] | 238 | llist_for_each_entry(reset_ep, &global_mgcp_client_conf->reset_epnames, list) |
| 239 | vty_out(vty, "%smgw reset-endpoint %s%s", indent, reset_ep->name, VTY_NEWLINE); |
| 240 | |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 241 | return CMD_SUCCESS; |
| 242 | } |
| 243 | |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 244 | void mgcp_client_vty_init(void *talloc_ctx, int node, struct mgcp_client_conf *conf) |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 245 | { |
Neels Hofmeyr | 3a8e723 | 2017-09-04 01:02:56 +0200 | [diff] [blame] | 246 | global_mgcp_client_ctx = talloc_ctx; |
| 247 | global_mgcp_client_conf = conf; |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 248 | |
Vadim Yanitskiy | 3ba4095 | 2020-10-04 16:42:04 +0700 | [diff] [blame] | 249 | install_lib_element(node, &cfg_mgw_local_ip_cmd); |
| 250 | install_lib_element(node, &cfg_mgw_local_port_cmd); |
| 251 | install_lib_element(node, &cfg_mgw_remote_ip_cmd); |
| 252 | install_lib_element(node, &cfg_mgw_remote_port_cmd); |
| 253 | install_lib_element(node, &cfg_mgw_endpoint_range_cmd); |
| 254 | install_lib_element(node, &cfg_mgw_rtp_bts_base_port_cmd); |
| 255 | install_lib_element(node, &cfg_mgw_endpoint_domain_name_cmd); |
Philipp Maier | 3f2c15f | 2021-07-22 11:53:07 +0200 | [diff] [blame] | 256 | install_lib_element(node, &cfg_mgw_reset_ep_name_cmd); |
| 257 | install_lib_element(node, &cfg_mgw_no_reset_ep_name_cmd); |
Neels Hofmeyr | 87203f2 | 2017-10-31 01:15:45 +0100 | [diff] [blame] | 258 | |
| 259 | /* deprecated 'mgcpgw' commands */ |
Vadim Yanitskiy | 3ba4095 | 2020-10-04 16:42:04 +0700 | [diff] [blame] | 260 | install_lib_element(node, &cfg_mgcpgw_local_ip_cmd); |
| 261 | install_lib_element(node, &cfg_mgcpgw_local_port_cmd); |
| 262 | install_lib_element(node, &cfg_mgcpgw_remote_ip_cmd); |
| 263 | install_lib_element(node, &cfg_mgcpgw_remote_port_cmd); |
| 264 | install_lib_element(node, &cfg_mgcpgw_endpoint_range_cmd); |
| 265 | install_lib_element(node, &cfg_mgcpgw_rtp_bts_base_port_cmd); |
Stefan Sperling | 2924825 | 2018-02-22 18:09:28 +0100 | [diff] [blame] | 266 | |
| 267 | osmo_fsm_vty_add_cmds(); |
Neels Hofmeyr | e9920f2 | 2017-07-10 15:07:22 +0200 | [diff] [blame] | 268 | } |