Enabling password authentication on Windows using Apache (link if you wish to RTFM) isn’t too much of a chore if you have basic knowledge of some simple coding and apache configuration.

A couple things to jot down:

  1. Path to your Apache server (e.g., c:\apache)
  2. Path to your CONF folder (e.g., c:\apache\conf)
  3. Path to your DOCROOT folder (e.g., c:\apache\htdocs)
  4. Path to the folder you wish to password-protect. In myexample, lets take a
    folder called “secure”, so the path to this

    would be
    “c:\apache\htdocs\secure”. (It could be ABOVE the htdocs

    folder as
    well, FYI).

Ok, what to do:

  1. Open up your httpd.conf. (On my machine this is at
    “c:\apache\conf\httpd.conf”).
  2. Look for the word AllowOverride, and change it from None to All.
  3. Our httpd.conf is done. Now we need to create the password
    file. Open up a DOS prompt and go to the apache’s BIN directory. In
    my case, it is “c:\apache\bin”.
  4. Now, we need to create the .HTACCESS file itself.
  5. Restart Apache – This is what happens when accessing your secret area!