diff -up bind-9.3.6-P1/bin/named/controlconf.c.acl-to-isccfg bind-9.3.6-P1/bin/named/controlconf.c --- bind-9.3.6-P1/bin/named/controlconf.c.acl-to-isccfg 2008-07-24 01:36:22.000000000 +0200 +++ bind-9.3.6-P1/bin/named/controlconf.c 2009-04-24 14:58:16.134901764 +0200 @@ -909,7 +909,7 @@ get_key_info(const cfg_obj_t *config, co static void update_listener(ns_controls_t *cp, controllistener_t **listenerp, const cfg_obj_t *control, const cfg_obj_t *config, - isc_sockaddr_t *addr, ns_aclconfctx_t *aclconfctx, + isc_sockaddr_t *addr, cfg_aclconfctx_t *aclconfctx, const char *socktext) { controllistener_t *listener; @@ -997,7 +997,7 @@ update_listener(ns_controls_t *cp, contr */ if (control != NULL) { allow = cfg_tuple_get(control, "allow"); - result = ns_acl_fromconfig(allow, config, aclconfctx, + result = cfg_acl_fromconfig(allow, config, aclconfctx, listener->mctx, &new_acl); } else { result = dns_acl_any(listener->mctx, &new_acl); @@ -1026,7 +1026,7 @@ update_listener(ns_controls_t *cp, contr static void add_listener(ns_controls_t *cp, controllistener_t **listenerp, const cfg_obj_t *control, const cfg_obj_t *config, - isc_sockaddr_t *addr, ns_aclconfctx_t *aclconfctx, + isc_sockaddr_t *addr, cfg_aclconfctx_t *aclconfctx, const char *socktext) { isc_mem_t *mctx = cp->server->mctx; @@ -1059,7 +1059,7 @@ add_listener(ns_controls_t *cp, controll */ if (control != NULL) { allow = cfg_tuple_get(control, "allow"); - result = ns_acl_fromconfig(allow, config, aclconfctx, + result = cfg_acl_fromconfig(allow, config, aclconfctx, mctx, &new_acl); } else { result = dns_acl_any(mctx, &new_acl); @@ -1145,7 +1145,7 @@ add_listener(ns_controls_t *cp, controll isc_result_t ns_controls_configure(ns_controls_t *cp, const cfg_obj_t *config, - ns_aclconfctx_t *aclconfctx) + cfg_aclconfctx_t *aclconfctx) { controllistener_t *listener; controllistenerlist_t new_listeners; diff -up bind-9.3.6-P1/bin/named/include/named/control.h.acl-to-isccfg bind-9.3.6-P1/bin/named/include/named/control.h --- bind-9.3.6-P1/bin/named/include/named/control.h.acl-to-isccfg 2009-04-24 14:56:18.806901712 +0200 +++ bind-9.3.6-P1/bin/named/include/named/control.h 2009-04-24 14:57:38.886901713 +0200 @@ -26,7 +26,8 @@ #include <isccc/types.h> -#include <named/aclconf.h> +#include <isccfg/aclconf.h> + #include <named/types.h> #define NS_CONTROL_PORT 953 @@ -68,7 +69,7 @@ ns_controls_destroy(ns_controls_t **ctrl isc_result_t ns_controls_configure(ns_controls_t *controls, const cfg_obj_t *config, - ns_aclconfctx_t *aclconfctx); + cfg_aclconfctx_t *aclconfctx); /* * Configure zero or more command channels into 'controls' * as defined in the configuration parse tree 'config'. diff -up bind-9.3.6-P1/bin/named/include/named/zoneconf.h.acl-to-isccfg bind-9.3.6-P1/bin/named/include/named/zoneconf.h --- bind-9.3.6-P1/bin/named/include/named/zoneconf.h.acl-to-isccfg 2009-04-24 14:58:49.462901982 +0200 +++ bind-9.3.6-P1/bin/named/include/named/zoneconf.h 2009-04-24 14:59:08.406901495 +0200 @@ -23,15 +23,14 @@ #include <isc/lang.h> #include <isc/types.h> +#include <isccfg/aclconf.h> #include <isccfg/cfg.h> -#include <named/aclconf.h> - ISC_LANG_BEGINDECLS isc_result_t ns_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig, - const cfg_obj_t *zconfig, ns_aclconfctx_t *ac, + const cfg_obj_t *zconfig, cfg_aclconfctx_t *ac, dns_zone_t *zone); /* * Configure or reconfigure a zone according to the named.conf diff -up bind-9.3.6-P1/bin/named/Makefile.in.acl-to-isccfg bind-9.3.6-P1/bin/named/Makefile.in --- bind-9.3.6-P1/bin/named/Makefile.in.acl-to-isccfg 2009-04-24 14:55:10.938901720 +0200 +++ bind-9.3.6-P1/bin/named/Makefile.in 2009-04-24 14:55:11.002902963 +0200 @@ -63,7 +63,7 @@ SUBDIRS = unix TARGETS = named@EXEEXT@ lwresd@EXEEXT@ -OBJS = aclconf.o builtin.o client.o config.o control.o \ +OBJS = builtin.o client.o config.o control.o \ controlconf.o interfacemgr.o \ listenlist.o log.o logconf.o main.o notify.o \ query.o server.o sortlist.o \ @@ -75,7 +75,7 @@ OBJS = aclconf.o builtin.o client.o con UOBJS = unix/os.o -SRCS = aclconf.c builtin.c client.c config.c control.c \ +SRCS = builtin.c client.c config.c control.c \ controlconf.c interfacemgr.c \ listenlist.c log.c logconf.c main.c notify.c \ query.c server.c sortlist.c \ diff -up bind-9.3.6-P1/bin/named/server.c.acl-to-isccfg bind-9.3.6-P1/bin/named/server.c --- bind-9.3.6-P1/bin/named/server.c.acl-to-isccfg 2009-04-24 14:55:10.990902124 +0200 +++ bind-9.3.6-P1/bin/named/server.c 2009-04-24 14:55:11.006901745 +0200 @@ -172,11 +172,11 @@ ns_server_reload(isc_task_t *task, isc_e static isc_result_t ns_listenelt_fromconfig(const cfg_obj_t *listener, const cfg_obj_t *config, - ns_aclconfctx_t *actx, + cfg_aclconfctx_t *actx, isc_mem_t *mctx, ns_listenelt_t **target); static isc_result_t ns_listenlist_fromconfig(const cfg_obj_t *listenlist, const cfg_obj_t *config, - ns_aclconfctx_t *actx, + cfg_aclconfctx_t *actx, isc_mem_t *mctx, ns_listenlist_t **target); static isc_result_t @@ -190,7 +190,7 @@ configure_alternates(const cfg_obj_t *co static isc_result_t configure_zone(const cfg_obj_t *config, const cfg_obj_t *zconfig, const cfg_obj_t *vconfig, isc_mem_t *mctx, dns_view_t *view, - ns_aclconfctx_t *aclconf); + cfg_aclconfctx_t *aclconf); static void end_reserved_dispatches(ns_server_t *server, isc_boolean_t all); @@ -202,7 +202,7 @@ end_reserved_dispatches(ns_server_t *ser */ static isc_result_t configure_view_acl(const cfg_obj_t *vconfig, const cfg_obj_t *config, - const char *aclname, ns_aclconfctx_t *actx, + const char *aclname, cfg_aclconfctx_t *actx, isc_mem_t *mctx, dns_acl_t **aclp) { isc_result_t result; @@ -229,7 +229,7 @@ configure_view_acl(const cfg_obj_t *vcon */ return (ISC_R_SUCCESS); - result = ns_acl_fromconfig(aclobj, config, actx, mctx, aclp); + result = cfg_acl_fromconfig(aclobj, config, actx, mctx, aclp); return (result); } @@ -810,7 +810,7 @@ disable_algorithms(const cfg_obj_t *disa */ static isc_result_t configure_view(dns_view_t *view, const cfg_obj_t *config, - const cfg_obj_t *vconfig, isc_mem_t *mctx, ns_aclconfctx_t *actx, + const cfg_obj_t *vconfig, isc_mem_t *mctx, cfg_aclconfctx_t *actx, isc_boolean_t need_hints) { const cfg_obj_t *maps[4]; @@ -1697,7 +1697,7 @@ create_view(const cfg_obj_t *vconfig, dn static isc_result_t configure_zone(const cfg_obj_t *config, const cfg_obj_t *zconfig, const cfg_obj_t *vconfig, isc_mem_t *mctx, dns_view_t *view, - ns_aclconfctx_t *aclconf) + cfg_aclconfctx_t *aclconf) { dns_view_t *pview = NULL; /* Production view */ dns_zone_t *zone = NULL; /* New or reused zone */ @@ -2311,10 +2311,10 @@ load_configuration(const char *filename, isc_uint32_t interface_interval; isc_uint32_t reserved; isc_uint32_t udpsize; - ns_aclconfctx_t aclconfctx; + cfg_aclconfctx_t aclconfctx; unsigned int maxsocks; - ns_aclconfctx_init(&aclconfctx); + cfg_aclconfctx_init(&aclconfctx); ISC_LIST_INIT(viewlist); /* Ensure exclusive access to configuration data. */ @@ -2997,7 +2997,7 @@ load_configuration(const char *filename, if (v6portset != NULL) isc_portset_destroy(ns_g_mctx, &v6portset); - ns_aclconfctx_destroy(&aclconfctx); + cfg_aclconfctx_destroy(&aclconfctx); if (parser != NULL) { if (config != NULL) @@ -3773,7 +3773,7 @@ ns_server_togglequerylog(ns_server_t *se static isc_result_t ns_listenlist_fromconfig(const cfg_obj_t *listenlist, const cfg_obj_t *config, - ns_aclconfctx_t *actx, + cfg_aclconfctx_t *actx, isc_mem_t *mctx, ns_listenlist_t **target) { isc_result_t result; @@ -3812,7 +3812,7 @@ ns_listenlist_fromconfig(const cfg_obj_t */ static isc_result_t ns_listenelt_fromconfig(const cfg_obj_t *listener, const cfg_obj_t *config, - ns_aclconfctx_t *actx, + cfg_aclconfctx_t *actx, isc_mem_t *mctx, ns_listenelt_t **target) { isc_result_t result; @@ -3844,7 +3844,7 @@ ns_listenelt_fromconfig(const cfg_obj_t if (result != ISC_R_SUCCESS) return (result); - result = ns_acl_fromconfig(cfg_tuple_get(listener, "acl"), + result = cfg_acl_fromconfig(cfg_tuple_get(listener, "acl"), config, actx, mctx, &delt->acl); if (result != ISC_R_SUCCESS) { ns_listenelt_destroy(delt); diff -up bind-9.3.6-P1/bin/named/zoneconf.c.acl-to-isccfg bind-9.3.6-P1/bin/named/zoneconf.c --- bind-9.3.6-P1/bin/named/zoneconf.c.acl-to-isccfg 2009-04-24 14:55:10.978901991 +0200 +++ bind-9.3.6-P1/bin/named/zoneconf.c 2009-04-24 14:55:11.006901745 +0200 @@ -57,7 +57,7 @@ static isc_result_t configure_zone_acl(const cfg_obj_t *zconfig, const cfg_obj_t *vconfig, const cfg_obj_t *config, const char *aclname, - ns_aclconfctx_t *actx, dns_zone_t *zone, + cfg_aclconfctx_t *actx, dns_zone_t *zone, void (*setzacl)(dns_zone_t *, dns_acl_t *), void (*clearzacl)(dns_zone_t *)) { @@ -85,7 +85,7 @@ configure_zone_acl(const cfg_obj_t *zcon return (ISC_R_SUCCESS); } - result = ns_acl_fromconfig(aclobj, config, actx, + result = cfg_acl_fromconfig(aclobj, config, actx, dns_zone_getmctx(zone), &dacl); if (result != ISC_R_SUCCESS) return (result); @@ -317,7 +317,7 @@ checknames(dns_zonetype_t ztype, const c isc_result_t ns_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig, - const cfg_obj_t *zconfig, ns_aclconfctx_t *ac, + const cfg_obj_t *zconfig, cfg_aclconfctx_t *ac, dns_zone_t *zone) { isc_result_t result; diff -up bind-9.3.6-P1/lib/isccfg/aclconf.c.acl-to-isccfg bind-9.3.6-P1/lib/isccfg/aclconf.c --- bind-9.3.6-P1/lib/isccfg/aclconf.c.acl-to-isccfg 2007-08-28 09:19:08.000000000 +0200 +++ bind-9.3.6-P1/lib/isccfg/aclconf.c 2009-04-24 14:55:37.174901733 +0200 @@ -23,23 +23,22 @@ #include <isc/string.h> /* Required for HP/UX (and others?) */ #include <isc/util.h> +#include <isccfg/aclconf.h> #include <isccfg/namedconf.h> #include <dns/acl.h> #include <dns/fixedname.h> #include <dns/log.h> -#include <named/aclconf.h> - #define LOOP_MAGIC ISC_MAGIC('L','O','O','P') void -ns_aclconfctx_init(ns_aclconfctx_t *ctx) { +cfg_aclconfctx_init(cfg_aclconfctx_t *ctx) { ISC_LIST_INIT(ctx->named_acl_cache); } void -ns_aclconfctx_destroy(ns_aclconfctx_t *ctx) { +cfg_aclconfctx_destroy(cfg_aclconfctx_t *ctx) { dns_acl_t *dacl, *next; for (dacl = ISC_LIST_HEAD(ctx->named_acl_cache); dacl != NULL; @@ -77,7 +76,7 @@ get_acl_def(const cfg_obj_t *cctx, const static isc_result_t convert_named_acl(const cfg_obj_t *nameobj, const cfg_obj_t *cctx, - ns_aclconfctx_t *ctx, isc_mem_t *mctx, + cfg_aclconfctx_t *ctx, isc_mem_t *mctx, dns_acl_t **target) { isc_result_t result; @@ -116,7 +115,7 @@ convert_named_acl(const cfg_obj_t *nameo DE_CONST(aclname, loop.name); loop.magic = LOOP_MAGIC; ISC_LIST_APPEND(ctx->named_acl_cache, &loop, nextincache); - result = ns_acl_fromconfig(cacl, cctx, ctx, mctx, &dacl); + result = cfg_acl_fromconfig(cacl, cctx, ctx, mctx, &dacl); ISC_LIST_UNLINK(ctx->named_acl_cache, &loop, nextincache); loop.magic = 0; loop.name = NULL; @@ -154,9 +153,9 @@ convert_keyname(const cfg_obj_t *keyobj, } isc_result_t -ns_acl_fromconfig(const cfg_obj_t *caml, +cfg_acl_fromconfig(const cfg_obj_t *caml, const cfg_obj_t *cctx, - ns_aclconfctx_t *ctx, + cfg_aclconfctx_t *ctx, isc_mem_t *mctx, dns_acl_t **target) { @@ -209,7 +208,7 @@ ns_acl_fromconfig(const cfg_obj_t *caml, } else if (cfg_obj_islist(ce)) { /* Nested ACL */ de->type = dns_aclelementtype_nestedacl; - result = ns_acl_fromconfig(ce, cctx, ctx, mctx, + result = cfg_acl_fromconfig(ce, cctx, ctx, mctx, &de->u.nestedacl); if (result != ISC_R_SUCCESS) goto cleanup; diff -up bind-9.3.6-P1/lib/isccfg/include/isccfg/aclconf.h.acl-to-isccfg bind-9.3.6-P1/lib/isccfg/include/isccfg/aclconf.h --- bind-9.3.6-P1/lib/isccfg/include/isccfg/aclconf.h.acl-to-isccfg 2006-03-02 01:37:20.000000000 +0100 +++ bind-9.3.6-P1/lib/isccfg/include/isccfg/aclconf.h 2009-04-24 14:55:11.006901745 +0200 @@ -26,9 +26,9 @@ #include <dns/types.h> -typedef struct ns_aclconfctx { +typedef struct cfg_aclconfctx { ISC_LIST(dns_acl_t) named_acl_cache; -} ns_aclconfctx_t; +} cfg_aclconfctx_t; /*** *** Functions @@ -37,21 +37,21 @@ typedef struct ns_aclconfctx { ISC_LANG_BEGINDECLS void -ns_aclconfctx_init(ns_aclconfctx_t *ctx); +cfg_aclconfctx_init(cfg_aclconfctx_t *ctx); /* * Initialize an ACL configuration context. */ void -ns_aclconfctx_destroy(ns_aclconfctx_t *ctx); +cfg_aclconfctx_destroy(cfg_aclconfctx_t *ctx); /* * Destroy an ACL configuration context. */ isc_result_t -ns_acl_fromconfig(const cfg_obj_t *caml, +cfg_acl_fromconfig(const cfg_obj_t *caml, const cfg_obj_t *cctx, - ns_aclconfctx_t *ctx, + cfg_aclconfctx_t *ctx, isc_mem_t *mctx, dns_acl_t **target); /* diff -up bind-9.3.6-P1/lib/isccfg/include/isccfg/Makefile.in.acl-to-isccfg bind-9.3.6-P1/lib/isccfg/include/isccfg/Makefile.in --- bind-9.3.6-P1/lib/isccfg/include/isccfg/Makefile.in.acl-to-isccfg 2007-08-28 09:19:18.000000000 +0200 +++ bind-9.3.6-P1/lib/isccfg/include/isccfg/Makefile.in 2009-04-24 14:55:11.006901745 +0200 @@ -26,7 +26,7 @@ top_srcdir = @top_srcdir@ # machine generated. The latter are handled specially in the # install target below. # -HEADERS = cfg.h grammar.h log.h namedconf.h version.h +HEADERS = aclconf.h cfg.h grammar.h log.h namedconf.h version.h SUBDIRS = TARGETS = diff -up bind-9.3.6-P1/lib/isccfg/Makefile.in.acl-to-isccfg bind-9.3.6-P1/lib/isccfg/Makefile.in --- bind-9.3.6-P1/lib/isccfg/Makefile.in.acl-to-isccfg 2009-04-24 14:55:10.934922680 +0200 +++ bind-9.3.6-P1/lib/isccfg/Makefile.in 2009-04-24 14:55:11.006901745 +0200 @@ -43,10 +43,10 @@ LIBS = @LIBS@ SUBDIRS = include # Alphabetically -OBJS = log.@O@ namedconf.@O@ parser.@O@ version.@O@ +OBJS = aclconf.@O@ log.@O@ namedconf.@O@ parser.@O@ version.@O@ # Alphabetically -SRCS = log.c namedconf.c parser.c version.c +SRCS = aclconf.c log.c namedconf.c parser.c version.c TARGETS = timestamp