X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FProtocol%2FSalmon.php;h=81b1f7528d67f7725e0d0c96027b997505970e2c;hb=424a85bb9424d5b826734147add52f4d196f13c9;hp=77084591022b0fa2f994ab893dbc23de53d06228;hpb=c947b7f211e2468561a8864b2141dfcbfe65b63b;p=friendica.git diff --git a/src/Protocol/Salmon.php b/src/Protocol/Salmon.php index 7708459102..81b1f7528d 100644 --- a/src/Protocol/Salmon.php +++ b/src/Protocol/Salmon.php @@ -1,6 +1,6 @@ fetch($ret[$x]); } } } @@ -155,7 +155,7 @@ class Salmon $salmon = XML::fromArray($xmldata, $xml, false, $namespaces); // slap them - $postResult = Network::post($url, $salmon, [ + $postResult = DI::httpRequest()->post($url, $salmon, [ 'Content-type: application/magic-envelope+xml', 'Content-length: ' . strlen($salmon) ]); @@ -180,7 +180,7 @@ class Salmon $salmon = XML::fromArray($xmldata, $xml, false, $namespaces); // slap them - $postResult = Network::post($url, $salmon, [ + $postResult = DI::httpRequest()->post($url, $salmon, [ 'Content-type: application/magic-envelope+xml', 'Content-length: ' . strlen($salmon) ]); @@ -203,7 +203,7 @@ class Salmon $salmon = XML::fromArray($xmldata, $xml, false, $namespaces); // slap them - $postResult = Network::post($url, $salmon, [ + $postResult = DI::httpRequest()->post($url, $salmon, [ 'Content-type: application/magic-envelope+xml', 'Content-length: ' . strlen($salmon)]); $return_code = $postResult->getReturnCode(); @@ -229,7 +229,7 @@ class Salmon */ public static function salmonKey($pubkey) { - Crypto::pemToMe($pubkey, $m, $e); - return 'RSA' . '.' . Strings::base64UrlEncode($m, true) . '.' . Strings::base64UrlEncode($e, true); + Crypto::pemToMe($pubkey, $modulus, $exponent); + return 'RSA' . '.' . Strings::base64UrlEncode($modulus, true) . '.' . Strings::base64UrlEncode($exponent, true); } }