[cgiapp] Re: CAP::Authorization, CAP::AutoRunmode & CA::Dispatch

Mark Stosberg mark at summersault.com
Wed Aug 12 10:40:21 EDT 2009


On Tue, 11 Aug 2009 10:52:51 +0100
Richard Jones <ra.jones at dpw.clara.co.uk> wrote:

> Am having some difficulty with the FORBIDDEN_RUNMODE param when using 
> CAP::Authorization with CA::Dispatch. All my application classes inherit 
> from a base class where I have defined the 'forbidden' runmode (using 
> AutoRunmode syntax). But declaring FORBIDDEN_RUNMODE => 'forbidden' in 
> authz->config() means that for some reason the classes loaded by 
> CA::Dispatch - which all 'use base MyApp::Base' - can't find the 
> forbidden() rm so return my error page instead.

I suggest looking into this a bit further. At the moment that the
forbidden run mode can't be found, has it been registered in the
run_modes() hash?

> and this actually works, even though I'm using a version 4.xx 
> CGI::Application - I get my forbidden() output rather than the error 
> page. But is this the right way to use CAP::Authorization in this
> situation? Should I expect CAP::Auth to work out-of-the-box with 
> CA::Dispatch?

I think these tools should be work together. In fact, I think I'm using
them together myself.

    Mark


-- 
 . . . . . . . . . . . . . . . . . . . . . . . . . . . 
   Mark Stosberg            Principal Developer  
   mark at summersault.com     Summersault, LLC     
   765-939-9301 ext 202     database driven websites
 . . . . . http://www.summersault.com/ . . . . . . . .




More information about the cgiapp mailing list