'sha512', 'private_key_bits' => 4096, 'private_key_type' => OPENSSL_KEYTYPE_RSA, ]); openssl_pkey_export($rsa, $private_key); $public_key = openssl_pkey_get_details($rsa)['key']; file_put_contents(ROOT.DS.'keys'.DS.'id_rsa', $private_key); file_put_contents(ROOT.DS.'keys'.DS.'id_rsa.pub', $public_key); } else { $public_key = file_get_contents(ROOT.DS.'keys'.DS.'id_rsa.pub'); } */ if(strpos($_SERVER['HTTP_ACCEPT'], 'application/activity+json') !== false): header('Content-Type: application/ld+json'); ?>{ "@context": [ "https://www.w3.org/ns/activitystreams", "https://w3id.org/security/v1" ], "id": "/actor", "type": "Person", "name": "", "summary": "", "preferredUsername": "", "manuallyApprovesFollowers": false, "discoverable": true, "publishedDate": "2023-01-01T00:00:00Z", "icon": { "url": "/favicon-large.png", "mediaType": "image/png", "type": "Image" }, "inbox": "/inbox", "outbox": "/outbox", "followers": "/followers", "publicKey": { "id": "/actor#main-key", "owner": "/actor", "publicKeyPem": "" } }