iliaa Tue Feb 28 14:47:15 2006 UTC Added files: (Branch: PHP_4_4) /php-src/ext/session/tests bug36459.phpt
Modified files: /php-src/ext/standard url_scanner_ex.re url_scanner_ex.c /php-src NEWS Log: MFH: Fixed bug #36459 (Incorrect adding PHPSESSID to links, which contains \r\n).
http://cvs.php.net/viewcvs.cgi/php-src/ext/standard/url_scanner_ex.re?r1=1.63.2.11.2.1&r2=1.63.2.11.2.2&diff_format=u Index: php-src/ext/standard/url_scanner_ex.re diff -u php-src/ext/standard/url_scanner_ex.re:1.63.2.11.2.1 php-src/ext/standard/url_scanner_ex.re:1.63.2.11.2.2 --- php-src/ext/standard/url_scanner_ex.re:1.63.2.11.2.1 Sun Jan 1 13:46:58 2006 +++ php-src/ext/standard/url_scanner_ex.re Tue Feb 28 14:47:14 2006 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: url_scanner_ex.re,v 1.63.2.11.2.1 2006/01/01 13:46:58 sniper Exp $ */ +/* $Id: url_scanner_ex.re,v 1.63.2.11.2.2 2006/02/28 14:47:14 iliaa Exp $ */ #include "php.h" @@ -302,7 +302,7 @@ start = YYCURSOR; /*!re2c ">" { passthru(STD_ARGS); handle_form(STD_ARGS); goto state_plain_begin; } - [ \v\t\n]+ { passthru(STD_ARGS); goto state_next_arg; } + [ \v\r\t\n]+ { passthru(STD_ARGS); goto state_next_arg; } alpha { --YYCURSOR; STATE = STATE_ARG; goto state_arg; } any { passthru(STD_ARGS); goto state_plain_begin; } */ @@ -327,7 +327,7 @@ /*!re2c ["] (any\[">])* ["] { handle_val(STD_ARGS, 1, '"'); goto state_next_arg_begin; } ['] (any\['>])* ['] { handle_val(STD_ARGS, 1, '\''); goto state_next_arg_begin; } - (any\[ \t\n>])+ { handle_val(STD_ARGS, 0, '\0'); goto state_next_arg_begin; } + (any\[ \r\t\n>])+ { handle_val(STD_ARGS, 0, ' '); goto state_next_arg_begin; } any { passthru(STD_ARGS); goto state_next_arg_begin; } */ http://cvs.php.net/viewcvs.cgi/php-src/ext/standard/url_scanner_ex.c?r1=1.72.2.15.2.4&r2=1.72.2.15.2.5&diff_format=u Index: php-src/ext/standard/url_scanner_ex.c diff -u php-src/ext/standard/url_scanner_ex.c:1.72.2.15.2.4 php-src/ext/standard/url_scanner_ex.c:1.72.2.15.2.5 --- php-src/ext/standard/url_scanner_ex.c:1.72.2.15.2.4 Sun Jan 1 13:46:58 2006 +++ php-src/ext/standard/url_scanner_ex.c Tue Feb 28 14:47:14 2006 @@ -1,5 +1,5 @@ -/* Generated by re2c 0.9.10 on Mon Sep 5 19:24:48 2005 */ -#line 1 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +/* Generated by re2c 0.9.11 on Tue Feb 28 09:46:35 2006 */ +#line 1 "ext/standard/url_scanner_ex.re" /* +----------------------------------------------------------------------+ | PHP Version 4 | @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: url_scanner_ex.c,v 1.72.2.15.2.4 2006/01/01 13:46:58 sniper Exp $ */ +/* $Id: url_scanner_ex.c,v 1.72.2.15.2.5 2006/02/28 14:47:14 iliaa Exp $ */ #include "php.h" @@ -91,7 +91,7 @@ STD_PHP_INI_ENTRY("url_rewriter.tags", "a=href,area=href,frame=src,form=,fieldset=", PHP_INI_ALL, OnUpdateTags, url_adapt_state_ex, php_basic_globals, basic_globals) PHP_INI_END() -#line 97 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 97 "ext/standard/url_scanner_ex.re" #define YYFILL(n) goto done @@ -109,43 +109,8 @@ q = (p = url->c) + url->len; scan: -{ - static unsigned char yybm[] = { - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 0, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 0, 128, 128, 128, 128, 0, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - }; -#line 149 "<stdout>" +#line 114 "ext/standard/url_scanner_ex.c" { YYCTYPE yych; goto yy0; @@ -153,45 +118,44 @@ yy0: if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; - if(yybm[0+yych] & 128) { - goto yy8; + switch(yych){ + case '#': goto yy6; + case ':': goto yy2; + case '?': goto yy4; + default: goto yy8; } - if(yych <= '9') goto yy6; - if(yych >= ';') goto yy4; - goto yy2; yy2: ++YYCURSOR; goto yy3; yy3: -#line 115 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 115 "ext/standard/url_scanner_ex.re" { smart_str_append(dest, url); return; } -#line 168 "<stdout>" +#line 133 "ext/standard/url_scanner_ex.c" yy4: ++YYCURSOR; goto yy5; yy5: -#line 116 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 116 "ext/standard/url_scanner_ex.re" { sep = separator; goto scan; } -#line 174 "<stdout>" +#line 139 "ext/standard/url_scanner_ex.c" yy6: ++YYCURSOR; goto yy7; yy7: -#line 117 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 117 "ext/standard/url_scanner_ex.re" { bash = p - 1; goto done; } -#line 180 "<stdout>" +#line 145 "ext/standard/url_scanner_ex.c" yy8: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy9; -yy9: if(yybm[0+yych] & 128) { - goto yy8; +yy9: switch(yych){ + case '#': case ':': case '?': goto yy10; + default: goto yy8; } - goto yy10; yy10: -#line 118 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 118 "ext/standard/url_scanner_ex.re" { goto scan; } -#line 192 "<stdout>" -} +#line 157 "ext/standard/url_scanner_ex.c" } -#line 119 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 119 "ext/standard/url_scanner_ex.re" done: @@ -359,43 +323,8 @@ state_plain: start = YYCURSOR; -{ - static unsigned char yybm[] = { - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 0, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - }; -#line 399 "<stdout>" +#line 328 "ext/standard/url_scanner_ex.c" { YYCTYPE yych; goto yy11; @@ -403,72 +332,36 @@ yy11: if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; - if(yybm[0+yych] & 128) { - goto yy15; + switch(yych){ + case '<': goto yy13; + default: goto yy15; } - goto yy13; yy13: ++YYCURSOR; goto yy14; yy14: -#line 287 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 287 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); STATE = STATE_TAG; goto state_tag; } -#line 416 "<stdout>" +#line 345 "ext/standard/url_scanner_ex.c" yy15: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy16; -yy16: if(yybm[0+yych] & 128) { - goto yy15; +yy16: switch(yych){ + case '<': goto yy17; + default: goto yy15; } - goto yy17; yy17: -#line 288 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 288 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); goto state_plain; } -#line 428 "<stdout>" -} +#line 357 "ext/standard/url_scanner_ex.c" } -#line 289 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 289 "ext/standard/url_scanner_ex.re" state_tag: start = YYCURSOR; -{ - static unsigned char yybm[] = { - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 0, 0, 0, 0, 0, - 0, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - }; -#line 472 "<stdout>" +#line 365 "ext/standard/url_scanner_ex.c" { YYCTYPE yych; goto yy18; @@ -476,35 +369,133 @@ yy18: if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; - if(yych <= '@') goto yy22; - if(yych <= 'Z') goto yy20; - if(yych <= '`') goto yy22; - if(yych >= '{') goto yy22; - goto yy20; + switch(yych){ + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy20; + default: goto yy22; + } yy20: ++YYCURSOR; yych = *YYCURSOR; goto yy25; yy21: -#line 294 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 294 "ext/standard/url_scanner_ex.re" { handle_tag(STD_ARGS); /* Sets STATE */; passthru(STD_ARGS); if (STATE == STATE_PLAIN) goto state_plain; else goto state_next_arg; } -#line 491 "<stdout>" +#line 433 "ext/standard/url_scanner_ex.c" yy22: ++YYCURSOR; goto yy23; yy23: -#line 295 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 295 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); goto state_plain_begin; } -#line 497 "<stdout>" +#line 439 "ext/standard/url_scanner_ex.c" yy24: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy25; -yy25: if(yybm[0+yych] & 128) { - goto yy24; +yy25: switch(yych){ + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy24; + default: goto yy21; } - goto yy21; } -} -#line 296 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 296 "ext/standard/url_scanner_ex.re" state_next_arg_begin: @@ -512,43 +503,8 @@ state_next_arg: start = YYCURSOR; -{ - static unsigned char yybm[] = { - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 128, 128, 128, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 128, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - }; -#line 552 "<stdout>" +#line 508 "ext/standard/url_scanner_ex.c" { YYCTYPE yych; goto yy26; @@ -556,102 +512,107 @@ yy26: if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; - if(yych <= '='){ - if(yych <= 0x0B){ - if(yych <= 0x08) goto yy34; - goto yy30; - } else { - if(yych == ' ') goto yy30; - goto yy34; - } - } else { - if(yych <= 'Z'){ - if(yych <= '>') goto yy28; - if(yych <= '@') goto yy34; - goto yy32; - } else { - if(yych <= '`') goto yy34; - if(yych <= 'z') goto yy32; - goto yy34; - } + switch(yych){ + case 0x09: + case 0x0A: + case 0x0B: case 0x0D: case ' ': goto yy30; + case '>': goto yy28; + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy32; + default: goto yy34; } yy28: ++YYCURSOR; goto yy29; yy29: -#line 304 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 304 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); handle_form(STD_ARGS); goto state_plain_begin; } -#line 584 "<stdout>" +#line 579 "ext/standard/url_scanner_ex.c" yy30: ++YYCURSOR; yych = *YYCURSOR; goto yy37; yy31: -#line 305 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 305 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); goto state_next_arg; } -#line 591 "<stdout>" +#line 586 "ext/standard/url_scanner_ex.c" yy32: ++YYCURSOR; goto yy33; yy33: -#line 306 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 306 "ext/standard/url_scanner_ex.re" { --YYCURSOR; STATE = STATE_ARG; goto state_arg; } -#line 597 "<stdout>" +#line 592 "ext/standard/url_scanner_ex.c" yy34: ++YYCURSOR; goto yy35; yy35: -#line 307 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 307 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); goto state_plain_begin; } -#line 603 "<stdout>" +#line 598 "ext/standard/url_scanner_ex.c" yy36: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy37; -yy37: if(yybm[0+yych] & 128) { - goto yy36; +yy37: switch(yych){ + case 0x09: + case 0x0A: + case 0x0B: case 0x0D: case ' ': goto yy36; + default: goto yy31; } - goto yy31; -} } -#line 308 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 308 "ext/standard/url_scanner_ex.re" state_arg: start = YYCURSOR; -{ - static unsigned char yybm[] = { - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 128, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 0, 0, 0, 0, 0, - 0, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 128, 128, 128, 128, 128, - 128, 128, 128, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - }; -#line 655 "<stdout>" +#line 616 "ext/standard/url_scanner_ex.c" { YYCTYPE yych; goto yy38; @@ -659,202 +620,224 @@ yy38: if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; - if(yych <= '@') goto yy42; - if(yych <= 'Z') goto yy40; - if(yych <= '`') goto yy42; - if(yych >= '{') goto yy42; - goto yy40; + switch(yych){ + case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy40; + default: goto yy42; + } yy40: ++YYCURSOR; yych = *YYCURSOR; goto yy45; yy41: -#line 313 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 313 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); handle_arg(STD_ARGS); STATE = STATE_BEFORE_VAL; goto state_before_val; } -#line 674 "<stdout>" +#line 684 "ext/standard/url_scanner_ex.c" yy42: ++YYCURSOR; goto yy43; yy43: -#line 314 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 314 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); STATE = STATE_NEXT_ARG; goto state_next_arg; } -#line 680 "<stdout>" +#line 690 "ext/standard/url_scanner_ex.c" yy44: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy45; -yy45: if(yybm[0+yych] & 128) { - goto yy44; +yy45: switch(yych){ + case '-': case 'A': + case 'B': + case 'C': + case 'D': + case 'E': + case 'F': + case 'G': + case 'H': + case 'I': + case 'J': + case 'K': + case 'L': + case 'M': + case 'N': + case 'O': + case 'P': + case 'Q': + case 'R': + case 'S': + case 'T': + case 'U': + case 'V': + case 'W': + case 'X': + case 'Y': + case 'Z': case 'a': + case 'b': + case 'c': + case 'd': + case 'e': + case 'f': + case 'g': + case 'h': + case 'i': + case 'j': + case 'k': + case 'l': + case 'm': + case 'n': + case 'o': + case 'p': + case 'q': + case 'r': + case 's': + case 't': + case 'u': + case 'v': + case 'w': + case 'x': + case 'y': + case 'z': goto yy44; + default: goto yy41; } - goto yy41; } -} -#line 315 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 315 "ext/standard/url_scanner_ex.re" state_before_val: start = YYCURSOR; -{ - static unsigned char yybm[] = { - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 128, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, - }; -#line 732 "<stdout>" +#line 756 "ext/standard/url_scanner_ex.c" { YYCTYPE yych; - unsigned int yyaccept; + unsigned int yyaccept = 0; goto yy46; ++YYCURSOR; yy46: if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; - if(yych == ' ') goto yy48; - if(yych == '=') goto yy50; - goto yy52; + switch(yych){ + case ' ': goto yy48; + case '=': goto yy50; + default: goto yy52; + } yy48: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); - if(yych == ' ') goto yy55; - if(yych == '=') goto yy53; - goto yy49; + switch(yych){ + case ' ': goto yy55; + case '=': goto yy53; + default: goto yy49; + } yy49: -#line 321 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 321 "ext/standard/url_scanner_ex.re" { --YYCURSOR; goto state_next_arg_begin; } -#line 752 "<stdout>" +#line 780 "ext/standard/url_scanner_ex.c" yy50: ++YYCURSOR; yych = *YYCURSOR; goto yy54; yy51: -#line 320 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 320 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); STATE = STATE_VAL; goto state_val; } -#line 759 "<stdout>" +#line 787 "ext/standard/url_scanner_ex.c" yy52: yych = *++YYCURSOR; goto yy49; yy53: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy54; -yy54: if(yybm[0+yych] & 128) { - goto yy53; +yy54: switch(yych){ + case ' ': goto yy53; + default: goto yy51; } - goto yy51; yy55: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy56; -yy56: if(yych == ' ') goto yy55; - if(yych == '=') goto yy53; - goto yy57; +yy56: switch(yych){ + case ' ': goto yy55; + case '=': goto yy53; + default: goto yy57; + } yy57: YYCURSOR = YYMARKER; switch(yyaccept){ case 0: goto yy49; } } -} -#line 322 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 322 "ext/standard/url_scanner_ex.re" state_val: start = YYCURSOR; -{ - static unsigned char yybm[] = { - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 160, 160, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 160, 248, 56, 248, 248, 248, 248, 200, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 0, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - 248, 248, 248, 248, 248, 248, 248, 248, - }; -#line 825 "<stdout>" +#line 819 "ext/standard/url_scanner_ex.c" { YYCTYPE yych; - unsigned int yyaccept; + unsigned int yyaccept = 0; goto yy58; ++YYCURSOR; yy58: if((YYLIMIT - YYCURSOR) < 3) YYFILL(3); yych = *YYCURSOR; - if(yych <= '!'){ - if(yych <= 0x0A){ - if(yych <= 0x08) goto yy63; - goto yy64; - } else { - if(yych == ' ') goto yy64; - goto yy63; - } - } else { - if(yych <= '\''){ - if(yych <= '"') goto yy60; - if(yych <= '&') goto yy63; - goto yy62; - } else { - if(yych == '>') goto yy64; - goto yy63; - } + switch(yych){ + case 0x09: + case 0x0A: case 0x0D: case ' ': case '>': goto yy64; + case '"': goto yy60; + case '\'': goto yy62; + default: goto yy63; } yy60: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); goto yy77; yy61: -#line 330 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" -{ handle_val(STD_ARGS, 0, '\0'); goto state_next_arg_begin; } -#line 858 "<stdout>" +#line 330 "ext/standard/url_scanner_ex.re" +{ handle_val(STD_ARGS, 0, ' '); goto state_next_arg_begin; } +#line 841 "ext/standard/url_scanner_ex.c" yy62: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); goto yy69; @@ -863,47 +846,49 @@ yy64: ++YYCURSOR; goto yy65; yy65: -#line 331 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 331 "ext/standard/url_scanner_ex.re" { passthru(STD_ARGS); goto state_next_arg_begin; } -#line 869 "<stdout>" +#line 852 "ext/standard/url_scanner_ex.c" yy66: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy67; -yy67: if(yybm[0+yych] & 8) { - goto yy66; +yy67: switch(yych){ + case 0x09: + case 0x0A: case 0x0D: case ' ': case '>': goto yy61; + default: goto yy66; } - goto yy61; yy68: yyaccept = 0; YYMARKER = ++YYCURSOR; if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; goto yy69; -yy69: if(yybm[0+yych] & 16) { - goto yy68; +yy69: switch(yych){ + case 0x09: + case 0x0A: case 0x0D: case ' ': goto yy72; + case '\'': goto yy70; + case '>': goto yy61; + default: goto yy68; } - if(yych <= '&') goto yy72; - if(yych >= '(') goto yy61; - goto yy70; yy70: ++YYCURSOR; - if(yybm[0+(yych = *YYCURSOR)] & 8) { - yych = *YYCURSOR; - goto yy66; + switch((yych = *YYCURSOR)) { + case 0x09: + case 0x0A: case 0x0D: case ' ': case '>': goto yy71; + default: goto yy66; } - goto yy71; yy71: -#line 329 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 329 "ext/standard/url_scanner_ex.re" { handle_val(STD_ARGS, 1, '\''); goto state_next_arg_begin; } -#line 898 "<stdout>" +#line 883 "ext/standard/url_scanner_ex.c" yy72: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy73; -yy73: if(yybm[0+yych] & 32) { - goto yy72; +yy73: switch(yych){ + case '\'': goto yy75; + case '>': goto yy74; + default: goto yy72; } - if(yych <= '=') goto yy75; - goto yy74; yy74: YYCURSOR = YYMARKER; switch(yyaccept){ case 0: goto yy61; @@ -915,37 +900,37 @@ if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); yych = *YYCURSOR; goto yy77; -yy77: if(yybm[0+yych] & 64) { - goto yy76; +yy77: switch(yych){ + case 0x09: + case 0x0A: case 0x0D: case ' ': goto yy80; + case '"': goto yy78; + case '>': goto yy61; + default: goto yy76; } - if(yych <= '!') goto yy80; - if(yych >= '#') goto yy61; - goto yy78; yy78: ++YYCURSOR; - if(yybm[0+(yych = *YYCURSOR)] & 8) { - yych = *YYCURSOR; - goto yy66; + switch((yych = *YYCURSOR)) { + case 0x09: + case 0x0A: case 0x0D: case ' ': case '>': goto yy79; + default: goto yy66; } - goto yy79; yy79: -#line 328 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 328 "ext/standard/url_scanner_ex.re" { handle_val(STD_ARGS, 1, '"'); goto state_next_arg_begin; } -#line 934 "<stdout>" +#line 920 "ext/standard/url_scanner_ex.c" yy80: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; goto yy81; -yy81: if(yybm[0+yych] & 128) { - goto yy80; +yy81: switch(yych){ + case '"': goto yy82; + case '>': goto yy74; + default: goto yy80; } - if(yych >= '>') goto yy74; - goto yy82; yy82: ++YYCURSOR; yych = *YYCURSOR; goto yy79; } -} -#line 332 "/usr/src/php/php_4_4/ext/standard/url_scanner_ex.re" +#line 332 "ext/standard/url_scanner_ex.re" stop: http://cvs.php.net/viewcvs.cgi/php-src/NEWS?r1=1.1247.2.920.2.117&r2=1.1247.2.920.2.118&diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.1247.2.920.2.117 php-src/NEWS:1.1247.2.920.2.118 --- php-src/NEWS:1.1247.2.920.2.117 Tue Feb 21 15:35:01 2006 +++ php-src/NEWS Tue Feb 28 14:47:15 2006 @@ -2,6 +2,8 @@ ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? 2006, Version 4.4.3 - Added a check for special characters in the session name. (Ilia) +- Fixed bug #36459 (Incorrect adding PHPSESSID to links, which contains \r\n). + (Ilia) - Fixed bug #36458 (sleep() accepts negative values). (Ilia) - Fixed bug #36242 (Possible memory corruption in stream_select()). (Tony) - Fixed bug #36223 (curl bypasses open_basedir restrictions). (Tony) http://cvs.php.net/viewcvs.cgi/php-src/ext/session/tests/bug36459.phpt?view=markup&rev=1.1 Index: php-src/ext/session/tests/bug36459.phpt +++ php-src/ext/session/tests/bug36459.phpt
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php