diff options
Diffstat (limited to 'Zotlabs/Zot/Auth.php')
-rw-r--r-- | Zotlabs/Zot/Auth.php | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/Zotlabs/Zot/Auth.php b/Zotlabs/Zot/Auth.php index d4d3bee1d..8d198f506 100644 --- a/Zotlabs/Zot/Auth.php +++ b/Zotlabs/Zot/Auth.php @@ -43,6 +43,12 @@ class Auth { $this->Finalise(); } + if(strpbrk($this->sec,'.:')) { + logger('illegal security context'); + $this->Debug('illegal security context.'); + $this->Finalise(); + } + $x = $this->GetHublocs($this->address); if($x) { @@ -109,6 +115,14 @@ class Auth { $this->remote_hub = $hubloc['hubloc_url']; $this->dnt = 0; + if(! $this->sec) { + logger('missing security context.'); + if($this->test) + $this->Debug('missing security context.'); + return false; + } + + // check credentials and access // If they are already authenticated and haven't changed credentials, @@ -176,7 +190,7 @@ class Auth { return false; } - $this->Debug('auth check request returned .' . print_r($j, true)); + $this->Debug('auth check request returned ' . print_r($j, true)); if(! $j['success']) return false; |