&tls_params, tlsctx_cache, &delt));
}
- result = cfg_acl_fromconfig2(cfg_tuple_get(listener, "acl"), config,
- named_g_lctx, actx, mctx, 0, family,
- &delt->acl);
+ result = cfg_acl_fromconfig(cfg_tuple_get(listener, "acl"), config,
+ named_g_lctx, actx, mctx, family,
+ &delt->acl);
if (result != ISC_R_SUCCESS) {
ns_listenelt_destroy(delt);
return (result);
#endif /* HAVE_GEOIP2 */
isc_result_t
-cfg_acl_fromconfig(const cfg_obj_t *caml, const cfg_obj_t *cctx,
+cfg_acl_fromconfig(const cfg_obj_t *acl_data, const cfg_obj_t *cctx,
isc_log_t *lctx, cfg_aclconfctx_t *ctx, isc_mem_t *mctx,
unsigned int nest_level, dns_acl_t **target) {
- return (cfg_acl_fromconfig2(caml, cctx, lctx, ctx, mctx, nest_level, 0,
- target));
-}
-
-isc_result_t
-cfg_acl_fromconfig2(const cfg_obj_t *acl_data, const cfg_obj_t *cctx,
- isc_log_t *lctx, cfg_aclconfctx_t *ctx, isc_mem_t *mctx,
- unsigned int nest_level, uint16_t family,
- dns_acl_t **target) {
isc_result_t result;
dns_acl_t *dacl = NULL, *inneracl = NULL;
dns_aclelement_t *de;
unsigned int bitlen;
cfg_obj_asnetprefix(ce, &addr, &bitlen);
- if (family != 0 && family != addr.family) {
- char buf[ISC_NETADDR_FORMATSIZE + 1];
- isc_netaddr_format(&addr, buf, sizeof(buf));
- cfg_obj_log(ce, lctx, ISC_LOG_WARNING,
- "'%s': incorrect address family; "
- "ignoring",
- buf);
- if (nest_level != 0) {
- dns_acl_detach(&de->nestedacl);
- }
- continue;
- }
result = isc_netaddr_prefixok(&addr, bitlen);
if (result != ISC_R_SUCCESS) {
char buf[ISC_NETADDR_FORMATSIZE + 1];
cfg_acl_fromconfig(const cfg_obj_t *caml, const cfg_obj_t *cctx,
isc_log_t *lctx, cfg_aclconfctx_t *ctx, isc_mem_t *mctx,
unsigned int nest_level, dns_acl_t **target);
-
-isc_result_t
-cfg_acl_fromconfig2(const cfg_obj_t *caml, const cfg_obj_t *cctx,
- isc_log_t *lctx, cfg_aclconfctx_t *ctx, isc_mem_t *mctx,
- unsigned int nest_level, uint16_t family,
- dns_acl_t **target);
/*
* Construct a new dns_acl_t from configuration data in 'caml' and
* 'cctx'. Memory is allocated through 'mctx'.
* nested dns_acl_t object when the referring objects were created
* passing the same ACL configuration context 'ctx'.
*
- * cfg_acl_fromconfig() is a backward-compatible version of
- * cfg_acl_fromconfig2(), which allows an address family to be
- * specified. If 'family' is not zero, then only addresses/prefixes
- * of a matching family (AF_INET or AF_INET6) may be configured.
- *
* On success, attach '*target' to the new dns_acl_t object.
*
* Require: