Fixes to bugs introduced by the multiple mail feature
This commit is contained in:
parent
31469204e0
commit
04069871bb
@ -86,7 +86,7 @@ class IDF_Form_Password extends Pluf_Form
|
||||
$return_url = Pluf_HTTP_URL_urlForView('IDF_Views::passwordRecoveryInputCode');
|
||||
$tmpl = new Pluf_Template('idf/user/passrecovery-email.txt');
|
||||
$cr = new Pluf_Crypt(md5(Pluf::f('secret_key')));
|
||||
$code = trim($cr->encrypt($user->email.':'.$user->id.':'.time()),
|
||||
$code = trim($cr->encrypt($user->email.':'.$user->id.':'.time().':primary'),
|
||||
'~');
|
||||
$code = substr(md5(Pluf::f('secret_key').$code), 0, 2).$code;
|
||||
$url = Pluf::f('url_base').Pluf_HTTP_URL_urlForView('IDF_Views::passwordRecovery', array($code), array(), false);
|
||||
|
@ -63,7 +63,7 @@ class IDF_Form_UserChangeEmail extends Pluf_Form
|
||||
throw new Pluf_Form_Invalid(__('The validation key is not valid. Please copy/paste it from your confirmation email.'));
|
||||
}
|
||||
$cr = new Pluf_Crypt(md5(Pluf::f('secret_key')));
|
||||
return explode(':', $cr->decrypt($encrypted), 3);
|
||||
return explode(':', $cr->decrypt($encrypted), 4);
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user