| Server IP : 202.155.9.250 / Your IP : 216.73.217.177 Web Server : LiteSpeed System : Linux srv339029361 5.15.0-177-generic #187-Ubuntu SMP Sat Apr 11 22:54:33 UTC 2026 x86_64 User : grabn6394 ( 1016) PHP Version : 8.0.30 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/local/CyberPanel/lib/python3.10/site-packages/asyncssh/ |
Upload File : |
# Copyright (c) 2017-2024 by Ron Frederick <ronf@timeheart.net> and others.
#
# This program and the accompanying materials are made available under
# the terms of the Eclipse Public License v2.0 which accompanies this
# distribution and is available at:
#
# http://www.eclipse.org/legal/epl-2.0/
#
# This program may also be made available under the following secondary
# licenses when the conditions for such availability set forth in the
# Eclipse Public License v2.0 are satisfied:
#
# GNU General Public License, Version 2.0, or any later versions of
# that license
#
# SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later
#
# Contributors:
# Ron Frederick - initial implementation, API, and documentation
"""GSSAPI wrapper"""
import sys
from typing import Optional
from .misc import BytesOrStrDict
try:
# pylint: disable=unused-import
if sys.platform == 'win32': # pragma: no cover
from .gss_win32 import GSSBase, GSSClient, GSSServer, GSSError
else:
from .gss_unix import GSSBase, GSSClient, GSSServer, GSSError
gss_available = True
except ImportError: # pragma: no cover
gss_available = False
class GSSError(ValueError): # type: ignore
"""Stub class for reporting that GSS is not available"""
def __init__(self, maj_code: int, min_code: int,
token: Optional[bytes] = None):
super().__init__('GSS not available')
self.maj_code = maj_code
self.min_code = min_code
self.token = token
class GSSBase: # type: ignore
"""Base class for reporting that GSS is not available"""
class GSSClient(GSSBase): # type: ignore
"""Stub client class for reporting that GSS is not available"""
def __init__(self, _host: str, _store: Optional[BytesOrStrDict],
_delegate_creds: bool):
raise GSSError(0, 0)
class GSSServer(GSSBase): # type: ignore
"""Stub client class for reporting that GSS is not available"""
def __init__(self, _host: str, _store: Optional[BytesOrStrDict]):
raise GSSError(0, 0)