diff options
author | zotlabs <mike@macgirvin.com> | 2017-09-03 23:50:18 -0700 |
---|---|---|
committer | zotlabs <mike@macgirvin.com> | 2017-09-03 23:50:18 -0700 |
commit | fc62f07a089daf698953e6e4197668fbf8aebef9 (patch) | |
tree | 3e6a0b53dc61008b336497eb16a693b8670b6004 /Zotlabs/Zot | |
parent | 3d0a7f4fc5eacbafa08f49118dc7e54927b4fbed (diff) | |
download | volse-hubzilla-fc62f07a089daf698953e6e4197668fbf8aebef9.tar.gz volse-hubzilla-fc62f07a089daf698953e6e4197668fbf8aebef9.tar.bz2 volse-hubzilla-fc62f07a089daf698953e6e4197668fbf8aebef9.zip |
validate the security context
Diffstat (limited to 'Zotlabs/Zot')
-rw-r--r-- | Zotlabs/Zot/Auth.php | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Zotlabs/Zot/Auth.php b/Zotlabs/Zot/Auth.php index 92b0fff78..afb7b1535 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) { @@ -153,6 +159,7 @@ class Auth { dbesc($hubloc['hubloc_url']) ); + // needs a nonce!!!! $p = zot_build_packet($channel,$type = 'auth_check', array(array('guid' => $hubloc['hubloc_guid'],'guid_sig' => $hubloc['hubloc_guid_sig'])), $hubloc['hubloc_sitekey'], (($x) ? $x[0]['site_crypto'] : ''), $this->sec); |