Hi,
I need to deny access to /members but allow access to every folders below.
There may be a lot of folders, maybe a thousan, and each of those folders
contain 5 other folders. So i need a wildcard.
Here is what i tried :
location ~ ^/members/([^/]+)/([^/?]+)$ { allow all; }#allo
Here is what i found to achieve this :
i denied access to every php files :
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
allow 127.0.0.1;
Hi,
It works, but i am still able to access the php files inside the restricted
directories. I tried with :
location /myfolder/(.+)\.php$ {
deny all;
}
But this doesn't work!
Also, i cannot make this method work nice with our clean url's. We are
using :
location / {
#try_fil
HI,
I want to configure our nginx to be a little more paranoid concerning file
access.
Right now, i am using rules like :
location /includes {
allow 127.0.0.1;
deny all;
}
... but i need to repeat this kind of rules for every folders, and then
restrict access to the php files inside. So our rul