Password Protecting your pages
How do I password protect my pages?Copy the lines below and put them in a file named .htaccess, You can make this file in any text editor. Be sure to modify the line named AuthUserFile below. Notice the last part of the AuthUserFile, service.pwd. This is the file that you need to put the username password pairs into, you can create this file in any text editor. The username and password pairs need to be encrypted through your console.
---------------------------COPY BELOW----------------------------- # This is the configuration file for you to password protect a directory. # # NOTE: Make sure you put the correct path to the directory you are # trying to protect after the AuthUserFile line below. Also make # sure you put this .htaccess file in the directory that you are trying to # to protect and the service.pwd also in the directory that you # are trying to protect. ###########################################################################The
AuthType Basic AuthName PasswordAdmin AuthUserFile /web/disk1/virtual/yourdomain.xxx/htdocs/cgi-bin/service.pwd require valid-user ---------------------------COPY ABOVE-----------------------------AuthUserFileline is very important. There are a few things that must be correct on this line.
- The
AuthUserFile <path>directive must be on one line.- The
<path>must be the full path on the server. You can determine the correct path to use by logging into your console. At the bottom of the main screen, you will see in small print
Document Root:The line following is the full path to your htdocs directory. Just add
/cgi-bin/service.pwdto the end of this path and you will have the correct path for theAuthUserFileline.- It is best to put the service.pwd file in the cgi-bin directory since the file cannot be viewed via a web browser when it is in this directory.
How do I encrypt the passwords?
You will need to use the http encryption utility in your account console and put them in a file named service.pwd, you can create this file in any text editor. The username password pairs should look something like this:
iqstech:00hzYw5m.HyAY
Notice that there is a space at the end of the encrypted password if you click and drag you mouse over it like you were going to copy it, this is very important and is usually left out when it gets copied and pasted into the service.pwd file.
Why doesn't this work for me, I think I did it right?
Make sure that when you encrypt the password you get the whole line copied to paste into the htpasswd file. Most of the time the last character doesn't get copied, which happens to be a space.
If you have problems with this system, please send email to help@webstorage.com and be sure to include the following information:
- Your FTP username
- The directory that you wish to protect
- Any additional information about what you have tried that might help us solve the problem.
© 1997-1999 Internet Quality Services Corporation. All rights reserved.