[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cobalt-developers] .htaccess Raq4



Telnet into server as admin, then su to root.

Step 1 (Create User authentication file)

The following command would create this file with the user "dudley" as the
first user entry in the file:

htpasswd -c /home/sites/site4/web/secure/users dudley

The -c in the command tells htpasswd to create the new file named "users"
inside the directory "secure". When you run the command you will be prompted
to enter a password and re-enter a the password for dudley. The same command
is used without the -c to add additional users to the same file.

Step 2 (Create .htaccess file)

To create this file, cd to the directory you want to password protect.  Then
type this command:

pico

Pico is a text editor that will run inside a telnet session.  Copy the text
below and paste it into your pico session.  Remember to change the directory
path of AuthUserFile to what you want it to be.

# Access file
order allow,deny
allow from all
require valid-user
Authname secure
AuthPAM_Enabled off
Authtype Basic
AuthUserFile /home/sites/site4/web/secure/users

After you paste this text into Pico, follow the menu option at the bottom of
your Pico session to save and exit.

Example:
type Control-X  to exit Pico
Do you want to save? Type Y for yes
File name: Type .htaccess
Enter

You should now have a shell prompt.
Exit telnet and your done.

----
Brian J. Coughter
Internet Services

Blue Water Graphics, Inc.
7977 SW Jack James Drive
Stuart, Florida 34997

561-286-2249  (Tel)
561-286-3055  (Fax)

brianc@xxxxxxxxxxxxxx