The SSH library
These are the callbacks exported by the socket structure They are called by the socket module when a socket event appears
This function is called when the ssh_socket_connect was used on the socket on nonblocking state, and the connection successed.
This function will be called each time a controlflow state changes, i.e. the socket is available for reading or writing.
This function will be called each time data appears on socket. The data not consumed will appear on the next data event.
This function will be called each time an exception appears on socket. An exception can be a socket problem (timeout, ...) or an end-of-file.
User-provided data. User is free to set anything he wants here