.htaccess login challenge broken with mod_rewrite

Discussion in 'Installation/Configuration' started by ozonblue, Sep 13, 2006.

  1. ozonblue

    ozonblue New Member

    Hi all.

    I'm running ISPconfig on Debian Sarge with perfect setup.

    I'm using the WebGUI content management system on some virtual hosts which rewrites some URL's - *excluding* the /stats/ directory which is protected by ISPconfig's .htaccess file.

    When I remove that .htaccess file everything works fine - which tells me that mod_rewrite is working correctly. When the .htaccess file is present - I get an unauthorised access message - but the login challenge dialog box doesn't pop up as it does on the virtual hosts without the rewrite rules.

    I try to delete the .htaccess file in the /stats/ directory - the problem is that ISPconfig keep on automatically adding that .htaccess file.

    I'm sure it is a issue with mod_rewrite not working well with .htaccess - perhaps somebody has a bit of advice ?

    Here is the rewrite rules from my "optional" Apache directives setting.

    **********************************************
    <Files ~ '.(pl)$'>
    SetHandler perl-script
    PerlHandler ModPerl::Registry
    </Files>
    RewriteEngine On
    RewriteRule ^/extras/ - [L]
    RewriteRule ^/env.pl - [L]
    RewriteRule ^/uploads/ - [L]
    RewriteRule ^/stats/ - [L]
    RewriteRule ^/images/ - [L]
    RewriteRule ^/images_files/ - [L]
    RewriteRule ^/extras/ - [L]
    RewriteRule ^/(.*) /index.pl/$1
    *****************************************
     
  2. till

    till Super Moderator Howtoforge Staff HowtoForge Supporter ISPConfig Developer

  3. ozonblue

    ozonblue New Member

    AllowOverride All didn solve the problem.

    i have however noticed that the error message is produced by the browser - not the server. Adding another rewrite rule that excluded rewriting browser requests for /error/ mysteriously soved the problem :)

    regards,

    Eugene Coetzee
     

Share This Page