]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
775. [bug] acls with invalid netmasks caused the parser to
authorBrian Wellington <source@isc.org>
Thu, 8 Mar 2001 18:24:54 +0000 (18:24 +0000)
committerBrian Wellington <source@isc.org>
Thu, 8 Mar 2001 18:24:54 +0000 (18:24 +0000)
                        abort with an assertion failure. [RT #996]
(not applicable to the mainline)

CHANGES
lib/dns/config/confparser.y.dirty

diff --git a/CHANGES b/CHANGES
index 1f6f9bc1b62eaceb15711676a2208a6da17827ca..d28ce8b505b53fb73a23ada2e52f65a45beee9e3 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,5 @@
+ 775.   [bug]          acls with invalid netmasks caused the parser to
+                       abort with an assertion failure. [RT #996]
 
  772.  [bug]           Owner names could be incorrectly omitted from cache
                        dumps in the presence of negative caching entries.
index 0707a788df92e8a253c58377d1494b5752046e98..02248ac3b0d51e88bf13a246b28303ca157ccb33 100644 (file)
@@ -33,7 +33,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: confparser.y.dirty,v 1.44.2.5 2001/03/06 02:05:34 bwelling Exp $ */
+/* $Id: confparser.y.dirty,v 1.44.2.6 2001/03/08 18:24:54 bwelling Exp $ */
 
 #include <config.h>
 
@@ -3368,10 +3368,9 @@ address_match_simple: ip_address
                if ($3 < 0 ||
                    ($1.type.sa.sa_family == AF_INET && $3 > 32) ||
                    ($1.type.sa.sa_family == AF_INET6 && $3 > 128)) {
-                       parser_warning(ISC_FALSE,
-                                      "mask bits (%d) out of range: "
-                                      "skipping", (int)$3);
-                       $$ = NULL;
+                       parser_error(ISC_FALSE,
+                                    "mask bits (%d) out of range", (int)$3);
+                       YYABORT;
                } else {
                        tmpres = dns_c_ipmatchpattern_new(currcfg->mem, &ime,
                                                          $1, $3);
@@ -3407,10 +3406,9 @@ address_match_simple: ip_address
                        YYABORT;
                } else {
                        if ($3 < 0 || $3 > 32) {
-                               parser_warning(ISC_FALSE,
-                                              "mask bits out of range; "
-                                              "skipping");
-                               $$ = NULL;
+                               parser_error(ISC_FALSE,
+                                            "mask bits out of range; ");
+                               YYABORT;
                        } else {
                                ia.s_addr = htonl(($1 & 0xff) << 24);
                                isc_sockaddr_fromin(&address, &ia, 0);