src/Token.php
public static function validate(string $token, string $secret): bool
    {
        $parse = self::parser($token, $secret);

        if (!self::validateWithExpiration($parse)) {
            return false;
        }

        if (!self::validateNotBefore($parse)) {
            return false;
        }

        return true;
    }
public static function validate(string $token, string $secret): bool
    {
        $parse = self::parser($token, $secret);

        if (!self::validateWithExpiration($parse)) {
            return false;
        }

        if (!self::validateNotBefore($parse)) {
            return false;
        }

        return true;
    }
public static function validate ( string $ token , string $ secret ) : bool { $ parse = self :: parser ( $ token , $ secret ) ; if ( ! self :: validateWithExpiration ( $ parse ) ) { return false ; } if ( ! self :: validateNotBefore ( $ parse ) ) { return false ; } return true ; }
Validate the Json web token, check it's structure and signature. Also
check its expiration claim and not before claim if they are set.

@param string $token
@param string $secret

@return bool
Validate the Json web token check it s structure and signature . Also check its expiration claim and not before claim if they are set .