dissect.target.helpers.sunrpc.client
¶
Module Contents¶
Classes¶
Abstract base class for generic types. |
|
An abstract base class for context managers. |
Functions¶
Attributes¶
- dissect.target.helpers.sunrpc.client.Credentials¶
- dissect.target.helpers.sunrpc.client.Verifier¶
- dissect.target.helpers.sunrpc.client.Params¶
- dissect.target.helpers.sunrpc.client.Results¶
- class dissect.target.helpers.sunrpc.client.AuthScheme¶
Bases:
Generic
[Credentials
,Verifier
]Abstract base class for generic types.
A generic type is typically declared by inheriting from this class parameterized with one or more type variables. For example, a generic mapping type might be defined as:
class Mapping(Generic[KT, VT]): def __getitem__(self, key: KT) -> VT: ... # Etc.
This class can then be used as follows:
def lookup_name(mapping: Mapping[KT, VT], key: KT, default: VT) -> VT: try: return mapping[key] except KeyError: return default
- credentials: Credentials¶
- verifier: Verifier¶
- credentials_serializer: dissect.target.helpers.sunrpc.serializer.AuthSerializer[Credentials]¶
- verifier_serializer: dissect.target.helpers.sunrpc.serializer.AuthSerializer[Verifier]¶
- dissect.target.helpers.sunrpc.client.auth_null() AuthScheme[dissect.target.helpers.sunrpc.sunrpc.AuthNull, dissect.target.helpers.sunrpc.sunrpc.AuthNull] ¶
- dissect.target.helpers.sunrpc.client.auth_unix(machine: str | None, uid: int, gid: int, gids: list[int]) AuthScheme[dissect.target.helpers.sunrpc.sunrpc.AuthUnix, dissect.target.helpers.sunrpc.sunrpc.AuthNull] ¶
- exception dissect.target.helpers.sunrpc.client.MismatchXidError¶
Bases:
Exception
Common base class for all non-exit exceptions.
- exception dissect.target.helpers.sunrpc.client.UnexpectedResponse¶
Bases:
Exception
Common base class for all non-exit exceptions.
- exception dissect.target.helpers.sunrpc.client.IncompleteMessage¶
Bases:
Exception
Common base class for all non-exit exceptions.
- class dissect.target.helpers.sunrpc.client.Client(sock: socket.socket, auth: AuthScheme[Credentials, Verifier], fragment_size: int = 8192)¶
Bases:
contextlib.AbstractContextManager
,Generic
[Credentials
,Verifier
]An abstract base class for context managers.
- PMAP_PORT = 111¶
- classmethod connect(hostname: str, port: int, auth: AuthScheme[Credentials, Verifier], local_port: int = 0) Client ¶
- __exit__(_: type[BaseException] | None, __: BaseException | None, ___: types.TracebackType | None) bool ¶
Raise any exception triggered within the runtime context.
- close() None ¶
- call(proc_desc: dissect.target.helpers.nfs.nfs3.ProcedureDescriptor, params: Params, params_serializer: dissect.target.helpers.sunrpc.serializer.XdrSerializer[Params], result_deserializer: dissect.target.helpers.sunrpc.serializer.XdrDeserializer[Results]) Results ¶
Synchronously call an RPC procedure and return the result
- __del__()¶