X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FModule%2FOutbox.php;h=3a822cc6e50349f4267f492377b027aaab892bf9;hb=3f523a88b0af4e2a73b29917da33d221abef9647;hp=c2024151e5b0fe7059a51d3077aaa43f944c5204;hpb=f2c31ef1c0e92208b58d22791fc72d0ad3e3d6ae;p=friendica.git diff --git a/src/Module/Outbox.php b/src/Module/Outbox.php index c2024151e5..3a822cc6e5 100644 --- a/src/Module/Outbox.php +++ b/src/Module/Outbox.php @@ -1,13 +1,31 @@ . + * */ + namespace Friendica\Module; use Friendica\BaseModule; -use Friendica\Core\System; +use Friendica\DI; use Friendica\Model\User; use Friendica\Protocol\ActivityPub; +use Friendica\Util\HTTPSignature; /** * ActivityPub Outbox @@ -16,7 +34,7 @@ class Outbox extends BaseModule { public static function rawContent(array $parameters = []) { - $a = self::getApp(); + $a = DI::app(); // @TODO: Replace with parameter from router if (empty($a->argv[1])) { @@ -30,11 +48,8 @@ class Outbox extends BaseModule $page = $_REQUEST['page'] ?? null; - /// @todo Add Authentication to enable fetching of non public content - // $requester = HTTPSignature::getSigner('', $_SERVER); - - $outbox = ActivityPub\Transmitter::getOutbox($owner, $page); - + $requester = HTTPSignature::getSigner('', $_SERVER); + $outbox = ActivityPub\Transmitter::getOutbox($owner, $page, $requester); header('Content-Type: application/activity+json'); echo json_encode($outbox); exit();