|
| enum | osmo_scu_prim_type {
OSMO_SCU_PRIM_N_CONNECT
, OSMO_SCU_PRIM_N_DATA
, OSMO_SCU_PRIM_N_EXPEDITED_DATA
, OSMO_SCU_PRIM_N_DISCONNECT
,
OSMO_SCU_PRIM_N_RESET
, OSMO_SCU_PRIM_N_INFORM
, OSMO_SCU_PRIM_N_UNITDATA
, OSMO_SCU_PRIM_N_NOTICE
,
OSMO_SCU_PRIM_N_COORD
, OSMO_SCU_PRIM_N_STATE
, OSMO_SCU_PRIM_N_PCSTATE
} |
| | SCCP-User primitives as per Q.711. More...
|
| |
| enum | osmo_sccp_routing_ind { OSMO_SCCP_RI_NONE
, OSMO_SCCP_RI_GT
, OSMO_SCCP_RI_SSN_PC
, OSMO_SCCP_RI_SSN_IP
} |
| |
| enum | osmo_sccp_gti {
OSMO_SCCP_GTI_NO_GT
, OSMO_SCCP_GTI_NAI_ONLY
, OSMO_SCCP_GTI_TT_ONLY
, OSMO_SCCP_GTI_TT_NPL_ENC
,
OSMO_SCCP_GTI_TT_NPL_ENC_NAI
} |
| |
| enum | osmo_sccp_npi {
OSMO_SCCP_NPI_UNKNOWN = 0
, OSMO_SCCP_NPI_E164_ISDN = 1
, OSMO_SCCP_NPI_GEERIC = 2
, OSMO_SCCP_NPI_X121_DATA = 3
,
OSMO_SCCP_NPI_F69_TELEX = 4
, OSMO_SCCP_NPI_E210_MARITIME = 5
, OSMO_SCCP_NPI_E212_LAND = 6
, OSMO_SCCP_NPI_E214_ISDN_MOBILE = 7
,
OSMO_SCCP_NPI_PRIVATE = 14
} |
| |
| enum | osmo_sccp_nai {
OSMO_SCCP_NAI_UNKNOWN = 0
, OSMO_SCCP_NAI_SUBSCR = 1
, OSMO_SCCP_NAI_RES_NAT_USE = 2
, OSMO_SCCP_NAI_NATL = 3
,
OSMO_SCCP_NAI_INTL = 4
} |
| |
| enum | osmo_sccp_ssn {
OSMO_SCCP_SSN_MGMT = 1
, OSMO_SCCP_SSN_ISUP = 3
, OSMO_SCCP_SSN_OMAP = 4
, OSMO_SCCP_SSN_MAP = 5
,
OSMO_SCCP_SSN_HLR = 6
, OSMO_SCCP_SSN_VLR = 7
, OSMO_SCCP_SSN_MSC = 8
, OSMO_SCCP_SSN_EIR = 9
,
OSMO_SCCP_SSN_AUC = 0x0a
, OSMO_SCCP_SSN_ISDN_SS = 0x0b
, OSMO_SCCP_SSN_RES_INTL = 0x0c
, OSMO_SCCP_SSN_BISDN = 0x0d
,
OSMO_SCCP_SSN_TC_TEST = 0x0e
, OSMO_SCCP_SSN_RANAP = 142
, OSMO_SCCP_SSN_RNSAP = 143
, OSMO_SCCP_SSN_GMLC_MAP = 145
,
OSMO_SCCP_SSN_CAP = 146
, OSMO_SCCP_SSN_gsmSCF_MAP = 147
, OSMO_SCCP_SSN_SIWF_MAP = 148
, OSMO_SCCP_SSN_SGSN_MAP = 149
,
OSMO_SCCP_SSN_GGSN_MAP = 150
, OSMO_SCCP_SSN_PCAP = 249
, OSMO_SCCP_SSN_BSC_BSSAP_LE = 250
, OSMO_SCCP_SSN_MSC_BSSAP_LE = 251
,
OSMO_SCCP_SSN_SMLC_BSSAP_LE = 252
, OSMO_SCCP_SSN_BSS_OAM = 253
, OSMO_SCCP_SSN_BSSAP = 254
} |
| |
| enum | osmo_sccp_reset_reason_nsp { OSMO_SCCP_RESET_REASON_NSP_UNSPEC = 0x0
, OSMO_SCCP_RESET_REASON_NSP_LOCAL_SCCP_ORIGIN
} |
| |
| enum | osmo_sccp_reset_reason_nsu { OSMO_SCCP_RESET_REASON_NSU_USER_SYNCHRONIZATION = 0x0
} |
| |
| enum | osmo_sccp_reset_reason_undefined { OSMO_SCCP_RESET_REASON_UNDEFINED = 0x0
} |
| |
| enum | osmo_sccp_release_reason_nsp {
OSMO_SCCP_REL_REASON_NSP_DISC_NT = 0x100
, OSMO_SCCP_REL_REASON_NSP_DISC_T
, OSMO_SCCP_REL_REASON_NSP_DISC_INVALID_STATE
, OSMO_SCCP_REL_REASON_NSP_DISC_RELEASE_IN_PROGRESS
,
OSMO_SCCP_REL_REASON_NSP_CREF_DST_ADDR_UNKNOWN_NT
, OSMO_SCCP_REL_REASON_NSP_CREF_DST_INACC_NT
, OSMO_SCCP_REL_REASON_NSP_CREF_DST_INACC_T
, OSMO_SCCP_REL_REASON_NSP_CREF_QOS_UNAVAIL_NT
,
OSMO_SCCP_REL_REASON_NSP_CREF_QOS_UNAVAIL_T
, OSMO_SCCP_REL_REASON_NSP_CREF_REASON_UNSPEC_NT
, OSMO_SCCP_REL_REASON_NSP_CREF_REASON_UNSPEC_T
, OSMO_SCCP_REL_REASON_NSP_CREF_LOCAL_ERROR
,
OSMO_SCCP_REL_REASON_NSP_CREF_INVALID_STATE
, OSMO_SCCP_REL_REASON_NSP_CREF_NO_TRANSITION
, OSMO_SCCP_REL_REASON_NSP_CREF_IN_RESTART_PHASE
, OSMO_SCCP_REL_REASON_NSP_CREF_HOP_COUNTER_VIOLATION
} |
| |
| enum | osmo_sccp_release_reason_nsu {
OSMO_SCCP_REL_REASON_NSU_DISC_NORMAL = 0x100
, OSMO_SCCP_REL_REASON_NSU_DISC_ABNORMAL
, OSMO_SCCP_REL_REASON_NSU_DISC_END_USER_CONGESTION
, OSMO_SCCP_REL_REASON_NSU_DISC_END_USER_FAILURE
,
OSMO_SCCP_REL_REASON_NSU_DISC_SCCP_USER_ORIGIN
, OSMO_SCCP_REL_REASON_NSU_DISC_ACCESS_CONGESTION
, OSMO_SCCP_REL_REASON_NSU_DISC_ACCESS_FAILURE
, OSMO_SCCP_REL_REASON_NSU_DISC_SUBSYS_CONGESTION
,
OSMO_SCCP_REL_REASON_NSU_CREF_NT_CONDITION
, OSMO_SCCP_REL_REASON_NSU_CREF_T_CONDITION
, OSMO_SCCP_REL_REASON_NSU_CREF_INCOMPAT_INFO_NSDU
, OSMO_SCCP_REL_REASON_NSU_CREF_END_USER_ORIGIN
,
OSMO_SCCP_REL_REASON_NSU_CREF_END_USER_CONGESTION
, OSMO_SCCP_REL_REASON_NSU_CREF_END_USER_FAILURE
, OSMO_SCCP_REL_REASON_NSU_CREF_SCCP_USER_ORIGINATED
, OSMO_SCCP_REL_REASON_NSU_CREF_ACCESS_CONGESTION
,
OSMO_SCCP_REL_REASON_NSU_CREF_ACCESS_FAILURE
, OSMO_SCCP_REL_REASON_NSU_CREF_SUBSYS_CONGESTION
} |
| |
| enum | osmo_sccp_release_reason_undefined { OSMO_SCCP_REL_REASON_UNDEFINED = 0x100
} |
| |
| enum | osmo_sccp_return_reason {
OSMO_SCCP_RETURN_REASON_NO_TRANSLATION_NATURE = 0
, OSMO_SCCP_RETURN_REASON_NO_TRANSLATION = 1
, OSMO_SCCP_RETURN_REASON_SUBSYSTEM_CONGESTION = 2
, OSMO_SCCP_RETURN_REASON_SUBSYSTEM_FAILURE = 3
,
OSMO_SCCP_RETURN_REASON_UNEQUIPPED_USER = 4
, OSMO_SCCP_RETURN_REASON_MTP_FAILURE = 5
, OSMO_SCCP_RETURN_REASON_NETWORK_CONGESTION = 6
, OSMO_SCCP_RETURN_REASON_UNQUALIFIED = 7
,
OSMO_SCCP_RETURN_REASON_ERROR_IN_MSG_TRANSPORT = 8
, OSMO_SCCP_RETURN_REASON_ERROR_IN_LOCAL_PROCESSING = 9
, OSMO_SCCP_RETURN_REASON_DEST_CANNOT_PERFORM_REASSEMBLY = 10
, OSMO_SCCP_RETURN_REASON_SCCP_FAILURE = 11
,
OSMO_SCCP_RETURN_REASON_HOP_COUNTER_VIOLATION = 12
, OSMO_SCCP_RETURN_REASON_SEGMENTATION_NOT_SUPPORTED = 13
, OSMO_SCCP_RETURN_REASON_SEGMENTATION_FAILURE = 14
} |
| |
| enum | osmo_sccp_sp_status { OSMO_SCCP_SP_S_INACCESSIBLE = 1
, OSMO_SCCP_SP_S_CONGESTED = 2
, OSMO_SCCP_SP_S_ACCESSIBLE = 3
} |
| |
| enum | osmo_sccp_rem_sccp_status {
OSMO_SCCP_REM_SCCP_S_AVAILABLE = 1
, OSMO_SCCP_REM_SCCP_S_UNAVAILABLE_UNKNOWN = 2
, OSMO_SCCP_REM_SCCP_S_UNEQUIPPED = 3
, OSMO_SCCP_REM_SCCP_S_INACCESSIBLE = 4
,
OSMO_SCCP_REM_SCCP_S_CONGESTED = 5
} |
| |
| enum | osmo_sccp_originator { OSMO_SCCP_ORIG_NS_PROVIDER
, OSMO_SCCP_ORIG_NS_USER
, OSMO_SCCP_ORIG_UNDEFINED
} |
| |
|
| static const char * | osmo_sccp_routing_ind_name (enum osmo_sccp_routing_ind val) |
| |
| static const char * | osmo_sccp_gti_name (enum osmo_sccp_gti val) |
| |
| static const char * | osmo_sccp_return_reason_name (enum osmo_sccp_return_reason val) |
| |
| static const char * | osmo_sccp_sp_status_name (enum osmo_sccp_sp_status val) |
| |
| static const char * | osmo_sccp_rem_sccp_status_name (enum osmo_sccp_rem_sccp_status val) |
| |
| static const char * | osmo_sccp_ssn_name (enum osmo_sccp_ssn val) |
| |
| static const char * | osmo_scu_prim_type_name (enum osmo_scu_prim_type val) |
| |
| int | osmo_scu_prim_hdr_name_buf (char *buf, size_t buflen, const struct osmo_prim_hdr *oph) |
| |
| char * | osmo_scu_prim_hdr_name_c (void *ctx, const struct osmo_prim_hdr *oph) |
| |
| char * | osmo_scu_prim_name (const struct osmo_prim_hdr *oph) |
| |
| void | osmo_sccp_vty_init (void) |
| |
| struct osmo_sccp_instance * | osmo_sccp_instance_create (struct osmo_ss7_instance *ss7, void *priv) |
| | create a SCCP Instance and register it as user with SS7 inst More...
|
| |
| void | osmo_sccp_instance_destroy (struct osmo_sccp_instance *inst) |
| |
| struct osmo_ss7_instance * | osmo_sccp_get_ss7 (const struct osmo_sccp_instance *sccp) |
| | get the SS7 instance that is related to the given SCCP instance More...
|
| |
| struct osmo_sccp_instance * | osmo_sccp_get_sccp (const struct osmo_sccp_user *scu) |
| | get the SCCP instance that is related to the given sccp user More...
|
| |
| void | osmo_sccp_set_priv (struct osmo_sccp_instance *sccp, void *priv) |
| |
| void * | osmo_sccp_get_priv (struct osmo_sccp_instance *sccp) |
| |
| void | osmo_sccp_user_unbind (struct osmo_sccp_user *scu) |
| | Unbind a given SCCP user. More...
|
| |
| void | osmo_sccp_user_set_priv (struct osmo_sccp_user *scu, void *priv) |
| |
| void * | osmo_sccp_user_get_priv (struct osmo_sccp_user *scu) |
| |
| struct osmo_sccp_user * | osmo_sccp_user_bind_pc (struct osmo_sccp_instance *inst, const char *name, osmo_prim_cb prim_cb, uint16_t ssn, uint32_t pc) |
| | Bind a given SCCP User to a given SSN+PC. More...
|
| |
| struct osmo_sccp_user * | osmo_sccp_user_bind (struct osmo_sccp_instance *inst, const char *name, osmo_prim_cb prim_cb, uint16_t ssn) |
| | Bind a given SCCP User to a given SSN (at any PC) More...
|
| |
| struct osmo_sccp_user * | osmo_sccp_user_find (struct osmo_sccp_instance *inst, uint16_t ssn, uint32_t pc) |
| | Find a SCCP User registered for given PC+SSN or SSN only. More...
|
| |
| int | osmo_sccp_user_sap_down (struct osmo_sccp_user *scu, struct osmo_prim_hdr *oph) |
| | Main entrance function for primitives from SCCP User. More...
|
| |
| int | osmo_sccp_user_sap_down_nofree (struct osmo_sccp_user *scu, struct osmo_prim_hdr *oph) |
| | Main entrance function for primitives from SCCP User. More...
|
| |
| int | osmo_sccp_addr_create (struct osmo_ss7_instance *inst, const char *name, const struct osmo_sccp_addr *dest_addr) |
| | Add an SCCP address entry to the addressbook. More...
|
| |
| int | osmo_sccp_addr_update (struct osmo_ss7_instance *inst, const char *name, const struct osmo_sccp_addr *dest_addr) |
| | Update the value of an SCCP address entry already present in the addressbook. More...
|
| |
| struct osmo_ss7_instance * | osmo_sccp_addr_by_name (struct osmo_sccp_addr *dest_addr, const char *name) |
| | Lookup an SCCP address from the addressbook by its name. More...
|
| |
| int | osmo_sccp_addr_by_name_local (struct osmo_sccp_addr *dest_addr, const char *name, const struct osmo_ss7_instance *inst) |
| | Lookup an SCCP address from the addressbook of a specific instance by its name. More...
|
| |
| const char * | osmo_sccp_name_by_addr (const struct osmo_sccp_addr *addr) |
| | Reverse lookup the lookup-name of a specified SCCP address. More...
|
| |
| void | osmo_sccp_local_addr_by_instance (struct osmo_sccp_addr *dest_addr, const struct osmo_sccp_instance *inst, uint32_t ssn) |
| | derive a basic local SCCP-Address from a given SCCP instance. More...
|
| |
| bool | osmo_sccp_check_addr (struct osmo_sccp_addr *addr, uint32_t presence) |
| | check whether a given SCCP-Address is consistent. More...
|
| |
| int | osmo_sccp_addr_cmp (const struct osmo_sccp_addr *a, const struct osmo_sccp_addr *b, uint32_t presence_criteria) |
| | Compare two SCCP addresses by given presence criteria. More...
|
| |
| int | osmo_sccp_addr_ri_cmp (const struct osmo_sccp_addr *a, const struct osmo_sccp_addr *b) |
| | Compare the routing information of two SCCP addresses. More...
|
| |
| int | osmo_sccp_gt_cmp (const struct osmo_sccp_gt *a, const struct osmo_sccp_gt *b) |
| | Compare two SCCP Global Titles. More...
|
| |
| const char * | osmo_sccp_user_name (struct osmo_sccp_user *scu) |
| | Compose a human readable string to describe the SCCP user's connection. More...
|
| |
| int | osmo_sccp_instance_next_conn_id (struct osmo_sccp_instance *sccp) |
| |
Compare two SCCP addresses by given presence criteria.
Any OSMO_SCCP_ADDR_T_* type not set in presence_criteria is ignored. In case all bits are set in presence_criteria, the comparison is in the order of: OSMO_SCCP_ADDR_T_GT, OSMO_SCCP_ADDR_T_PC, OSMO_SCCP_ADDR_T_IPv4, OSMO_SCCP_ADDR_T_IPv6, OSMO_SCCP_ADDR_T_SSN. The SCCP addresses' Routing Indicator is not compared, see osmo_sccp_addr_ri_cmp().
- Parameters
-
| [in] | a | left side. |
| [in] | b | right side. |
| [in] | presence_criteria | A bitmask of OSMO_SCCP_ADDR_T_* values, or OSMO_SCCP_ADDR_T_MASK to compare all parts, except the routing indicator. |
- Returns
- -1 if a < b, 1 if a > b, and 0 if all checked values match.
References osmo_sccp_addr::gt, osmo_sccp_addr::ip, OSMO_SCCP_ADDR_T_GT, OSMO_SCCP_ADDR_T_IPv4, OSMO_SCCP_ADDR_T_IPv6, OSMO_SCCP_ADDR_T_PC, OSMO_SCCP_ADDR_T_SSN, osmo_sccp_gt_cmp(), osmo_sccp_addr::pc, osmo_sccp_addr::presence, osmo_sccp_addr::ssn, osmo_sccp_addr::v4, and osmo_sccp_addr::v6.
Referenced by osmo_sccp_addr_ri_cmp(), and tcap_trans_track_entry_find().
Compose a human readable string to describe the SCCP user's connection.
The output follows ['<scu.name>':]<local-sccp-addr>, e.g. "'OsmoHNBW':RI=SSN_PC,PC=0.23.5,SSN=RANAP", or just "RI=SSN_PC,PC=0.23.5,SSN=RANAP" if no scu->name is set. This calls osmo_sccp_addr_name(), which returns a static buffer; hence calling this function and osmo_sccp_addr_name() in the same printf statement is likely to conflict.
References osmo_sccp_user::inst, osmo_sccp_user::name, osmo_sccp_addr_name(), osmo_sccp_make_addr_pc_ssn(), osmo_sccp_user::pc, osmo_sccp_instance::ss7, and osmo_sccp_user::ssn.