Welcome! Log In Create A New Profile

Advanced

nginx .htpasswd

Posted by Treehugger 
nginx .htpasswd
July 30, 2017 06:17PM
Hi,

I've a question. I have created a protected dir with a htpasswd file on server (centos 7, apache/nginx, plesk)

I want to protect the dir /cms and all what comes after that. Only when I login on /cms with user/pwd and go to /cms/dir or /cms/file.php, then often I get a second time I have to authenticate (not always). Is this a know issue? Is there something wrong with the config? Current config:

location ~ ^/cms/* {
auth_basic "something protected";
auth_basic_user_file /path/to/.htpasswd;
}

Hope anyone has an idea.

Kind regards,
Alex
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 299
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