mkhtaccess mkhtaccess is a barebones utility for creating .htaccess restrictions (either by username/password pairs or by restricting to the virginia.edu domain). mkhtaccess is very simple to use, but offers little flexibility. If you require more options and flexibility, please consult our more complete .htaccess documentation. The process for using mkhtaccess is as follows: 1. Using either SecureCRT or Nifty Telnet (both available from Software Central), log on to the server where your files reside (such as blue.unix.virginia.edu or minerva.acc.virginia.edu). 2. Change to the directory that you want to protect. For example, if you wanted to protect the directory "forfriends" in your personal Web site, you do the following (the commands you should type are in red):
3. Run the mkhtaccess utility by entering the following command:
You should then see the following menu:
4. Enter your choice and then follow the directions on the screen. If you choose to password protect, you will then be prompted to supply the desired username and password combination. If you choose to restrict to virginia.edu, there are no further steps to complete. 5. Finally, you should test your .htaccess restriction. Using your preferred Web browser, go to a page that is in the restricted directory. If you chose to password protect that directory, you should be prompted for the username and password. If you restricted your directory to virginia.edu, then you will need to use an outside Internet Service Provider to verify the protection. Technical Notes: mkhtaccess places a .htaccess file in the current directory. If option 1 (password protect) is selected, the htaccess file will resemble the following:
The .htpasswd file will be placed in the home directory of the person who initiated the mkhtaccess utility. If option 2 (restrict to virginia.edu) is selected, the htaccess file will resemble the following:
Web
Development Support | General
Info | Getting Started
| Design & Promotion
If you need further assistance with Web applications or questions, send e-mail to web-consult@virginia.edu or call the ITC Help Desk at 924-3731. |
||||||||||||||||||||||||||||||||||