Difference between revisions of "User:Djgreen/htpasswd"
m |
m |
||
Line 1: | Line 1: | ||
+ | ALTERNATIVE WEBPAGE PROTECTIONS | ||
+ | |||
ok. This is what I've done. In each of the directories, I've placed the following files: .htpass / .htaccess / and htpasswd (you can find these in L:\wolftech\web). | ok. This is what I've done. In each of the directories, I've placed the following files: .htpass / .htaccess / and htpasswd (you can find these in L:\wolftech\web). | ||
Revision as of 09:52, 30 June 2006
ALTERNATIVE WEBPAGE PROTECTIONS
ok. This is what I've done. In each of the directories, I've placed the following files: .htpass / .htaccess / and htpasswd (you can find these in L:\wolftech\web).
The first will contain all of the usernames and paswds you create. The second tells the webbrowser, STOP and chk if the person is in .htpass The third allows you to add and remove people from .htpass.
Procedure to edit .htaccess:
1. Using Putty, ssh to ssh.ncsu.edu (Add/Remove programs, add new prgm, communications, Putty) 2. Change to the AEMP directory
cd /afs/eos/engrwww/aemp
3. Edit the htpass file.
htpasswd.dat -c ./.htpass djgreen
If .htpass already exists, drop the "-c". That creates or adds a user to the paswd file.
4. To remove a user, simply edit the .htpass file using either "vi" or "pico" and delete the line that user is on.
Just for reference the contents of the .htaccess file are:
AuthType Basic AuthUserFile /afs/eos/engrservers/www/aemp/NSEC/.htpass AuthName "Password Required" require valid-user
One thing to note. When you tell it where to find the paswd file, you MUST use the full afs path and use /engrservers/www/ in place of /engrwww/ . Relative paths will not see it.