deadlock Message Board
[ March Full List | Reply ]

Re: Quick 'n' dirty .htpasswd tutorial
From Nancy on 21 March '99
replying to Quick 'n' dirty .htpasswd tutorial posted by Jim

>Telnet into your account, then enter this command:
>
>htpasswd -c .htpasswd nancy

Ok, I tried this and I got a message saying 'command not found'
Also this is what I put in my .htaccess file. Does it look right?
This I made on notepad then ftp to my members directory. I changed
the name to .htaccess.

AuthUserFile /nfs/falcon/export1/home/users/mldr/members/.htpasswd
AuthGroupFile /dev/null
AuthName Members Only Section
AuthType Basic

<Limit GET POST>
require valid-user
</Limit>

This account is in a separate directory along with my pubhtml directory. I can't seem to get a password or username entered through telnet. Am I doing this correctly? Geez...I remember when I learned ftp...same thing. No instructions come in the box:-)



>
>You'll be prompted to enter a password, then repeat it. Once you've
>done that, your password will be set up.
Didn't get one of these.

>
>In order to "make the password work" you need to put a file called
>.htaccess into your private directory. You can just use your normal
>FTP program, or whatever you usually use to upload your Web pages.
>
>The contents of your .htaccess file need to look something like this:
>
>AuthUserFile /home/nancy/.htpasswd
>AuthGroupFile /dev/null
>AuthName Nancy_Private
>AuthType Basic
><Limit GET POST>
>require user nancy
></Limit>

Is this supposed to be in the file I made with note pad? The one that I put in my 'members' section or do I put it though the telnet program?

>
>Notes about the above:
>
>AuthUserFile must be the path to the
>.htpasswd file - it'll be in your home directory, the one where
>you arrive when you log into your account.

Which account? Telnet or ftp?

>
>AuthName can be anything, it'll be displayed on the password entry
>box.
>
>require user nancy - only user nancy will be able to enter your
>private directory. You can add as many user/password combinations
>to your .htpasswd file as you like, so you can give different users
>access to different directories. If you want "any" registered
>user to be able to enter your private directory, put:
>
>require valid-user
>
>IMPORTANT: to add new users to your .htpasswd file, do this:
>
>htpasswd .htpasswd nancy2
>
>(note: do not use -c otherwise you'll create a new .htpasswd file
>and your old user will be deleted).
Only use the -c thing one time or once per user????
>
>Hope this helps...
Yes, it helps. I'm getting there.




Reply to this message

Required Details
Your name:
Subject:

Optional Details
Home page title:
Home page URL:
Email:
(if you'd like to receive
automatic replies by email)

Your Message