assh/assh_event.h header reference

Description  

The API of the library is event based, as explained in the Event based API section.

This header contains declaration of the assh_event_s structure as well as event management functions.

Members  

Types  

Functions  

  • void assh_event_done(assh_session_s *s, assh_event_s *e, assh_status_e err)
  • assh_bool_t assh_event_get(assh_session_s *s, assh_event_s *e, assh_time_t time)

Members detail  

void assh_event_done(assh_session_s *s, assh_event_s *e, assh_status_e err)  

This function is declared in assh/assh_event.h source file, line 248.

This function acknowledges the last event returned by the assh_event_get function.

If an error occurred during event processing by the caller, it should be reported to this function, especially if the error must terminate the session.

When an error is reported, the content of the event object is considered undefined by the library. The error will later be reported by an ASSH_EVENT_SESSION_ERROR event unless shadowed by an other error of higher severity.

See also State machines and Event based API.

assh_bool_t assh_event_get(assh_session_s *s, assh_event_s *e, assh_time_t time)  

This function is declared in assh/assh_event.h source file, line 229.

This function runs the various state machines which implement the ssh2 protocol, including the currently running service and key-exchange. It then reports the next available event to the caller.

The assh_event_done function must be called after each successful call to this function, before requesting the next event.

This function can be called again unless 0 is returned eventually. This occurs when the session terminates.

When the function returns 1, the passed object event is initialized and can be examined by the application.

In order for the library to handle protocol timeouts properly, the current time in seconds has to be passed to this function. When this is the case, the assh_session_deadline function can be used to get the next ssh2 protocol deadline.

See also State machines, Event based API and assh_session_closed.

enum assh_event_id_e  

This enum is declared in assh/assh_event.h source file, line 42.

This enum specifies event types.

IdentifierDescription
ASSH_EVENT_READSee assh_event_transport_read_s.
ASSH_EVENT_WRITESee assh_event_transport_write_s.
ASSH_EVENT_DISCONNECTSee assh_event_transport_disconnect_s.
ASSH_EVENT_DEBUGSee assh_event_transport_debug_s.
ASSH_EVENT_SESSION_ERRORSee assh_event_session_error_s.
ASSH_EVENT_KEX_HOSTKEY_LOOKUPSee assh_event_kex_hostkey_lookup_s.
ASSH_EVENT_KEX_DONESee assh_event_kex_done_s.
ASSH_EVENT_SERVICE_STARTSee assh_event_service_start_s.
ASSH_EVENT_USERAUTH_CLIENT_USERSee assh_event_userauth_client_user_s.
ASSH_EVENT_USERAUTH_CLIENT_METHODSSee assh_event_userauth_client_methods_s.
ASSH_EVENT_USERAUTH_CLIENT_BANNERSee assh_event_userauth_client_banner_s.
ASSH_EVENT_USERAUTH_CLIENT_PWCHANGESee assh_event_userauth_client_pwchange_s.
ASSH_EVENT_USERAUTH_CLIENT_KEYBOARDSee assh_event_userauth_client_keyboard_s.
ASSH_EVENT_USERAUTH_CLIENT_SUCCESS
ASSH_EVENT_USERAUTH_CLIENT_SIGNSee assh_event_userauth_client_sign_s.
ASSH_EVENT_USERAUTH_SERVER_METHODSSee assh_event_userauth_server_methods_s.
ASSH_EVENT_USERAUTH_SERVER_NONESee assh_event_userauth_server_none_s.
ASSH_EVENT_USERAUTH_SERVER_USERKEYSee assh_event_userauth_server_userkey_s.
ASSH_EVENT_USERAUTH_SERVER_PASSWORDSee assh_event_userauth_server_password_s.
ASSH_EVENT_USERAUTH_SERVER_KBINFOSee assh_event_userauth_server_kbinfo_s.
ASSH_EVENT_USERAUTH_SERVER_KBRESPONSESee assh_event_userauth_server_kbresponse_s.
ASSH_EVENT_USERAUTH_SERVER_HOSTBASEDSee assh_event_userauth_server_hostbased_s.
ASSH_EVENT_USERAUTH_SERVER_SUCCESSSee assh_event_userauth_server_success_s.
ASSH_EVENT_REQUESTSee assh_event_request_s.
ASSH_EVENT_REQUEST_ABORTSee assh_event_request_abort_s.
ASSH_EVENT_REQUEST_SUCCESSSee assh_event_request_success_s.
ASSH_EVENT_REQUEST_FAILURESee assh_event_request_failure_s.
ASSH_EVENT_CHANNEL_OPENSee assh_event_channel_open_s.
ASSH_EVENT_CHANNEL_CONFIRMATIONSee assh_event_channel_confirmation_s.
ASSH_EVENT_CHANNEL_FAILURESee assh_event_channel_failure_s.
ASSH_EVENT_CHANNEL_DATASee assh_event_channel_data_s.
ASSH_EVENT_CHANNEL_WINDOWSee assh_event_channel_window_s.
ASSH_EVENT_CHANNEL_EOFSee assh_event_channel_eof_s.
ASSH_EVENT_CHANNEL_CLOSESee assh_event_channel_close_s.
ASSH_EVENT_CHANNEL_ABORTSee assh_event_channel_abort_s.

struct assh_event_s  

Valid XHTML 1.0 StrictGenerated by diaxen on Sun Sep 27 13:33:12 2020 using MkDoc