Kbase 21763: How To Set up User Authentication on Apache for Webspeed
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  2/8/2002 |
|
SUMMARY:
This Solution provides example files and can be used as a basic guide for how to set up User Authentication with the Apache Web server 1.3.12 on Sun Solaris 8.
EXPLANATION:
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.
SOLUTION:
This example assumes that both the Apache Web server and Progress WebSpeed are configured correctly and that browser requests to the Web server are responding.
First, go to the following weblinks and create a password file.
While you're there, you might also read up on User Authentication
so that you will have a better understanding of what needs to be done and the reasons why.
http://www.apacheweek.com/features/userauth
http://hoohoo.ncsa.uiuc.edu/docs/tutorials/user.html#Basic
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. The websites references above will detail how to create this file:
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.
References to Written Documentation:
http://www.apacheweek.com/features/userauth
http://hoohoo.ncsa.uiuc.edu/docs/tutorials/user.html#Basic