Merge branch 'dev' of /home/macgirvin/z into dev

This commit is contained in:
nobody 2021-02-28 16:44:26 -08:00
commit 9ec4a8c8a5
3 changed files with 470 additions and 449 deletions

View file

@ -9,26 +9,44 @@ use Zotlabs\Lib\Zotfinger;
// performs zot_finger on $argv[1], which is a hex_encoded webbie/reddress
class Gprobe {
static public function run($argc,$argv) {
if($argc != 2)
if ($argc != 2) {
return;
}
$url = hex2bin($argv[1]);
if(! strpos($url,'@'))
$protocols = [];
if (! strpos($url,'@')) {
return;
}
$r = q("select * from hubloc where hubloc_addr = '%s' limit 1",
$r = q("select * from hubloc where hubloc_addr = '%s'",
dbesc($url)
);
if(! $r) {
if ($r) {
foreach ($r as $rv) {
if ($rv['hubloc_network'] === 'activitypub') {
$protocols[] = 'activitypub';
continue;
}
if ($rv['hubloc_network'] === 'zot6') {
$protocols[] = 'zot6';
continue;
}
}
}
if (! in_array('zot6',$protocols)) {
$href = Webfinger::zot_url(punify($url));
if($href) {
if ($href) {
$zf = Zotfinger::exec($href,$channel);
}
if(is_array($zf) && array_path_exists('signature/signer',$zf) && $zf['signature']['signer'] === $href && intval($zf['signature']['header_valid'])) {
if (is_array($zf) && array_path_exists('signature/signer',$zf) && $zf['signature']['signer'] === $href && intval($zf['signature']['header_valid']) && isset($zf['data']) && $zf['data']) {
$xc = Libzot::import_xchan($zf['data']);
}
}

View file

@ -16,7 +16,7 @@ use Zotlabs\Daemon\Run;
* @brief This file defines some global constants and includes the central App class.
*/
define ( 'STD_VERSION', '21.02.25' );
define ( 'STD_VERSION', '21.03.01' );
define ( 'ZOT_REVISION', '6.0' );
define ( 'DB_UPDATE_VERSION', 1247 );

File diff suppressed because it is too large Load diff