#include <config.h>
#include <isc/interfaceiter.h>
#include <isc/os.h>
#include <isc/string.h>
#include <isc/task.h>
#include <isc/util.h>
#include <dns/acl.h>
#include <dns/dispatch.h>
#include <named/client.h>
#include <named/log.h>
#include <named/interfacemgr.h>
#include <named/server.h>
Go to the source code of this file.
Data Structures | |
struct | ns_interfacemgr |
nameserver interface manager structure More... | |
Defines | |
#define | UDPBUFFERS 1000 |
#define | IFMGR_MAGIC ISC_MAGIC('I', 'F', 'M', 'G') |
#define | NS_INTERFACEMGR_VALID(t) ISC_MAGIC_VALID(t, IFMGR_MAGIC) |
#define | IFMGR_COMMON_LOGARGS ns_g_lctx, NS_LOGCATEGORY_NETWORK, NS_LOGMODULE_INTERFACEMGR |
Functions | |
static void | purge_old_interfaces (ns_interfacemgr_t *mgr) |
Remove any interfaces whose generation number is not the current one. | |
static void | clearlistenon (ns_interfacemgr_t *mgr) |
isc_result_t | ns_interfacemgr_create (isc_mem_t *mctx, isc_taskmgr_t *taskmgr, isc_socketmgr_t *socketmgr, dns_dispatchmgr_t *dispatchmgr, isc_task_t *task, ns_interfacemgr_t **mgrp) |
static void | ns_interfacemgr_destroy (ns_interfacemgr_t *mgr) |
dns_aclenv_t * | ns_interfacemgr_getaclenv (ns_interfacemgr_t *mgr) |
Set the IPv6 "listen-on" list of 'mgr' to 'value'. The previous IPv6 listen-on list is freed. | |
void | ns_interfacemgr_attach (ns_interfacemgr_t *source, ns_interfacemgr_t **target) |
Create a new interface manager. | |
void | ns_interfacemgr_detach (ns_interfacemgr_t **targetp) |
void | ns_interfacemgr_shutdown (ns_interfacemgr_t *mgr) |
static isc_result_t | ns_interface_create (ns_interfacemgr_t *mgr, isc_sockaddr_t *addr, const char *name, ns_interface_t **ifpret) |
static isc_result_t | ns_interface_listenudp (ns_interface_t *ifp) |
static isc_result_t | ns_interface_accepttcp (ns_interface_t *ifp) |
static isc_result_t | ns_interface_setup (ns_interfacemgr_t *mgr, isc_sockaddr_t *addr, const char *name, ns_interface_t **ifpret, isc_boolean_t accept_tcp, isc_dscp_t dscp, isc_boolean_t *addr_in_use) |
void | ns_interface_shutdown (ns_interface_t *ifp) |
static void | ns_interface_destroy (ns_interface_t *ifp) |
void | ns_interface_attach (ns_interface_t *source, ns_interface_t **target) |
void | ns_interface_detach (ns_interface_t **targetp) |
static ns_interface_t * | find_matching_interface (ns_interfacemgr_t *mgr, isc_sockaddr_t *addr) |
Search the interface list for an interface whose address and port both match those of 'addr'. Return a pointer to it, or NULL if not found. | |
static isc_result_t | clearacl (isc_mem_t *mctx, dns_acl_t **aclp) |
static isc_boolean_t | listenon_is_ip6_any (ns_listenelt_t *elt) |
static isc_result_t | setup_locals (ns_interfacemgr_t *mgr, isc_interface_t *interface) |
static void | setup_listenon (ns_interfacemgr_t *mgr, isc_interface_t *interface, in_port_t port) |
static isc_result_t | do_scan (ns_interfacemgr_t *mgr, ns_listenlist_t *ext_listen, isc_boolean_t verbose) |
static isc_result_t | ns_interfacemgr_scan0 (ns_interfacemgr_t *mgr, ns_listenlist_t *ext_listen, isc_boolean_t verbose) |
isc_boolean_t | ns_interfacemgr_islistening (ns_interfacemgr_t *mgr) |
isc_result_t | ns_interfacemgr_scan (ns_interfacemgr_t *mgr, isc_boolean_t verbose) |
Return if the manager is listening on any interface. It can be called after a scan or adjust. | |
isc_result_t | ns_interfacemgr_adjust (ns_interfacemgr_t *mgr, ns_listenlist_t *list, isc_boolean_t verbose) |
Scan the operatings system's list of network interfaces and create listeners when new interfaces are discovered. Shut down the sockets for interfaces that go away. | |
void | ns_interfacemgr_setlistenon4 (ns_interfacemgr_t *mgr, ns_listenlist_t *value) |
Similar to ns_interfacemgr_scan(), but this function also tries to see the need for an explicit listen-on when a list element in 'list' is going to override an already-listening a wildcard interface. | |
void | ns_interfacemgr_setlistenon6 (ns_interfacemgr_t *mgr, ns_listenlist_t *value) |
Set the IPv4 "listen-on" list of 'mgr' to 'value'. The previous IPv4 listen-on list is freed. | |
void | ns_interfacemgr_dumprecursing (FILE *f, ns_interfacemgr_t *mgr) |
Stop listening for queries on interface 'ifp'. May safely be called multiple times. | |
isc_boolean_t | ns_interfacemgr_listeningon (ns_interfacemgr_t *mgr, isc_sockaddr_t *addr) |
Definition in file interfacemgr.c.
#define UDPBUFFERS 1000 |
Definition at line 62 of file interfacemgr.c.
Referenced by get_view_querysource_dispatch(), ns_add_reserved_dispatch(), and ns_interface_listenudp().
#define IFMGR_MAGIC ISC_MAGIC('I', 'F', 'M', 'G') |
#define NS_INTERFACEMGR_VALID | ( | t | ) | ISC_MAGIC_VALID(t, IFMGR_MAGIC) |
Definition at line 66 of file interfacemgr.c.
Referenced by ns_interface_create(), ns_interfacemgr_attach(), ns_interfacemgr_destroy(), ns_interfacemgr_detach(), ns_interfacemgr_islistening(), ns_interfacemgr_scan0(), and ns_interfacemgr_shutdown().
#define IFMGR_COMMON_LOGARGS ns_g_lctx, NS_LOGCATEGORY_NETWORK, NS_LOGMODULE_INTERFACEMGR |
Definition at line 68 of file interfacemgr.c.
Referenced by do_scan(), ns_interface_accepttcp(), ns_interface_create(), ns_interface_listenudp(), ns_interfacemgr_scan0(), purge_old_interfaces(), and setup_locals().
static void purge_old_interfaces | ( | ns_interfacemgr_t * | mgr | ) | [static] |
Remove any interfaces whose generation number is not the current one.
Definition at line 679 of file interfacemgr.c.
References ns_interface::addr, ns_interfacemgr::generation, ns_interface::generation, IFMGR_COMMON_LOGARGS, INSIST, ISC_LIST_HEAD, ISC_LIST_NEXT, ISC_LIST_UNLINK, ISC_LOG_INFO, isc_log_write(), isc_sockaddr_format(), ns_interface::mgr, ns_interface_detach(), ns_interface_shutdown(), and NS_INTERFACE_VALID.
Referenced by ns_interfacemgr_scan0(), and ns_interfacemgr_shutdown().
static void clearlistenon | ( | ns_interfacemgr_t * | mgr | ) | [static] |
Definition at line 790 of file interfacemgr.c.
References ISC_LIST_HEAD, ISC_LIST_UNLINK, isc_mem_put, and ns_interfacemgr::mctx.
Referenced by do_scan(), and ns_interfacemgr_destroy().
isc_result_t ns_interfacemgr_create | ( | isc_mem_t * | mctx, | |
isc_taskmgr_t * | taskmgr, | |||
isc_socketmgr_t * | socketmgr, | |||
dns_dispatchmgr_t * | dispatchmgr, | |||
isc_task_t * | task, | |||
ns_interfacemgr_t ** | mgrp | |||
) |
Definition at line 172 of file interfacemgr.c.
References ns_interfacemgr::aclenv, ns_interfacemgr::dispatchmgr, dns_aclenv_destroy(), dns_aclenv_init(), ns_interfacemgr::generation, IFMGR_MAGIC, ISC_LIST_INIT, isc_mem_attach(), isc_mem_get, isc_mem_putanddetach, isc_mutex_init, ISC_R_FAMILYNOSUPPORT, ISC_R_NOMEMORY, ISC_R_NOPERM, ISC_R_NOTIMPLEMENTED, ISC_R_SUCCESS, isc_socket_create(), isc_socket_detach(), isc_socket_recv(), isc_sockettype_raw, isc_task_attach(), isc_task_detach(), ns_interfacemgr::listenon4, ns_interfacemgr::listenon6, ns_interfacemgr::lock, ns_interfacemgr::magic, ns_interfacemgr::mctx, ns_interfacemgr_detach(), ns_listenlist_attach(), ns_listenlist_create(), ns_listenlist_detach(), ns_interfacemgr::references, REQUIRE, ns_interfacemgr::socketmgr, ns_interfacemgr::taskmgr, and UNUSED.
Referenced by run_server().
static void ns_interfacemgr_destroy | ( | ns_interfacemgr_t * | mgr | ) | [static] |
Definition at line 276 of file interfacemgr.c.
References ns_interfacemgr::aclenv, clearlistenon(), DESTROYLOCK, dns_aclenv_destroy(), isc_mem_putanddetach, isc_socket_detach(), isc_task_detach(), ns_interfacemgr::listenon4, ns_interfacemgr::listenon6, ns_interfacemgr::lock, ns_interfacemgr::magic, ns_interfacemgr::mctx, NS_INTERFACEMGR_VALID, ns_listenlist_detach(), and REQUIRE.
Referenced by ns_interfacemgr_detach().
dns_aclenv_t* ns_interfacemgr_getaclenv | ( | ns_interfacemgr_t * | mgr | ) |
Set the IPv6 "listen-on" list of 'mgr' to 'value'. The previous IPv6 listen-on list is freed.
Definition at line 295 of file interfacemgr.c.
References ns_interfacemgr::aclenv.
Referenced by scan_interfaces().
void ns_interfacemgr_attach | ( | ns_interfacemgr_t * | source, | |
ns_interfacemgr_t ** | target | |||
) |
Create a new interface manager.
Initially, the new manager will not listen on any interfaces. Call ns_interfacemgr_setlistenon() and/or ns_interfacemgr_setlistenon6() to set nonempty listen-on lists.
Definition at line 300 of file interfacemgr.c.
References INSIST, ns_interfacemgr::lock, LOCK, NS_INTERFACEMGR_VALID, ns_interfacemgr::references, REQUIRE, and UNLOCK.
Referenced by ns_interface_create().
void ns_interfacemgr_detach | ( | ns_interfacemgr_t ** | targetp | ) |
Definition at line 310 of file interfacemgr.c.
References ISC_FALSE, ISC_TRUE, ns_interfacemgr::lock, LOCK, ns_interfacemgr_destroy(), NS_INTERFACEMGR_VALID, ns_interfacemgr::references, REQUIRE, and UNLOCK.
Referenced by ns_interface_destroy(), ns_interfacemgr_create(), and shutdown_server().
void ns_interfacemgr_shutdown | ( | ns_interfacemgr_t * | mgr | ) |
Shut down and detach all interfaces. By incrementing the generation count, we make purge_old_interfaces() consider all interfaces "old".
Definition at line 327 of file interfacemgr.c.
References ns_interfacemgr::generation, ISC_SOCKCANCEL_RECV, isc_socket_cancel(), isc_socket_detach(), isc_task_detach(), ns_interfacemgr::lock, LOCK, NS_INTERFACEMGR_VALID, purge_old_interfaces(), REQUIRE, and UNLOCK.
Referenced by shutdown_server().
static isc_result_t ns_interface_create | ( | ns_interfacemgr_t * | mgr, | |
isc_sockaddr_t * | addr, | |||
const char * | name, | |||
ns_interface_t ** | ifpret | |||
) | [static] |
Definition at line 350 of file interfacemgr.c.
References ns_interface::addr, ns_interface::clientmgr, DESTROYLOCK, ns_interface::dscp, ns_interface::flags, ns_interfacemgr::generation, ns_interface::generation, IFACE_MAGIC, IFMGR_COMMON_LOGARGS, ISC_LINK_INIT, ISC_LIST_APPEND, ISC_LOG_ERROR, isc_log_write(), isc_mem_get, isc_mem_put, isc_mutex_init, ISC_R_NOMEMORY, ISC_R_SUCCESS, ISC_R_UNEXPECTED, isc_result_totext(), ns_interface::lock, ns_interface::magic, MAX_UDP_DISPATCH, ns_interfacemgr::mctx, ns_interface::mgr, ns_interface::name, ns_clientmgr_create(), ns_interfacemgr_attach(), NS_INTERFACEMGR_VALID, ns_interface::ntcpcurrent, ns_interface::ntcptarget, ns_interface::nudpdispatch, ns_interface::references, REQUIRE, ns_interfacemgr::taskmgr, ns_interface::tcpsocket, and ns_interface::udpdispatch.
Referenced by ns_interface_setup().
static isc_result_t ns_interface_listenudp | ( | ns_interface_t * | ifp | ) | [static] |
Definition at line 424 of file interfacemgr.c.
References ns_interface::addr, ns_interface::clientmgr, ns_interfacemgr::dispatchmgr, dns_dispatch_changeattributes(), dns_dispatch_detach(), dns_dispatch_getudp_dup(), DNS_DISPATCHATTR_IPV4, DNS_DISPATCHATTR_IPV6, DNS_DISPATCHATTR_NOLISTEN, DNS_DISPATCHATTR_TCP, DNS_DISPATCHATTR_UDP, IFMGR_COMMON_LOGARGS, ISC_FALSE, ISC_LOG_ERROR, isc_log_write(), ISC_MIN, ISC_R_SUCCESS, isc_result_totext(), isc_sockaddr_pf(), MAX_UDP_DISPATCH, ns_interface::mgr, ns_clientmgr_createclients(), ns_interface::nudpdispatch, UDPBUFFERS, ns_interface::udpdispatch, and UNEXPECTED_ERROR.
Referenced by ns_interface_setup().
static isc_result_t ns_interface_accepttcp | ( | ns_interface_t * | ifp | ) | [static] |
Definition at line 486 of file interfacemgr.c.
References ns_interface::addr, ns_interface::clientmgr, ns_interface::dscp, IFMGR_COMMON_LOGARGS, ISC_LOG_ERROR, isc_log_write(), ISC_R_SUCCESS, isc_result_totext(), isc_sockaddr_pf(), isc_socket_bind(), isc_socket_create(), isc_socket_detach(), isc_socket_dscp(), isc_socket_filter(), isc_socket_ipv6only(), isc_socket_listen(), ISC_SOCKET_REUSEADDRESS, isc_socket_setname(), isc_sockettype_tcp, ISC_TRUE, ns_interface::mgr, ns_clientmgr_createclients(), ns_interface::ntcptarget, ns_interfacemgr::socketmgr, ns_interface::tcpsocket, and UNEXPECTED_ERROR.
Referenced by ns_interface_setup().
static isc_result_t ns_interface_setup | ( | ns_interfacemgr_t * | mgr, | |
isc_sockaddr_t * | addr, | |||
const char * | name, | |||
ns_interface_t ** | ifpret, | |||
isc_boolean_t | accept_tcp, | |||
isc_dscp_t | dscp, | |||
isc_boolean_t * | addr_in_use | |||
) | [static] |
Definition at line 552 of file interfacemgr.c.
References ns_interface::dscp, ISC_FALSE, ISC_LIST_UNLINK, ISC_R_ADDRINUSE, ISC_R_SUCCESS, ISC_TRUE, ns_interface::mgr, ns_interface_accepttcp(), ns_interface_create(), ns_interface_detach(), ns_interface_listenudp(), and REQUIRE.
Referenced by do_scan().
void ns_interface_shutdown | ( | ns_interface_t * | ifp | ) |
Definition at line 601 of file interfacemgr.c.
References ns_interface::clientmgr, and ns_clientmgr_destroy().
Referenced by ns_interface_destroy(), and purge_old_interfaces().
static void ns_interface_destroy | ( | ns_interface_t * | ifp | ) | [static] |
Definition at line 607 of file interfacemgr.c.
References DESTROYLOCK, dns_dispatch_changeattributes(), dns_dispatch_detach(), DNS_DISPATCHATTR_NOLISTEN, isc_mem_put, isc_socket_detach(), ns_interface::lock, ns_interface::magic, ns_interfacemgr::mctx, ns_interface::mgr, ns_interface_shutdown(), NS_INTERFACE_VALID, ns_interfacemgr_detach(), ns_interface::nudpdispatch, REQUIRE, ns_interface::tcpsocket, and ns_interface::udpdispatch.
Referenced by ns_interface_detach().
void ns_interface_attach | ( | ns_interface_t * | source, | |
ns_interface_t ** | target | |||
) |
Definition at line 634 of file interfacemgr.c.
References INSIST, ns_interface::lock, LOCK, NS_INTERFACE_VALID, ns_interface::references, REQUIRE, and UNLOCK.
Referenced by get_client(), and get_worker().
void ns_interface_detach | ( | ns_interface_t ** | targetp | ) |
Definition at line 644 of file interfacemgr.c.
References ISC_FALSE, ISC_TRUE, ns_interface::lock, LOCK, ns_interface_destroy(), NS_INTERFACE_VALID, ns_interface::references, REQUIRE, and UNLOCK.
Referenced by exit_check(), ns_interface_setup(), and purge_old_interfaces().
static ns_interface_t* find_matching_interface | ( | ns_interfacemgr_t * | mgr, | |
isc_sockaddr_t * | addr | |||
) | [static] |
Search the interface list for an interface whose address and port both match those of 'addr'. Return a pointer to it, or NULL if not found.
Definition at line 665 of file interfacemgr.c.
References ns_interface::addr, ISC_LIST_HEAD, ISC_LIST_NEXT, and isc_sockaddr_equal().
Referenced by do_scan().
static isc_result_t clearacl | ( | isc_mem_t * | mctx, | |
dns_acl_t ** | aclp | |||
) | [static] |
Definition at line 698 of file interfacemgr.c.
References dns_acl_attach(), dns_acl_create(), dns_acl_detach(), and ISC_R_SUCCESS.
Referenced by do_scan().
static isc_boolean_t listenon_is_ip6_any | ( | ns_listenelt_t * | elt | ) | [static] |
Definition at line 711 of file interfacemgr.c.
References ns_listenelt::acl, dns_acl_isany(), and REQUIRE.
Referenced by do_scan().
static isc_result_t setup_locals | ( | ns_interfacemgr_t * | mgr, | |
isc_interface_t * | interface | |||
) | [static] |
Definition at line 717 of file interfacemgr.c.
References ns_interfacemgr::aclenv, isc_interface::address, AF_INET6, dns_iptable_addprefix(), isc_netaddr::family, IFMGR_COMMON_LOGARGS, dns_acl::iptable, ISC_LOG_WARNING, isc_log_write(), isc_netaddr_masktoprefixlen(), ISC_R_SUCCESS, isc_result_totext(), ISC_TRUE, dns_aclenv::localhost, dns_aclenv::localnets, isc_interface::name, and isc_interface::netmask.
Referenced by do_scan().
static void setup_listenon | ( | ns_interfacemgr_t * | mgr, | |
isc_interface_t * | interface, | |||
in_port_t | port | |||
) | [static] |
Definition at line 765 of file interfacemgr.c.
References isc_interface::address, ISC_LIST_APPEND, ISC_LIST_HEAD, ISC_LIST_NEXT, isc_mem_get, isc_mem_put, isc_sockaddr_equal(), isc_sockaddr_fromnetaddr(), and ns_interfacemgr::mctx.
Referenced by do_scan().
static isc_result_t do_scan | ( | ns_interfacemgr_t * | mgr, | |
ns_listenlist_t * | ext_listen, | |||
isc_boolean_t | verbose | |||
) | [static] |
Definition at line 802 of file interfacemgr.c.
References ns_listenelt::acl, ns_interfacemgr::aclenv, isc_interface::address, AF_INET6, clearacl(), clearlistenon(), dns_acl_match(), ns_interface::dscp, ns_listenelt::dscp, isc_netaddr::family, find_matching_interface(), ns_interface::flags, ns_interfacemgr::generation, ns_interface::generation, IFMGR_COMMON_LOGARGS, isc_netaddr::in, isc_netaddr::in6, in6addr_any, ISC_FALSE, isc_interfaceiter_create(), isc_interfaceiter_current(), isc_interfaceiter_destroy(), isc_interfaceiter_first(), isc_interfaceiter_next(), ISC_LIST_HEAD, ISC_LIST_NEXT, ISC_LOG_DEBUG, ISC_LOG_ERROR, ISC_LOG_INFO, ISC_LOG_WARNING, isc_log_write(), isc_net_probe_ipv6only(), isc_net_probe_ipv6pktinfo(), isc_net_probeipv4(), isc_net_probeipv6(), isc_netaddr_any(), isc_netaddr_any6(), isc_netaddr_equal(), isc_netaddr_fromin(), isc_netaddr_fromin6(), isc_netaddr_setzone(), ISC_R_ADDRINUSE, ISC_R_NOMORE, ISC_R_SUCCESS, isc_result_totext(), isc_sockaddr_format(), ISC_SOCKADDR_FORMATSIZE, isc_sockaddr_fromin6(), isc_sockaddr_fromnetaddr(), ISC_TRUE, ns_interfacemgr::listenon4, ns_interfacemgr::listenon6, listenon_is_ip6_any(), dns_aclenv::localhost, dns_aclenv::localnets, match(), ns_interfacemgr::mctx, isc_interface::name, ns_interface_setup(), NS_INTERFACEFLAG_ANYADDR, ns_listenelt::port, setup_listenon(), setup_locals(), isc_netaddr::type, UNEXPECTED_ERROR, and isc_netaddr::zone.
Referenced by ns_interfacemgr_scan0().
static isc_result_t ns_interfacemgr_scan0 | ( | ns_interfacemgr_t * | mgr, | |
ns_listenlist_t * | ext_listen, | |||
isc_boolean_t | verbose | |||
) | [static] |
Definition at line 1146 of file interfacemgr.c.
References do_scan(), ns_interfacemgr::generation, IFMGR_COMMON_LOGARGS, ISC_FALSE, ISC_LIST_EMPTY, ISC_LOG_WARNING, isc_log_write(), ISC_R_ADDRINUSE, ISC_R_SUCCESS, ISC_TRUE, NS_INTERFACEMGR_VALID, purge_old_interfaces(), and REQUIRE.
Referenced by ns_interfacemgr_adjust(), and ns_interfacemgr_scan().
isc_boolean_t ns_interfacemgr_islistening | ( | ns_interfacemgr_t * | mgr | ) |
Definition at line 1184 of file interfacemgr.c.
References ISC_FALSE, ISC_LIST_EMPTY, ISC_TRUE, NS_INTERFACEMGR_VALID, and REQUIRE.
isc_result_t ns_interfacemgr_scan | ( | ns_interfacemgr_t * | mgr, | |
isc_boolean_t | verbose | |||
) |
Return if the manager is listening on any interface. It can be called after a scan or adjust.
Definition at line 1191 of file interfacemgr.c.
References ns_interfacemgr_scan0().
Referenced by scan_interfaces().
isc_result_t ns_interfacemgr_adjust | ( | ns_interfacemgr_t * | mgr, | |
ns_listenlist_t * | list, | |||
isc_boolean_t | verbose | |||
) |
Scan the operatings system's list of network interfaces and create listeners when new interfaces are discovered. Shut down the sockets for interfaces that go away.
This should be called once on server startup and then periodically according to the 'interface-interval' option in named.conf.
Definition at line 1196 of file interfacemgr.c.
References ns_interfacemgr_scan0().
Referenced by adjust_interfaces().
void ns_interfacemgr_setlistenon4 | ( | ns_interfacemgr_t * | mgr, | |
ns_listenlist_t * | value | |||
) |
Similar to ns_interfacemgr_scan(), but this function also tries to see the need for an explicit listen-on when a list element in 'list' is going to override an already-listening a wildcard interface.
This function does not update localhost and localnets ACLs.
This should be called once on server startup, after configuring views and zones.
Definition at line 1203 of file interfacemgr.c.
References ns_interfacemgr::listenon4, ns_interfacemgr::lock, LOCK, ns_listenlist_attach(), ns_listenlist_detach(), and UNLOCK.
Referenced by load_configuration().
void ns_interfacemgr_setlistenon6 | ( | ns_interfacemgr_t * | mgr, | |
ns_listenlist_t * | value | |||
) |
Set the IPv4 "listen-on" list of 'mgr' to 'value'. The previous IPv4 listen-on list is freed.
Definition at line 1211 of file interfacemgr.c.
References ns_interfacemgr::listenon6, ns_interfacemgr::lock, LOCK, ns_listenlist_attach(), ns_listenlist_detach(), and UNLOCK.
Referenced by load_configuration().
void ns_interfacemgr_dumprecursing | ( | FILE * | f, | |
ns_interfacemgr_t * | mgr | |||
) |
Stop listening for queries on interface 'ifp'. May safely be called multiple times.
Definition at line 1219 of file interfacemgr.c.
References ns_interface::clientmgr, ISC_LIST_HEAD, ISC_LIST_NEXT, ns_interfacemgr::lock, LOCK, ns_client_dumprecursing(), and UNLOCK.
Referenced by ns_server_dumprecursing().
isc_boolean_t ns_interfacemgr_listeningon | ( | ns_interfacemgr_t * | mgr, | |
isc_sockaddr_t * | addr | |||
) |
Definition at line 1233 of file interfacemgr.c.
References ISC_FALSE, ISC_LIST_HEAD, ISC_LIST_NEXT, isc_sockaddr_equal(), and ISC_TRUE.
Referenced by ns_client_isself().