EpcTools
An event based multi-threaded C++ development framework.
|
Go to the documentation of this file.
50 #define LOW_NIBBLE(a) (((unsigned char)a) & 0x0f)
51 #define HIGH_NIBBLE(a) ((((unsigned char)a) & 0xf0) >> 4)
53 #define PARSE_MNC(a,b) { \
54 if ( HIGH_NIBBLE(b[1]) == 0x0f ) { \
56 a[1] = LOW_NIBBLE(b[2]) + '0'; \
57 a[2] = HIGH_NIBBLE(b[2]) + '0'; \
60 a[0] = LOW_NIBBLE(b[2]) + '0'; \
61 a[1] = HIGH_NIBBLE(b[2]) + '0'; \
62 a[2] = HIGH_NIBBLE(b[1]) + '0'; \
67 #define PARSE_MCC(a,b) { \
68 a[0] = LOW_NIBBLE(b[0]) + '0'; \
69 a[1] = HIGH_NIBBLE(b[0]) + '0'; \
70 a[2] = LOW_NIBBLE(b[1]) + '0'; \
74 #define PARSE_PLMNID(a) \
75 char mnc[4], mcc[4]; \
79 #define PARSE_PLMNID_MCC(a) \
83 #define APPEND_MNC(a) append("mnc").append(a).append(".")
84 #define APPEND_MCC(a) append("mcc").append(a).append(".")
85 #define APPEND_3GPPNETWORK append("3gppnetwork.org")
472 static EString tai_fqdn(
const char *lb,
const char *hb,
const char *mnc,
const char *mcc );
478 static EString tai_fqdn(
const char *lb,
const char *hb,
const unsigned char *plmnid );
485 static EString mme_fqdn(
const char *mmec,
const char *mmegi,
const char *mnc,
const char *mcc );
491 static EString mme_fqdn(
const char *mmec,
const char *mmegi,
const unsigned char *plmnid );
509 static EString rai_fqdn(
const char *rac,
const char *lac,
const char *mnc,
const char *mcc );
515 static EString rai_fqdn(
const char *rac,
const char *lac,
const unsigned char *plmnid );
521 static EString rnc_fqdn(
const char *rnc,
const char *mnc,
const char *mcc );
526 static EString rnc_fqdn(
const char *rnc,
const unsigned char *plmnid );
534 static EString sgsn_fqdn(
const char *nri,
const char *rac,
const char *lac,
const char *mnc,
const char *mcc );
541 static EString sgsn_fqdn(
const char *nri,
const char *rac,
const char *lac,
const unsigned char *plmnid );
669 static EString epc(
const char *mnc,
const char *mcc );
673 static EString epc(
const unsigned char *plmnid );
690 static EString apn(
const char *
apn,
const char *mnc,
const char *mcc );
695 static EString apn(
const char *
apn,
const unsigned char *plmnid );
792 Void
setName(
const std::string &n );
808 Void
dump(
const char *prefix )
810 std::cout << prefix <<
"Name - " << m_name << std::endl;
811 std::cout << prefix <<
"topon - " << (m_topon?
"true":
"false") << std::endl;
813 std::cout << prefix <<
"Labels" << std::endl;
814 for ( CanonicalNodeName::const_iterator it = begin(); it != end(); ++it )
815 std::cout << prefix <<
" " << *it << std::endl;
827 typedef int UsageType;
839 Void
dump(
const char *prefix )
841 for (UsageTypeList::const_iterator it = begin();
845 std::cout << prefix << *it << std::endl;
854 typedef std::string NetworkCapability;
864 Void
dump(
const char *prefix )
866 for (NetworkCapabilityList::const_iterator it = begin();
870 std::cout << prefix << *it << std::endl;
884 Void
dump(
const char *prefix )
886 for (StringVector::const_iterator it = begin();
890 std::cout << prefix << *it << std::endl;
897 std::random_shuffle ( begin(), end() );
933 UsageType
addUsageType( UsageType ut ) { m_usageTypes.push_back( ut );
return ut; }
937 NetworkCapability &
addNetworkCapability( NetworkCapability &nc ) { m_networkCapabilities.push_back(nc);
return m_networkCapabilities.back(); }
941 Void
parse(
const std::string &rp );
948 return std::find( m_usageTypes.begin(), m_usageTypes.end(), ut ) != m_usageTypes.end();
956 return std::find( m_networkCapabilities.begin(), m_networkCapabilities.end(), nc ) != m_networkCapabilities.end();
961 Void
dump(
const char *prefix =
"" )
964 if ( !m_rawProtocol.empty() )
965 std::cout <<
"/" << m_rawProtocol;
966 std::cout <<
"] - [";
968 for ( UsageTypeList::const_iterator it = m_usageTypes.begin(); it != m_usageTypes.end(); ++it )
970 std::cout << (first?
"":
",") << *it;
973 std::cout <<
"] - [";
975 for ( NetworkCapabilityList::const_iterator it = m_networkCapabilities.begin(); it != m_networkCapabilities.end(); ++it )
977 std::cout << (first?
"":
",") << *it;
980 std::cout <<
"]" << std::endl;
1014 for (AppProtocolList::const_iterator it = begin();
1018 (*it)->dump( prefix );
1038 while ( !m_protocols.empty() )
1041 m_protocols.pop_front();
1058 Void
parse(
const std::string &ds );
1065 for ( AppProtocolList::const_iterator it = m_protocols.begin(); it != m_protocols.end(); ++it )
1067 if ( (*it)->getProtocol() == protocol )
1077 std::cout << m_rawService << std::endl;
1079 for ( AppProtocolList::const_iterator it = m_protocols.begin(); it != m_protocols.end(); ++it )
1132 uint16_t
setOrder( uint16_t order ) {
return m_order = order; }
1136 uint16_t
setPreference( uint16_t preference ) {
return m_preference = preference; }
1140 uint16_t
setPort( uint16_t port ) {
return m_port = port; }
1150 Void
addIPv4Host(
const std::string &host ) { m_ipv4_hosts.push_back( host ); }
1153 Void
addIPv6Host(
const std::string &host ) { m_ipv6_hosts.push_back( host ); }
1159 std::cout << prefix <<
"HOSTNAME: " << m_hostname << std::endl;
1160 std::cout << prefix <<
" order - " << m_order << std::endl;
1161 std::cout << prefix <<
" preference - " << m_preference << std::endl;
1162 std::cout << prefix <<
" port - " << m_port << std::endl;
1165 std::cout << prefix <<
" supported protocols" << std::endl;
1167 m_supported_protocols.
dump( pfx.c_str() );
1169 std::cout << prefix <<
" IPv4 HOSTS" << std::endl;
1170 m_ipv4_hosts.
dump( pfx.c_str() );
1172 std::cout << prefix <<
" IPv6 HOSTS" << std::endl;
1173 m_ipv6_hosts.
dump( pfx.c_str() );
1182 uint16_t m_preference;
1213 for (NodeSelectorResultList::const_iterator it = begin();
1217 (*it)->dump( prefix );
1283 std::cout <<
"NodeSelector REQUEST" << std::endl;
1284 std::cout <<
" domain - " << m_domain << std::endl;
1286 std::cout <<
" desired protocols" << std::endl;
1287 m_desiredProtocols.
dump(
" " );
1288 std::cout <<
" desired usage types" << std::endl;
1289 m_desiredUsageTypes.
dump(
" " );
1290 std::cout <<
" desired network capabilities" << std::endl;
1291 m_desiredNetworkCapabilities.
dump(
" " );
1292 std::cout <<
" results" << std::endl;
1293 m_results.
dump(
" " );
1315 AppServiceEnum parseService(
const std::string &service, std::list<AppProtocolEnum> &protocols )
const;
1318 static Void async_callback(
DNS::QueryPtr q, Bool cacheHit,
const void *data);
1320 DNS::namedserverid_t m_nsid;
1384 std::cout << prefix <<
"canonical name 1 - " << m_cnn1.
getName() << std::endl;
1385 m_candidate1.
dump( pfx.c_str() );
1386 std::cout << prefix <<
"canonical name 2 - " << m_cnn2.
getName() << std::endl;
1387 m_candidate2.
dump( pfx .c_str());
1388 std::cout << prefix <<
"pair type - " << (
1391 m_pairtype ==
ptDNSPriority ?
"DNS priority" :
"unknown") << std::endl;
1392 std::cout << prefix <<
"topological matches - " << m_topologicalMatches << std::endl;
1403 int m_topologicalMatches;
1422 Void
dump(
const char *prefix =
"" )
1430 std::cout << prefix <<
"candidate list" << std::endl;
1431 for ( ColocatedCandidateList::const_iterator it = begin(); it != end(); ++it )
1433 std::cout << pfx1 <<
"candidate " << candidate++ << std::endl;
1434 (*it)->dump( pfx2.c_str() );
1604 SGWNodeSelector(
const unsigned char lb,
const unsigned char hb,
const char *mnc,
const char *mcc )
1609 sprintf( lbbuf,
"%02x", lb );
1610 sprintf( hbbuf,
"%02x", hb );
1625 sprintf( lbbuf,
"%02x", lb );
1626 sprintf( hbbuf,
"%02x", hb );
1704 sprintf( lbbuf,
"%02x", lb );
1705 sprintf( hbbuf,
"%02x", hb );
1720 sprintf( lbbuf,
"%02x", lb );
1721 sprintf( hbbuf,
"%02x", hb );
1927 uint16_t
setOrder( uint16_t order ) {
return m_order = order; }
1965 std::cout << prefix <<
"Flags: " << (
1967 m_type ==
dnt_service ?
"service" :
"unknown") << std::endl;
1968 std::cout << prefix <<
"Order: " << m_order << std::endl;
1969 std::cout << prefix <<
"Preference: " << m_preference << std::endl;
1970 std::cout << prefix <<
"Service: " << m_service << std::endl;
1971 std::cout << prefix <<
"Replacement: " << m_replacement << std::endl;
1979 uint16_t m_preference;
2033 std::cout << prefix <<
"Name: " << m_name << std::endl;
2034 std::cout << prefix <<
"IPv4 addresses" << std::endl;
2035 m_ipv4_addrs.
dump( pfx.c_str() );
2036 std::cout << prefix <<
"IPv6 addresses" << std::endl;
2037 m_ipv6_addrs.
dump( pfx.c_str() );
2064 uint16_t
setPriority( uint16_t priority ) {
return m_priority = priority; }
2072 uint16_t
setWeight( uint16_t weight ) {
return m_weight = weight; }
2080 uint16_t
setPort( uint16_t port ) {
return m_port = port; }
2092 std::cout << prefix <<
"Priority: " << m_priority << std::endl;
2093 std::cout << prefix <<
"Weight: " << m_weight << std::endl;
2094 std::cout << prefix <<
"Port: " << m_port << std::endl;
2096 std::cout << prefix <<
"Diameter Host" << std::endl;
2097 m_host.
dump( pfx.c_str() );
2101 uint16_t m_priority;
2133 for (DiameterSrvVector::const_iterator it = begin();
2137 std::cout << prefix <<
"Diameter SRV " << ++cnt << std::endl;
2138 (*it)->dump( pfx.c_str() );
2170 std::cout << prefix <<
"Host Information" << std::endl;
2171 m_host.
dump( pfx.c_str() );
2199 std::cout << prefix <<
"Service Information" << std::endl;
2200 m_srv.
dump( pfx.c_str() );
2227 Void
dump(
const char *prefix =
"" )
2229 for (DiameterNaptrList::const_iterator it = begin();
2298 #endif // #ifndef __EPCDNS_H
x_s2a_pmip
Definition: epcdns.h:155
static EString mme_pool_fqdn(const char *mmegi, const char *mnc, const char *mcc)
Constructs the MME pool FQDN.
Definition: epcdns.cpp:106
colocated
Definition: epcdns.h:1346
x-s8-gtp
Definition: epcdns.h:235
AppServiceEnum getService()
Retrieves the application service type.
Definition: epcdns.h:1048
PairType
Pair type.
Definition: epcdns.h:1341
static EString diameter_fqdn(const char *mnc, const char *mcc)
Constructs the Diameter FQDN.
Definition: epcdns.cpp:683
~DiameterNaptrList()
Class destructor.
Definition: epcdns.h:2215
Void dump(const char *prefix="")
Prints the contents of this object.
Definition: epcdns.h:2227
An eNodeB user plane node selector.
Definition: epcdns.h:1786
const EString & setHostname(const std::string &hostname)
Assigns the host name.
Definition: epcdns.h:1144
Defines classes related to the DNS cache.
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:2165
DiameterProtocolEnum
The Diameter transport protocols.
Definition: epcdns.h:429
UsageTypeList()
Default constructor.
Definition: epcdns.h:835
Void(* AsyncNodeSelectorCallback)(NodeSelector &ns, cpVoid data)
Definition: epcdns.h:1232
x-nq
Definition: epcdns.h:135
contains the information to select a node.
Definition: epcdns.h:1235
x-s6a
Definition: epcdns.h:171
DNS::namedserverid_t setNamedServerID(DNS::namedserverid_t nsid)
Assigns the named server ID.
Definition: epcdns.h:1244
NetworkCapability & addDesiredNetworkCapability(NetworkCapability &nc)
Adds a desired network capability to the list of desired network capabilities.
Definition: epcdns.h:1270
GGSNAppProtocolEnum
the GGSN related protocols.
Definition: epcdns.h:241
SGWUPFNodeSelector(const char *node, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1752
AppService(const std::string &ds)
Class constructor.
Definition: epcdns.h:1034
~AppProtocol()
Class destructor.
Definition: epcdns.h:911
AMF.
Definition: epcdns.h:120
Void addSupportedProtocol(AppProtocol *ap)
Adds the application object to the list.
Definition: epcdns.h:1147
NodeSelector()
Default constructor.
Definition: epcdns.cpp:1057
Void parse(const std::string &ds)
Parses an application service string.
Definition: epcdns.cpp:1090
The namespace for the TS 29.303 related DNS functions.
Definition: epcdns.h:92
x-s6a
Definition: epcdns.h:286
Bool getTopon()
Determines if the "topon" feature is enabled for this object.
Definition: epcdns.h:796
static EString epc(const char *mnc, const char *mcc)
Constructs the home network realm/domain name.
Definition: epcdns.cpp:447
SGWUPFNodeSelector(const char *node, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1761
x-sxa
Definition: epcdns.h:179
DiameterNaptrTypeEnum getType()
Retrieves the NAPTR type.
Definition: epcdns.h:1919
SGSN.
Definition: epcdns.h:112
x-s2c-dsmip
Definition: epcdns.h:161
Represents a Diameter selector.
Definition: epcdns.h:2245
PGWNodeSelector(const char *apn, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1530
uint16_t getPreference()
Retrieves the preference value.
Definition: epcdns.h:1931
static AppServiceEnum getAppService(const std::string &s)
Retrieves the AppServiceEnum value for a given string.
Definition: epcdns.cpp:506
SGWAppProtocolEnum
the SGW related protocols.
Definition: epcdns.h:216
x-s8-gtp
Definition: epcdns.h:173
uint16_t setPreference(uint16_t pref)
Assigns the preference value.
Definition: epcdns.h:1935
x-s1_u
Definition: epcdns.h:219
x-s4
Definition: epcdns.h:263
const EString & setRealm(const char *mnc, const char *mcc)
Assigns the realm.
Definition: epcdns.h:2262
EString & getRawService()
Retrieves the raw application service string.
Definition: epcdns.h:1054
const EString & getService()
Retrieves the service value.
Definition: epcdns.h:1939
const EString & setName(const char *name)
Assigns the Diameter host name.
Definition: epcdns.h:2006
AppProtocolList & getDesiredProtocols()
Retrieves the list of application protocols.
Definition: epcdns.h:1251
SGW.
Definition: epcdns.h:108
x-s1-mme
Definition: epcdns.h:282
SGWNodeSelector(const char *node, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1657
SGWUPFNodeSelector(unsigned char lb, unsigned char hb, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1715
EpcNodeSelector(const char *node, const unsigned char *plmnid, AppServiceEnum appsvc=x_3gpp_any)
Class constructor.
Definition: epcdns.h:1845
Unknown.
Definition: epcdns.h:127
TCP.
Definition: epcdns.h:434
const EString & getName() const
Retrieves the Diameter host name.
Definition: epcdns.h:2002
AMFAppProtocolEnum
the AMF related protocols.
Definition: epcdns.h:310
x-s2b-pmip
Definition: epcdns.h:227
Void dump()
Prints the contents of this object.
Definition: epcdns.h:1281
3GPP SWm
Definition: epcdns.h:372
SIP.
Definition: epcdns.h:348
~AppService()
Class destructor.
Definition: epcdns.h:1036
uint16_t setOrder(uint16_t order)
Assigns the order value.
Definition: epcdns.h:1132
int getTopologicalMatches()
Retrieves the number of topological matches.
Definition: epcdns.h:1375
UsageType addUsageType(UsageType ut)
Adds a usage type object to the usage type list.
Definition: epcdns.h:933
x-s8-pmip
Definition: epcdns.h:212
x-sxb
Definition: epcdns.h:181
A Diameter NAPTR A record object.
Definition: epcdns.h:2153
static EString apn(const char *apn, const char *mnc, const char *mcc)
Constructs the APN.
Definition: epcdns.cpp:486
MMEAppProtocolEnum
the SGSN related protocols.
Definition: epcdns.h:269
Void addIPv4Host(const std::string &host)
Adds an IPv4 host to the list of IPv4 hosts.
Definition: epcdns.h:1150
static EString rnc_fqdn(const char *rnc, const char *mnc, const char *mcc)
Constructs the radio network controller (RNC) FQDN.
Definition: epcdns.cpp:150
Canonical node name.
Definition: epcdns.h:781
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:1963
static EString emergency_epdg_oi_fqdn(const char *mnc, const char *mcc)
Constructs the operator identifier (OI) based emergency ePDG FQDN.
Definition: epcdns.cpp:320
AppProtocolList()
Default constructor.
Definition: epcdns.h:998
MMENodeSelector(const char *mmegi, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1489
WiMAX DHCP Diameter Application (WDDA)
Definition: epcdns.h:415
UsageType addDesiredUsageType(UsageType ut)
Adds a desired usage type to the list of desired usage types.
Definition: epcdns.h:1262
Void addIPv6Host(const std::string &host)
Adds an IPv6 host to the list of IPv6 hosts.
Definition: epcdns.h:1153
AppProtocolEnum
3GPP protocols defined in 23.003 v15.5.0, table 19.4.3.1.
Definition: epcdns.h:124
SGWUPFNodeSelector(const char *lb, const char *hb, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1732
x-s12
Definition: epcdns.h:147
uint16_t getPort()
Retrieves the IP port.
Definition: epcdns.h:2076
x-gn
Definition: epcdns.h:129
x-sv
Definition: epcdns.h:177
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:2028
Represents an NAPTR resource record.
Definition: dnsrecord.h:429
x-sxc
Definition: epcdns.h:183
x-s2b-gtp
Definition: epcdns.h:200
PGWAppProtocolEnum
the PGW related protocols.
Definition: epcdns.h:187
x-s2a-gtp
Definition: epcdns.h:194
static EString global_enodeb_id_fqdn(const char *enb, const char *mnc, const char *mcc)
Constructs the global eNodeB ID.
Definition: epcdns.cpp:405
static EString nonemergency_epdg_visitedcountry_fqdn(const char *mcc)
Constructs the visited country FQDN.
Definition: epcdns.cpp:301
x-s2a-mipv4
Definition: epcdns.h:196
AppProtocol * addDesiredProtocol(PGWAppProtocolEnum p)
Adds the desired application protocol to the selector.
Definition: epcdns.h:1863
MSCAppProtocolEnum
the MSC related protocols.
Definition: epcdns.h:292
AppProtocol()
Default constructor.
Definition: epcdns.h:909
ENodeBUPFNodeSelector(const char *enb, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1793
x-s3
Definition: epcdns.h:284
topological distance
Definition: epcdns.h:1348
service
Definition: epcdns.h:1895
WiMAX Policy and Charging Control R3 Online Charging Diameter Application (WiMAX PCC-R3-OC)
Definition: epcdns.h:425
AppProtocol * findProtocol(AppProtocolEnum protocol)
Searches for a specific application protocol object.
Definition: epcdns.h:1063
const EString & setName(const std::string &name)
Assigns the Diameter host name.
Definition: epcdns.h:2010
x-s1-mme
Definition: epcdns.h:139
const EString & getDomainName()
Retrieves the domain name.
Definition: epcdns.h:1254
Represents a diameter host.
Definition: epcdns.h:1988
const EString & setRealm(const char *realm)
Assigns the realm.
Definition: epcdns.h:2257
x-gp
Definition: epcdns.h:192
DiameterHost()
Default constructor.
Definition: epcdns.h:1992
int topologicalCompare(const CanonicalNodeName &right)
Performs a topological comparison with another CanonicalNodeName object.
Definition: epcdns.cpp:866
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:864
~DiameterSrv()
Class destructor.
Definition: epcdns.h:2056
Mobile IPv4.
Definition: epcdns.h:340
host name
Definition: epcdns.h:1893
A EPC node selector.
Definition: epcdns.h:1827
TCP with TLS.
Definition: epcdns.h:438
NodeSelectorResultList()
Default constructor.
Definition: epcdns.h:1197
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:839
WiMAX Policy and Charging Control R3 Offline Charging Diameter Application (WiMAX PCC-R3-OFC)
Definition: epcdns.h:421
Represents a list of network capabilities.
Definition: epcdns.h:858
AppServiceEnum
Service names defined in 23.003 v15.5.0, table 19.4.3.1.
Definition: epcdns.h:99
const EString & setService(const char *service)
Assigns the service value.
Definition: epcdns.h:1943
x-sv
Definition: epcdns.h:288
CanonicalNodeName & getCanonicalNodeName2()
Retrieves the second canonical node name.
Definition: epcdns.h:1369
unknown
Definition: epcdns.h:1344
UPF.
Definition: epcdns.h:118
x-gp
Definition: epcdns.h:131
Unknown.
Definition: epcdns.h:432
static AppProtocolEnum getAppProtocol(const std::string &p)
Retrieves the AppProtocolEnum value for a given string.
Definition: epcdns.cpp:519
x-s10
Definition: epcdns.h:278
static EString mme_fqdn(const char *mmec, const char *mmegi, const char *mnc, const char *mcc)
Constructs the mobile management entity (MME) FQDN.
Definition: epcdns.cpp:83
A PGW user plane node selector.
Definition: epcdns.h:1555
Diameter name pointer (NAPTR) object.
Definition: epcdns.h:1902
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:1379
Contains the node selector results.
Definition: epcdns.h:1096
A list of node selector result objects.
Definition: epcdns.h:1193
x-sxc
Definition: epcdns.h:306
static EString nonemergency_epdg_lac_fqdn(const char *lac, const char *mnc, const char *mcc)
Constructs the location area code based ePDG FQDN.
Definition: epcdns.cpp:279
DiameterNaptrTypeEnum
Diameter name pointer (NAPTR) type.
Definition: epcdns.h:1888
EpcNodeSelector(const char *fqdn, AppServiceEnum appsvc=x_3gpp_any)
Class constructor.
Definition: epcdns.h:1854
x-s4
Definition: epcdns.h:229
x-sv
Definition: epcdns.h:295
MMENodeSelector(const char *mmec, const char *mmegi, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1470
WiMAX Policy and Charging Control R3 Offline Charging Prime Diameter Application (WiMAX PCC-R3-OFC-PR...
Definition: epcdns.h:423
~DiameterSrvVector()
Class destructor.
Definition: epcdns.h:2115
Represents a vector (array) of Diameter servers.
Definition: epcdns.h:2111
DiameterApplicationEnum setApplication(DiameterApplicationEnum app)
Assigns the applciation type.
Definition: epcdns.h:2274
~ColocatedCandidateList()
Class destructor.
Definition: epcdns.cpp:1184
Void addIPv4Address(const std::string &addr)
Adds an IPv4 address for this Diameter host.
Definition: epcdns.h:2021
AppProtocol * addDesiredProtocol(MMEAppProtocolEnum p)
Adds the desired application protocol to the selector.
Definition: epcdns.h:1498
unknown
Definition: epcdns.h:1891
3GPP S6a
Definition: epcdns.h:370
WiMAX Network Accounting Diameter Application (WNADA)
Definition: epcdns.h:409
A Diameter NAPTR S record object.
Definition: epcdns.h:2182
NodeSelectorResult & getCandidate2()
Retrieves the second candidate node selector result object.
Definition: epcdns.h:1363
Void sort_vector()
Sorts the vector (array) of Diameter servers.
Definition: epcdns.cpp:1381
DiameterNaptr(DiameterNaptrTypeEnum drt)
Class constructor.
Definition: epcdns.h:1907
PGW.
Definition: epcdns.h:106
NodeSelectorResultList & getResults()
Retrieves the node selector results list.
Definition: epcdns.h:1257
Relay.
Definition: epcdns.h:356
const EString & getRealm()
Retrieves the realm.
Definition: epcdns.h:2253
DiameterProtocolEnum getProtocol()
Retrieves the protocol type.
Definition: epcdns.h:2278
uint16_t setPort(uint16_t port)
Assigns the IP port.
Definition: epcdns.h:1140
StringVector & getIPv6Addresses()
Retrieves the list of IPv6 addresses for this Diameter host.
Definition: epcdns.h:2017
x-gp
Definition: epcdns.h:255
virtual ~DiameterNaptr()
Class destructor.
Definition: epcdns.h:1913
DiameterSrvVector & getSrvs()
Retrieves the Diameter server.
Definition: epcdns.h:2190
x-s11
Definition: epcdns.h:280
A list of Diameter NAPTR objects.
Definition: epcdns.h:2211
DiameterApplicationEnum
the Diameter application ID's.
Definition: epcdns.h:317
DNS priority.
Definition: epcdns.h:1350
DNS::namedserverid_t getNamedServerID()
Retrieves the named server ID.
Definition: epcdns.h:1240
x-s2a-pmip
Definition: epcdns.h:198
WiMAX Policy and Charging Control R3 Policies Diameter Application (WiMAX PCC-R3-P)
Definition: epcdns.h:419
AppProtocol * addDesiredProtocol(PGWAppProtocolEnum p)
Adds the desired application protocol to the selector.
Definition: epcdns.h:1539
GGSN.
Definition: epcdns.h:110
static EString getDiameterService(DiameterApplicationEnum app, DiameterProtocolEnum protocol)
Constructs the Diameter service string.
Definition: epcdns.cpp:702
~NodeSelectorResultList()
Class destructor.
Definition: epcdns.h:1199
x-sv
Definition: epcdns.h:265
3GPP S9
Definition: epcdns.h:374
x-s1-u
Definition: epcdns.h:141
static EString rai_fqdn(const char *rac, const char *lac, const char *mnc, const char *mcc)
Constructs the routing area identity (RAI) FQDN.
Definition: epcdns.cpp:127
x-s3
Definition: epcdns.h:163
PairType getPairType()
Retrieves the pair type.
Definition: epcdns.h:1372
x-s4
Definition: epcdns.h:165
WiMAX Location Authentication Authorization Diameter Application (WLAADA)
Definition: epcdns.h:417
Void addIPv6Address(const std::string &addr)
Adds an IPv6 address for this Diameter host.
Definition: epcdns.h:2024
Void dump(const char *prefix="")
Prints the contents of this object.
Definition: epcdns.h:1422
MMENodeSelector(const char *mmegi, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1480
x-n2
Definition: epcdns.h:133
x-gp
Definition: epcdns.h:274
UsageTypeList & getUsageTypes()
Retrieves the list of usage types.
Definition: epcdns.h:921
static EString nonemergency_epdg_tai_fqdn(const char *lb, const char *hb, const char *mnc, const char *mcc)
Constructs the tracking area identity based ePDG FQDN.
Definition: epcdns.cpp:255
Base Accounting.
Definition: epcdns.h:342
A list of colocated candidates.
Definition: epcdns.h:1410
SGWNodeSelector(const char *node, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1666
SGSNAppProtocolEnum
the SGSN related protocols.
Definition: epcdns.h:250
x-gn
Definition: epcdns.h:244
DiameterHost(const char *name)
Class constructor.
Definition: epcdns.h:1995
DiameterHost & getHost()
Retrieves the Diameter host.
Definition: epcdns.h:2161
DiameterNaptrList & process()
Performs the lookup of the Diameter hosts.
Definition: epcdns.cpp:1221
StringVector & getIPv6Hosts()
Retrieves the list of IPv6 hosts.
Definition: epcdns.h:1127
const EString & getReplacement()
Retrieves the replacement value.
Definition: epcdns.h:1951
AppProtocol * addDesiredProtocol(SGWAppProtocolEnum p)
Adds the desired application protocol to the selector.
Definition: epcdns.h:1675
AppServiceEnum getDesiredService()
Retrieves the desired application service type.
Definition: epcdns.h:1248
DiameterNaptrA()
Default constructor.
Definition: epcdns.h:2157
uint16_t setPreference(uint16_t preference)
Assigns the preference value.
Definition: epcdns.h:1136
x-s8-gtp
Definition: epcdns.h:210
const EString & getHostname()
Retrieves the host name.
Definition: epcdns.h:1109
x-s12
Definition: epcdns.h:223
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:1157
unknown
Definition: epcdns.h:320
DiameterNaptrS()
Default constructor.
Definition: epcdns.h:2186
WiMAX MIP4 Diameter Application (WM4DA)
Definition: epcdns.h:411
A MME node selector.
Definition: epcdns.h:1451
Void parse(const std::string &rp)
Parses any usage types and network capabilities.
Definition: epcdns.cpp:1113
x-s10
Definition: epcdns.h:143
x-nqprime
Definition: epcdns.h:257
Provides several utilities for manipulating names, services and protocols.
Definition: epcdns.h:445
Void setName(const std::string &n)
Assigns the canonical node name.
Definition: epcdns.cpp:817
x-s11
Definition: epcdns.h:221
static EString epc_nodes_domain_fqdn(const char *mnc, const char *mcc)
Constructs the EPC nodes subdomain (DNS zone).
Definition: epcdns.cpp:196
static Bool sort_compare(NodeSelectorResult *&first, NodeSelectorResult *&second)
A comparison function used to sort the members of the list.
Definition: epcdns.cpp:1076
EAP.
Definition: epcdns.h:346
static EString home_network_gprs(const char *mnc, const char *mcc)
Constructs the APN operator identifier.
Definition: epcdns.cpp:42
StringVector & getIPv4Addresses()
Retrieves the list of IPv4 addresses for this Diameter host.
Definition: epcdns.h:2014
MSC.
Definition: epcdns.h:116
uint16_t getWeight()
Retrieves the weight value.
Definition: epcdns.h:2068
x-gn
Definition: epcdns.h:272
DiameterSelector()
Default constructor.
Definition: epcdns.cpp:1215
x-s16
Definition: epcdns.h:259
Represents a vector (array) of strings.
Definition: epcdns.h:879
Represents a Diameter server.
Definition: epcdns.h:2050
x-gn
Definition: epcdns.h:253
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:1211
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:2127
x-s2a-mipv4
Definition: epcdns.h:153
AppProtocolEnum getProtocol()
Retrieves the protocol enumeration.
Definition: epcdns.h:918
NodeSelectorResult()
Default constructor.
Definition: epcdns.h:1100
x-nq
Definition: epcdns.h:276
Unknown.
Definition: epcdns.h:102
x-nqprime
Definition: epcdns.h:137
DiameterHost(const std::string &name)
Class constructor.
Definition: epcdns.h:1998
const EString & getRawProtocol()
Retrieves the raw protocol string.
Definition: epcdns.h:915
x-s5-gtp
Definition: epcdns.h:167
static EString emergency_epdg_tai_fqdn(const char *lb, const char *hb, const char *mnc, const char *mcc)
Constructs the tracking area identity based emergency ePDG FQDN.
Definition: epcdns.cpp:340
Represents a list of usage types.
Definition: epcdns.h:831
Void dump()
Prints the contents of this object.
Definition: epcdns.h:1075
PGWUPFNodeSelector(const char *apn, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1571
const EString & setService(const std::string &service)
Assigns the service value.
Definition: epcdns.h:1947
EpcNodeSelector & setAppService(AppServiceEnum s)
Assigns the required application service type.
Definition: epcdns.h:1874
const EString & setRealm(const unsigned char *plmnid)
Assigns the realm.
Definition: epcdns.h:2266
SGWNodeSelector(const unsigned char lb, const unsigned char hb, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1604
NetworkCapability & addDesiredNetworkCapability(const char *nc)
Adds a desired network capability to the list of desired network capabilities.
Definition: epcdns.h:1266
static EString epc_node_fqdn(const char *node, const char *mnc, const char *mcc)
Constructs the EPC node FQDN.
Definition: epcdns.cpp:215
x-s5-pmip
Definition: epcdns.h:169
NASREQ.
Definition: epcdns.h:338
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:884
x-s8-pmip
Definition: epcdns.h:237
static const char * getDiameterProtocol(DiameterProtocolEnum protocol)
Converts a DiameterProtocolEnum to the corresponding Diameter protocol string.
Definition: epcdns.cpp:795
AppProtocolList & getProtocols()
Retrieves the list of application protocols.
Definition: epcdns.h:1051
WiMAX MIP6 Diameter Application (WM6DA)
Definition: epcdns.h:413
Application protocol object.
Definition: epcdns.h:905
AppProtocol * addDesiredProtocol(UPFAppProtocolEnum p)
Adds the desired application protocol to the selector.
Definition: epcdns.h:1811
x-s2b-pmip
Definition: epcdns.h:159
const EString & setReplacement(const std::string &replacement)
Assigns the replacement value.
Definition: epcdns.h:1959
CanonicalNodeName()
Default constructor.
Definition: epcdns.cpp:806
AppService()
Default constructor.
Definition: epcdns.h:1031
A SGW node selector.
Definition: epcdns.h:1596
A PGW node selector.
Definition: epcdns.h:1514
x-16
Definition: epcdns.h:149
NetworkCapability & addNetworkCapability(NetworkCapability &nc)
Adds a network capability to the network capability list.
Definition: epcdns.h:937
x-s5-gtp
Definition: epcdns.h:231
x-s5-pmip
Definition: epcdns.h:233
static EString nonemergency_epdg_oi_fqdn(const char *mnc, const char *mcc)
Constructs the operator identifier (OI) based ePDG FQDN.
Definition: epcdns.cpp:235
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:808
ENodeBUPFNodeSelector(const char *enb, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1802
SGWNodeSelector(const char *lb, const char *hb, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1637
const EString & setReplacement(const char *replacement)
Assigns the replacement value.
Definition: epcdns.h:1955
SCTP.
Definition: epcdns.h:436
String class.
Definition: estring.h:30
static EString emergency_epdg_visitedcountry_fqdn(const char *mcc)
Constructs the visited country emergency FQDN.
Definition: epcdns.cpp:386
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:2194
x-sxa
Definition: epcdns.h:302
~AppProtocolList()
Class destructor.
Definition: epcdns.h:1000
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:1012
Manages a list of application protocols.
Definition: epcdns.h:994
AppProtocol * addDesiredProtocol(UPFAppProtocolEnum p)
Adds the desired application protocol to the selector.
Definition: epcdns.h:1770
static EString tai_fqdn(const char *lb, const char *hb, const char *mnc, const char *mcc)
Constructs the tracking area identity FQDN.
Definition: epcdns.cpp:60
x-gn
Definition: epcdns.h:190
uint16_t getPreference()
Retrieves the preference value.
Definition: epcdns.h:1115
x-gp
Definition: epcdns.h:246
x-s2c-dsmip
Definition: epcdns.h:204
PGWNodeSelector(const char *apn, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1521
x-s5-gtp
Definition: epcdns.h:206
Mobile IPv6 Auth.
Definition: epcdns.h:352
MME.
Definition: epcdns.h:114
Mobile IPv6 IKE.
Definition: epcdns.h:350
x-s2b-pmip
Definition: epcdns.h:202
Credit Control.
Definition: epcdns.h:344
Void shuffle()
Randomizes the list of strings.
Definition: epcdns.h:895
NetworkCapabilityList & getNetworkCapabilities()
Retrieves the list of network capabilities.
Definition: epcdns.h:924
x-s2b-gtp
Definition: epcdns.h:157
Void dump(const char *prefix)
Prints the contents of this object.
Definition: epcdns.h:2088
A SGW user plane node selector.
Definition: epcdns.h:1691
x-s2a-gtp
Definition: epcdns.h:151
uint16_t getPriority()
Retrieves the priority value.
Definition: epcdns.h:2060
uint16_t getOrder()
Retrieves the order value.
Definition: epcdns.h:1112
EpcNodeSelector(const char *node, const char *mnc, const char *mcc, AppServiceEnum appsvc=x_3gpp_any)
Class constructor.
Definition: epcdns.h:1835
~NodeSelector()
Class destructor.
Definition: epcdns.cpp:1063
x-s2a-pmip
Definition: epcdns.h:225
AppProtocol * addDesiredProtocol(UPFAppProtocolEnum p)
Adds the desired application protocol to the selector.
Definition: epcdns.h:1580
static EString home_network(const char *mnc, const char *mcc)
Constructs the home network domain name.
Definition: epcdns.cpp:24
std::shared_ptr< Query > QueryPtr
A typedef to std::shared_ptr<Query>.
Definition: dnsquery.h:40
uint16_t getOrder()
Retrieves the order value.
Definition: epcdns.h:1923
3GPP STa
Definition: epcdns.h:368
x-s5-pmip
Definition: epcdns.h:208
PGWUPFNodeSelector(const char *apn, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1562
Represents a colocated candidate.
Definition: epcdns.h:1337
Any.
Definition: epcdns.h:104
DiameterApplicationEnum getApplicataion()
Retrieves the application type.
Definition: epcdns.h:2270
AppServiceEnum setAppService(AppServiceEnum s)
Assigns the application service type.
Definition: epcdns.h:1305
x-n2
Definition: epcdns.h:313
static uint32_t getDiameterApplication(DiameterApplicationEnum app)
Converts a DiameterApplicationEnum to the corresponding Diameter application ID.
Definition: epcdns.cpp:709
SGWUPFNodeSelector(const char *lb, const char *hb, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1742
uint16_t setOrder(uint16_t order)
Assigns the order value.
Definition: epcdns.h:1927
DiameterProtocolEnum setProtocol(DiameterProtocolEnum proto)
Assigns the protocol type.
Definition: epcdns.h:2282
Encapsulates and extends a std::string object.
UPFAppProtocolEnum
the UPF related protocols.
Definition: epcdns.h:299
CanonicalNodeName & getCanonicalNodeName1()
Retrieves the first canonical node name.
Definition: epcdns.h:1366
x-sxb
Definition: epcdns.h:304
static EString local_homenetwork_fqdn(const char *lhn, const char *mcc)
Constructs the local home network identifier.
Definition: epcdns.cpp:426
const EString getName() const
Retrieves the canonical node name.
Definition: epcdns.h:799
x-s3
Definition: epcdns.h:261
AppProtocolEnum setProtocol(AppProtocolEnum ape)
Assigns the protocol enumeration.
Definition: epcdns.h:929
static EString emergency_epdg_lac_fqdn(const char *lac, const char *mnc, const char *mcc)
Constructs the location area code based emergency ePDG FQDN.
Definition: epcdns.cpp:364
Void dump(const char *prefix="")
Prints the contents of this object.
Definition: epcdns.h:961
SGWNodeSelector(const char *lb, const char *hb, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1647
uint16_t getPort()
Retrieves the IP port value.
Definition: epcdns.h:1118
SGWUPFNodeSelector(const unsigned char lb, const unsigned char hb, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1699
SGWNodeSelector(unsigned char lb, unsigned char hb, const unsigned char *plmnid)
Class constructor.
Definition: epcdns.h:1620
AppProtocolList & getSupportedProtocols()
Retrieves the list supported protocols.
Definition: epcdns.h:1121
Bool findUsageType(UsageType ut)
Determines if a usage type exists in the usage type list.
Definition: epcdns.h:946
x-s8-pmip
Definition: epcdns.h:175
uint16_t setPriority(uint16_t priority)
Assigns the priority value.
Definition: epcdns.h:2064
iMAX Network Access Authentication and Authorization Diameter Application (WNAAADA)
Definition: epcdns.h:407
NodeSelectorResult & getCandidate1()
Retrieves the first candidate node selector result object.
Definition: epcdns.h:1360
NodeSelectorResultList & process()
Performs synchronous selection process.
Definition: epcdns.cpp:895
uint16_t setWeight(uint16_t weight)
Assigns the weight value.
Definition: epcdns.h:2072
x-s11
Definition: epcdns.h:145
DiameterHost & getHost()
Retrieves the diameter host.
Definition: epcdns.h:2084
StringVector & getIPv4Hosts()
Retrieves the list of IPv4 hosts.
Definition: epcdns.h:1124
uint16_t setPort(uint16_t port)
Assigns the IP port.
Definition: epcdns.h:2080
DiameterSrv()
Default constructor.
Definition: epcdns.h:2054
static EString apn_fqdn(const char *apn, const char *mnc, const char *mcc)
Constructs the APN FQDN.
Definition: epcdns.cpp:466
const EString & setDomainName(const std::string &d)
Assigns the domain name.
Definition: epcdns.h:1309
The application service object.
Definition: epcdns.h:1027
QoS.
Definition: epcdns.h:354
Bool findNetworkCapability(const NetworkCapability &nc)
Determines if a network capability exists in the network capabilities list.
Definition: epcdns.h:954
Void addDesiredProtocol(AppProtocol *ap)
Adds a desired application protcol to the desired protocol list.
Definition: epcdns.h:1312
static EString sgsn_fqdn(const char *nri, const char *rac, const char *lac, const char *mnc, const char *mcc)
Constructs the serving GPRS support node (SGSN) FQDN.
Definition: epcdns.cpp:171
MMENodeSelector(const char *mmec, const char *mmegi, const char *mnc, const char *mcc)
Class constructor.
Definition: epcdns.h:1460