> after I click submit:
> /app/Model/Milli.php (line 40)
> '6cff21416995c69a93338d57f969665dc2bb2e00'
> /app/Model/Milli.php (line 40)
> 'fc33ed920738abf172f2b56f6afbda65e86525de'
> The latter is correct, as stored in the database. What's going on?! I
> stored the password using same AuthComponent::password() call.
> --
> Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org > Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.
> To unsubscribe from this group, send email to
> cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
No, of course I didn't. Only one thing changed, don't know if it's
related: I entered the users and their hashed passwords in one
controller, then logged in as them and attempted hashing their own
password in the other. This shouldn't matter, unless Cake further
salts the hash using controller's name or something.
On May 18, 6:32 pm, Michael Gaiser <mjgai...@gmail.com> wrote:
> > after I click submit:
> > /app/Model/Milli.php (line 40)
> > '6cff21416995c69a93338d57f969665dc2bb2e00'
> > /app/Model/Milli.php (line 40)
> > 'fc33ed920738abf172f2b56f6afbda65e86525de'
> > The latter is correct, as stored in the database. What's going on?! I
> > stored the password using same AuthComponent::password() call.
> > --
> > Our newest site for the community: CakePHP Video Tutorialshttp://tv.cakephp.org > > Check out the new CakePHP Questions sitehttp://ask.cakephp.organd help others with their CakePHP related questions.
> > To unsubscribe from this group, send email to
> > cake-php+unsubscribe@googlegroups.com For more options, visit this group athttp://groups.google.com/group/cake-php
I should note that users are able to log in by entering their user/
pass, thus hashing works. It's just that I'm unable to generate the
same hash using AuthComponent::password('my-cleartext-pass')
I've figured it out. The callback receives data as array, so it should
have been
return AuthComponent::password($current_password['current_password'])
== $user[$this->alias]['password'];
PHP sucks... a good language would have told me that I'm sending it
array while it's expecting a string. I spent a couple of hours late
Friday to find where I got it wrong, to no avail.
Maybe - PHP has its pros and cons, however people whose understanding
of a language (or will to learn a language or use other peoples
codebases written in that language) amount to picking out a function
name and wanting to throw whatever parameters at it until there are no
errors spat out, or just happen to work by chance, lead to extremely
incompetent coders who usually, in one way or another, still make it
into the "profession" and give others a bad name.
On May 21, 12:43 am, rahajiyev <rahaji...@bankofbaku.com> wrote:
> PHP sucks... a good language would have told me that I'm sending it
> array while it's expecting a string. I spent a couple of hours late
> Friday to find where I got it wrong, to no avail.