Levi E. Stanley wrote:
Hi, I have written a authentication module, which seems to work fine but after you put in the correct username and password, it seems to have forgotten to load up any of the files in the DocumentIndex.

For example when I type this in the browser http://www.twistedme.com/protected/ I get a Not Found error (The requested URL /protected/ was not found on this server.

But if I do this http://www.twistedme.com/protected/index.php it seems it wants to download the file, if I convert it into index.html, it renders it correctly. Am I missing something?

I has nothing to do with your authentication module. I'd bet you'd see the same results whether you had your auth turned off or not. It's the fact that you haven't told apache what to use as your index. See below...


This is what my config file looks like for apache if it helps.

<VirtualHost *:80>
   ServerAdmin [EMAIL PROTECTED]
   DocumentRoot /mnt/sites/twistedme.com
   ServerAlias vibing.com www.twistedme.com
   ServerName twistedme.com
   PerlModule Apache2
   PerlModule My::Authenticate
   <Directory /mnt/sites/twistedme.com/protected>

You need a
DirectoryIndex index.php
somethere inside of this Directory directive. The reason it won't execute the script is also an apache/php configuration problem. Do you have php installed? Either way you need to consult the php docs cause it has nothing to do with mod_perl.


       SetHandler perl-script
       PerlAuthenHandler My::Authenticate
             AuthType Basic
       AuthName "My Protected Area"
       Require valid-user
   </Directory>
   CustomLog /mnt/sites/logs/twistedme.com-access.log combined
   ErrorLog  /mnt/raid/sites/logs/twistedme.com-error.log
</VirtualHost>


HTH

--
Michael Peters
Developer
Plus Three, LP


-- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html



Reply via email to