Tuesday, February 12, 2013

OSX Server https with password page

Hi there,

I did got OSX Server for my mac mini, so I wanted to create a folder password protected with a user that exists on my mac, plus forward to https because the password.

After some search, just found ninja tricks to enable auth modifying the files, plus some htaccess examples that caused double auth, or some loops.

After some test, I have came with a simple solution.

On the folder you want to protect, just create a .htaccess file with :

Is totally local, doesn't require modify the httpd.conf file, nor restart the service.

The trick is on the Error 403, that will happen if the connection came from http.

Just replace with your server/path and voila.

[ update Feb 16 ] in order to get .htaccess to work, please be sure you get the same enabled on the console

No comments:

Post a Comment