You are here

private static function JWT::safeStrlen in Auth0 Single Sign On 8.2

Get the number of bytes in cryptographic strings.

Parameters

string $str:

Return value

int

1 call to JWT::safeStrlen()
JWT::verify in vendor/firebase/php-jwt/src/JWT.php
Verify a signature with the message, key and method. Not all methods are symmetric, so we must have a separate verify and sign method.

File

vendor/firebase/php-jwt/src/JWT.php, line 385

Class

JWT
JSON Web Token implementation, based on this spec: https://tools.ietf.org/html/rfc7519

Namespace

Firebase\JWT

Code

private static function safeStrlen($str) {
  if (\function_exists('mb_strlen')) {
    return \mb_strlen($str, '8bit');
  }
  return \strlen($str);
}