From 6b7a488cbcedf0fcb3f9de3e8e63795afd599781 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Sur=C3=BD?= Date: Thu, 16 Sep 2021 10:38:22 +0200 Subject: [PATCH] Mark the masterfile-format type 'map' as deprecated The map masterfile-format is very fragile and it needs API bump every time a RBTDB data structures changes. Also while testing it, we found out that files larger than 2GB weren't loading and nobody noticed, and loading many map files were also failing (subject to kernel limits). Thus we are marking the masterfile-format type 'map' as deprecated and to be removed in the next stable BIND 9 release. --- bin/named/zoneconf.c | 3 +++ lib/bind9/check.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/bin/named/zoneconf.c b/bin/named/zoneconf.c index 92fa47cc9f..d61fb4f2a5 100644 --- a/bin/named/zoneconf.c +++ b/bin/named/zoneconf.c @@ -1053,6 +1053,9 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig, masterformat = dns_masterformat_raw; } else if (strcasecmp(masterformatstr, "map") == 0) { masterformat = dns_masterformat_map; + cfg_obj_log(obj, named_g_lctx, ISC_LOG_WARNING, + "masterfile-format: format 'map' is " + "deprecated"); } else { INSIST(0); ISC_UNREACHABLE(); diff --git a/lib/bind9/check.c b/lib/bind9/check.c index 5cc360624e..7189a8d4c6 100644 --- a/lib/bind9/check.c +++ b/lib/bind9/check.c @@ -3459,6 +3459,9 @@ check_zoneconf(const cfg_obj_t *zconfig, const cfg_obj_t *voptions, masterformat = dns_masterformat_raw; } else if (strcasecmp(masterformatstr, "map") == 0) { masterformat = dns_masterformat_map; + cfg_obj_log(obj, logctx, ISC_LOG_WARNING, + "masterfile-format: format 'map' is " + "deprecated"); } else { INSIST(0); ISC_UNREACHABLE();