public static function validateToken ($name = 'csrfToken', $token = null)
    {
        if ($token === null) $token = Http::getInstance()->request()->paramPost($name);
        if (! is_string($token)) return false;
        return hash_equals($token, Http::getInstance()->session()->get($name));
    }