<feed xmlns='http://www.w3.org/2005/Atom'>
<title>nginx.git/src/http/modules/ngx_http_referer_module.c, branch release-1.19.3</title>
<subtitle>nginx</subtitle>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/'/>
<entry>
<title>Referer: fixed $invalid_referer.</title>
<updated>2017-08-04T05:01:55+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@nginx.com</email>
</author>
<published>2017-08-04T05:01:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=c09bba400d233331f1b405e18c6912a30502dee9'/>
<id>c09bba400d233331f1b405e18c6912a30502dee9</id>
<content type='text'>
The variable was considered non-existent in the absence of any
valid_referers directives.

Given the following config snippet,

    location / {
        return 200 $invalid_referer;
    }

    location /referer {
        valid_referers server_names;
    }

"location /" should work identically and independently on other
"location /referer".

The fix is to always add the $invalid_referer variable as long
as the module is compiled in, as is done by other modules.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The variable was considered non-existent in the absence of any
valid_referers directives.

Given the following config snippet,

    location / {
        return 200 $invalid_referer;
    }

    location /referer {
        valid_referers server_names;
    }

"location /" should work identically and independently on other
"location /referer".

The fix is to always add the $invalid_referer variable as long
as the module is compiled in, as is done by other modules.
</pre>
</div>
</content>
</entry>
<entry>
<title>Style.</title>
<updated>2016-03-30T08:52:16+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@nginx.com</email>
</author>
<published>2016-03-30T08:52:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=7ad57da59821294255610545b2b5ce07e74124a5'/>
<id>7ad57da59821294255610545b2b5ce07e74124a5</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Referer: fixed hostname buffer overflow check.</title>
<updated>2013-08-29T18:35:54+00:00</updated>
<author>
<name>Valentin Bartenev</name>
<email>vbart@nginx.com</email>
</author>
<published>2013-08-29T18:35:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=6d7ec5009a585fbbfa01a1b02fe7116957bcf5f0'/>
<id>6d7ec5009a585fbbfa01a1b02fe7116957bcf5f0</id>
<content type='text'>
Because of premature check the effective buffer size was 255 symbols
while the buffer is able to handle 256.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Because of premature check the effective buffer size was 255 symbols
while the buffer is able to handle 256.
</pre>
</div>
</content>
</entry>
<entry>
<title>Referer: "server_names" parsing deferred to merge phase.</title>
<updated>2013-08-29T18:35:27+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2013-08-29T18:35:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=e4209c02695eeff839d8e7aa807b62fe502bb4e8'/>
<id>e4209c02695eeff839d8e7aa807b62fe502bb4e8</id>
<content type='text'>
This allows to approach "server_name" values specified below the
"valid_referers" directive when used within the "server_names" parameter, e.g.:

    server_name  example.org;
    valid_referers server_names;
    server_name  example.com;

As a bonus, this fixes bogus error with "server_names" specified several times.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This allows to approach "server_name" values specified below the
"valid_referers" directive when used within the "server_names" parameter, e.g.:

    server_name  example.org;
    valid_referers server_names;
    server_name  example.com;

As a bonus, this fixes bogus error with "server_names" specified several times.
</pre>
</div>
</content>
</entry>
<entry>
<title>Referer: fixed server_name regex matching.</title>
<updated>2013-08-29T18:35:26+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2013-08-29T18:35:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=8658c5b8a11c2155e66e1bd1c322099f672f7c15'/>
<id>8658c5b8a11c2155e66e1bd1c322099f672f7c15</id>
<content type='text'>
The server_name regexes are normally compiled for case-sensitive matching.
This violates case-insensitive obligations in the referer module.  To fix
this, the host string is converted to lower case before matching.

Previously server_name regex was executed against the whole referer string
after dropping the scheme part.  This could led to an improper matching, e.g.:

    server_name ~^localhost$;
    valid_referers server_names;

    Referer: http://localhost/index.html

It was changed to look only at the hostname part.

The server_name regexes are separated into another array to not clash with
regular regexes.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The server_name regexes are normally compiled for case-sensitive matching.
This violates case-insensitive obligations in the referer module.  To fix
this, the host string is converted to lower case before matching.

Previously server_name regex was executed against the whole referer string
after dropping the scheme part.  This could led to an improper matching, e.g.:

    server_name ~^localhost$;
    valid_referers server_names;

    Referer: http://localhost/index.html

It was changed to look only at the hostname part.

The server_name regexes are separated into another array to not clash with
regular regexes.
</pre>
</div>
</content>
</entry>
<entry>
<title>Referer: fixed error type usage inconsistency for ngx_http_add*().</title>
<updated>2013-08-29T18:35:26+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2013-08-29T18:35:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=3ef0dfa145513c98b331f75730c3f16e4713cda4'/>
<id>3ef0dfa145513c98b331f75730c3f16e4713cda4</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Referer module: fixed regex matching against HTTPS referers.</title>
<updated>2013-08-13T13:47:04+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2013-08-13T13:47:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=9aaf256e4024e278e099c94281246aada63fc2fa'/>
<id>9aaf256e4024e278e099c94281246aada63fc2fa</id>
<content type='text'>
When matching a compiled regex against value in the "Referer" header field,
the length was calculated incorrectly for strings that start from "https://".
This might cause matching to fail for regexes with end-of-line anchors.

Patch by Liangbin Li.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When matching a compiled regex against value in the "Referer" header field,
the length was calculated incorrectly for strings that start from "https://".
This might cause matching to fail for regexes with end-of-line anchors.

Patch by Liangbin Li.
</pre>
</div>
</content>
</entry>
<entry>
<title>Referer module: added $invalid_referer to variables hash.</title>
<updated>2013-05-22T18:31:53+00:00</updated>
<author>
<name>Maxim Dounin</name>
<email>mdounin@mdounin.ru</email>
</author>
<published>2013-05-22T18:31:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=4fd486e68ccc90f38c4bfc1ed9abef99565471cb'/>
<id>4fd486e68ccc90f38c4bfc1ed9abef99565471cb</id>
<content type='text'>
This makes it accessible via dynamic lookup with ngx_http_get_variable()
from Perl, SSI, etc.

Patch by Yichun Zhang (agentzh).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This makes it accessible via dynamic lookup with ngx_http_get_variable()
from Perl, SSI, etc.

Patch by Yichun Zhang (agentzh).
</pre>
</div>
</content>
</entry>
<entry>
<title>Copyright updated.</title>
<updated>2012-01-18T15:07:43+00:00</updated>
<author>
<name>Maxim Konovalov</name>
<email>maxim@nginx.com</email>
</author>
<published>2012-01-18T15:07:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=f8d59e33f34185c28d1d3c6625a897e214b7ca73'/>
<id>f8d59e33f34185c28d1d3c6625a897e214b7ca73</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix names of the referer hash size directives introduced in r3940.</title>
<updated>2011-08-18T16:27:30+00:00</updated>
<author>
<name>Igor Sysoev</name>
<email>igor@sysoev.ru</email>
</author>
<published>2011-08-18T16:27:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=c4ff39ae2b79a6a54535f3c8abc9f2ccefa4ee99'/>
<id>c4ff39ae2b79a6a54535f3c8abc9f2ccefa4ee99</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
