[Catalyst] progressive authentication via db & LDAP
Tomas Doran
bobtfish at bobtfish.net
Wed Jan 26 14:54:57 GMT 2011
On 26 Jan 2011, at 13:48, piccard wrote:
>
>> You set it in the config, you implement a check_password method in
>> your user object (which goes and checks the password from LDAP),
>> you're done.
>
>
> For anybody who is working on the same problem, this solution worked
> 4 me:
>
> + set the extended classin the config via the store_user_class-key
>
I don't think you even need to go that far..
The DBIx::Class::User module will delegate any unknown methods onto
your user row..
So you should just be able to add your check_password method onto the
row object, without having a custom user_class..
Then you get the initial advantage I was promoting (i.e. your database
model is internally consistent, and you can use check_password outside
of a Catalyst context if you want to), and you have less code...
Cheers
t0m
More information about the Catalyst
mailing list