Welcome! Log In Create A New Profile

Advanced

HTTP Referer Module Support Variables? And pcre question...

All files from this thread

File Name File Size   Posted by Date  
localhost-if_eth0-day.png 23.1 KB open | download Jim Ohlstein 07/30/2009 Read message
Resicow
August 03, 2009 02:45PM
Hello All,

Is it safe to use variables with the http_referer module?

I'd like to specify the valid_referers via set variables, instead of
hard-coding them into the configuration.

So something like:
valid_referers
<http://wiki.nginx.org/NginxHttpRefererModule#valid_referers> none
blocked $domain1 $domain2;

Also, is it possible to somehow get the top level folder using rewrite
and pcre?

So for example, if the URI is this:
/folder1/folder2/lots_of_other_folders/file.txt

How would it be possible to set a variable equal to "folder1"? Everytime
I try, it never quite works.

Thanks,

John
Subject Author Posted

HTTP Referer Module Attachments

Jim Ohlstein July 30, 2009 09:47AM

Re: HTTP Referer Module

Igor Sysoev July 30, 2009 09:54AM

Re: HTTP Referer Module

Jim Ohlstein July 30, 2009 01:34PM

Re: HTTP Referer Module

Igor Sysoev July 30, 2009 01:42PM

HTTP Referer Module Support Variables? And pcre question...

Resicow August 03, 2009 02:45PM

Re: HTTP Referer Module Support Variables? And pcre question...

Maxim Dounin August 06, 2009 06:25PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 177
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready