Ignore:
Timestamp:
Oct 8, 2006 12:39:34 PM (18 years ago)
Author:
bennylp
Message:

Major addition to support DNS SRV resolution in PJSIP:

  • added DNS asynchronous/caching resolver engine in PJLIB-UTIL (resolver.[hc])
  • modified SIP resolver (sip_resolve.c) to properly perform DNS SRV/A resolution when DNS resolution is enabled.
  • added dns_test.c in PJSIP-TEST for testing the SIP resolver.
  • added nameserver configuration in PJSUA-LIB
  • added "--nameserver" option in PJSUA.
  • updated project/Makefiles and doxygen documentation.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/include/pjsip/sip_endpoint.h

    r736 r753  
    276276 
    277277/** 
     278 * Create the DNS resolver instance. Application creates the DNS 
     279 * resolver instance, set the nameserver to be used by the DNS 
     280 * resolver, then set the DNS resolver to be used by the endpoint 
     281 * by calling #pjsip_endpt_set_resolver(). 
     282 * 
     283 * @param endpt         The SIP endpoint instance. 
     284 * @param p_resv        Pointer to receive the DNS resolver instance. 
     285 * 
     286 * @return              PJ_SUCCESS on success, or the appropriate error 
     287 *                      code. 
     288 */ 
     289PJ_DECL(pj_status_t) pjsip_endpt_create_resolver(pjsip_endpoint *endpt, 
     290                                                 pj_dns_resolver **p_resv); 
     291 
     292/** 
     293 * Set DNS resolver to be used by the SIP resolver. Application can set 
     294 * the resolver instance to NULL to disable DNS resolution (perhaps 
     295 * temporarily). When DNS resolver is disabled, the endpoint will resolve 
     296 * hostnames with the normal pj_gethostbyname() function. 
     297 * 
     298 * @param endpt         The SIP endpoint instance. 
     299 * @param resv          The resolver instance to be used by the SIP 
     300 *                      endpoint. 
     301 * 
     302 * @return              PJ_SUCCESS on success, or the appropriate error 
     303 *                      code. 
     304 */ 
     305PJ_DECL(pj_status_t) pjsip_endpt_set_resolver(pjsip_endpoint *endpt, 
     306                                              pj_dns_resolver *resv); 
     307 
     308/** 
     309 * Get the DNS resolver being used by the SIP resolver. 
     310 * 
     311 * @param endpt         The SIP endpoint instance. 
     312 * 
     313 * @return              The DNS resolver instance currently being used 
     314 *                      by the SIP endpoint. 
     315 */ 
     316PJ_DECL(pj_dns_resolver*) pjsip_endpt_get_resolver(pjsip_endpoint *endpt); 
     317 
     318/** 
    278319 * Asynchronously resolve a SIP target host or domain according to rule  
    279320 * specified in RFC 3263 (Locating SIP Servers). When the resolving operation 
    280321 * has completed, the callback will be called. 
    281  * 
    282  * Note: at the moment we don't have implementation of RFC 3263 yet! 
    283322 * 
    284323 * @param endpt     The endpoint instance. 
Note: See TracChangeset for help on using the changeset viewer.