protected function verifySecurityContextHash(array $tokenData, HttpRequest $httpRequest)
    {
        if (!isset($tokenData['securityContextHash'])) {
            return;
        }
        /** @var $actionRequest ActionRequest */
        $actionRequest = $this->objectManager->get(ActionRequest::class, $httpRequest);
        $this->securityContext->setRequest($actionRequest);
        if ($tokenData['securityContextHash'] !== $this->securityContext->getContextHash()) {
            $this->emitInvalidSecurityContextHash($tokenData, $httpRequest);
            throw new AccessDeniedException(sprintf('Invalid security hash!%sThis request is signed for a security context hash of "%s", but the current hash is "%s"',
                chr(10), $tokenData['securityContextHash'], $this->securityContext->getContextHash()), 1429705633);
        }
    }
protected function verifySecurityContextHash(array $tokenData, HttpRequest $httpRequest)
    {
        if (!isset($tokenData['securityContextHash'])) {
            return;
        }
        /** @var $actionRequest ActionRequest */
        $actionRequest = $this->objectManager->get(ActionRequest::class, $httpRequest);
        $this->securityContext->setRequest($actionRequest);
        if ($tokenData['securityContextHash'] !== $this->securityContext->getContextHash()) {
            $this->emitInvalidSecurityContextHash($tokenData, $httpRequest);
            throw new AccessDeniedException(sprintf('Invalid security hash!%sThis request is signed for a security context hash of "%s", but the current hash is "%s"',
                chr(10), $tokenData['securityContextHash'], $this->securityContext->getContextHash()), 1429705633);
        }
    }
protected function verifySecurityContextHash ( array $ tokenData , HttpRequest $ httpRequest ) { if ( ! isset ( $ tokenData [ 'securityContextHash' ] ) ) { return ; } /** @var $actionRequest ActionRequest */ $ actionRequest = $ this -> objectManager -> get ( ActionRequest :: class , $ httpRequest ) ; $ this -> securityContext -> setRequest ( $ actionRequest ) ; if ( $ tokenData [ 'securityContextHash' ] !== $ this -> securityContext -> getContextHash ( ) ) { $ this -> emitInvalidSecurityContextHash ( $ tokenData , $ httpRequest ) ; throw new AccessDeniedException ( sprintf ( 'Invalid security hash!%sThis request is signed for a security context hash of "%s", but the current hash is "%s"' , chr ( 10 ) , $ tokenData [ 'securityContextHash' ] , $ this -> securityContext -> getContextHash ( ) ) , 1429705633 ) ; } }
Checks whether the current request has the same security context hash as the one of the token

@param array $tokenData
@param HttpRequest $httpRequest
@return void
@throws AccessDeniedException
Checks whether the current request has the same security context hash as the one of the token