Mercurial > hg > nginx-vendor-0-7
comparison src/core/ngx_string.c @ 502:89dc5654117c NGINX_0_7_63
nginx 0.7.63
*) Security: now "/../" are disabled in "Destination" request header
line.
*) Change: minimum supported OpenSSL version is 0.9.7.
*) Change: the "ask" parameter of the "ssl_verify_client" directive was
changed to the "optional" parameter and now it checks a client
certificate if it was offered.
Thanks to Brice Figureau.
*) Feature: now the "-V" switch shows TLS SNI support.
*) Feature: the $ssl_client_verify variable.
Thanks to Brice Figureau.
*) Feature: the "ssl_crl" directive.
Thanks to Brice Figureau.
*) Bugfix: the $ssl_client_cert variable usage corrupted memory; the
bug had appeared in 0.7.7.
Thanks to Sergey Zhuravlev.
*) Feature: now the start cache loader runs in a separate process; this
should improve large caches handling.
*) Feature: now temporary files and permanent storage area may reside
at different file systems.
*) Bugfix: nginx counted incorrectly disk cache size.
*) Change: now directive "gzip_disable msie6" does not disable gzipping
for MSIE 6.0 SV1.
*) Bugfix: nginx always added "Vary: Accept-Encoding" response header
line, if both "gzip_static" and "gzip_vary" were on.
*) Feature: the "proxy" parameter of the "geo" directive.
*) Feature: the ngx_http_geoip_module.
*) Feature: the "limit_rate_after" directive.
Thanks to Ivan Debnar.
*) Feature: the "limit_req_log_level" and "limit_conn_log_level"
directives.
*) Bugfix: now "limit_req" directive conforms to the leaky bucket
algorithm.
Thanks to Maxim Dounin.
*) Bugfix: in ngx_http_limit_req_module.
Thanks to Maxim Dounin.
*) Bugfix: now nginx allows underscores in a request method.
*) Bugfix: "proxy_pass_header" and "fastcgi_pass_header" directives did
not pass to a client the "X-Accel-Redirect", "X-Accel-Limit-Rate",
"X-Accel-Buffering", and "X-Accel-Charset" lines from backend
response header.
Thanks to Maxim Dounin.
*) Bugfix: in handling "Last-Modified" and "Accept-Ranges" backend
response header lines; the bug had appeared in 0.7.44.
Thanks to Maxim Dounin.
*) Feature: the "image_filter_transparency" directive.
*) Feature: the "image_filter" directive supports variables for setting
size.
*) Bugfix: in PNG alpha-channel support in the
ngx_http_image_filter_module.
*) Bugfix: in transparency support in the ngx_http_image_filter_module.
*) Feature: now several "perl_modules" directives may be used.
*) Bugfix: ngx_http_perl_module responses did not work in subrequests.
*) Bugfix: nginx sent '\0' in a "Location" response header line on
MKCOL request.
Thanks to Xie Zhenye.
*) Bugfix: an "error_page" directive did not redirect a 413 error; the
bug had appeared in 0.6.10.
*) Bugfix: in memory allocation error handling.
Thanks to Maxim Dounin and Kirill A. Korinskiy.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Mon, 26 Oct 2009 00:00:00 +0300 |
parents | ed3d382670c7 |
children | 706fef7f4dcc |
comparison
equal
deleted
inserted
replaced
501:dc87c92181c7 | 502:89dc5654117c |
---|---|
28 { | 28 { |
29 if (n == 0) { | 29 if (n == 0) { |
30 return dst; | 30 return dst; |
31 } | 31 } |
32 | 32 |
33 for ( /* void */ ; --n; dst++, src++) { | 33 while (--n) { |
34 *dst = *src; | 34 *dst = *src; |
35 | 35 |
36 if (*dst == '\0') { | 36 if (*dst == '\0') { |
37 return dst; | 37 return dst; |
38 } | 38 } |
39 | |
40 dst++; | |
41 src++; | |
39 } | 42 } |
40 | 43 |
41 *dst = '\0'; | 44 *dst = '\0'; |
42 | 45 |
43 return dst; | 46 return dst; |
563 | 566 |
564 for ( ;; ) { | 567 for ( ;; ) { |
565 c1 = (ngx_uint_t) *s1++; | 568 c1 = (ngx_uint_t) *s1++; |
566 c2 = (ngx_uint_t) *s2++; | 569 c2 = (ngx_uint_t) *s2++; |
567 | 570 |
568 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; | 571 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; |
569 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; | 572 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; |
570 | 573 |
571 if (c1 == c2) { | 574 if (c1 == c2) { |
572 | 575 |
573 if (c1) { | 576 if (c1) { |
574 continue; | 577 continue; |
589 | 592 |
590 while (n) { | 593 while (n) { |
591 c1 = (ngx_uint_t) *s1++; | 594 c1 = (ngx_uint_t) *s1++; |
592 c2 = (ngx_uint_t) *s2++; | 595 c2 = (ngx_uint_t) *s2++; |
593 | 596 |
594 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; | 597 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; |
595 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; | 598 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; |
596 | 599 |
597 if (c1 == c2) { | 600 if (c1 == c2) { |
598 | 601 |
599 if (c1) { | 602 if (c1) { |
600 n--; | 603 n--; |
678 ngx_strcasestrn(u_char *s1, char *s2, size_t n) | 681 ngx_strcasestrn(u_char *s1, char *s2, size_t n) |
679 { | 682 { |
680 ngx_uint_t c1, c2; | 683 ngx_uint_t c1, c2; |
681 | 684 |
682 c2 = (ngx_uint_t) *s2++; | 685 c2 = (ngx_uint_t) *s2++; |
683 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; | 686 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; |
684 | 687 |
685 do { | 688 do { |
686 do { | 689 do { |
687 c1 = (ngx_uint_t) *s1++; | 690 c1 = (ngx_uint_t) *s1++; |
688 | 691 |
689 if (c1 == 0) { | 692 if (c1 == 0) { |
690 return NULL; | 693 return NULL; |
691 } | 694 } |
692 | 695 |
693 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; | 696 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; |
694 | 697 |
695 } while (c1 != c2); | 698 } while (c1 != c2); |
696 | 699 |
697 } while (ngx_strncasecmp(s1, (u_char *) s2, n) != 0); | 700 } while (ngx_strncasecmp(s1, (u_char *) s2, n) != 0); |
698 | 701 |
710 ngx_strlcasestrn(u_char *s1, u_char *last, u_char *s2, size_t n) | 713 ngx_strlcasestrn(u_char *s1, u_char *last, u_char *s2, size_t n) |
711 { | 714 { |
712 ngx_uint_t c1, c2; | 715 ngx_uint_t c1, c2; |
713 | 716 |
714 c2 = (ngx_uint_t) *s2++; | 717 c2 = (ngx_uint_t) *s2++; |
715 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; | 718 c2 = (c2 >= 'A' && c2 <= 'Z') ? (c2 | 0x20) : c2; |
716 last -= n; | 719 last -= n; |
717 | 720 |
718 do { | 721 do { |
719 do { | 722 do { |
720 if (s1 >= last) { | 723 if (s1 >= last) { |
721 return NULL; | 724 return NULL; |
722 } | 725 } |
723 | 726 |
724 c1 = (ngx_uint_t) *s1++; | 727 c1 = (ngx_uint_t) *s1++; |
725 | 728 |
726 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; | 729 c1 = (c1 >= 'A' && c1 <= 'Z') ? (c1 | 0x20) : c1; |
727 | 730 |
728 } while (c1 != c2); | 731 } while (c1 != c2); |
729 | 732 |
730 } while (ngx_strncasecmp(s1, s2, n) != 0); | 733 } while (ngx_strncasecmp(s1, s2, n) != 0); |
731 | 734 |
1335 | 1338 |
1336 if (dst == NULL) { | 1339 if (dst == NULL) { |
1337 | 1340 |
1338 /* find the number of the characters to be escaped */ | 1341 /* find the number of the characters to be escaped */ |
1339 | 1342 |
1340 n = 0; | 1343 n = 0; |
1341 | 1344 |
1342 for (i = 0; i < size; i++) { | 1345 for (i = 0; i < size; i++) { |
1343 if (escape[*src >> 5] & (1 << (*src & 0x1f))) { | 1346 if (escape[*src >> 5] & (1 << (*src & 0x1f))) { |
1344 n++; | 1347 n++; |
1345 } | 1348 } |