127char *
osmo_mnc_name_buf(
char *buf,
size_t buf_len, uint16_t mnc,
bool mnc_3_digits);
128char *
osmo_mnc_name_c(
const void *ctx, uint16_t mnc,
bool mnc_3_digits);
174int osmo_mnc_cmp(uint16_t a_mnc,
bool a_mnc_3_digits, uint16_t b_mnc,
bool b_mnc_3_digits);
char * osmo_sai_name_buf(char *buf, size_t buf_len, const struct osmo_service_area_id *sai)
Return MCC-MNC-LAC-SAC as string, in caller-provided output buffer.
Definition: gsm23003.c:415
char * osmo_cgi_name_c(const void *ctx, const struct osmo_cell_global_id *cgi)
Return MCC-MNC-LAC-CI as string, in a talloc-allocated output buffer.
Definition: gsm23003.c:321
char * osmo_cgi_name_buf(char *buf, size_t buf_len, const struct osmo_cell_global_id *cgi)
Return MCC-MNC-LAC-CI as string, in caller-provided output buffer.
Definition: gsm23003.c:289
const char * osmo_cgi_name2(const struct osmo_cell_global_id *cgi)
Same as osmo_cgi_name(), but uses a different static buffer.
Definition: gsm23003.c:310
int osmo_gen_home_network_domain(char *out, const struct osmo_plmn_id *plmn)
Generate TS 23.003 Section 19.2 Home Network Realm/Domain (text form)
Definition: gsm23003.c:753
const char * osmo_mcc_name(uint16_t mcc)
Return MCC string as standardized 3-digit with leading zeros.
Definition: gsm23003.c:104
const char * osmo_mnc_name(uint16_t mnc, bool mnc_3_digits)
Return MNC string as standardized 2- or 3-digit with leading zeros.
Definition: gsm23003.c:155
char * osmo_mcc_name_buf(char *buf, size_t buf_len, uint16_t mcc)
Return MCC string as standardized 3-digit with leading zeros.
Definition: gsm23003.c:94
const char * osmo_gummei_name(const struct osmo_gummei *gummei)
Return string representation of GUMMEI in static output buffer.
Definition: gsm23003.c:481
int osmo_rai_cmp(const struct osmo_routing_area_id *a, const struct osmo_routing_area_id *b)
Definition: gsm23003.c:651
int osmo_parse_home_network_domain(struct osmo_plmn_id *out, const char *in)
Parse a TS 23.003 Section 19.2 Home Network Realm/Domain (text form) into a osmo_plmn_id.
Definition: gsm23003.c:766
int osmo_cgi_ps_cmp(const struct osmo_cell_global_id_ps *a, const struct osmo_cell_global_id_ps *b)
Definition: gsm23003.c:685
char * osmo_mnc_name_c(const void *ctx, uint16_t mnc, bool mnc_3_digits)
Return MNC string as standardized 2- or 3-digit with leading zeros, into a talloc-allocated buffer.
Definition: gsm23003.c:142
int osmo_gummei_cmp(const struct osmo_gummei *a, const struct osmo_gummei *b)
Definition: gsm23003.c:740
const char * osmo_lai_name(const struct osmo_location_area_id *lai)
Return MCC-MNC-LAC as string, in a static buffer.
Definition: gsm23003.c:227
void osmo_plmn_to_bcd(uint8_t *bcd_dst, const struct osmo_plmn_id *plmn)
Definition: gsm23003.c:513
int osmo_rnc_id_cmp(const struct osmo_rnc_id *a, const struct osmo_rnc_id *b)
Definition: gsm23003.c:702
int osmo_parse_mme_domain(struct osmo_gummei *out, const char *in)
Parse a TS 23.003 Section 19.4.2.4 MME Domain (text form) into a osmo_gummei.
Definition: gsm23003.c:797
const char * osmo_mcc_name_c(const void *ctx, uint16_t mcc)
Return MCC string as standardized 3-digit with leading zeros, into a talloc-allocated buffer.
Definition: gsm23003.c:115
const char * osmo_sai_name(const struct osmo_service_area_id *sai)
Return MCC-MNC-LAC-SAC as string, in a static buffer.
Definition: gsm23003.c:425
int osmo_plmn_cmp(const struct osmo_plmn_id *a, const struct osmo_plmn_id *b)
Definition: gsm23003.c:618
char * osmo_lai_name_c(const void *ctx, const struct osmo_location_area_id *lai)
Return MCC-MNC-LAC as string, in a talloc-allocated output buffer.
Definition: gsm23003.c:238
int osmo_cgi_cmp(const struct osmo_cell_global_id *a, const struct osmo_cell_global_id *b)
Definition: gsm23003.c:668
char * osmo_rai_name2_buf(char *buf, size_t buf_len, const struct osmo_routing_area_id *rai)
Return MCC-MNC-LAC-RAC as string, in caller-provided output buffer.
Definition: gsm23003.c:252
const char * osmo_plmn_name(const struct osmo_plmn_id *plmn)
Return MCC-MNC string as standardized 3-digit-dash-2/3-digit with leading zeros.
Definition: gsm23003.c:179
bool osmo_imsi_str_valid(const char *imsi)
Determine whether the given IMSI is valid according to 3GPP TS 23.003.
Definition: gsm23003.c:56
const char * osmo_rai_name2(const struct osmo_routing_area_id *rai)
Return MCC-MNC-LAC-RAC as string, in a static buffer.
Definition: gsm23003.c:264
const char * osmo_rnc_id_name(const struct osmo_rnc_id *rnc_id)
Return string representation of RNC in static output buffer.
Definition: gsm23003.c:378
char * osmo_plmn_name_buf(char *buf, size_t buf_len, const struct osmo_plmn_id *plmn)
Return MCC-MNC string as standardized 3-digit-dash-2/3-digit with leading zeros.
Definition: gsm23003.c:167
int osmo_mme_id_cmp(const struct osmo_mme_id *a, const struct osmo_mme_id *b)
Definition: gsm23003.c:720
int osmo_mnc_cmp(uint16_t a_mnc, bool a_mnc_3_digits, uint16_t b_mnc, bool b_mnc_3_digits)
Definition: gsm23003.c:602
osmo_cgi_part
Bitmask of items contained in a struct osmo_cell_global_id.
Definition: gsm23003.h:45
@ OSMO_CGI_PART_CI
Definition: gsm23003.h:48
@ OSMO_CGI_PART_RAC
Definition: gsm23003.h:49
@ OSMO_CGI_PART_LAC
Definition: gsm23003.h:47
@ OSMO_CGI_PART_PLMN
Definition: gsm23003.h:46
char * osmo_rai_name2_c(const void *ctx, const struct osmo_routing_area_id *rai)
Return MCC-MNC-LAC-RAC as string, in a talloc-allocated output buffer.
Definition: gsm23003.c:275
int osmo_lai_cmp(const struct osmo_location_area_id *a, const struct osmo_location_area_id *b)
Definition: gsm23003.c:634
const char * osmo_sai_name2(const struct osmo_service_area_id *sai)
Same as osmo_cgi_name(), but uses a different static buffer.
Definition: gsm23003.c:436
const char * osmo_cgi_ps_name(const struct osmo_cell_global_id_ps *cgi_ps)
Return MCC-MNC-LAC-RAC-CI as string, in a static buffer.
Definition: gsm23003.c:343
static int osmo_mcc_from_str(const char *mcc_str, uint16_t *mcc)
Definition: gsm23003.h:169
char * osmo_gummei_name_c(const void *ctx, const struct osmo_gummei *gummei)
Return string representation of GUMMEI in static output buffer.
Definition: gsm23003.c:493
char * osmo_sai_name_c(const void *ctx, const struct osmo_service_area_id *sai)
Return MCC-MNC-LAC-SAC as string, in a talloc-allocated output buffer.
Definition: gsm23003.c:447
char * osmo_cgi_ps_name_buf(char *buf, size_t buf_len, const struct osmo_cell_global_id_ps *cgi_ps)
Return MCC-MNC-LAC-RAC-CI as string, in caller-provided output buffer.
Definition: gsm23003.c:333
char * osmo_gummei_name_buf(char *buf, size_t buf_len, const struct osmo_gummei *gummei)
Return string representation of GUMMEI in caller-provided output buffer.
Definition: gsm23003.c:469
char * osmo_rnc_id_name_buf(char *buf, size_t buf_len, const struct osmo_rnc_id *rnc_id)
Return string representation of RNC in caller-provided output buffer.
Definition: gsm23003.c:366
const char * osmo_cgi_ps_name2(const struct osmo_cell_global_id_ps *cgi_ps)
Same as osmo_cgi_ps_name(), but uses a different static buffer.
Definition: gsm23003.c:354
char * osmo_plmn_name_c(const void *ctx, const struct osmo_plmn_id *plmn)
Return MCC-MNC string as standardized 3-digit-dash-2/3-digit with leading zeros, into a dynamically-a...
Definition: gsm23003.c:202
bool osmo_imei_str_valid(const char *imei, bool with_15th_digit)
Determine whether the given IMEI is valid according to 3GPP TS 23.003, Section 6.2....
Definition: gsm23003.c:80
char * osmo_lai_name_buf(char *buf, size_t buf_len, const struct osmo_location_area_id *lai)
Return MCC-MNC-LAC as string, in caller-provided output buffer.
Definition: gsm23003.c:216
const char * osmo_plmn_name2(const struct osmo_plmn_id *plmn)
Same as osmo_plmn_name(), but returning in a different static buffer.
Definition: gsm23003.c:190
bool osmo_msisdn_str_valid(const char *msisdn)
Determine whether the given MSISDN is valid according to 3GPP TS 23.003.
Definition: gsm23003.c:66
osmo_gsn_addr_type
Definition: gsm23003.h:78
@ GSN_ADDR_TYPE_IPV6
Definition: gsm23003.h:80
@ GSN_ADDR_TYPE_IPV4
Definition: gsm23003.h:79
char * osmo_cgi_ps_name_c(const void *ctx, const struct osmo_cell_global_id_ps *cgi_ps)
Return MCC-MNC-LAC-RAC-CI as string, in a talloc-allocated output buffer.
Definition: gsm23003.c:403
void osmo_plmn_from_bcd(const uint8_t *bcd_src, struct osmo_plmn_id *plmn)
Definition: gsm23003.c:538
int osmo_gen_mme_domain(char *out, const struct osmo_gummei *gummei)
Generate TS 23.003 Section 19.4.2.4 MME Domain (text form)
Definition: gsm23003.c:783
int osmo_mnc_from_str(const char *mnc_str, uint16_t *mnc, bool *mnc_3_digits)
Definition: gsm23003.c:565
const char * osmo_cgi_name(const struct osmo_cell_global_id *cgi)
Return MCC-MNC-LAC-CI as string, in a static buffer.
Definition: gsm23003.c:299
int osmo_gen_mme_group_domain(char *out, uint16_t mmegi, const struct osmo_plmn_id *plmn)
Generate TS 23.003 Section 19.4.2.4 MME Group Domain (text form)
Definition: gsm23003.c:817
char * osmo_mnc_name_buf(char *buf, size_t buf_len, uint16_t mnc, bool mnc_3_digits)
Return MNC string as standardized 2- or 3-digit with leading zeros.
Definition: gsm23003.c:130
char * osmo_rnc_id_name_c(const void *ctx, const struct osmo_rnc_id *rnc_id)
Return string representation of RNC in static output buffer.
Definition: gsm23003.c:390
struct gsm48_loc_area_id lai
Definition: gsm_04_08.h:2
Definition: gsm23003.h:37
uint16_t cell_identity
Definition: gsm23003.h:39
struct osmo_routing_area_id rai
Definition: gsm23003.h:38
Definition: gsm23003.h:29
uint16_t cell_identity
Definition: gsm23003.h:31
struct osmo_location_area_id lai
Definition: gsm23003.h:30
Definition: gsm23003.h:96
uint32_t eci
Definition: gsm23003.h:98
struct osmo_plmn_id plmn
Definition: gsm23003.h:97
Definition: gsm23003.h:84
uint8_t length
Definition: gsm23003.h:86
uint8_t addr[16]
Definition: gsm23003.h:87
enum osmo_gsn_addr_type type
Definition: gsm23003.h:85
Definition: gsm23003.h:108
struct osmo_plmn_id plmn
Definition: gsm23003.h:109
struct osmo_mme_id mme
Definition: gsm23003.h:110
Definition: gsm23003.h:114
struct osmo_gummei gummei
Definition: gsm23003.h:115
uint32_t mtmsi
Definition: gsm23003.h:116
Definition: gsm23003.h:54
uint16_t lac
Definition: gsm23003.h:55
uint16_t ci
Definition: gsm23003.h:56
Definition: gsm23003.h:17
uint16_t lac
Definition: gsm23003.h:19
struct osmo_plmn_id plmn
Definition: gsm23003.h:18
Definition: gsm23003.h:102
uint8_t code
Definition: gsm23003.h:104
uint16_t group_id
Definition: gsm23003.h:103
Definition: gsm23003.h:10
uint16_t mcc
Definition: gsm23003.h:11
bool mnc_3_digits
Definition: gsm23003.h:13
uint16_t mnc
Definition: gsm23003.h:12
Definition: gsm23003.h:60
uint16_t rnc_id
Definition: gsm23003.h:62
struct osmo_plmn_id plmn
Definition: gsm23003.h:61
Definition: gsm23003.h:23
struct osmo_location_area_id lac
Definition: gsm23003.h:24
uint8_t rac
Definition: gsm23003.h:25
Definition: gsm23003.h:66
uint16_t sac
Definition: gsm23003.h:68
struct osmo_location_area_id lai
Definition: gsm23003.h:67
Definition: gsm23003.h:72
uint32_t snac
Definition: gsm23003.h:74
struct osmo_plmn_id plmn
Definition: gsm23003.h:73
Definition: gsm23003.h:91
struct osmo_plmn_id plmn
Definition: gsm23003.h:92
uint16_t tac
Definition: gsm23003.h:93