aboutsummaryrefslogtreecommitdiffstats
path: root/mod/probe.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-12-29 00:33:04 -0800
committerfriendica <info@friendica.com>2012-12-29 00:33:04 -0800
commit098de66c2fcda2e6e2449640e888a0d1f9e5aa84 (patch)
treeb4d445749234a04906cf8bc7f7b779735ab597f9 /mod/probe.php
parent70153a22744bf96bab4b1f76ab0841fd999ddd6e (diff)
downloadvolse-hubzilla-098de66c2fcda2e6e2449640e888a0d1f9e5aa84.tar.gz
volse-hubzilla-098de66c2fcda2e6e2449640e888a0d1f9e5aa84.tar.bz2
volse-hubzilla-098de66c2fcda2e6e2449640e888a0d1f9e5aa84.zip
probe diagnostic translated to zot, will use your current channel for permissions, logout to check anonymous permissions
Diffstat (limited to 'mod/probe.php')
-rw-r--r--mod/probe.php10
1 files changed, 7 insertions, 3 deletions
diff --git a/mod/probe.php b/mod/probe.php
index c95db291b..f90728df2 100644
--- a/mod/probe.php
+++ b/mod/probe.php
@@ -1,6 +1,7 @@
<?php
require_once('include/Scrape.php');
+require_once('include/zot.php');
function probe_content(&$a) {
@@ -13,11 +14,14 @@ function probe_content(&$a) {
$o .= '<br /><br />';
if(x($_GET,'addr')) {
-
+ $channel = $a->get_channel();
$addr = trim($_GET['addr']);
- $res = probe_url($addr);
+ $res = zot_finger($addr,$channel);
$o .= '<pre>';
- $o .= str_replace("\n",'<br />',print_r($res,true));
+ $j = json_decode($res['body'],true);
+ if($j && $j['permissions'] && $j['permissions']['iv'])
+ $j['permissions'] = json_decode(aes_unencapsulate($j['permissions'],$channel['channel_prvkey']),true);
+ $o .= str_replace("\n",'<br />',print_r($j,true));
$o .= '</pre>';
}
return $o;