1 /* A Bison parser, made by GNU Bison 3.0.4. */ 2 3 /* Bison implementation for Yacc-like parsers in C 4 5 Copyright (C) 1984, 1989-1990, 2000-2015 Free Software Foundation, Inc. 6 7 This program is free software: you can redistribute it and/or modify 8 it under the terms of the GNU General Public License as published by 9 the Free Software Foundation, either version 3 of the License, or 10 (at your option) any later version. 11 12 This program is distributed in the hope that it will be useful, 13 but WITHOUT ANY WARRANTY; without even the implied warranty of 14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 GNU General Public License for more details. 16 17 You should have received a copy of the GNU General Public License 18 along with this program. If not, see <http://www.gnu.org/licenses/>. */ 19 20 /* As a special exception, you may create a larger work that contains 21 part or all of the Bison parser skeleton and distribute that work 22 under terms of your choice, so long as that work isn't itself a 23 parser generator using the skeleton or a modified version thereof 24 as a parser skeleton. Alternatively, if you modify or redistribute 25 the parser skeleton itself, you may (at your option) remove this 26 special exception, which will cause the skeleton and the resulting 27 Bison output files to be licensed under the GNU General Public 28 License without this special exception. 29 30 This special exception was added by the Free Software Foundation in 31 version 2.2 of Bison. */ 32 33 /* C LALR(1) parser skeleton written by Richard Stallman, by 34 simplifying the original so-called "semantic" parser. */ 35 36 /* All symbols defined below should begin with yy or YY, to avoid 37 infringing on user name space. This should be done even for local 38 variables, as they might otherwise be expanded by user macros. 39 There are some unavoidable exceptions within include files to 40 define necessary library symbols; they are noted "INFRINGES ON 41 USER NAME SPACE" below. */ 42 43 /* Identify Bison output. */ 44 #define YYBISON 1 45 46 /* Bison version. */ 47 #define YYBISON_VERSION "3.0.4" 48 49 /* Skeleton name. */ 50 #define YYSKELETON_NAME "yacc.c" 51 52 /* Pure parsers. */ 53 #define YYPURE 0 54 55 /* Push parsers. */ 56 #define YYPUSH 0 57 58 /* Pull parsers. */ 59 #define YYPULL 1 60 61 62 63 64 /* Copy the first part of user declarations. */ 65 #line 38 "util/configparser.y" /* yacc.c:339 */ 66 67 #include "config.h" 68 69 #include <stdarg.h> 70 #include <stdio.h> 71 #include <string.h> 72 #include <stdlib.h> 73 #include <assert.h> 74 75 #include "util/configyyrename.h" 76 #include "util/config_file.h" 77 #include "util/net_help.h" 78 79 int ub_c_lex(void); 80 void ub_c_error(const char *message); 81 82 /* these need to be global, otherwise they cannot be used inside yacc */ 83 extern struct config_parser_state* cfg_parser; 84 85 #if 0 86 #define OUTYY(s) printf s /* used ONLY when debugging */ 87 #else 88 #define OUTYY(s) 89 #endif 90 91 92 #line 93 "util/configparser.c" /* yacc.c:339 */ 93 94 # ifndef YY_NULLPTR 95 # if defined __cplusplus && 201103L <= __cplusplus 96 # define YY_NULLPTR nullptr 97 # else 98 # define YY_NULLPTR 0 99 # endif 100 # endif 101 102 /* Enabling verbose error messages. */ 103 #ifdef YYERROR_VERBOSE 104 # undef YYERROR_VERBOSE 105 # define YYERROR_VERBOSE 1 106 #else 107 # define YYERROR_VERBOSE 0 108 #endif 109 110 /* In a future release of Bison, this section will be replaced 111 by #include "configparser.h". */ 112 #ifndef YY_YY_UTIL_CONFIGPARSER_H_INCLUDED 113 # define YY_YY_UTIL_CONFIGPARSER_H_INCLUDED 114 /* Debug traces. */ 115 #ifndef YYDEBUG 116 # define YYDEBUG 0 117 #endif 118 #if YYDEBUG 119 extern int yydebug; 120 #endif 121 122 /* Token type. */ 123 #ifndef YYTOKENTYPE 124 # define YYTOKENTYPE 125 enum yytokentype 126 { 127 SPACE = 258, 128 LETTER = 259, 129 NEWLINE = 260, 130 COMMENT = 261, 131 COLON = 262, 132 ANY = 263, 133 ZONESTR = 264, 134 STRING_ARG = 265, 135 VAR_SERVER = 266, 136 VAR_VERBOSITY = 267, 137 VAR_NUM_THREADS = 268, 138 VAR_PORT = 269, 139 VAR_OUTGOING_RANGE = 270, 140 VAR_INTERFACE = 271, 141 VAR_DO_IP4 = 272, 142 VAR_DO_IP6 = 273, 143 VAR_DO_UDP = 274, 144 VAR_DO_TCP = 275, 145 VAR_TCP_MSS = 276, 146 VAR_OUTGOING_TCP_MSS = 277, 147 VAR_CHROOT = 278, 148 VAR_USERNAME = 279, 149 VAR_DIRECTORY = 280, 150 VAR_LOGFILE = 281, 151 VAR_PIDFILE = 282, 152 VAR_MSG_CACHE_SIZE = 283, 153 VAR_MSG_CACHE_SLABS = 284, 154 VAR_NUM_QUERIES_PER_THREAD = 285, 155 VAR_RRSET_CACHE_SIZE = 286, 156 VAR_RRSET_CACHE_SLABS = 287, 157 VAR_OUTGOING_NUM_TCP = 288, 158 VAR_INFRA_HOST_TTL = 289, 159 VAR_INFRA_LAME_TTL = 290, 160 VAR_INFRA_CACHE_SLABS = 291, 161 VAR_INFRA_CACHE_NUMHOSTS = 292, 162 VAR_INFRA_CACHE_LAME_SIZE = 293, 163 VAR_NAME = 294, 164 VAR_STUB_ZONE = 295, 165 VAR_STUB_HOST = 296, 166 VAR_STUB_ADDR = 297, 167 VAR_TARGET_FETCH_POLICY = 298, 168 VAR_HARDEN_SHORT_BUFSIZE = 299, 169 VAR_HARDEN_LARGE_QUERIES = 300, 170 VAR_FORWARD_ZONE = 301, 171 VAR_FORWARD_HOST = 302, 172 VAR_FORWARD_ADDR = 303, 173 VAR_DO_NOT_QUERY_ADDRESS = 304, 174 VAR_HIDE_IDENTITY = 305, 175 VAR_HIDE_VERSION = 306, 176 VAR_IDENTITY = 307, 177 VAR_VERSION = 308, 178 VAR_HARDEN_GLUE = 309, 179 VAR_MODULE_CONF = 310, 180 VAR_TRUST_ANCHOR_FILE = 311, 181 VAR_TRUST_ANCHOR = 312, 182 VAR_VAL_OVERRIDE_DATE = 313, 183 VAR_BOGUS_TTL = 314, 184 VAR_VAL_CLEAN_ADDITIONAL = 315, 185 VAR_VAL_PERMISSIVE_MODE = 316, 186 VAR_INCOMING_NUM_TCP = 317, 187 VAR_MSG_BUFFER_SIZE = 318, 188 VAR_KEY_CACHE_SIZE = 319, 189 VAR_KEY_CACHE_SLABS = 320, 190 VAR_TRUSTED_KEYS_FILE = 321, 191 VAR_VAL_NSEC3_KEYSIZE_ITERATIONS = 322, 192 VAR_USE_SYSLOG = 323, 193 VAR_OUTGOING_INTERFACE = 324, 194 VAR_ROOT_HINTS = 325, 195 VAR_DO_NOT_QUERY_LOCALHOST = 326, 196 VAR_CACHE_MAX_TTL = 327, 197 VAR_HARDEN_DNSSEC_STRIPPED = 328, 198 VAR_ACCESS_CONTROL = 329, 199 VAR_LOCAL_ZONE = 330, 200 VAR_LOCAL_DATA = 331, 201 VAR_INTERFACE_AUTOMATIC = 332, 202 VAR_STATISTICS_INTERVAL = 333, 203 VAR_DO_DAEMONIZE = 334, 204 VAR_USE_CAPS_FOR_ID = 335, 205 VAR_STATISTICS_CUMULATIVE = 336, 206 VAR_OUTGOING_PORT_PERMIT = 337, 207 VAR_OUTGOING_PORT_AVOID = 338, 208 VAR_DLV_ANCHOR_FILE = 339, 209 VAR_DLV_ANCHOR = 340, 210 VAR_NEG_CACHE_SIZE = 341, 211 VAR_HARDEN_REFERRAL_PATH = 342, 212 VAR_PRIVATE_ADDRESS = 343, 213 VAR_PRIVATE_DOMAIN = 344, 214 VAR_REMOTE_CONTROL = 345, 215 VAR_CONTROL_ENABLE = 346, 216 VAR_CONTROL_INTERFACE = 347, 217 VAR_CONTROL_PORT = 348, 218 VAR_SERVER_KEY_FILE = 349, 219 VAR_SERVER_CERT_FILE = 350, 220 VAR_CONTROL_KEY_FILE = 351, 221 VAR_CONTROL_CERT_FILE = 352, 222 VAR_CONTROL_USE_CERT = 353, 223 VAR_EXTENDED_STATISTICS = 354, 224 VAR_LOCAL_DATA_PTR = 355, 225 VAR_JOSTLE_TIMEOUT = 356, 226 VAR_STUB_PRIME = 357, 227 VAR_UNWANTED_REPLY_THRESHOLD = 358, 228 VAR_LOG_TIME_ASCII = 359, 229 VAR_DOMAIN_INSECURE = 360, 230 VAR_PYTHON = 361, 231 VAR_PYTHON_SCRIPT = 362, 232 VAR_VAL_SIG_SKEW_MIN = 363, 233 VAR_VAL_SIG_SKEW_MAX = 364, 234 VAR_CACHE_MIN_TTL = 365, 235 VAR_VAL_LOG_LEVEL = 366, 236 VAR_AUTO_TRUST_ANCHOR_FILE = 367, 237 VAR_KEEP_MISSING = 368, 238 VAR_ADD_HOLDDOWN = 369, 239 VAR_DEL_HOLDDOWN = 370, 240 VAR_SO_RCVBUF = 371, 241 VAR_EDNS_BUFFER_SIZE = 372, 242 VAR_PREFETCH = 373, 243 VAR_PREFETCH_KEY = 374, 244 VAR_SO_SNDBUF = 375, 245 VAR_SO_REUSEPORT = 376, 246 VAR_HARDEN_BELOW_NXDOMAIN = 377, 247 VAR_IGNORE_CD_FLAG = 378, 248 VAR_LOG_QUERIES = 379, 249 VAR_TCP_UPSTREAM = 380, 250 VAR_SSL_UPSTREAM = 381, 251 VAR_SSL_SERVICE_KEY = 382, 252 VAR_SSL_SERVICE_PEM = 383, 253 VAR_SSL_PORT = 384, 254 VAR_FORWARD_FIRST = 385, 255 VAR_STUB_FIRST = 386, 256 VAR_MINIMAL_RESPONSES = 387, 257 VAR_RRSET_ROUNDROBIN = 388, 258 VAR_MAX_UDP_SIZE = 389, 259 VAR_DELAY_CLOSE = 390, 260 VAR_UNBLOCK_LAN_ZONES = 391, 261 VAR_INSECURE_LAN_ZONES = 392, 262 VAR_INFRA_CACHE_MIN_RTT = 393, 263 VAR_DNS64_PREFIX = 394, 264 VAR_DNS64_SYNTHALL = 395, 265 VAR_DNSTAP = 396, 266 VAR_DNSTAP_ENABLE = 397, 267 VAR_DNSTAP_SOCKET_PATH = 398, 268 VAR_DNSTAP_SEND_IDENTITY = 399, 269 VAR_DNSTAP_SEND_VERSION = 400, 270 VAR_DNSTAP_IDENTITY = 401, 271 VAR_DNSTAP_VERSION = 402, 272 VAR_DNSTAP_LOG_RESOLVER_QUERY_MESSAGES = 403, 273 VAR_DNSTAP_LOG_RESOLVER_RESPONSE_MESSAGES = 404, 274 VAR_DNSTAP_LOG_CLIENT_QUERY_MESSAGES = 405, 275 VAR_DNSTAP_LOG_CLIENT_RESPONSE_MESSAGES = 406, 276 VAR_DNSTAP_LOG_FORWARDER_QUERY_MESSAGES = 407, 277 VAR_DNSTAP_LOG_FORWARDER_RESPONSE_MESSAGES = 408, 278 VAR_HARDEN_ALGO_DOWNGRADE = 409, 279 VAR_IP_TRANSPARENT = 410, 280 VAR_DISABLE_DNSSEC_LAME_CHECK = 411, 281 VAR_RATELIMIT = 412, 282 VAR_RATELIMIT_SLABS = 413, 283 VAR_RATELIMIT_SIZE = 414, 284 VAR_RATELIMIT_FOR_DOMAIN = 415, 285 VAR_RATELIMIT_BELOW_DOMAIN = 416, 286 VAR_RATELIMIT_FACTOR = 417, 287 VAR_CAPS_WHITELIST = 418, 288 VAR_CACHE_MAX_NEGATIVE_TTL = 419, 289 VAR_PERMIT_SMALL_HOLDDOWN = 420, 290 VAR_QNAME_MINIMISATION = 421, 291 VAR_IP_FREEBIND = 422, 292 VAR_DEFINE_TAG = 423, 293 VAR_LOCAL_ZONE_TAG = 424 294 }; 295 #endif 296 /* Tokens. */ 297 #define SPACE 258 298 #define LETTER 259 299 #define NEWLINE 260 300 #define COMMENT 261 301 #define COLON 262 302 #define ANY 263 303 #define ZONESTR 264 304 #define STRING_ARG 265 305 #define VAR_SERVER 266 306 #define VAR_VERBOSITY 267 307 #define VAR_NUM_THREADS 268 308 #define VAR_PORT 269 309 #define VAR_OUTGOING_RANGE 270 310 #define VAR_INTERFACE 271 311 #define VAR_DO_IP4 272 312 #define VAR_DO_IP6 273 313 #define VAR_DO_UDP 274 314 #define VAR_DO_TCP 275 315 #define VAR_TCP_MSS 276 316 #define VAR_OUTGOING_TCP_MSS 277 317 #define VAR_CHROOT 278 318 #define VAR_USERNAME 279 319 #define VAR_DIRECTORY 280 320 #define VAR_LOGFILE 281 321 #define VAR_PIDFILE 282 322 #define VAR_MSG_CACHE_SIZE 283 323 #define VAR_MSG_CACHE_SLABS 284 324 #define VAR_NUM_QUERIES_PER_THREAD 285 325 #define VAR_RRSET_CACHE_SIZE 286 326 #define VAR_RRSET_CACHE_SLABS 287 327 #define VAR_OUTGOING_NUM_TCP 288 328 #define VAR_INFRA_HOST_TTL 289 329 #define VAR_INFRA_LAME_TTL 290 330 #define VAR_INFRA_CACHE_SLABS 291 331 #define VAR_INFRA_CACHE_NUMHOSTS 292 332 #define VAR_INFRA_CACHE_LAME_SIZE 293 333 #define VAR_NAME 294 334 #define VAR_STUB_ZONE 295 335 #define VAR_STUB_HOST 296 336 #define VAR_STUB_ADDR 297 337 #define VAR_TARGET_FETCH_POLICY 298 338 #define VAR_HARDEN_SHORT_BUFSIZE 299 339 #define VAR_HARDEN_LARGE_QUERIES 300 340 #define VAR_FORWARD_ZONE 301 341 #define VAR_FORWARD_HOST 302 342 #define VAR_FORWARD_ADDR 303 343 #define VAR_DO_NOT_QUERY_ADDRESS 304 344 #define VAR_HIDE_IDENTITY 305 345 #define VAR_HIDE_VERSION 306 346 #define VAR_IDENTITY 307 347 #define VAR_VERSION 308 348 #define VAR_HARDEN_GLUE 309 349 #define VAR_MODULE_CONF 310 350 #define VAR_TRUST_ANCHOR_FILE 311 351 #define VAR_TRUST_ANCHOR 312 352 #define VAR_VAL_OVERRIDE_DATE 313 353 #define VAR_BOGUS_TTL 314 354 #define VAR_VAL_CLEAN_ADDITIONAL 315 355 #define VAR_VAL_PERMISSIVE_MODE 316 356 #define VAR_INCOMING_NUM_TCP 317 357 #define VAR_MSG_BUFFER_SIZE 318 358 #define VAR_KEY_CACHE_SIZE 319 359 #define VAR_KEY_CACHE_SLABS 320 360 #define VAR_TRUSTED_KEYS_FILE 321 361 #define VAR_VAL_NSEC3_KEYSIZE_ITERATIONS 322 362 #define VAR_USE_SYSLOG 323 363 #define VAR_OUTGOING_INTERFACE 324 364 #define VAR_ROOT_HINTS 325 365 #define VAR_DO_NOT_QUERY_LOCALHOST 326 366 #define VAR_CACHE_MAX_TTL 327 367 #define VAR_HARDEN_DNSSEC_STRIPPED 328 368 #define VAR_ACCESS_CONTROL 329 369 #define VAR_LOCAL_ZONE 330 370 #define VAR_LOCAL_DATA 331 371 #define VAR_INTERFACE_AUTOMATIC 332 372 #define VAR_STATISTICS_INTERVAL 333 373 #define VAR_DO_DAEMONIZE 334 374 #define VAR_USE_CAPS_FOR_ID 335 375 #define VAR_STATISTICS_CUMULATIVE 336 376 #define VAR_OUTGOING_PORT_PERMIT 337 377 #define VAR_OUTGOING_PORT_AVOID 338 378 #define VAR_DLV_ANCHOR_FILE 339 379 #define VAR_DLV_ANCHOR 340 380 #define VAR_NEG_CACHE_SIZE 341 381 #define VAR_HARDEN_REFERRAL_PATH 342 382 #define VAR_PRIVATE_ADDRESS 343 383 #define VAR_PRIVATE_DOMAIN 344 384 #define VAR_REMOTE_CONTROL 345 385 #define VAR_CONTROL_ENABLE 346 386 #define VAR_CONTROL_INTERFACE 347 387 #define VAR_CONTROL_PORT 348 388 #define VAR_SERVER_KEY_FILE 349 389 #define VAR_SERVER_CERT_FILE 350 390 #define VAR_CONTROL_KEY_FILE 351 391 #define VAR_CONTROL_CERT_FILE 352 392 #define VAR_CONTROL_USE_CERT 353 393 #define VAR_EXTENDED_STATISTICS 354 394 #define VAR_LOCAL_DATA_PTR 355 395 #define VAR_JOSTLE_TIMEOUT 356 396 #define VAR_STUB_PRIME 357 397 #define VAR_UNWANTED_REPLY_THRESHOLD 358 398 #define VAR_LOG_TIME_ASCII 359 399 #define VAR_DOMAIN_INSECURE 360 400 #define VAR_PYTHON 361 401 #define VAR_PYTHON_SCRIPT 362 402 #define VAR_VAL_SIG_SKEW_MIN 363 403 #define VAR_VAL_SIG_SKEW_MAX 364 404 #define VAR_CACHE_MIN_TTL 365 405 #define VAR_VAL_LOG_LEVEL 366 406 #define VAR_AUTO_TRUST_ANCHOR_FILE 367 407 #define VAR_KEEP_MISSING 368 408 #define VAR_ADD_HOLDDOWN 369 409 #define VAR_DEL_HOLDDOWN 370 410 #define VAR_SO_RCVBUF 371 411 #define VAR_EDNS_BUFFER_SIZE 372 412 #define VAR_PREFETCH 373 413 #define VAR_PREFETCH_KEY 374 414 #define VAR_SO_SNDBUF 375 415 #define VAR_SO_REUSEPORT 376 416 #define VAR_HARDEN_BELOW_NXDOMAIN 377 417 #define VAR_IGNORE_CD_FLAG 378 418 #define VAR_LOG_QUERIES 379 419 #define VAR_TCP_UPSTREAM 380 420 #define VAR_SSL_UPSTREAM 381 421 #define VAR_SSL_SERVICE_KEY 382 422 #define VAR_SSL_SERVICE_PEM 383 423 #define VAR_SSL_PORT 384 424 #define VAR_FORWARD_FIRST 385 425 #define VAR_STUB_FIRST 386 426 #define VAR_MINIMAL_RESPONSES 387 427 #define VAR_RRSET_ROUNDROBIN 388 428 #define VAR_MAX_UDP_SIZE 389 429 #define VAR_DELAY_CLOSE 390 430 #define VAR_UNBLOCK_LAN_ZONES 391 431 #define VAR_INSECURE_LAN_ZONES 392 432 #define VAR_INFRA_CACHE_MIN_RTT 393 433 #define VAR_DNS64_PREFIX 394 434 #define VAR_DNS64_SYNTHALL 395 435 #define VAR_DNSTAP 396 436 #define VAR_DNSTAP_ENABLE 397 437 #define VAR_DNSTAP_SOCKET_PATH 398 438 #define VAR_DNSTAP_SEND_IDENTITY 399 439 #define VAR_DNSTAP_SEND_VERSION 400 440 #define VAR_DNSTAP_IDENTITY 401 441 #define VAR_DNSTAP_VERSION 402 442 #define VAR_DNSTAP_LOG_RESOLVER_QUERY_MESSAGES 403 443 #define VAR_DNSTAP_LOG_RESOLVER_RESPONSE_MESSAGES 404 444 #define VAR_DNSTAP_LOG_CLIENT_QUERY_MESSAGES 405 445 #define VAR_DNSTAP_LOG_CLIENT_RESPONSE_MESSAGES 406 446 #define VAR_DNSTAP_LOG_FORWARDER_QUERY_MESSAGES 407 447 #define VAR_DNSTAP_LOG_FORWARDER_RESPONSE_MESSAGES 408 448 #define VAR_HARDEN_ALGO_DOWNGRADE 409 449 #define VAR_IP_TRANSPARENT 410 450 #define VAR_DISABLE_DNSSEC_LAME_CHECK 411 451 #define VAR_RATELIMIT 412 452 #define VAR_RATELIMIT_SLABS 413 453 #define VAR_RATELIMIT_SIZE 414 454 #define VAR_RATELIMIT_FOR_DOMAIN 415 455 #define VAR_RATELIMIT_BELOW_DOMAIN 416 456 #define VAR_RATELIMIT_FACTOR 417 457 #define VAR_CAPS_WHITELIST 418 458 #define VAR_CACHE_MAX_NEGATIVE_TTL 419 459 #define VAR_PERMIT_SMALL_HOLDDOWN 420 460 #define VAR_QNAME_MINIMISATION 421 461 #define VAR_IP_FREEBIND 422 462 #define VAR_DEFINE_TAG 423 463 #define VAR_LOCAL_ZONE_TAG 424 464 465 /* Value type. */ 466 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED 467 468 union YYSTYPE 469 { 470 #line 64 "util/configparser.y" /* yacc.c:355 */ 471 472 char* str; 473 474 #line 475 "util/configparser.c" /* yacc.c:355 */ 475 }; 476 477 typedef union YYSTYPE YYSTYPE; 478 # define YYSTYPE_IS_TRIVIAL 1 479 # define YYSTYPE_IS_DECLARED 1 480 #endif 481 482 483 extern YYSTYPE yylval; 484 485 int yyparse (void); 486 487 #endif /* !YY_YY_UTIL_CONFIGPARSER_H_INCLUDED */ 488 489 /* Copy the second part of user declarations. */ 490 491 #line 492 "util/configparser.c" /* yacc.c:358 */ 492 493 #ifdef short 494 # undef short 495 #endif 496 497 #ifdef YYTYPE_UINT8 498 typedef YYTYPE_UINT8 yytype_uint8; 499 #else 500 typedef unsigned char yytype_uint8; 501 #endif 502 503 #ifdef YYTYPE_INT8 504 typedef YYTYPE_INT8 yytype_int8; 505 #else 506 typedef signed char yytype_int8; 507 #endif 508 509 #ifdef YYTYPE_UINT16 510 typedef YYTYPE_UINT16 yytype_uint16; 511 #else 512 typedef unsigned short int yytype_uint16; 513 #endif 514 515 #ifdef YYTYPE_INT16 516 typedef YYTYPE_INT16 yytype_int16; 517 #else 518 typedef short int yytype_int16; 519 #endif 520 521 #ifndef YYSIZE_T 522 # ifdef __SIZE_TYPE__ 523 # define YYSIZE_T __SIZE_TYPE__ 524 # elif defined size_t 525 # define YYSIZE_T size_t 526 # elif ! defined YYSIZE_T 527 # include <stddef.h> /* INFRINGES ON USER NAME SPACE */ 528 # define YYSIZE_T size_t 529 # else 530 # define YYSIZE_T unsigned int 531 # endif 532 #endif 533 534 #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) 535 536 #ifndef YY_ 537 # if defined YYENABLE_NLS && YYENABLE_NLS 538 # if ENABLE_NLS 539 # include <libintl.h> /* INFRINGES ON USER NAME SPACE */ 540 # define YY_(Msgid) dgettext ("bison-runtime", Msgid) 541 # endif 542 # endif 543 # ifndef YY_ 544 # define YY_(Msgid) Msgid 545 # endif 546 #endif 547 548 #ifndef YY_ATTRIBUTE 549 # if (defined __GNUC__ \ 550 && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \ 551 || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C 552 # define YY_ATTRIBUTE(Spec) __attribute__(Spec) 553 # else 554 # define YY_ATTRIBUTE(Spec) /* empty */ 555 # endif 556 #endif 557 558 #ifndef YY_ATTRIBUTE_PURE 559 # define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__)) 560 #endif 561 562 #ifndef YY_ATTRIBUTE_UNUSED 563 # define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__)) 564 #endif 565 566 #if !defined _Noreturn \ 567 && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112) 568 # if defined _MSC_VER && 1200 <= _MSC_VER 569 # define _Noreturn __declspec (noreturn) 570 # else 571 # define _Noreturn YY_ATTRIBUTE ((__noreturn__)) 572 # endif 573 #endif 574 575 /* Suppress unused-variable warnings by "using" E. */ 576 #if ! defined lint || defined __GNUC__ 577 # define YYUSE(E) ((void) (E)) 578 #else 579 # define YYUSE(E) /* empty */ 580 #endif 581 582 #if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ 583 /* Suppress an incorrect diagnostic about yylval being uninitialized. */ 584 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ 585 _Pragma ("GCC diagnostic push") \ 586 _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\ 587 _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") 588 # define YY_IGNORE_MAYBE_UNINITIALIZED_END \ 589 _Pragma ("GCC diagnostic pop") 590 #else 591 # define YY_INITIAL_VALUE(Value) Value 592 #endif 593 #ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN 594 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN 595 # define YY_IGNORE_MAYBE_UNINITIALIZED_END 596 #endif 597 #ifndef YY_INITIAL_VALUE 598 # define YY_INITIAL_VALUE(Value) /* Nothing. */ 599 #endif 600 601 602 #if ! defined yyoverflow || YYERROR_VERBOSE 603 604 /* The parser invokes alloca or malloc; define the necessary symbols. */ 605 606 # ifdef YYSTACK_USE_ALLOCA 607 # if YYSTACK_USE_ALLOCA 608 # ifdef __GNUC__ 609 # define YYSTACK_ALLOC __builtin_alloca 610 # elif defined __BUILTIN_VA_ARG_INCR 611 # include <alloca.h> /* INFRINGES ON USER NAME SPACE */ 612 # elif defined _AIX 613 # define YYSTACK_ALLOC __alloca 614 # elif defined _MSC_VER 615 # include <malloc.h> /* INFRINGES ON USER NAME SPACE */ 616 # define alloca _alloca 617 # else 618 # define YYSTACK_ALLOC alloca 619 # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS 620 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ 621 /* Use EXIT_SUCCESS as a witness for stdlib.h. */ 622 # ifndef EXIT_SUCCESS 623 # define EXIT_SUCCESS 0 624 # endif 625 # endif 626 # endif 627 # endif 628 # endif 629 630 # ifdef YYSTACK_ALLOC 631 /* Pacify GCC's 'empty if-body' warning. */ 632 # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) 633 # ifndef YYSTACK_ALLOC_MAXIMUM 634 /* The OS might guarantee only one guard page at the bottom of the stack, 635 and a page size can be as small as 4096 bytes. So we cannot safely 636 invoke alloca (N) if N exceeds 4096. Use a slightly smaller number 637 to allow for a few compiler-allocated temporary stack slots. */ 638 # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ 639 # endif 640 # else 641 # define YYSTACK_ALLOC YYMALLOC 642 # define YYSTACK_FREE YYFREE 643 # ifndef YYSTACK_ALLOC_MAXIMUM 644 # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM 645 # endif 646 # if (defined __cplusplus && ! defined EXIT_SUCCESS \ 647 && ! ((defined YYMALLOC || defined malloc) \ 648 && (defined YYFREE || defined free))) 649 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ 650 # ifndef EXIT_SUCCESS 651 # define EXIT_SUCCESS 0 652 # endif 653 # endif 654 # ifndef YYMALLOC 655 # define YYMALLOC malloc 656 # if ! defined malloc && ! defined EXIT_SUCCESS 657 void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ 658 # endif 659 # endif 660 # ifndef YYFREE 661 # define YYFREE free 662 # if ! defined free && ! defined EXIT_SUCCESS 663 void free (void *); /* INFRINGES ON USER NAME SPACE */ 664 # endif 665 # endif 666 # endif 667 #endif /* ! defined yyoverflow || YYERROR_VERBOSE */ 668 669 670 #if (! defined yyoverflow \ 671 && (! defined __cplusplus \ 672 || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) 673 674 /* A type that is properly aligned for any stack member. */ 675 union yyalloc 676 { 677 yytype_int16 yyss_alloc; 678 YYSTYPE yyvs_alloc; 679 }; 680 681 /* The size of the maximum gap between one aligned stack and the next. */ 682 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) 683 684 /* The size of an array large to enough to hold all stacks, each with 685 N elements. */ 686 # define YYSTACK_BYTES(N) \ 687 ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ 688 + YYSTACK_GAP_MAXIMUM) 689 690 # define YYCOPY_NEEDED 1 691 692 /* Relocate STACK from its old location to the new one. The 693 local variables YYSIZE and YYSTACKSIZE give the old and new number of 694 elements in the stack, and YYPTR gives the new location of the 695 stack. Advance YYPTR to a properly aligned location for the next 696 stack. */ 697 # define YYSTACK_RELOCATE(Stack_alloc, Stack) \ 698 do \ 699 { \ 700 YYSIZE_T yynewbytes; \ 701 YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ 702 Stack = &yyptr->Stack_alloc; \ 703 yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ 704 yyptr += yynewbytes / sizeof (*yyptr); \ 705 } \ 706 while (0) 707 708 #endif 709 710 #if defined YYCOPY_NEEDED && YYCOPY_NEEDED 711 /* Copy COUNT objects from SRC to DST. The source and destination do 712 not overlap. */ 713 # ifndef YYCOPY 714 # if defined __GNUC__ && 1 < __GNUC__ 715 # define YYCOPY(Dst, Src, Count) \ 716 __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src))) 717 # else 718 # define YYCOPY(Dst, Src, Count) \ 719 do \ 720 { \ 721 YYSIZE_T yyi; \ 722 for (yyi = 0; yyi < (Count); yyi++) \ 723 (Dst)[yyi] = (Src)[yyi]; \ 724 } \ 725 while (0) 726 # endif 727 # endif 728 #endif /* !YYCOPY_NEEDED */ 729 730 /* YYFINAL -- State number of the termination state. */ 731 #define YYFINAL 2 732 /* YYLAST -- Last index in YYTABLE. */ 733 #define YYLAST 319 734 735 /* YYNTOKENS -- Number of terminals. */ 736 #define YYNTOKENS 170 737 /* YYNNTS -- Number of nonterminals. */ 738 #define YYNNTS 175 739 /* YYNRULES -- Number of rules. */ 740 #define YYNRULES 335 741 /* YYNSTATES -- Number of states. */ 742 #define YYNSTATES 495 743 744 /* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned 745 by yylex, with out-of-bounds checking. */ 746 #define YYUNDEFTOK 2 747 #define YYMAXUTOK 424 748 749 #define YYTRANSLATE(YYX) \ 750 ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) 751 752 /* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM 753 as returned by yylex, without out-of-bounds checking. */ 754 static const yytype_uint8 yytranslate[] = 755 { 756 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 757 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 758 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 759 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 760 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 761 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 762 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 763 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 764 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 765 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 766 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 767 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 768 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 769 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 770 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 771 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 772 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 773 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 774 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 775 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 776 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 777 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 778 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 779 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 780 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 781 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, 782 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 783 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 784 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 785 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 786 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 787 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 788 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 789 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 790 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 791 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 792 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 793 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 794 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 795 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 796 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 797 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 798 165, 166, 167, 168, 169 799 }; 800 801 #if YYDEBUG 802 /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ 803 static const yytype_uint16 yyrline[] = 804 { 805 0, 131, 131, 131, 132, 132, 133, 133, 134, 134, 806 138, 143, 144, 145, 145, 145, 146, 146, 147, 147, 807 147, 148, 148, 149, 149, 149, 150, 150, 150, 151, 808 151, 152, 152, 153, 153, 154, 154, 155, 155, 156, 809 156, 157, 157, 158, 158, 159, 159, 159, 160, 160, 810 160, 161, 161, 161, 162, 162, 163, 163, 164, 164, 811 165, 165, 166, 166, 166, 167, 167, 168, 168, 169, 812 169, 169, 170, 170, 171, 171, 172, 172, 173, 173, 813 173, 174, 174, 175, 175, 176, 176, 177, 177, 178, 814 178, 179, 179, 179, 180, 180, 181, 181, 181, 182, 815 182, 182, 183, 183, 183, 184, 184, 184, 185, 185, 816 185, 186, 186, 186, 187, 187, 188, 188, 189, 189, 817 190, 190, 191, 191, 191, 192, 192, 193, 193, 194, 818 194, 195, 195, 196, 196, 196, 197, 199, 211, 212, 819 213, 213, 213, 213, 213, 215, 227, 228, 229, 229, 820 229, 229, 231, 240, 249, 260, 269, 278, 287, 300, 821 315, 324, 333, 342, 351, 360, 369, 378, 387, 396, 822 405, 414, 423, 432, 441, 448, 455, 464, 473, 487, 823 496, 505, 512, 519, 526, 534, 541, 548, 555, 562, 824 570, 578, 586, 593, 600, 609, 618, 625, 632, 640, 825 648, 658, 668, 678, 691, 702, 710, 723, 732, 741, 826 750, 760, 770, 778, 791, 800, 808, 817, 825, 838, 827 847, 854, 864, 874, 884, 894, 904, 914, 924, 934, 828 941, 948, 955, 964, 973, 982, 989, 999, 1016, 1023, 829 1041, 1054, 1067, 1076, 1085, 1094, 1103, 1113, 1123, 1132, 830 1141, 1148, 1157, 1166, 1175, 1184, 1192, 1205, 1213, 1237, 831 1244, 1259, 1269, 1279, 1286, 1293, 1302, 1316, 1335, 1344, 832 1352, 1365, 1378, 1391, 1400, 1410, 1420, 1427, 1434, 1443, 833 1453, 1463, 1470, 1477, 1486, 1491, 1492, 1493, 1493, 1493, 834 1494, 1494, 1494, 1495, 1495, 1497, 1507, 1516, 1523, 1533, 835 1540, 1547, 1554, 1561, 1566, 1567, 1568, 1568, 1569, 1569, 836 1570, 1570, 1571, 1572, 1573, 1574, 1575, 1576, 1578, 1586, 837 1593, 1601, 1609, 1616, 1623, 1632, 1641, 1650, 1659, 1668, 838 1677, 1682, 1683, 1684, 1686, 1692 839 }; 840 #endif 841 842 #if YYDEBUG || YYERROR_VERBOSE || 0 843 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. 844 First, the terminals, then, starting at YYNTOKENS, nonterminals. */ 845 static const char *const yytname[] = 846 { 847 "$end", "error", "$undefined", "SPACE", "LETTER", "NEWLINE", "COMMENT", 848 "COLON", "ANY", "ZONESTR", "STRING_ARG", "VAR_SERVER", "VAR_VERBOSITY", 849 "VAR_NUM_THREADS", "VAR_PORT", "VAR_OUTGOING_RANGE", "VAR_INTERFACE", 850 "VAR_DO_IP4", "VAR_DO_IP6", "VAR_DO_UDP", "VAR_DO_TCP", "VAR_TCP_MSS", 851 "VAR_OUTGOING_TCP_MSS", "VAR_CHROOT", "VAR_USERNAME", "VAR_DIRECTORY", 852 "VAR_LOGFILE", "VAR_PIDFILE", "VAR_MSG_CACHE_SIZE", 853 "VAR_MSG_CACHE_SLABS", "VAR_NUM_QUERIES_PER_THREAD", 854 "VAR_RRSET_CACHE_SIZE", "VAR_RRSET_CACHE_SLABS", "VAR_OUTGOING_NUM_TCP", 855 "VAR_INFRA_HOST_TTL", "VAR_INFRA_LAME_TTL", "VAR_INFRA_CACHE_SLABS", 856 "VAR_INFRA_CACHE_NUMHOSTS", "VAR_INFRA_CACHE_LAME_SIZE", "VAR_NAME", 857 "VAR_STUB_ZONE", "VAR_STUB_HOST", "VAR_STUB_ADDR", 858 "VAR_TARGET_FETCH_POLICY", "VAR_HARDEN_SHORT_BUFSIZE", 859 "VAR_HARDEN_LARGE_QUERIES", "VAR_FORWARD_ZONE", "VAR_FORWARD_HOST", 860 "VAR_FORWARD_ADDR", "VAR_DO_NOT_QUERY_ADDRESS", "VAR_HIDE_IDENTITY", 861 "VAR_HIDE_VERSION", "VAR_IDENTITY", "VAR_VERSION", "VAR_HARDEN_GLUE", 862 "VAR_MODULE_CONF", "VAR_TRUST_ANCHOR_FILE", "VAR_TRUST_ANCHOR", 863 "VAR_VAL_OVERRIDE_DATE", "VAR_BOGUS_TTL", "VAR_VAL_CLEAN_ADDITIONAL", 864 "VAR_VAL_PERMISSIVE_MODE", "VAR_INCOMING_NUM_TCP", "VAR_MSG_BUFFER_SIZE", 865 "VAR_KEY_CACHE_SIZE", "VAR_KEY_CACHE_SLABS", "VAR_TRUSTED_KEYS_FILE", 866 "VAR_VAL_NSEC3_KEYSIZE_ITERATIONS", "VAR_USE_SYSLOG", 867 "VAR_OUTGOING_INTERFACE", "VAR_ROOT_HINTS", "VAR_DO_NOT_QUERY_LOCALHOST", 868 "VAR_CACHE_MAX_TTL", "VAR_HARDEN_DNSSEC_STRIPPED", "VAR_ACCESS_CONTROL", 869 "VAR_LOCAL_ZONE", "VAR_LOCAL_DATA", "VAR_INTERFACE_AUTOMATIC", 870 "VAR_STATISTICS_INTERVAL", "VAR_DO_DAEMONIZE", "VAR_USE_CAPS_FOR_ID", 871 "VAR_STATISTICS_CUMULATIVE", "VAR_OUTGOING_PORT_PERMIT", 872 "VAR_OUTGOING_PORT_AVOID", "VAR_DLV_ANCHOR_FILE", "VAR_DLV_ANCHOR", 873 "VAR_NEG_CACHE_SIZE", "VAR_HARDEN_REFERRAL_PATH", "VAR_PRIVATE_ADDRESS", 874 "VAR_PRIVATE_DOMAIN", "VAR_REMOTE_CONTROL", "VAR_CONTROL_ENABLE", 875 "VAR_CONTROL_INTERFACE", "VAR_CONTROL_PORT", "VAR_SERVER_KEY_FILE", 876 "VAR_SERVER_CERT_FILE", "VAR_CONTROL_KEY_FILE", "VAR_CONTROL_CERT_FILE", 877 "VAR_CONTROL_USE_CERT", "VAR_EXTENDED_STATISTICS", "VAR_LOCAL_DATA_PTR", 878 "VAR_JOSTLE_TIMEOUT", "VAR_STUB_PRIME", "VAR_UNWANTED_REPLY_THRESHOLD", 879 "VAR_LOG_TIME_ASCII", "VAR_DOMAIN_INSECURE", "VAR_PYTHON", 880 "VAR_PYTHON_SCRIPT", "VAR_VAL_SIG_SKEW_MIN", "VAR_VAL_SIG_SKEW_MAX", 881 "VAR_CACHE_MIN_TTL", "VAR_VAL_LOG_LEVEL", "VAR_AUTO_TRUST_ANCHOR_FILE", 882 "VAR_KEEP_MISSING", "VAR_ADD_HOLDDOWN", "VAR_DEL_HOLDDOWN", 883 "VAR_SO_RCVBUF", "VAR_EDNS_BUFFER_SIZE", "VAR_PREFETCH", 884 "VAR_PREFETCH_KEY", "VAR_SO_SNDBUF", "VAR_SO_REUSEPORT", 885 "VAR_HARDEN_BELOW_NXDOMAIN", "VAR_IGNORE_CD_FLAG", "VAR_LOG_QUERIES", 886 "VAR_TCP_UPSTREAM", "VAR_SSL_UPSTREAM", "VAR_SSL_SERVICE_KEY", 887 "VAR_SSL_SERVICE_PEM", "VAR_SSL_PORT", "VAR_FORWARD_FIRST", 888 "VAR_STUB_FIRST", "VAR_MINIMAL_RESPONSES", "VAR_RRSET_ROUNDROBIN", 889 "VAR_MAX_UDP_SIZE", "VAR_DELAY_CLOSE", "VAR_UNBLOCK_LAN_ZONES", 890 "VAR_INSECURE_LAN_ZONES", "VAR_INFRA_CACHE_MIN_RTT", "VAR_DNS64_PREFIX", 891 "VAR_DNS64_SYNTHALL", "VAR_DNSTAP", "VAR_DNSTAP_ENABLE", 892 "VAR_DNSTAP_SOCKET_PATH", "VAR_DNSTAP_SEND_IDENTITY", 893 "VAR_DNSTAP_SEND_VERSION", "VAR_DNSTAP_IDENTITY", "VAR_DNSTAP_VERSION", 894 "VAR_DNSTAP_LOG_RESOLVER_QUERY_MESSAGES", 895 "VAR_DNSTAP_LOG_RESOLVER_RESPONSE_MESSAGES", 896 "VAR_DNSTAP_LOG_CLIENT_QUERY_MESSAGES", 897 "VAR_DNSTAP_LOG_CLIENT_RESPONSE_MESSAGES", 898 "VAR_DNSTAP_LOG_FORWARDER_QUERY_MESSAGES", 899 "VAR_DNSTAP_LOG_FORWARDER_RESPONSE_MESSAGES", 900 "VAR_HARDEN_ALGO_DOWNGRADE", "VAR_IP_TRANSPARENT", 901 "VAR_DISABLE_DNSSEC_LAME_CHECK", "VAR_RATELIMIT", "VAR_RATELIMIT_SLABS", 902 "VAR_RATELIMIT_SIZE", "VAR_RATELIMIT_FOR_DOMAIN", 903 "VAR_RATELIMIT_BELOW_DOMAIN", "VAR_RATELIMIT_FACTOR", 904 "VAR_CAPS_WHITELIST", "VAR_CACHE_MAX_NEGATIVE_TTL", 905 "VAR_PERMIT_SMALL_HOLDDOWN", "VAR_QNAME_MINIMISATION", "VAR_IP_FREEBIND", 906 "VAR_DEFINE_TAG", "VAR_LOCAL_ZONE_TAG", "$accept", "toplevelvars", 907 "toplevelvar", "serverstart", "contents_server", "content_server", 908 "stubstart", "contents_stub", "content_stub", "forwardstart", 909 "contents_forward", "content_forward", "server_num_threads", 910 "server_verbosity", "server_statistics_interval", 911 "server_statistics_cumulative", "server_extended_statistics", 912 "server_port", "server_interface", "server_outgoing_interface", 913 "server_outgoing_range", "server_outgoing_port_permit", 914 "server_outgoing_port_avoid", "server_outgoing_num_tcp", 915 "server_incoming_num_tcp", "server_interface_automatic", "server_do_ip4", 916 "server_do_ip6", "server_do_udp", "server_do_tcp", "server_tcp_mss", 917 "server_outgoing_tcp_mss", "server_tcp_upstream", "server_ssl_upstream", 918 "server_ssl_service_key", "server_ssl_service_pem", "server_ssl_port", 919 "server_do_daemonize", "server_use_syslog", "server_log_time_ascii", 920 "server_log_queries", "server_chroot", "server_username", 921 "server_directory", "server_logfile", "server_pidfile", 922 "server_root_hints", "server_dlv_anchor_file", "server_dlv_anchor", 923 "server_auto_trust_anchor_file", "server_trust_anchor_file", 924 "server_trusted_keys_file", "server_trust_anchor", 925 "server_domain_insecure", "server_hide_identity", "server_hide_version", 926 "server_identity", "server_version", "server_so_rcvbuf", 927 "server_so_sndbuf", "server_so_reuseport", "server_ip_transparent", 928 "server_ip_freebind", "server_edns_buffer_size", 929 "server_msg_buffer_size", "server_msg_cache_size", 930 "server_msg_cache_slabs", "server_num_queries_per_thread", 931 "server_jostle_timeout", "server_delay_close", 932 "server_unblock_lan_zones", "server_insecure_lan_zones", 933 "server_rrset_cache_size", "server_rrset_cache_slabs", 934 "server_infra_host_ttl", "server_infra_lame_ttl", 935 "server_infra_cache_numhosts", "server_infra_cache_lame_size", 936 "server_infra_cache_slabs", "server_infra_cache_min_rtt", 937 "server_target_fetch_policy", "server_harden_short_bufsize", 938 "server_harden_large_queries", "server_harden_glue", 939 "server_harden_dnssec_stripped", "server_harden_below_nxdomain", 940 "server_harden_referral_path", "server_harden_algo_downgrade", 941 "server_use_caps_for_id", "server_caps_whitelist", 942 "server_private_address", "server_private_domain", "server_prefetch", 943 "server_prefetch_key", "server_unwanted_reply_threshold", 944 "server_do_not_query_address", "server_do_not_query_localhost", 945 "server_access_control", "server_module_conf", 946 "server_val_override_date", "server_val_sig_skew_min", 947 "server_val_sig_skew_max", "server_cache_max_ttl", 948 "server_cache_max_negative_ttl", "server_cache_min_ttl", 949 "server_bogus_ttl", "server_val_clean_additional", 950 "server_val_permissive_mode", "server_ignore_cd_flag", 951 "server_val_log_level", "server_val_nsec3_keysize_iterations", 952 "server_add_holddown", "server_del_holddown", "server_keep_missing", 953 "server_permit_small_holddown", "server_key_cache_size", 954 "server_key_cache_slabs", "server_neg_cache_size", "server_local_zone", 955 "server_local_data", "server_local_data_ptr", "server_minimal_responses", 956 "server_rrset_roundrobin", "server_max_udp_size", "server_dns64_prefix", 957 "server_dns64_synthall", "server_define_tag", "server_local_zone_tag", 958 "server_ratelimit", "server_ratelimit_size", "server_ratelimit_slabs", 959 "server_ratelimit_for_domain", "server_ratelimit_below_domain", 960 "server_ratelimit_factor", "server_qname_minimisation", "stub_name", 961 "stub_host", "stub_addr", "stub_first", "stub_prime", "forward_name", 962 "forward_host", "forward_addr", "forward_first", "rcstart", 963 "contents_rc", "content_rc", "rc_control_enable", "rc_control_port", 964 "rc_control_interface", "rc_control_use_cert", "rc_server_key_file", 965 "rc_server_cert_file", "rc_control_key_file", "rc_control_cert_file", 966 "dtstart", "contents_dt", "content_dt", "dt_dnstap_enable", 967 "dt_dnstap_socket_path", "dt_dnstap_send_identity", 968 "dt_dnstap_send_version", "dt_dnstap_identity", "dt_dnstap_version", 969 "dt_dnstap_log_resolver_query_messages", 970 "dt_dnstap_log_resolver_response_messages", 971 "dt_dnstap_log_client_query_messages", 972 "dt_dnstap_log_client_response_messages", 973 "dt_dnstap_log_forwarder_query_messages", 974 "dt_dnstap_log_forwarder_response_messages", "pythonstart", 975 "contents_py", "content_py", "py_script", 976 "server_disable_dnssec_lame_check", YY_NULLPTR 977 }; 978 #endif 979 980 # ifdef YYPRINT 981 /* YYTOKNUM[NUM] -- (External) token number corresponding to the 982 (internal) symbol number NUM (which must be that of a token). */ 983 static const yytype_uint16 yytoknum[] = 984 { 985 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 986 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 987 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, 988 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, 989 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, 990 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, 991 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, 992 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, 993 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, 994 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, 995 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, 996 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, 997 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, 998 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, 999 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, 1000 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, 1001 415, 416, 417, 418, 419, 420, 421, 422, 423, 424 1002 }; 1003 # endif 1004 1005 #define YYPACT_NINF -81 1006 1007 #define yypact_value_is_default(Yystate) \ 1008 (!!((Yystate) == (-81))) 1009 1010 #define YYTABLE_NINF -1 1011 1012 #define yytable_value_is_error(Yytable_value) \ 1013 0 1014 1015 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing 1016 STATE-NUM. */ 1017 static const yytype_int16 yypact[] = 1018 { 1019 -81, 118, -81, -81, -81, -81, -81, -81, -81, -81, 1020 -81, -81, -81, -81, -81, -81, -12, 39, 47, 40, 1021 36, -80, 18, 19, 20, 24, 25, 26, 69, 72, 1022 73, 74, 75, 80, 109, 120, 129, 130, 149, 150, 1023 151, 152, 153, 155, 156, 157, 158, 159, 161, 162, 1024 163, 164, 165, 166, 180, 181, 182, 183, 184, 185, 1025 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 1026 196, 197, 199, 200, 201, 202, 203, 204, 205, 206, 1027 207, 208, 209, 210, 211, 212, 213, 215, 216, 217, 1028 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, 1029 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 1030 238, 239, 240, 241, 242, 243, 244, 245, 246, 247, 1031 248, 250, 251, 252, 253, 254, 255, 256, 257, 258, 1032 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 1033 269, 270, 271, 272, 273, 274, -81, -81, -81, -81, 1034 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1035 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1036 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1037 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1038 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1039 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1040 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1041 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1042 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1043 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1044 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1045 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1046 -81, 275, 276, 277, 278, 279, -81, -81, -81, -81, 1047 -81, -81, 280, 281, 282, 283, -81, -81, -81, -81, 1048 -81, 284, 285, 286, 287, 288, 289, 290, 291, -81, 1049 -81, -81, -81, -81, -81, -81, -81, -81, 292, 293, 1050 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, 1051 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1052 -81, -81, -81, 304, -81, -81, -81, -81, -81, -81, 1053 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1054 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1055 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1056 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1057 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1058 -81, 305, 306, -81, -81, -81, -81, -81, -81, -81, 1059 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1060 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1061 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1062 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1063 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1064 307, 308, -81, -81, -81, -81, -81, -81, -81, 309, 1065 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1066 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1067 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1068 -81, -81, -81, -81, -81 1069 }; 1070 1071 /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. 1072 Performed when YYTABLE does not specify something else to do. Zero 1073 means the default is an error. */ 1074 static const yytype_uint16 yydefact[] = 1075 { 1076 2, 0, 1, 10, 137, 145, 284, 330, 303, 3, 1077 12, 139, 147, 286, 305, 332, 4, 5, 6, 8, 1078 9, 7, 0, 0, 0, 0, 0, 0, 0, 0, 1079 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1080 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1081 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1082 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1083 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1084 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1085 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1086 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1087 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1088 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1089 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1090 0, 0, 0, 0, 0, 0, 11, 13, 14, 72, 1091 75, 84, 15, 23, 63, 16, 76, 77, 34, 56, 1092 71, 17, 18, 19, 20, 21, 22, 106, 107, 108, 1093 109, 110, 73, 62, 88, 105, 24, 25, 26, 27, 1094 28, 64, 78, 79, 94, 50, 60, 51, 89, 44, 1095 45, 46, 47, 98, 102, 114, 122, 133, 99, 57, 1096 29, 30, 31, 86, 115, 116, 117, 32, 33, 35, 1097 36, 38, 39, 37, 120, 40, 41, 42, 48, 67, 1098 103, 81, 121, 74, 129, 82, 83, 100, 101, 87, 1099 43, 65, 68, 49, 52, 90, 91, 66, 130, 92, 1100 53, 54, 55, 104, 93, 61, 95, 96, 97, 131, 1101 58, 59, 80, 69, 70, 85, 111, 112, 113, 118, 1102 119, 134, 135, 123, 125, 124, 126, 127, 128, 132, 1103 136, 0, 0, 0, 0, 0, 138, 140, 141, 142, 1104 144, 143, 0, 0, 0, 0, 146, 148, 149, 150, 1105 151, 0, 0, 0, 0, 0, 0, 0, 0, 285, 1106 287, 289, 288, 294, 290, 291, 292, 293, 0, 0, 1107 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1108 304, 306, 307, 308, 309, 310, 311, 312, 313, 314, 1109 315, 316, 317, 0, 331, 333, 153, 152, 157, 160, 1110 158, 166, 167, 168, 169, 170, 171, 181, 182, 183, 1111 184, 185, 205, 206, 207, 212, 213, 163, 214, 215, 1112 218, 216, 217, 220, 221, 222, 235, 194, 195, 196, 1113 197, 223, 238, 190, 192, 239, 245, 246, 247, 164, 1114 204, 255, 256, 191, 250, 178, 159, 186, 236, 242, 1115 224, 0, 0, 259, 165, 154, 177, 228, 155, 161, 1116 162, 187, 188, 257, 226, 230, 231, 156, 260, 208, 1117 234, 179, 193, 240, 241, 244, 249, 189, 253, 251, 1118 252, 198, 203, 232, 233, 199, 200, 225, 248, 180, 1119 172, 173, 174, 175, 176, 261, 262, 263, 209, 210, 1120 211, 219, 264, 265, 227, 201, 335, 268, 270, 269, 1121 0, 0, 273, 229, 243, 254, 274, 202, 266, 0, 1122 275, 276, 277, 279, 278, 280, 281, 282, 283, 295, 1123 297, 296, 299, 300, 301, 302, 298, 318, 319, 320, 1124 321, 322, 323, 324, 325, 326, 327, 328, 329, 334, 1125 237, 258, 271, 272, 267 1126 }; 1127 1128 /* YYPGOTO[NTERM-NUM]. */ 1129 static const yytype_int8 yypgoto[] = 1130 { 1131 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1132 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1133 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1134 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1135 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1136 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1137 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1138 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1139 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1140 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1141 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1142 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1143 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1144 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1145 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1146 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1147 -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, 1148 -81, -81, -81, -81, -81 1149 }; 1150 1151 /* YYDEFGOTO[NTERM-NUM]. */ 1152 static const yytype_int16 yydefgoto[] = 1153 { 1154 -1, 1, 9, 10, 16, 146, 11, 17, 276, 12, 1155 18, 286, 147, 148, 149, 150, 151, 152, 153, 154, 1156 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 1157 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 1158 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, 1159 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 1160 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 1161 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 1162 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, 1163 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 1164 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 1165 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 1166 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, 1167 265, 266, 267, 268, 269, 277, 278, 279, 280, 281, 1168 287, 288, 289, 290, 13, 19, 299, 300, 301, 302, 1169 303, 304, 305, 306, 307, 14, 20, 320, 321, 322, 1170 323, 324, 325, 326, 327, 328, 329, 330, 331, 332, 1171 15, 21, 334, 335, 270 1172 }; 1173 1174 /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If 1175 positive, shift that token. If negative, reduce the rule whose 1176 number is the opposite. If YYTABLE_NINF, syntax error. */ 1177 static const yytype_uint16 yytable[] = 1178 { 1179 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 1180 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 1181 42, 43, 44, 45, 46, 47, 48, 333, 336, 337, 1182 338, 49, 50, 51, 339, 340, 341, 52, 53, 54, 1183 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1184 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 1185 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 1186 85, 86, 87, 88, 89, 90, 91, 92, 271, 342, 1187 272, 273, 343, 344, 345, 346, 282, 93, 94, 95, 1188 347, 96, 97, 98, 283, 284, 99, 100, 101, 102, 1189 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 1190 113, 114, 115, 116, 117, 118, 119, 120, 2, 348, 1191 121, 122, 123, 124, 125, 126, 127, 128, 129, 3, 1192 349, 291, 292, 293, 294, 295, 296, 297, 298, 350, 1193 351, 274, 130, 131, 132, 133, 134, 135, 136, 137, 1194 138, 139, 140, 141, 142, 143, 144, 145, 4, 352, 1195 353, 354, 355, 356, 5, 357, 358, 359, 360, 361, 1196 275, 362, 363, 364, 365, 366, 367, 285, 308, 309, 1197 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 1198 368, 369, 370, 371, 372, 373, 374, 375, 376, 377, 1199 378, 379, 380, 381, 382, 383, 384, 385, 6, 386, 1200 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, 1201 397, 398, 399, 400, 7, 401, 402, 403, 404, 405, 1202 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, 1203 416, 417, 418, 419, 420, 421, 422, 423, 424, 425, 1204 426, 427, 428, 429, 430, 431, 432, 433, 434, 8, 1205 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, 1206 445, 446, 447, 448, 449, 450, 451, 452, 453, 454, 1207 455, 456, 457, 458, 459, 460, 461, 462, 463, 464, 1208 465, 466, 467, 468, 469, 470, 471, 472, 473, 474, 1209 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, 1210 485, 486, 487, 488, 489, 490, 491, 492, 493, 494 1211 }; 1212 1213 static const yytype_uint8 yycheck[] = 1214 { 1215 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 1216 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 1217 32, 33, 34, 35, 36, 37, 38, 107, 10, 10, 1218 10, 43, 44, 45, 10, 10, 10, 49, 50, 51, 1219 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 1220 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 1221 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 1222 82, 83, 84, 85, 86, 87, 88, 89, 39, 10, 1223 41, 42, 10, 10, 10, 10, 39, 99, 100, 101, 1224 10, 103, 104, 105, 47, 48, 108, 109, 110, 111, 1225 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 1226 122, 123, 124, 125, 126, 127, 128, 129, 0, 10, 1227 132, 133, 134, 135, 136, 137, 138, 139, 140, 11, 1228 10, 91, 92, 93, 94, 95, 96, 97, 98, 10, 1229 10, 102, 154, 155, 156, 157, 158, 159, 160, 161, 1230 162, 163, 164, 165, 166, 167, 168, 169, 40, 10, 1231 10, 10, 10, 10, 46, 10, 10, 10, 10, 10, 1232 131, 10, 10, 10, 10, 10, 10, 130, 142, 143, 1233 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 1234 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1235 10, 10, 10, 10, 10, 10, 10, 10, 90, 10, 1236 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1237 10, 10, 10, 10, 106, 10, 10, 10, 10, 10, 1238 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1239 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1240 10, 10, 10, 10, 10, 10, 10, 10, 10, 141, 1241 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1242 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1243 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1244 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1245 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1246 10, 10, 10, 10, 10, 10, 10, 10, 10, 10 1247 }; 1248 1249 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing 1250 symbol of state STATE-NUM. */ 1251 static const yytype_uint16 yystos[] = 1252 { 1253 0, 171, 0, 11, 40, 46, 90, 106, 141, 172, 1254 173, 176, 179, 314, 325, 340, 174, 177, 180, 315, 1255 326, 341, 12, 13, 14, 15, 16, 17, 18, 19, 1256 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 1257 30, 31, 32, 33, 34, 35, 36, 37, 38, 43, 1258 44, 45, 49, 50, 51, 52, 53, 54, 55, 56, 1259 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 1260 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 1261 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 1262 87, 88, 89, 99, 100, 101, 103, 104, 105, 108, 1263 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 1264 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 1265 129, 132, 133, 134, 135, 136, 137, 138, 139, 140, 1266 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, 1267 164, 165, 166, 167, 168, 169, 175, 182, 183, 184, 1268 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 1269 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 1270 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 1271 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, 1272 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 1273 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 1274 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 1275 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, 1276 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 1277 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, 1278 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, 1279 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, 1280 344, 39, 41, 42, 102, 131, 178, 305, 306, 307, 1281 308, 309, 39, 47, 48, 130, 181, 310, 311, 312, 1282 313, 91, 92, 93, 94, 95, 96, 97, 98, 316, 1283 317, 318, 319, 320, 321, 322, 323, 324, 142, 143, 1284 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 1285 327, 328, 329, 330, 331, 332, 333, 334, 335, 336, 1286 337, 338, 339, 107, 342, 343, 10, 10, 10, 10, 1287 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1288 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1289 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1290 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1291 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1292 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1293 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1294 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1295 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1296 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1297 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1298 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1299 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1300 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1301 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 1302 10, 10, 10, 10, 10 1303 }; 1304 1305 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ 1306 static const yytype_uint16 yyr1[] = 1307 { 1308 0, 170, 171, 171, 172, 172, 172, 172, 172, 172, 1309 173, 174, 174, 175, 175, 175, 175, 175, 175, 175, 1310 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1311 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1312 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1313 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1314 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1315 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1316 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1317 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1318 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1319 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1320 175, 175, 175, 175, 175, 175, 175, 175, 175, 175, 1321 175, 175, 175, 175, 175, 175, 175, 176, 177, 177, 1322 178, 178, 178, 178, 178, 179, 180, 180, 181, 181, 1323 181, 181, 182, 183, 184, 185, 186, 187, 188, 189, 1324 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 1325 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 1326 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 1327 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 1328 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, 1329 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 1330 250, 251, 252, 253, 254, 255, 256, 257, 258, 259, 1331 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 1332 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 1333 280, 281, 282, 283, 284, 285, 286, 287, 288, 289, 1334 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, 1335 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, 1336 310, 311, 312, 313, 314, 315, 315, 316, 316, 316, 1337 316, 316, 316, 316, 316, 317, 318, 319, 320, 321, 1338 322, 323, 324, 325, 326, 326, 327, 327, 327, 327, 1339 327, 327, 327, 327, 327, 327, 327, 327, 328, 329, 1340 330, 331, 332, 333, 334, 335, 336, 337, 338, 339, 1341 340, 341, 341, 342, 343, 344 1342 }; 1343 1344 /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ 1345 static const yytype_uint8 yyr2[] = 1346 { 1347 0, 2, 0, 2, 2, 2, 2, 2, 2, 2, 1348 1, 2, 0, 1, 1, 1, 1, 1, 1, 1, 1349 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1350 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1351 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1352 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1353 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1354 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1355 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1356 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1357 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1358 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1359 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1360 1, 1, 1, 1, 1, 1, 1, 1, 2, 0, 1361 1, 1, 1, 1, 1, 1, 2, 0, 1, 1, 1362 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 1363 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1364 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1365 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1366 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1367 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1368 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1369 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1370 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 1371 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1372 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 1373 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 1374 2, 3, 3, 2, 2, 2, 2, 2, 2, 2, 1375 2, 2, 2, 2, 1, 2, 0, 1, 1, 1, 1376 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 1377 2, 2, 2, 1, 2, 0, 1, 1, 1, 1, 1378 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1379 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1380 1, 2, 0, 1, 2, 2 1381 }; 1382 1383 1384 #define yyerrok (yyerrstatus = 0) 1385 #define yyclearin (yychar = YYEMPTY) 1386 #define YYEMPTY (-2) 1387 #define YYEOF 0 1388 1389 #define YYACCEPT goto yyacceptlab 1390 #define YYABORT goto yyabortlab 1391 #define YYERROR goto yyerrorlab 1392 1393 1394 #define YYRECOVERING() (!!yyerrstatus) 1395 1396 #define YYBACKUP(Token, Value) \ 1397 do \ 1398 if (yychar == YYEMPTY) \ 1399 { \ 1400 yychar = (Token); \ 1401 yylval = (Value); \ 1402 YYPOPSTACK (yylen); \ 1403 yystate = *yyssp; \ 1404 goto yybackup; \ 1405 } \ 1406 else \ 1407 { \ 1408 yyerror (YY_("syntax error: cannot back up")); \ 1409 YYERROR; \ 1410 } \ 1411 while (0) 1412 1413 /* Error token number */ 1414 #define YYTERROR 1 1415 #define YYERRCODE 256 1416 1417 1418 1419 /* Enable debugging if requested. */ 1420 #if YYDEBUG 1421 1422 # ifndef YYFPRINTF 1423 # include <stdio.h> /* INFRINGES ON USER NAME SPACE */ 1424 # define YYFPRINTF fprintf 1425 # endif 1426 1427 # define YYDPRINTF(Args) \ 1428 do { \ 1429 if (yydebug) \ 1430 YYFPRINTF Args; \ 1431 } while (0) 1432 1433 /* This macro is provided for backward compatibility. */ 1434 #ifndef YY_LOCATION_PRINT 1435 # define YY_LOCATION_PRINT(File, Loc) ((void) 0) 1436 #endif 1437 1438 1439 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ 1440 do { \ 1441 if (yydebug) \ 1442 { \ 1443 YYFPRINTF (stderr, "%s ", Title); \ 1444 yy_symbol_print (stderr, \ 1445 Type, Value); \ 1446 YYFPRINTF (stderr, "\n"); \ 1447 } \ 1448 } while (0) 1449 1450 1451 /*----------------------------------------. 1452 | Print this symbol's value on YYOUTPUT. | 1453 `----------------------------------------*/ 1454 1455 static void 1456 yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) 1457 { 1458 FILE *yyo = yyoutput; 1459 YYUSE (yyo); 1460 if (!yyvaluep) 1461 return; 1462 # ifdef YYPRINT 1463 if (yytype < YYNTOKENS) 1464 YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); 1465 # endif 1466 YYUSE (yytype); 1467 } 1468 1469 1470 /*--------------------------------. 1471 | Print this symbol on YYOUTPUT. | 1472 `--------------------------------*/ 1473 1474 static void 1475 yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) 1476 { 1477 YYFPRINTF (yyoutput, "%s %s (", 1478 yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]); 1479 1480 yy_symbol_value_print (yyoutput, yytype, yyvaluep); 1481 YYFPRINTF (yyoutput, ")"); 1482 } 1483 1484 /*------------------------------------------------------------------. 1485 | yy_stack_print -- Print the state stack from its BOTTOM up to its | 1486 | TOP (included). | 1487 `------------------------------------------------------------------*/ 1488 1489 static void 1490 yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) 1491 { 1492 YYFPRINTF (stderr, "Stack now"); 1493 for (; yybottom <= yytop; yybottom++) 1494 { 1495 int yybot = *yybottom; 1496 YYFPRINTF (stderr, " %d", yybot); 1497 } 1498 YYFPRINTF (stderr, "\n"); 1499 } 1500 1501 # define YY_STACK_PRINT(Bottom, Top) \ 1502 do { \ 1503 if (yydebug) \ 1504 yy_stack_print ((Bottom), (Top)); \ 1505 } while (0) 1506 1507 1508 /*------------------------------------------------. 1509 | Report that the YYRULE is going to be reduced. | 1510 `------------------------------------------------*/ 1511 1512 static void 1513 yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule) 1514 { 1515 unsigned long int yylno = yyrline[yyrule]; 1516 int yynrhs = yyr2[yyrule]; 1517 int yyi; 1518 YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", 1519 yyrule - 1, yylno); 1520 /* The symbols being reduced. */ 1521 for (yyi = 0; yyi < yynrhs; yyi++) 1522 { 1523 YYFPRINTF (stderr, " $%d = ", yyi + 1); 1524 yy_symbol_print (stderr, 1525 yystos[yyssp[yyi + 1 - yynrhs]], 1526 &(yyvsp[(yyi + 1) - (yynrhs)]) 1527 ); 1528 YYFPRINTF (stderr, "\n"); 1529 } 1530 } 1531 1532 # define YY_REDUCE_PRINT(Rule) \ 1533 do { \ 1534 if (yydebug) \ 1535 yy_reduce_print (yyssp, yyvsp, Rule); \ 1536 } while (0) 1537 1538 /* Nonzero means print parse trace. It is left uninitialized so that 1539 multiple parsers can coexist. */ 1540 int yydebug; 1541 #else /* !YYDEBUG */ 1542 # define YYDPRINTF(Args) 1543 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) 1544 # define YY_STACK_PRINT(Bottom, Top) 1545 # define YY_REDUCE_PRINT(Rule) 1546 #endif /* !YYDEBUG */ 1547 1548 1549 /* YYINITDEPTH -- initial size of the parser's stacks. */ 1550 #ifndef YYINITDEPTH 1551 # define YYINITDEPTH 200 1552 #endif 1553 1554 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only 1555 if the built-in stack extension method is used). 1556 1557 Do not make this value too large; the results are undefined if 1558 YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) 1559 evaluated with infinite-precision integer arithmetic. */ 1560 1561 #ifndef YYMAXDEPTH 1562 # define YYMAXDEPTH 10000 1563 #endif 1564 1565 1566 #if YYERROR_VERBOSE 1567 1568 # ifndef yystrlen 1569 # if defined __GLIBC__ && defined _STRING_H 1570 # define yystrlen strlen 1571 # else 1572 /* Return the length of YYSTR. */ 1573 static YYSIZE_T 1574 yystrlen (const char *yystr) 1575 { 1576 YYSIZE_T yylen; 1577 for (yylen = 0; yystr[yylen]; yylen++) 1578 continue; 1579 return yylen; 1580 } 1581 # endif 1582 # endif 1583 1584 # ifndef yystpcpy 1585 # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE 1586 # define yystpcpy stpcpy 1587 # else 1588 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in 1589 YYDEST. */ 1590 static char * 1591 yystpcpy (char *yydest, const char *yysrc) 1592 { 1593 char *yyd = yydest; 1594 const char *yys = yysrc; 1595 1596 while ((*yyd++ = *yys++) != '\0') 1597 continue; 1598 1599 return yyd - 1; 1600 } 1601 # endif 1602 # endif 1603 1604 # ifndef yytnamerr 1605 /* Copy to YYRES the contents of YYSTR after stripping away unnecessary 1606 quotes and backslashes, so that it's suitable for yyerror. The 1607 heuristic is that double-quoting is unnecessary unless the string 1608 contains an apostrophe, a comma, or backslash (other than 1609 backslash-backslash). YYSTR is taken from yytname. If YYRES is 1610 null, do not copy; instead, return the length of what the result 1611 would have been. */ 1612 static YYSIZE_T 1613 yytnamerr (char *yyres, const char *yystr) 1614 { 1615 if (*yystr == '"') 1616 { 1617 YYSIZE_T yyn = 0; 1618 char const *yyp = yystr; 1619 1620 for (;;) 1621 switch (*++yyp) 1622 { 1623 case '\'': 1624 case ',': 1625 goto do_not_strip_quotes; 1626 1627 case '\\': 1628 if (*++yyp != '\\') 1629 goto do_not_strip_quotes; 1630 /* Fall through. */ 1631 default: 1632 if (yyres) 1633 yyres[yyn] = *yyp; 1634 yyn++; 1635 break; 1636 1637 case '"': 1638 if (yyres) 1639 yyres[yyn] = '\0'; 1640 return yyn; 1641 } 1642 do_not_strip_quotes: ; 1643 } 1644 1645 if (! yyres) 1646 return yystrlen (yystr); 1647 1648 return yystpcpy (yyres, yystr) - yyres; 1649 } 1650 # endif 1651 1652 /* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message 1653 about the unexpected token YYTOKEN for the state stack whose top is 1654 YYSSP. 1655 1656 Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is 1657 not large enough to hold the message. In that case, also set 1658 *YYMSG_ALLOC to the required number of bytes. Return 2 if the 1659 required number of bytes is too large to store. */ 1660 static int 1661 yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, 1662 yytype_int16 *yyssp, int yytoken) 1663 { 1664 YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]); 1665 YYSIZE_T yysize = yysize0; 1666 enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; 1667 /* Internationalized format string. */ 1668 const char *yyformat = YY_NULLPTR; 1669 /* Arguments of yyformat. */ 1670 char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; 1671 /* Number of reported tokens (one for the "unexpected", one per 1672 "expected"). */ 1673 int yycount = 0; 1674 1675 /* There are many possibilities here to consider: 1676 - If this state is a consistent state with a default action, then 1677 the only way this function was invoked is if the default action 1678 is an error action. In that case, don't check for expected 1679 tokens because there are none. 1680 - The only way there can be no lookahead present (in yychar) is if 1681 this state is a consistent state with a default action. Thus, 1682 detecting the absence of a lookahead is sufficient to determine 1683 that there is no unexpected or expected token to report. In that 1684 case, just report a simple "syntax error". 1685 - Don't assume there isn't a lookahead just because this state is a 1686 consistent state with a default action. There might have been a 1687 previous inconsistent state, consistent state with a non-default 1688 action, or user semantic action that manipulated yychar. 1689 - Of course, the expected token list depends on states to have 1690 correct lookahead information, and it depends on the parser not 1691 to perform extra reductions after fetching a lookahead from the 1692 scanner and before detecting a syntax error. Thus, state merging 1693 (from LALR or IELR) and default reductions corrupt the expected 1694 token list. However, the list is correct for canonical LR with 1695 one exception: it will still contain any token that will not be 1696 accepted due to an error action in a later state. 1697 */ 1698 if (yytoken != YYEMPTY) 1699 { 1700 int yyn = yypact[*yyssp]; 1701 yyarg[yycount++] = yytname[yytoken]; 1702 if (!yypact_value_is_default (yyn)) 1703 { 1704 /* Start YYX at -YYN if negative to avoid negative indexes in 1705 YYCHECK. In other words, skip the first -YYN actions for 1706 this state because they are default actions. */ 1707 int yyxbegin = yyn < 0 ? -yyn : 0; 1708 /* Stay within bounds of both yycheck and yytname. */ 1709 int yychecklim = YYLAST - yyn + 1; 1710 int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; 1711 int yyx; 1712 1713 for (yyx = yyxbegin; yyx < yyxend; ++yyx) 1714 if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR 1715 && !yytable_value_is_error (yytable[yyx + yyn])) 1716 { 1717 if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) 1718 { 1719 yycount = 1; 1720 yysize = yysize0; 1721 break; 1722 } 1723 yyarg[yycount++] = yytname[yyx]; 1724 { 1725 YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]); 1726 if (! (yysize <= yysize1 1727 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) 1728 return 2; 1729 yysize = yysize1; 1730 } 1731 } 1732 } 1733 } 1734 1735 switch (yycount) 1736 { 1737 # define YYCASE_(N, S) \ 1738 case N: \ 1739 yyformat = S; \ 1740 break 1741 YYCASE_(0, YY_("syntax error")); 1742 YYCASE_(1, YY_("syntax error, unexpected %s")); 1743 YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); 1744 YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); 1745 YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); 1746 YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); 1747 # undef YYCASE_ 1748 } 1749 1750 { 1751 YYSIZE_T yysize1 = yysize + yystrlen (yyformat); 1752 if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) 1753 return 2; 1754 yysize = yysize1; 1755 } 1756 1757 if (*yymsg_alloc < yysize) 1758 { 1759 *yymsg_alloc = 2 * yysize; 1760 if (! (yysize <= *yymsg_alloc 1761 && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) 1762 *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; 1763 return 1; 1764 } 1765 1766 /* Avoid sprintf, as that infringes on the user's name space. 1767 Don't have undefined behavior even if the translation 1768 produced a string with the wrong number of "%s"s. */ 1769 { 1770 char *yyp = *yymsg; 1771 int yyi = 0; 1772 while ((*yyp = *yyformat) != '\0') 1773 if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) 1774 { 1775 yyp += yytnamerr (yyp, yyarg[yyi++]); 1776 yyformat += 2; 1777 } 1778 else 1779 { 1780 yyp++; 1781 yyformat++; 1782 } 1783 } 1784 return 0; 1785 } 1786 #endif /* YYERROR_VERBOSE */ 1787 1788 /*-----------------------------------------------. 1789 | Release the memory associated to this symbol. | 1790 `-----------------------------------------------*/ 1791 1792 static void 1793 yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) 1794 { 1795 YYUSE (yyvaluep); 1796 if (!yymsg) 1797 yymsg = "Deleting"; 1798 YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); 1799 1800 YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN 1801 YYUSE (yytype); 1802 YY_IGNORE_MAYBE_UNINITIALIZED_END 1803 } 1804 1805 1806 1807 1808 /* The lookahead symbol. */ 1809 int yychar; 1810 1811 /* The semantic value of the lookahead symbol. */ 1812 YYSTYPE yylval; 1813 /* Number of syntax errors so far. */ 1814 int yynerrs; 1815 1816 1817 /*----------. 1818 | yyparse. | 1819 `----------*/ 1820 1821 int 1822 yyparse (void) 1823 { 1824 int yystate; 1825 /* Number of tokens to shift before error messages enabled. */ 1826 int yyerrstatus; 1827 1828 /* The stacks and their tools: 1829 'yyss': related to states. 1830 'yyvs': related to semantic values. 1831 1832 Refer to the stacks through separate pointers, to allow yyoverflow 1833 to reallocate them elsewhere. */ 1834 1835 /* The state stack. */ 1836 yytype_int16 yyssa[YYINITDEPTH]; 1837 yytype_int16 *yyss; 1838 yytype_int16 *yyssp; 1839 1840 /* The semantic value stack. */ 1841 YYSTYPE yyvsa[YYINITDEPTH]; 1842 YYSTYPE *yyvs; 1843 YYSTYPE *yyvsp; 1844 1845 YYSIZE_T yystacksize; 1846 1847 int yyn; 1848 int yyresult; 1849 /* Lookahead token as an internal (translated) token number. */ 1850 int yytoken = 0; 1851 /* The variables used to return semantic value and location from the 1852 action routines. */ 1853 YYSTYPE yyval; 1854 1855 #if YYERROR_VERBOSE 1856 /* Buffer for error messages, and its allocated size. */ 1857 char yymsgbuf[128]; 1858 char *yymsg = yymsgbuf; 1859 YYSIZE_T yymsg_alloc = sizeof yymsgbuf; 1860 #endif 1861 1862 #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) 1863 1864 /* The number of symbols on the RHS of the reduced rule. 1865 Keep to zero when no symbol should be popped. */ 1866 int yylen = 0; 1867 1868 yyssp = yyss = yyssa; 1869 yyvsp = yyvs = yyvsa; 1870 yystacksize = YYINITDEPTH; 1871 1872 YYDPRINTF ((stderr, "Starting parse\n")); 1873 1874 yystate = 0; 1875 yyerrstatus = 0; 1876 yynerrs = 0; 1877 yychar = YYEMPTY; /* Cause a token to be read. */ 1878 goto yysetstate; 1879 1880 /*------------------------------------------------------------. 1881 | yynewstate -- Push a new state, which is found in yystate. | 1882 `------------------------------------------------------------*/ 1883 yynewstate: 1884 /* In all cases, when you get here, the value and location stacks 1885 have just been pushed. So pushing a state here evens the stacks. */ 1886 yyssp++; 1887 1888 yysetstate: 1889 *yyssp = yystate; 1890 1891 if (yyss + yystacksize - 1 <= yyssp) 1892 { 1893 /* Get the current used size of the three stacks, in elements. */ 1894 YYSIZE_T yysize = yyssp - yyss + 1; 1895 1896 #ifdef yyoverflow 1897 { 1898 /* Give user a chance to reallocate the stack. Use copies of 1899 these so that the &'s don't force the real ones into 1900 memory. */ 1901 YYSTYPE *yyvs1 = yyvs; 1902 yytype_int16 *yyss1 = yyss; 1903 1904 /* Each stack pointer address is followed by the size of the 1905 data in use in that stack, in bytes. This used to be a 1906 conditional around just the two extra args, but that might 1907 be undefined if yyoverflow is a macro. */ 1908 yyoverflow (YY_("memory exhausted"), 1909 &yyss1, yysize * sizeof (*yyssp), 1910 &yyvs1, yysize * sizeof (*yyvsp), 1911 &yystacksize); 1912 1913 yyss = yyss1; 1914 yyvs = yyvs1; 1915 } 1916 #else /* no yyoverflow */ 1917 # ifndef YYSTACK_RELOCATE 1918 goto yyexhaustedlab; 1919 # else 1920 /* Extend the stack our own way. */ 1921 if (YYMAXDEPTH <= yystacksize) 1922 goto yyexhaustedlab; 1923 yystacksize *= 2; 1924 if (YYMAXDEPTH < yystacksize) 1925 yystacksize = YYMAXDEPTH; 1926 1927 { 1928 yytype_int16 *yyss1 = yyss; 1929 union yyalloc *yyptr = 1930 (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); 1931 if (! yyptr) 1932 goto yyexhaustedlab; 1933 YYSTACK_RELOCATE (yyss_alloc, yyss); 1934 YYSTACK_RELOCATE (yyvs_alloc, yyvs); 1935 # undef YYSTACK_RELOCATE 1936 if (yyss1 != yyssa) 1937 YYSTACK_FREE (yyss1); 1938 } 1939 # endif 1940 #endif /* no yyoverflow */ 1941 1942 yyssp = yyss + yysize - 1; 1943 yyvsp = yyvs + yysize - 1; 1944 1945 YYDPRINTF ((stderr, "Stack size increased to %lu\n", 1946 (unsigned long int) yystacksize)); 1947 1948 if (yyss + yystacksize - 1 <= yyssp) 1949 YYABORT; 1950 } 1951 1952 YYDPRINTF ((stderr, "Entering state %d\n", yystate)); 1953 1954 if (yystate == YYFINAL) 1955 YYACCEPT; 1956 1957 goto yybackup; 1958 1959 /*-----------. 1960 | yybackup. | 1961 `-----------*/ 1962 yybackup: 1963 1964 /* Do appropriate processing given the current state. Read a 1965 lookahead token if we need one and don't already have one. */ 1966 1967 /* First try to decide what to do without reference to lookahead token. */ 1968 yyn = yypact[yystate]; 1969 if (yypact_value_is_default (yyn)) 1970 goto yydefault; 1971 1972 /* Not known => get a lookahead token if don't already have one. */ 1973 1974 /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ 1975 if (yychar == YYEMPTY) 1976 { 1977 YYDPRINTF ((stderr, "Reading a token: ")); 1978 yychar = yylex (); 1979 } 1980 1981 if (yychar <= YYEOF) 1982 { 1983 yychar = yytoken = YYEOF; 1984 YYDPRINTF ((stderr, "Now at end of input.\n")); 1985 } 1986 else 1987 { 1988 yytoken = YYTRANSLATE (yychar); 1989 YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); 1990 } 1991 1992 /* If the proper action on seeing token YYTOKEN is to reduce or to 1993 detect an error, take that action. */ 1994 yyn += yytoken; 1995 if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) 1996 goto yydefault; 1997 yyn = yytable[yyn]; 1998 if (yyn <= 0) 1999 { 2000 if (yytable_value_is_error (yyn)) 2001 goto yyerrlab; 2002 yyn = -yyn; 2003 goto yyreduce; 2004 } 2005 2006 /* Count tokens shifted since error; after three, turn off error 2007 status. */ 2008 if (yyerrstatus) 2009 yyerrstatus--; 2010 2011 /* Shift the lookahead token. */ 2012 YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); 2013 2014 /* Discard the shifted token. */ 2015 yychar = YYEMPTY; 2016 2017 yystate = yyn; 2018 YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN 2019 *++yyvsp = yylval; 2020 YY_IGNORE_MAYBE_UNINITIALIZED_END 2021 2022 goto yynewstate; 2023 2024 2025 /*-----------------------------------------------------------. 2026 | yydefault -- do the default action for the current state. | 2027 `-----------------------------------------------------------*/ 2028 yydefault: 2029 yyn = yydefact[yystate]; 2030 if (yyn == 0) 2031 goto yyerrlab; 2032 goto yyreduce; 2033 2034 2035 /*-----------------------------. 2036 | yyreduce -- Do a reduction. | 2037 `-----------------------------*/ 2038 yyreduce: 2039 /* yyn is the number of a rule to reduce with. */ 2040 yylen = yyr2[yyn]; 2041 2042 /* If YYLEN is nonzero, implement the default value of the action: 2043 '$$ = $1'. 2044 2045 Otherwise, the following line sets YYVAL to garbage. 2046 This behavior is undocumented and Bison 2047 users should not rely upon it. Assigning to YYVAL 2048 unconditionally makes the parser a bit smaller, and it avoids a 2049 GCC warning that YYVAL may be used uninitialized. */ 2050 yyval = yyvsp[1-yylen]; 2051 2052 2053 YY_REDUCE_PRINT (yyn); 2054 switch (yyn) 2055 { 2056 case 10: 2057 #line 139 "util/configparser.y" /* yacc.c:1646 */ 2058 { 2059 OUTYY(("\nP(server:)\n")); 2060 } 2061 #line 2062 "util/configparser.c" /* yacc.c:1646 */ 2062 break; 2063 2064 case 137: 2065 #line 200 "util/configparser.y" /* yacc.c:1646 */ 2066 { 2067 struct config_stub* s; 2068 OUTYY(("\nP(stub_zone:)\n")); 2069 s = (struct config_stub*)calloc(1, sizeof(struct config_stub)); 2070 if(s) { 2071 s->next = cfg_parser->cfg->stubs; 2072 cfg_parser->cfg->stubs = s; 2073 } else 2074 yyerror("out of memory"); 2075 } 2076 #line 2077 "util/configparser.c" /* yacc.c:1646 */ 2077 break; 2078 2079 case 145: 2080 #line 216 "util/configparser.y" /* yacc.c:1646 */ 2081 { 2082 struct config_stub* s; 2083 OUTYY(("\nP(forward_zone:)\n")); 2084 s = (struct config_stub*)calloc(1, sizeof(struct config_stub)); 2085 if(s) { 2086 s->next = cfg_parser->cfg->forwards; 2087 cfg_parser->cfg->forwards = s; 2088 } else 2089 yyerror("out of memory"); 2090 } 2091 #line 2092 "util/configparser.c" /* yacc.c:1646 */ 2092 break; 2093 2094 case 152: 2095 #line 232 "util/configparser.y" /* yacc.c:1646 */ 2096 { 2097 OUTYY(("P(server_num_threads:%s)\n", (yyvsp[0].str))); 2098 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2099 yyerror("number expected"); 2100 else cfg_parser->cfg->num_threads = atoi((yyvsp[0].str)); 2101 free((yyvsp[0].str)); 2102 } 2103 #line 2104 "util/configparser.c" /* yacc.c:1646 */ 2104 break; 2105 2106 case 153: 2107 #line 241 "util/configparser.y" /* yacc.c:1646 */ 2108 { 2109 OUTYY(("P(server_verbosity:%s)\n", (yyvsp[0].str))); 2110 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2111 yyerror("number expected"); 2112 else cfg_parser->cfg->verbosity = atoi((yyvsp[0].str)); 2113 free((yyvsp[0].str)); 2114 } 2115 #line 2116 "util/configparser.c" /* yacc.c:1646 */ 2116 break; 2117 2118 case 154: 2119 #line 250 "util/configparser.y" /* yacc.c:1646 */ 2120 { 2121 OUTYY(("P(server_statistics_interval:%s)\n", (yyvsp[0].str))); 2122 if(strcmp((yyvsp[0].str), "") == 0 || strcmp((yyvsp[0].str), "0") == 0) 2123 cfg_parser->cfg->stat_interval = 0; 2124 else if(atoi((yyvsp[0].str)) == 0) 2125 yyerror("number expected"); 2126 else cfg_parser->cfg->stat_interval = atoi((yyvsp[0].str)); 2127 free((yyvsp[0].str)); 2128 } 2129 #line 2130 "util/configparser.c" /* yacc.c:1646 */ 2130 break; 2131 2132 case 155: 2133 #line 261 "util/configparser.y" /* yacc.c:1646 */ 2134 { 2135 OUTYY(("P(server_statistics_cumulative:%s)\n", (yyvsp[0].str))); 2136 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2137 yyerror("expected yes or no."); 2138 else cfg_parser->cfg->stat_cumulative = (strcmp((yyvsp[0].str), "yes")==0); 2139 free((yyvsp[0].str)); 2140 } 2141 #line 2142 "util/configparser.c" /* yacc.c:1646 */ 2142 break; 2143 2144 case 156: 2145 #line 270 "util/configparser.y" /* yacc.c:1646 */ 2146 { 2147 OUTYY(("P(server_extended_statistics:%s)\n", (yyvsp[0].str))); 2148 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2149 yyerror("expected yes or no."); 2150 else cfg_parser->cfg->stat_extended = (strcmp((yyvsp[0].str), "yes")==0); 2151 free((yyvsp[0].str)); 2152 } 2153 #line 2154 "util/configparser.c" /* yacc.c:1646 */ 2154 break; 2155 2156 case 157: 2157 #line 279 "util/configparser.y" /* yacc.c:1646 */ 2158 { 2159 OUTYY(("P(server_port:%s)\n", (yyvsp[0].str))); 2160 if(atoi((yyvsp[0].str)) == 0) 2161 yyerror("port number expected"); 2162 else cfg_parser->cfg->port = atoi((yyvsp[0].str)); 2163 free((yyvsp[0].str)); 2164 } 2165 #line 2166 "util/configparser.c" /* yacc.c:1646 */ 2166 break; 2167 2168 case 158: 2169 #line 288 "util/configparser.y" /* yacc.c:1646 */ 2170 { 2171 OUTYY(("P(server_interface:%s)\n", (yyvsp[0].str))); 2172 if(cfg_parser->cfg->num_ifs == 0) 2173 cfg_parser->cfg->ifs = calloc(1, sizeof(char*)); 2174 else cfg_parser->cfg->ifs = realloc(cfg_parser->cfg->ifs, 2175 (cfg_parser->cfg->num_ifs+1)*sizeof(char*)); 2176 if(!cfg_parser->cfg->ifs) 2177 yyerror("out of memory"); 2178 else 2179 cfg_parser->cfg->ifs[cfg_parser->cfg->num_ifs++] = (yyvsp[0].str); 2180 } 2181 #line 2182 "util/configparser.c" /* yacc.c:1646 */ 2182 break; 2183 2184 case 159: 2185 #line 301 "util/configparser.y" /* yacc.c:1646 */ 2186 { 2187 OUTYY(("P(server_outgoing_interface:%s)\n", (yyvsp[0].str))); 2188 if(cfg_parser->cfg->num_out_ifs == 0) 2189 cfg_parser->cfg->out_ifs = calloc(1, sizeof(char*)); 2190 else cfg_parser->cfg->out_ifs = realloc( 2191 cfg_parser->cfg->out_ifs, 2192 (cfg_parser->cfg->num_out_ifs+1)*sizeof(char*)); 2193 if(!cfg_parser->cfg->out_ifs) 2194 yyerror("out of memory"); 2195 else 2196 cfg_parser->cfg->out_ifs[ 2197 cfg_parser->cfg->num_out_ifs++] = (yyvsp[0].str); 2198 } 2199 #line 2200 "util/configparser.c" /* yacc.c:1646 */ 2200 break; 2201 2202 case 160: 2203 #line 316 "util/configparser.y" /* yacc.c:1646 */ 2204 { 2205 OUTYY(("P(server_outgoing_range:%s)\n", (yyvsp[0].str))); 2206 if(atoi((yyvsp[0].str)) == 0) 2207 yyerror("number expected"); 2208 else cfg_parser->cfg->outgoing_num_ports = atoi((yyvsp[0].str)); 2209 free((yyvsp[0].str)); 2210 } 2211 #line 2212 "util/configparser.c" /* yacc.c:1646 */ 2212 break; 2213 2214 case 161: 2215 #line 325 "util/configparser.y" /* yacc.c:1646 */ 2216 { 2217 OUTYY(("P(server_outgoing_port_permit:%s)\n", (yyvsp[0].str))); 2218 if(!cfg_mark_ports((yyvsp[0].str), 1, 2219 cfg_parser->cfg->outgoing_avail_ports, 65536)) 2220 yyerror("port number or range (\"low-high\") expected"); 2221 free((yyvsp[0].str)); 2222 } 2223 #line 2224 "util/configparser.c" /* yacc.c:1646 */ 2224 break; 2225 2226 case 162: 2227 #line 334 "util/configparser.y" /* yacc.c:1646 */ 2228 { 2229 OUTYY(("P(server_outgoing_port_avoid:%s)\n", (yyvsp[0].str))); 2230 if(!cfg_mark_ports((yyvsp[0].str), 0, 2231 cfg_parser->cfg->outgoing_avail_ports, 65536)) 2232 yyerror("port number or range (\"low-high\") expected"); 2233 free((yyvsp[0].str)); 2234 } 2235 #line 2236 "util/configparser.c" /* yacc.c:1646 */ 2236 break; 2237 2238 case 163: 2239 #line 343 "util/configparser.y" /* yacc.c:1646 */ 2240 { 2241 OUTYY(("P(server_outgoing_num_tcp:%s)\n", (yyvsp[0].str))); 2242 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2243 yyerror("number expected"); 2244 else cfg_parser->cfg->outgoing_num_tcp = atoi((yyvsp[0].str)); 2245 free((yyvsp[0].str)); 2246 } 2247 #line 2248 "util/configparser.c" /* yacc.c:1646 */ 2248 break; 2249 2250 case 164: 2251 #line 352 "util/configparser.y" /* yacc.c:1646 */ 2252 { 2253 OUTYY(("P(server_incoming_num_tcp:%s)\n", (yyvsp[0].str))); 2254 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2255 yyerror("number expected"); 2256 else cfg_parser->cfg->incoming_num_tcp = atoi((yyvsp[0].str)); 2257 free((yyvsp[0].str)); 2258 } 2259 #line 2260 "util/configparser.c" /* yacc.c:1646 */ 2260 break; 2261 2262 case 165: 2263 #line 361 "util/configparser.y" /* yacc.c:1646 */ 2264 { 2265 OUTYY(("P(server_interface_automatic:%s)\n", (yyvsp[0].str))); 2266 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2267 yyerror("expected yes or no."); 2268 else cfg_parser->cfg->if_automatic = (strcmp((yyvsp[0].str), "yes")==0); 2269 free((yyvsp[0].str)); 2270 } 2271 #line 2272 "util/configparser.c" /* yacc.c:1646 */ 2272 break; 2273 2274 case 166: 2275 #line 370 "util/configparser.y" /* yacc.c:1646 */ 2276 { 2277 OUTYY(("P(server_do_ip4:%s)\n", (yyvsp[0].str))); 2278 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2279 yyerror("expected yes or no."); 2280 else cfg_parser->cfg->do_ip4 = (strcmp((yyvsp[0].str), "yes")==0); 2281 free((yyvsp[0].str)); 2282 } 2283 #line 2284 "util/configparser.c" /* yacc.c:1646 */ 2284 break; 2285 2286 case 167: 2287 #line 379 "util/configparser.y" /* yacc.c:1646 */ 2288 { 2289 OUTYY(("P(server_do_ip6:%s)\n", (yyvsp[0].str))); 2290 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2291 yyerror("expected yes or no."); 2292 else cfg_parser->cfg->do_ip6 = (strcmp((yyvsp[0].str), "yes")==0); 2293 free((yyvsp[0].str)); 2294 } 2295 #line 2296 "util/configparser.c" /* yacc.c:1646 */ 2296 break; 2297 2298 case 168: 2299 #line 388 "util/configparser.y" /* yacc.c:1646 */ 2300 { 2301 OUTYY(("P(server_do_udp:%s)\n", (yyvsp[0].str))); 2302 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2303 yyerror("expected yes or no."); 2304 else cfg_parser->cfg->do_udp = (strcmp((yyvsp[0].str), "yes")==0); 2305 free((yyvsp[0].str)); 2306 } 2307 #line 2308 "util/configparser.c" /* yacc.c:1646 */ 2308 break; 2309 2310 case 169: 2311 #line 397 "util/configparser.y" /* yacc.c:1646 */ 2312 { 2313 OUTYY(("P(server_do_tcp:%s)\n", (yyvsp[0].str))); 2314 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2315 yyerror("expected yes or no."); 2316 else cfg_parser->cfg->do_tcp = (strcmp((yyvsp[0].str), "yes")==0); 2317 free((yyvsp[0].str)); 2318 } 2319 #line 2320 "util/configparser.c" /* yacc.c:1646 */ 2320 break; 2321 2322 case 170: 2323 #line 406 "util/configparser.y" /* yacc.c:1646 */ 2324 { 2325 OUTYY(("P(server_tcp_mss:%s)\n", (yyvsp[0].str))); 2326 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2327 yyerror("number expected"); 2328 else cfg_parser->cfg->tcp_mss = atoi((yyvsp[0].str)); 2329 free((yyvsp[0].str)); 2330 } 2331 #line 2332 "util/configparser.c" /* yacc.c:1646 */ 2332 break; 2333 2334 case 171: 2335 #line 415 "util/configparser.y" /* yacc.c:1646 */ 2336 { 2337 OUTYY(("P(server_outgoing_tcp_mss:%s)\n", (yyvsp[0].str))); 2338 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2339 yyerror("number expected"); 2340 else cfg_parser->cfg->outgoing_tcp_mss = atoi((yyvsp[0].str)); 2341 free((yyvsp[0].str)); 2342 } 2343 #line 2344 "util/configparser.c" /* yacc.c:1646 */ 2344 break; 2345 2346 case 172: 2347 #line 424 "util/configparser.y" /* yacc.c:1646 */ 2348 { 2349 OUTYY(("P(server_tcp_upstream:%s)\n", (yyvsp[0].str))); 2350 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2351 yyerror("expected yes or no."); 2352 else cfg_parser->cfg->tcp_upstream = (strcmp((yyvsp[0].str), "yes")==0); 2353 free((yyvsp[0].str)); 2354 } 2355 #line 2356 "util/configparser.c" /* yacc.c:1646 */ 2356 break; 2357 2358 case 173: 2359 #line 433 "util/configparser.y" /* yacc.c:1646 */ 2360 { 2361 OUTYY(("P(server_ssl_upstream:%s)\n", (yyvsp[0].str))); 2362 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2363 yyerror("expected yes or no."); 2364 else cfg_parser->cfg->ssl_upstream = (strcmp((yyvsp[0].str), "yes")==0); 2365 free((yyvsp[0].str)); 2366 } 2367 #line 2368 "util/configparser.c" /* yacc.c:1646 */ 2368 break; 2369 2370 case 174: 2371 #line 442 "util/configparser.y" /* yacc.c:1646 */ 2372 { 2373 OUTYY(("P(server_ssl_service_key:%s)\n", (yyvsp[0].str))); 2374 free(cfg_parser->cfg->ssl_service_key); 2375 cfg_parser->cfg->ssl_service_key = (yyvsp[0].str); 2376 } 2377 #line 2378 "util/configparser.c" /* yacc.c:1646 */ 2378 break; 2379 2380 case 175: 2381 #line 449 "util/configparser.y" /* yacc.c:1646 */ 2382 { 2383 OUTYY(("P(server_ssl_service_pem:%s)\n", (yyvsp[0].str))); 2384 free(cfg_parser->cfg->ssl_service_pem); 2385 cfg_parser->cfg->ssl_service_pem = (yyvsp[0].str); 2386 } 2387 #line 2388 "util/configparser.c" /* yacc.c:1646 */ 2388 break; 2389 2390 case 176: 2391 #line 456 "util/configparser.y" /* yacc.c:1646 */ 2392 { 2393 OUTYY(("P(server_ssl_port:%s)\n", (yyvsp[0].str))); 2394 if(atoi((yyvsp[0].str)) == 0) 2395 yyerror("port number expected"); 2396 else cfg_parser->cfg->ssl_port = atoi((yyvsp[0].str)); 2397 free((yyvsp[0].str)); 2398 } 2399 #line 2400 "util/configparser.c" /* yacc.c:1646 */ 2400 break; 2401 2402 case 177: 2403 #line 465 "util/configparser.y" /* yacc.c:1646 */ 2404 { 2405 OUTYY(("P(server_do_daemonize:%s)\n", (yyvsp[0].str))); 2406 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2407 yyerror("expected yes or no."); 2408 else cfg_parser->cfg->do_daemonize = (strcmp((yyvsp[0].str), "yes")==0); 2409 free((yyvsp[0].str)); 2410 } 2411 #line 2412 "util/configparser.c" /* yacc.c:1646 */ 2412 break; 2413 2414 case 178: 2415 #line 474 "util/configparser.y" /* yacc.c:1646 */ 2416 { 2417 OUTYY(("P(server_use_syslog:%s)\n", (yyvsp[0].str))); 2418 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2419 yyerror("expected yes or no."); 2420 else cfg_parser->cfg->use_syslog = (strcmp((yyvsp[0].str), "yes")==0); 2421 #if !defined(HAVE_SYSLOG_H) && !defined(UB_ON_WINDOWS) 2422 if(strcmp((yyvsp[0].str), "yes") == 0) 2423 yyerror("no syslog services are available. " 2424 "(reconfigure and compile to add)"); 2425 #endif 2426 free((yyvsp[0].str)); 2427 } 2428 #line 2429 "util/configparser.c" /* yacc.c:1646 */ 2429 break; 2430 2431 case 179: 2432 #line 488 "util/configparser.y" /* yacc.c:1646 */ 2433 { 2434 OUTYY(("P(server_log_time_ascii:%s)\n", (yyvsp[0].str))); 2435 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2436 yyerror("expected yes or no."); 2437 else cfg_parser->cfg->log_time_ascii = (strcmp((yyvsp[0].str), "yes")==0); 2438 free((yyvsp[0].str)); 2439 } 2440 #line 2441 "util/configparser.c" /* yacc.c:1646 */ 2441 break; 2442 2443 case 180: 2444 #line 497 "util/configparser.y" /* yacc.c:1646 */ 2445 { 2446 OUTYY(("P(server_log_queries:%s)\n", (yyvsp[0].str))); 2447 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2448 yyerror("expected yes or no."); 2449 else cfg_parser->cfg->log_queries = (strcmp((yyvsp[0].str), "yes")==0); 2450 free((yyvsp[0].str)); 2451 } 2452 #line 2453 "util/configparser.c" /* yacc.c:1646 */ 2453 break; 2454 2455 case 181: 2456 #line 506 "util/configparser.y" /* yacc.c:1646 */ 2457 { 2458 OUTYY(("P(server_chroot:%s)\n", (yyvsp[0].str))); 2459 free(cfg_parser->cfg->chrootdir); 2460 cfg_parser->cfg->chrootdir = (yyvsp[0].str); 2461 } 2462 #line 2463 "util/configparser.c" /* yacc.c:1646 */ 2463 break; 2464 2465 case 182: 2466 #line 513 "util/configparser.y" /* yacc.c:1646 */ 2467 { 2468 OUTYY(("P(server_username:%s)\n", (yyvsp[0].str))); 2469 free(cfg_parser->cfg->username); 2470 cfg_parser->cfg->username = (yyvsp[0].str); 2471 } 2472 #line 2473 "util/configparser.c" /* yacc.c:1646 */ 2473 break; 2474 2475 case 183: 2476 #line 520 "util/configparser.y" /* yacc.c:1646 */ 2477 { 2478 OUTYY(("P(server_directory:%s)\n", (yyvsp[0].str))); 2479 free(cfg_parser->cfg->directory); 2480 cfg_parser->cfg->directory = (yyvsp[0].str); 2481 } 2482 #line 2483 "util/configparser.c" /* yacc.c:1646 */ 2483 break; 2484 2485 case 184: 2486 #line 527 "util/configparser.y" /* yacc.c:1646 */ 2487 { 2488 OUTYY(("P(server_logfile:%s)\n", (yyvsp[0].str))); 2489 free(cfg_parser->cfg->logfile); 2490 cfg_parser->cfg->logfile = (yyvsp[0].str); 2491 cfg_parser->cfg->use_syslog = 0; 2492 } 2493 #line 2494 "util/configparser.c" /* yacc.c:1646 */ 2494 break; 2495 2496 case 185: 2497 #line 535 "util/configparser.y" /* yacc.c:1646 */ 2498 { 2499 OUTYY(("P(server_pidfile:%s)\n", (yyvsp[0].str))); 2500 free(cfg_parser->cfg->pidfile); 2501 cfg_parser->cfg->pidfile = (yyvsp[0].str); 2502 } 2503 #line 2504 "util/configparser.c" /* yacc.c:1646 */ 2504 break; 2505 2506 case 186: 2507 #line 542 "util/configparser.y" /* yacc.c:1646 */ 2508 { 2509 OUTYY(("P(server_root_hints:%s)\n", (yyvsp[0].str))); 2510 if(!cfg_strlist_insert(&cfg_parser->cfg->root_hints, (yyvsp[0].str))) 2511 yyerror("out of memory"); 2512 } 2513 #line 2514 "util/configparser.c" /* yacc.c:1646 */ 2514 break; 2515 2516 case 187: 2517 #line 549 "util/configparser.y" /* yacc.c:1646 */ 2518 { 2519 OUTYY(("P(server_dlv_anchor_file:%s)\n", (yyvsp[0].str))); 2520 free(cfg_parser->cfg->dlv_anchor_file); 2521 cfg_parser->cfg->dlv_anchor_file = (yyvsp[0].str); 2522 } 2523 #line 2524 "util/configparser.c" /* yacc.c:1646 */ 2524 break; 2525 2526 case 188: 2527 #line 556 "util/configparser.y" /* yacc.c:1646 */ 2528 { 2529 OUTYY(("P(server_dlv_anchor:%s)\n", (yyvsp[0].str))); 2530 if(!cfg_strlist_insert(&cfg_parser->cfg->dlv_anchor_list, (yyvsp[0].str))) 2531 yyerror("out of memory"); 2532 } 2533 #line 2534 "util/configparser.c" /* yacc.c:1646 */ 2534 break; 2535 2536 case 189: 2537 #line 563 "util/configparser.y" /* yacc.c:1646 */ 2538 { 2539 OUTYY(("P(server_auto_trust_anchor_file:%s)\n", (yyvsp[0].str))); 2540 if(!cfg_strlist_insert(&cfg_parser->cfg-> 2541 auto_trust_anchor_file_list, (yyvsp[0].str))) 2542 yyerror("out of memory"); 2543 } 2544 #line 2545 "util/configparser.c" /* yacc.c:1646 */ 2545 break; 2546 2547 case 190: 2548 #line 571 "util/configparser.y" /* yacc.c:1646 */ 2549 { 2550 OUTYY(("P(server_trust_anchor_file:%s)\n", (yyvsp[0].str))); 2551 if(!cfg_strlist_insert(&cfg_parser->cfg-> 2552 trust_anchor_file_list, (yyvsp[0].str))) 2553 yyerror("out of memory"); 2554 } 2555 #line 2556 "util/configparser.c" /* yacc.c:1646 */ 2556 break; 2557 2558 case 191: 2559 #line 579 "util/configparser.y" /* yacc.c:1646 */ 2560 { 2561 OUTYY(("P(server_trusted_keys_file:%s)\n", (yyvsp[0].str))); 2562 if(!cfg_strlist_insert(&cfg_parser->cfg-> 2563 trusted_keys_file_list, (yyvsp[0].str))) 2564 yyerror("out of memory"); 2565 } 2566 #line 2567 "util/configparser.c" /* yacc.c:1646 */ 2567 break; 2568 2569 case 192: 2570 #line 587 "util/configparser.y" /* yacc.c:1646 */ 2571 { 2572 OUTYY(("P(server_trust_anchor:%s)\n", (yyvsp[0].str))); 2573 if(!cfg_strlist_insert(&cfg_parser->cfg->trust_anchor_list, (yyvsp[0].str))) 2574 yyerror("out of memory"); 2575 } 2576 #line 2577 "util/configparser.c" /* yacc.c:1646 */ 2577 break; 2578 2579 case 193: 2580 #line 594 "util/configparser.y" /* yacc.c:1646 */ 2581 { 2582 OUTYY(("P(server_domain_insecure:%s)\n", (yyvsp[0].str))); 2583 if(!cfg_strlist_insert(&cfg_parser->cfg->domain_insecure, (yyvsp[0].str))) 2584 yyerror("out of memory"); 2585 } 2586 #line 2587 "util/configparser.c" /* yacc.c:1646 */ 2587 break; 2588 2589 case 194: 2590 #line 601 "util/configparser.y" /* yacc.c:1646 */ 2591 { 2592 OUTYY(("P(server_hide_identity:%s)\n", (yyvsp[0].str))); 2593 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2594 yyerror("expected yes or no."); 2595 else cfg_parser->cfg->hide_identity = (strcmp((yyvsp[0].str), "yes")==0); 2596 free((yyvsp[0].str)); 2597 } 2598 #line 2599 "util/configparser.c" /* yacc.c:1646 */ 2599 break; 2600 2601 case 195: 2602 #line 610 "util/configparser.y" /* yacc.c:1646 */ 2603 { 2604 OUTYY(("P(server_hide_version:%s)\n", (yyvsp[0].str))); 2605 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2606 yyerror("expected yes or no."); 2607 else cfg_parser->cfg->hide_version = (strcmp((yyvsp[0].str), "yes")==0); 2608 free((yyvsp[0].str)); 2609 } 2610 #line 2611 "util/configparser.c" /* yacc.c:1646 */ 2611 break; 2612 2613 case 196: 2614 #line 619 "util/configparser.y" /* yacc.c:1646 */ 2615 { 2616 OUTYY(("P(server_identity:%s)\n", (yyvsp[0].str))); 2617 free(cfg_parser->cfg->identity); 2618 cfg_parser->cfg->identity = (yyvsp[0].str); 2619 } 2620 #line 2621 "util/configparser.c" /* yacc.c:1646 */ 2621 break; 2622 2623 case 197: 2624 #line 626 "util/configparser.y" /* yacc.c:1646 */ 2625 { 2626 OUTYY(("P(server_version:%s)\n", (yyvsp[0].str))); 2627 free(cfg_parser->cfg->version); 2628 cfg_parser->cfg->version = (yyvsp[0].str); 2629 } 2630 #line 2631 "util/configparser.c" /* yacc.c:1646 */ 2631 break; 2632 2633 case 198: 2634 #line 633 "util/configparser.y" /* yacc.c:1646 */ 2635 { 2636 OUTYY(("P(server_so_rcvbuf:%s)\n", (yyvsp[0].str))); 2637 if(!cfg_parse_memsize((yyvsp[0].str), &cfg_parser->cfg->so_rcvbuf)) 2638 yyerror("buffer size expected"); 2639 free((yyvsp[0].str)); 2640 } 2641 #line 2642 "util/configparser.c" /* yacc.c:1646 */ 2642 break; 2643 2644 case 199: 2645 #line 641 "util/configparser.y" /* yacc.c:1646 */ 2646 { 2647 OUTYY(("P(server_so_sndbuf:%s)\n", (yyvsp[0].str))); 2648 if(!cfg_parse_memsize((yyvsp[0].str), &cfg_parser->cfg->so_sndbuf)) 2649 yyerror("buffer size expected"); 2650 free((yyvsp[0].str)); 2651 } 2652 #line 2653 "util/configparser.c" /* yacc.c:1646 */ 2653 break; 2654 2655 case 200: 2656 #line 649 "util/configparser.y" /* yacc.c:1646 */ 2657 { 2658 OUTYY(("P(server_so_reuseport:%s)\n", (yyvsp[0].str))); 2659 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2660 yyerror("expected yes or no."); 2661 else cfg_parser->cfg->so_reuseport = 2662 (strcmp((yyvsp[0].str), "yes")==0); 2663 free((yyvsp[0].str)); 2664 } 2665 #line 2666 "util/configparser.c" /* yacc.c:1646 */ 2666 break; 2667 2668 case 201: 2669 #line 659 "util/configparser.y" /* yacc.c:1646 */ 2670 { 2671 OUTYY(("P(server_ip_transparent:%s)\n", (yyvsp[0].str))); 2672 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2673 yyerror("expected yes or no."); 2674 else cfg_parser->cfg->ip_transparent = 2675 (strcmp((yyvsp[0].str), "yes")==0); 2676 free((yyvsp[0].str)); 2677 } 2678 #line 2679 "util/configparser.c" /* yacc.c:1646 */ 2679 break; 2680 2681 case 202: 2682 #line 669 "util/configparser.y" /* yacc.c:1646 */ 2683 { 2684 OUTYY(("P(server_ip_freebind:%s)\n", (yyvsp[0].str))); 2685 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2686 yyerror("expected yes or no."); 2687 else cfg_parser->cfg->ip_freebind = 2688 (strcmp((yyvsp[0].str), "yes")==0); 2689 free((yyvsp[0].str)); 2690 } 2691 #line 2692 "util/configparser.c" /* yacc.c:1646 */ 2692 break; 2693 2694 case 203: 2695 #line 679 "util/configparser.y" /* yacc.c:1646 */ 2696 { 2697 OUTYY(("P(server_edns_buffer_size:%s)\n", (yyvsp[0].str))); 2698 if(atoi((yyvsp[0].str)) == 0) 2699 yyerror("number expected"); 2700 else if (atoi((yyvsp[0].str)) < 12) 2701 yyerror("edns buffer size too small"); 2702 else if (atoi((yyvsp[0].str)) > 65535) 2703 cfg_parser->cfg->edns_buffer_size = 65535; 2704 else cfg_parser->cfg->edns_buffer_size = atoi((yyvsp[0].str)); 2705 free((yyvsp[0].str)); 2706 } 2707 #line 2708 "util/configparser.c" /* yacc.c:1646 */ 2708 break; 2709 2710 case 204: 2711 #line 692 "util/configparser.y" /* yacc.c:1646 */ 2712 { 2713 OUTYY(("P(server_msg_buffer_size:%s)\n", (yyvsp[0].str))); 2714 if(atoi((yyvsp[0].str)) == 0) 2715 yyerror("number expected"); 2716 else if (atoi((yyvsp[0].str)) < 4096) 2717 yyerror("message buffer size too small (use 4096)"); 2718 else cfg_parser->cfg->msg_buffer_size = atoi((yyvsp[0].str)); 2719 free((yyvsp[0].str)); 2720 } 2721 #line 2722 "util/configparser.c" /* yacc.c:1646 */ 2722 break; 2723 2724 case 205: 2725 #line 703 "util/configparser.y" /* yacc.c:1646 */ 2726 { 2727 OUTYY(("P(server_msg_cache_size:%s)\n", (yyvsp[0].str))); 2728 if(!cfg_parse_memsize((yyvsp[0].str), &cfg_parser->cfg->msg_cache_size)) 2729 yyerror("memory size expected"); 2730 free((yyvsp[0].str)); 2731 } 2732 #line 2733 "util/configparser.c" /* yacc.c:1646 */ 2733 break; 2734 2735 case 206: 2736 #line 711 "util/configparser.y" /* yacc.c:1646 */ 2737 { 2738 OUTYY(("P(server_msg_cache_slabs:%s)\n", (yyvsp[0].str))); 2739 if(atoi((yyvsp[0].str)) == 0) 2740 yyerror("number expected"); 2741 else { 2742 cfg_parser->cfg->msg_cache_slabs = atoi((yyvsp[0].str)); 2743 if(!is_pow2(cfg_parser->cfg->msg_cache_slabs)) 2744 yyerror("must be a power of 2"); 2745 } 2746 free((yyvsp[0].str)); 2747 } 2748 #line 2749 "util/configparser.c" /* yacc.c:1646 */ 2749 break; 2750 2751 case 207: 2752 #line 724 "util/configparser.y" /* yacc.c:1646 */ 2753 { 2754 OUTYY(("P(server_num_queries_per_thread:%s)\n", (yyvsp[0].str))); 2755 if(atoi((yyvsp[0].str)) == 0) 2756 yyerror("number expected"); 2757 else cfg_parser->cfg->num_queries_per_thread = atoi((yyvsp[0].str)); 2758 free((yyvsp[0].str)); 2759 } 2760 #line 2761 "util/configparser.c" /* yacc.c:1646 */ 2761 break; 2762 2763 case 208: 2764 #line 733 "util/configparser.y" /* yacc.c:1646 */ 2765 { 2766 OUTYY(("P(server_jostle_timeout:%s)\n", (yyvsp[0].str))); 2767 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2768 yyerror("number expected"); 2769 else cfg_parser->cfg->jostle_time = atoi((yyvsp[0].str)); 2770 free((yyvsp[0].str)); 2771 } 2772 #line 2773 "util/configparser.c" /* yacc.c:1646 */ 2773 break; 2774 2775 case 209: 2776 #line 742 "util/configparser.y" /* yacc.c:1646 */ 2777 { 2778 OUTYY(("P(server_delay_close:%s)\n", (yyvsp[0].str))); 2779 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2780 yyerror("number expected"); 2781 else cfg_parser->cfg->delay_close = atoi((yyvsp[0].str)); 2782 free((yyvsp[0].str)); 2783 } 2784 #line 2785 "util/configparser.c" /* yacc.c:1646 */ 2785 break; 2786 2787 case 210: 2788 #line 751 "util/configparser.y" /* yacc.c:1646 */ 2789 { 2790 OUTYY(("P(server_unblock_lan_zones:%s)\n", (yyvsp[0].str))); 2791 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2792 yyerror("expected yes or no."); 2793 else cfg_parser->cfg->unblock_lan_zones = 2794 (strcmp((yyvsp[0].str), "yes")==0); 2795 free((yyvsp[0].str)); 2796 } 2797 #line 2798 "util/configparser.c" /* yacc.c:1646 */ 2798 break; 2799 2800 case 211: 2801 #line 761 "util/configparser.y" /* yacc.c:1646 */ 2802 { 2803 OUTYY(("P(server_insecure_lan_zones:%s)\n", (yyvsp[0].str))); 2804 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2805 yyerror("expected yes or no."); 2806 else cfg_parser->cfg->insecure_lan_zones = 2807 (strcmp((yyvsp[0].str), "yes")==0); 2808 free((yyvsp[0].str)); 2809 } 2810 #line 2811 "util/configparser.c" /* yacc.c:1646 */ 2811 break; 2812 2813 case 212: 2814 #line 771 "util/configparser.y" /* yacc.c:1646 */ 2815 { 2816 OUTYY(("P(server_rrset_cache_size:%s)\n", (yyvsp[0].str))); 2817 if(!cfg_parse_memsize((yyvsp[0].str), &cfg_parser->cfg->rrset_cache_size)) 2818 yyerror("memory size expected"); 2819 free((yyvsp[0].str)); 2820 } 2821 #line 2822 "util/configparser.c" /* yacc.c:1646 */ 2822 break; 2823 2824 case 213: 2825 #line 779 "util/configparser.y" /* yacc.c:1646 */ 2826 { 2827 OUTYY(("P(server_rrset_cache_slabs:%s)\n", (yyvsp[0].str))); 2828 if(atoi((yyvsp[0].str)) == 0) 2829 yyerror("number expected"); 2830 else { 2831 cfg_parser->cfg->rrset_cache_slabs = atoi((yyvsp[0].str)); 2832 if(!is_pow2(cfg_parser->cfg->rrset_cache_slabs)) 2833 yyerror("must be a power of 2"); 2834 } 2835 free((yyvsp[0].str)); 2836 } 2837 #line 2838 "util/configparser.c" /* yacc.c:1646 */ 2838 break; 2839 2840 case 214: 2841 #line 792 "util/configparser.y" /* yacc.c:1646 */ 2842 { 2843 OUTYY(("P(server_infra_host_ttl:%s)\n", (yyvsp[0].str))); 2844 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2845 yyerror("number expected"); 2846 else cfg_parser->cfg->host_ttl = atoi((yyvsp[0].str)); 2847 free((yyvsp[0].str)); 2848 } 2849 #line 2850 "util/configparser.c" /* yacc.c:1646 */ 2850 break; 2851 2852 case 215: 2853 #line 801 "util/configparser.y" /* yacc.c:1646 */ 2854 { 2855 OUTYY(("P(server_infra_lame_ttl:%s)\n", (yyvsp[0].str))); 2856 verbose(VERB_DETAIL, "ignored infra-lame-ttl: %s (option " 2857 "removed, use infra-host-ttl)", (yyvsp[0].str)); 2858 free((yyvsp[0].str)); 2859 } 2860 #line 2861 "util/configparser.c" /* yacc.c:1646 */ 2861 break; 2862 2863 case 216: 2864 #line 809 "util/configparser.y" /* yacc.c:1646 */ 2865 { 2866 OUTYY(("P(server_infra_cache_numhosts:%s)\n", (yyvsp[0].str))); 2867 if(atoi((yyvsp[0].str)) == 0) 2868 yyerror("number expected"); 2869 else cfg_parser->cfg->infra_cache_numhosts = atoi((yyvsp[0].str)); 2870 free((yyvsp[0].str)); 2871 } 2872 #line 2873 "util/configparser.c" /* yacc.c:1646 */ 2873 break; 2874 2875 case 217: 2876 #line 818 "util/configparser.y" /* yacc.c:1646 */ 2877 { 2878 OUTYY(("P(server_infra_cache_lame_size:%s)\n", (yyvsp[0].str))); 2879 verbose(VERB_DETAIL, "ignored infra-cache-lame-size: %s " 2880 "(option removed, use infra-cache-numhosts)", (yyvsp[0].str)); 2881 free((yyvsp[0].str)); 2882 } 2883 #line 2884 "util/configparser.c" /* yacc.c:1646 */ 2884 break; 2885 2886 case 218: 2887 #line 826 "util/configparser.y" /* yacc.c:1646 */ 2888 { 2889 OUTYY(("P(server_infra_cache_slabs:%s)\n", (yyvsp[0].str))); 2890 if(atoi((yyvsp[0].str)) == 0) 2891 yyerror("number expected"); 2892 else { 2893 cfg_parser->cfg->infra_cache_slabs = atoi((yyvsp[0].str)); 2894 if(!is_pow2(cfg_parser->cfg->infra_cache_slabs)) 2895 yyerror("must be a power of 2"); 2896 } 2897 free((yyvsp[0].str)); 2898 } 2899 #line 2900 "util/configparser.c" /* yacc.c:1646 */ 2900 break; 2901 2902 case 219: 2903 #line 839 "util/configparser.y" /* yacc.c:1646 */ 2904 { 2905 OUTYY(("P(server_infra_cache_min_rtt:%s)\n", (yyvsp[0].str))); 2906 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 2907 yyerror("number expected"); 2908 else cfg_parser->cfg->infra_cache_min_rtt = atoi((yyvsp[0].str)); 2909 free((yyvsp[0].str)); 2910 } 2911 #line 2912 "util/configparser.c" /* yacc.c:1646 */ 2912 break; 2913 2914 case 220: 2915 #line 848 "util/configparser.y" /* yacc.c:1646 */ 2916 { 2917 OUTYY(("P(server_target_fetch_policy:%s)\n", (yyvsp[0].str))); 2918 free(cfg_parser->cfg->target_fetch_policy); 2919 cfg_parser->cfg->target_fetch_policy = (yyvsp[0].str); 2920 } 2921 #line 2922 "util/configparser.c" /* yacc.c:1646 */ 2922 break; 2923 2924 case 221: 2925 #line 855 "util/configparser.y" /* yacc.c:1646 */ 2926 { 2927 OUTYY(("P(server_harden_short_bufsize:%s)\n", (yyvsp[0].str))); 2928 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2929 yyerror("expected yes or no."); 2930 else cfg_parser->cfg->harden_short_bufsize = 2931 (strcmp((yyvsp[0].str), "yes")==0); 2932 free((yyvsp[0].str)); 2933 } 2934 #line 2935 "util/configparser.c" /* yacc.c:1646 */ 2935 break; 2936 2937 case 222: 2938 #line 865 "util/configparser.y" /* yacc.c:1646 */ 2939 { 2940 OUTYY(("P(server_harden_large_queries:%s)\n", (yyvsp[0].str))); 2941 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2942 yyerror("expected yes or no."); 2943 else cfg_parser->cfg->harden_large_queries = 2944 (strcmp((yyvsp[0].str), "yes")==0); 2945 free((yyvsp[0].str)); 2946 } 2947 #line 2948 "util/configparser.c" /* yacc.c:1646 */ 2948 break; 2949 2950 case 223: 2951 #line 875 "util/configparser.y" /* yacc.c:1646 */ 2952 { 2953 OUTYY(("P(server_harden_glue:%s)\n", (yyvsp[0].str))); 2954 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2955 yyerror("expected yes or no."); 2956 else cfg_parser->cfg->harden_glue = 2957 (strcmp((yyvsp[0].str), "yes")==0); 2958 free((yyvsp[0].str)); 2959 } 2960 #line 2961 "util/configparser.c" /* yacc.c:1646 */ 2961 break; 2962 2963 case 224: 2964 #line 885 "util/configparser.y" /* yacc.c:1646 */ 2965 { 2966 OUTYY(("P(server_harden_dnssec_stripped:%s)\n", (yyvsp[0].str))); 2967 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2968 yyerror("expected yes or no."); 2969 else cfg_parser->cfg->harden_dnssec_stripped = 2970 (strcmp((yyvsp[0].str), "yes")==0); 2971 free((yyvsp[0].str)); 2972 } 2973 #line 2974 "util/configparser.c" /* yacc.c:1646 */ 2974 break; 2975 2976 case 225: 2977 #line 895 "util/configparser.y" /* yacc.c:1646 */ 2978 { 2979 OUTYY(("P(server_harden_below_nxdomain:%s)\n", (yyvsp[0].str))); 2980 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2981 yyerror("expected yes or no."); 2982 else cfg_parser->cfg->harden_below_nxdomain = 2983 (strcmp((yyvsp[0].str), "yes")==0); 2984 free((yyvsp[0].str)); 2985 } 2986 #line 2987 "util/configparser.c" /* yacc.c:1646 */ 2987 break; 2988 2989 case 226: 2990 #line 905 "util/configparser.y" /* yacc.c:1646 */ 2991 { 2992 OUTYY(("P(server_harden_referral_path:%s)\n", (yyvsp[0].str))); 2993 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 2994 yyerror("expected yes or no."); 2995 else cfg_parser->cfg->harden_referral_path = 2996 (strcmp((yyvsp[0].str), "yes")==0); 2997 free((yyvsp[0].str)); 2998 } 2999 #line 3000 "util/configparser.c" /* yacc.c:1646 */ 3000 break; 3001 3002 case 227: 3003 #line 915 "util/configparser.y" /* yacc.c:1646 */ 3004 { 3005 OUTYY(("P(server_harden_algo_downgrade:%s)\n", (yyvsp[0].str))); 3006 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3007 yyerror("expected yes or no."); 3008 else cfg_parser->cfg->harden_algo_downgrade = 3009 (strcmp((yyvsp[0].str), "yes")==0); 3010 free((yyvsp[0].str)); 3011 } 3012 #line 3013 "util/configparser.c" /* yacc.c:1646 */ 3013 break; 3014 3015 case 228: 3016 #line 925 "util/configparser.y" /* yacc.c:1646 */ 3017 { 3018 OUTYY(("P(server_use_caps_for_id:%s)\n", (yyvsp[0].str))); 3019 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3020 yyerror("expected yes or no."); 3021 else cfg_parser->cfg->use_caps_bits_for_id = 3022 (strcmp((yyvsp[0].str), "yes")==0); 3023 free((yyvsp[0].str)); 3024 } 3025 #line 3026 "util/configparser.c" /* yacc.c:1646 */ 3026 break; 3027 3028 case 229: 3029 #line 935 "util/configparser.y" /* yacc.c:1646 */ 3030 { 3031 OUTYY(("P(server_caps_whitelist:%s)\n", (yyvsp[0].str))); 3032 if(!cfg_strlist_insert(&cfg_parser->cfg->caps_whitelist, (yyvsp[0].str))) 3033 yyerror("out of memory"); 3034 } 3035 #line 3036 "util/configparser.c" /* yacc.c:1646 */ 3036 break; 3037 3038 case 230: 3039 #line 942 "util/configparser.y" /* yacc.c:1646 */ 3040 { 3041 OUTYY(("P(server_private_address:%s)\n", (yyvsp[0].str))); 3042 if(!cfg_strlist_insert(&cfg_parser->cfg->private_address, (yyvsp[0].str))) 3043 yyerror("out of memory"); 3044 } 3045 #line 3046 "util/configparser.c" /* yacc.c:1646 */ 3046 break; 3047 3048 case 231: 3049 #line 949 "util/configparser.y" /* yacc.c:1646 */ 3050 { 3051 OUTYY(("P(server_private_domain:%s)\n", (yyvsp[0].str))); 3052 if(!cfg_strlist_insert(&cfg_parser->cfg->private_domain, (yyvsp[0].str))) 3053 yyerror("out of memory"); 3054 } 3055 #line 3056 "util/configparser.c" /* yacc.c:1646 */ 3056 break; 3057 3058 case 232: 3059 #line 956 "util/configparser.y" /* yacc.c:1646 */ 3060 { 3061 OUTYY(("P(server_prefetch:%s)\n", (yyvsp[0].str))); 3062 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3063 yyerror("expected yes or no."); 3064 else cfg_parser->cfg->prefetch = (strcmp((yyvsp[0].str), "yes")==0); 3065 free((yyvsp[0].str)); 3066 } 3067 #line 3068 "util/configparser.c" /* yacc.c:1646 */ 3068 break; 3069 3070 case 233: 3071 #line 965 "util/configparser.y" /* yacc.c:1646 */ 3072 { 3073 OUTYY(("P(server_prefetch_key:%s)\n", (yyvsp[0].str))); 3074 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3075 yyerror("expected yes or no."); 3076 else cfg_parser->cfg->prefetch_key = (strcmp((yyvsp[0].str), "yes")==0); 3077 free((yyvsp[0].str)); 3078 } 3079 #line 3080 "util/configparser.c" /* yacc.c:1646 */ 3080 break; 3081 3082 case 234: 3083 #line 974 "util/configparser.y" /* yacc.c:1646 */ 3084 { 3085 OUTYY(("P(server_unwanted_reply_threshold:%s)\n", (yyvsp[0].str))); 3086 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3087 yyerror("number expected"); 3088 else cfg_parser->cfg->unwanted_threshold = atoi((yyvsp[0].str)); 3089 free((yyvsp[0].str)); 3090 } 3091 #line 3092 "util/configparser.c" /* yacc.c:1646 */ 3092 break; 3093 3094 case 235: 3095 #line 983 "util/configparser.y" /* yacc.c:1646 */ 3096 { 3097 OUTYY(("P(server_do_not_query_address:%s)\n", (yyvsp[0].str))); 3098 if(!cfg_strlist_insert(&cfg_parser->cfg->donotqueryaddrs, (yyvsp[0].str))) 3099 yyerror("out of memory"); 3100 } 3101 #line 3102 "util/configparser.c" /* yacc.c:1646 */ 3102 break; 3103 3104 case 236: 3105 #line 990 "util/configparser.y" /* yacc.c:1646 */ 3106 { 3107 OUTYY(("P(server_do_not_query_localhost:%s)\n", (yyvsp[0].str))); 3108 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3109 yyerror("expected yes or no."); 3110 else cfg_parser->cfg->donotquery_localhost = 3111 (strcmp((yyvsp[0].str), "yes")==0); 3112 free((yyvsp[0].str)); 3113 } 3114 #line 3115 "util/configparser.c" /* yacc.c:1646 */ 3115 break; 3116 3117 case 237: 3118 #line 1000 "util/configparser.y" /* yacc.c:1646 */ 3119 { 3120 OUTYY(("P(server_access_control:%s %s)\n", (yyvsp[-1].str), (yyvsp[0].str))); 3121 if(strcmp((yyvsp[0].str), "deny")!=0 && strcmp((yyvsp[0].str), "refuse")!=0 && 3122 strcmp((yyvsp[0].str), "deny_non_local")!=0 && 3123 strcmp((yyvsp[0].str), "refuse_non_local")!=0 && 3124 strcmp((yyvsp[0].str), "allow")!=0 && 3125 strcmp((yyvsp[0].str), "allow_snoop")!=0) { 3126 yyerror("expected deny, refuse, deny_non_local, " 3127 "refuse_non_local, allow or allow_snoop " 3128 "in access control action"); 3129 } else { 3130 if(!cfg_str2list_insert(&cfg_parser->cfg->acls, (yyvsp[-1].str), (yyvsp[0].str))) 3131 fatal_exit("out of memory adding acl"); 3132 } 3133 } 3134 #line 3135 "util/configparser.c" /* yacc.c:1646 */ 3135 break; 3136 3137 case 238: 3138 #line 1017 "util/configparser.y" /* yacc.c:1646 */ 3139 { 3140 OUTYY(("P(server_module_conf:%s)\n", (yyvsp[0].str))); 3141 free(cfg_parser->cfg->module_conf); 3142 cfg_parser->cfg->module_conf = (yyvsp[0].str); 3143 } 3144 #line 3145 "util/configparser.c" /* yacc.c:1646 */ 3145 break; 3146 3147 case 239: 3148 #line 1024 "util/configparser.y" /* yacc.c:1646 */ 3149 { 3150 OUTYY(("P(server_val_override_date:%s)\n", (yyvsp[0].str))); 3151 if(*(yyvsp[0].str) == '\0' || strcmp((yyvsp[0].str), "0") == 0) { 3152 cfg_parser->cfg->val_date_override = 0; 3153 } else if(strlen((yyvsp[0].str)) == 14) { 3154 cfg_parser->cfg->val_date_override = 3155 cfg_convert_timeval((yyvsp[0].str)); 3156 if(!cfg_parser->cfg->val_date_override) 3157 yyerror("bad date/time specification"); 3158 } else { 3159 if(atoi((yyvsp[0].str)) == 0) 3160 yyerror("number expected"); 3161 cfg_parser->cfg->val_date_override = atoi((yyvsp[0].str)); 3162 } 3163 free((yyvsp[0].str)); 3164 } 3165 #line 3166 "util/configparser.c" /* yacc.c:1646 */ 3166 break; 3167 3168 case 240: 3169 #line 1042 "util/configparser.y" /* yacc.c:1646 */ 3170 { 3171 OUTYY(("P(server_val_sig_skew_min:%s)\n", (yyvsp[0].str))); 3172 if(*(yyvsp[0].str) == '\0' || strcmp((yyvsp[0].str), "0") == 0) { 3173 cfg_parser->cfg->val_sig_skew_min = 0; 3174 } else { 3175 cfg_parser->cfg->val_sig_skew_min = atoi((yyvsp[0].str)); 3176 if(!cfg_parser->cfg->val_sig_skew_min) 3177 yyerror("number expected"); 3178 } 3179 free((yyvsp[0].str)); 3180 } 3181 #line 3182 "util/configparser.c" /* yacc.c:1646 */ 3182 break; 3183 3184 case 241: 3185 #line 1055 "util/configparser.y" /* yacc.c:1646 */ 3186 { 3187 OUTYY(("P(server_val_sig_skew_max:%s)\n", (yyvsp[0].str))); 3188 if(*(yyvsp[0].str) == '\0' || strcmp((yyvsp[0].str), "0") == 0) { 3189 cfg_parser->cfg->val_sig_skew_max = 0; 3190 } else { 3191 cfg_parser->cfg->val_sig_skew_max = atoi((yyvsp[0].str)); 3192 if(!cfg_parser->cfg->val_sig_skew_max) 3193 yyerror("number expected"); 3194 } 3195 free((yyvsp[0].str)); 3196 } 3197 #line 3198 "util/configparser.c" /* yacc.c:1646 */ 3198 break; 3199 3200 case 242: 3201 #line 1068 "util/configparser.y" /* yacc.c:1646 */ 3202 { 3203 OUTYY(("P(server_cache_max_ttl:%s)\n", (yyvsp[0].str))); 3204 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3205 yyerror("number expected"); 3206 else cfg_parser->cfg->max_ttl = atoi((yyvsp[0].str)); 3207 free((yyvsp[0].str)); 3208 } 3209 #line 3210 "util/configparser.c" /* yacc.c:1646 */ 3210 break; 3211 3212 case 243: 3213 #line 1077 "util/configparser.y" /* yacc.c:1646 */ 3214 { 3215 OUTYY(("P(server_cache_max_negative_ttl:%s)\n", (yyvsp[0].str))); 3216 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3217 yyerror("number expected"); 3218 else cfg_parser->cfg->max_negative_ttl = atoi((yyvsp[0].str)); 3219 free((yyvsp[0].str)); 3220 } 3221 #line 3222 "util/configparser.c" /* yacc.c:1646 */ 3222 break; 3223 3224 case 244: 3225 #line 1086 "util/configparser.y" /* yacc.c:1646 */ 3226 { 3227 OUTYY(("P(server_cache_min_ttl:%s)\n", (yyvsp[0].str))); 3228 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3229 yyerror("number expected"); 3230 else cfg_parser->cfg->min_ttl = atoi((yyvsp[0].str)); 3231 free((yyvsp[0].str)); 3232 } 3233 #line 3234 "util/configparser.c" /* yacc.c:1646 */ 3234 break; 3235 3236 case 245: 3237 #line 1095 "util/configparser.y" /* yacc.c:1646 */ 3238 { 3239 OUTYY(("P(server_bogus_ttl:%s)\n", (yyvsp[0].str))); 3240 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3241 yyerror("number expected"); 3242 else cfg_parser->cfg->bogus_ttl = atoi((yyvsp[0].str)); 3243 free((yyvsp[0].str)); 3244 } 3245 #line 3246 "util/configparser.c" /* yacc.c:1646 */ 3246 break; 3247 3248 case 246: 3249 #line 1104 "util/configparser.y" /* yacc.c:1646 */ 3250 { 3251 OUTYY(("P(server_val_clean_additional:%s)\n", (yyvsp[0].str))); 3252 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3253 yyerror("expected yes or no."); 3254 else cfg_parser->cfg->val_clean_additional = 3255 (strcmp((yyvsp[0].str), "yes")==0); 3256 free((yyvsp[0].str)); 3257 } 3258 #line 3259 "util/configparser.c" /* yacc.c:1646 */ 3259 break; 3260 3261 case 247: 3262 #line 1114 "util/configparser.y" /* yacc.c:1646 */ 3263 { 3264 OUTYY(("P(server_val_permissive_mode:%s)\n", (yyvsp[0].str))); 3265 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3266 yyerror("expected yes or no."); 3267 else cfg_parser->cfg->val_permissive_mode = 3268 (strcmp((yyvsp[0].str), "yes")==0); 3269 free((yyvsp[0].str)); 3270 } 3271 #line 3272 "util/configparser.c" /* yacc.c:1646 */ 3272 break; 3273 3274 case 248: 3275 #line 1124 "util/configparser.y" /* yacc.c:1646 */ 3276 { 3277 OUTYY(("P(server_ignore_cd_flag:%s)\n", (yyvsp[0].str))); 3278 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3279 yyerror("expected yes or no."); 3280 else cfg_parser->cfg->ignore_cd = (strcmp((yyvsp[0].str), "yes")==0); 3281 free((yyvsp[0].str)); 3282 } 3283 #line 3284 "util/configparser.c" /* yacc.c:1646 */ 3284 break; 3285 3286 case 249: 3287 #line 1133 "util/configparser.y" /* yacc.c:1646 */ 3288 { 3289 OUTYY(("P(server_val_log_level:%s)\n", (yyvsp[0].str))); 3290 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3291 yyerror("number expected"); 3292 else cfg_parser->cfg->val_log_level = atoi((yyvsp[0].str)); 3293 free((yyvsp[0].str)); 3294 } 3295 #line 3296 "util/configparser.c" /* yacc.c:1646 */ 3296 break; 3297 3298 case 250: 3299 #line 1142 "util/configparser.y" /* yacc.c:1646 */ 3300 { 3301 OUTYY(("P(server_val_nsec3_keysize_iterations:%s)\n", (yyvsp[0].str))); 3302 free(cfg_parser->cfg->val_nsec3_key_iterations); 3303 cfg_parser->cfg->val_nsec3_key_iterations = (yyvsp[0].str); 3304 } 3305 #line 3306 "util/configparser.c" /* yacc.c:1646 */ 3306 break; 3307 3308 case 251: 3309 #line 1149 "util/configparser.y" /* yacc.c:1646 */ 3310 { 3311 OUTYY(("P(server_add_holddown:%s)\n", (yyvsp[0].str))); 3312 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3313 yyerror("number expected"); 3314 else cfg_parser->cfg->add_holddown = atoi((yyvsp[0].str)); 3315 free((yyvsp[0].str)); 3316 } 3317 #line 3318 "util/configparser.c" /* yacc.c:1646 */ 3318 break; 3319 3320 case 252: 3321 #line 1158 "util/configparser.y" /* yacc.c:1646 */ 3322 { 3323 OUTYY(("P(server_del_holddown:%s)\n", (yyvsp[0].str))); 3324 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3325 yyerror("number expected"); 3326 else cfg_parser->cfg->del_holddown = atoi((yyvsp[0].str)); 3327 free((yyvsp[0].str)); 3328 } 3329 #line 3330 "util/configparser.c" /* yacc.c:1646 */ 3330 break; 3331 3332 case 253: 3333 #line 1167 "util/configparser.y" /* yacc.c:1646 */ 3334 { 3335 OUTYY(("P(server_keep_missing:%s)\n", (yyvsp[0].str))); 3336 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3337 yyerror("number expected"); 3338 else cfg_parser->cfg->keep_missing = atoi((yyvsp[0].str)); 3339 free((yyvsp[0].str)); 3340 } 3341 #line 3342 "util/configparser.c" /* yacc.c:1646 */ 3342 break; 3343 3344 case 254: 3345 #line 1176 "util/configparser.y" /* yacc.c:1646 */ 3346 { 3347 OUTYY(("P(server_permit_small_holddown:%s)\n", (yyvsp[0].str))); 3348 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3349 yyerror("expected yes or no."); 3350 else cfg_parser->cfg->permit_small_holddown = 3351 (strcmp((yyvsp[0].str), "yes")==0); 3352 free((yyvsp[0].str)); 3353 } 3354 #line 3355 "util/configparser.c" /* yacc.c:1646 */ 3355 break; 3356 3357 case 255: 3358 #line 1185 "util/configparser.y" /* yacc.c:1646 */ 3359 { 3360 OUTYY(("P(server_key_cache_size:%s)\n", (yyvsp[0].str))); 3361 if(!cfg_parse_memsize((yyvsp[0].str), &cfg_parser->cfg->key_cache_size)) 3362 yyerror("memory size expected"); 3363 free((yyvsp[0].str)); 3364 } 3365 #line 3366 "util/configparser.c" /* yacc.c:1646 */ 3366 break; 3367 3368 case 256: 3369 #line 1193 "util/configparser.y" /* yacc.c:1646 */ 3370 { 3371 OUTYY(("P(server_key_cache_slabs:%s)\n", (yyvsp[0].str))); 3372 if(atoi((yyvsp[0].str)) == 0) 3373 yyerror("number expected"); 3374 else { 3375 cfg_parser->cfg->key_cache_slabs = atoi((yyvsp[0].str)); 3376 if(!is_pow2(cfg_parser->cfg->key_cache_slabs)) 3377 yyerror("must be a power of 2"); 3378 } 3379 free((yyvsp[0].str)); 3380 } 3381 #line 3382 "util/configparser.c" /* yacc.c:1646 */ 3382 break; 3383 3384 case 257: 3385 #line 1206 "util/configparser.y" /* yacc.c:1646 */ 3386 { 3387 OUTYY(("P(server_neg_cache_size:%s)\n", (yyvsp[0].str))); 3388 if(!cfg_parse_memsize((yyvsp[0].str), &cfg_parser->cfg->neg_cache_size)) 3389 yyerror("memory size expected"); 3390 free((yyvsp[0].str)); 3391 } 3392 #line 3393 "util/configparser.c" /* yacc.c:1646 */ 3393 break; 3394 3395 case 258: 3396 #line 1214 "util/configparser.y" /* yacc.c:1646 */ 3397 { 3398 OUTYY(("P(server_local_zone:%s %s)\n", (yyvsp[-1].str), (yyvsp[0].str))); 3399 if(strcmp((yyvsp[0].str), "static")!=0 && strcmp((yyvsp[0].str), "deny")!=0 && 3400 strcmp((yyvsp[0].str), "refuse")!=0 && strcmp((yyvsp[0].str), "redirect")!=0 && 3401 strcmp((yyvsp[0].str), "transparent")!=0 && strcmp((yyvsp[0].str), "nodefault")!=0 3402 && strcmp((yyvsp[0].str), "typetransparent")!=0 && 3403 strcmp((yyvsp[0].str), "inform")!=0 && strcmp((yyvsp[0].str), "inform_deny")!=0) 3404 yyerror("local-zone type: expected static, deny, " 3405 "refuse, redirect, transparent, " 3406 "typetransparent, inform, inform_deny " 3407 "or nodefault"); 3408 else if(strcmp((yyvsp[0].str), "nodefault")==0) { 3409 if(!cfg_strlist_insert(&cfg_parser->cfg-> 3410 local_zones_nodefault, (yyvsp[-1].str))) 3411 fatal_exit("out of memory adding local-zone"); 3412 free((yyvsp[0].str)); 3413 } else { 3414 if(!cfg_str2list_insert(&cfg_parser->cfg->local_zones, 3415 (yyvsp[-1].str), (yyvsp[0].str))) 3416 fatal_exit("out of memory adding local-zone"); 3417 } 3418 } 3419 #line 3420 "util/configparser.c" /* yacc.c:1646 */ 3420 break; 3421 3422 case 259: 3423 #line 1238 "util/configparser.y" /* yacc.c:1646 */ 3424 { 3425 OUTYY(("P(server_local_data:%s)\n", (yyvsp[0].str))); 3426 if(!cfg_strlist_insert(&cfg_parser->cfg->local_data, (yyvsp[0].str))) 3427 fatal_exit("out of memory adding local-data"); 3428 } 3429 #line 3430 "util/configparser.c" /* yacc.c:1646 */ 3430 break; 3431 3432 case 260: 3433 #line 1245 "util/configparser.y" /* yacc.c:1646 */ 3434 { 3435 char* ptr; 3436 OUTYY(("P(server_local_data_ptr:%s)\n", (yyvsp[0].str))); 3437 ptr = cfg_ptr_reverse((yyvsp[0].str)); 3438 free((yyvsp[0].str)); 3439 if(ptr) { 3440 if(!cfg_strlist_insert(&cfg_parser->cfg-> 3441 local_data, ptr)) 3442 fatal_exit("out of memory adding local-data"); 3443 } else { 3444 yyerror("local-data-ptr could not be reversed"); 3445 } 3446 } 3447 #line 3448 "util/configparser.c" /* yacc.c:1646 */ 3448 break; 3449 3450 case 261: 3451 #line 1260 "util/configparser.y" /* yacc.c:1646 */ 3452 { 3453 OUTYY(("P(server_minimal_responses:%s)\n", (yyvsp[0].str))); 3454 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3455 yyerror("expected yes or no."); 3456 else cfg_parser->cfg->minimal_responses = 3457 (strcmp((yyvsp[0].str), "yes")==0); 3458 free((yyvsp[0].str)); 3459 } 3460 #line 3461 "util/configparser.c" /* yacc.c:1646 */ 3461 break; 3462 3463 case 262: 3464 #line 1270 "util/configparser.y" /* yacc.c:1646 */ 3465 { 3466 OUTYY(("P(server_rrset_roundrobin:%s)\n", (yyvsp[0].str))); 3467 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3468 yyerror("expected yes or no."); 3469 else cfg_parser->cfg->rrset_roundrobin = 3470 (strcmp((yyvsp[0].str), "yes")==0); 3471 free((yyvsp[0].str)); 3472 } 3473 #line 3474 "util/configparser.c" /* yacc.c:1646 */ 3474 break; 3475 3476 case 263: 3477 #line 1280 "util/configparser.y" /* yacc.c:1646 */ 3478 { 3479 OUTYY(("P(server_max_udp_size:%s)\n", (yyvsp[0].str))); 3480 cfg_parser->cfg->max_udp_size = atoi((yyvsp[0].str)); 3481 free((yyvsp[0].str)); 3482 } 3483 #line 3484 "util/configparser.c" /* yacc.c:1646 */ 3484 break; 3485 3486 case 264: 3487 #line 1287 "util/configparser.y" /* yacc.c:1646 */ 3488 { 3489 OUTYY(("P(dns64_prefix:%s)\n", (yyvsp[0].str))); 3490 free(cfg_parser->cfg->dns64_prefix); 3491 cfg_parser->cfg->dns64_prefix = (yyvsp[0].str); 3492 } 3493 #line 3494 "util/configparser.c" /* yacc.c:1646 */ 3494 break; 3495 3496 case 265: 3497 #line 1294 "util/configparser.y" /* yacc.c:1646 */ 3498 { 3499 OUTYY(("P(server_dns64_synthall:%s)\n", (yyvsp[0].str))); 3500 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3501 yyerror("expected yes or no."); 3502 else cfg_parser->cfg->dns64_synthall = (strcmp((yyvsp[0].str), "yes")==0); 3503 free((yyvsp[0].str)); 3504 } 3505 #line 3506 "util/configparser.c" /* yacc.c:1646 */ 3506 break; 3507 3508 case 266: 3509 #line 1303 "util/configparser.y" /* yacc.c:1646 */ 3510 { 3511 char* p, *s = (yyvsp[0].str); 3512 OUTYY(("P(server_define_tag:%s)\n", (yyvsp[0].str))); 3513 while((p=strsep(&s, " \t\n")) != NULL) { 3514 if(*p) { 3515 if(!config_add_tag(cfg_parser->cfg, p)) 3516 yyerror("could not define-tag, " 3517 "out of memory"); 3518 } 3519 } 3520 free((yyvsp[0].str)); 3521 } 3522 #line 3523 "util/configparser.c" /* yacc.c:1646 */ 3523 break; 3524 3525 case 267: 3526 #line 1317 "util/configparser.y" /* yacc.c:1646 */ 3527 { 3528 size_t len = 0; 3529 uint8_t* bitlist = config_parse_taglist(cfg_parser->cfg, (yyvsp[0].str), 3530 &len); 3531 free((yyvsp[0].str)); 3532 OUTYY(("P(server_local_zone_tag:%s)\n", (yyvsp[-1].str))); 3533 if(!bitlist) 3534 yyerror("could not parse tags, (define-tag them first)"); 3535 if(bitlist) { 3536 if(!cfg_strbytelist_insert( 3537 &cfg_parser->cfg->local_zone_tags, 3538 (yyvsp[-1].str), bitlist, len)) { 3539 yyerror("out of memory"); 3540 free((yyvsp[-1].str)); 3541 } 3542 } 3543 } 3544 #line 3545 "util/configparser.c" /* yacc.c:1646 */ 3545 break; 3546 3547 case 268: 3548 #line 1336 "util/configparser.y" /* yacc.c:1646 */ 3549 { 3550 OUTYY(("P(server_ratelimit:%s)\n", (yyvsp[0].str))); 3551 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3552 yyerror("number expected"); 3553 else cfg_parser->cfg->ratelimit = atoi((yyvsp[0].str)); 3554 free((yyvsp[0].str)); 3555 } 3556 #line 3557 "util/configparser.c" /* yacc.c:1646 */ 3557 break; 3558 3559 case 269: 3560 #line 1345 "util/configparser.y" /* yacc.c:1646 */ 3561 { 3562 OUTYY(("P(server_ratelimit_size:%s)\n", (yyvsp[0].str))); 3563 if(!cfg_parse_memsize((yyvsp[0].str), &cfg_parser->cfg->ratelimit_size)) 3564 yyerror("memory size expected"); 3565 free((yyvsp[0].str)); 3566 } 3567 #line 3568 "util/configparser.c" /* yacc.c:1646 */ 3568 break; 3569 3570 case 270: 3571 #line 1353 "util/configparser.y" /* yacc.c:1646 */ 3572 { 3573 OUTYY(("P(server_ratelimit_slabs:%s)\n", (yyvsp[0].str))); 3574 if(atoi((yyvsp[0].str)) == 0) 3575 yyerror("number expected"); 3576 else { 3577 cfg_parser->cfg->ratelimit_slabs = atoi((yyvsp[0].str)); 3578 if(!is_pow2(cfg_parser->cfg->ratelimit_slabs)) 3579 yyerror("must be a power of 2"); 3580 } 3581 free((yyvsp[0].str)); 3582 } 3583 #line 3584 "util/configparser.c" /* yacc.c:1646 */ 3584 break; 3585 3586 case 271: 3587 #line 1366 "util/configparser.y" /* yacc.c:1646 */ 3588 { 3589 OUTYY(("P(server_ratelimit_for_domain:%s %s)\n", (yyvsp[-1].str), (yyvsp[0].str))); 3590 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) { 3591 yyerror("number expected"); 3592 } else { 3593 if(!cfg_str2list_insert(&cfg_parser->cfg-> 3594 ratelimit_for_domain, (yyvsp[-1].str), (yyvsp[0].str))) 3595 fatal_exit("out of memory adding " 3596 "ratelimit-for-domain"); 3597 } 3598 } 3599 #line 3600 "util/configparser.c" /* yacc.c:1646 */ 3600 break; 3601 3602 case 272: 3603 #line 1379 "util/configparser.y" /* yacc.c:1646 */ 3604 { 3605 OUTYY(("P(server_ratelimit_below_domain:%s %s)\n", (yyvsp[-1].str), (yyvsp[0].str))); 3606 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) { 3607 yyerror("number expected"); 3608 } else { 3609 if(!cfg_str2list_insert(&cfg_parser->cfg-> 3610 ratelimit_below_domain, (yyvsp[-1].str), (yyvsp[0].str))) 3611 fatal_exit("out of memory adding " 3612 "ratelimit-below-domain"); 3613 } 3614 } 3615 #line 3616 "util/configparser.c" /* yacc.c:1646 */ 3616 break; 3617 3618 case 273: 3619 #line 1392 "util/configparser.y" /* yacc.c:1646 */ 3620 { 3621 OUTYY(("P(server_ratelimit_factor:%s)\n", (yyvsp[0].str))); 3622 if(atoi((yyvsp[0].str)) == 0 && strcmp((yyvsp[0].str), "0") != 0) 3623 yyerror("number expected"); 3624 else cfg_parser->cfg->ratelimit_factor = atoi((yyvsp[0].str)); 3625 free((yyvsp[0].str)); 3626 } 3627 #line 3628 "util/configparser.c" /* yacc.c:1646 */ 3628 break; 3629 3630 case 274: 3631 #line 1401 "util/configparser.y" /* yacc.c:1646 */ 3632 { 3633 OUTYY(("P(server_qname_minimisation:%s)\n", (yyvsp[0].str))); 3634 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3635 yyerror("expected yes or no."); 3636 else cfg_parser->cfg->qname_minimisation = 3637 (strcmp((yyvsp[0].str), "yes")==0); 3638 free((yyvsp[0].str)); 3639 } 3640 #line 3641 "util/configparser.c" /* yacc.c:1646 */ 3641 break; 3642 3643 case 275: 3644 #line 1411 "util/configparser.y" /* yacc.c:1646 */ 3645 { 3646 OUTYY(("P(name:%s)\n", (yyvsp[0].str))); 3647 if(cfg_parser->cfg->stubs->name) 3648 yyerror("stub name override, there must be one name " 3649 "for one stub-zone"); 3650 free(cfg_parser->cfg->stubs->name); 3651 cfg_parser->cfg->stubs->name = (yyvsp[0].str); 3652 } 3653 #line 3654 "util/configparser.c" /* yacc.c:1646 */ 3654 break; 3655 3656 case 276: 3657 #line 1421 "util/configparser.y" /* yacc.c:1646 */ 3658 { 3659 OUTYY(("P(stub-host:%s)\n", (yyvsp[0].str))); 3660 if(!cfg_strlist_insert(&cfg_parser->cfg->stubs->hosts, (yyvsp[0].str))) 3661 yyerror("out of memory"); 3662 } 3663 #line 3664 "util/configparser.c" /* yacc.c:1646 */ 3664 break; 3665 3666 case 277: 3667 #line 1428 "util/configparser.y" /* yacc.c:1646 */ 3668 { 3669 OUTYY(("P(stub-addr:%s)\n", (yyvsp[0].str))); 3670 if(!cfg_strlist_insert(&cfg_parser->cfg->stubs->addrs, (yyvsp[0].str))) 3671 yyerror("out of memory"); 3672 } 3673 #line 3674 "util/configparser.c" /* yacc.c:1646 */ 3674 break; 3675 3676 case 278: 3677 #line 1435 "util/configparser.y" /* yacc.c:1646 */ 3678 { 3679 OUTYY(("P(stub-first:%s)\n", (yyvsp[0].str))); 3680 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3681 yyerror("expected yes or no."); 3682 else cfg_parser->cfg->stubs->isfirst=(strcmp((yyvsp[0].str), "yes")==0); 3683 free((yyvsp[0].str)); 3684 } 3685 #line 3686 "util/configparser.c" /* yacc.c:1646 */ 3686 break; 3687 3688 case 279: 3689 #line 1444 "util/configparser.y" /* yacc.c:1646 */ 3690 { 3691 OUTYY(("P(stub-prime:%s)\n", (yyvsp[0].str))); 3692 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3693 yyerror("expected yes or no."); 3694 else cfg_parser->cfg->stubs->isprime = 3695 (strcmp((yyvsp[0].str), "yes")==0); 3696 free((yyvsp[0].str)); 3697 } 3698 #line 3699 "util/configparser.c" /* yacc.c:1646 */ 3699 break; 3700 3701 case 280: 3702 #line 1454 "util/configparser.y" /* yacc.c:1646 */ 3703 { 3704 OUTYY(("P(name:%s)\n", (yyvsp[0].str))); 3705 if(cfg_parser->cfg->forwards->name) 3706 yyerror("forward name override, there must be one " 3707 "name for one forward-zone"); 3708 free(cfg_parser->cfg->forwards->name); 3709 cfg_parser->cfg->forwards->name = (yyvsp[0].str); 3710 } 3711 #line 3712 "util/configparser.c" /* yacc.c:1646 */ 3712 break; 3713 3714 case 281: 3715 #line 1464 "util/configparser.y" /* yacc.c:1646 */ 3716 { 3717 OUTYY(("P(forward-host:%s)\n", (yyvsp[0].str))); 3718 if(!cfg_strlist_insert(&cfg_parser->cfg->forwards->hosts, (yyvsp[0].str))) 3719 yyerror("out of memory"); 3720 } 3721 #line 3722 "util/configparser.c" /* yacc.c:1646 */ 3722 break; 3723 3724 case 282: 3725 #line 1471 "util/configparser.y" /* yacc.c:1646 */ 3726 { 3727 OUTYY(("P(forward-addr:%s)\n", (yyvsp[0].str))); 3728 if(!cfg_strlist_insert(&cfg_parser->cfg->forwards->addrs, (yyvsp[0].str))) 3729 yyerror("out of memory"); 3730 } 3731 #line 3732 "util/configparser.c" /* yacc.c:1646 */ 3732 break; 3733 3734 case 283: 3735 #line 1478 "util/configparser.y" /* yacc.c:1646 */ 3736 { 3737 OUTYY(("P(forward-first:%s)\n", (yyvsp[0].str))); 3738 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3739 yyerror("expected yes or no."); 3740 else cfg_parser->cfg->forwards->isfirst=(strcmp((yyvsp[0].str), "yes")==0); 3741 free((yyvsp[0].str)); 3742 } 3743 #line 3744 "util/configparser.c" /* yacc.c:1646 */ 3744 break; 3745 3746 case 284: 3747 #line 1487 "util/configparser.y" /* yacc.c:1646 */ 3748 { 3749 OUTYY(("\nP(remote-control:)\n")); 3750 } 3751 #line 3752 "util/configparser.c" /* yacc.c:1646 */ 3752 break; 3753 3754 case 295: 3755 #line 1498 "util/configparser.y" /* yacc.c:1646 */ 3756 { 3757 OUTYY(("P(control_enable:%s)\n", (yyvsp[0].str))); 3758 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3759 yyerror("expected yes or no."); 3760 else cfg_parser->cfg->remote_control_enable = 3761 (strcmp((yyvsp[0].str), "yes")==0); 3762 free((yyvsp[0].str)); 3763 } 3764 #line 3765 "util/configparser.c" /* yacc.c:1646 */ 3765 break; 3766 3767 case 296: 3768 #line 1508 "util/configparser.y" /* yacc.c:1646 */ 3769 { 3770 OUTYY(("P(control_port:%s)\n", (yyvsp[0].str))); 3771 if(atoi((yyvsp[0].str)) == 0) 3772 yyerror("control port number expected"); 3773 else cfg_parser->cfg->control_port = atoi((yyvsp[0].str)); 3774 free((yyvsp[0].str)); 3775 } 3776 #line 3777 "util/configparser.c" /* yacc.c:1646 */ 3777 break; 3778 3779 case 297: 3780 #line 1517 "util/configparser.y" /* yacc.c:1646 */ 3781 { 3782 OUTYY(("P(control_interface:%s)\n", (yyvsp[0].str))); 3783 if(!cfg_strlist_insert(&cfg_parser->cfg->control_ifs, (yyvsp[0].str))) 3784 yyerror("out of memory"); 3785 } 3786 #line 3787 "util/configparser.c" /* yacc.c:1646 */ 3787 break; 3788 3789 case 298: 3790 #line 1524 "util/configparser.y" /* yacc.c:1646 */ 3791 { 3792 OUTYY(("P(control_use_cert:%s)\n", (yyvsp[0].str))); 3793 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3794 yyerror("expected yes or no."); 3795 else cfg_parser->cfg->remote_control_use_cert = 3796 (strcmp((yyvsp[0].str), "yes")==0); 3797 free((yyvsp[0].str)); 3798 } 3799 #line 3800 "util/configparser.c" /* yacc.c:1646 */ 3800 break; 3801 3802 case 299: 3803 #line 1534 "util/configparser.y" /* yacc.c:1646 */ 3804 { 3805 OUTYY(("P(rc_server_key_file:%s)\n", (yyvsp[0].str))); 3806 free(cfg_parser->cfg->server_key_file); 3807 cfg_parser->cfg->server_key_file = (yyvsp[0].str); 3808 } 3809 #line 3810 "util/configparser.c" /* yacc.c:1646 */ 3810 break; 3811 3812 case 300: 3813 #line 1541 "util/configparser.y" /* yacc.c:1646 */ 3814 { 3815 OUTYY(("P(rc_server_cert_file:%s)\n", (yyvsp[0].str))); 3816 free(cfg_parser->cfg->server_cert_file); 3817 cfg_parser->cfg->server_cert_file = (yyvsp[0].str); 3818 } 3819 #line 3820 "util/configparser.c" /* yacc.c:1646 */ 3820 break; 3821 3822 case 301: 3823 #line 1548 "util/configparser.y" /* yacc.c:1646 */ 3824 { 3825 OUTYY(("P(rc_control_key_file:%s)\n", (yyvsp[0].str))); 3826 free(cfg_parser->cfg->control_key_file); 3827 cfg_parser->cfg->control_key_file = (yyvsp[0].str); 3828 } 3829 #line 3830 "util/configparser.c" /* yacc.c:1646 */ 3830 break; 3831 3832 case 302: 3833 #line 1555 "util/configparser.y" /* yacc.c:1646 */ 3834 { 3835 OUTYY(("P(rc_control_cert_file:%s)\n", (yyvsp[0].str))); 3836 free(cfg_parser->cfg->control_cert_file); 3837 cfg_parser->cfg->control_cert_file = (yyvsp[0].str); 3838 } 3839 #line 3840 "util/configparser.c" /* yacc.c:1646 */ 3840 break; 3841 3842 case 303: 3843 #line 1562 "util/configparser.y" /* yacc.c:1646 */ 3844 { 3845 OUTYY(("\nP(dnstap:)\n")); 3846 } 3847 #line 3848 "util/configparser.c" /* yacc.c:1646 */ 3848 break; 3849 3850 case 318: 3851 #line 1579 "util/configparser.y" /* yacc.c:1646 */ 3852 { 3853 OUTYY(("P(dt_dnstap_enable:%s)\n", (yyvsp[0].str))); 3854 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3855 yyerror("expected yes or no."); 3856 else cfg_parser->cfg->dnstap = (strcmp((yyvsp[0].str), "yes")==0); 3857 } 3858 #line 3859 "util/configparser.c" /* yacc.c:1646 */ 3859 break; 3860 3861 case 319: 3862 #line 1587 "util/configparser.y" /* yacc.c:1646 */ 3863 { 3864 OUTYY(("P(dt_dnstap_socket_path:%s)\n", (yyvsp[0].str))); 3865 free(cfg_parser->cfg->dnstap_socket_path); 3866 cfg_parser->cfg->dnstap_socket_path = (yyvsp[0].str); 3867 } 3868 #line 3869 "util/configparser.c" /* yacc.c:1646 */ 3869 break; 3870 3871 case 320: 3872 #line 1594 "util/configparser.y" /* yacc.c:1646 */ 3873 { 3874 OUTYY(("P(dt_dnstap_send_identity:%s)\n", (yyvsp[0].str))); 3875 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3876 yyerror("expected yes or no."); 3877 else cfg_parser->cfg->dnstap_send_identity = (strcmp((yyvsp[0].str), "yes")==0); 3878 } 3879 #line 3880 "util/configparser.c" /* yacc.c:1646 */ 3880 break; 3881 3882 case 321: 3883 #line 1602 "util/configparser.y" /* yacc.c:1646 */ 3884 { 3885 OUTYY(("P(dt_dnstap_send_version:%s)\n", (yyvsp[0].str))); 3886 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3887 yyerror("expected yes or no."); 3888 else cfg_parser->cfg->dnstap_send_version = (strcmp((yyvsp[0].str), "yes")==0); 3889 } 3890 #line 3891 "util/configparser.c" /* yacc.c:1646 */ 3891 break; 3892 3893 case 322: 3894 #line 1610 "util/configparser.y" /* yacc.c:1646 */ 3895 { 3896 OUTYY(("P(dt_dnstap_identity:%s)\n", (yyvsp[0].str))); 3897 free(cfg_parser->cfg->dnstap_identity); 3898 cfg_parser->cfg->dnstap_identity = (yyvsp[0].str); 3899 } 3900 #line 3901 "util/configparser.c" /* yacc.c:1646 */ 3901 break; 3902 3903 case 323: 3904 #line 1617 "util/configparser.y" /* yacc.c:1646 */ 3905 { 3906 OUTYY(("P(dt_dnstap_version:%s)\n", (yyvsp[0].str))); 3907 free(cfg_parser->cfg->dnstap_version); 3908 cfg_parser->cfg->dnstap_version = (yyvsp[0].str); 3909 } 3910 #line 3911 "util/configparser.c" /* yacc.c:1646 */ 3911 break; 3912 3913 case 324: 3914 #line 1624 "util/configparser.y" /* yacc.c:1646 */ 3915 { 3916 OUTYY(("P(dt_dnstap_log_resolver_query_messages:%s)\n", (yyvsp[0].str))); 3917 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3918 yyerror("expected yes or no."); 3919 else cfg_parser->cfg->dnstap_log_resolver_query_messages = 3920 (strcmp((yyvsp[0].str), "yes")==0); 3921 } 3922 #line 3923 "util/configparser.c" /* yacc.c:1646 */ 3923 break; 3924 3925 case 325: 3926 #line 1633 "util/configparser.y" /* yacc.c:1646 */ 3927 { 3928 OUTYY(("P(dt_dnstap_log_resolver_response_messages:%s)\n", (yyvsp[0].str))); 3929 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3930 yyerror("expected yes or no."); 3931 else cfg_parser->cfg->dnstap_log_resolver_response_messages = 3932 (strcmp((yyvsp[0].str), "yes")==0); 3933 } 3934 #line 3935 "util/configparser.c" /* yacc.c:1646 */ 3935 break; 3936 3937 case 326: 3938 #line 1642 "util/configparser.y" /* yacc.c:1646 */ 3939 { 3940 OUTYY(("P(dt_dnstap_log_client_query_messages:%s)\n", (yyvsp[0].str))); 3941 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3942 yyerror("expected yes or no."); 3943 else cfg_parser->cfg->dnstap_log_client_query_messages = 3944 (strcmp((yyvsp[0].str), "yes")==0); 3945 } 3946 #line 3947 "util/configparser.c" /* yacc.c:1646 */ 3947 break; 3948 3949 case 327: 3950 #line 1651 "util/configparser.y" /* yacc.c:1646 */ 3951 { 3952 OUTYY(("P(dt_dnstap_log_client_response_messages:%s)\n", (yyvsp[0].str))); 3953 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3954 yyerror("expected yes or no."); 3955 else cfg_parser->cfg->dnstap_log_client_response_messages = 3956 (strcmp((yyvsp[0].str), "yes")==0); 3957 } 3958 #line 3959 "util/configparser.c" /* yacc.c:1646 */ 3959 break; 3960 3961 case 328: 3962 #line 1660 "util/configparser.y" /* yacc.c:1646 */ 3963 { 3964 OUTYY(("P(dt_dnstap_log_forwarder_query_messages:%s)\n", (yyvsp[0].str))); 3965 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3966 yyerror("expected yes or no."); 3967 else cfg_parser->cfg->dnstap_log_forwarder_query_messages = 3968 (strcmp((yyvsp[0].str), "yes")==0); 3969 } 3970 #line 3971 "util/configparser.c" /* yacc.c:1646 */ 3971 break; 3972 3973 case 329: 3974 #line 1669 "util/configparser.y" /* yacc.c:1646 */ 3975 { 3976 OUTYY(("P(dt_dnstap_log_forwarder_response_messages:%s)\n", (yyvsp[0].str))); 3977 if(strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 3978 yyerror("expected yes or no."); 3979 else cfg_parser->cfg->dnstap_log_forwarder_response_messages = 3980 (strcmp((yyvsp[0].str), "yes")==0); 3981 } 3982 #line 3983 "util/configparser.c" /* yacc.c:1646 */ 3983 break; 3984 3985 case 330: 3986 #line 1678 "util/configparser.y" /* yacc.c:1646 */ 3987 { 3988 OUTYY(("\nP(python:)\n")); 3989 } 3990 #line 3991 "util/configparser.c" /* yacc.c:1646 */ 3991 break; 3992 3993 case 334: 3994 #line 1687 "util/configparser.y" /* yacc.c:1646 */ 3995 { 3996 OUTYY(("P(python-script:%s)\n", (yyvsp[0].str))); 3997 free(cfg_parser->cfg->python_script); 3998 cfg_parser->cfg->python_script = (yyvsp[0].str); 3999 } 4000 #line 4001 "util/configparser.c" /* yacc.c:1646 */ 4001 break; 4002 4003 case 335: 4004 #line 1693 "util/configparser.y" /* yacc.c:1646 */ 4005 { 4006 OUTYY(("P(disable_dnssec_lame_check:%s)\n", (yyvsp[0].str))); 4007 if (strcmp((yyvsp[0].str), "yes") != 0 && strcmp((yyvsp[0].str), "no") != 0) 4008 yyerror("expected yes or no."); 4009 else cfg_parser->cfg->disable_dnssec_lame_check = 4010 (strcmp((yyvsp[0].str), "yes")==0); 4011 free((yyvsp[0].str)); 4012 } 4013 #line 4014 "util/configparser.c" /* yacc.c:1646 */ 4014 break; 4015 4016 4017 #line 4018 "util/configparser.c" /* yacc.c:1646 */ 4018 default: break; 4019 } 4020 /* User semantic actions sometimes alter yychar, and that requires 4021 that yytoken be updated with the new translation. We take the 4022 approach of translating immediately before every use of yytoken. 4023 One alternative is translating here after every semantic action, 4024 but that translation would be missed if the semantic action invokes 4025 YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or 4026 if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an 4027 incorrect destructor might then be invoked immediately. In the 4028 case of YYERROR or YYBACKUP, subsequent parser actions might lead 4029 to an incorrect destructor call or verbose syntax error message 4030 before the lookahead is translated. */ 4031 YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); 4032 4033 YYPOPSTACK (yylen); 4034 yylen = 0; 4035 YY_STACK_PRINT (yyss, yyssp); 4036 4037 *++yyvsp = yyval; 4038 4039 /* Now 'shift' the result of the reduction. Determine what state 4040 that goes to, based on the state we popped back to and the rule 4041 number reduced by. */ 4042 4043 yyn = yyr1[yyn]; 4044 4045 yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; 4046 if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) 4047 yystate = yytable[yystate]; 4048 else 4049 yystate = yydefgoto[yyn - YYNTOKENS]; 4050 4051 goto yynewstate; 4052 4053 4054 /*--------------------------------------. 4055 | yyerrlab -- here on detecting error. | 4056 `--------------------------------------*/ 4057 yyerrlab: 4058 /* Make sure we have latest lookahead translation. See comments at 4059 user semantic actions for why this is necessary. */ 4060 yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); 4061 4062 /* If not already recovering from an error, report this error. */ 4063 if (!yyerrstatus) 4064 { 4065 ++yynerrs; 4066 #if ! YYERROR_VERBOSE 4067 yyerror (YY_("syntax error")); 4068 #else 4069 # define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ 4070 yyssp, yytoken) 4071 { 4072 char const *yymsgp = YY_("syntax error"); 4073 int yysyntax_error_status; 4074 yysyntax_error_status = YYSYNTAX_ERROR; 4075 if (yysyntax_error_status == 0) 4076 yymsgp = yymsg; 4077 else if (yysyntax_error_status == 1) 4078 { 4079 if (yymsg != yymsgbuf) 4080 YYSTACK_FREE (yymsg); 4081 yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); 4082 if (!yymsg) 4083 { 4084 yymsg = yymsgbuf; 4085 yymsg_alloc = sizeof yymsgbuf; 4086 yysyntax_error_status = 2; 4087 } 4088 else 4089 { 4090 yysyntax_error_status = YYSYNTAX_ERROR; 4091 yymsgp = yymsg; 4092 } 4093 } 4094 yyerror (yymsgp); 4095 if (yysyntax_error_status == 2) 4096 goto yyexhaustedlab; 4097 } 4098 # undef YYSYNTAX_ERROR 4099 #endif 4100 } 4101 4102 4103 4104 if (yyerrstatus == 3) 4105 { 4106 /* If just tried and failed to reuse lookahead token after an 4107 error, discard it. */ 4108 4109 if (yychar <= YYEOF) 4110 { 4111 /* Return failure if at end of input. */ 4112 if (yychar == YYEOF) 4113 YYABORT; 4114 } 4115 else 4116 { 4117 yydestruct ("Error: discarding", 4118 yytoken, &yylval); 4119 yychar = YYEMPTY; 4120 } 4121 } 4122 4123 /* Else will try to reuse lookahead token after shifting the error 4124 token. */ 4125 goto yyerrlab1; 4126 4127 4128 /*---------------------------------------------------. 4129 | yyerrorlab -- error raised explicitly by YYERROR. | 4130 `---------------------------------------------------*/ 4131 yyerrorlab: 4132 4133 /* Pacify compilers like GCC when the user code never invokes 4134 YYERROR and the label yyerrorlab therefore never appears in user 4135 code. */ 4136 if (/*CONSTCOND*/ 0) 4137 goto yyerrorlab; 4138 4139 /* Do not reclaim the symbols of the rule whose action triggered 4140 this YYERROR. */ 4141 YYPOPSTACK (yylen); 4142 yylen = 0; 4143 YY_STACK_PRINT (yyss, yyssp); 4144 yystate = *yyssp; 4145 goto yyerrlab1; 4146 4147 4148 /*-------------------------------------------------------------. 4149 | yyerrlab1 -- common code for both syntax error and YYERROR. | 4150 `-------------------------------------------------------------*/ 4151 yyerrlab1: 4152 yyerrstatus = 3; /* Each real token shifted decrements this. */ 4153 4154 for (;;) 4155 { 4156 yyn = yypact[yystate]; 4157 if (!yypact_value_is_default (yyn)) 4158 { 4159 yyn += YYTERROR; 4160 if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) 4161 { 4162 yyn = yytable[yyn]; 4163 if (0 < yyn) 4164 break; 4165 } 4166 } 4167 4168 /* Pop the current state because it cannot handle the error token. */ 4169 if (yyssp == yyss) 4170 YYABORT; 4171 4172 4173 yydestruct ("Error: popping", 4174 yystos[yystate], yyvsp); 4175 YYPOPSTACK (1); 4176 yystate = *yyssp; 4177 YY_STACK_PRINT (yyss, yyssp); 4178 } 4179 4180 YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN 4181 *++yyvsp = yylval; 4182 YY_IGNORE_MAYBE_UNINITIALIZED_END 4183 4184 4185 /* Shift the error token. */ 4186 YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); 4187 4188 yystate = yyn; 4189 goto yynewstate; 4190 4191 4192 /*-------------------------------------. 4193 | yyacceptlab -- YYACCEPT comes here. | 4194 `-------------------------------------*/ 4195 yyacceptlab: 4196 yyresult = 0; 4197 goto yyreturn; 4198 4199 /*-----------------------------------. 4200 | yyabortlab -- YYABORT comes here. | 4201 `-----------------------------------*/ 4202 yyabortlab: 4203 yyresult = 1; 4204 goto yyreturn; 4205 4206 #if !defined yyoverflow || YYERROR_VERBOSE 4207 /*-------------------------------------------------. 4208 | yyexhaustedlab -- memory exhaustion comes here. | 4209 `-------------------------------------------------*/ 4210 yyexhaustedlab: 4211 yyerror (YY_("memory exhausted")); 4212 yyresult = 2; 4213 /* Fall through. */ 4214 #endif 4215 4216 yyreturn: 4217 if (yychar != YYEMPTY) 4218 { 4219 /* Make sure we have latest lookahead translation. See comments at 4220 user semantic actions for why this is necessary. */ 4221 yytoken = YYTRANSLATE (yychar); 4222 yydestruct ("Cleanup: discarding lookahead", 4223 yytoken, &yylval); 4224 } 4225 /* Do not reclaim the symbols of the rule whose action triggered 4226 this YYABORT or YYACCEPT. */ 4227 YYPOPSTACK (yylen); 4228 YY_STACK_PRINT (yyss, yyssp); 4229 while (yyssp != yyss) 4230 { 4231 yydestruct ("Cleanup: popping", 4232 yystos[*yyssp], yyvsp); 4233 YYPOPSTACK (1); 4234 } 4235 #ifndef yyoverflow 4236 if (yyss != yyssa) 4237 YYSTACK_FREE (yyss); 4238 #endif 4239 #if YYERROR_VERBOSE 4240 if (yymsg != yymsgbuf) 4241 YYSTACK_FREE (yymsg); 4242 #endif 4243 return yyresult; 4244 } 4245 #line 1701 "util/configparser.y" /* yacc.c:1906 */ 4246 4247 4248 /* parse helper routines could be here */ 4249