15 #ifndef _SipSrvLookup_h_ 16 #define _SipSrvLookup_h_ 21 #elif defined(_VXWORKS) 23 #elif defined(__pingtel_on_posix__) 26 # error Unsupported target platform. 30 #include "os/OsDefs.h" 31 #include "os/OsMutex.h" 32 #include "os/OsSocket.h" 63 OsSocket::IpProtocolSocketType socketType,
174 const char*& out_name,
217 static void setDnsSrvResolveEnabled(UtlBoolean& enabled);
220 OsSocket::IpProtocolSocketType
type;
222 struct sockaddr_in sin;
241 UtlBoolean isValidServerT();
245 void getHostNameFromServerT(UtlString& hostName);
248 void getIpAddressFromServerT(UtlString& hostName);
251 int getPortFromServerT();
254 unsigned int getWeightFromServerT();
257 float getScoreFromServerT();
260 unsigned int getPriorityFromServerT();
263 OsSocket::IpProtocolSocketType getProtocolFromServerT();
266 #endif // _SipSrvLookup_h_ Special value.
Definition: SipSrvLookup.h:103
If 1, do not search for NAPTR records.
Definition: SipSrvLookup.h:106
OptionCode
Option codes for server lookup.
Definition: SipSrvLookup.h:102
unsigned int priority
SRV priority value.
Definition: SipSrvLookup.h:223
float score
Calculated sorting score.
Definition: SipSrvLookup.h:225
unsigned int weight
SRV weight.
Definition: SipSrvLookup.h:224
If 1, print DNS answers.
Definition: SipSrvLookup.h:109
A class (with no members) whose 'servers' method implements the RFC 3263 process for determining a li...
Definition: SipSrvLookup.h:53
Start of range.
Definition: SipSrvLookup.h:104
End of range.
Definition: SipSrvLookup.h:114
If 1, sort DNS answers before using them.
Definition: SipSrvLookup.h:107
If 1, do not search for SRV records.
Definition: SipSrvLookup.h:105
static int getOption(OptionCode option)
Get an option value.
Definition: SipSrvLookup.h:134
static int options[OptionCodeLast+1]
The array of option values.
Definition: SipSrvLookup.h:203
Max. number of CNAMEs to follow.
Definition: SipSrvLookup.h:111
static server_t * servers(const char *domain, const char *service, OsSocket::IpProtocolSocketType socketType, int port, const char *srcIp)
Get the list of server entries for SIP domain name 'domain'.
Definition: SipSrvLookup.cpp:245
char * host
Host name. (Owned by this object.)
Definition: SipSrvLookup.h:219
Structure to describe a server found for a SIP domain.
Definition: SipSrvLookup.h:213
OsSocket::IpProtocolSocketType type
OsSocket:{TCP,UDP,SSL_SOCKET}.
Definition: SipSrvLookup.h:220
static OsMutex sMutex
Mutex to keep the routines thread-safe.
Definition: SipSrvLookup.h:200
static UtlBoolean mDnsSrvResolveEnabled
Definition: SipSrvLookup.h:229
static void res_query_and_parse(const char *in_name, int type, res_response *in_response, const char *&out_name, res_response *&out_response)
Perform a DNS query and parse the results. Follows CNAME records.
Definition: SipSrvLookup.cpp:764
If 1, do not add TCP contacts by default, for better RFC 3263 conformance.
Definition: SipSrvLookup.h:112
static void setDnsSrvTimeouts(int initialTimeoutInSecs, int retries)
setOption can be called at any time from any thread without causing harm to any requests that may be ...
Definition: SipSrvLookup.cpp:416
static void getDnsSrvTimeouts(int &initialTimeoutInSecs, int &retries)
Gets the timing paramters for DSN SRV queries.
Definition: SipSrvLookup.cpp:445
static void setOption(OptionCode option, int value)
Set an option value.
Definition: SipSrvLookup.cpp:407