projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
7e60c33
)
DataObjects/Core_person.php
author
Alan Knowles
<alan@roojs.com>
Thu, 17 Dec 2020 06:53:16 +0000
(14:53 +0800)
committer
Alan Knowles
<alan@roojs.com>
Thu, 17 Dec 2020 06:53:16 +0000
(14:53 +0800)
DataObjects/Core_person.php
patch
|
blob
|
history
diff --git
a/DataObjects/Core_person.php
b/DataObjects/Core_person.php
index
2ce28a2
..
e8b1644
100644
(file)
--- a/
DataObjects/Core_person.php
+++ b/
DataObjects/Core_person.php
@@
-549,8
+549,8
@@
class Pman_Core_DataObjects_Core_person extends DB_DataObject
function genAutoLoginURL($url, $expires = false)
{
$expires = $expires === false ? strtotime("NOW + 1 WEEK") : $expires;
function genAutoLoginURL($url, $expires = false)
{
$expires = $expires === false ? strtotime("NOW + 1 WEEK") : $expires;
- echo serialize(array($url, $expires, $this->email, $this->passwd));
- echo hash('sha256', serialize(array($url, $expires, $this->email, $this->passwd)));
+
//
echo serialize(array($url, $expires, $this->email, $this->passwd));
+
//
echo hash('sha256', serialize(array($url, $expires, $this->email, $this->passwd)));
return $url.'/'.$this->id .'/'.$expires.'/'.
hash('sha256',
return $url.'/'.$this->id .'/'.$expires.'/'.
hash('sha256',
@@
-573,8
+573,8
@@
class Pman_Core_DataObjects_Core_person extends DB_DataObject
if ($time < time()) {
return false;
}
if ($time < time()) {
return false;
}
- echo serialize(array('/'.$url, $time, $u->email, $u->passwd));
- echo hash('sha256', serialize(array('/'.$url, $time, $u->email, $u->passwd)));
+
//
echo serialize(array('/'.$url, $time, $u->email, $u->passwd));
+
//
echo hash('sha256', serialize(array('/'.$url, $time, $u->email, $u->passwd)));
if ($hash == hash('sha256', serialize(array('/'.$url, $time*1, $u->email, $u->passwd)))) {
$u->login();
return $u;
if ($hash == hash('sha256', serialize(array('/'.$url, $time*1, $u->email, $u->passwd)))) {
$u->login();
return $u;