use Friendica\Model\APContact;
use Friendica\Model\Contact;
use Friendica\Model\User;
-use Friendica\Network\CurlResult;
-use Friendica\Network\HTTPClientOptions;
-use Friendica\Network\IHTTPResult;
+use Friendica\Network\HTTPClient\Response\CurlResult;
+use Friendica\Network\HTTPClient\Client\HttpClientOptions;
+use Friendica\Network\HTTPClient\Capability\ICanHandleHttpResponses;
/**
* Implements HTTP Signatures per draft-cavage-http-signatures-07.
* 'nobody' => only return the header
* 'cookiejar' => path to cookie jar file
*
- * @return IHTTPResult CurlResult
+ * @return \Friendica\Network\HTTPClient\Capability\ICanHandleHttpResponses CurlResult
* @throws \Friendica\Network\HTTPException\InternalServerErrorException
*/
public static function fetchRaw($request, $uid = 0, $opts = ['accept_content' => ['application/activity+json', 'application/ld+json']])
}
$curl_opts = $opts;
- $curl_opts[HTTPClientOptions::HEADERS] = $header;
+ $curl_opts[HttpClientOptions::HEADERS] = $header;
if (!empty($opts['nobody'])) {
$curlResult = DI::httpClient()->head($request, $curl_opts);
public static function getSigner($content, $http_headers)
{
if (empty($http_headers['HTTP_SIGNATURE'])) {
- Logger::info('No HTTP_SIGNATURE header');
+ Logger::debug('No HTTP_SIGNATURE header');
return false;
}