Java StuffJava introJava Scripts ICS Free Java Java Mongers |
|
Blankstester |
1. Use our
access program to add your username/password to our database. 2. Create a .htaccess file in the directory you would like to password protect. 3. The .htaccess file should contain the following: AuthUserFile /data/.htpasswd AuthGroupFile /dev/null AuthName username AuthType Basic require user username Change username to the name you added to our database with the access.pl program. |
STANFORD SCHOOL OF ENGINEERING Password Protection for your Class Website |
Setting up password protection for your site requires using telnet and some basic UNIX commands.
Step One: create .htaccess file Create the following document using a simple text editor. Substitute the appropriate information for your site inside the parentheses.
AuthUserFile /(server path to your class folder)/.htpasswd Save this file as .htaccess and upload it into the directory that you want to protect (i.e., your class folder). Step Two: create your .htpasswd file Using the htpasswd program on your server, create an encrypted version of the name and passsword you plan to give the class to access the website. While in your telnet session, dial into your server and go to your directory. At the prompt, type:
You will be asked for the password and then a .htpasswd file will be created for you. Make sure this file is located in your directory. If it is not, load it into the class folder. Test to make sure your password works.
For more detailed instructions check out the tutorial on the Leland server. http://www.stanford.edu/userauth-tutorial.html
|
Password protecting folders: