# ``twisted`.`conch`.`avatar`.`ConchUser``

class documentation

`class ConchUser: (source)`

Known subclasses: `twisted.conch.manhole_ssh.TerminalUser`, `twisted.conch.unix.UnixConchUser`

Implements interfaces: `twisted.conch.interfaces.IConchUser`

View In Hierarchy

Undocumented

Method | `__init__` | Undocumented
Method | `conn.setter` | Undocumented
Method | `gotGlobalRequest` | A global request was sent from the other side.
Method | `lookupChannel` | The other side requested a channel of some sort.
Method | `lookupSubsystem` | The other side requested a subsystem.
Instance Variable | `channelLookup` | Undocumented
Instance Variable | `subsystemLookup` | Undocumented
Property | `conn` | The SSHConnection object for this user.
Class Variable | `_log` | Undocumented
Instance Variable | `_conn` | Undocumented

def __init__(self): (source)
overridden in `twisted.conch.manhole_ssh.TerminalUser`, `twisted.conch.unix.UnixConchUser`

Undocumented

@conn.setter
def conn(self, value): (source)

Undocumented

def gotGlobalRequest(self, requestType, data): (source)
from `twisted.conch.interfaces.IConchUser`

A global request was sent from the other side.

We return a true value on success or a false value on failure. If we indicate success by returning a tuple, its second item will be sent to the other side as additional response data.

Parameters
requestType:`bytes` | The type of the request
data:`bytes` | Additional request data
Returns
boolean or `tuple` | Undocumented

def lookupChannel(self, channelType, windowSize, maxPacket, data): (source)
from `twisted.conch.interfaces.IConchUser`

The other side requested a channel of some sort.

`channelType` is the type of channel being requested, as an ssh connection protocol channel type. `data` is any other packet data (often nothing).

We return a subclass of `SSHChannel`. If the channel type is unknown, we return `None`.

For other failures, we raise an exception. If a `ConchError` is raised, the `.value` will be the message, and the `.data` will be the error code.

Parameters
channelType:`bytes` | The requested channel type
windowSize:`int` | The initial size of the remote window
maxPacket:`int` | The largest packet we should send
data:`bytes` | Additional request data
Returns
a subclass of `SSHChannel` or `None` | Undocumented

def lookupSubsystem(self, subsystem, data): (source)
from `twisted.conch.interfaces.IConchUser`

The other side requested a subsystem.

We return a `Protocol` implementing the requested subsystem. If the subsystem is not available, we return `None`.

Parameters
subsystem:`bytes` | The name of the subsystem being requested
data:`bytes` | Additional request data (often nothing)
Returns
`Protocol` or `None` | Undocumented

channelLookup: `dict` = (source)

Undocumented

subsystemLookup: `dict` = (source)

Undocumented

@property
conn = (source)
from `twisted.conch.interfaces.IConchUser`
The SSHConnection object for this user.
_log = (source)

Undocumented

_conn = (source)

Undocumented