Each plugin is required to return a pointer to a struct of this type as the return value from its entry point. More...
#include <gnunet_transport_plugin.h>
Data Fields | |
void * | cls |
Closure for all of the callbacks. More... | |
GNUNET_TRANSPORT_TransmitFunction | send |
Function that the transport service will use to transmit data to another peer. More... | |
GNUNET_TRANSPORT_DisconnectPeerFunction | disconnect_peer |
Function that can be used to force the plugin to disconnect from the given peer and cancel all previous transmissions (and their continuations). More... | |
GNUNET_TRANSPORT_DisconnectSessionFunction | disconnect_session |
Function that can be used to force the plugin to disconnect from the given peer and cancel all previous transmissions (and their continuations). More... | |
GNUNET_TRANSPORT_UpdateSessionTimeout | update_session_timeout |
Function that will be called whenever the transport service wants to notify the plugin that a session is still active and in use and therefore the session timeout for this session has to be updated. More... | |
GNUNET_TRANSPORT_UpdateInboundDelay | update_inbound_delay |
Function that will be called whenever the transport service wants to notify the plugin that the inbound quota changed and that the plugin should update it's delay for the next receive value. More... | |
GNUNET_TRANSPORT_QueryKeepaliveFactorFunction | query_keepalive_factor |
Function that is used to query keepalive factor. More... | |
GNUNET_TRANSPORT_AddressPrettyPrinter | address_pretty_printer |
Function to pretty-print addresses. More... | |
GNUNET_TRANSPORT_CheckAddress | check_address |
Function that will be called to check if a binary address for this plugin is well-formed and corresponds to an address for THIS peer (as per our configuration). More... | |
GNUNET_TRANSPORT_AddressToString | address_to_string |
Function that will be called to convert a binary address to a string (numeric conversion only). More... | |
GNUNET_TRANSPORT_StringToAddress | string_to_address |
Function that will be called to convert a string address to binary (numeric conversion only). More... | |
GNUNET_TRANSPORT_CreateSession | get_session |
Function that will be called tell the plugin to create a session object. More... | |
GNUNET_TRANSPORT_GetNetworkType | get_network |
Function to obtain the network type for a session. More... | |
GNUNET_TRANSPORT_GetNetworkTypeForAddress | get_network_for_address |
Function to obtain the network type for an address. More... | |
GNUNET_TRANSPORT_SessionMonitorSetup | setup_monitor |
Function to monitor the sessions managed by the plugin. More... | |
Each plugin is required to return a pointer to a struct of this type as the return value from its entry point.
Definition at line 624 of file gnunet_transport_plugin.h.
void* GNUNET_TRANSPORT_PluginFunctions::cls |
Closure for all of the callbacks.
Definition at line 629 of file gnunet_transport_plugin.h.
Referenced by add_address_to_hello(), add_address_to_uri(), add_valid_address(), GST_neighbours_calculate_receive_delay(), GST_plugins_monitor_subscribe(), GST_validation_handle_ping(), handle_client_address_to_string(), inbound_bw_tracker_update(), kill_session_task(), libgnunet_plugin_block_SERVICE_done(), LIBGNUNET_PLUGIN_TRANSPORT_DONE(), libgnunet_plugin_transport_http_client_done(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_done(), libgnunet_plugin_transport_tcp_init(), libgnunet_plugin_transport_udp_init(), libgnunet_plugin_transport_unix_done(), multicast_pong(), send_syn(), send_syn_ack_message(), send_with_session(), switch_address_bl_check_cont(), and transmit_ping_if_allowed().
GNUNET_TRANSPORT_TransmitFunction GNUNET_TRANSPORT_PluginFunctions::send |
Function that the transport service will use to transmit data to another peer.
May be NULL for plugins that only support receiving data. After this call, the plugin call the specified continuation with success or error before notifying us about the target having disconnected.
Definition at line 638 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), GST_validation_handle_ping(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), libgnunet_plugin_transport_udp_init(), multicast_pong(), send_syn(), send_syn_ack_message(), and transmit_ping_if_allowed().
GNUNET_TRANSPORT_DisconnectPeerFunction GNUNET_TRANSPORT_PluginFunctions::disconnect_peer |
Function that can be used to force the plugin to disconnect from the given peer and cancel all previous transmissions (and their continuations).
Definition at line 645 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_DisconnectSessionFunction GNUNET_TRANSPORT_PluginFunctions::disconnect_session |
Function that can be used to force the plugin to disconnect from the given peer and cancel all previous transmissions (and their continuations).
Definition at line 652 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), kill_session_task(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), libgnunet_plugin_transport_udp_init(), and switch_address_bl_check_cont().
GNUNET_TRANSPORT_UpdateSessionTimeout GNUNET_TRANSPORT_PluginFunctions::update_session_timeout |
Function that will be called whenever the transport service wants to notify the plugin that a session is still active and in use and therefore the session timeout for this session has to be updated.
Definition at line 659 of file gnunet_transport_plugin.h.
Referenced by GST_neighbours_calculate_receive_delay(), GST_plugins_load(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_UpdateInboundDelay GNUNET_TRANSPORT_PluginFunctions::update_inbound_delay |
Function that will be called whenever the transport service wants to notify the plugin that the inbound quota changed and that the plugin should update it's delay for the next receive value.
Definition at line 666 of file gnunet_transport_plugin.h.
Referenced by inbound_bw_tracker_update(), libgnunet_plugin_transport_http_client_init(), and libgnunet_plugin_transport_tcp_init().
GNUNET_TRANSPORT_QueryKeepaliveFactorFunction GNUNET_TRANSPORT_PluginFunctions::query_keepalive_factor |
Function that is used to query keepalive factor.
GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT is divided by this number to calculate the interval between keepalive packets.
Definition at line 673 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_AddressPrettyPrinter GNUNET_TRANSPORT_PluginFunctions::address_pretty_printer |
Function to pretty-print addresses.
Definition at line 678 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), handle_client_address_to_string(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_CheckAddress GNUNET_TRANSPORT_PluginFunctions::check_address |
Function that will be called to check if a binary address for this plugin is well-formed and corresponds to an address for THIS peer (as per our configuration).
Naturally, if absolutely necessary, plugins can be a bit conservative in their answer, but in general plugins should make sure that the address does not redirect traffic to a 3rd party that might try to man-in-the-middle our traffic.
Definition at line 689 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), GST_validation_handle_ping(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_AddressToString GNUNET_TRANSPORT_PluginFunctions::address_to_string |
Function that will be called to convert a binary address to a string (numeric conversion only).
Definition at line 695 of file gnunet_transport_plugin.h.
Referenced by add_address_to_uri(), add_valid_address(), GST_plugins_a2s(), GST_plugins_load(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_StringToAddress GNUNET_TRANSPORT_PluginFunctions::string_to_address |
Function that will be called to convert a string address to binary (numeric conversion only).
Definition at line 701 of file gnunet_transport_plugin.h.
Referenced by add_address_to_hello(), GST_plugins_load(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_CreateSession GNUNET_TRANSPORT_PluginFunctions::get_session |
Function that will be called tell the plugin to create a session object.
Definition at line 707 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), GST_validation_handle_ping(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), libgnunet_plugin_transport_udp_init(), multicast_pong(), send_syn_ack_message(), send_with_session(), switch_address_bl_check_cont(), and transmit_ping_if_allowed().
GNUNET_TRANSPORT_GetNetworkType GNUNET_TRANSPORT_PluginFunctions::get_network |
Function to obtain the network type for a session.
Definition at line 712 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_load(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), libgnunet_plugin_transport_udp_init(), and transmit_ping_if_allowed().
GNUNET_TRANSPORT_GetNetworkTypeForAddress GNUNET_TRANSPORT_PluginFunctions::get_network_for_address |
Function to obtain the network type for an address.
Definition at line 717 of file gnunet_transport_plugin.h.
Referenced by add_valid_address(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().
GNUNET_TRANSPORT_SessionMonitorSetup GNUNET_TRANSPORT_PluginFunctions::setup_monitor |
Function to monitor the sessions managed by the plugin.
Definition at line 722 of file gnunet_transport_plugin.h.
Referenced by GST_plugins_monitor_subscribe(), libgnunet_plugin_transport_http_client_init(), libgnunet_plugin_transport_tcp_init(), and libgnunet_plugin_transport_udp_init().