2017-09-04 13:13:25 +00:00
|
|
|
#ifndef _GB_PROXY_H
|
|
|
|
#define _GB_PROXY_H
|
|
|
|
|
|
|
|
|
|
|
|
#include <osmocom/core/msgb.h>
|
2018-02-20 23:39:36 +00:00
|
|
|
#include <osmocom/gsm/gsm23003.h>
|
2017-09-04 13:13:25 +00:00
|
|
|
|
|
|
|
#include <osmocom/gprs/gprs_ns.h>
|
|
|
|
#include <osmocom/vty/command.h>
|
|
|
|
|
|
|
|
#include <sys/types.h>
|
|
|
|
#include <regex.h>
|
|
|
|
|
|
|
|
#define GBPROXY_INIT_VU_GEN_TX 256
|
|
|
|
|
|
|
|
struct rate_ctr_group;
|
|
|
|
struct gprs_gb_parse_context;
|
|
|
|
struct tlv_parsed;
|
|
|
|
|
|
|
|
enum gbproxy_global_ctr {
|
|
|
|
GBPROX_GLOB_CTR_INV_BVCI,
|
|
|
|
GBPROX_GLOB_CTR_INV_LAI,
|
|
|
|
GBPROX_GLOB_CTR_INV_RAI,
|
|
|
|
GBPROX_GLOB_CTR_INV_NSEI,
|
|
|
|
GBPROX_GLOB_CTR_PROTO_ERR_BSS,
|
|
|
|
GBPROX_GLOB_CTR_PROTO_ERR_SGSN,
|
|
|
|
GBPROX_GLOB_CTR_NOT_SUPPORTED_BSS,
|
|
|
|
GBPROX_GLOB_CTR_NOT_SUPPORTED_SGSN,
|
|
|
|
GBPROX_GLOB_CTR_RESTART_RESET_SGSN,
|
|
|
|
GBPROX_GLOB_CTR_TX_ERR_SGSN,
|
|
|
|
GBPROX_GLOB_CTR_OTHER_ERR,
|
|
|
|
GBPROX_GLOB_CTR_PATCH_PEER_ERR,
|
|
|
|
};
|
|
|
|
|
|
|
|
enum gbproxy_peer_ctr {
|
|
|
|
GBPROX_PEER_CTR_BLOCKED,
|
|
|
|
GBPROX_PEER_CTR_UNBLOCKED,
|
|
|
|
GBPROX_PEER_CTR_DROPPED,
|
|
|
|
GBPROX_PEER_CTR_INV_NSEI,
|
|
|
|
GBPROX_PEER_CTR_TX_ERR,
|
|
|
|
GBPROX_PEER_CTR_RAID_PATCHED_BSS,
|
|
|
|
GBPROX_PEER_CTR_RAID_PATCHED_SGSN,
|
|
|
|
GBPROX_PEER_CTR_APN_PATCHED,
|
|
|
|
GBPROX_PEER_CTR_TLLI_PATCHED_BSS,
|
|
|
|
GBPROX_PEER_CTR_TLLI_PATCHED_SGSN,
|
|
|
|
GBPROX_PEER_CTR_PTMSI_PATCHED_BSS,
|
|
|
|
GBPROX_PEER_CTR_PTMSI_PATCHED_SGSN,
|
|
|
|
GBPROX_PEER_CTR_PATCH_CRYPT_ERR,
|
|
|
|
GBPROX_PEER_CTR_PATCH_ERR,
|
|
|
|
GBPROX_PEER_CTR_ATTACH_REQS,
|
|
|
|
GBPROX_PEER_CTR_ATTACH_REJS,
|
|
|
|
GBPROX_PEER_CTR_ATTACH_ACKS,
|
|
|
|
GBPROX_PEER_CTR_ATTACH_COMPLS,
|
|
|
|
GBPROX_PEER_CTR_RA_UPD_REQS,
|
|
|
|
GBPROX_PEER_CTR_RA_UPD_REJS,
|
|
|
|
GBPROX_PEER_CTR_RA_UPD_ACKS,
|
|
|
|
GBPROX_PEER_CTR_RA_UPD_COMPLS,
|
|
|
|
GBPROX_PEER_CTR_GMM_STATUS_BSS,
|
|
|
|
GBPROX_PEER_CTR_GMM_STATUS_SGSN,
|
|
|
|
GBPROX_PEER_CTR_DETACH_REQS,
|
|
|
|
GBPROX_PEER_CTR_DETACH_ACKS,
|
|
|
|
GBPROX_PEER_CTR_PDP_ACT_REQS,
|
|
|
|
GBPROX_PEER_CTR_PDP_ACT_REJS,
|
|
|
|
GBPROX_PEER_CTR_PDP_ACT_ACKS,
|
|
|
|
GBPROX_PEER_CTR_PDP_DEACT_REQS,
|
|
|
|
GBPROX_PEER_CTR_PDP_DEACT_ACKS,
|
|
|
|
GBPROX_PEER_CTR_TLLI_UNKNOWN,
|
|
|
|
GBPROX_PEER_CTR_TLLI_CACHE_SIZE,
|
|
|
|
GBPROX_PEER_CTR_LAST,
|
|
|
|
};
|
|
|
|
|
|
|
|
enum gbproxy_keep_mode {
|
2019-03-22 07:26:45 +00:00
|
|
|
GBPROX_KEEP_NEVER, /* don't ever keep TLLI/IMSI state of de-registered subscribers */
|
|
|
|
GBPROX_KEEP_REATTACH, /* keep if re-attach has been requested by SGSN */
|
|
|
|
GBPROX_KEEP_IDENTIFIED, /* keep if we had resolved an IMSI */
|
|
|
|
GBPROX_KEEP_ALWAYS, /* always keep */
|
2017-09-04 13:13:25 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
enum gbproxy_match_id {
|
2019-03-22 07:26:45 +00:00
|
|
|
GBPROX_MATCH_PATCHING, /* match rule on whether or not we should patch */
|
|
|
|
GBPROX_MATCH_ROUTING, /* match rule on whether or not we should route (2-SGSN) */
|
2017-09-04 13:13:25 +00:00
|
|
|
GBPROX_MATCH_LAST
|
|
|
|
};
|
|
|
|
|
|
|
|
struct gbproxy_match {
|
2019-03-22 07:26:45 +00:00
|
|
|
int enable; /* is this match enabled? */
|
|
|
|
char *re_str; /* regular expression (for IMSI) in string format */
|
|
|
|
regex_t re_comp; /* compiled regular expression (for IMSI) */
|
2017-09-04 13:13:25 +00:00
|
|
|
};
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* global gb-proxy configuration */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gbproxy_config {
|
|
|
|
/* parsed from config file */
|
|
|
|
uint16_t nsip_sgsn_nsei;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* NS instance of libosmogb */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gprs_ns_inst *nsi;
|
|
|
|
|
|
|
|
/* Linked list of all Gb peers (except SGSN) */
|
|
|
|
struct llist_head bts_peers;
|
|
|
|
|
|
|
|
/* Counter */
|
|
|
|
struct rate_ctr_group *ctrg;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* MCC/MNC to be patched into RA-ID on the way from BSS to SGSN? */
|
2018-02-20 23:39:36 +00:00
|
|
|
struct osmo_plmn_id core_plmn;
|
2019-03-22 07:26:45 +00:00
|
|
|
|
|
|
|
/* APN to be patched into PDP CTX ACT REQ on the way from BSS to SGSN */
|
2017-09-04 13:13:25 +00:00
|
|
|
uint8_t* core_apn;
|
|
|
|
size_t core_apn_size;
|
2019-03-22 07:26:45 +00:00
|
|
|
|
2018-08-17 11:13:27 +00:00
|
|
|
/* Frequency (sec) at which timer to clean stale links is fired (0 disabled) */
|
|
|
|
unsigned int clean_stale_timer_freq;
|
2018-08-16 10:11:46 +00:00
|
|
|
/* If !0, Max age to consider a struct gbproxy_link_info as stale */
|
2017-09-04 13:13:25 +00:00
|
|
|
int tlli_max_age;
|
2018-08-16 10:11:46 +00:00
|
|
|
/* If !0, Max len of gbproxy_peer->list (list of struct gbproxy_link_info) */
|
2017-09-04 13:13:25 +00:00
|
|
|
int tlli_max_len;
|
2018-08-16 10:11:46 +00:00
|
|
|
/* If !0, Max len of gbproxy_link_info->stored_msgs (list of msgb) */
|
|
|
|
uint32_t stored_msgs_max_len;
|
2017-09-04 13:13:25 +00:00
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* Should the P-TMSI be patched on the fly (required for 2-SGSN config) */
|
2017-09-04 13:13:25 +00:00
|
|
|
int patch_ptmsi;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* Should the IMSI be acquired by the proxy (required for 2-SGSN config) */
|
2017-09-04 13:13:25 +00:00
|
|
|
int acquire_imsi;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* Should we route subscribers to two different SGSNs? */
|
2017-09-04 13:13:25 +00:00
|
|
|
int route_to_sgsn2;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* NSEI of the second SGSN */
|
2017-09-04 13:13:25 +00:00
|
|
|
uint16_t nsip_sgsn2_nsei;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* should we keep a cache of per-subscriber state even after de-registration? */
|
2017-09-04 13:13:25 +00:00
|
|
|
enum gbproxy_keep_mode keep_link_infos;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* IMSI checking/matching for 2-SGSN routing and patching */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gbproxy_match matches[GBPROX_MATCH_LAST];
|
|
|
|
};
|
|
|
|
|
|
|
|
struct gbproxy_patch_state {
|
2018-02-20 23:39:36 +00:00
|
|
|
struct osmo_plmn_id local_plmn;
|
2017-09-04 13:13:25 +00:00
|
|
|
|
|
|
|
/* List of TLLIs for which patching is enabled */
|
|
|
|
struct llist_head logical_links;
|
|
|
|
int logical_link_count;
|
|
|
|
};
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* one peer at NS level that we interact with (BSS/PCU) */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gbproxy_peer {
|
2019-03-22 07:26:45 +00:00
|
|
|
/* linked to gbproxy_config.bts_peers */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct llist_head list;
|
|
|
|
|
|
|
|
/* point back to the config */
|
|
|
|
struct gbproxy_config *cfg;
|
|
|
|
|
|
|
|
/* NSEI of the peer entity */
|
|
|
|
uint16_t nsei;
|
|
|
|
|
|
|
|
/* BVCI used for Point-to-Point to this peer */
|
|
|
|
uint16_t bvci;
|
|
|
|
int blocked;
|
|
|
|
|
|
|
|
/* Routeing Area that this peer is part of (raw 04.08 encoding) */
|
|
|
|
uint8_t ra[6];
|
|
|
|
|
|
|
|
/* Counter */
|
|
|
|
struct rate_ctr_group *ctrg;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* State related to on-the-fly patching of certain messages */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gbproxy_patch_state patch_state;
|
2018-08-17 11:13:27 +00:00
|
|
|
|
|
|
|
/* Fired periodically to clean up stale links from list */
|
|
|
|
struct osmo_timer_list clean_stale_timer;
|
2017-09-04 13:13:25 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
struct gbproxy_tlli_state {
|
2019-03-22 07:26:45 +00:00
|
|
|
/* currently active TLLI */
|
2017-09-04 13:13:25 +00:00
|
|
|
uint32_t current;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* newly-assigned TLLI (e.g. during P-TMSI allocation procedure) */
|
2017-09-04 13:13:25 +00:00
|
|
|
uint32_t assigned;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* has the BSS side validated (confirmed) the new TLLI? */
|
2017-09-04 13:13:25 +00:00
|
|
|
int bss_validated;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* has the SGSN side validated (confirmed) the new TLLI? */
|
2017-09-04 13:13:25 +00:00
|
|
|
int net_validated;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* NOTE: once both are validated, we set current = assigned and assigned = 0 */
|
2017-09-04 13:13:25 +00:00
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* The P-TMSI for this subscriber */
|
2017-09-04 13:13:25 +00:00
|
|
|
uint32_t ptmsi;
|
|
|
|
};
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* One TLLI (= UE, = Subscriber) served via this proxy */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gbproxy_link_info {
|
2019-03-22 07:26:45 +00:00
|
|
|
/* link to gbproxy_peer.patch_state.logical_links */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct llist_head list;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* TLLI on the BSS/PCU side */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gbproxy_tlli_state tlli;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* TLLI on the SGSN side (can be different in case of P-TMSI patching) */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct gbproxy_tlli_state sgsn_tlli;
|
2019-03-22 07:26:45 +00:00
|
|
|
/* NSEI of the SGSN serving this link */
|
2017-09-04 13:13:25 +00:00
|
|
|
uint32_t sgsn_nsei;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* timestamp when we last had any contact with this UE */
|
2017-09-04 13:13:25 +00:00
|
|
|
time_t timestamp;
|
2019-03-22 07:26:45 +00:00
|
|
|
|
|
|
|
/* IMSI of the subscriber (if/once known) */
|
2017-09-04 13:13:25 +00:00
|
|
|
uint8_t *imsi;
|
|
|
|
size_t imsi_len;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* is the IMSI acquisition still pending? */
|
2017-09-04 13:13:25 +00:00
|
|
|
int imsi_acq_pending;
|
2019-03-22 07:26:45 +00:00
|
|
|
|
|
|
|
/* queue of stored UL messages (until IMSI acquisition completes and we can
|
|
|
|
* determine which of the SGSNs we should route this to */
|
2017-09-04 13:13:25 +00:00
|
|
|
struct llist_head stored_msgs;
|
2018-08-16 10:11:46 +00:00
|
|
|
uint32_t stored_msgs_len;
|
2019-03-22 07:26:45 +00:00
|
|
|
|
|
|
|
/* generated N(U) we use (required due to IMSI acquisition */
|
2017-09-04 13:13:25 +00:00
|
|
|
unsigned vu_gen_tx_bss;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* is this subscriber deregistered (TLLI invalidated)? */
|
2017-09-04 13:13:25 +00:00
|
|
|
int is_deregistered;
|
|
|
|
|
2019-03-22 07:26:45 +00:00
|
|
|
/* does this link match either the (2-SGSN) routing or the patching rule? */
|
2017-09-04 13:13:25 +00:00
|
|
|
int is_matching[GBPROX_MATCH_LAST];
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
/* gb_proxy_vty .c */
|
|
|
|
|
|
|
|
int gbproxy_vty_init(void);
|
|
|
|
int gbproxy_parse_config(const char *config_file, struct gbproxy_config *cfg);
|
|
|
|
|
gb_proxy: Add ctrl interface and nsvc-state, gbproxy-state commands
This patch adds a control interface to osmo-gbproxy as well as the first
two commands to query the state of each NSVC and gbproxy peer.
The "nsvc-state" command replies with
nsei, nsvci, local state, role, remote state of all NSVCs.
The "gbproxy-state" command replies with
nsei, bvci, mcc, mnc, lac, rac, and state of each peer.
Entries are separated by a newline '\n' character. If there are no
entries an empty list is returned. This behaviour is similar to that of
the subscriber-list-active-v1 command in osmo-sgsn.
$ ./osmo_ctrl.py -d 127.0.0.1 -p 4263 -g nsvc-state
Got message: b'GET_REPLY 23 nsvc-state 101,101,DEAD,BLOCKED,SGSN,DEAD,UNBLOCKED\n'
$ ./osmo_ctrl.py -d 127.0.0.1 -p 4263 -g gbproxy-state
Got message: b'GET_REPLY 4871085901306801158 gbproxy-state '
Change-Id: I82c74fd0bfcb9ba4ec3619d9fdaa0cae201b3177
Ticket: OS#3281, SYS#4235
Sponsored-by: On-Waves ehf
2018-06-01 05:21:20 +00:00
|
|
|
/* gb_proxy_ctrl.c */
|
|
|
|
int gb_ctrl_cmds_install(void);
|
|
|
|
|
2017-09-04 13:13:25 +00:00
|
|
|
|
|
|
|
/* gb_proxy.c */
|
|
|
|
int gbproxy_init_config(struct gbproxy_config *cfg);
|
|
|
|
|
|
|
|
/* Main input function for Gb proxy */
|
|
|
|
int gbprox_rcvmsg(struct gbproxy_config *cfg, struct msgb *msg, uint16_t nsei, uint16_t ns_bvci, uint16_t nsvci);
|
|
|
|
|
|
|
|
int gbprox_signal(unsigned int subsys, unsigned int signal,
|
|
|
|
void *handler_data, void *signal_data);
|
|
|
|
|
|
|
|
/* Reset all persistent NS-VC's */
|
|
|
|
int gbprox_reset_persistent_nsvcs(struct gprs_ns_inst *nsi);
|
|
|
|
|
|
|
|
void gbprox_reset(struct gbproxy_config *cfg);
|
|
|
|
|
|
|
|
/* TLLI info handling */
|
|
|
|
void gbproxy_delete_link_infos(struct gbproxy_peer *peer);
|
|
|
|
struct gbproxy_link_info *gbproxy_update_link_state_ul(
|
|
|
|
struct gbproxy_peer *peer, time_t now,
|
|
|
|
struct gprs_gb_parse_context *parse_ctx);
|
|
|
|
struct gbproxy_link_info *gbproxy_update_link_state_dl(
|
|
|
|
struct gbproxy_peer *peer, time_t now,
|
|
|
|
struct gprs_gb_parse_context *parse_ctx);
|
|
|
|
int gbproxy_update_link_state_after(
|
|
|
|
struct gbproxy_peer *peer, struct gbproxy_link_info *link_info,
|
|
|
|
time_t now, struct gprs_gb_parse_context *parse_ctx);
|
|
|
|
int gbproxy_remove_stale_link_infos(struct gbproxy_peer *peer, time_t now);
|
|
|
|
void gbproxy_delete_link_info(struct gbproxy_peer *peer,
|
|
|
|
struct gbproxy_link_info *link_info);
|
|
|
|
void gbproxy_link_info_discard_messages(struct gbproxy_link_info *link_info);
|
|
|
|
|
|
|
|
void gbproxy_attach_link_info(struct gbproxy_peer *peer, time_t now,
|
|
|
|
struct gbproxy_link_info *link_info);
|
|
|
|
void gbproxy_update_link_info(struct gbproxy_link_info *link_info,
|
|
|
|
const uint8_t *imsi, size_t imsi_len);
|
|
|
|
void gbproxy_detach_link_info(struct gbproxy_peer *peer,
|
|
|
|
struct gbproxy_link_info *link_info);
|
|
|
|
struct gbproxy_link_info *gbproxy_link_info_alloc( struct gbproxy_peer *peer);
|
|
|
|
|
|
|
|
struct gbproxy_link_info *gbproxy_link_info_by_tlli(
|
|
|
|
struct gbproxy_peer *peer, uint32_t tlli);
|
|
|
|
struct gbproxy_link_info *gbproxy_link_info_by_imsi(
|
|
|
|
struct gbproxy_peer *peer, const uint8_t *imsi, size_t imsi_len);
|
|
|
|
struct gbproxy_link_info *gbproxy_link_info_by_any_sgsn_tlli(
|
|
|
|
struct gbproxy_peer *peer, uint32_t tlli);
|
|
|
|
struct gbproxy_link_info *gbproxy_link_info_by_sgsn_tlli(
|
|
|
|
struct gbproxy_peer *peer,
|
|
|
|
uint32_t tlli, uint32_t sgsn_nsei);
|
|
|
|
struct gbproxy_link_info *gbproxy_link_info_by_ptmsi(
|
|
|
|
struct gbproxy_peer *peer,
|
|
|
|
uint32_t ptmsi);
|
|
|
|
|
|
|
|
int gbproxy_imsi_matches(
|
|
|
|
struct gbproxy_config *cfg,
|
|
|
|
enum gbproxy_match_id match_id,
|
|
|
|
struct gbproxy_link_info *link_info);
|
|
|
|
uint32_t gbproxy_map_tlli(
|
|
|
|
uint32_t other_tlli, struct gbproxy_link_info *link_info, int to_bss);
|
|
|
|
|
|
|
|
/* needed by gb_proxy_tlli.h */
|
|
|
|
uint32_t gbproxy_make_bss_ptmsi(struct gbproxy_peer *peer, uint32_t sgsn_ptmsi);
|
|
|
|
uint32_t gbproxy_make_sgsn_tlli(
|
|
|
|
struct gbproxy_peer *peer, struct gbproxy_link_info *link_info,
|
|
|
|
uint32_t bss_tlli);
|
|
|
|
void gbproxy_reset_link(struct gbproxy_link_info *link_info);
|
|
|
|
int gbproxy_check_imsi(
|
|
|
|
struct gbproxy_match *match, const uint8_t *imsi, size_t imsi_len);
|
|
|
|
|
|
|
|
/* Message patching */
|
|
|
|
void gbproxy_patch_bssgp(
|
|
|
|
struct msgb *msg, uint8_t *bssgp, size_t bssgp_len,
|
|
|
|
struct gbproxy_peer *peer, struct gbproxy_link_info *link_info,
|
|
|
|
int *len_change, struct gprs_gb_parse_context *parse_ctx);
|
|
|
|
|
|
|
|
int gbproxy_patch_llc(
|
|
|
|
struct msgb *msg, uint8_t *llc, size_t llc_len,
|
|
|
|
struct gbproxy_peer *peer, struct gbproxy_link_info *link_info,
|
|
|
|
int *len_change, struct gprs_gb_parse_context *parse_ctx);
|
|
|
|
|
|
|
|
int gbproxy_set_patch_filter(
|
|
|
|
struct gbproxy_match *match, const char *filter, const char **err_msg);
|
|
|
|
void gbproxy_clear_patch_filter(struct gbproxy_match *match);
|
|
|
|
|
|
|
|
/* Peer handling */
|
|
|
|
struct gbproxy_peer *gbproxy_peer_by_bvci(
|
|
|
|
struct gbproxy_config *cfg, uint16_t bvci);
|
|
|
|
struct gbproxy_peer *gbproxy_peer_by_nsei(
|
|
|
|
struct gbproxy_config *cfg, uint16_t nsei);
|
|
|
|
struct gbproxy_peer *gbproxy_peer_by_rai(
|
|
|
|
struct gbproxy_config *cfg, const uint8_t *ra);
|
|
|
|
struct gbproxy_peer *gbproxy_peer_by_lai(
|
|
|
|
struct gbproxy_config *cfg, const uint8_t *la);
|
|
|
|
struct gbproxy_peer *gbproxy_peer_by_lac(
|
|
|
|
struct gbproxy_config *cfg, const uint8_t *la);
|
|
|
|
struct gbproxy_peer *gbproxy_peer_by_bssgp_tlv(
|
|
|
|
struct gbproxy_config *cfg, struct tlv_parsed *tp);
|
|
|
|
struct gbproxy_peer *gbproxy_peer_alloc(struct gbproxy_config *cfg, uint16_t bvci);
|
|
|
|
void gbproxy_peer_free(struct gbproxy_peer *peer);
|
|
|
|
int gbproxy_cleanup_peers(struct gbproxy_config *cfg, uint16_t nsei, uint16_t bvci);
|
|
|
|
|
|
|
|
#endif
|