#include #define yy_create_buffer sudoers_create_buffer #define yy_delete_buffer sudoers_delete_buffer #define yy_scan_buffer sudoers_scan_buffer #define yy_scan_string sudoers_scan_string #define yy_scan_bytes sudoers_scan_bytes #define yy_flex_debug sudoers_flex_debug #define yy_init_buffer sudoers_init_buffer #define yy_flush_buffer sudoers_flush_buffer #define yy_load_buffer_state sudoers_load_buffer_state #define yy_switch_to_buffer sudoers_switch_to_buffer #define yyin sudoersin #define yyleng sudoersleng #define yylex sudoerslex #define yyout sudoersout #define yyrestart sudoersrestart #define yytext sudoerstext /* $OpenBSD: flex.skl,v 1.11 2010/08/04 18:24:50 millert Exp $ */ /* A lexical scanner generated by flex */ /* Scanner skeleton version: * $Header: /usr/local/www/users/anoncvs/cvs/embedaddon/sudo/plugins/sudoers/toke.c,v 1.1.1.4 2013/07/22 10:46:12 misho Exp $ */ #define FLEX_SCANNER #define YY_FLEX_MAJOR_VERSION 2 #define YY_FLEX_MINOR_VERSION 5 #include #include /* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */ #ifdef c_plusplus #ifndef __cplusplus #define __cplusplus #endif #endif #ifdef __cplusplus #include #include /* Use prototypes in function declarations. */ #define YY_USE_PROTOS /* The "const" storage-class-modifier is valid. */ #define YY_USE_CONST #else /* ! __cplusplus */ #ifdef __STDC__ #define YY_USE_PROTOS #define YY_USE_CONST #endif /* __STDC__ */ #endif /* ! __cplusplus */ #ifdef __TURBOC__ #pragma warn -rch #pragma warn -use #include #include #define YY_USE_CONST #define YY_USE_PROTOS #endif #ifdef YY_USE_CONST #define yyconst const #else #define yyconst #endif #ifdef YY_USE_PROTOS #define YY_PROTO(proto) proto #else #define YY_PROTO(proto) () #endif /* Returned upon end-of-file. */ #define YY_NULL 0 /* Promotes a possibly negative, possibly signed char to an unsigned * integer for use as an array index. If the signed char is negative, * we want to instead treat it as an 8-bit unsigned char, hence the * double cast. */ #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) /* Enter a start condition. This macro really ought to take a parameter, * but we do it the disgusting crufty way forced on us by the ()-less * definition of BEGIN. */ #define BEGIN yy_start = 1 + 2 * /* Translate the current start state into a value that can be later handed * to BEGIN to return to the state. The YYSTATE alias is for lex * compatibility. */ #define YY_START ((yy_start - 1) / 2) #define YYSTATE YY_START /* Action number for EOF rule of a given start state. */ #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) /* Special action meaning "start processing a new file". */ #define YY_NEW_FILE yyrestart( yyin ) #define YY_END_OF_BUFFER_CHAR 0 /* Size of default input buffer. */ #define YY_BUF_SIZE 16384 typedef struct yy_buffer_state *YY_BUFFER_STATE; extern int yyleng; extern FILE *yyin, *yyout; #define EOB_ACT_CONTINUE_SCAN 0 #define EOB_ACT_END_OF_FILE 1 #define EOB_ACT_LAST_MATCH 2 /* The funky do-while in the following #define is used to turn the definition * int a single C statement (which needs a semi-colon terminator). This * avoids problems with code like: * * if ( condition_holds ) * yyless( 5 ); * else * do_something_else(); * * Prior to using the do-while the compiler would get upset at the * "else" because it interpreted the "if" statement as being all * done when it reached the ';' after the yyless() call. */ /* Return all but the first 'n' matched characters back to the input stream. */ #define yyless(n) \ do \ { \ /* Undo effects of setting up yytext. */ \ *yy_cp = yy_hold_char; \ YY_RESTORE_YY_MORE_OFFSET \ yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \ YY_DO_BEFORE_ACTION; /* set up yytext again */ \ } \ while ( 0 ) #define unput(c) yyunput( c, yytext_ptr ) /* The following is because we cannot portably get our hands on size_t * (without autoconf's help, which isn't available because we want * flex-generated scanners to compile on their own). */ typedef unsigned int yy_size_t; struct yy_buffer_state { FILE *yy_input_file; char *yy_ch_buf; /* input buffer */ char *yy_buf_pos; /* current position in input buffer */ /* Size of input buffer in bytes, not including room for EOB * characters. */ yy_size_t yy_buf_size; /* Number of characters read into yy_ch_buf, not including EOB * characters. */ int yy_n_chars; /* Whether we "own" the buffer - i.e., we know we created it, * and can realloc() it to grow it, and should free() it to * delete it. */ int yy_is_our_buffer; /* Whether this is an "interactive" input source; if so, and * if we're using stdio for input, then we want to use getc() * instead of fread(), to make sure we stop fetching input after * each newline. */ int yy_is_interactive; /* Whether we're considered to be at the beginning of a line. * If so, '^' rules will be active on the next match, otherwise * not. */ int yy_at_bol; /* Whether to try to fill the input buffer when we reach the * end of it. */ int yy_fill_buffer; int yy_buffer_status; #define YY_BUFFER_NEW 0 #define YY_BUFFER_NORMAL 1 /* When an EOF's been seen but there's still some text to process * then we mark the buffer as YY_EOF_PENDING, to indicate that we * shouldn't try reading from the input source any more. We might * still have a bunch of tokens to match, though, because of * possible backing-up. * * When we actually see the EOF, we change the status to "new" * (via yyrestart()), so that the user can continue scanning by * just pointing yyin at a new input file. */ #define YY_BUFFER_EOF_PENDING 2 }; static YY_BUFFER_STATE yy_current_buffer = 0; /* We provide macros for accessing buffer states in case in the * future we want to put the buffer states in a more general * "scanner state". */ #define YY_CURRENT_BUFFER yy_current_buffer /* yy_hold_char holds the character lost when yytext is formed. */ static char yy_hold_char; static int yy_n_chars; /* number of characters read into yy_ch_buf */ int yyleng; /* Points to current character in buffer. */ static char *yy_c_buf_p = (char *) 0; static int yy_init = 1; /* whether we need to initialize */ static int yy_start = 0; /* start state number */ /* Flag which is used to allow yywrap()'s to do buffer switches * instead of setting up a fresh yyin. A bit of a hack ... */ static int yy_did_buffer_switch_on_eof; void yyrestart YY_PROTO(( FILE *input_file )); void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer )); void yy_load_buffer_state YY_PROTO(( void )); YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size )); void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b )); void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file )); void yy_flush_buffer YY_PROTO(( YY_BUFFER_STATE b )); #define YY_FLUSH_BUFFER yy_flush_buffer( yy_current_buffer ) YY_BUFFER_STATE yy_scan_buffer YY_PROTO(( char *base, yy_size_t size )); YY_BUFFER_STATE yy_scan_string YY_PROTO(( yyconst char *yy_str )); YY_BUFFER_STATE yy_scan_bytes YY_PROTO(( yyconst char *bytes, int len )); static void *yy_flex_alloc YY_PROTO(( yy_size_t )); static void *yy_flex_realloc YY_PROTO(( void *, yy_size_t )); static void yy_flex_free YY_PROTO(( void * )); #define yy_new_buffer yy_create_buffer #define yy_set_interactive(is_interactive) \ { \ if ( ! yy_current_buffer ) \ yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \ yy_current_buffer->yy_is_interactive = is_interactive; \ } #define yy_set_bol(at_bol) \ { \ if ( ! yy_current_buffer ) \ yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); \ yy_current_buffer->yy_at_bol = at_bol; \ } #define YY_AT_BOL() (yy_current_buffer->yy_at_bol) #define yywrap() 1 #define YY_SKIP_YYWRAP typedef unsigned char YY_CHAR; FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0; typedef int yy_state_type; extern char *yytext; #define yytext_ptr yytext static yy_state_type yy_get_previous_state YY_PROTO(( void )); static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state )); static int yy_get_next_buffer YY_PROTO(( void )); static void yy_fatal_error YY_PROTO(( yyconst char msg[] )); /* Done after the current pattern has been matched and before the * corresponding action - sets up yytext. */ #define YY_DO_BEFORE_ACTION \ yytext_ptr = yy_bp; \ yyleng = (int) (yy_cp - yy_bp); \ yy_hold_char = *yy_cp; \ *yy_cp = '\0'; \ yy_c_buf_p = yy_cp; #define YY_NUM_RULES 67 #define YY_END_OF_BUFFER 68 static yyconst short int yy_accept[814] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 68, 55, 63, 62, 61, 54, 66, 34, 56, 57, 34, 58, 55, 55, 55, 55, 60, 59, 66, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 66, 55, 55, 63, 66, 46, 46, 46, 46, 46, 2, 66, 1, 55, 46, 46, 55, 17, 16, 17, 16, 16, 66, 66, 66, 3, 9, 8, 9, 4, 9, 5, 66, 13, 13, 13, 11, 12, 66, 19, 19, 18, 18, 18, 19, 18, 18, 18, 19, 19, 19, 19, 19, 18, 19, 19, 55, 0, 63, 61, 0, 65, 0, 55, 36, 0, 34, 0, 35, 0, 53, 53, 0, 55, 55, 0, 55, 55, 55, 55, 0, 39, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 55, 64, 55, 55, 63, 0, 0, 0, 0, 0, 0, 55, 55, 55, 55, 55, 2, 1, 0, 1, 47, 47, 0, 55, 17, 17, 15, 14, 15, 0, 0, 3, 9, 0, 6, 7, 9, 9, 13, 0, 13, 13, 0, 10, 36, 0, 0, 35, 19, 19, 0, 19, 0, 0, 18, 18, 18, 18, 18, 18, 19, 19, 46, 19, 19, 19, 19, 19, 19, 19, 0, 0, 0, 36, 55, 55, 55, 55, 55, 0, 0, 39, 39, 46, 41, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 55, 55, 0, 0, 0, 0, 0, 0, 55, 55, 55, 55, 55, 0, 55, 10, 0, 0, 0, 18, 18, 18, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 0, 55, 55, 55, 55, 55, 55, 0, 40, 40, 40, 0, 0, 39, 39, 39, 39, 39, 39, 39, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 42, 46, 43, 55, 55, 55, 55, 0, 0, 0, 0, 0, 0, 55, 55, 55, 55, 0, 0, 0, 0, 0, 18, 18, 19, 46, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 55, 55, 55, 0, 0, 40, 40, 40, 0, 39, 39, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 0, 27, 46, 46, 46, 46, 46, 46, 46, 46, 44, 46, 55, 55, 55, 55, 55, 0, 0, 0, 0, 55, 55, 55, 0, 0, 0, 18, 18, 46, 46, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 55, 55, 55, 55, 55, 0, 40, 0, 39, 39, 39, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 46, 46, 46, 46, 46, 46, 46, 46, 46, 48, 49, 50, 51, 55, 0, 0, 0, 55, 55, 55, 0, 0, 0, 0, 0, 46, 46, 19, 46, 19, 19, 19, 19, 19, 19, 19, 19, 19, 37, 37, 37, 0, 0, 39, 39, 39, 39, 39, 39, 39, 0, 0, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 46, 46, 46, 0, 26, 46, 46, 46, 46, 0, 25, 0, 28, 55, 0, 0, 0, 55, 55, 55, 37, 37, 37, 46, 46, 46, 46, 19, 19, 19, 55, 37, 37, 37, 37, 0, 39, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 46, 46, 46, 46, 46, 46, 46, 52, 0, 0, 0, 55, 22, 47, 0, 37, 37, 37, 37, 46, 46, 46, 46, 19, 19, 19, 38, 38, 38, 38, 39, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 0, 0, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 46, 46, 46, 46, 46, 0, 24, 0, 29, 0, 22, 0, 0, 55, 0, 55, 38, 38, 38, 38, 46, 46, 46, 46, 55, 55, 38, 38, 38, 38, 0, 0, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 45, 0, 32, 46, 46, 46, 0, 0, 0, 20, 0, 23, 22, 0, 0, 0, 0, 0, 22, 0, 0, 0, 38, 38, 38, 38, 46, 46, 46, 55, 55, 55, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, 0, 30, 46, 46, 23, 0, 0, 22, 0, 0, 0, 46, 46, 55, 55, 55, 55, 55, 0, 0, 0, 0, 0, 39, 39, 39, 39, 39, 39, 39, 39, 0, 33, 46, 0, 0, 0, 0, 0, 0, 46, 55, 55, 55, 39, 39, 39, 39, 39, 39, 0, 31, 0, 0, 21, 0, 0, 0, 55, 55, 55, 55, 55, 39, 39, 39, 39, 39, 0, 0, 0, 0, 0, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 0 } ; static yyconst int yy_ec[256] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 4, 5, 6, 1, 7, 1, 1, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 1, 1, 27, 28, 10, 29, 30, 31, 32, 33, 34, 31, 35, 36, 37, 38, 38, 39, 40, 41, 42, 43, 38, 44, 45, 46, 47, 48, 49, 50, 51, 38, 10, 52, 10, 1, 53, 1, 54, 55, 56, 57, 58, 59, 60, 61, 62, 60, 60, 63, 64, 65, 66, 60, 60, 67, 68, 69, 70, 60, 60, 60, 60, 60, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 } ; static yyconst int yy_meta[71] = { 0, 1, 2, 3, 4, 5, 6, 1, 7, 7, 1, 8, 9, 10, 11, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 15, 7, 1, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 18, 19, 20, 20, 20, 20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21 } ; static yyconst short int yy_base[931] = { 0, 0, 69, 71, 79, 94, 124, 175, 244, 153, 197, 85, 130, 314, 0, 4514, 4461, 4510, 5604, 4507, 5604, 382, 86, 5604, 5604, 4458, 5604, 140, 394, 195, 153, 4483, 5604, 5604, 453, 4383, 43, 508, 37, 4379, 65, 4378, 4385, 4367, 566, 581, 91, 151, 604, 39, 41, 4351, 34, 4348, 117, 4402, 4412, 428, 4371, 4382, 136, 0, 5604, 4407, 5604, 0, 606, 664, 105, 0, 4358, 5604, 115, 5604, 133, 5604, 138, 4357, 152, 171, 5604, 188, 383, 641, 694, 737, 235, 245, 794, 843, 4369, 157, 898, 4365, 4364, 4375, 4370, 944, 0, 206, 4351, 266, 4400, 4397, 4397, 5604, 263, 532, 585, 4386, 608, 707, 4346, 829, 648, 4345, 968, 981, 1018, 4359, 4370, 563, 708, 422, 4357, 371, 1062, 1106, 4343, 4347, 4340, 4344, 596, 4333, 4340, 4337, 4329, 4331, 644, 5604, 237, 137, 946, 4309, 4314, 4305, 4300, 4301, 121, 225, 530, 377, 369, 335, 445, 4366, 720, 4365, 931, 4314, 1018, 169, 0, 4361, 160, 5604, 5604, 991, 388, 0, 4312, 638, 5604, 5604, 4311, 661, 4310, 4356, 392, 221, 420, 4358, 653, 665, 1139, 4296, 1145, 0, 1173, 1201, 1210, 1037, 1239, 4333, 1081, 1170, 826, 1288, 1343, 4307, 0, 4311, 4309, 899, 4298, 4296, 4287, 4283, 4336, 4335, 1222, 1258, 1389, 1362, 968, 1428, 4323, 4310, 1472, 520, 1517, 1561, 1605, 4303, 4297, 4280, 4282, 4289, 4300, 4295, 4283, 4279, 4292, 4291, 4290, 654, 493, 4258, 4252, 4242, 4244, 4250, 534, 579, 4253, 491, 407, 506, 1413, 626, 4304, 4251, 4239, 1651, 1661, 4227, 1705, 0, 4197, 4164, 4155, 4151, 4151, 4135, 4112, 4111, 811, 4067, 4122, 1749, 378, 0, 0, 1041, 243, 4098, 4097, 1786, 805, 4096, 4095, 623, 1410, 1799, 1447, 1091, 1844, 1890, 4094, 429, 4073, 632, 4084, 4082, 4056, 4054, 4050, 4053, 0, 4046, 0, 929, 638, 544, 561, 4022, 4024, 4008, 4022, 4008, 746, 524, 1063, 413, 662, 1491, 4060, 4059, 4058, 1270, 1900, 1944, 763, 904, 4037, 4020, 4009, 4007, 3992, 3988, 818, 3993, 3988, 3912, 1990, 2002, 2014, 3930, 3929, 2024, 3929, 3912, 3911, 3910, 919, 1536, 1003, 1580, 1142, 2037, 0, 1626, 2083, 1680, 1372, 2128, 2174, 764, 5604, 3892, 3877, 3870, 3884, 3862, 3869, 3879, 3879, 0, 3863, 698, 593, 820, 973, 1093, 3857, 3824, 3825, 922, 897, 969, 1097, 3866, 3858, 2186, 2196, 3829, 3807, 3800, 3814, 3778, 3784, 3794, 3793, 3747, 3726, 3716, 3711, 3696, 3656, 2240, 1017, 2279, 2291, 1637, 3686, 3662, 3648, 3646, 2301, 1127, 3642, 3641, 2347, 1154, 1205, 1209, 1724, 1761, 2359, 0, 1763, 2405, 1774, 1457, 2450, 2496, 2521, 1024, 1127, 1181, 1190, 1169, 1207, 1224, 1392, 3602, 3584, 3577, 3560, 1240, 3581, 3547, 1313, 1391, 874, 1774, 1821, 3584, 3576, 3569, 1503, 3523, 3519, 869, 1379, 3515, 3511, 949, 1045, 0, 0, 0, 0, 3478, 2577, 1863, 1546, 3510, 3509, 3506, 1919, 2616, 1963, 1590, 2660, 2706, 2056, 3517, 3509, 3487, 1692, 1879, 1979, 2096, 2104, 2147, 2106, 2718, 0, 2217, 2764, 2250, 1734, 2809, 2855, 2880, 2086, 1133, 1088, 5604, 421, 2087, 1184, 2088, 1369, 5604, 1370, 5604, 1197, 3418, 3389, 1282, 2127, 1249, 1368, 3442, 3427, 2936, 3386, 3320, 3309, 3295, 2951, 1219, 3272, 3006, 1181, 3044, 0, 1709, 3290, 3263, 2260, 58, 2320, 1774, 3083, 0, 2380, 3129, 2424, 1831, 3173, 3219, 3270, 3265, 3231, 2336, 2462, 2464, 2471, 3256, 2477, 3243, 0, 2589, 3289, 2600, 1929, 3335, 3360, 1376, 1087, 1847, 1409, 1542, 1586, 3218, 3184, 3166, 1832, 1427, 2060, 3174, 2635, 3210, 3186, 3185, 2435, 3129, 3111, 3114, 3066, 3429, 1454, 0, 3486, 2679, 2737, 1483, 3085, 2989, 2839, 3525, 2819, 2003, 2280, 2783, 2381, 3537, 0, 2830, 3583, 3016, 2157, 3627, 3673, 3026, 2821, 2801, 2750, 2228, 2472, 2474, 2695, 1189, 1531, 3685, 0, 2647, 1848, 1925, 1602, 1522, 1849, 1587, 5604, 1664, 5604, 2692, 1967, 1630, 2177, 2014, 2406, 2761, 2674, 2630, 3731, 2272, 1926, 2155, 2500, 1927, 3741, 2076, 3780, 0, 1967, 2277, 3054, 2598, 2535, 2509, 2841, 2470, 2431, 2485, 2600, 3064, 2617, 3819, 0, 3104, 3865, 3148, 3036, 3909, 3955, 2390, 2373, 3966, 3118, 2338, 1742, 2298, 2129, 5604, 2743, 1825, 1738, 2219, 2153, 1825, 5604, 2062, 2083, 3130, 3172, 3276, 3281, 1984, 2880, 1920, 3360, 3192, 1912, 1877, 1858, 3274, 1744, 2326, 2643, 2745, 3978, 3990, 4002, 1700, 1693, 4014, 1662, 1623, 2856, 2951, 3496, 3084, 4026, 0, 3508, 4072, 3556, 3074, 0, 1599, 1510, 1503, 3319, 1423, 2328, 5604, 3154, 2037, 5604, 2124, 3602, 3646, 1409, 1403, 4118, 2407, 2791, 4130, 2334, 4142, 4154, 3659, 3704, 1390, 1286, 1251, 3418, 1158, 1087, 3105, 1077, 1056, 4166, 0, 3568, 2499, 5604, 3270, 2220, 3751, 1014, 1005, 957, 3614, 2522, 4178, 4190, 4202, 3761, 3790, 3800, 684, 0, 683, 2685, 5604, 658, 2222, 5604, 522, 382, 4214, 4226, 2335, 4238, 4250, 3840, 5604, 3846, 3884, 3202, 5604, 3928, 374, 208, 117, 3716, 4260, 4297, 4334, 4045, 4091, 4270, 59, 4371, 3941, 5604, 4280, 3771, 5604, 4423, 4444, 4465, 4486, 4507, 4528, 4549, 4570, 4591, 4600, 2074, 4620, 4641, 2383, 4662, 4683, 4704, 4725, 4746, 4767, 4788, 4809, 2337, 4830, 4839, 4847, 4856, 4876, 4897, 4918, 2474, 4939, 4960, 4981, 5002, 5011, 5030, 5039, 5048, 2421, 2516, 5056, 5064, 5072, 5081, 5089, 5096, 5104, 5112, 5121, 5131, 2600, 2694, 5139, 5147, 5155, 2695, 2757, 5164, 5174, 5194, 2798, 5203, 5211, 2799, 5220, 5230, 5250, 2228, 2615, 5259, 5271, 5280, 5290, 2803, 2825, 5299, 5309, 5318, 5338, 2700, 5347, 5359, 2841, 2872, 5368, 5378, 2873, 5387, 5397, 5417, 5438, 5459, 3115, 3116, 5479, 3168, 5486, 5496, 2951, 2967, 5505, 2520, 5525, 3304, 3313, 5534, 5544, 3517, 3314, 3318, 5552, 5562, 5582, 3814, 3319, 3430 } ; static yyconst short int yy_def[931] = { 0, 813, 1, 1, 1, 814, 814, 815, 815, 816, 816, 817, 817, 813, 13, 813, 818, 813, 813, 813, 813, 819, 820, 813, 813, 821, 813, 822, 818, 28, 28, 823, 813, 813, 813, 34, 34, 34, 37, 37, 37, 37, 37, 37, 818, 28, 818, 813, 819, 34, 34, 37, 37, 37, 813, 824, 813, 825, 37, 37, 818, 826, 813, 826, 813, 826, 813, 819, 813, 827, 828, 813, 828, 813, 828, 813, 829, 830, 830, 830, 813, 813, 831, 832, 833, 813, 85, 85, 85, 813, 89, 89, 89, 92, 92, 92, 92, 85, 88, 88, 818, 818, 813, 813, 834, 813, 835, 813, 820, 836, 831, 820, 821, 821, 822, 837, 818, 818, 28, 838, 118, 118, 118, 118, 839, 840, 37, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 818, 813, 818, 818, 813, 813, 813, 813, 813, 813, 834, 818, 118, 818, 818, 818, 813, 813, 813, 813, 841, 842, 818, 818, 843, 843, 813, 813, 813, 835, 813, 844, 845, 845, 813, 813, 845, 845, 830, 813, 830, 830, 813, 813, 831, 831, 831, 846, 847, 88, 846, 848, 813, 813, 85, 192, 192, 192, 192, 813, 197, 198, 849, 198, 198, 198, 198, 198, 88, 88, 834, 850, 813, 813, 818, 212, 212, 118, 215, 851, 813, 852, 813, 127, 221, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 818, 818, 813, 813, 813, 813, 813, 834, 818, 215, 818, 818, 818, 813, 818, 813, 853, 854, 813, 88, 254, 197, 198, 198, 198, 198, 198, 198, 198, 198, 198, 88, 88, 850, 818, 818, 212, 212, 212, 818, 855, 856, 856, 277, 857, 856, 858, 220, 813, 283, 283, 813, 283, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 818, 818, 818, 818, 813, 813, 813, 813, 813, 834, 818, 818, 818, 818, 813, 813, 853, 853, 813, 254, 197, 198, 859, 198, 198, 198, 198, 198, 198, 88, 88, 88, 88, 212, 212, 212, 813, 860, 860, 339, 860, 861, 862, 863, 813, 864, 286, 864, 813, 349, 864, 813, 352, 352, 813, 352, 813, 813, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 818, 818, 818, 818, 818, 813, 813, 813, 834, 818, 818, 818, 865, 866, 813, 88, 321, 859, 859, 198, 198, 198, 198, 198, 198, 88, 88, 88, 88, 88, 818, 818, 212, 212, 818, 867, 867, 868, 869, 813, 813, 870, 871, 813, 872, 872, 873, 355, 873, 813, 418, 873, 813, 421, 421, 813, 421, 813, 426, 426, 426, 426, 426, 426, 426, 426, 818, 818, 818, 818, 818, 813, 813, 874, 818, 818, 818, 813, 813, 875, 875, 813, 859, 859, 198, 859, 198, 198, 198, 198, 88, 88, 88, 88, 88, 818, 464, 464, 813, 876, 877, 408, 813, 471, 471, 813, 471, 813, 813, 878, 878, 813, 813, 879, 879, 880, 424, 880, 813, 487, 880, 813, 490, 490, 813, 490, 813, 495, 495, 813, 813, 495, 495, 495, 495, 813, 813, 813, 813, 818, 813, 813, 881, 818, 818, 818, 882, 883, 813, 884, 884, 884, 884, 813, 522, 885, 818, 818, 818, 527, 527, 813, 886, 813, 887, 474, 887, 813, 536, 887, 813, 539, 539, 813, 539, 888, 889, 813, 813, 890, 890, 891, 892, 891, 813, 553, 891, 813, 556, 556, 556, 813, 560, 560, 560, 560, 560, 560, 818, 813, 813, 893, 818, 818, 818, 813, 813, 894, 894, 813, 895, 895, 895, 895, 813, 583, 896, 818, 586, 586, 586, 813, 897, 898, 813, 899, 899, 900, 542, 900, 813, 599, 900, 813, 602, 602, 813, 602, 813, 813, 901, 901, 813, 813, 902, 902, 903, 903, 813, 617, 903, 560, 560, 560, 560, 560, 813, 813, 813, 813, 813, 813, 904, 893, 818, 905, 906, 907, 908, 813, 907, 909, 909, 909, 909, 818, 818, 818, 646, 646, 818, 813, 813, 910, 910, 813, 813, 911, 911, 912, 605, 912, 813, 661, 912, 813, 664, 664, 813, 664, 913, 914, 813, 813, 915, 915, 560, 813, 813, 560, 560, 560, 813, 904, 904, 813, 893, 818, 905, 905, 905, 905, 916, 905, 917, 917, 813, 813, 907, 907, 813, 813, 909, 909, 909, 646, 646, 646, 918, 919, 813, 813, 920, 920, 921, 667, 921, 813, 716, 921, 813, 719, 719, 922, 813, 913, 913, 813, 813, 813, 813, 560, 560, 813, 893, 813, 813, 923, 924, 813, 909, 909, 646, 818, 646, 646, 818, 813, 813, 918, 918, 813, 813, 925, 925, 926, 926, 926, 756, 926, 813, 813, 560, 927, 813, 813, 923, 923, 813, 909, 646, 646, 646, 813, 813, 813, 813, 928, 928, 813, 813, 927, 927, 813, 929, 930, 813, 646, 818, 646, 646, 818, 813, 813, 813, 813, 813, 813, 813, 929, 929, 813, 818, 818, 818, 813, 813, 813, 818, 818, 818, 813, 813, 813, 0, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813 } ; static yyconst short int yy_nxt[5675] = { 0, 16, 17, 18, 19, 20, 21, 22, 23, 24, 16, 25, 26, 16, 16, 27, 28, 29, 30, 28, 28, 28, 28, 28, 28, 28, 31, 32, 33, 16, 34, 35, 35, 35, 36, 37, 37, 37, 37, 38, 37, 39, 37, 40, 41, 42, 43, 37, 37, 37, 37, 37, 44, 16, 45, 45, 45, 45, 45, 45, 16, 16, 16, 16, 16, 16, 16, 16, 46, 16, 16, 47, 532, 54, 130, 48, 135, 55, 127, 131, 127, 54, 127, 56, 534, 55, 57, 78, 18, 79, 80, 56, 109, 129, 57, 133, 17, 62, 63, 150, 64, 49, 50, 149, 152, 51, 64, 168, 139, 134, 58, 101, 110, 52, 59, 37, 53, 37, 58, 154, 64, 65, 59, 37, 105, 37, 17, 62, 63, 155, 64, 796, 78, 18, 79, 80, 64, 81, 111, 60, 175, 139, 172, 101, 115, 115, 66, 60, 115, 115, 64, 65, 140, 142, 178, 17, 18, 19, 71, 67, 173, 141, 168, 139, 72, 73, 74, 171, 115, 122, 122, 122, 122, 122, 123, 179, 66, 17, 18, 19, 75, 67, 81, 143, 144, 171, 242, 145, 101, 101, 180, 181, 116, 176, 236, 146, 198, 140, 147, 17, 18, 19, 71, 67, 177, 76, 161, 201, 72, 73, 74, 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, 101, 796, 177, 75, 179, 249, 68, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 17, 18, 19, 76, 67, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 195, 195, 195, 195, 195, 196, 206, 100, 119, 100, 100, 100, 177, 100, 100, 207, 101, 100, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 101, 243, 235, 100, 100, 100, 101, 68, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 33, 17, 18, 19, 33, 33, 82, 23, 24, 33, 83, 26, 33, 33, 84, 85, 86, 87, 85, 85, 85, 85, 85, 85, 85, 31, 88, 33, 33, 89, 90, 90, 90, 91, 92, 92, 92, 92, 93, 92, 94, 92, 95, 92, 96, 92, 92, 92, 92, 92, 92, 68, 33, 97, 97, 97, 97, 97, 97, 98, 98, 98, 98, 98, 98, 98, 98, 99, 98, 98, 105, 218, 101, 796, 109, 168, 139, 269, 247, 178, 106, 796, 220, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 117, 183, 118, 118, 118, 118, 118, 118, 118, 118, 118, 118, 119, 101, 180, 181, 120, 120, 120, 120, 120, 101, 101, 357, 159, 159, 246, 184, 159, 159, 216, 216, 216, 216, 216, 216, 177, 245, 101, 154, 120, 120, 120, 120, 120, 120, 100, 358, 159, 155, 127, 101, 100, 313, 563, 100, 100, 101, 100, 100, 100, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 119, 160, 311, 100, 126, 126, 126, 126, 126, 127, 127, 127, 127, 128, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 101, 127, 120, 120, 120, 120, 120, 120, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 813, 218, 796, 105, 127, 127, 127, 127, 127, 101, 100, 101, 282, 127, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 101, 304, 311, 372, 100, 100, 100, 100, 100, 100, 138, 139, 100, 100, 100, 311, 100, 100, 101, 378, 100, 216, 216, 216, 216, 216, 216, 216, 216, 216, 216, 244, 310, 813, 100, 100, 100, 100, 101, 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, 105, 164, 139, 165, 813, 166, 101, 109, 436, 165, 106, 166, 373, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 226, 101, 166, 166, 813, 227, 311, 111, 218, 228, 170, 229, 185, 170, 170, 101, 168, 139, 185, 282, 170, 185, 115, 115, 185, 185, 115, 115, 166, 813, 184, 782, 371, 168, 139, 170, 148, 105, 187, 360, 185, 109, 301, 302, 361, 303, 115, 167, 101, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 101, 813, 314, 188, 185, 115, 101, 532, 115, 115, 116, 115, 115, 115, 115, 184, 101, 115, 115, 108, 714, 108, 108, 171, 101, 108, 108, 184, 435, 108, 380, 187, 115, 115, 216, 216, 216, 216, 216, 216, 216, 216, 216, 216, 108, 108, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 190, 115, 187, 105, 101, 191, 187, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 119, 187, 357, 357, 193, 193, 193, 193, 193, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 358, 358, 193, 193, 193, 193, 193, 193, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 813, 377, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 813, 341, 341, 341, 187, 187, 187, 187, 187, 330, 331, 112, 332, 112, 112, 112, 394, 112, 112, 395, 437, 112, 255, 255, 255, 255, 255, 255, 187, 187, 187, 187, 187, 187, 187, 112, 112, 112, 187, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 119, 187, 498, 101, 197, 197, 197, 197, 197, 198, 198, 198, 198, 199, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 499, 200, 193, 193, 193, 193, 193, 193, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 813, 105, 101, 443, 198, 198, 198, 198, 198, 260, 218, 159, 159, 198, 261, 159, 159, 386, 262, 513, 263, 282, 387, 369, 142, 101, 370, 504, 187, 187, 187, 187, 187, 187, 813, 159, 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, 114, 763, 100, 100, 114, 505, 100, 100, 143, 144, 114, 101, 145, 160, 272, 272, 272, 272, 272, 273, 146, 438, 442, 147, 114, 114, 100, 212, 213, 214, 212, 212, 212, 212, 212, 212, 212, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 345, 218, 763, 158, 101, 100, 100, 158, 101, 100, 100, 763, 347, 158, 399, 444, 101, 215, 215, 215, 215, 215, 215, 215, 215, 215, 215, 158, 158, 100, 506, 215, 215, 215, 215, 215, 251, 252, 253, 251, 251, 251, 251, 251, 251, 251, 100, 100, 100, 100, 496, 127, 101, 813, 507, 215, 215, 215, 215, 215, 215, 221, 221, 221, 221, 221, 221, 221, 221, 221, 221, 119, 119, 498, 532, 221, 221, 221, 221, 221, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 350, 350, 350, 350, 350, 351, 714, 499, 101, 215, 215, 215, 215, 215, 215, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 813, 379, 622, 127, 127, 127, 127, 127, 127, 182, 218, 182, 182, 101, 185, 182, 182, 101, 439, 182, 185, 282, 445, 185, 813, 218, 185, 185, 100, 100, 100, 100, 100, 100, 182, 182, 347, 218, 127, 127, 187, 497, 185, 185, 562, 185, 185, 185, 347, 185, 185, 498, 659, 185, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 525, 188, 185, 185, 185, 185, 115, 345, 218, 115, 115, 499, 115, 115, 115, 115, 115, 127, 115, 115, 115, 565, 502, 345, 218, 127, 115, 345, 218, 127, 504, 500, 187, 115, 115, 347, 501, 101, 127, 416, 115, 115, 211, 211, 211, 211, 211, 211, 211, 211, 211, 211, 503, 101, 505, 127, 198, 190, 115, 254, 254, 254, 254, 254, 254, 254, 254, 254, 254, 746, 567, 584, 127, 254, 254, 254, 254, 254, 211, 211, 211, 211, 211, 211, 211, 211, 211, 211, 315, 105, 316, 316, 316, 316, 316, 316, 101, 254, 254, 254, 254, 254, 254, 187, 746, 101, 508, 187, 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, 119, 187, 105, 572, 256, 256, 256, 256, 256, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 570, 200, 254, 254, 254, 254, 254, 254, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 813, 511, 504, 506, 198, 198, 198, 198, 198, 271, 271, 271, 271, 271, 271, 271, 271, 271, 271, 419, 419, 419, 419, 419, 420, 506, 505, 507, 187, 187, 187, 187, 187, 187, 269, 746, 270, 270, 270, 270, 270, 270, 270, 270, 270, 270, 159, 520, 763, 507, 159, 101, 521, 621, 763, 127, 159, 287, 287, 287, 287, 287, 287, 287, 287, 287, 287, 127, 573, 218, 159, 159, 101, 100, 101, 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, 512, 624, 627, 127, 274, 274, 274, 274, 274, 349, 349, 349, 349, 349, 349, 349, 349, 349, 349, 488, 488, 488, 488, 488, 489, 101, 628, 633, 274, 274, 274, 274, 274, 274, 276, 277, 278, 278, 278, 278, 278, 278, 278, 278, 279, 649, 649, 649, 280, 280, 280, 280, 280, 381, 382, 383, 381, 381, 381, 381, 381, 381, 381, 446, 218, 447, 447, 447, 447, 447, 447, 218, 280, 280, 280, 280, 280, 280, 218, 283, 284, 285, 283, 283, 283, 283, 283, 283, 283, 286, 625, 813, 218, 287, 287, 287, 287, 287, 410, 411, 412, 410, 410, 410, 410, 410, 410, 410, 528, 528, 528, 528, 528, 529, 626, 679, 127, 287, 287, 287, 287, 287, 287, 288, 288, 288, 288, 288, 288, 288, 288, 288, 288, 119, 627, 625, 127, 288, 288, 288, 288, 288, 356, 356, 356, 356, 356, 356, 356, 356, 356, 356, 537, 537, 537, 537, 537, 538, 628, 626, 218, 274, 274, 274, 274, 274, 274, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 813, 683, 684, 127, 127, 127, 127, 127, 127, 345, 218, 414, 414, 414, 414, 414, 414, 678, 659, 127, 399, 347, 400, 400, 400, 400, 400, 400, 100, 100, 100, 100, 100, 100, 315, 627, 318, 318, 318, 318, 318, 319, 316, 316, 316, 316, 320, 320, 320, 320, 320, 320, 320, 320, 320, 320, 119, 597, 101, 628, 320, 320, 320, 320, 320, 418, 418, 418, 418, 418, 418, 418, 418, 418, 418, 476, 746, 477, 477, 477, 477, 477, 477, 746, 320, 320, 320, 320, 320, 320, 321, 321, 321, 321, 321, 321, 321, 321, 321, 321, 100, 100, 100, 100, 321, 321, 321, 321, 321, 425, 425, 425, 425, 425, 425, 425, 425, 425, 425, 554, 554, 554, 554, 554, 555, 345, 218, 695, 320, 320, 320, 320, 320, 320, 334, 335, 336, 334, 334, 334, 334, 334, 334, 334, 813, 218, 345, 218, 483, 483, 483, 483, 483, 483, 731, 127, 416, 813, 416, 487, 487, 487, 487, 487, 487, 487, 487, 487, 487, 534, 101, 339, 339, 340, 341, 341, 341, 341, 341, 341, 341, 279, 345, 218, 346, 346, 346, 346, 346, 346, 346, 346, 346, 346, 347, 101, 683, 684, 348, 348, 348, 348, 348, 631, 105, 514, 515, 516, 517, 515, 515, 515, 515, 515, 515, 515, 600, 600, 600, 600, 600, 601, 348, 348, 348, 348, 348, 348, 218, 352, 353, 354, 352, 352, 352, 352, 352, 352, 352, 355, 730, 695, 127, 356, 356, 356, 356, 356, 527, 527, 527, 527, 527, 527, 527, 527, 527, 527, 632, 623, 695, 680, 675, 218, 127, 127, 127, 356, 356, 356, 356, 356, 356, 813, 347, 348, 348, 348, 348, 348, 348, 348, 348, 348, 348, 384, 384, 384, 384, 384, 384, 384, 384, 384, 384, 695, 676, 676, 813, 384, 384, 384, 384, 384, 475, 475, 475, 475, 475, 475, 475, 475, 475, 475, 618, 618, 618, 618, 618, 619, 677, 677, 813, 384, 384, 384, 384, 384, 384, 385, 385, 385, 385, 385, 385, 385, 385, 385, 385, 703, 634, 694, 127, 385, 385, 385, 385, 385, 536, 536, 536, 536, 536, 536, 536, 536, 536, 536, 100, 100, 100, 100, 634, 218, 634, 634, 734, 384, 384, 384, 384, 384, 384, 399, 416, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 399, 532, 401, 401, 401, 401, 401, 401, 401, 401, 401, 401, 399, 534, 402, 402, 402, 402, 402, 403, 400, 400, 400, 400, 405, 405, 405, 405, 405, 405, 405, 405, 405, 405, 279, 345, 218, 414, 414, 414, 414, 414, 414, 414, 414, 414, 414, 347, 634, 105, 101, 413, 413, 413, 413, 413, 544, 545, 546, 544, 544, 544, 544, 544, 544, 544, 686, 761, 107, 127, 634, 107, 634, 635, 644, 413, 413, 413, 413, 413, 413, 345, 218, 415, 415, 415, 415, 415, 415, 415, 415, 415, 415, 416, 345, 218, 101, 417, 417, 417, 417, 417, 345, 218, 813, 218, 416, 127, 127, 127, 762, 105, 101, 733, 485, 676, 485, 561, 564, 101, 566, 417, 417, 417, 417, 417, 417, 218, 421, 422, 423, 421, 421, 421, 421, 421, 421, 421, 424, 677, 684, 813, 425, 425, 425, 425, 425, 494, 494, 494, 494, 494, 494, 494, 494, 494, 494, 662, 662, 662, 662, 662, 663, 101, 105, 813, 425, 425, 425, 425, 425, 425, 813, 571, 417, 417, 417, 417, 417, 417, 417, 417, 417, 417, 446, 701, 449, 449, 449, 449, 449, 450, 447, 447, 447, 447, 384, 384, 384, 384, 384, 384, 384, 384, 384, 384, 781, 782, 781, 782, 384, 384, 384, 384, 384, 345, 218, 549, 549, 549, 549, 549, 549, 685, 575, 575, 607, 485, 608, 608, 608, 608, 608, 608, 384, 384, 384, 384, 384, 384, 464, 465, 466, 464, 464, 464, 464, 464, 464, 464, 553, 553, 553, 553, 553, 553, 553, 553, 553, 553, 591, 592, 593, 591, 591, 591, 591, 591, 591, 591, 695, 732, 700, 700, 700, 644, 101, 399, 532, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 399, 597, 400, 400, 400, 400, 400, 400, 400, 400, 400, 400, 471, 472, 473, 471, 471, 471, 471, 471, 471, 471, 474, 728, 101, 728, 475, 475, 475, 475, 475, 543, 543, 543, 543, 543, 543, 543, 543, 543, 543, 127, 211, 741, 786, 211, 218, 729, 218, 729, 475, 475, 475, 475, 475, 475, 476, 416, 479, 479, 479, 479, 479, 480, 477, 477, 477, 477, 345, 218, 483, 483, 483, 483, 483, 483, 483, 483, 483, 483, 416, 101, 101, 218, 482, 482, 482, 482, 482, 532, 813, 595, 595, 595, 595, 595, 595, 169, 169, 169, 218, 534, 597, 688, 759, 689, 690, 691, 482, 482, 482, 482, 482, 482, 345, 218, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 485, 316, 760, 316, 486, 486, 486, 486, 486, 599, 599, 599, 599, 599, 599, 599, 599, 599, 599, 574, 575, 575, 575, 575, 575, 575, 597, 692, 486, 486, 486, 486, 486, 486, 218, 490, 491, 492, 490, 490, 490, 490, 490, 490, 490, 493, 218, 345, 218, 494, 494, 494, 494, 494, 345, 218, 218, 485, 218, 485, 813, 218, 169, 169, 169, 534, 551, 485, 532, 551, 759, 813, 551, 494, 494, 494, 494, 494, 494, 813, 597, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 100, 650, 778, 760, 813, 317, 100, 317, 735, 100, 100, 735, 100, 100, 100, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 702, 779, 650, 100, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 495, 127, 127, 127, 127, 127, 127, 127, 101, 127, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 525, 526, 526, 526, 526, 526, 526, 526, 526, 526, 526, 345, 218, 614, 614, 614, 614, 614, 614, 447, 650, 447, 532, 551, 617, 617, 617, 617, 617, 617, 617, 617, 617, 617, 659, 576, 576, 101, 532, 813, 533, 533, 533, 533, 533, 533, 533, 533, 533, 533, 534, 659, 695, 813, 535, 535, 535, 535, 535, 636, 637, 638, 639, 636, 636, 636, 636, 636, 636, 345, 218, 674, 674, 674, 674, 674, 674, 813, 535, 535, 535, 535, 535, 535, 539, 540, 541, 539, 539, 539, 539, 539, 539, 539, 542, 778, 695, 739, 543, 543, 543, 543, 543, 646, 646, 646, 646, 646, 646, 646, 646, 646, 646, 448, 477, 448, 477, 345, 218, 779, 575, 575, 543, 543, 543, 543, 543, 543, 813, 551, 535, 535, 535, 535, 535, 535, 535, 535, 535, 535, 345, 218, 549, 549, 549, 549, 549, 549, 549, 549, 549, 549, 485, 728, 681, 813, 548, 548, 548, 548, 548, 647, 647, 647, 647, 647, 648, 649, 649, 649, 649, 688, 607, 689, 690, 691, 478, 729, 478, 813, 548, 548, 548, 548, 548, 548, 345, 218, 550, 550, 550, 550, 550, 550, 550, 550, 550, 550, 551, 127, 740, 813, 552, 552, 552, 552, 552, 606, 606, 606, 606, 606, 606, 606, 606, 606, 606, 447, 477, 447, 477, 694, 608, 607, 608, 813, 552, 552, 552, 552, 552, 552, 218, 556, 557, 558, 556, 556, 556, 556, 556, 556, 556, 607, 609, 768, 609, 559, 559, 559, 559, 559, 532, 534, 657, 657, 657, 657, 657, 657, 651, 650, 651, 650, 597, 651, 651, 651, 651, 651, 651, 559, 559, 559, 559, 559, 559, 813, 532, 552, 552, 552, 552, 552, 552, 552, 552, 552, 552, 100, 659, 652, 608, 652, 608, 100, 687, 687, 100, 100, 687, 100, 100, 100, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 687, 687, 687, 100, 127, 127, 127, 127, 127, 127, 127, 560, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 101, 127, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 574, 577, 577, 577, 577, 577, 578, 575, 575, 575, 575, 187, 723, 723, 532, 187, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 714, 187, 724, 724, 198, 198, 198, 583, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 650, 200, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 586, 587, 588, 589, 586, 586, 586, 586, 586, 586, 661, 661, 661, 661, 661, 661, 661, 661, 661, 661, 669, 670, 671, 669, 669, 669, 669, 669, 669, 669, 717, 717, 717, 717, 717, 718, 101, 525, 526, 526, 526, 526, 526, 526, 526, 526, 526, 526, 707, 708, 709, 707, 707, 707, 707, 707, 707, 707, 668, 668, 668, 668, 668, 668, 668, 668, 668, 668, 757, 757, 757, 757, 757, 758, 101, 532, 813, 595, 595, 595, 595, 595, 595, 595, 595, 595, 595, 534, 714, 470, 643, 594, 594, 594, 594, 594, 532, 532, 712, 712, 712, 712, 712, 712, 696, 697, 696, 697, 659, 714, 813, 218, 813, 813, 813, 594, 594, 594, 594, 594, 594, 532, 551, 596, 596, 596, 596, 596, 596, 596, 596, 596, 596, 597, 759, 642, 641, 598, 598, 598, 598, 598, 716, 716, 716, 716, 716, 716, 716, 716, 716, 716, 688, 640, 689, 690, 691, 651, 760, 651, 692, 598, 598, 598, 598, 598, 598, 602, 603, 604, 602, 602, 602, 602, 602, 602, 602, 605, 574, 574, 127, 606, 606, 606, 606, 606, 736, 737, 738, 736, 736, 736, 736, 736, 736, 736, 791, 791, 791, 791, 791, 791, 692, 574, 101, 606, 606, 606, 606, 606, 606, 813, 630, 598, 598, 598, 598, 598, 598, 598, 598, 598, 598, 607, 629, 610, 610, 610, 610, 610, 611, 608, 608, 608, 608, 345, 218, 614, 614, 614, 614, 614, 614, 614, 614, 614, 614, 551, 101, 218, 778, 613, 613, 613, 613, 613, 813, 607, 689, 690, 691, 813, 607, 813, 813, 691, 695, 470, 696, 696, 696, 696, 696, 696, 779, 613, 613, 613, 613, 613, 613, 345, 218, 615, 615, 615, 615, 615, 615, 615, 615, 615, 615, 747, 343, 747, 127, 616, 616, 616, 616, 616, 748, 764, 748, 764, 692, 765, 797, 765, 797, 692, 218, 723, 723, 723, 723, 723, 723, 585, 582, 616, 616, 616, 616, 616, 616, 813, 581, 616, 616, 616, 616, 616, 616, 616, 616, 616, 616, 100, 693, 580, 693, 693, 693, 100, 693, 693, 100, 100, 693, 100, 100, 100, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 693, 693, 693, 100, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 620, 127, 127, 127, 101, 127, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, 625, 746, 579, 747, 747, 747, 747, 747, 747, 187, 798, 574, 798, 187, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 626, 187, 574, 569, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 568, 200, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, 644, 476, 645, 645, 645, 645, 645, 645, 645, 645, 645, 645, 722, 722, 722, 722, 722, 722, 722, 722, 722, 722, 532, 476, 753, 753, 753, 753, 753, 753, 755, 476, 470, 755, 714, 343, 279, 755, 101, 650, 524, 653, 653, 653, 653, 653, 654, 651, 651, 651, 651, 532, 523, 657, 657, 657, 657, 657, 657, 657, 657, 657, 657, 597, 522, 519, 518, 656, 656, 656, 656, 656, 756, 756, 756, 756, 756, 756, 756, 756, 756, 756, 532, 446, 777, 777, 777, 777, 777, 777, 446, 656, 656, 656, 656, 656, 656, 532, 446, 658, 658, 658, 658, 658, 658, 658, 658, 658, 658, 659, 510, 509, 101, 660, 660, 660, 660, 660, 735, 735, 735, 735, 735, 735, 735, 735, 735, 735, 763, 101, 764, 764, 764, 764, 764, 764, 101, 660, 660, 660, 660, 660, 660, 664, 665, 666, 664, 664, 664, 664, 664, 664, 664, 667, 101, 476, 476, 668, 668, 668, 668, 668, 735, 735, 735, 735, 735, 735, 735, 735, 735, 735, 470, 741, 343, 742, 742, 742, 742, 742, 742, 668, 668, 668, 668, 668, 668, 813, 279, 660, 660, 660, 660, 660, 660, 660, 660, 660, 660, 345, 218, 674, 674, 674, 674, 674, 674, 674, 674, 674, 674, 101, 279, 463, 462, 673, 673, 673, 673, 673, 772, 773, 774, 772, 772, 772, 772, 772, 772, 772, 796, 461, 797, 797, 797, 797, 797, 797, 460, 673, 673, 673, 673, 673, 673, 695, 459, 698, 698, 698, 698, 698, 699, 700, 700, 700, 700, 704, 705, 706, 704, 704, 704, 704, 704, 704, 704, 783, 784, 785, 783, 783, 783, 783, 783, 783, 783, 791, 791, 791, 791, 791, 791, 791, 791, 791, 791, 810, 810, 810, 810, 810, 810, 101, 644, 458, 645, 645, 645, 645, 645, 645, 645, 645, 645, 645, 792, 792, 792, 792, 792, 792, 792, 792, 792, 792, 793, 793, 793, 793, 793, 794, 791, 791, 791, 791, 457, 795, 456, 455, 795, 454, 101, 532, 795, 712, 712, 712, 712, 712, 712, 712, 712, 712, 712, 659, 453, 452, 451, 711, 711, 711, 711, 711, 786, 813, 787, 787, 787, 787, 787, 787, 791, 791, 791, 791, 791, 791, 791, 791, 791, 791, 446, 711, 711, 711, 711, 711, 711, 532, 446, 713, 713, 713, 713, 713, 713, 713, 713, 713, 713, 714, 101, 374, 441, 715, 715, 715, 715, 715, 791, 791, 791, 791, 791, 791, 791, 791, 791, 791, 440, 434, 433, 432, 431, 430, 429, 428, 427, 715, 715, 715, 715, 715, 715, 719, 720, 721, 719, 719, 719, 719, 719, 719, 719, 426, 408, 343, 279, 722, 722, 722, 722, 722, 804, 805, 806, 804, 804, 804, 804, 804, 804, 804, 404, 279, 125, 807, 807, 807, 807, 807, 807, 722, 722, 722, 722, 722, 722, 813, 398, 715, 715, 715, 715, 715, 715, 715, 715, 715, 715, 218, 725, 725, 725, 725, 725, 726, 723, 723, 723, 723, 741, 101, 742, 742, 742, 742, 742, 742, 742, 742, 742, 742, 741, 397, 743, 743, 743, 743, 743, 743, 743, 743, 743, 743, 741, 396, 744, 744, 744, 744, 744, 745, 742, 742, 742, 742, 746, 393, 749, 749, 749, 749, 749, 750, 747, 747, 747, 747, 532, 392, 753, 753, 753, 753, 753, 753, 753, 753, 753, 753, 714, 391, 390, 389, 752, 752, 752, 752, 752, 810, 810, 810, 810, 810, 810, 810, 810, 810, 810, 388, 315, 315, 315, 374, 376, 374, 375, 374, 752, 752, 752, 752, 752, 752, 532, 368, 754, 754, 754, 754, 754, 754, 754, 754, 754, 754, 367, 366, 365, 364, 755, 755, 755, 755, 755, 804, 804, 804, 804, 804, 804, 804, 804, 804, 804, 363, 362, 359, 119, 279, 343, 279, 125, 105, 755, 755, 755, 755, 755, 755, 763, 333, 766, 766, 766, 766, 766, 767, 764, 764, 764, 764, 100, 329, 769, 770, 771, 769, 769, 769, 769, 769, 769, 769, 741, 328, 742, 742, 742, 742, 742, 742, 742, 742, 742, 742, 741, 327, 742, 742, 742, 742, 742, 742, 742, 742, 742, 742, 532, 326, 777, 777, 777, 777, 777, 777, 777, 777, 777, 777, 786, 325, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 786, 324, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 786, 323, 789, 789, 789, 789, 789, 790, 787, 787, 787, 787, 796, 322, 799, 799, 799, 799, 799, 800, 797, 797, 797, 797, 100, 191, 801, 802, 803, 801, 801, 801, 801, 801, 801, 801, 786, 315, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 786, 315, 787, 787, 787, 787, 787, 787, 787, 787, 787, 787, 807, 807, 807, 807, 807, 807, 807, 807, 807, 807, 811, 811, 811, 811, 811, 812, 810, 810, 810, 810, 810, 810, 810, 810, 810, 810, 810, 810, 810, 810, 250, 312, 309, 308, 307, 306, 101, 801, 801, 801, 801, 801, 801, 801, 801, 801, 801, 305, 300, 299, 298, 297, 296, 295, 294, 293, 292, 291, 290, 289, 125, 117, 105, 105, 267, 266, 265, 264, 259, 258, 257, 813, 188, 101, 808, 808, 808, 808, 808, 809, 807, 807, 807, 807, 250, 176, 177, 171, 171, 163, 248, 157, 157, 241, 240, 239, 238, 237, 234, 233, 232, 231, 230, 225, 224, 223, 222, 125, 100, 125, 101, 807, 807, 807, 807, 807, 807, 807, 807, 807, 807, 190, 113, 210, 105, 103, 102, 101, 205, 204, 203, 202, 198, 177, 171, 163, 133, 131, 157, 156, 153, 151, 137, 136, 135, 132, 127, 101, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 61, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 77, 100, 125, 113, 103, 102, 101, 813, 100, 813, 100, 100, 100, 100, 813, 813, 100, 100, 100, 100, 100, 100, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, 108, 813, 813, 813, 813, 108, 813, 108, 813, 108, 108, 108, 108, 108, 813, 108, 108, 108, 108, 108, 108, 112, 813, 813, 813, 813, 813, 813, 112, 813, 112, 112, 112, 112, 813, 813, 112, 112, 112, 112, 112, 112, 114, 813, 813, 114, 114, 813, 114, 114, 813, 114, 114, 114, 114, 813, 813, 114, 114, 114, 114, 114, 114, 124, 124, 813, 124, 813, 813, 813, 124, 158, 813, 813, 158, 158, 813, 158, 158, 813, 158, 158, 158, 158, 813, 813, 158, 158, 158, 158, 158, 158, 162, 813, 813, 162, 162, 813, 162, 162, 813, 162, 162, 162, 162, 813, 162, 162, 162, 813, 162, 162, 162, 170, 813, 813, 170, 813, 813, 170, 170, 813, 170, 170, 170, 170, 170, 813, 170, 170, 170, 170, 170, 170, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, 176, 176, 813, 176, 813, 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, 182, 813, 813, 813, 813, 182, 813, 182, 813, 182, 182, 182, 182, 182, 813, 182, 182, 182, 182, 182, 182, 186, 813, 813, 813, 813, 813, 813, 186, 813, 186, 186, 186, 186, 813, 186, 186, 186, 186, 186, 186, 186, 189, 813, 813, 189, 189, 813, 189, 189, 813, 189, 189, 189, 189, 813, 189, 189, 189, 189, 189, 189, 189, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 209, 209, 813, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 209, 115, 813, 813, 115, 115, 813, 115, 115, 813, 115, 115, 115, 115, 813, 813, 115, 115, 115, 115, 115, 115, 124, 124, 813, 124, 813, 813, 813, 124, 217, 217, 813, 217, 813, 813, 813, 217, 219, 219, 219, 813, 219, 813, 813, 813, 219, 158, 813, 813, 158, 158, 813, 158, 158, 813, 158, 158, 158, 158, 813, 813, 158, 158, 158, 158, 158, 158, 159, 813, 813, 159, 159, 813, 159, 159, 813, 159, 159, 159, 159, 813, 813, 159, 159, 159, 159, 159, 159, 162, 813, 813, 162, 162, 813, 162, 162, 813, 162, 162, 162, 162, 813, 162, 162, 162, 813, 162, 162, 162, 170, 813, 813, 170, 813, 813, 170, 170, 813, 170, 170, 170, 170, 170, 813, 170, 170, 170, 170, 170, 170, 185, 813, 813, 813, 813, 813, 813, 185, 813, 185, 185, 185, 185, 813, 813, 185, 185, 185, 185, 185, 185, 186, 813, 813, 813, 813, 813, 813, 186, 813, 186, 186, 186, 186, 813, 186, 186, 186, 186, 186, 186, 186, 189, 813, 813, 189, 189, 813, 189, 189, 813, 189, 189, 189, 189, 813, 189, 189, 189, 189, 189, 189, 189, 200, 813, 813, 200, 200, 813, 200, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, 275, 275, 813, 275, 813, 813, 813, 275, 281, 281, 281, 813, 281, 813, 813, 813, 281, 337, 337, 813, 337, 813, 813, 813, 337, 338, 338, 813, 338, 813, 813, 813, 338, 342, 342, 813, 342, 813, 813, 813, 342, 344, 344, 344, 813, 344, 813, 813, 813, 344, 200, 813, 813, 200, 200, 813, 200, 404, 404, 813, 404, 813, 813, 813, 404, 406, 406, 813, 406, 813, 813, 813, 406, 407, 407, 813, 407, 813, 813, 813, 407, 409, 409, 409, 813, 409, 813, 813, 813, 409, 413, 413, 413, 413, 813, 413, 813, 813, 813, 413, 467, 467, 813, 467, 813, 813, 813, 467, 468, 468, 813, 468, 813, 813, 813, 468, 469, 469, 813, 469, 813, 813, 813, 469, 481, 481, 481, 813, 481, 813, 813, 813, 481, 482, 482, 482, 482, 813, 482, 813, 813, 813, 482, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 530, 530, 813, 530, 813, 813, 813, 530, 531, 531, 813, 531, 813, 813, 813, 531, 547, 547, 547, 813, 547, 813, 813, 813, 547, 548, 548, 548, 548, 813, 548, 813, 813, 813, 548, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 200, 813, 813, 200, 200, 813, 200, 187, 813, 813, 813, 187, 187, 813, 187, 187, 187, 813, 813, 187, 187, 590, 590, 813, 590, 813, 813, 813, 590, 594, 813, 594, 594, 813, 594, 813, 813, 813, 594, 612, 612, 612, 813, 612, 813, 813, 813, 612, 613, 613, 613, 613, 813, 613, 813, 813, 813, 613, 559, 559, 813, 813, 559, 813, 813, 813, 559, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, 200, 813, 813, 200, 200, 813, 200, 187, 813, 813, 813, 187, 187, 813, 187, 187, 187, 813, 813, 187, 187, 655, 655, 813, 655, 813, 813, 813, 655, 656, 813, 656, 656, 813, 656, 813, 813, 813, 656, 672, 672, 672, 813, 672, 813, 813, 813, 672, 673, 673, 673, 813, 813, 673, 813, 813, 813, 673, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 682, 687, 687, 813, 687, 687, 687, 813, 687, 813, 687, 687, 687, 687, 813, 813, 687, 687, 687, 687, 687, 687, 693, 693, 813, 693, 693, 693, 813, 693, 813, 693, 693, 693, 693, 813, 813, 693, 693, 693, 693, 693, 693, 200, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 200, 200, 813, 200, 200, 813, 200, 710, 710, 813, 710, 813, 813, 813, 710, 711, 813, 711, 711, 813, 711, 813, 813, 813, 711, 727, 727, 813, 813, 727, 813, 813, 813, 727, 693, 813, 813, 813, 813, 813, 813, 693, 813, 693, 693, 693, 693, 813, 813, 693, 693, 693, 693, 693, 693, 751, 751, 813, 751, 813, 813, 813, 751, 752, 813, 752, 752, 813, 752, 813, 813, 813, 752, 775, 775, 813, 775, 813, 813, 813, 775, 776, 813, 776, 813, 813, 776, 813, 813, 813, 776, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 780, 15, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813 } ; static yyconst short int yy_chk[5675] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 533, 3, 38, 2, 52, 3, 49, 38, 50, 4, 36, 3, 533, 4, 3, 11, 11, 11, 11, 4, 22, 36, 4, 40, 5, 5, 5, 50, 5, 2, 2, 49, 52, 2, 5, 68, 68, 40, 3, 807, 22, 2, 3, 3, 2, 3, 4, 54, 5, 5, 4, 4, 148, 4, 6, 6, 6, 54, 6, 799, 12, 12, 12, 12, 6, 11, 22, 3, 76, 76, 72, 46, 27, 27, 5, 4, 27, 27, 6, 6, 46, 47, 78, 9, 9, 9, 9, 9, 74, 46, 164, 164, 9, 9, 9, 72, 27, 30, 30, 30, 30, 30, 30, 79, 6, 7, 7, 7, 9, 7, 12, 47, 47, 74, 148, 47, 60, 141, 81, 81, 27, 81, 141, 47, 91, 60, 47, 10, 10, 10, 10, 10, 78, 9, 60, 91, 10, 10, 10, 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, 161, 798, 79, 10, 179, 161, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 10, 8, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 87, 87, 87, 87, 87, 87, 99, 101, 274, 101, 101, 101, 179, 101, 101, 99, 149, 101, 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, 140, 149, 140, 101, 101, 101, 274, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 21, 125, 153, 797, 82, 168, 168, 270, 153, 178, 21, 784, 125, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 28, 82, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 152, 180, 180, 28, 28, 28, 28, 28, 151, 270, 289, 57, 57, 152, 82, 57, 57, 123, 123, 123, 123, 123, 123, 178, 151, 28, 154, 28, 28, 28, 28, 28, 28, 34, 289, 57, 154, 500, 246, 34, 246, 500, 34, 34, 313, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 57, 313, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 219, 783, 242, 37, 37, 37, 37, 37, 245, 150, 236, 219, 37, 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, 247, 236, 245, 303, 37, 37, 37, 37, 37, 37, 44, 44, 44, 44, 44, 247, 44, 44, 311, 311, 44, 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, 150, 242, 108, 44, 44, 44, 45, 303, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 48, 66, 66, 66, 108, 66, 304, 110, 370, 66, 48, 66, 304, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 132, 243, 66, 66, 110, 132, 243, 108, 281, 132, 171, 132, 83, 171, 171, 370, 138, 138, 83, 281, 171, 83, 114, 114, 83, 83, 114, 114, 66, 182, 110, 780, 302, 175, 175, 171, 48, 67, 83, 291, 83, 183, 235, 235, 291, 235, 114, 67, 249, 182, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 302, 183, 249, 83, 83, 84, 138, 777, 84, 84, 114, 84, 84, 84, 84, 182, 235, 84, 84, 111, 775, 111, 111, 175, 314, 111, 111, 183, 369, 111, 314, 84, 84, 84, 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, 111, 111, 156, 156, 156, 156, 156, 156, 156, 156, 156, 156, 84, 84, 85, 310, 369, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 322, 357, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 322, 357, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 85, 88, 310, 88, 88, 88, 88, 88, 88, 88, 88, 88, 88, 88, 278, 278, 278, 88, 88, 88, 88, 88, 266, 266, 113, 266, 113, 113, 113, 330, 113, 113, 330, 371, 113, 196, 196, 196, 196, 196, 196, 88, 88, 88, 88, 88, 88, 89, 113, 113, 113, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 453, 371, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 453, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, 377, 444, 378, 92, 92, 92, 92, 92, 203, 344, 158, 158, 92, 203, 158, 158, 323, 203, 444, 203, 344, 323, 301, 142, 378, 301, 457, 92, 92, 92, 92, 92, 92, 97, 158, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 116, 766, 116, 116, 116, 457, 116, 116, 142, 142, 116, 301, 142, 158, 214, 214, 214, 214, 214, 214, 142, 372, 377, 142, 116, 116, 116, 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, 167, 167, 167, 167, 167, 167, 167, 167, 167, 167, 346, 346, 765, 160, 379, 160, 160, 160, 372, 160, 160, 764, 346, 160, 400, 379, 117, 118, 118, 118, 118, 118, 118, 118, 118, 118, 118, 160, 160, 160, 458, 118, 118, 118, 118, 118, 191, 191, 191, 191, 191, 191, 191, 191, 191, 191, 273, 273, 273, 273, 427, 427, 400, 755, 458, 118, 118, 118, 118, 118, 118, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 312, 498, 754, 126, 126, 126, 126, 126, 194, 194, 194, 194, 194, 194, 194, 194, 194, 194, 285, 285, 285, 285, 285, 285, 752, 498, 312, 126, 126, 126, 126, 126, 126, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 127, 312, 562, 562, 127, 127, 127, 127, 127, 184, 409, 184, 184, 373, 186, 184, 184, 380, 373, 184, 186, 409, 380, 186, 348, 348, 186, 186, 127, 127, 127, 127, 127, 127, 184, 184, 348, 413, 497, 428, 186, 428, 186, 188, 497, 188, 188, 188, 413, 188, 188, 429, 751, 188, 195, 195, 195, 195, 195, 195, 195, 195, 195, 195, 526, 186, 186, 188, 188, 188, 189, 615, 615, 189, 189, 429, 189, 189, 189, 189, 190, 431, 189, 189, 190, 502, 431, 414, 414, 502, 190, 415, 415, 429, 433, 430, 189, 189, 189, 414, 430, 526, 430, 415, 190, 190, 210, 210, 210, 210, 210, 210, 210, 210, 210, 210, 432, 508, 433, 432, 523, 189, 189, 192, 192, 192, 192, 192, 192, 192, 192, 192, 192, 749, 508, 523, 433, 192, 192, 192, 192, 192, 211, 211, 211, 211, 211, 211, 211, 211, 211, 211, 319, 511, 319, 319, 319, 319, 319, 319, 439, 192, 192, 192, 192, 192, 192, 197, 748, 513, 439, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 442, 513, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 511, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 197, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 198, 442, 504, 506, 198, 198, 198, 198, 198, 213, 213, 213, 213, 213, 213, 213, 213, 213, 213, 354, 354, 354, 354, 354, 354, 434, 504, 506, 198, 198, 198, 198, 198, 198, 212, 747, 212, 212, 212, 212, 212, 212, 212, 212, 212, 212, 248, 454, 737, 434, 248, 514, 454, 561, 736, 561, 248, 282, 282, 282, 282, 282, 282, 282, 282, 282, 282, 434, 514, 727, 248, 248, 212, 215, 443, 215, 215, 215, 215, 215, 215, 215, 215, 215, 215, 443, 564, 584, 564, 215, 215, 215, 215, 215, 284, 284, 284, 284, 284, 284, 284, 284, 284, 284, 423, 423, 423, 423, 423, 423, 571, 584, 571, 215, 215, 215, 215, 215, 215, 218, 218, 218, 218, 218, 218, 218, 218, 218, 218, 218, 589, 589, 589, 218, 218, 218, 218, 218, 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, 450, 725, 450, 450, 450, 450, 450, 450, 724, 218, 218, 218, 218, 218, 218, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 565, 616, 616, 220, 220, 220, 220, 220, 345, 345, 345, 345, 345, 345, 345, 345, 345, 345, 466, 466, 466, 466, 466, 466, 565, 623, 623, 220, 220, 220, 220, 220, 220, 221, 221, 221, 221, 221, 221, 221, 221, 221, 221, 221, 566, 625, 565, 221, 221, 221, 221, 221, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 473, 473, 473, 473, 473, 473, 566, 625, 723, 221, 221, 221, 221, 221, 221, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 222, 631, 631, 566, 222, 222, 222, 222, 222, 351, 351, 351, 351, 351, 351, 351, 351, 622, 711, 622, 403, 351, 403, 403, 403, 403, 403, 403, 222, 222, 222, 222, 222, 222, 253, 627, 253, 253, 253, 253, 253, 253, 253, 253, 253, 253, 254, 254, 254, 254, 254, 254, 254, 254, 254, 254, 254, 710, 403, 627, 254, 254, 254, 254, 254, 353, 353, 353, 353, 353, 353, 353, 353, 353, 353, 480, 708, 480, 480, 480, 480, 480, 480, 707, 254, 254, 254, 254, 254, 254, 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, 529, 529, 529, 529, 256, 256, 256, 256, 256, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 492, 492, 492, 492, 492, 492, 674, 674, 700, 256, 256, 256, 256, 256, 256, 269, 269, 269, 269, 269, 269, 269, 269, 269, 269, 417, 417, 420, 420, 420, 420, 420, 420, 420, 420, 680, 680, 417, 535, 420, 422, 422, 422, 422, 422, 422, 422, 422, 422, 422, 535, 269, 277, 277, 277, 277, 277, 277, 277, 277, 277, 277, 277, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 445, 683, 683, 283, 283, 283, 283, 283, 570, 570, 445, 446, 446, 446, 446, 446, 446, 446, 446, 446, 446, 541, 541, 541, 541, 541, 541, 283, 283, 283, 283, 283, 283, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 679, 698, 679, 286, 286, 286, 286, 286, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 570, 563, 697, 624, 620, 481, 563, 620, 624, 286, 286, 286, 286, 286, 286, 287, 481, 287, 287, 287, 287, 287, 287, 287, 287, 287, 287, 320, 320, 320, 320, 320, 320, 320, 320, 320, 320, 696, 621, 640, 643, 320, 320, 320, 320, 320, 470, 470, 470, 470, 470, 470, 470, 470, 470, 470, 558, 558, 558, 558, 558, 558, 621, 640, 643, 320, 320, 320, 320, 320, 320, 321, 321, 321, 321, 321, 321, 321, 321, 321, 321, 643, 630, 693, 621, 321, 321, 321, 321, 321, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 648, 648, 648, 648, 630, 482, 630, 630, 691, 321, 321, 321, 321, 321, 321, 334, 482, 334, 334, 334, 334, 334, 334, 334, 334, 334, 334, 335, 595, 335, 335, 335, 335, 335, 335, 335, 335, 335, 335, 336, 595, 336, 336, 336, 336, 336, 336, 336, 336, 336, 336, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 349, 349, 349, 349, 349, 349, 349, 349, 349, 349, 349, 349, 349, 572, 685, 633, 349, 349, 349, 349, 349, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 633, 731, 824, 731, 572, 824, 572, 572, 645, 349, 349, 349, 349, 349, 349, 352, 352, 352, 352, 352, 352, 352, 352, 352, 352, 352, 352, 352, 483, 483, 572, 352, 352, 352, 352, 352, 484, 484, 486, 486, 483, 496, 501, 503, 733, 733, 645, 685, 484, 676, 486, 496, 501, 686, 503, 352, 352, 352, 352, 352, 352, 355, 355, 355, 355, 355, 355, 355, 355, 355, 355, 355, 355, 676, 682, 641, 355, 355, 355, 355, 355, 485, 485, 485, 485, 485, 485, 485, 485, 485, 485, 604, 604, 604, 604, 604, 604, 512, 632, 641, 355, 355, 355, 355, 355, 355, 356, 512, 356, 356, 356, 356, 356, 356, 356, 356, 356, 356, 383, 641, 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, 384, 384, 384, 384, 384, 384, 384, 384, 384, 384, 762, 762, 781, 781, 384, 384, 384, 384, 384, 489, 489, 489, 489, 489, 489, 489, 489, 632, 882, 882, 611, 489, 611, 611, 611, 611, 611, 611, 384, 384, 384, 384, 384, 384, 399, 399, 399, 399, 399, 399, 399, 399, 399, 399, 491, 491, 491, 491, 491, 491, 491, 491, 491, 491, 532, 532, 532, 532, 532, 532, 532, 532, 532, 532, 639, 681, 639, 639, 639, 649, 399, 401, 596, 401, 401, 401, 401, 401, 401, 401, 401, 401, 401, 402, 596, 402, 402, 402, 402, 402, 402, 402, 402, 402, 402, 408, 408, 408, 408, 408, 408, 408, 408, 408, 408, 408, 701, 649, 728, 408, 408, 408, 408, 408, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 675, 836, 742, 787, 836, 547, 701, 673, 728, 408, 408, 408, 408, 408, 408, 412, 547, 412, 412, 412, 412, 412, 412, 412, 412, 412, 412, 418, 418, 418, 418, 418, 418, 418, 418, 418, 418, 418, 418, 418, 742, 787, 670, 418, 418, 418, 418, 418, 538, 598, 538, 538, 538, 538, 538, 538, 827, 827, 827, 669, 538, 598, 634, 739, 634, 634, 634, 418, 418, 418, 418, 418, 418, 421, 421, 421, 421, 421, 421, 421, 421, 421, 421, 421, 421, 421, 853, 739, 853, 421, 421, 421, 421, 421, 540, 540, 540, 540, 540, 540, 540, 540, 540, 540, 578, 578, 578, 578, 578, 578, 578, 656, 634, 421, 421, 421, 421, 421, 421, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, 548, 549, 549, 424, 424, 424, 424, 424, 550, 550, 612, 548, 613, 549, 552, 552, 844, 844, 844, 655, 550, 612, 657, 613, 759, 642, 552, 424, 424, 424, 424, 424, 424, 425, 657, 425, 425, 425, 425, 425, 425, 425, 425, 425, 425, 426, 653, 768, 759, 642, 854, 426, 854, 916, 426, 426, 916, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 642, 768, 652, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, 464, 464, 464, 464, 464, 464, 464, 464, 464, 464, 464, 555, 555, 555, 555, 555, 555, 555, 555, 865, 651, 865, 658, 555, 557, 557, 557, 557, 557, 557, 557, 557, 557, 557, 658, 883, 883, 464, 471, 660, 471, 471, 471, 471, 471, 471, 471, 471, 471, 471, 471, 660, 637, 702, 471, 471, 471, 471, 471, 574, 574, 574, 574, 574, 574, 574, 574, 574, 574, 619, 619, 619, 619, 619, 619, 619, 619, 702, 471, 471, 471, 471, 471, 471, 474, 474, 474, 474, 474, 474, 474, 474, 474, 474, 474, 778, 636, 702, 474, 474, 474, 474, 474, 587, 587, 587, 587, 587, 587, 587, 587, 587, 587, 866, 870, 866, 870, 614, 614, 778, 894, 894, 474, 474, 474, 474, 474, 474, 475, 614, 475, 475, 475, 475, 475, 475, 475, 475, 475, 475, 487, 487, 487, 487, 487, 487, 487, 487, 487, 487, 487, 487, 487, 678, 629, 703, 487, 487, 487, 487, 487, 588, 588, 588, 588, 588, 588, 588, 588, 588, 588, 635, 610, 635, 635, 635, 871, 678, 871, 703, 487, 487, 487, 487, 487, 487, 490, 490, 490, 490, 490, 490, 490, 490, 490, 490, 490, 490, 490, 678, 703, 740, 490, 490, 490, 490, 490, 597, 597, 597, 597, 597, 597, 597, 597, 597, 597, 875, 878, 875, 878, 635, 888, 609, 888, 740, 490, 490, 490, 490, 490, 490, 493, 493, 493, 493, 493, 493, 493, 493, 493, 493, 493, 608, 889, 740, 889, 493, 493, 493, 493, 493, 601, 594, 601, 601, 601, 601, 601, 601, 897, 592, 897, 654, 601, 654, 654, 654, 654, 654, 654, 493, 493, 493, 493, 493, 493, 494, 712, 494, 494, 494, 494, 494, 494, 494, 494, 494, 494, 495, 712, 898, 901, 898, 901, 495, 692, 692, 495, 495, 692, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 692, 692, 692, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 495, 517, 517, 517, 517, 517, 517, 517, 517, 517, 517, 517, 522, 913, 913, 713, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 713, 522, 914, 914, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 591, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 522, 525, 525, 525, 525, 525, 525, 525, 525, 525, 525, 603, 603, 603, 603, 603, 603, 603, 603, 603, 603, 607, 607, 607, 607, 607, 607, 607, 607, 607, 607, 666, 666, 666, 666, 666, 666, 525, 527, 527, 527, 527, 527, 527, 527, 527, 527, 527, 527, 650, 650, 650, 650, 650, 650, 650, 650, 650, 650, 659, 659, 659, 659, 659, 659, 659, 659, 659, 659, 721, 721, 721, 721, 721, 721, 527, 536, 715, 536, 536, 536, 536, 536, 536, 536, 536, 536, 536, 536, 715, 590, 582, 536, 536, 536, 536, 536, 663, 753, 663, 663, 663, 663, 663, 663, 907, 908, 907, 908, 663, 753, 687, 672, 687, 687, 687, 536, 536, 536, 536, 536, 536, 539, 672, 539, 539, 539, 539, 539, 539, 539, 539, 539, 539, 539, 730, 581, 580, 539, 539, 539, 539, 539, 665, 665, 665, 665, 665, 665, 665, 665, 665, 665, 688, 579, 688, 688, 688, 910, 730, 910, 687, 539, 539, 539, 539, 539, 539, 542, 542, 542, 542, 542, 542, 542, 542, 542, 542, 542, 577, 576, 730, 542, 542, 542, 542, 542, 695, 695, 695, 695, 695, 695, 695, 695, 695, 695, 794, 794, 794, 794, 794, 794, 688, 575, 573, 542, 542, 542, 542, 542, 542, 543, 569, 543, 543, 543, 543, 543, 543, 543, 543, 543, 543, 546, 568, 546, 546, 546, 546, 546, 546, 546, 546, 546, 546, 553, 553, 553, 553, 553, 553, 553, 553, 553, 553, 553, 553, 553, 567, 551, 761, 553, 553, 553, 553, 553, 689, 545, 689, 689, 689, 690, 544, 690, 690, 690, 699, 531, 699, 699, 699, 699, 699, 699, 761, 553, 553, 553, 553, 553, 553, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 918, 530, 918, 761, 556, 556, 556, 556, 556, 919, 923, 919, 923, 689, 924, 929, 924, 929, 690, 726, 726, 726, 726, 726, 726, 726, 524, 521, 556, 556, 556, 556, 556, 556, 559, 520, 559, 559, 559, 559, 559, 559, 559, 559, 559, 559, 560, 694, 519, 694, 694, 694, 560, 694, 694, 560, 560, 694, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 694, 694, 694, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 560, 583, 750, 518, 750, 750, 750, 750, 750, 750, 583, 930, 516, 930, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 515, 510, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 509, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 583, 586, 479, 586, 586, 586, 586, 586, 586, 586, 586, 586, 586, 714, 714, 714, 714, 714, 714, 714, 714, 714, 714, 718, 478, 718, 718, 718, 718, 718, 718, 922, 477, 469, 922, 718, 468, 467, 922, 586, 593, 463, 593, 593, 593, 593, 593, 593, 593, 593, 593, 593, 599, 456, 599, 599, 599, 599, 599, 599, 599, 599, 599, 599, 599, 455, 452, 451, 599, 599, 599, 599, 599, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 758, 449, 758, 758, 758, 758, 758, 758, 448, 599, 599, 599, 599, 599, 599, 602, 447, 602, 602, 602, 602, 602, 602, 602, 602, 602, 602, 602, 441, 440, 438, 602, 602, 602, 602, 602, 734, 734, 734, 734, 734, 734, 734, 734, 734, 734, 767, 437, 767, 767, 767, 767, 767, 767, 436, 602, 602, 602, 602, 602, 602, 605, 605, 605, 605, 605, 605, 605, 605, 605, 605, 605, 435, 411, 410, 605, 605, 605, 605, 605, 735, 735, 735, 735, 735, 735, 735, 735, 735, 735, 407, 745, 406, 745, 745, 745, 745, 745, 745, 605, 605, 605, 605, 605, 605, 606, 405, 606, 606, 606, 606, 606, 606, 606, 606, 606, 606, 617, 617, 617, 617, 617, 617, 617, 617, 617, 617, 617, 617, 745, 404, 398, 397, 617, 617, 617, 617, 617, 746, 746, 746, 746, 746, 746, 746, 746, 746, 746, 800, 396, 800, 800, 800, 800, 800, 800, 395, 617, 617, 617, 617, 617, 617, 638, 394, 638, 638, 638, 638, 638, 638, 638, 638, 638, 638, 644, 644, 644, 644, 644, 644, 644, 644, 644, 644, 763, 763, 763, 763, 763, 763, 763, 763, 763, 763, 772, 772, 772, 772, 772, 772, 772, 772, 772, 772, 812, 812, 812, 812, 812, 812, 644, 646, 393, 646, 646, 646, 646, 646, 646, 646, 646, 646, 646, 773, 773, 773, 773, 773, 773, 773, 773, 773, 773, 774, 774, 774, 774, 774, 774, 774, 774, 774, 774, 392, 928, 391, 390, 928, 389, 646, 661, 928, 661, 661, 661, 661, 661, 661, 661, 661, 661, 661, 661, 388, 387, 386, 661, 661, 661, 661, 661, 790, 385, 790, 790, 790, 790, 790, 790, 792, 792, 792, 792, 792, 792, 792, 792, 792, 792, 382, 661, 661, 661, 661, 661, 661, 664, 381, 664, 664, 664, 664, 664, 664, 664, 664, 664, 664, 664, 790, 376, 375, 664, 664, 664, 664, 664, 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, 374, 368, 366, 365, 364, 363, 362, 361, 360, 664, 664, 664, 664, 664, 664, 667, 667, 667, 667, 667, 667, 667, 667, 667, 667, 359, 343, 342, 341, 667, 667, 667, 667, 667, 796, 796, 796, 796, 796, 796, 796, 796, 796, 796, 340, 338, 337, 809, 809, 809, 809, 809, 809, 667, 667, 667, 667, 667, 667, 668, 333, 668, 668, 668, 668, 668, 668, 668, 668, 668, 668, 671, 671, 671, 671, 671, 671, 671, 671, 671, 671, 671, 704, 809, 704, 704, 704, 704, 704, 704, 704, 704, 704, 704, 705, 332, 705, 705, 705, 705, 705, 705, 705, 705, 705, 705, 706, 331, 706, 706, 706, 706, 706, 706, 706, 706, 706, 706, 709, 329, 709, 709, 709, 709, 709, 709, 709, 709, 709, 709, 716, 328, 716, 716, 716, 716, 716, 716, 716, 716, 716, 716, 716, 327, 326, 325, 716, 716, 716, 716, 716, 804, 804, 804, 804, 804, 804, 804, 804, 804, 804, 324, 318, 317, 316, 309, 308, 307, 306, 305, 716, 716, 716, 716, 716, 716, 719, 299, 719, 719, 719, 719, 719, 719, 719, 719, 719, 719, 297, 296, 295, 294, 719, 719, 719, 719, 719, 805, 805, 805, 805, 805, 805, 805, 805, 805, 805, 293, 292, 290, 288, 280, 279, 276, 275, 268, 719, 719, 719, 719, 719, 719, 738, 267, 738, 738, 738, 738, 738, 738, 738, 738, 738, 738, 741, 265, 741, 741, 741, 741, 741, 741, 741, 741, 741, 741, 743, 264, 743, 743, 743, 743, 743, 743, 743, 743, 743, 743, 744, 263, 744, 744, 744, 744, 744, 744, 744, 744, 744, 744, 756, 262, 756, 756, 756, 756, 756, 756, 756, 756, 756, 756, 769, 261, 769, 769, 769, 769, 769, 769, 769, 769, 769, 769, 770, 260, 770, 770, 770, 770, 770, 770, 770, 770, 770, 770, 771, 259, 771, 771, 771, 771, 771, 771, 771, 771, 771, 771, 785, 258, 785, 785, 785, 785, 785, 785, 785, 785, 785, 785, 786, 255, 786, 786, 786, 786, 786, 786, 786, 786, 786, 786, 788, 252, 788, 788, 788, 788, 788, 788, 788, 788, 788, 788, 789, 251, 789, 789, 789, 789, 789, 789, 789, 789, 789, 789, 801, 801, 801, 801, 801, 801, 801, 801, 801, 801, 806, 806, 806, 806, 806, 806, 806, 806, 806, 806, 811, 811, 811, 811, 811, 811, 811, 811, 811, 811, 250, 244, 241, 240, 239, 238, 801, 802, 802, 802, 802, 802, 802, 802, 802, 802, 802, 237, 234, 233, 232, 231, 230, 229, 228, 227, 226, 225, 224, 223, 217, 216, 209, 208, 207, 206, 205, 204, 202, 201, 199, 193, 185, 802, 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, 181, 177, 176, 174, 170, 163, 159, 157, 155, 147, 146, 145, 144, 143, 137, 136, 135, 134, 133, 131, 130, 129, 128, 124, 120, 119, 803, 808, 808, 808, 808, 808, 808, 808, 808, 808, 808, 115, 112, 109, 104, 103, 102, 100, 96, 95, 94, 93, 90, 77, 70, 63, 59, 58, 56, 55, 53, 51, 43, 42, 41, 39, 35, 808, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 815, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 816, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, 818, 31, 25, 19, 17, 16, 15, 818, 0, 818, 818, 818, 818, 0, 0, 818, 818, 818, 818, 818, 818, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, 820, 0, 0, 0, 0, 820, 0, 820, 0, 820, 820, 820, 820, 820, 0, 820, 820, 820, 820, 820, 820, 821, 0, 0, 0, 0, 0, 0, 821, 0, 821, 821, 821, 821, 0, 0, 821, 821, 821, 821, 821, 821, 822, 0, 0, 822, 822, 0, 822, 822, 0, 822, 822, 822, 822, 0, 0, 822, 822, 822, 822, 822, 822, 823, 823, 0, 823, 0, 0, 0, 823, 825, 0, 0, 825, 825, 0, 825, 825, 0, 825, 825, 825, 825, 0, 0, 825, 825, 825, 825, 825, 825, 826, 0, 0, 826, 826, 0, 826, 826, 0, 826, 826, 826, 826, 0, 826, 826, 826, 0, 826, 826, 826, 828, 0, 0, 828, 0, 0, 828, 828, 0, 828, 828, 828, 828, 828, 0, 828, 828, 828, 828, 828, 828, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 829, 830, 830, 0, 830, 0, 830, 830, 830, 830, 830, 830, 830, 830, 830, 830, 830, 830, 830, 830, 830, 830, 831, 0, 0, 0, 0, 831, 0, 831, 0, 831, 831, 831, 831, 831, 0, 831, 831, 831, 831, 831, 831, 832, 0, 0, 0, 0, 0, 0, 832, 0, 832, 832, 832, 832, 0, 832, 832, 832, 832, 832, 832, 832, 833, 0, 0, 833, 833, 0, 833, 833, 0, 833, 833, 833, 833, 0, 833, 833, 833, 833, 833, 833, 833, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 834, 835, 835, 0, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 835, 837, 0, 0, 837, 837, 0, 837, 837, 0, 837, 837, 837, 837, 0, 0, 837, 837, 837, 837, 837, 837, 838, 838, 0, 838, 0, 0, 0, 838, 839, 839, 0, 839, 0, 0, 0, 839, 840, 840, 840, 0, 840, 0, 0, 0, 840, 841, 0, 0, 841, 841, 0, 841, 841, 0, 841, 841, 841, 841, 0, 0, 841, 841, 841, 841, 841, 841, 842, 0, 0, 842, 842, 0, 842, 842, 0, 842, 842, 842, 842, 0, 0, 842, 842, 842, 842, 842, 842, 843, 0, 0, 843, 843, 0, 843, 843, 0, 843, 843, 843, 843, 0, 843, 843, 843, 0, 843, 843, 843, 845, 0, 0, 845, 0, 0, 845, 845, 0, 845, 845, 845, 845, 845, 0, 845, 845, 845, 845, 845, 845, 846, 0, 0, 0, 0, 0, 0, 846, 0, 846, 846, 846, 846, 0, 0, 846, 846, 846, 846, 846, 846, 847, 0, 0, 0, 0, 0, 0, 847, 0, 847, 847, 847, 847, 0, 847, 847, 847, 847, 847, 847, 847, 848, 0, 0, 848, 848, 0, 848, 848, 0, 848, 848, 848, 848, 0, 848, 848, 848, 848, 848, 848, 848, 849, 0, 0, 849, 849, 0, 849, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, 851, 851, 0, 851, 0, 0, 0, 851, 852, 852, 852, 0, 852, 0, 0, 0, 852, 855, 855, 0, 855, 0, 0, 0, 855, 856, 856, 0, 856, 0, 0, 0, 856, 857, 857, 0, 857, 0, 0, 0, 857, 858, 858, 858, 0, 858, 0, 0, 0, 858, 859, 0, 0, 859, 859, 0, 859, 860, 860, 0, 860, 0, 0, 0, 860, 861, 861, 0, 861, 0, 0, 0, 861, 862, 862, 0, 862, 0, 0, 0, 862, 863, 863, 863, 0, 863, 0, 0, 0, 863, 864, 864, 864, 864, 0, 864, 0, 0, 0, 864, 867, 867, 0, 867, 0, 0, 0, 867, 868, 868, 0, 868, 0, 0, 0, 868, 869, 869, 0, 869, 0, 0, 0, 869, 872, 872, 872, 0, 872, 0, 0, 0, 872, 873, 873, 873, 873, 0, 873, 0, 0, 0, 873, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, 876, 876, 0, 876, 0, 0, 0, 876, 877, 877, 0, 877, 0, 0, 0, 877, 879, 879, 879, 0, 879, 0, 0, 0, 879, 880, 880, 880, 880, 0, 880, 0, 0, 0, 880, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, 884, 0, 0, 884, 884, 0, 884, 885, 0, 0, 0, 885, 885, 0, 885, 885, 885, 0, 0, 885, 885, 886, 886, 0, 886, 0, 0, 0, 886, 887, 0, 887, 887, 0, 887, 0, 0, 0, 887, 890, 890, 890, 0, 890, 0, 0, 0, 890, 891, 891, 891, 891, 0, 891, 0, 0, 0, 891, 892, 892, 0, 0, 892, 0, 0, 0, 892, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 893, 895, 0, 0, 895, 895, 0, 895, 896, 0, 0, 0, 896, 896, 0, 896, 896, 896, 0, 0, 896, 896, 899, 899, 0, 899, 0, 0, 0, 899, 900, 0, 900, 900, 0, 900, 0, 0, 0, 900, 902, 902, 902, 0, 902, 0, 0, 0, 902, 903, 903, 903, 0, 0, 903, 0, 0, 0, 903, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 904, 905, 905, 0, 905, 905, 905, 0, 905, 0, 905, 905, 905, 905, 0, 0, 905, 905, 905, 905, 905, 905, 906, 906, 0, 906, 906, 906, 0, 906, 0, 906, 906, 906, 906, 0, 0, 906, 906, 906, 906, 906, 906, 909, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 909, 909, 0, 909, 909, 0, 909, 911, 911, 0, 911, 0, 0, 0, 911, 912, 0, 912, 912, 0, 912, 0, 0, 0, 912, 915, 915, 0, 0, 915, 0, 0, 0, 915, 917, 0, 0, 0, 0, 0, 0, 917, 0, 917, 917, 917, 917, 0, 0, 917, 917, 917, 917, 917, 917, 920, 920, 0, 920, 0, 0, 0, 920, 921, 0, 921, 921, 0, 921, 0, 0, 0, 921, 925, 925, 0, 925, 0, 0, 0, 925, 926, 0, 926, 0, 0, 926, 0, 0, 0, 926, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 927, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, 813 } ; static yy_state_type yy_last_accepting_state; static char *yy_last_accepting_cpos; /* The intent behind this definition is that it'll catch * any uses of REJECT which flex missed. */ #define REJECT reject_used_but_not_detected #define yymore() yymore_used_but_not_detected #define YY_MORE_ADJ 0 #define YY_RESTORE_YY_MORE_OFFSET char *yytext; #line 1 "toke.l" #define INITIAL 0 #line 2 "toke.l" /* * Copyright (c) 1996, 1998-2005, 2007-2013 * Todd C. Miller * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * * Sponsored in part by the Defense Advanced Research Projects * Agency (DARPA) and Air Force Research Laboratory, Air Force * Materiel Command, USAF, under agreement number F39502-99-1-0512. */ #include #include #include #include #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif /* STDC_HEADERS */ #ifdef HAVE_STRING_H # include #endif /* HAVE_STRING_H */ #ifdef HAVE_STRINGS_H # include #endif /* HAVE_STRINGS_H */ #if defined(HAVE_STDINT_H) # include #elif defined(HAVE_INTTYPES_H) # include #endif #ifdef HAVE_UNISTD_H # include #endif /* HAVE_UNISTD_H */ #if defined(HAVE_MALLOC_H) && !defined(STDC_HEADERS) # include #endif /* HAVE_MALLOC_H && !STDC_HEADERS */ #ifdef HAVE_DIRENT_H # include # define NAMLEN(dirent) strlen((dirent)->d_name) #else # define dirent direct # define NAMLEN(dirent) (dirent)->d_namlen # ifdef HAVE_SYS_NDIR_H # include # endif # ifdef HAVE_SYS_DIR_H # include # endif # ifdef HAVE_NDIR_H # include # endif #endif #include #include #include "sudoers.h" #include "parse.h" #include "toke.h" #include #include "lbuf.h" #include "sha2.h" #include "secure_path.h" extern YYSTYPE sudoerslval; extern bool parse_error; extern bool sudoers_warnings; int sudolineno; int last_token; char *sudoers; /* Default sudoers path, mode and owner (may be set via sudo.conf) */ const char *sudoers_file = _PATH_SUDOERS; mode_t sudoers_mode = SUDOERS_MODE; uid_t sudoers_uid = SUDOERS_UID; gid_t sudoers_gid = SUDOERS_GID; static bool continued, sawspace; static int prev_state; static int digest_len; static bool _push_include(char *, bool); static bool pop_include(void); static char *parse_include(char *); int (*trace_print)(const char *msg) = sudoers_trace_print; #define LEXRETURN(n) do { \ last_token = (n); \ return (n); \ } while (0) #define ECHO ignore_result(fwrite(sudoerstext, sudoersleng, 1, sudoersout)) #define push_include(_p) (_push_include((_p), false)) #define push_includedir(_p) (_push_include((_p), true)) #define YY_NO_INPUT 1 #define YY_NO_UNPUT 1 #define GOTDEFS 1 #define GOTCMND 2 #define STARTDEFS 3 #define INDEFS 4 #define INSTR 5 #define WANTDIGEST 6 #line 2056 "lex.sudoers.c" /* Macros after this point can all be overridden by user definitions in * section 1. */ #ifndef YY_SKIP_YYWRAP #ifdef __cplusplus extern "C" int yywrap YY_PROTO(( void )); #else extern int yywrap YY_PROTO(( void )); #endif #endif #ifndef YY_NO_UNPUT static void yyunput YY_PROTO(( int c, char *buf_ptr )); #endif #ifndef yytext_ptr static void yy_flex_strncpy YY_PROTO(( char *, yyconst char *, int )); #endif #ifdef YY_NEED_STRLEN static int yy_flex_strlen YY_PROTO(( yyconst char * )); #endif #ifndef YY_NO_INPUT #ifdef __cplusplus static int yyinput YY_PROTO(( void )); #else static int input YY_PROTO(( void )); #endif #endif #if defined(YY_STACK_USED) && YY_STACK_USED static int yy_start_stack_ptr = 0; static int yy_start_stack_depth = 0; static int *yy_start_stack = 0; #ifndef YY_NO_PUSH_STATE static void yy_push_state YY_PROTO(( int new_state )); #endif #ifndef YY_NO_POP_STATE static void yy_pop_state YY_PROTO(( void )); #endif #ifndef YY_NO_TOP_STATE static int yy_top_state YY_PROTO(( void )); #endif #else #define YY_NO_PUSH_STATE 1 #define YY_NO_POP_STATE 1 #define YY_NO_TOP_STATE 1 #endif #ifdef YY_MALLOC_DECL YY_MALLOC_DECL #else #ifdef __STDC__ #ifndef __cplusplus #include #endif #else /* Just try to get by without declaring the routines. This will fail * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int) * or sizeof(void*) != sizeof(int). */ #endif #endif /* Amount of stuff to slurp up with each read. */ #ifndef YY_READ_BUF_SIZE #define YY_READ_BUF_SIZE 8192 #endif /* Copy whatever the last rule matched to the standard output. */ #ifndef ECHO /* This used to be an fputs(), but since the string might contain NUL's, * we now use fwrite(). */ #define ECHO (void) fwrite( yytext, yyleng, 1, yyout ) #endif /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, * is returned in "result". */ #ifndef YY_INPUT #define YY_INPUT(buf,result,max_size) \ if ( yy_current_buffer->yy_is_interactive ) \ { \ int c = '*', n; \ for ( n = 0; n < max_size && \ (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ buf[n] = (char) c; \ if ( c == '\n' ) \ buf[n++] = (char) c; \ if ( c == EOF && ferror( yyin ) ) \ YY_FATAL_ERROR( "input in flex scanner failed" ); \ result = n; \ } \ else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \ && ferror( yyin ) ) \ YY_FATAL_ERROR( "input in flex scanner failed" ); #endif /* No semi-colon after return; correct usage is to write "yyterminate();" - * we don't want an extra ';' after the "return" because that will cause * some compilers to complain about unreachable statements. */ #ifndef yyterminate #define yyterminate() return YY_NULL #endif /* Number of entries by which start-condition stack grows. */ #ifndef YY_START_STACK_INCR #define YY_START_STACK_INCR 25 #endif /* Report a fatal error. */ #ifndef YY_FATAL_ERROR #define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) #endif /* Default declaration of generated scanner - a define so the user can * easily add parameters. */ #ifndef YY_DECL #define YY_DECL int yylex YY_PROTO(( void )) #endif /* Code executed at the beginning of each rule, after yytext and yyleng * have been set up. */ #ifndef YY_USER_ACTION #define YY_USER_ACTION #endif /* Code executed at the end of each rule. */ #ifndef YY_BREAK #define YY_BREAK break; #endif #define YY_RULE_SETUP \ if ( yyleng > 0 ) \ yy_current_buffer->yy_at_bol = \ (yytext[yyleng - 1] == '\n'); \ YY_USER_ACTION YY_DECL { register yy_state_type yy_current_state; register char *yy_cp, *yy_bp; register int yy_act; #line 140 "toke.l" #line 2212 "lex.sudoers.c" if ( yy_init ) { yy_init = 0; #ifdef YY_USER_INIT YY_USER_INIT; #endif if ( ! yy_start ) yy_start = 1; /* first start state */ if ( ! yyin ) yyin = stdin; if ( ! yyout ) yyout = stdout; if ( ! yy_current_buffer ) yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); yy_load_buffer_state(); } while ( 1 ) /* loops until end-of-file is reached */ { yy_cp = yy_c_buf_p; /* Support of yytext. */ *yy_cp = yy_hold_char; /* yy_bp points to the position in yy_ch_buf of the start of * the current run. */ yy_bp = yy_cp; yy_current_state = yy_start; yy_current_state += YY_AT_BOL(); yy_match: do { register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; if ( yy_accept[yy_current_state] ) { yy_last_accepting_state = yy_current_state; yy_last_accepting_cpos = yy_cp; } while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 814 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; ++yy_cp; } while ( yy_base[yy_current_state] != 5604 ); yy_find_action: yy_act = yy_accept[yy_current_state]; if ( yy_act == 0 ) { /* have to back up */ yy_cp = yy_last_accepting_cpos; yy_current_state = yy_last_accepting_state; yy_act = yy_accept[yy_current_state]; } YY_DO_BEFORE_ACTION; do_action: /* This label is used only to access EOF actions. */ switch ( yy_act ) { /* beginning of action switch */ case 0: /* must back up */ /* undo the effects of YY_DO_BEFORE_ACTION */ *yy_cp = yy_hold_char; yy_cp = yy_last_accepting_cpos; yy_current_state = yy_last_accepting_state; goto yy_find_action; case 1: YY_RULE_SETUP #line 141 "toke.l" { LEXTRACE(", "); LEXRETURN(','); } /* return ',' */ YY_BREAK case 2: YY_RULE_SETUP #line 146 "toke.l" BEGIN STARTDEFS; YY_BREAK case 3: YY_RULE_SETUP #line 148 "toke.l" { BEGIN INDEFS; LEXTRACE("DEFVAR "); if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXRETURN(DEFVAR); } YY_BREAK case 4: YY_RULE_SETUP #line 157 "toke.l" { BEGIN STARTDEFS; LEXTRACE(", "); LEXRETURN(','); } /* return ',' */ YY_BREAK case 5: YY_RULE_SETUP #line 163 "toke.l" { LEXTRACE("= "); LEXRETURN('='); } /* return '=' */ YY_BREAK case 6: YY_RULE_SETUP #line 168 "toke.l" { LEXTRACE("+= "); LEXRETURN('+'); } /* return '+' */ YY_BREAK case 7: YY_RULE_SETUP #line 173 "toke.l" { LEXTRACE("-= "); LEXRETURN('-'); } /* return '-' */ YY_BREAK case 8: YY_RULE_SETUP #line 178 "toke.l" { LEXTRACE("BEGINSTR "); sudoerslval.string = NULL; prev_state = YY_START; BEGIN INSTR; } YY_BREAK case 9: YY_RULE_SETUP #line 185 "toke.l" { LEXTRACE("WORD(2) "); if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXRETURN(WORD); } YY_BREAK case 10: YY_RULE_SETUP #line 194 "toke.l" { /* Line continuation char followed by newline. */ sudolineno++; continued = true; } YY_BREAK case 11: YY_RULE_SETUP #line 200 "toke.l" { LEXTRACE("ENDSTR "); BEGIN prev_state; if (sudoerslval.string == NULL) { LEXTRACE("ERROR "); /* empty string */ LEXRETURN(ERROR); } if (prev_state == INITIAL) { switch (sudoerslval.string[0]) { case '%': if (sudoerslval.string[1] == '\0' || (sudoerslval.string[1] == ':' && sudoerslval.string[2] == '\0')) { LEXTRACE("ERROR "); /* empty group */ LEXRETURN(ERROR); } LEXTRACE("USERGROUP "); LEXRETURN(USERGROUP); case '+': if (sudoerslval.string[1] == '\0') { LEXTRACE("ERROR "); /* empty netgroup */ LEXRETURN(ERROR); } LEXTRACE("NETGROUP "); LEXRETURN(NETGROUP); } } LEXTRACE("WORD(4) "); LEXRETURN(WORD); } YY_BREAK case 12: YY_RULE_SETUP #line 232 "toke.l" { LEXTRACE("BACKSLASH "); if (!append(sudoerstext, sudoersleng)) yyterminate(); } YY_BREAK case 13: YY_RULE_SETUP #line 238 "toke.l" { LEXTRACE("STRBODY "); if (!append(sudoerstext, sudoersleng)) yyterminate(); } YY_BREAK case 14: YY_RULE_SETUP #line 246 "toke.l" { /* quoted fnmatch glob char, pass verbatim */ LEXTRACE("QUOTEDCHAR "); if (!fill_args(sudoerstext, 2, sawspace)) yyterminate(); sawspace = false; } YY_BREAK case 15: YY_RULE_SETUP #line 254 "toke.l" { /* quoted sudoers special char, strip backslash */ LEXTRACE("QUOTEDCHAR "); if (!fill_args(sudoerstext + 1, 1, sawspace)) yyterminate(); sawspace = false; } YY_BREAK case 16: YY_RULE_SETUP #line 262 "toke.l" { BEGIN INITIAL; yyless(0); LEXRETURN(COMMAND); } /* end of command line args */ YY_BREAK case 17: YY_RULE_SETUP #line 268 "toke.l" { LEXTRACE("ARG "); if (!fill_args(sudoerstext, sudoersleng, sawspace)) yyterminate(); sawspace = false; } /* a command line arg */ YY_BREAK case 18: YY_RULE_SETUP #line 276 "toke.l" { /* Only return DIGEST if the length is correct. */ if (sudoersleng == digest_len * 2) { if (!fill(sudoerstext, sudoersleng)) yyterminate(); BEGIN INITIAL; LEXTRACE("DIGEST "); LEXRETURN(DIGEST); } BEGIN INITIAL; yyless(sudoersleng); } /* hex digest */ YY_BREAK case 19: YY_RULE_SETUP #line 289 "toke.l" { /* Only return DIGEST if the length is correct. */ size_t len; if (sudoerstext[sudoersleng - 1] == '=') { /* use padding */ len = 4 * ((digest_len + 2) / 3); } else { /* no padding */ len = (4 * digest_len + 2) / 3; } if (sudoersleng == len) { if (!fill(sudoerstext, sudoersleng)) yyterminate(); BEGIN INITIAL; LEXTRACE("DIGEST "); LEXRETURN(DIGEST); } BEGIN INITIAL; yyless(sudoersleng); } /* base64 digest */ YY_BREAK case 20: YY_RULE_SETUP #line 310 "toke.l" { char *path; if (continued) { LEXTRACE("ERROR "); LEXRETURN(ERROR); } if ((path = parse_include(sudoerstext)) == NULL) yyterminate(); LEXTRACE("INCLUDE\n"); /* Push current buffer and switch to include file */ if (!push_include(path)) yyterminate(); } YY_BREAK case 21: YY_RULE_SETUP #line 328 "toke.l" { char *path; if (continued) { LEXTRACE("ERROR "); LEXRETURN(ERROR); } if ((path = parse_include(sudoerstext)) == NULL) yyterminate(); LEXTRACE("INCLUDEDIR\n"); /* * Push current buffer and switch to include file. * We simply ignore empty directories. */ if (!push_includedir(path) && parse_error) yyterminate(); } YY_BREAK case 22: YY_RULE_SETUP #line 349 "toke.l" { char deftype; int n; if (continued) { LEXTRACE("ERROR "); LEXRETURN(ERROR); } for (n = 0; isblank((unsigned char)sudoerstext[n]); n++) continue; n += sizeof("Defaults") - 1; if ((deftype = sudoerstext[n++]) != '\0') { while (isblank((unsigned char)sudoerstext[n])) n++; } BEGIN GOTDEFS; switch (deftype) { case ':': yyless(n); LEXTRACE("DEFAULTS_USER "); LEXRETURN(DEFAULTS_USER); case '>': yyless(n); LEXTRACE("DEFAULTS_RUNAS "); LEXRETURN(DEFAULTS_RUNAS); case '@': yyless(n); LEXTRACE("DEFAULTS_HOST "); LEXRETURN(DEFAULTS_HOST); case '!': yyless(n); LEXTRACE("DEFAULTS_CMND "); LEXRETURN(DEFAULTS_CMND); default: LEXTRACE("DEFAULTS "); LEXRETURN(DEFAULTS); } } YY_BREAK case 23: YY_RULE_SETUP #line 389 "toke.l" { int n; if (continued) { LEXTRACE("ERROR "); LEXRETURN(ERROR); } for (n = 0; isblank((unsigned char)sudoerstext[n]); n++) continue; switch (sudoerstext[n]) { case 'H': LEXTRACE("HOSTALIAS "); LEXRETURN(HOSTALIAS); case 'C': LEXTRACE("CMNDALIAS "); LEXRETURN(CMNDALIAS); case 'U': LEXTRACE("USERALIAS "); LEXRETURN(USERALIAS); case 'R': LEXTRACE("RUNASALIAS "); LEXRETURN(RUNASALIAS); } } YY_BREAK case 24: YY_RULE_SETUP #line 415 "toke.l" { /* cmnd does not require passwd for this user */ LEXTRACE("NOPASSWD "); LEXRETURN(NOPASSWD); } YY_BREAK case 25: YY_RULE_SETUP #line 421 "toke.l" { /* cmnd requires passwd for this user */ LEXTRACE("PASSWD "); LEXRETURN(PASSWD); } YY_BREAK case 26: YY_RULE_SETUP #line 427 "toke.l" { LEXTRACE("NOEXEC "); LEXRETURN(NOEXEC); } YY_BREAK case 27: YY_RULE_SETUP #line 432 "toke.l" { LEXTRACE("EXEC "); LEXRETURN(EXEC); } YY_BREAK case 28: YY_RULE_SETUP #line 437 "toke.l" { LEXTRACE("SETENV "); LEXRETURN(SETENV); } YY_BREAK case 29: YY_RULE_SETUP #line 442 "toke.l" { LEXTRACE("NOSETENV "); LEXRETURN(NOSETENV); } YY_BREAK case 30: YY_RULE_SETUP #line 447 "toke.l" { LEXTRACE("LOG_OUTPUT "); LEXRETURN(LOG_OUTPUT); } YY_BREAK case 31: YY_RULE_SETUP #line 452 "toke.l" { LEXTRACE("NOLOG_OUTPUT "); LEXRETURN(NOLOG_OUTPUT); } YY_BREAK case 32: YY_RULE_SETUP #line 457 "toke.l" { LEXTRACE("LOG_INPUT "); LEXRETURN(LOG_INPUT); } YY_BREAK case 33: YY_RULE_SETUP #line 462 "toke.l" { LEXTRACE("NOLOG_INPUT "); LEXRETURN(NOLOG_INPUT); } YY_BREAK case 34: YY_RULE_SETUP #line 467 "toke.l" { /* empty group or netgroup */ LEXTRACE("ERROR "); LEXRETURN(ERROR); } YY_BREAK case 35: YY_RULE_SETUP #line 473 "toke.l" { /* netgroup */ if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("NETGROUP "); LEXRETURN(NETGROUP); } YY_BREAK case 36: YY_RULE_SETUP #line 481 "toke.l" { /* group */ if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("USERGROUP "); LEXRETURN(USERGROUP); } YY_BREAK case 37: YY_RULE_SETUP #line 489 "toke.l" { if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("NTWKADDR "); LEXRETURN(NTWKADDR); } YY_BREAK case 38: YY_RULE_SETUP #line 496 "toke.l" { if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("NTWKADDR "); LEXRETURN(NTWKADDR); } YY_BREAK case 39: YY_RULE_SETUP #line 503 "toke.l" { if (!ipv6_valid(sudoerstext)) { LEXTRACE("ERROR "); LEXRETURN(ERROR); } if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("NTWKADDR "); LEXRETURN(NTWKADDR); } YY_BREAK case 40: YY_RULE_SETUP #line 514 "toke.l" { if (!ipv6_valid(sudoerstext)) { LEXTRACE("ERROR "); LEXRETURN(ERROR); } if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("NTWKADDR "); LEXRETURN(NTWKADDR); } YY_BREAK case 41: YY_RULE_SETUP #line 525 "toke.l" { LEXTRACE("ALL "); LEXRETURN(ALL); } YY_BREAK case 42: YY_RULE_SETUP #line 531 "toke.l" { #ifdef HAVE_SELINUX LEXTRACE("ROLE "); LEXRETURN(ROLE); #else goto got_alias; #endif } YY_BREAK case 43: YY_RULE_SETUP #line 540 "toke.l" { #ifdef HAVE_SELINUX LEXTRACE("TYPE "); LEXRETURN(TYPE); #else goto got_alias; #endif } YY_BREAK case 44: YY_RULE_SETUP #line 548 "toke.l" { #ifdef HAVE_PRIV_SET LEXTRACE("PRIVS "); LEXRETURN(PRIVS); #else goto got_alias; #endif } YY_BREAK case 45: YY_RULE_SETUP #line 557 "toke.l" { #ifdef HAVE_PRIV_SET LEXTRACE("LIMITPRIVS "); LEXRETURN(LIMITPRIVS); #else goto got_alias; #endif } YY_BREAK case 46: YY_RULE_SETUP #line 566 "toke.l" { got_alias: if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("ALIAS "); LEXRETURN(ALIAS); } YY_BREAK case 47: YY_RULE_SETUP #line 574 "toke.l" { /* XXX - no way to specify digest for command */ /* no command args allowed for Defaults!/path */ if (!fill_cmnd(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("COMMAND "); LEXRETURN(COMMAND); } YY_BREAK case 48: YY_RULE_SETUP #line 583 "toke.l" { digest_len = SHA224_DIGEST_LENGTH; BEGIN WANTDIGEST; LEXTRACE("SHA224 "); LEXRETURN(SHA224); } YY_BREAK case 49: YY_RULE_SETUP #line 590 "toke.l" { digest_len = SHA256_DIGEST_LENGTH; BEGIN WANTDIGEST; LEXTRACE("SHA256 "); LEXRETURN(SHA256); } YY_BREAK case 50: YY_RULE_SETUP #line 597 "toke.l" { digest_len = SHA384_DIGEST_LENGTH; BEGIN WANTDIGEST; LEXTRACE("SHA384 "); LEXRETURN(SHA384); } YY_BREAK case 51: YY_RULE_SETUP #line 604 "toke.l" { digest_len = SHA512_DIGEST_LENGTH; BEGIN WANTDIGEST; LEXTRACE("SHA512 "); LEXRETURN(SHA512); } YY_BREAK case 52: YY_RULE_SETUP #line 611 "toke.l" { BEGIN GOTCMND; LEXTRACE("COMMAND "); if (!fill_cmnd(sudoerstext, sudoersleng)) yyterminate(); } /* sudo -e */ YY_BREAK case 53: YY_RULE_SETUP #line 618 "toke.l" { /* directories can't have args... */ if (sudoerstext[sudoersleng - 1] == '/') { LEXTRACE("COMMAND "); if (!fill_cmnd(sudoerstext, sudoersleng)) yyterminate(); LEXRETURN(COMMAND); } else { BEGIN GOTCMND; LEXTRACE("COMMAND "); if (!fill_cmnd(sudoerstext, sudoersleng)) yyterminate(); } } /* a pathname */ YY_BREAK case 54: YY_RULE_SETUP #line 633 "toke.l" { LEXTRACE("BEGINSTR "); sudoerslval.string = NULL; prev_state = YY_START; BEGIN INSTR; } YY_BREAK case 55: YY_RULE_SETUP #line 640 "toke.l" { /* a word */ if (!fill(sudoerstext, sudoersleng)) yyterminate(); LEXTRACE("WORD(5) "); LEXRETURN(WORD); } YY_BREAK case 56: YY_RULE_SETUP #line 648 "toke.l" { LEXTRACE("( "); LEXRETURN('('); } YY_BREAK case 57: YY_RULE_SETUP #line 653 "toke.l" { LEXTRACE(") "); LEXRETURN(')'); } YY_BREAK case 58: YY_RULE_SETUP #line 658 "toke.l" { LEXTRACE(", "); LEXRETURN(','); } /* return ',' */ YY_BREAK case 59: YY_RULE_SETUP #line 663 "toke.l" { LEXTRACE("= "); LEXRETURN('='); } /* return '=' */ YY_BREAK case 60: YY_RULE_SETUP #line 668 "toke.l" { LEXTRACE(": "); LEXRETURN(':'); } /* return ':' */ YY_BREAK case 61: YY_RULE_SETUP #line 673 "toke.l" { if (sudoersleng & 1) { LEXTRACE("!"); LEXRETURN('!'); /* return '!' */ } } YY_BREAK case 62: YY_RULE_SETUP #line 680 "toke.l" { if (YY_START == INSTR) { LEXTRACE("ERROR "); LEXRETURN(ERROR); /* line break in string */ } BEGIN INITIAL; sudolineno++; continued = false; LEXTRACE("\n"); LEXRETURN(COMMENT); } /* return newline */ YY_BREAK case 63: YY_RULE_SETUP #line 692 "toke.l" { /* throw away space/tabs */ sawspace = true; /* but remember for fill_args */ } YY_BREAK case 64: YY_RULE_SETUP #line 696 "toke.l" { sawspace = true; /* remember for fill_args */ sudolineno++; continued = true; } /* throw away EOL after \ */ YY_BREAK case 65: YY_RULE_SETUP #line 702 "toke.l" { BEGIN INITIAL; sudolineno++; continued = false; LEXTRACE("#\n"); LEXRETURN(COMMENT); } /* comment, not uid/gid */ YY_BREAK case 66: YY_RULE_SETUP #line 710 "toke.l" { LEXTRACE("ERROR "); LEXRETURN(ERROR); } /* parse error */ YY_BREAK case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(GOTDEFS): case YY_STATE_EOF(GOTCMND): case YY_STATE_EOF(STARTDEFS): case YY_STATE_EOF(INDEFS): case YY_STATE_EOF(INSTR): case YY_STATE_EOF(WANTDIGEST): #line 715 "toke.l" { if (YY_START != INITIAL) { BEGIN INITIAL; LEXTRACE("ERROR "); LEXRETURN(ERROR); } if (!pop_include()) yyterminate(); } YY_BREAK case 67: YY_RULE_SETUP #line 725 "toke.l" ECHO; YY_BREAK #line 3092 "lex.sudoers.c" case YY_END_OF_BUFFER: { /* Amount of text matched not including the EOB char. */ int yy_amount_of_matched_text = (int) (yy_cp - yytext_ptr) - 1; /* Undo the effects of YY_DO_BEFORE_ACTION. */ *yy_cp = yy_hold_char; YY_RESTORE_YY_MORE_OFFSET if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_NEW ) { /* We're scanning a new file or input source. It's * possible that this happened because the user * just pointed yyin at a new source and called * yylex(). If so, then we have to assure * consistency between yy_current_buffer and our * globals. Here is the right place to do so, because * this is the first action (other than possibly a * back-up) that will match for the new input source. */ yy_n_chars = yy_current_buffer->yy_n_chars; yy_current_buffer->yy_input_file = yyin; yy_current_buffer->yy_buffer_status = YY_BUFFER_NORMAL; } /* Note that here we test for yy_c_buf_p "<=" to the position * of the first EOB in the buffer, since yy_c_buf_p will * already have been incremented past the NUL character * (since all states make transitions on EOB to the * end-of-buffer state). Contrast this with the test * in input(). */ if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] ) { /* This was really a NUL. */ yy_state_type yy_next_state; yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text; yy_current_state = yy_get_previous_state(); /* Okay, we're now positioned to make the NUL * transition. We couldn't have * yy_get_previous_state() go ahead and do it * for us because it doesn't know how to deal * with the possibility of jamming (and we don't * want to build jamming into it because then it * will run more slowly). */ yy_next_state = yy_try_NUL_trans( yy_current_state ); yy_bp = yytext_ptr + YY_MORE_ADJ; if ( yy_next_state ) { /* Consume the NUL. */ yy_cp = ++yy_c_buf_p; yy_current_state = yy_next_state; goto yy_match; } else { yy_cp = yy_c_buf_p; goto yy_find_action; } } else switch ( yy_get_next_buffer() ) { case EOB_ACT_END_OF_FILE: { yy_did_buffer_switch_on_eof = 0; if ( yywrap() ) { /* Note: because we've taken care in * yy_get_next_buffer() to have set up * yytext, we can now set up * yy_c_buf_p so that if some total * hoser (like flex itself) wants to * call the scanner after we return the * YY_NULL, it'll still work - another * YY_NULL will get returned. */ yy_c_buf_p = yytext_ptr + YY_MORE_ADJ; yy_act = YY_STATE_EOF(YY_START); goto do_action; } else { if ( ! yy_did_buffer_switch_on_eof ) YY_NEW_FILE; } break; } case EOB_ACT_CONTINUE_SCAN: yy_c_buf_p = yytext_ptr + yy_amount_of_matched_text; yy_current_state = yy_get_previous_state(); yy_cp = yy_c_buf_p; yy_bp = yytext_ptr + YY_MORE_ADJ; goto yy_match; case EOB_ACT_LAST_MATCH: yy_c_buf_p = &yy_current_buffer->yy_ch_buf[yy_n_chars]; yy_current_state = yy_get_previous_state(); yy_cp = yy_c_buf_p; yy_bp = yytext_ptr + YY_MORE_ADJ; goto yy_find_action; } break; } default: YY_FATAL_ERROR( "fatal flex scanner internal error--no action found" ); } /* end of action switch */ } /* end of scanning one token */ } /* end of yylex */ /* yy_get_next_buffer - try to read in a new buffer * * Returns a code representing an action: * EOB_ACT_LAST_MATCH - * EOB_ACT_CONTINUE_SCAN - continue scanning from current position * EOB_ACT_END_OF_FILE - end of file */ static int yy_get_next_buffer() { register char *dest = yy_current_buffer->yy_ch_buf; register char *source = yytext_ptr; register int number_to_move, i; int ret_val; if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] ) YY_FATAL_ERROR( "fatal flex scanner internal error--end of buffer missed" ); if ( yy_current_buffer->yy_fill_buffer == 0 ) { /* Don't try to fill the buffer, so this is an EOF. */ if ( yy_c_buf_p - yytext_ptr - YY_MORE_ADJ == 1 ) { /* We matched a single character, the EOB, so * treat this as a final EOF. */ return EOB_ACT_END_OF_FILE; } else { /* We matched some text prior to the EOB, first * process it. */ return EOB_ACT_LAST_MATCH; } } /* Try to read more data. */ /* First move last chars to start of buffer. */ number_to_move = (int) (yy_c_buf_p - yytext_ptr) - 1; for ( i = 0; i < number_to_move; ++i ) *(dest++) = *(source++); if ( yy_current_buffer->yy_buffer_status == YY_BUFFER_EOF_PENDING ) /* don't do the read, it's not guaranteed to return an EOF, * just force an EOF */ yy_current_buffer->yy_n_chars = yy_n_chars = 0; else { int num_to_read = yy_current_buffer->yy_buf_size - number_to_move - 1; while ( num_to_read <= 0 ) { /* Not enough room in the buffer - grow it. */ #ifdef YY_USES_REJECT YY_FATAL_ERROR( "input buffer overflow, can't enlarge buffer because scanner uses REJECT" ); #else /* just a shorter name for the current buffer */ YY_BUFFER_STATE b = yy_current_buffer; int yy_c_buf_p_offset = (int) (yy_c_buf_p - b->yy_ch_buf); if ( b->yy_is_our_buffer ) { int new_size = b->yy_buf_size * 2; if ( new_size <= 0 ) b->yy_buf_size += b->yy_buf_size / 8; else b->yy_buf_size *= 2; b->yy_ch_buf = (char *) /* Include room in for 2 EOB chars. */ yy_flex_realloc( (void *) b->yy_ch_buf, b->yy_buf_size + 2 ); } else /* Can't grow it, we don't own it. */ b->yy_ch_buf = 0; if ( ! b->yy_ch_buf ) YY_FATAL_ERROR( "fatal error - scanner input buffer overflow" ); yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset]; num_to_read = yy_current_buffer->yy_buf_size - number_to_move - 1; #endif } if ( num_to_read > YY_READ_BUF_SIZE ) num_to_read = YY_READ_BUF_SIZE; /* Read in more data. */ YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]), yy_n_chars, num_to_read ); yy_current_buffer->yy_n_chars = yy_n_chars; } if ( yy_n_chars == 0 ) { if ( number_to_move == YY_MORE_ADJ ) { ret_val = EOB_ACT_END_OF_FILE; yyrestart( yyin ); } else { ret_val = EOB_ACT_LAST_MATCH; yy_current_buffer->yy_buffer_status = YY_BUFFER_EOF_PENDING; } } else ret_val = EOB_ACT_CONTINUE_SCAN; yy_n_chars += number_to_move; yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR; yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR; yytext_ptr = &yy_current_buffer->yy_ch_buf[0]; return ret_val; } /* yy_get_previous_state - get the state just before the EOB char was reached */ static yy_state_type yy_get_previous_state() { register yy_state_type yy_current_state; register char *yy_cp; yy_current_state = yy_start; yy_current_state += YY_AT_BOL(); for ( yy_cp = yytext_ptr + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp ) { register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); if ( yy_accept[yy_current_state] ) { yy_last_accepting_state = yy_current_state; yy_last_accepting_cpos = yy_cp; } while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 814 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; } return yy_current_state; } /* yy_try_NUL_trans - try to make a transition on the NUL character * * synopsis * next_state = yy_try_NUL_trans( current_state ); */ #ifdef YY_USE_PROTOS static yy_state_type yy_try_NUL_trans( yy_state_type yy_current_state ) #else static yy_state_type yy_try_NUL_trans( yy_current_state ) yy_state_type yy_current_state; #endif { register int yy_is_jam; register char *yy_cp = yy_c_buf_p; register YY_CHAR yy_c = 1; if ( yy_accept[yy_current_state] ) { yy_last_accepting_state = yy_current_state; yy_last_accepting_cpos = yy_cp; } while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; if ( yy_current_state >= 814 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; yy_is_jam = (yy_current_state == 813); return yy_is_jam ? 0 : yy_current_state; } #ifndef YY_NO_UNPUT #ifdef YY_USE_PROTOS static void yyunput( int c, register char *yy_bp ) #else static void yyunput( c, yy_bp ) int c; register char *yy_bp; #endif { register char *yy_cp = yy_c_buf_p; /* undo effects of setting up yytext */ *yy_cp = yy_hold_char; if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 ) { /* need to shift things up to make room */ /* +2 for EOB chars. */ register int number_to_move = yy_n_chars + 2; register char *dest = &yy_current_buffer->yy_ch_buf[ yy_current_buffer->yy_buf_size + 2]; register char *source = &yy_current_buffer->yy_ch_buf[number_to_move]; while ( source > yy_current_buffer->yy_ch_buf ) *--dest = *--source; yy_cp += (int) (dest - source); yy_bp += (int) (dest - source); yy_current_buffer->yy_n_chars = yy_n_chars = yy_current_buffer->yy_buf_size; if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 ) YY_FATAL_ERROR( "flex scanner push-back overflow" ); } *--yy_cp = (char) c; yytext_ptr = yy_bp; yy_hold_char = *yy_cp; yy_c_buf_p = yy_cp; } #endif /* ifndef YY_NO_UNPUT */ #ifndef YY_NO_INPUT #ifdef __cplusplus static int yyinput() #else static int input() #endif { int c; *yy_c_buf_p = yy_hold_char; if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR ) { /* yy_c_buf_p now points to the character we want to return. * If this occurs *before* the EOB characters, then it's a * valid NUL; if not, then we've hit the end of the buffer. */ if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] ) /* This was really a NUL. */ *yy_c_buf_p = '\0'; else { /* need more input */ int offset = yy_c_buf_p - yytext_ptr; ++yy_c_buf_p; switch ( yy_get_next_buffer() ) { case EOB_ACT_LAST_MATCH: /* This happens because yy_g_n_b() * sees that we've accumulated a * token and flags that we need to * try matching the token before * proceeding. But for input(), * there's no matching to consider. * So convert the EOB_ACT_LAST_MATCH * to EOB_ACT_END_OF_FILE. */ /* Reset buffer status. */ yyrestart( yyin ); /* fall through */ case EOB_ACT_END_OF_FILE: { if ( yywrap() ) return EOF; if ( ! yy_did_buffer_switch_on_eof ) YY_NEW_FILE; #ifdef __cplusplus return yyinput(); #else return input(); #endif } case EOB_ACT_CONTINUE_SCAN: yy_c_buf_p = yytext_ptr + offset; break; } } } c = *(unsigned char *) yy_c_buf_p; /* cast for 8-bit char's */ *yy_c_buf_p = '\0'; /* preserve yytext */ yy_hold_char = *++yy_c_buf_p; yy_current_buffer->yy_at_bol = (c == '\n'); return c; } #endif /* ifndef YY_NO_INPUT */ #ifdef YY_USE_PROTOS void yyrestart( FILE *input_file ) #else void yyrestart( input_file ) FILE *input_file; #endif { if ( ! yy_current_buffer ) yy_current_buffer = yy_create_buffer( yyin, YY_BUF_SIZE ); yy_init_buffer( yy_current_buffer, input_file ); yy_load_buffer_state(); } #ifdef YY_USE_PROTOS void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer ) #else void yy_switch_to_buffer( new_buffer ) YY_BUFFER_STATE new_buffer; #endif { if ( yy_current_buffer == new_buffer ) return; if ( yy_current_buffer ) { /* Flush out information for old buffer. */ *yy_c_buf_p = yy_hold_char; yy_current_buffer->yy_buf_pos = yy_c_buf_p; yy_current_buffer->yy_n_chars = yy_n_chars; } yy_current_buffer = new_buffer; yy_load_buffer_state(); /* We don't actually know whether we did this switch during * EOF (yywrap()) processing, but the only time this flag * is looked at is after yywrap() is called, so it's safe * to go ahead and always set it. */ yy_did_buffer_switch_on_eof = 1; } #ifdef YY_USE_PROTOS void yy_load_buffer_state( void ) #else void yy_load_buffer_state() #endif { yy_n_chars = yy_current_buffer->yy_n_chars; yytext_ptr = yy_c_buf_p = yy_current_buffer->yy_buf_pos; yyin = yy_current_buffer->yy_input_file; yy_hold_char = *yy_c_buf_p; } #ifdef YY_USE_PROTOS YY_BUFFER_STATE yy_create_buffer( FILE *file, int size ) #else YY_BUFFER_STATE yy_create_buffer( file, size ) FILE *file; int size; #endif { YY_BUFFER_STATE b; b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) ); if ( ! b ) YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); b->yy_buf_size = size; /* yy_ch_buf has to be 2 characters longer than the size given because * we need to put in 2 end-of-buffer characters. */ b->yy_ch_buf = (char *) yy_flex_alloc( b->yy_buf_size + 2 ); if ( ! b->yy_ch_buf ) YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); b->yy_is_our_buffer = 1; yy_init_buffer( b, file ); return b; } #ifdef YY_USE_PROTOS void yy_delete_buffer( YY_BUFFER_STATE b ) #else void yy_delete_buffer( b ) YY_BUFFER_STATE b; #endif { if ( ! b ) return; if ( b == yy_current_buffer ) yy_current_buffer = (YY_BUFFER_STATE) 0; if ( b->yy_is_our_buffer ) yy_flex_free( (void *) b->yy_ch_buf ); yy_flex_free( (void *) b ); } #ifndef YY_ALWAYS_INTERACTIVE #ifndef YY_NEVER_INTERACTIVE #include #endif #endif #ifdef YY_USE_PROTOS void yy_init_buffer( YY_BUFFER_STATE b, FILE *file ) #else void yy_init_buffer( b, file ) YY_BUFFER_STATE b; FILE *file; #endif { int oerrno = errno; yy_flush_buffer( b ); b->yy_input_file = file; b->yy_fill_buffer = 1; #if defined(YY_ALWAYS_INTERACTIVE) && YY_ALWAYS_INTERACTIVE b->yy_is_interactive = 1; #else #if defined(YY_NEVER_INTERACTIVE) && YY_NEVER_INTERACTIVE b->yy_is_interactive = 0; #else b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0; #endif #endif errno = oerrno; } #ifdef YY_USE_PROTOS void yy_flush_buffer( YY_BUFFER_STATE b ) #else void yy_flush_buffer( b ) YY_BUFFER_STATE b; #endif { if ( ! b ) return; b->yy_n_chars = 0; /* We always need two end-of-buffer characters. The first causes * a transition to the end-of-buffer state. The second causes * a jam in that state. */ b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; b->yy_buf_pos = &b->yy_ch_buf[0]; b->yy_at_bol = 1; b->yy_buffer_status = YY_BUFFER_NEW; if ( b == yy_current_buffer ) yy_load_buffer_state(); } #ifndef YY_NO_SCAN_BUFFER #ifdef YY_USE_PROTOS YY_BUFFER_STATE yy_scan_buffer( char *base, yy_size_t size ) #else YY_BUFFER_STATE yy_scan_buffer( base, size ) char *base; yy_size_t size; #endif { YY_BUFFER_STATE b; if ( size < 2 || base[size-2] != YY_END_OF_BUFFER_CHAR || base[size-1] != YY_END_OF_BUFFER_CHAR ) /* They forgot to leave room for the EOB's. */ return 0; b = (YY_BUFFER_STATE) yy_flex_alloc( sizeof( struct yy_buffer_state ) ); if ( ! b ) YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" ); b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ b->yy_buf_pos = b->yy_ch_buf = base; b->yy_is_our_buffer = 0; b->yy_input_file = 0; b->yy_n_chars = b->yy_buf_size; b->yy_is_interactive = 0; b->yy_at_bol = 1; b->yy_fill_buffer = 0; b->yy_buffer_status = YY_BUFFER_NEW; yy_switch_to_buffer( b ); return b; } #endif #ifndef YY_NO_SCAN_STRING #ifdef YY_USE_PROTOS YY_BUFFER_STATE yy_scan_string( yyconst char *yy_str ) #else YY_BUFFER_STATE yy_scan_string( yy_str ) yyconst char *yy_str; #endif { int len; for ( len = 0; yy_str[len]; ++len ) ; return yy_scan_bytes( yy_str, len ); } #endif #ifndef YY_NO_SCAN_BYTES #ifdef YY_USE_PROTOS YY_BUFFER_STATE yy_scan_bytes( yyconst char *bytes, int len ) #else YY_BUFFER_STATE yy_scan_bytes( bytes, len ) yyconst char *bytes; int len; #endif { YY_BUFFER_STATE b; char *buf; yy_size_t n; int i; /* Get memory for full buffer, including space for trailing EOB's. */ n = len + 2; buf = (char *) yy_flex_alloc( n ); if ( ! buf ) YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" ); for ( i = 0; i < len; ++i ) buf[i] = bytes[i]; buf[len] = buf[len+1] = YY_END_OF_BUFFER_CHAR; b = yy_scan_buffer( buf, n ); if ( ! b ) YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" ); /* It's okay to grow etc. this buffer, and we should throw it * away when we're done. */ b->yy_is_our_buffer = 1; return b; } #endif #ifndef YY_NO_PUSH_STATE #ifdef YY_USE_PROTOS static void yy_push_state( int new_state ) #else static void yy_push_state( new_state ) int new_state; #endif { if ( yy_start_stack_ptr >= yy_start_stack_depth ) { yy_size_t new_size; yy_start_stack_depth += YY_START_STACK_INCR; new_size = yy_start_stack_depth * sizeof( int ); if ( ! yy_start_stack ) yy_start_stack = (int *) yy_flex_alloc( new_size ); else yy_start_stack = (int *) yy_flex_realloc( (void *) yy_start_stack, new_size ); if ( ! yy_start_stack ) YY_FATAL_ERROR( "out of memory expanding start-condition stack" ); } yy_start_stack[yy_start_stack_ptr++] = YY_START; BEGIN(new_state); } #endif #ifndef YY_NO_POP_STATE static void yy_pop_state() { if ( --yy_start_stack_ptr < 0 ) YY_FATAL_ERROR( "start-condition stack underflow" ); BEGIN(yy_start_stack[yy_start_stack_ptr]); } #endif #ifndef YY_NO_TOP_STATE static int yy_top_state() { return yy_start_stack[yy_start_stack_ptr - 1]; } #endif #ifndef YY_EXIT_FAILURE #define YY_EXIT_FAILURE 2 #endif #ifdef YY_USE_PROTOS static void yy_fatal_error( yyconst char msg[] ) #else static void yy_fatal_error( msg ) char msg[]; #endif { (void) fprintf( stderr, "%s\n", msg ); exit( YY_EXIT_FAILURE ); } /* Redefine yyless() so it works in section 3 code. */ #undef yyless #define yyless(n) \ do \ { \ /* Undo effects of setting up yytext. */ \ yytext[yyleng] = yy_hold_char; \ yy_c_buf_p = yytext + n; \ yy_hold_char = *yy_c_buf_p; \ *yy_c_buf_p = '\0'; \ yyleng = n; \ } \ while ( 0 ) /* Internal utility routines. */ #ifndef yytext_ptr #ifdef YY_USE_PROTOS static void yy_flex_strncpy( char *s1, yyconst char *s2, int n ) #else static void yy_flex_strncpy( s1, s2, n ) char *s1; yyconst char *s2; int n; #endif { register int i; for ( i = 0; i < n; ++i ) s1[i] = s2[i]; } #endif #ifdef YY_NEED_STRLEN #ifdef YY_USE_PROTOS static int yy_flex_strlen( yyconst char *s ) #else static int yy_flex_strlen( s ) yyconst char *s; #endif { register int n; for ( n = 0; s[n]; ++n ) ; return n; } #endif #ifdef YY_USE_PROTOS static void *yy_flex_alloc( yy_size_t size ) #else static void *yy_flex_alloc( size ) yy_size_t size; #endif { return (void *) malloc( size ); } #ifdef YY_USE_PROTOS static void *yy_flex_realloc( void *ptr, yy_size_t size ) #else static void *yy_flex_realloc( ptr, size ) void *ptr; yy_size_t size; #endif { /* The cast to (char *) in the following accommodates both * implementations that use char* generic pointers, and those * that use void* generic pointers. It works with the latter * because both ANSI C and C++ allow castless assignment from * any pointer type to void*, and deal with argument conversions * as though doing an assignment. */ return (void *) realloc( (char *) ptr, size ); } #ifdef YY_USE_PROTOS static void yy_flex_free( void *ptr ) #else static void yy_flex_free( ptr ) void *ptr; #endif { free( ptr ); } #if defined(YY_MAIN) && YY_MAIN int main() { yylex(); return 0; } #endif #line 725 "toke.l" struct path_list { char *path; struct path_list *next; }; struct include_stack { YY_BUFFER_STATE bs; char *path; struct path_list *more; /* more files in case of includedir */ int lineno; bool keepopen; }; static int pl_compare(const void *v1, const void *v2) { const struct path_list * const *p1 = v1; const struct path_list * const *p2 = v2; return strcmp((*p1)->path, (*p2)->path); } static char * switch_dir(struct include_stack *stack, char *dirpath) { DIR *dir; int i, count = 0; char *path = NULL; struct dirent *dent; struct stat sb; struct path_list *pl, *first = NULL; struct path_list **sorted = NULL; debug_decl(switch_dir, SUDO_DEBUG_PARSER) if (!(dir = opendir(dirpath))) { if (errno != ENOENT) { warning("%s", dirpath); sudoerserror(NULL); } goto done; } while ((dent = readdir(dir))) { /* Ignore files that end in '~' or have a '.' in them. */ if (dent->d_name[0] == '\0' || dent->d_name[NAMLEN(dent) - 1] == '~' || strchr(dent->d_name, '.') != NULL) { continue; } if (asprintf(&path, "%s/%s", dirpath, dent->d_name) == -1) { closedir(dir); goto bad; } if (stat(path, &sb) != 0 || !S_ISREG(sb.st_mode)) { efree(path); path = NULL; continue; } pl = malloc(sizeof(*pl)); if (pl == NULL) goto bad; pl->path = path; pl->next = first; first = pl; path = NULL; count++; } closedir(dir); if (count == 0) goto done; /* Sort the list as an array. */ sorted = malloc(sizeof(*sorted) * count); if (sorted == NULL) goto bad; pl = first; for (i = 0; i < count; i++) { sorted[i] = pl; pl = pl->next; } qsort(sorted, count, sizeof(*sorted), pl_compare); /* Apply sorting to the list. */ first = sorted[0]; sorted[count - 1]->next = NULL; for (i = 1; i < count; i++) sorted[i - 1]->next = sorted[i]; efree(sorted); /* Pull out the first element for parsing, leave the rest for later. */ if (count) { path = first->path; pl = first->next; efree(first); stack->more = pl; } else { path = NULL; } done: efree(dirpath); debug_return_str(path); bad: while (first != NULL) { pl = first; first = pl->next; efree(pl->path); efree(pl); } efree(sorted); efree(dirpath); efree(path); debug_return_str(NULL); } #define MAX_SUDOERS_DEPTH 128 #define SUDOERS_STACK_INCREMENT 16 static size_t istacksize, idepth; static struct include_stack *istack; static bool keepopen; void init_lexer(void) { struct path_list *pl; debug_decl(init_lexer, SUDO_DEBUG_PARSER) while (idepth) { idepth--; while ((pl = istack[idepth].more) != NULL) { istack[idepth].more = pl->next; efree(pl->path); efree(pl); } efree(istack[idepth].path); if (idepth && !istack[idepth].keepopen) fclose(istack[idepth].bs->yy_input_file); sudoers_delete_buffer(istack[idepth].bs); } efree(istack); istack = NULL; istacksize = idepth = 0; sudolineno = 1; keepopen = false; sawspace = false; continued = false; prev_state = INITIAL; debug_return; } static bool _push_include(char *path, bool isdir) { struct path_list *pl; FILE *fp; debug_decl(_push_include, SUDO_DEBUG_PARSER) /* push current state onto stack */ if (idepth >= istacksize) { if (idepth > MAX_SUDOERS_DEPTH) { sudoerserror(N_("too many levels of includes")); debug_return_bool(false); } istacksize += SUDOERS_STACK_INCREMENT; istack = (struct include_stack *) realloc(istack, sizeof(*istack) * istacksize); if (istack == NULL) { warning(NULL); sudoerserror(NULL); debug_return_bool(false); } } if (isdir) { struct stat sb; switch (sudo_secure_dir(path, sudoers_uid, sudoers_gid, &sb)) { case SUDO_PATH_SECURE: break; case SUDO_PATH_MISSING: debug_return_bool(false); case SUDO_PATH_BAD_TYPE: errno = ENOTDIR; if (sudoers_warnings) { warning("%s", path); } debug_return_bool(false); case SUDO_PATH_WRONG_OWNER: if (sudoers_warnings) { warningx(_("%s is owned by uid %u, should be %u"), path, (unsigned int) sb.st_uid, (unsigned int) sudoers_uid); } debug_return_bool(false); case SUDO_PATH_WORLD_WRITABLE: if (sudoers_warnings) { warningx(_("%s is world writable"), path); } debug_return_bool(false); case SUDO_PATH_GROUP_WRITABLE: if (sudoers_warnings) { warningx(_("%s is owned by gid %u, should be %u"), path, (unsigned int) sb.st_gid, (unsigned int) sudoers_gid); } debug_return_bool(false); default: /* NOTREACHED */ debug_return_bool(false); } if (!(path = switch_dir(&istack[idepth], path))) { /* switch_dir() called sudoerserror() for us */ debug_return_bool(false); } while ((fp = open_sudoers(path, false, &keepopen)) == NULL) { /* Unable to open path in includedir, go to next one, if any. */ efree(path); if ((pl = istack[idepth].more) == NULL) debug_return_bool(false); path = pl->path; istack[idepth].more = pl->next; efree(pl); } } else { if ((fp = open_sudoers(path, true, &keepopen)) == NULL) { /* The error was already printed by open_sudoers() */ sudoerserror(NULL); debug_return_bool(false); } istack[idepth].more = NULL; } /* Push the old (current) file and open the new one. */ istack[idepth].path = sudoers; /* push old path */ istack[idepth].bs = YY_CURRENT_BUFFER; istack[idepth].lineno = sudolineno; istack[idepth].keepopen = keepopen; idepth++; sudolineno = 1; sudoers = path; sudoers_switch_to_buffer(sudoers_create_buffer(fp, YY_BUF_SIZE)); debug_return_bool(true); } static bool pop_include(void) { struct path_list *pl; FILE *fp; debug_decl(pop_include, SUDO_DEBUG_PARSER) if (idepth == 0) debug_return_bool(false); if (!keepopen) fclose(YY_CURRENT_BUFFER->yy_input_file); sudoers_delete_buffer(YY_CURRENT_BUFFER); /* If we are in an include dir, move to the next file. */ while ((pl = istack[idepth - 1].more) != NULL) { fp = open_sudoers(pl->path, false, &keepopen); if (fp != NULL) { istack[idepth - 1].more = pl->next; efree(sudoers); sudoers = pl->path; sudolineno = 1; sudoers_switch_to_buffer(sudoers_create_buffer(fp, YY_BUF_SIZE)); efree(pl); break; } /* Unable to open path in include dir, go to next one. */ istack[idepth - 1].more = pl->next; efree(pl->path); efree(pl); } /* If no path list, just pop the last dir on the stack. */ if (pl == NULL) { idepth--; sudoers_switch_to_buffer(istack[idepth].bs); efree(sudoers); sudoers = istack[idepth].path; sudolineno = istack[idepth].lineno; keepopen = istack[idepth].keepopen; } debug_return_bool(true); } static char * parse_include(char *base) { char *cp, *ep, *path, *pp; int dirlen = 0, len = 0, subst = 0; size_t shost_len = 0; debug_decl(parse_include, SUDO_DEBUG_PARSER) /* Pull out path from #include line. */ cp = base + sizeof("#include"); if (*cp == 'i') cp += 3; /* includedir */ while (isblank((unsigned char) *cp)) cp++; ep = cp; while (*ep != '\0' && !isspace((unsigned char) *ep)) { if (ep[0] == '%' && ep[1] == 'h') { shost_len = strlen(user_shost); len += shost_len - 2; subst = 1; } ep++; } /* Relative paths are located in the same dir as the sudoers file. */ if (*cp != '/') { char *dirend = strrchr(sudoers, '/'); if (dirend != NULL) dirlen = (int)(dirend - sudoers) + 1; } /* Make a copy of the fully-qualified path and return it. */ len += (int)(ep - cp); path = pp = malloc(len + dirlen + 1); if (path == NULL) { warning(NULL); sudoerserror(NULL); debug_return_str(NULL); } if (dirlen) { memcpy(path, sudoers, dirlen); pp += dirlen; } if (subst) { /* substitute for %h */ while (cp < ep) { if (cp[0] == '%' && cp[1] == 'h') { memcpy(pp, user_shost, shost_len); pp += shost_len; cp += 2; continue; } *pp++ = *cp++; } *pp = '\0'; } else { memcpy(pp, cp, len); pp[len] = '\0'; } /* Push any excess characters (e.g. comment, newline) back to the lexer */ if (*ep != '\0') yyless((int)(ep - base)); debug_return_str(path); } #ifdef TRACELEXER int sudoers_trace_print(const char *msg) { return fputs(msg, stderr); } #else int sudoers_trace_print(const char *msg) { static bool initialized; static struct lbuf lbuf; if (!initialized) { initialized = true; lbuf_init(&lbuf, NULL, 0, NULL, 0); } lbuf_append(&lbuf, "%s", msg); /* XXX - assumes a final newline */ if (strchr(msg, '\n') != NULL) { sudo_debug_printf2(NULL, NULL, 0, SUDO_DEBUG_PARSER|SUDO_DEBUG_DEBUG, "%s:%d %s", sudoers, sudolineno, lbuf.buf); lbuf.len = 0; } return 0; } #endif /* TRACELEXER */