ENG
329 (73566), 394 (09403): Fall 2002 Password
protecting a web folder
Step 2: Creating a
".nsconfig" file
An .nsconfig file is a simple
text file which contains information about exactly which folder
you are password protecting (you probably have more than one
subfolder on your site).
i.
Start with opening up the Notepad or Wordpad. A new, blank document
will open up.
ii. Copy and Paste
the below text-exactly as is- into the notepad document:
# All files in my Web directory
www/secure
<Files secure/*>
# Require a valid userid and password
RequireAuth userfile=/afs/asu.edu/users/c/a/j/cajsa/www/.passwd
realm="Enter your message here that you want your visitors
to see when prompted for password"
</Files>
#This will prevent anyone from being able to see your .passwd
file
<Files .passwd>
RestrictAccess method="(GET|HEAD|POST)" type="deny"
ip="*"
</Files>
#This will prevent anyone from being able to see your .nsconfig
file
<Files .nsconfig>
RestrictAccess method="(GET|HEAD|POST)" type="deny"
ip="*"
</Files>
(Stop here. Do not copy this
line)
The sections in bold
print will need to be personalized according to the personal
configuration for your AFS account.
iii. Save the file
OUTSIDE the directory you want to secure, and make sure to give
it the EXACT name ".nsconfig" (without the quotation
marks).
iv. You have now created your
.nsconfig file! You can now proceed to Step
3: Creating the Password file (".passwd" file)
Step
1 | Step 3 | Step
4 |Back to Webdesign resources
About the instructors |Supplementary Readings & On-line
Resources |Course WebBoard | Back
to top | home
|