aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Lib
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2020-11-08 12:55:32 +0000
committerMario <mario@mariovavti.com>2020-11-08 12:55:32 +0000
commit255b6a14a8d993a086dc790e8c4dbe64ce6e3e48 (patch)
treea3b3fb650c9ffc117d4c0b871686c1309642b796 /Zotlabs/Lib
parente98804693dfde4a6da075fc9fdf85a0ac12c3658 (diff)
downloadvolse-hubzilla-255b6a14a8d993a086dc790e8c4dbe64ce6e3e48.tar.gz
volse-hubzilla-255b6a14a8d993a086dc790e8c4dbe64ce6e3e48.tar.bz2
volse-hubzilla-255b6a14a8d993a086dc790e8c4dbe64ce6e3e48.zip
less hubloc confusion
Diffstat (limited to 'Zotlabs/Lib')
-rw-r--r--Zotlabs/Lib/JSalmon.php2
-rw-r--r--Zotlabs/Lib/Zotfinger.php7
2 files changed, 5 insertions, 4 deletions
diff --git a/Zotlabs/Lib/JSalmon.php b/Zotlabs/Lib/JSalmon.php
index 67512046f..48a4e649b 100644
--- a/Zotlabs/Lib/JSalmon.php
+++ b/Zotlabs/Lib/JSalmon.php
@@ -51,7 +51,7 @@ class JSalmon {
. base64url_encode($x['encoding'],true) . '.'
. base64url_encode($x['alg'],true);
- $key = HTTPSig::get_key(EMPTY_STR,base64url_decode($x['sigs']['key_id']));
+ $key = HTTPSig::get_key(EMPTY_STR,'zot6',base64url_decode($x['sigs']['key_id']));
logger('key: ' . print_r($key,true));
if($key['portable_id'] && $key['public_key']) {
if(rsa_verify($signed_data,base64url_decode($x['sigs']['value']),$key['public_key'])) {
diff --git a/Zotlabs/Lib/Zotfinger.php b/Zotlabs/Lib/Zotfinger.php
index 722e34dfc..e853d6ebc 100644
--- a/Zotlabs/Lib/Zotfinger.php
+++ b/Zotlabs/Lib/Zotfinger.php
@@ -6,7 +6,7 @@ use Zotlabs\Web\HTTPSig;
class Zotfinger {
- static function exec($resource,$channel = null) {
+ static function exec($resource,$channel = null, $verify = true) {
if(! $resource) {
return false;
@@ -41,8 +41,9 @@ class Zotfinger {
logger('fetch: ' . print_r($x,true));
if($x['success']) {
-
- $result['signature'] = HTTPSig::verify($x);
+ if ($verify) {
+ $result['signature'] = HTTPSig::verify($x, EMPTY_STR, 'zot6');
+ }
$result['data'] = json_decode($x['body'],true);