How to set passwd for your web pages


Dear IE Students,

If you want to set passwd for your HTML documents, please follow these steps:

  1. mkdir a directory under your ~/public_html
  2. In this directory create a file ".htaccess" file with the following lines
       AuthUserFile < path>/passwd_file 
    AuthName "Restricted stuff"
    AuthType Basic
    Require valid-user
  3. create the "passwd_file" with the following command
    htpasswd -c passwd_file user_name
  4. put the HTML documents that you want to protect under this directory
  5. now whenever people access these HTML documents under this directory need to supply the user_name and its passwd


As this web server is shared by all students, any highly confidential document is not suitable to be housed in this web server.