Hello Martin,

Thank you for you answer. I had to implement my custom methods find()
and hashPassword() in the user model. I end up with:

hashPasswords:
1) find username in database
2) if username not found, fail
3) check user type. if type = "local" then return Security::hash()
4) if type = "nis", find user in NIS domain and get the salt from its
password hash
5) hash the form data using salt from NIS

find:
1) check if there is a "password" in conditions
2) if not, return parent::find()
3) find username in database
4) check user type. if type = "local" then return parent::find()
5) if type = "nis", find user in NIS domain and compare given password
with NIS password
6) if passwords matches, return the user array. if not, return false

I am wasting some database queries but thats the best i could achieve
without having to write my own component.

Best Regards,
~IF.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to