33 #define DEBUG_TRANSPORT GNUNET_EXTRA_LOGGING
40 #define MAX_BANDWIDTH_CARRY_S GNUNET_CONSTANTS_MAX_BANDWIDTH_CARRY_S
46 #define MIN_QUOTA_REFRESH_TIME 2000
52 #define DEFAULT_MAX_FDS 256
57 #define LATENCY_EVALUATION_MAX_DELAY \
58 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 1)
63 #define CONNECTED_LATENCY_EVALUATION_MAX_DELAY \
64 GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 1)
124 #if (defined(GNUNET_TRANSPORT_COMMUNICATION_VERSION) || \
125 defined(GNUNET_TRANSPORT_CORE_VERSION))
223 #if (defined(GNUNET_TRANSPORT_COMMUNICATION_VERSION) || \
224 defined(GNUNET_TRANSPORT_CORE_VERSION))
296 #if ! (defined(GNUNET_TRANSPORT_COMMUNICATION_VERSION) || \
297 defined(GNUNET_TRANSPORT_CORE_VERSION))
312 #if ! (defined(GNUNET_TRANSPORT_COMMUNICATION_VERSION) || \
313 defined(GNUNET_TRANSPORT_CORE_VERSION))
683 struct GNUNET_TRANSPORT_CommunicatorAvailableMessage
702 struct GNUNET_TRANSPORT_AddAddressMessage
731 struct GNUNET_TRANSPORT_DelAddressMessage
748 struct GNUNET_TRANSPORT_IncomingMessage
789 struct GNUNET_TRANSPORT_IncomingMessageAck
816 struct GNUNET_TRANSPORT_AddQueueMessage
866 struct GNUNET_TRANSPORT_UpdateQueueMessage
914 struct GNUNET_TRANSPORT_DelQueueMessage
936 struct GNUNET_TRANSPORT_CreateQueue
960 struct GNUNET_TRANSPORT_CreateQueueResponse
978 struct GNUNET_TRANSPORT_SendMessageTo
1007 struct GNUNET_TRANSPORT_SendMessageToAck
1041 struct GNUNET_TRANSPORT_CommunicatorBackchannel
1070 struct GNUNET_TRANSPORT_CommunicatorBackchannelIncoming
1096 struct GNUNET_TRANSPORT_MonitorStart
1118 struct GNUNET_TRANSPORT_MonitorData
1169 struct GNUNET_TRANSPORT_AddressToVerify
1194 struct ExpressPreferenceMessage
1225 struct RequestHelloValidationMessage
static char * expiration
Credential TTL.
uint16_t status
See PRISM_STATUS_*-constants.
struct GNUNET_IDENTITY_PrivateKey pk
Private key from command line option, or NULL.
static struct GNUNET_NAT_AUTO_Test * nt
Handle to a NAT test operation.
static unsigned long long reserved
How much space have we currently reserved?
struct GNUNET_BIO_WriteHandle * bw
handle to the file to write the load statistics to
static struct GNUNET_PeerIdentity pid
Identity of the peer we transmit to / connect to.
Functions related to time.
#define GNUNET_NETWORK_STRUCT_BEGIN
Define as empty, GNUNET_PACKED should suffice, but this won't work on W32.
#define GNUNET_NETWORK_STRUCT_END
Define as empty, GNUNET_PACKED should suffice, but this won't work on W32;.
#define GNUNET_PACKED
gcc-ism to get packed structs.
void receiver(void *cls, const void *buf, size_t available, const struct sockaddr *addr, socklen_t addrlen, int errCode)
Callback to read from the SOCKS5 proxy.
Message from the library to the transport service asking for converting a transport address to a huma...
uint16_t addrlen
Length of the (binary) address in bytes, in big-endian.
int16_t numeric_only
Should the conversion use numeric IP addresses (otherwise a reverse DNS lookup is OK – if applicable)...
struct GNUNET_TIME_RelativeNBO timeout
timeout to give up (for DNS resolution timeout mostly)
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_TO_STRING.
Message used to notify the transport API about an address to string conversion.
uint32_t addr_len
Length of the following string, zero if is GNUNET_SYSERR.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_TO_STRING_REPLY.
uint32_t res
GNUNET_OK if the conversion succeeded, GNUNET_SYSERR if it failed
Change in blacklisting (either request or notification, depending on which direction it is going).
uint32_t is_allowed
0 for the query, GNUNET_OK (allowed) or GNUNET_SYSERR (disallowed) for the response.
struct GNUNET_PeerIdentity peer
Which peer is being blacklisted or queried?
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_BLACKLIST_QUERY or GNUNET_MESSAGE_TYPE_TRANSPORT_BLACKLIST...
Message from the transport service to the library informing about neighbors.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_CONNECT.
struct GNUNET_PeerIdentity id
Identity of the new neighbour.
struct GNUNET_BANDWIDTH_Value32NBO quota_out
Current outbound quota for this peer.
Message from the transport service to the library informing about disconnects.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_DISCONNECT.
uint32_t reserved
Reserved, always zero.
struct GNUNET_PeerIdentity peer
Who got disconnected?
ATS performance characteristics for an address in network byte order (for IPC).
32-bit bandwidth used for network exchange by GNUnet, in bytes per second.
The identity of the host (wraps the signing key of the peer).
Time for absolute time used by GNUnet, in microseconds and in network byte order.
Time for relative time used by GNUnet, in microseconds and in network byte order.
Message used to notify the transport API about a message received from the network.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_RECV.
struct GNUNET_PeerIdentity peer
Which peer sent the message?
Message used to notify the transport service about a message to be transmitted to another peer.
uint32_t priority
An enum GNUNET_MQ_PriorityPreferences in NBO.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_SEND.
struct GNUNET_PeerIdentity peer
Which peer should receive the message?
struct GNUNET_TIME_RelativeNBO timeout
Allowed delay.
Message from the transport service to the library containing information about a peer.
uint32_t pluginlen
Length of the plugin name.
struct GNUNET_TIME_AbsoluteNBO state_timeout
Timeout for the state this peer is in.
struct GNUNET_MessageHeader header
Type is GNUNET_MESSAGE_TYPE_TRANSPORT_MONITOR_PEER_RESPONSE.
struct GNUNET_PeerIdentity peer
Peer identity.
uint32_t local_address_info
Local info about the address.
uint32_t reserved
For alignment.
uint32_t state
State this peer is in as an enum GNUNET_TRANSPORT_PeerState
uint32_t addrlen
Address length.
Message from the library to the transport service asking for binary addresses known for a peer.
struct GNUNET_PeerIdentity peer
The identity of the peer to look up.
uint32_t one_shot
One shot call or continuous replies?
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_MONITOR_PEER_REQUEST.
Message used to set a particular bandwidth quota.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_SET_QUOTA.
struct GNUNET_BANDWIDTH_Value32NBO quota
Quota.
struct GNUNET_PeerIdentity peer
About which peer are we talking here?
Message used to notify the transport API that it can send another message to the transport service.
struct GNUNET_PeerIdentity peer
Which peer can CORE handle more from now?
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_RECV_OK.
uint32_t increase_window_delta
Number of messages by which to increase the window, greater or equal to one.
Message used to notify the transport API that it can send another message to the transport service.
uint16_t success
GNUNET_OK if the transmission succeeded, GNUNET_SYSERR if it failed (i.e.
uint16_t bytes_msg
Size of message sent.
uint32_t bytes_physical
Size of message sent over wire.
struct GNUNET_PeerIdentity peer
Which peer can send more now?
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_SEND_OK.
Message from the transport service to the library asking to check if both processes agree about this ...
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_START.
uint32_t options
0: no options 1: The self field should be checked 2: this client is interested in payload traffic
struct GNUNET_PeerIdentity self
Identity we think we have.
Message from the library to the transport service asking for binary addresses known for a peer.
struct GNUNET_TIME_RelativeNBO delay_in
Fake delay to add on inbound traffic.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_TRAFFIC_METRIC.
struct GNUNET_TIME_RelativeNBO delay_out
Fake delay to add on outbound traffic.
struct GNUNET_ATS_PropertiesNBO properties
Fake properties to generate.
uint32_t reserved
Always zero.
struct GNUNET_PeerIdentity peer
The identity of the peer to look up.
Transport-level connection status update.
struct GNUNET_MessageHeader header
Type will be GNUNET_MESSAGE_TYPE_TRANSPORT_MONITOR_PLUGIN_EVENT.
struct GNUNET_TIME_AbsoluteNBO timeout
When will this transport plugin session time out?
uint16_t plugin_address_len
Length of the plugin address in bytes.
uint16_t plugin_name_len
Length of the plugin name in bytes, including 0-termination.
uint16_t session_state
An enum GNUNET_TRANSPORT_SessionState in NBO.
struct GNUNET_TIME_AbsoluteNBO delay
Until how long is this plugin currently blocked from reading?
uint32_t bytes_pending
Number of bytes waiting for transmission.
uint32_t msgs_pending
Number of messages waiting transmission.
uint64_t session_id
Unique identifier for the session.
struct GNUNET_PeerIdentity peer
Which peer is this connection for?
int16_t is_inbound
GNUNET_YES if this is an inbound connection, GNUNET_NO if this is an outbound connection,...
Message from the transport service to the library containing information about a peer.
uint32_t pluginlen
Length of the plugin name.
struct GNUNET_TIME_AbsoluteNBO last_validation
At what time did we successfully validate the address last.
struct GNUNET_MessageHeader header
Type is #GNUNET_MESSAGE_TYPE_TRANSPORT_MONITOR_VALIDATION_RESPONSE.
uint32_t addrlen
Address length.
uint32_t reserved
For alignment.
struct GNUNET_PeerIdentity peer
Peer identity.
struct GNUNET_TIME_AbsoluteNBO valid_until
Until when is the address believed to be valid.
uint32_t local_address_info
Local info about the address.
struct GNUNET_TIME_AbsoluteNBO next_validation
When will we next try to validate the address (typically done before valid_until happens).
Message from the library to the transport service asking for binary addresses known for a peer.
struct GNUNET_MessageHeader header
Type will be #GNUNET_MESSAGE_TYPE_TRANSPORT_MONITOR_VALIDATION_REQUEST.
struct GNUNET_PeerIdentity peer
The identity of the peer to look up.
uint32_t one_shot
One shot call or continuous replies?
struct GNUNET_TESTBED_Peer * peer
The peer associated with this model.
void(* NotifyConnect)(void *cls, const struct GNUNET_PeerIdentity *peer, struct GNUNET_BANDWIDTH_Value32NBO bandwidth_in, struct GNUNET_BANDWIDTH_Value32NBO bandwidth_out)
Similar to GNUNET_TRANSPORT_NotifyDisconnect but in and out quotas are included here.