Documentation for Crowd 1.0. Documentation for other versions of Crowd is available too.
IN DEVELOPMENT
The attached Perl module is in beta, use the module with caution.
If you find any problems with the module please comment on the following ticket:
This documentation describes how to configure Crowd to authenticate HTTP Authentication requests made to an Apache webserver.
mod_perl
module installed and configured.SOAP::Lite
perl module (v0.69 or greater recommended).The following instructions are for Unix systems. If you're running Apache on Windows, see the notes below.
SOAP::Lite
Perl ModuleSOAP::Lite
is a Perl library for managing SOAP calls. It is used by the CrowdAuth
module to talk to the Crowd server.
The easiest way to install SOAP::Lite
is via CPAN, by running the following command.
perl -MCPAN -e 'install SOAP::Lite'
Alternatively, you can download and install the package manually.
Apache::CrowdAuth
Perl ModuleDownload the Apache-CrowdAuth-0.03.tar.gz file and extract and install it as follows:
tar xvzf Apache-CrowdAuth-0.03.tar.gz cd Apache-CrowdAuth-0.03 perl Makefile.PL make make install
mod_perl
is enabled.Your Apache config file should contain a line like the following:
LoadModule perl_module modules/mod_perl.so
Many common distributions of Apache come with mod_perl
preconfigured.
To tell Apache to use Crowd to authenticate requests for a particular location, edit the Apache config file to add the following commands to a <Location>
or <Directory>
section.
Alias /crowd/ "/var/crowd/" <Directory "/var/crowd/"> . . . AuthName crowd AuthType Basic PerlAuthenHandler Apache::CrowdAuth PerlSetVar CrowdAppName appname PerlSetVar CrowdAppPassword apppassword PerlSetVar CrowdSOAPURL http://localhost:8080/crowd/services/SecurityServer require valid-user . . . </Directory>
コマンド |
説明 |
---|---|
|
Defines the realm of the authentication. This information is typically provided to the user in the dialog box popped up by their browser |
|
Tells apache to use basic authentication |
|
Tells Apache to delegate authentication to the CrowdAuth module |
|
Set the Application Apache should authenticate as |
|
Set the password for the Application |
|
The URL of the Crowd SOAP service |
|
Tells Apache that clients must provide a valid username/password to access the location |
If you are using Apache to manage access to a subversion repository (instructions), you can use the same configuration method to delegate user authentication to Crowd.
例:
<Location /svn> # Uncomment this to enable the repository, DAV svn # Set this to the path to your repository SVNPath /var/lib/svn AuthName crowd AuthType Basic PerlAuthenHandler Apache::CrowdAuth PerlSetVar CrowdAppName subversion PerlSetVar CrowdAppPassword svn PerlSetVar CrowdSOAPURL http://localhost:8080/crowd/services/SecurityServer require valid-user # The following three lines allow anonymous read, but make # committers authenticate themselves. <LimitExcept GET PROPFIND OPTIONS REPORT> Require valid-user </LimitExcept> </Location>
Note that Apache will have to be restarted before any changes to its config files will take effect.
CrowdAuth
module logs detailed output if the Apache LogLevel parameter is set to info
or debug
. This can be useful in diagnosing problems (WARNING: passwords are logged in plaintext to the Apache log file when LogLevel
is set to debug
). |
One or both of the |
|
The attempt to authenticate the application with crowd failed. Check the values of the |
|
Failed to authenticate a username/password pair provided by the client. This may just mean that the username or password supplied is incorrect. Note that |
|
Internal SOAP protocol error |
|
Indicates that Apache can't connect to the Crowd SOAP service |
|
Indicates that the URL used to connect to the Crowd SOAP service is incorrect. Check the value of the |
|
The |
|
The |
mod_perl
and Perl Modules on Windows
Setting up CrowdAuth
on an Apache instance running on Windows requires that some things be done differently.
(The following instructions assume you are using ActivePerl as your Perl environment).
mod_perl
pre-installed. A Win32 version of mod_perl
in PPM format is available here..tar.gz
format used to distribute CrowdAuth (and other modules) is supported by most modern Windows archiving utilities (WinZip, for example).make
utility used to build the Perl modules is not part of a Windows. nmake
, Microsoft's equivalent, is available (as a self-extracting archive) here.SOAP::Lite
on WindowsUse the cpan
shell
C:\ cpan cpan> install SOAP::Lite
Apache::CrowdAuth
on WindowsExtract Apache-CrowdAuth-0.03.tar.gz using Winzip or equivalent... cd Apache-CrowdAuth-0.03 perl Makefile.PL nmake nmake install
When editing the httpd.conf file and adding the mod_perl.so module to Apache, you may need to add the following line above the LoadModule line
LoadFile "C:/Perl/bin/perl58.dll" LoadModule perl_module modules/mod_perl.so
This LoadFile line points to the perl58.dll in your Perl install directory.
2 Comments
user-c4e61
Feb 02, 2007Apache2::CrowdAuth
is not included in the crowd 0.4.3 distribution.Justen Stepka [Atlassian]
Feb 05, 2007Until the code is folded into the release archive, I have attached the module to this page as an attachment.