Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. UriSigner.php

function UriSigner::computeHash

2 calls to UriSigner::computeHash()
UriSigner::check in vendor/symfony/http-foundation/UriSigner.php
Checks that a URI contains the correct hash. Also checks if the URI has not expired (If you used expiration during signing).
UriSigner::sign in vendor/symfony/http-foundation/UriSigner.php
Signs a URI.

File

vendor/symfony/http-foundation/UriSigner.php, line 125

Class

UriSigner
@author Fabien Potencier <fabien@symfony.com>

Namespace

Symfony\Component\HttpFoundation

Code

private function computeHash(string $uri) : string {
    return base64_encode(hash_hmac('sha256', $uri, $this->secret, true));
}
RSS feed
Powered by Drupal