You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Th...@equant.com on 2002/01/16 17:16:43 UTC

Perl based Authentication on Apache

Dear addressed,

pls, provide.

i want to use the Perl-based Authentication Module
     Apache::authDBI
written by Edmund Mergl.
This is tested with
     Apache 1.3.6
     Mod_perl 1.21

However i want to use it with
     Apache 2.0.30
     Mod_perl 2.0

This is configured on the System with:

httpd.conf:
========
LoadModule perl_module modules/libmodperl.so

Perlhandler  Apache::AuthDBI

ScriptAlias /ro-euma/ "/home/admin/ro-euma/"

<Directory "/home/admin/ro-euma">
    AllowOverride All
    SetHandler Apache::AuthDBI::authen
    Options ExecCGI Includes
    Order allow,deny
    Allow from all
</Directory>
====================

And in the corresponding .htaccess-File:
==============
AuthName "RO-EUMA CSF"
AuthType Basic

PerlHandler Apache::AuthDBI::authen
PerlSetVar Auth_DBI_data_source dbi:Pg:dbname=roeuma

PerlSetVar Auth_DBI_username      admin
PerlSetVar Auth_DBI_password      sita_fra
# DBI->connect($data_source, $username, $password)

PerlSetVar Auth_DBI_pwd_table     login
PerlSetVar Auth_DBI_uid_field     username
PerlSetVar Auth_DBI_pwd_field     passwd
#SELECT pwd_field FROM pwd_table WHERE uid_field=$user

require user twaelde
=====================

Trying this i got the error-message inside the error log from Apache:
     configuration error: couldn't check user. No user file?:
/ro-euma/index.pl

i guess Apache does not access this AuthenticationHandler and requires
something like a htpaaswd.

Pls, what must i do to correct this ?

Thks for every help in advance n Bgrds
Thomas