> Well then my next question then becomes: is it possible with mod_perl
> to hook into other modules' calls (I'm trying to not duplicate all of
> mod_access, merely change the return value)?
> 
> eg along the lines of:
> 
> sub handler {
>   my $r = shift;
>   if ($r->api_call('check_dir_access') == FORBIDDEN) {
>      $r->headers_out->set(Location => $url);
>      return REDIRECT;
>   }
>   return DECLINED;
> }
> 
> along with appropriate directives to override mod_access,
> <Location />
>    Deny from all
>    PerlAccessHandler CTT::302
> </Location>
> 
> (I know I'm grasping at straws by now, but... if the api call is
> exposeable, it becomes possible)

I would investigate other methods before trying this (such as the ideas Stas
had), but the short answer is that yes, you can call core functions
directly.  see recipe 8.9 in the mod_perl developer's cookbook.

  http://www.modperlcookbook.org/code/ch08/Cookbook/MIMEMagic.pm

HTH

--Geoff

-- 
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