summaryrefslogtreecommitdiffhomepage
path: root/src/core/ngx_string.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2015-03-17Core: overflow detection in number parsing functions.Ruslan Ermilov1-42/+57
2015-01-27A bounds check of %N format on Windows.Igor Sysoev1-1/+5
Thanks to Joe Bialek, Adam Zabrocki and Microsoft Vulnerability Research.
2014-12-12Autoindex: implemented JSON output format.Valentin Bartenev1-0/+52
2014-06-26Core: use uppercase hexadecimal digits for percent-encoding.Piotr Sikora1-1/+1
RFC3986 says that, for consistency, URI producers and normalizers should use uppercase hexadecimal digits for all percent-encodings. This is also what modern web browsers and other tools use. Using lowercase hexadecimal digits makes it harder to interact with those tools in case when use of the percent-encoded URI is required, for example when $request_uri is part of the cache key. Signed-off-by: Piotr Sikora <piotr@cloudflare.com>
2014-02-04Core: added ngx_encode_base64url().Maxim Dounin1-12/+37
2013-09-23Added ngx_filename_cmp() with "/" sorted to the left.Maxim Dounin1-0/+40
This patch fixes incorrect handling of auto redirect in configurations like: location /0 { } location /a- { } location /a/ { proxy_pass ... } With previously used sorting, this resulted in the following locations tree (as "-" is less than "/"): "/a-" "/0" "/a/" and a request to "/a" didn't match "/a/" with auto_redirect, as it didn't traverse relevant tree node during lookup (it tested "/a-", then "/0", and then falled back to null location). To preserve locale use for non-ASCII characters on case-insensetive systems, libc's tolower() used.
2013-09-04Win32: Open Watcom C compatibility fixes.Maxim Dounin1-1/+1
Precompiled headers are disabled as they lead to internal compiler errors with long configure lines. Couple of false positive warnings silenced. Various win32 typedefs are adjusted to work with Open Watcom C 1.9 headers. With this patch, it's now again possible to compile nginx using owc386, with options we normally compile on win32 minus ipv6 and ssl.
2012-08-03Added "const" to ngx_memcpy() with NGX_MEMCPY_LIMIT defined.Maxim Dounin1-1/+1
This fixes warning produced during compilation of the ngx_http_geoip_module due to const qualifier being discarded.
2012-04-23Fix of "%f" format handling.Igor Sysoev1-16/+19
ngx_sprintf("%.2f", 0.999) incorrectly resulted in "0.100" instead of "1.00".
2012-01-18Copyright updated.Maxim Konovalov1-0/+1
2011-11-25Added escaping of double quotes in ngx_escape_html().Maxim Dounin1-0/+9
Patch by Zaur Abasmirzoev.
2011-10-13Fixed utf8 decode (ticket #25).Maxim Dounin1-3/+3
Patch by Alexey Kuts.
2011-10-11Autoindex: escape '?' in file names.Maxim Dounin1-1/+21
For files with '?' in their names autoindex generated links with '?' not escaped. This resulted in effectively truncated links as '?' indicates query string start. This is an updated version of the patch originally posted at [1]. It introduces generic NGX_ESCAPE_URI_COMPONENT which escapes everything but unreserved characters as per RFC 3986. This approach also renders unneeded special colon processing (as colon is percent-encoded now), it's dropped accordingly. [1] http://nginx.org/pipermail/nginx-devel/2010-February/000112.html Reported by Konstantin Leonov.
2011-09-19Replaced "can not" with "cannot" and "could not" in a bunch of places.Ruslan Ermilov1-1/+1
Fixed nearby grammar errors.
2010-09-02new ngx_http_secure_link_module with secure_link, secure_link_md5, andIgor Sysoev1-8/+45
secure_link_expires
2010-07-30escape ";" in argumentsIgor Sysoev1-1/+1
2010-06-23change ngx_http_variable_value_node_t to more generic ngx_str_node_tIgor Sysoev1-0/+83
2010-05-14use ngx_min() and ngx_max()Igor Sysoev1-8/+3
2010-05-14ngx_atofp()Igor Sysoev1-0/+50
2010-05-12fix rounding issues in %f formatIgor Sysoev1-1/+1
2010-05-12use double in %f format to allow %.15f precisionIgor Sysoev1-3/+3
2010-04-01escape ampersand in argument while rewriteIgor Sysoev1-2/+2
2010-01-11fix ngx_utf8_cpystrn(): it did not fully copy utf-8 stringIgor Sysoev1-3/+1
2009-11-02optimize some cycles:Igor Sysoev1-9/+14
*) delete surplus variable; *) on i386/amd64 "while (n) / n--" is smaller than "while (n--)", because the platforms have no postfix operations
2009-09-12If .domain.com, .sub.domain.com, and .domain-some.com were defined,Igor Sysoev1-0/+31
then .sub.domain.com was matched by .domain.com: wildcard names hash was built incorrectly due to sorting order issue of "." vs "-". They were sorted as com.domain com.domain-some com.domain.sub while they should be sorted as com.domain com.domain.sub com.domain-some for correct hash building
2009-09-11style fixIgor Sysoev1-9/+9
2009-08-26fix typoIgor Sysoev1-1/+1
2009-06-05change surplus for() to while()Igor Sysoev1-1/+4
2009-04-27ngx_vslprintf(), ngx_slprintf()Igor Sysoev1-10/+18
2009-04-06backout r2677 and fix ngx_strlcasestrn() againIgor Sysoev1-5/+1
2009-04-06fix ngx_strlcasestrn()Igor Sysoev1-0/+4
2009-04-04ngx_strlcasestrn()Igor Sysoev1-0/+33
2008-11-10%f formatIgor Sysoev1-63/+137
2008-08-04ngx_strlow()Igor Sysoev1-0/+11
2008-07-29rename ngx_utf_...() to ngx_utf8_...()Igor Sysoev1-8/+8
2008-07-25fix utf-8 names in autoindexIgor Sysoev1-26/+30
2008-06-17*) back out r2040Igor Sysoev1-1/+1
*) refactor ngx_palloc() *) introduce ngx_pnalloc() *) additional pool blocks have smaller header
2008-03-24use ngx_int_t in ngx_sort() callbackIgor Sysoev1-1/+1
2008-03-23use dynamically allocated buffer in ngx_sort()Igor Sysoev1-5/+11
2008-01-24limit string lengthIgor Sysoev1-1/+3
2008-01-24use correct type castIgor Sysoev1-1/+1
2008-01-22allow zero length in %*sIgor Sysoev1-2/+2
2007-12-24%*s formatIgor Sysoev1-3/+16
2007-12-17replace ngx_md5_text() with ngx_hex_dump()Igor Sysoev1-7/+6
2007-11-09do not encode already encoded characters in msie_refreshIgor Sysoev1-1/+1
2007-10-22unescape SSI includeIgor Sysoev1-3/+15
2007-10-09style fix: remove trailing spacesIgor Sysoev1-3/+3
2007-10-01ngx_strnstr()Igor Sysoev1-0/+34
2007-10-01add commentIgor Sysoev1-0/+6
2007-09-27ngx_escape_html()Igor Sysoev1-0/+61