View Single Post
Old 12-10-2020, 02:17 PM   #1788
Minstrelcda
Member
Minstrelcda doesn't litterMinstrelcda doesn't litter
 
Posts: 12
Karma: 108
Join Date: Dec 2020
Device: kobo
Quote:
Originally Posted by mariosipad View Post
@Minstrelcda


2 - Authentication
To use basic authentication in apache with .htaccess you need to change a setting in the apache2.conf (or httpd.conf) file (not COPS).
Search for:
Code:
<Directory /var/www/http>
    Options Indexes FollowSymLinks
    AllowOverride None
    Require all granted
</Directory>
and change None to All.

You can, for testing purposes only (!!!), put your .htpasswd file in the COPS directory and reference it with ./.htpasswd in .htaccess.

Thanks for your reply.

I made the change above in my httpd.conf file and restarted the service, but I can still log in directly without the prompt.

If I change the path in .htaccess to ./.htpasswd, when I log in I get a 500 Internal Server error. Changing the path to anything else where the .htpasswd file is located doesn't present the error, but also doesn't prompt me for the login.
Minstrelcda is offline   Reply With Quote