protected function AcquiaSearchService::authenticateResponse in Acquia Connector 7
Same name and namespace in other branches
- 7.3 acquia_search/Acquia_Search_Service.php \AcquiaSearchService::authenticateResponse()
- 7.2 acquia_search/Acquia_Search_Service.php \AcquiaSearchService::authenticateResponse()
Validate the hmac for the response body.
Return value
The response object.
3 calls to AcquiaSearchService::authenticateResponse()
- AcquiaSearchService::makeServletRequest in acquia_search/
Acquia_Search_Service.php - Make a request to a servlet (a path) that's not a standard path.
- AcquiaSearchService::_sendRawGet in acquia_search/
Acquia_Search_Service.php - Central method for making a GET operation against this Solr Server
- AcquiaSearchService::_sendRawPost in acquia_search/
Acquia_Search_Service.php - Central method for making a POST operation against this Solr Server
File
- acquia_search/
Acquia_Search_Service.php, line 61
Class
- AcquiaSearchService
- Starting point for the Solr API. Represents a Solr server resource and has methods for pinging, adding, deleting, committing, optimizing and searching.
Code
protected function authenticateResponse($response, $nonce, $url) {
$hmac = acquia_search_extract_hmac($response->headers);
if (!acquia_search_valid_response($hmac, $nonce, $response->data, NULL, $this->env_id)) {
throw new Exception('Authentication of search content failed url: ' . $url);
}
return $response;
}