You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Michael A Nachbaur <mi...@nachbaur.com> on 2002/01/28 23:07:45 UTC

Dynamically serving an .htaccess file with mod_perl

Hello all,

Does anyone know of a way that I can server the contents of an .htaccess
file dynamically?  I know Apache checks the request directory (and all
directories above it) for an .htaccess file before serving a file request,
but there is no mention of how it goes about loading that file.

thanks.

-man


Re: Dynamically serving an .htaccess file with mod_perl

Posted by Dave Hodgkinson <da...@davehodgkinson.com>.
dom@idealx.com writes:

> > > Does anyone know of a way that I can server the contents of an
> > > .htaccess file dynamically? 
> > Make the .htacess file in question a FIFO, with a script on the
> > backend that Does The Right Thing.
> 
> Whoops, you would loose big when two concurrent Apache processes
> attempt to access the .htaccess simultaneously... 

Not if the file is small enough...low level reads are granular up to,
I think 8k. Maybe.

-- 
Dave Hodgkinson, Wizard for Hire         http://www.davehodgkinson.com
Editor-in-chief, The Highway Star           http://www.deep-purple.com
   Interim Technical Director, Web Architecture Consultant for hire

Re: Dynamically serving an .htaccess file with mod_perl

Posted by do...@idealx.com.
> > Does anyone know of a way that I can server the contents of an
> > .htaccess file dynamically? 
> Make the .htacess file in question a FIFO, with a script on the
> backend that Does The Right Thing.

Whoops, you would loose big when two concurrent Apache processes
attempt to access the .htaccess simultaneously... Why not rewrite
AuthenHandler instead (we are on mod_perl list right ?)

-- 
Dominique QUATRAVAUX                           Ingénieur développeur sénior
01 44 42 00 35                                 IDEALX


Re: Dynamically serving an .htaccess file with mod_perl

Posted by darren chamberlain <dl...@users.sourceforge.net>.
Michael A Nachbaur <mi...@nachbaur.com> said something to this effect on 01/28/2002:
> Does anyone know of a way that I can server the contents of an
> .htaccess file dynamically?  I know Apache checks the request
> directory (and all directories above it) for an .htaccess file
> before serving a file request, but there is no mention of how
> it goes about loading that file.

Make the .htacess file in question a FIFO, with a script on the
backend that Does The Right Thing.

(darren)

-- 
Unix is an operating system, OS/2 is half an operating system,
Windows is a shell, and DOS is a boot partition virus.
    -- Peter H. Coffin

Re: Dynamically serving an .htaccess file with mod_perl

Posted by Matt Sergeant <ma...@sergeant.org>.
On Mon, 28 Jan 2002, Michael A Nachbaur wrote:

> Hello all,
>
> Does anyone know of a way that I can server the contents of an .htaccess
> file dynamically?  I know Apache checks the request directory (and all
> directories above it) for an .htaccess file before serving a file request,
> but there is no mention of how it goes about loading that file.

Not that I know of, but you can hook in there custom parsing code. It's
way too complex to explain though, so I suggest you get the eagle book
which goes into details on it.

-- 
<!-- Matt -->
<:->Get a smart net</:->