1

We want to ensure all sites hosted on apache web server all protected using htpasswd (Apache Basic Authentication)

There are a few sites which are redirected from http to https, and the above authentication goes into a redirect loop on HTTPS (on further,related reading it seems that HTTP basic authentication compares the password (encrypted) format in plain text)

We have tried several samples/snippets to make basic authentication prompt work on HTTPS, but every code snippet results into multiple redirect loop and back to Auth prompt even when I key the correct password.

The links that I have already referred are : Apache .htaccess redirect to HTTPS before asking for user authentication https://webmasters.stackexchange.com/questions/8853/properly-force-ssl-with-htaccess-no-double-authentication Do HTTP authentication over HTTPS with URL rewriting

We have tried all the combinations SSLRequireSSL, writing it in other VirtualHost, but nothing seems to work as site redirects from HTTP to HTTPS during the Authentication, Furthermore, there are no error logs of any kind, so it implies the .htaccess and apache config is fine.

SSL,rewrite,auth etc modules are already enabled on the server

0 Answers0