mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-16 14:58:25 +00:00
res_pjsip: Add external PJSIP resolver implementation using core DNS API.
This change adds the following: 1. A query set implementation. This is an API that allows queries to be executed in parallel and once all have completed a callback is invoked. 2. Unit tests for the query set implementation. 3. An external PJSIP resolver which uses the DNS core API to do NAPTR, SRV, AAAA, and A lookups. For the resolver it will do NAPTR, SRV, and AAAA/A lookups in parallel. If NAPTR or SRV are available it will then do more queries. And so on. Preference is NAPTR > SRV > AAAA/A, with IPv6 preferred over IPv4. For transport it will prefer TLS > TCP > UDP if no explicit transport has been provided. Configured transports on the system are taken into account to eliminate resolved addresses which have no hope of completing. ASTERISK-24947 #close Reported by: Joshua Colp Change-Id: I56cb03ce4f9d3d600776f36928e0b3e379b5d71e
This commit is contained in:
@@ -204,6 +204,15 @@ int ast_dns_record_get_ttl(const struct ast_dns_record *record);
|
||||
*/
|
||||
const char *ast_dns_record_get_data(const struct ast_dns_record *record);
|
||||
|
||||
/*!
|
||||
* \brief Retrieve the size of the raw DNS record
|
||||
*
|
||||
* \param record The DNS record
|
||||
*
|
||||
* \return the size of the raw DNS record
|
||||
*/
|
||||
size_t ast_dns_record_get_data_size(const struct ast_dns_record *record);
|
||||
|
||||
/*!
|
||||
* \brief Get the next DNS record
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user