diff --git a/CHANGES b/CHANGES index 6b06454f4ad707dd2d73386a21551b315fe9e53b..9a2244806d9863063270d1cf949d4377b78f06dc 100644 --- a/CHANGES +++ b/CHANGES @@ -30,6 +30,11 @@ SIP Changes ----------- * The ATTENDED_TRANSFER_COMPLETE_SOUND can now be set using setvar to cause a given audio file to be played upon completion of an attended transfer. + * Added DNS manager support to registrations for peers referencing peer entries. + +IAX Changes +----------- + * Existing DNS manager lookups extended to check for SRV records. CLI Changes ----------- @@ -37,6 +42,11 @@ CLI Changes references that particular configuration file. Also added "config list" which shows which configuration files are in use. +DNS manager changes +------------------- + * Addresses managed by DNS manager now can check to see if there is a DNS + SRV record for a given domain and will use that hostname/port if present. + ------------------------------------------------------------------------------ --- Functionality changes from Asterisk 1.4.X to Asterisk 1.6.0 ------------- ------------------------------------------------------------------------------ @@ -194,8 +204,7 @@ SIP changes configs/sip.conf.sample for more information on how it is used. * Added a new configuration option "authfailureevents" that enables manager events when a peer can't authenticate properly. - * Added DNS manager support to registrations, both for peers referencing - and not referencing a peer entry. + * Added DNS manager support to registrations for peers not referencing a peer entry. IAX2 changes ------------ @@ -536,11 +545,6 @@ Call Detail Records * The ResetCDR application now has an 'e' option that re-enables a CDR if it has been disabled using the NoCDR application. -DNS manager changes -------------------- - * Addresses managed by DNS manager now will check to see if there is a DNS - SRV record for a given domain and will use that hostname/port if present. - Miscellaneous New Modules ------------------------- * Added a new CDR module, cdr_sqlite3_custom. diff --git a/channels/chan_iax2.c b/channels/chan_iax2.c index 0ab1f3bd3e0d6d8275fa535785d043fc2a33d984..ce89db72f9875579ebea74d821cb4bb55784fa47 100644 --- a/channels/chan_iax2.c +++ b/channels/chan_iax2.c @@ -6427,7 +6427,7 @@ static int iax2_append_register(const char *hostname, const char *username, if (!(reg = ast_calloc(1, sizeof(*reg)))) return -1; - if (ast_dnsmgr_lookup(hostname, ®->addr, ®->dnsmgr, NULL) < 0) { + if (ast_dnsmgr_lookup(hostname, ®->addr, ®->dnsmgr, srvlookup ? "_iax._udp" : NULL) < 0) { ast_free(reg); return -1; } @@ -10095,7 +10095,7 @@ static struct iax2_peer *build_peer(const char *name, struct ast_variable *v, st /* Non-dynamic. Make sure we become that way if we're not */ AST_SCHED_DEL(sched, peer->expire); ast_clear_flag(peer, IAX_DYNAMIC); - if (ast_dnsmgr_lookup(v->value, &peer->addr, &peer->dnsmgr, NULL)) + if (ast_dnsmgr_lookup(v->value, &peer->addr, &peer->dnsmgr, srvlookup ? "_iax._udp" : NULL)); return peer_unref(peer); if (!peer->addr.sin_port) peer->addr.sin_port = htons(IAX_DEFAULT_PORTNO);