On 16 Apr 2012, at 07:11, brainbuz wrote:
> In my auto action I have something like:
>
> $c->{ USERNAME } = $c->engine->env->{ HTTP_COOKIE } ;#Authenticated via
> apache 2.4 mod_auth_form
>
> $c->{ USERRIGHTS } = $c->model( ‘method returning a ref to a list of the
> rights for $c->{ USERNAME }’);
>
Writing into the context object like this is fairly disrecommended - using the
stash (or adding accessors on your context) is probably nicer..
Also, the authentication framework can probably do most of the heavy lifting
for you instead of doing this manually…
Anyway, no matter - the answer you're probably looking for is to use
Plack::Middleware::ForceEnv
Cheers
t0m
_______________________________________________
List: [email protected]
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[email protected]/
Dev site: http://dev.catalyst.perl.org/