Commit f0e57c23 authored by Mark Andrews's avatar Mark Andrews
Browse files

1552. [bug] Accept NOTIFY requests from mapped masters if

                        matched-mapped is set. [RT #10049]
parent 7ad4d54f
......@@ -93,7 +93,8 @@
1553. [bug] The windows socket code could stop accepting
connections. [RT#10115]
1552. [placeholder] rt10049
1552. [bug] Accept NOTIFY requests from mapped masters if
matched-mapped is set. [RT #10049]
1551. [port] Open "/dev/null" before calling chroot().
......
......@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: zone.c,v 1.405 2004/02/27 20:41:45 marka Exp $ */
/* $Id: zone.c,v 1.406 2004/03/02 01:19:51 marka Exp $ */
#include <config.h>
......@@ -4601,15 +4601,25 @@ dns_zone_notifyreceive(dns_zone_t *zone, isc_sockaddr_t *from,
return (ISC_R_SUCCESS);
}
for (i = 0; i < zone->masterscnt; i++)
isc_netaddr_fromsockaddr(&netaddr, from);
for (i = 0; i < zone->masterscnt; i++) {
if (isc_sockaddr_eqaddr(from, &zone->masters[i]))
break;
if (zone->view->aclenv.match_mapped &&
IN6_IS_ADDR_V4MAPPED(&from->type.sin6.sin6_addr) &&
isc_sockaddr_pf(&zone->masters[i]) == AF_INET) {
isc_netaddr_t na1, na2;
isc_netaddr_fromv4mapped(&na1, &netaddr);
isc_netaddr_fromsockaddr(&na2, &zone->masters[i]);
if (isc_netaddr_equal(&na1, &na2))
break;
}
}
/*
* Accept notify requests from non masters if they are on
* 'zone->notify_acl'.
*/
isc_netaddr_fromsockaddr(&netaddr, from);
if (i >= zone->masterscnt && zone->notify_acl != NULL &&
dns_acl_match(&netaddr, NULL, zone->notify_acl,
&zone->view->aclenv,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment