Is there a way to tell Cake not to cache Auth info in the session?
Whenever the admin changes a users data (like the time when password
will expire) he needs to mirror that change in the Session so the user
Auth can pick up the changes and act accordingly:

  public function beforeSave() {
                $data = &$this->data[$this->alias];
                if (isset($data['new_password'])) {
                        $data['password'] =
AuthComponent::password($data['new_password']);
                        $data['password_expiration'] = date('Y-m-d
H:i:s', strtotime("+1 month"));
 
SessionComponent::write('Auth.User.password_expiration',
$data['password_expiration']);
                }
}

Without the last line, the stale data in Session would be used. This
isn't cool at all.

-- 
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+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php

Reply via email to