0 && $course_id > 0 && 1 === preg_match( '/^[a-f0-9]{32}$/', $token ) && hash_equals( self::sign( $user_id, $course_id ), $token ); } }