aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Zot/Finger.php
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Zot/Finger.php')
-rw-r--r--Zotlabs/Zot/Finger.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/Zotlabs/Zot/Finger.php b/Zotlabs/Zot/Finger.php
index 778b701cd..cadde5415 100644
--- a/Zotlabs/Zot/Finger.php
+++ b/Zotlabs/Zot/Finger.php
@@ -2,6 +2,7 @@
namespace Zotlabs\Zot;
+use Zotlabs\Lib\Crypto;
use Zotlabs\Web\HTTPSig;
/**
@@ -109,7 +110,7 @@ class Finger {
$result = z_post_url('http://' . $host . $rhs,$postvars, $retries, [ 'headers' => $xhead ]);
}
}
- }
+ }
else {
$rhs .= '?f=&address=' . urlencode($address) . '&token=' . self::$token;
@@ -135,7 +136,7 @@ class Finger {
if($x && (! $verify['header_valid'])) {
$signed_token = ((is_array($x) && array_key_exists('signed_token', $x)) ? $x['signed_token'] : null);
if($signed_token) {
- $valid = rsa_verify('token.' . self::$token, base64url_decode($signed_token), $x['key']);
+ $valid = Crypto::verify('token.' . self::$token, base64url_decode($signed_token), $x['key']);
if(! $valid) {
logger('invalid signed token: ' . $url . $rhs, LOGGER_NORMAL, LOG_ERR);