[Catalyst] Advice needed: Action for authentication check

Matthieu Codron matthieu at codron.org
Thu Aug 3 09:56:48 CEST 2006


Hi everyone,

I have been playing with some "recent" features of Catalyst like
Actions and forward chains.
I was wondering if an action could be used to provide encaspulated
authentication check like in:

sub dostuff : ActionClass('Secured') {
 ...
}

The Secured action would check if a user is logged in and would take
appropriate actions if not (redirect to a login page or an acces
denied page)

It seemed a bit top obvious, so I was wondering if I was missing something :-)

In general, are Actions meant to be some kind of AOP feature?

Thanks for the advice(s)

Regards,
-- 
Matthieu



More information about the Catalyst mailing list