This is what was done to solve the problem. I am providing the two relevant
location blocks.
# protect the "secure" folder ( /var/www/html/secure )
location /secure/ {
auth_basic "Restricted";
auth_basic_user_file /var/www/protected/.htpasswd;
}
# T
On Mon, Mar 18, 2013 at 08:10:47PM -0400, mottwsc wrote:
Hi there,
> I have found that this now
> works as it should to protect the /secure folder when trying to view html
> files, but it does not when viewing php files in the /secure folder (it just
> bypasses authentication and displays the fil
I was able to get partway through the problem with some help. The basic
problem was that I had been missing a root directive in one of the location
blocks. I was advised to (and did) move the root statement up to the server
block and comment it out from any sub-blocks. I have found that this now
On Sun, Mar 10, 2013 at 04:07:23PM -0400, mottwsc wrote:
Hi there,
> I'm trying to secure a directory on a CentOS 6.3 64 server running NGINX
> 1.2.7. I think I've set this up correctly, but it keeps giving me a 404 Not
> Found error when I try to access a file in that folder in the browser usin
I'm trying to secure a directory on a CentOS 6.3 64 server running NGINX
1.2.7. I think I've set this up correctly, but it keeps giving me a 404 Not
Found error when I try to access a file in that folder in the browser using
domainName/secure/hello2.html.
I created an .htpasswd file using printf