esshd v0.1.0 Sshd.ShellHandler behaviour View Source

As incoming SSH connections are accepted, authorized, and request remote shell services; they are passed to the Sshd.ShellHandler.on_shell/4 callback.

Link to this section Summary

Callbacks

User function callback to perform any tasks prior to launching a shell session

User function callback to perform any tasks after a shell session. Will always be called, regardless of disconnect reason

User function callback to handle incoming shell requests

Link to this section Types

Link to this type ip_address() View Source
ip_address() :: :inet.ip_address
Link to this type peer_address() View Source
peer_address() :: {ip_address, port_number}
Link to this type port_number() View Source
port_number() :: :inet.port_number
Link to this type ssh_publickey() View Source
ssh_publickey() :: binary

Link to this section Callbacks

Link to this callback on_connect(username, ip_address, port_number, method) View Source
on_connect(username, ip_address, port_number, method) ::
  :ok |
  {:error, any}

User function callback to perform any tasks prior to launching a shell session.

Link to this callback on_disconnect(username, ip_address, port_number) View Source
on_disconnect(username, ip_address, port_number) ::
  :ok |
  {:error, any}

User function callback to perform any tasks after a shell session. Will always be called, regardless of disconnect reason.

Link to this callback on_shell(username, ssh_publickey, ip_address, port_number) View Source
on_shell(username, ssh_publickey, ip_address, port_number) ::
  :ok |
  {:error, any}

User function callback to handle incoming shell requests.