Consultor Eletrônico



Kbase P11790: How to set up User Authentication on Apache for Webspeed?
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   10/16/2008
Status: Verified

GOAL:

How to set up User Authentication on Apache for Webspeed?

FACT(s) (Environment):

WebSpeed 3.x

FIX:

If you want to enable User Authentication so that users must enter a username and password when using WebSpeed, you must make sure that certain areas are configured correctly. This will also allow you to query the REMOTE_USER CGI variable.

Before you start, you will need to have a password file created. The following links will help you do this;

http://www.apacheweek.com/features/userauth
http://hoohoo.ncsa.uiuc.edu/docs/tutorials/user.html#Basic

Please note that this example assumes that both the Apache Web Server and WebSpeed are configured correctly and that browser requests to the Web Server is responding.

Below is an example of the apache/conf/access.conf file. This file's contents are sometimes incorporated into the apache/conf/httpd.conf file. These 'Directory' entries are used to tell Apache that it will allow User Authentication to be overridden by .htaccess files found in the directory listed.
In this example, there are two directories that are allowed to be overridden by the .htaccess files:

<Directory "/usr/local/apache/htdocs">
AllowOverride AuthConfig
</Directory>

- and -

<Directory "/usr/local/apache/cgi-bin">
AllowOverride AuthConfig
</Directory>

Below is an example of an .htaccess file which can be placed into the above directories to enable User Authentication when accessed. The AuthUserFile points to a file called 'users' that contains your list of users and passwords.

AuthName "Restricted Stuff"
AuthType Basic
AuthUserFile /usr/local/etc/httpd/users

require valid-user

NOTE: If you don't configure User Authentication against the apache/cgi-bin directory, you will find that WebSpeed will not trigger the Authentication.

FIX:

References to Written Documentation:

http://www.apacheweek.com/features/userauth
http://hoohoo.ncsa.uiuc.edu/docs/tutorials/user.html#Basic