Struct thrussh::server::Session

source ·
pub struct Session(_);
Expand description

A connected server session. This type is unique to a client.

Implementations

Flush the session, i.e. encrypt the pending buffer.

Retrieves the configuration of this session.

Sends a disconnect message.

Send a “success” reply to a /global/ request (requests without a channel number, such as TCP/IP forwarding or cancelling). Always call this function if the request was successful (it checks whether the client expects an answer).

Send a “failure” reply to a global request.

Send a “success” reply to a channel request. Always call this function if the request was successful (it checks whether the client expects an answer).

Send a “failure” reply to a global request.

Send a “failure” reply to a request to open a channel open.

Close a channel.

Send EOF to a channel

Send data to a channel. On session channels, extended can be used to encode standard error by passing Some(1), and stdout by passing None.

The number of bytes added to the “sending pipeline” (to be processed by the event loop) is returned.

Inform the client of whether they may perform control-S/control-Q flow control. See RFC4254.

Send the exit status of a program.

If the program was killed by a signal, send the details about the signal to the client.

Open a TCP/IP forwarding channel, when a connection comes to a local port for which forwarding has been requested. See RFC4254. The TCP/IP packets can then be tunneled through the channel using .data().

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.