* Fix for sso login from zdoo.
This commit is contained in:
@@ -26,7 +26,7 @@ class sso extends control
|
||||
$this->app->loadConfig('sso');
|
||||
if(!$this->config->sso->turnon) return print($this->locate($locate));
|
||||
|
||||
if($type != 'return') return $this->ssoZen->locateNotifyLink($locate, $referer);
|
||||
if($type != 'return') return $this->ssoZen->locateNotifyLink($this->config->sso->addr, $referer);
|
||||
|
||||
$this->ssoZen->idenfyFromSSO($locate);
|
||||
return $this->locate($this->createLink('user', 'login', empty($referer) ? '' : "referer=$referer"));
|
||||
|
||||
+3
-3
@@ -104,8 +104,9 @@ class ssoZen extends sso
|
||||
{
|
||||
if($this->get->status != 'success' || md5($this->get->data) != $this->get->md5) return false;
|
||||
|
||||
$last = $this->server->request_time;
|
||||
$data = json_decode(base64_decode($this->get->data));
|
||||
$userIP = helper::getRemoteIp();
|
||||
$last = $this->server->request_time;
|
||||
$data = json_decode(base64_decode($this->get->data));
|
||||
|
||||
if($data->auth != $this->computeAuth($data->token)) return false;
|
||||
|
||||
@@ -224,4 +225,3 @@ class ssoZen extends sso
|
||||
return md5($code . $userIP . $token . $key);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user