Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 1 | /* OpenBSC NAT interface to quagga VTY */ |
| 2 | /* (C) 2010 by Holger Hans Peter Freyther |
| 3 | * (C) 2010 by On-Waves |
| 4 | * All Rights Reserved |
| 5 | * |
| 6 | * This program is free software; you can redistribute it and/or modify |
| 7 | * it under the terms of the GNU General Public License as published by |
| 8 | * the Free Software Foundation; either version 2 of the License, or |
| 9 | * (at your option) any later version. |
| 10 | * |
| 11 | * This program is distributed in the hope that it will be useful, |
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 | * GNU General Public License for more details. |
| 15 | * |
| 16 | * You should have received a copy of the GNU General Public License along |
| 17 | * with this program; if not, write to the Free Software Foundation, Inc., |
| 18 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
| 19 | * |
| 20 | */ |
| 21 | |
| 22 | #include <vty/command.h> |
| 23 | #include <vty/buffer.h> |
| 24 | #include <vty/vty.h> |
| 25 | |
| 26 | #include <openbsc/bsc_nat.h> |
| 27 | #include <openbsc/gsm_04_08.h> |
Holger Hans Peter Freyther | 3660e4d | 2010-06-15 18:50:26 +0800 | [diff] [blame] | 28 | #include <openbsc/mgcp.h> |
Holger Hans Peter Freyther | b372fad | 2010-04-06 12:01:15 +0200 | [diff] [blame] | 29 | #include <openbsc/vty.h> |
Holger Hans Peter Freyther | 3b96089 | 2010-06-15 19:06:18 +0800 | [diff] [blame] | 30 | |
| 31 | #include <osmocore/talloc.h> |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 32 | |
| 33 | #include <sccp/sccp.h> |
| 34 | |
| 35 | #include <stdlib.h> |
| 36 | |
| 37 | static struct bsc_nat *_nat; |
| 38 | |
| 39 | static struct cmd_node nat_node = { |
| 40 | NAT_NODE, |
| 41 | "%s(nat)#", |
| 42 | 1, |
| 43 | }; |
| 44 | |
| 45 | static struct cmd_node bsc_node = { |
| 46 | BSC_NODE, |
| 47 | "%s(bsc)#", |
| 48 | 1, |
| 49 | }; |
| 50 | |
| 51 | static int config_write_nat(struct vty *vty) |
| 52 | { |
| 53 | vty_out(vty, "nat%s", VTY_NEWLINE); |
Holger Hans Peter Freyther | 4b6da56 | 2010-04-13 09:24:37 +0200 | [diff] [blame] | 54 | if (_nat->imsi_allow) |
| 55 | vty_out(vty, " imsi allow %s%s", _nat->imsi_allow, VTY_NEWLINE); |
| 56 | if (_nat->imsi_deny) |
| 57 | vty_out(vty, " insi deny %s%s", _nat->imsi_deny, VTY_NEWLINE); |
Holger Hans Peter Freyther | 9226d70 | 2010-06-15 18:51:04 +0800 | [diff] [blame] | 58 | vty_out(vty, " msc ip %s%s", _nat->msc_ip, VTY_NEWLINE); |
Holger Hans Peter Freyther | bace202 | 2010-04-17 07:48:45 +0200 | [diff] [blame] | 59 | vty_out(vty, " msc port %d%s", _nat->msc_port, VTY_NEWLINE); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 60 | return CMD_SUCCESS; |
| 61 | } |
| 62 | |
| 63 | static void config_write_bsc_single(struct vty *vty, struct bsc_config *bsc) |
| 64 | { |
| 65 | vty_out(vty, " bsc %u%s", bsc->nr, VTY_NEWLINE); |
| 66 | vty_out(vty, " token %s%s", bsc->token, VTY_NEWLINE); |
Holger Hans Peter Freyther | 085ea30 | 2010-04-16 16:52:20 +0200 | [diff] [blame] | 67 | vty_out(vty, " location_area_code %u%s", bsc->lac, VTY_NEWLINE); |
Holger Hans Peter Freyther | 4b6da56 | 2010-04-13 09:24:37 +0200 | [diff] [blame] | 68 | if (bsc->imsi_allow) |
| 69 | vty_out(vty, " imsi allow %s%s", bsc->imsi_allow, VTY_NEWLINE); |
| 70 | if (bsc->imsi_deny) |
| 71 | vty_out(vty, " imsi deny %s%s", bsc->imsi_deny, VTY_NEWLINE); |
Holger Hans Peter Freyther | 7acf462 | 2010-04-21 19:05:14 +0800 | [diff] [blame] | 72 | vty_out(vty, " paging forbidden %d%s", bsc->forbid_paging, VTY_NEWLINE); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 73 | } |
| 74 | |
| 75 | static int config_write_bsc(struct vty *vty) |
| 76 | { |
| 77 | struct bsc_config *bsc; |
| 78 | |
| 79 | llist_for_each_entry(bsc, &_nat->bsc_configs, entry) |
| 80 | config_write_bsc_single(vty, bsc); |
| 81 | return CMD_SUCCESS; |
| 82 | } |
| 83 | |
| 84 | |
Holger Hans Peter Freyther | 17f8c95 | 2010-04-19 16:06:43 +0800 | [diff] [blame] | 85 | DEFUN(show_sccp, show_sccp_cmd, "show sccp connections", |
| 86 | SHOW_STR "Display information about current SCCP connections") |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 87 | { |
| 88 | struct sccp_connections *con; |
| 89 | llist_for_each_entry(con, &_nat->sccp_connections, list_entry) { |
Holger Hans Peter Freyther | bfcf519 | 2010-04-06 15:11:34 +0200 | [diff] [blame] | 90 | vty_out(vty, "SCCP for BSC: Nr: %d lac: %d BSC ref: 0x%x Local ref: 0x%x MSC/BSC mux: 0x%x/0x%x%s", |
| 91 | con->bsc->cfg ? con->bsc->cfg->nr : -1, |
| 92 | con->bsc->cfg ? con->bsc->cfg->lac : -1, |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 93 | sccp_src_ref_to_int(&con->real_ref), |
Holger Hans Peter Freyther | 32aba23 | 2010-04-05 10:10:33 +0200 | [diff] [blame] | 94 | sccp_src_ref_to_int(&con->patched_ref), |
| 95 | con->msc_timeslot, con->bsc_timeslot, |
| 96 | VTY_NEWLINE); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 97 | } |
| 98 | |
| 99 | return CMD_SUCCESS; |
| 100 | } |
| 101 | |
Holger Hans Peter Freyther | 17f8c95 | 2010-04-19 16:06:43 +0800 | [diff] [blame] | 102 | DEFUN(show_bsc, show_bsc_cmd, "show bsc connections", |
| 103 | SHOW_STR "Display information about current BSCs") |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 104 | { |
| 105 | struct bsc_connection *con; |
Holger Hans Peter Freyther | 9e53e97 | 2010-04-08 10:35:20 +0200 | [diff] [blame] | 106 | struct sockaddr_in sock; |
| 107 | socklen_t len = sizeof(sock); |
| 108 | |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 109 | llist_for_each_entry(con, &_nat->bsc_connections, list_entry) { |
Holger Hans Peter Freyther | 9e53e97 | 2010-04-08 10:35:20 +0200 | [diff] [blame] | 110 | getpeername(con->write_queue.bfd.fd, (struct sockaddr *) &sock, &len); |
| 111 | vty_out(vty, "BSC lac: %d, %d auth: %d fd: %d peername: %s%s", |
Holger Hans Peter Freyther | bfcf519 | 2010-04-06 15:11:34 +0200 | [diff] [blame] | 112 | con->cfg ? con->cfg->nr : -1, |
| 113 | con->cfg ? con->cfg->lac : -1, |
Holger Hans Peter Freyther | 9e53e97 | 2010-04-08 10:35:20 +0200 | [diff] [blame] | 114 | con->authenticated, con->write_queue.bfd.fd, |
| 115 | inet_ntoa(sock.sin_addr), VTY_NEWLINE); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 116 | } |
| 117 | |
| 118 | return CMD_SUCCESS; |
| 119 | } |
| 120 | |
Holger Hans Peter Freyther | 73e5b78 | 2010-04-12 07:29:22 +0200 | [diff] [blame] | 121 | DEFUN(show_bsc_cfg, show_bsc_cfg_cmd, "bsc config show", |
Holger Freyther | f514812 | 2010-04-17 23:10:34 +0800 | [diff] [blame] | 122 | "Display information about known BSC configs") |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 123 | { |
| 124 | struct bsc_config *conf; |
| 125 | llist_for_each_entry(conf, &_nat->bsc_configs, entry) { |
| 126 | vty_out(vty, "BSC token: '%s' lac: %u nr: %u%s", |
| 127 | conf->token, conf->lac, conf->nr, VTY_NEWLINE); |
Holger Hans Peter Freyther | 4b6da56 | 2010-04-13 09:24:37 +0200 | [diff] [blame] | 128 | vty_out(vty, " imsi_allow: '%s' imsi_deny: '%s'%s", |
| 129 | conf->imsi_allow ? conf->imsi_allow: "any", |
| 130 | conf->imsi_deny ? conf->imsi_deny : "none", |
| 131 | VTY_NEWLINE); |
Holger Hans Peter Freyther | 7acf462 | 2010-04-21 19:05:14 +0800 | [diff] [blame] | 132 | vty_out(vty, " paging forbidden: %d%s", |
| 133 | conf->forbid_paging, VTY_NEWLINE); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 134 | } |
| 135 | |
| 136 | return CMD_SUCCESS; |
| 137 | } |
| 138 | |
Holger Hans Peter Freyther | 02e1c7d | 2010-04-12 12:33:27 +0200 | [diff] [blame] | 139 | DEFUN(show_stats, |
| 140 | show_stats_cmd, |
| 141 | "show statistics", |
| 142 | SHOW_STR "Display network statistics\n") |
| 143 | { |
| 144 | struct bsc_config *conf; |
| 145 | |
| 146 | vty_out(vty, "NAT statistics%s", VTY_NEWLINE); |
| 147 | vty_out(vty, " SCCP Connections %lu total, %lu calls%s", |
| 148 | counter_get(_nat->stats.sccp.conn), |
| 149 | counter_get(_nat->stats.sccp.calls), VTY_NEWLINE); |
| 150 | vty_out(vty, " MSC Connections %lu%s", |
| 151 | counter_get(_nat->stats.msc.reconn), VTY_NEWLINE); |
| 152 | vty_out(vty, " BSC Connections %lu total, %lu auth failed.%s", |
| 153 | counter_get(_nat->stats.bsc.reconn), |
| 154 | counter_get(_nat->stats.bsc.auth_fail), VTY_NEWLINE); |
| 155 | |
| 156 | llist_for_each_entry(conf, &_nat->bsc_configs, entry) { |
| 157 | vty_out(vty, " BSC lac: %d nr: %d%s", |
| 158 | conf->lac, conf->nr, VTY_NEWLINE); |
| 159 | vty_out(vty, " SCCP Connnections %lu total, %lu calls%s", |
| 160 | counter_get(conf->stats.sccp.conn), |
| 161 | counter_get(conf->stats.sccp.calls), VTY_NEWLINE); |
| 162 | vty_out(vty, " BSC Connections %lu total%s", |
| 163 | counter_get(conf->stats.net.reconn), VTY_NEWLINE); |
| 164 | } |
| 165 | |
| 166 | return CMD_SUCCESS; |
| 167 | } |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 168 | |
| 169 | DEFUN(cfg_nat, cfg_nat_cmd, "nat", "Configute the NAT") |
| 170 | { |
| 171 | vty->index = _nat; |
| 172 | vty->node = NAT_NODE; |
| 173 | |
| 174 | return CMD_SUCCESS; |
| 175 | } |
| 176 | |
Holger Hans Peter Freyther | 4b6da56 | 2010-04-13 09:24:37 +0200 | [diff] [blame] | 177 | static void parse_reg(void *ctx, regex_t *reg, char **imsi, int argc, const char **argv) |
| 178 | { |
| 179 | if (*imsi) { |
| 180 | talloc_free(*imsi); |
| 181 | *imsi = NULL; |
| 182 | } |
| 183 | regfree(reg); |
| 184 | |
| 185 | if (argc > 0) { |
| 186 | *imsi = talloc_strdup(ctx, argv[0]); |
| 187 | regcomp(reg, argv[0], 0); |
| 188 | } |
| 189 | } |
| 190 | |
| 191 | DEFUN(cfg_nat_imsi_allow, |
| 192 | cfg_nat_imsi_allow_cmd, |
| 193 | "imsi allow [REGEXP]", |
| 194 | "Allow matching IMSIs to talk to the MSC. " |
| 195 | "The defualt is to allow everyone.") |
| 196 | { |
| 197 | parse_reg(_nat, &_nat->imsi_allow_re, &_nat->imsi_allow, argc, argv); |
| 198 | return CMD_SUCCESS; |
| 199 | } |
| 200 | |
| 201 | DEFUN(cfg_nat_imsi_deny, |
| 202 | cfg_nat_imsi_deny_cmd, |
| 203 | "imsi deny [REGEXP]", |
| 204 | "Deny matching IMSIs to talk to the MSC. " |
| 205 | "The defualt is to not deny.") |
| 206 | { |
| 207 | parse_reg(_nat, &_nat->imsi_deny_re, &_nat->imsi_deny, argc, argv); |
| 208 | return CMD_SUCCESS; |
| 209 | } |
| 210 | |
Holger Hans Peter Freyther | 9226d70 | 2010-06-15 18:51:04 +0800 | [diff] [blame] | 211 | DEFUN(cfg_nat_msc_ip, |
| 212 | cfg_nat_msc_ip_cmd, |
| 213 | "msc ip IP", |
| 214 | "Set the IP address of the MSC.") |
| 215 | { |
| 216 | bsc_nat_set_msc_ip(_nat, argv[0]); |
| 217 | return CMD_SUCCESS; |
| 218 | } |
| 219 | |
Holger Hans Peter Freyther | bace202 | 2010-04-17 07:48:45 +0200 | [diff] [blame] | 220 | DEFUN(cfg_nat_msc_port, |
| 221 | cfg_nat_msc_port_cmd, |
| 222 | "msc port <1-65500>", |
| 223 | "Set the port of the MSC.") |
| 224 | { |
| 225 | _nat->msc_port = atoi(argv[0]); |
| 226 | return CMD_SUCCESS; |
| 227 | } |
| 228 | |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 229 | /* per BSC configuration */ |
| 230 | DEFUN(cfg_bsc, cfg_bsc_cmd, "bsc BSC_NR", "Select a BSC to configure\n") |
| 231 | { |
| 232 | int bsc_nr = atoi(argv[0]); |
| 233 | struct bsc_config *bsc; |
| 234 | |
| 235 | if (bsc_nr > _nat->num_bsc) { |
| 236 | vty_out(vty, "%% The next unused BSC number is %u%s", |
| 237 | _nat->num_bsc, VTY_NEWLINE); |
| 238 | return CMD_WARNING; |
| 239 | } else if (bsc_nr == _nat->num_bsc) { |
| 240 | /* allocate a new one */ |
| 241 | bsc = bsc_config_alloc(_nat, "unknown", 0); |
| 242 | } else |
| 243 | bsc = bsc_config_num(_nat, bsc_nr); |
| 244 | |
| 245 | if (!bsc) |
| 246 | return CMD_WARNING; |
| 247 | |
| 248 | vty->index = bsc; |
| 249 | vty->node = BSC_NODE; |
| 250 | |
| 251 | return CMD_SUCCESS; |
| 252 | } |
| 253 | |
| 254 | DEFUN(cfg_bsc_token, cfg_bsc_token_cmd, "token TOKEN", "Set the token") |
| 255 | { |
| 256 | struct bsc_config *conf = vty->index; |
| 257 | |
| 258 | if (conf->token) |
| 259 | talloc_free(conf->token); |
| 260 | conf->token = talloc_strdup(conf, argv[0]); |
| 261 | return CMD_SUCCESS; |
| 262 | } |
| 263 | |
| 264 | DEFUN(cfg_bsc_lac, cfg_bsc_lac_cmd, "location_area_code <0-65535>", |
| 265 | "Set the Location Area Code (LAC) of this BSC\n") |
| 266 | { |
Holger Hans Peter Freyther | 435a5c1 | 2010-03-30 06:08:56 +0200 | [diff] [blame] | 267 | struct bsc_config *tmp; |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 268 | struct bsc_config *conf = vty->index; |
| 269 | |
| 270 | int lac = atoi(argv[0]); |
| 271 | |
| 272 | if (lac < 0 || lac > 0xffff) { |
| 273 | vty_out(vty, "%% LAC %d is not in the valid range (0-65535)%s", |
| 274 | lac, VTY_NEWLINE); |
| 275 | return CMD_WARNING; |
| 276 | } |
| 277 | |
| 278 | if (lac == GSM_LAC_RESERVED_DETACHED || lac == GSM_LAC_RESERVED_ALL_BTS) { |
| 279 | vty_out(vty, "%% LAC %d is reserved by GSM 04.08%s", |
| 280 | lac, VTY_NEWLINE); |
| 281 | return CMD_WARNING; |
| 282 | } |
| 283 | |
Holger Hans Peter Freyther | 435a5c1 | 2010-03-30 06:08:56 +0200 | [diff] [blame] | 284 | /* verify that the LACs are unique */ |
| 285 | llist_for_each_entry(tmp, &_nat->bsc_configs, entry) { |
| 286 | if (tmp->lac == lac) { |
| 287 | vty_out(vty, "%% LAC %d is already used.%s", lac, VTY_NEWLINE); |
| 288 | return CMD_ERR_INCOMPLETE; |
| 289 | } |
| 290 | } |
| 291 | |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 292 | conf->lac = lac; |
| 293 | |
| 294 | return CMD_SUCCESS; |
| 295 | } |
| 296 | |
Holger Hans Peter Freyther | 4b6da56 | 2010-04-13 09:24:37 +0200 | [diff] [blame] | 297 | DEFUN(cfg_bsc_imsi_allow, |
| 298 | cfg_bsc_imsi_allow_cmd, |
| 299 | "imsi allow [REGEXP]", |
| 300 | "Allow IMSIs with the following network to talk to the MSC." |
| 301 | "The default is to allow everyone)") |
| 302 | { |
| 303 | struct bsc_config *conf = vty->index; |
| 304 | |
| 305 | parse_reg(conf, &conf->imsi_allow_re, &conf->imsi_allow, argc, argv); |
| 306 | return CMD_SUCCESS; |
| 307 | } |
| 308 | |
| 309 | DEFUN(cfg_bsc_imsi_deny, |
| 310 | cfg_bsc_imsi_deny_cmd, |
| 311 | "imsi deny [REGEXP]", |
| 312 | "Deny IMSIs with the following network to talk to the MSC." |
| 313 | "The default is to not deny anyone.)") |
| 314 | { |
| 315 | struct bsc_config *conf = vty->index; |
| 316 | |
| 317 | parse_reg(conf, &conf->imsi_deny_re, &conf->imsi_deny, argc, argv); |
| 318 | return CMD_SUCCESS; |
| 319 | } |
| 320 | |
Holger Hans Peter Freyther | 7acf462 | 2010-04-21 19:05:14 +0800 | [diff] [blame] | 321 | DEFUN(cfg_bsc_paging, |
| 322 | cfg_bsc_paging_cmd, |
| 323 | "paging forbidden (0|1)", |
| 324 | "Forbid sending PAGING REQUESTS to the BSC.") |
| 325 | { |
| 326 | struct bsc_config *conf = vty->index; |
| 327 | |
Holger Hans Peter Freyther | e6ac5de | 2010-04-21 20:07:07 +0800 | [diff] [blame] | 328 | if (strcmp("1", argv[0]) == 0) |
Holger Hans Peter Freyther | 7acf462 | 2010-04-21 19:05:14 +0800 | [diff] [blame] | 329 | conf->forbid_paging = 1; |
| 330 | else |
| 331 | conf->forbid_paging = 0; |
| 332 | |
| 333 | return CMD_SUCCESS; |
| 334 | } |
| 335 | |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 336 | int bsc_nat_vty_init(struct bsc_nat *nat) |
| 337 | { |
| 338 | _nat = nat; |
| 339 | |
| 340 | cmd_init(1); |
| 341 | vty_init(); |
| 342 | |
| 343 | /* show commands */ |
| 344 | install_element(VIEW_NODE, &show_sccp_cmd); |
| 345 | install_element(VIEW_NODE, &show_bsc_cmd); |
| 346 | install_element(VIEW_NODE, &show_bsc_cfg_cmd); |
Holger Hans Peter Freyther | 02e1c7d | 2010-04-12 12:33:27 +0200 | [diff] [blame] | 347 | install_element(VIEW_NODE, &show_stats_cmd); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 348 | |
Holger Hans Peter Freyther | b372fad | 2010-04-06 12:01:15 +0200 | [diff] [blame] | 349 | openbsc_vty_add_cmds(); |
| 350 | |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 351 | /* nat group */ |
| 352 | install_element(CONFIG_NODE, &cfg_nat_cmd); |
| 353 | install_node(&nat_node, config_write_nat); |
| 354 | install_default(NAT_NODE); |
Holger Hans Peter Freyther | 4b6da56 | 2010-04-13 09:24:37 +0200 | [diff] [blame] | 355 | install_element(NAT_NODE, &cfg_nat_imsi_allow_cmd); |
| 356 | install_element(NAT_NODE, &cfg_nat_imsi_deny_cmd); |
Holger Hans Peter Freyther | 9226d70 | 2010-06-15 18:51:04 +0800 | [diff] [blame] | 357 | install_element(NAT_NODE, &cfg_nat_msc_ip_cmd); |
Holger Hans Peter Freyther | bace202 | 2010-04-17 07:48:45 +0200 | [diff] [blame] | 358 | install_element(NAT_NODE, &cfg_nat_msc_port_cmd); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 359 | |
| 360 | /* BSC subgroups */ |
| 361 | install_element(NAT_NODE, &cfg_bsc_cmd); |
| 362 | install_node(&bsc_node, config_write_bsc); |
| 363 | install_default(BSC_NODE); |
| 364 | install_element(BSC_NODE, &cfg_bsc_token_cmd); |
| 365 | install_element(BSC_NODE, &cfg_bsc_lac_cmd); |
Holger Hans Peter Freyther | 4b6da56 | 2010-04-13 09:24:37 +0200 | [diff] [blame] | 366 | install_element(BSC_NODE, &cfg_bsc_imsi_allow_cmd); |
| 367 | install_element(BSC_NODE, &cfg_bsc_imsi_deny_cmd); |
Holger Hans Peter Freyther | 7acf462 | 2010-04-21 19:05:14 +0800 | [diff] [blame] | 368 | install_element(BSC_NODE, &cfg_bsc_paging_cmd); |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 369 | |
Holger Hans Peter Freyther | 3660e4d | 2010-06-15 18:50:26 +0800 | [diff] [blame] | 370 | mgcp_vty_init(); |
| 371 | |
Holger Hans Peter Freyther | 5e54788 | 2010-06-15 18:46:11 +0800 | [diff] [blame] | 372 | return 0; |
| 373 | } |
| 374 | |
| 375 | |
| 376 | /* called by the telnet interface... we have our own init above */ |
| 377 | void bsc_vty_init() |
| 378 | {} |