nate, someone could want to use other hashing methods and not the
default one.
i vote for enabling :)

and adding the last crypt component to cake :D

On Jan 18, 6:18 am, nate <[EMAIL PROTECTED]> wrote:
> No.  Disabling password hashing is Evil with a capital "E".  That's
> why I don't let you do it.
>
> On Jan 17, 11:03 am, dizz <[EMAIL PROTECTED]> wrote:
>
> > Thanks to both of you, I thought of this, but I thought it would be
> > easier to disable the AuthComponent::hashPasswords and then do what
> > Baz did above.
>
> > Anyways thanks again for the help.
>
> > -Andrew
>
> > On Jan 17, 10:45 pm, Baz <[EMAIL PROTECTED]> wrote:
>
> > > Yep,
>
> > > Use a different field, eg. new_password or something. (I'm assuming
> > > you're validating when creating a password. No need for login)
>
> > > Here's assuming you have a model called User:
>
> > > // needed for validation for some reason
> > > $this->User->set($this->data);
> > > if ($this->validates($this->data))
> > > {
> > >     $this->data['User']['passwd'] =
> > > $this->Auth->password($this->data['User']['new_passwd'] )
>
> > >     // all we did was hash passwords, no need to revalidate.
> > >     if ($this->save($this->data, false))
> > >     {
> > >         //    do stuff
> > >     } else
> > >     {
> > >         // invalid
> > >     }
>
> > > }
>
> > > Would be nice to stick this is beforeSave in the model, but you can't
> > > [easily] access the Auth component from the model.
>
> > > Hope this helps.
>
> > > On Jan 17, 2008 9:31 AM, dizz <[EMAIL PROTECTED]> wrote:
>
> > > > Hello,
>
> > > > I am using the auth component and before my model can validate the
> > > > password the auth component already encrypts the password so making it
> > > > impossible to use the between built in valid method.
>
> > > > Is there any work around for this?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
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