code for maintaining the overlay topology More...
#include "platform.h"
#include "gnunet_util_lib.h"
#include "gnunet_friends_lib.h"
#include "gnunet_constants.h"
#include "gnunet_core_service.h"
#include "gnunet_protocols.h"
#include "gnunet_peerinfo_service.h"
#include "gnunet_statistics_service.h"
#include "gnunet_transport_service.h"
#include "gnunet_ats_service.h"
Go to the source code of this file.
Data Structures | |
struct | Peer |
A peer. More... | |
struct | FindAdvHelloContext |
Closure for find_advertisable_hello(). More... | |
Macros | |
#define | HELLO_ADVERTISEMENT_MIN_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5) |
At what frequency do we sent HELLOs to a peer? More... | |
#define | HELLO_ADVERTISEMENT_MIN_REPEAT_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4) |
After what time period do we expire the HELLO Bloom filter? More... | |
Functions | |
static int | blacklist_check (void *cls, const struct GNUNET_PeerIdentity *pid) |
Function that decides if a connection is acceptable or not. More... | |
static void | whitelist_peers () |
Whitelist all peers that we blacklisted; we've passed the minimum number of friends. More... | |
static int | free_peer (void *cls, const struct GNUNET_PeerIdentity *pid, void *value) |
Free all resources associated with the given peer. More... | |
static void | attempt_connect (struct Peer *pos) |
Recalculate how much we want to be connected to the specified peer and let ATS know about the result. More... | |
static struct Peer * | make_peer (const struct GNUNET_PeerIdentity *peer, const struct GNUNET_HELLO_Message *hello, int is_friend) |
Create a new entry in the peer list. More... | |
static void | setup_filter (struct Peer *peer) |
Setup bloom filter for the given peer entry. More... | |
static int | find_advertisable_hello (void *cls, const struct GNUNET_PeerIdentity *pid, void *value) |
Find a peer that would be reasonable for advertising. More... | |
static void | schedule_next_hello (void *cls) |
Calculate when we would like to send the next HELLO to this peer and ask for it. More... | |
static int | reschedule_hellos (void *cls, const struct GNUNET_PeerIdentity *pid, void *value) |
Cancel existing requests for sending HELLOs to this peer and recalculate when we should send HELLOs to it based on our current state (something changed!). More... | |
static void * | connect_notify (void *cls, const struct GNUNET_PeerIdentity *peer, struct GNUNET_MQ_Handle *mq) |
Method called whenever a peer connects. More... | |
static int | try_add_peers (void *cls, const struct GNUNET_PeerIdentity *pid, void *value) |
Try to add more peers to our connection set. More... | |
static void | add_peer_task (void *cls) |
Add peers and schedule connection attempt. More... | |
static void | disconnect_notify (void *cls, const struct GNUNET_PeerIdentity *peer, void *internal_cls) |
Method called whenever a peer disconnects. More... | |
static int | address_iterator (void *cls, const struct GNUNET_HELLO_Address *address, struct GNUNET_TIME_Absolute expiration) |
Iterator called on each address. More... | |
static void | consider_for_advertising (const struct GNUNET_HELLO_Message *hello) |
We've gotten a HELLO from another peer. More... | |
static void | process_peer (void *cls, const struct GNUNET_PeerIdentity *peer, const struct GNUNET_HELLO_Message *hello, const char *err_msg) |
PEERINFO calls this function to let us know about a possible peer that we might want to connect to. More... | |
static void | core_init (void *cls, const struct GNUNET_PeerIdentity *my_id) |
Function called after GNUNET_CORE_connect has succeeded (or failed for good). More... | |
static void | handle_friend (void *cls, const struct GNUNET_PeerIdentity *pid) |
Process friend found in FRIENDS file. More... | |
static void | read_friends_file (const struct GNUNET_CONFIGURATION_Handle *cfg) |
Read the friends file. More... | |
static int | check_hello (void *cls, const struct GNUNET_HELLO_Message *message) |
This function is called whenever an encrypted HELLO message is received. More... | |
static void | handle_hello (void *cls, const struct GNUNET_HELLO_Message *message) |
This function is called whenever an encrypted HELLO message is received. More... | |
static void | cleaning_task (void *cls) |
Last task run during shutdown. More... | |
static void | run (void *cls, char *const *args, const char *cfgfile, const struct GNUNET_CONFIGURATION_Handle *c) |
Main function that will be run. More... | |
int | main (int argc, char *const *argv) |
The main function for the topology daemon. More... | |
Variables | |
static struct GNUNET_PEERINFO_NotifyContext * | peerinfo_notify |
Our peerinfo notification context. More... | |
static const struct GNUNET_CONFIGURATION_Handle * | cfg |
Our configuration. More... | |
static struct GNUNET_CORE_Handle * | handle |
Handle to the CORE service. More... | |
static struct GNUNET_PEERINFO_Handle * | pi |
Handle to the PEERINFO service. More... | |
static struct GNUNET_ATS_ConnectivityHandle * | ats |
Handle to the ATS service. More... | |
static struct GNUNET_PeerIdentity | my_identity |
Identity of this peer. More... | |
static struct GNUNET_CONTAINER_MultiPeerMap * | peers |
All of our friends, all of our current neighbours and all peers for which we have HELLOs. More... | |
static struct GNUNET_STATISTICS_Handle * | stats |
Handle for reporting statistics. More... | |
static struct GNUNET_TRANSPORT_Blacklist * | blacklist |
Blacklist (NULL if we have none). More... | |
static struct GNUNET_SCHEDULER_Task * | add_task |
Task scheduled to asynchronously reconsider adding/removing peer connectivity suggestions. More... | |
static struct GNUNET_TRANSPORT_OfferHelloHandle * | oh |
Active HELLO offering to transport service. More... | |
static int | friends_only |
Flag to disallow non-friend connections (pure F2F mode). More... | |
static unsigned int | minimum_friend_count |
Minimum number of friends to have in the connection set before we allow non-friends. More... | |
static unsigned int | connection_count |
Number of peers (friends and others) that we are currently connected to. More... | |
static unsigned int | target_connection_count |
Target number of connections. More... | |
static unsigned int | friend_count |
Number of friends that we are currently connected to. More... | |
code for maintaining the overlay topology
This daemon combines three functions:
All three require similar information (who are our friends impacts connectivity suggestions; connectivity suggestions should consider blacklisting; connectivity suggestions should consider available/known HELLOs; gossip requires connectivity data; connectivity suggestions require connectivity data), which is why they are combined in this program.
Definition in file gnunet-daemon-topology.c.
#define HELLO_ADVERTISEMENT_MIN_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5) |
At what frequency do we sent HELLOs to a peer?
Definition at line 54 of file gnunet-daemon-topology.c.
#define HELLO_ADVERTISEMENT_MIN_REPEAT_FREQUENCY GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 4) |
After what time period do we expire the HELLO Bloom filter?
Definition at line 60 of file gnunet-daemon-topology.c.
|
static |
Function that decides if a connection is acceptable or not.
If we have a blacklist, only friends are allowed, so the check is rather simple.
cls | closure |
pid | peer to approve or disapprove |
Definition at line 220 of file gnunet-daemon-topology.c.
References gettext_noop, GNUNET_CONTAINER_multipeermap_get(), GNUNET_NO, GNUNET_OK, GNUNET_STATISTICS_update(), GNUNET_SYSERR, GNUNET_YES, Peer::is_friend, peers, pid, and stats.
Referenced by disconnect_notify(), and run().
|
static |
Whitelist all peers that we blacklisted; we've passed the minimum number of friends.
Definition at line 240 of file gnunet-daemon-topology.c.
References blacklist, and GNUNET_TRANSPORT_blacklist_cancel().
Referenced by cleaning_task(), and connect_notify().
|
static |
Free all resources associated with the given peer.
cls | closure (not used) |
pid | identity of the peer |
value | peer to free |
Definition at line 259 of file gnunet-daemon-topology.c.
References Peer::filter, GNUNET_ATS_connectivity_suggest_cancel(), GNUNET_break, GNUNET_CONTAINER_bloomfilter_free(), GNUNET_CONTAINER_multipeermap_remove(), GNUNET_free, GNUNET_OK, GNUNET_SCHEDULER_cancel(), GNUNET_YES, Peer::hello, Peer::hello_delay_task, Peer::mq, peers, pid, Peer::sh, and value.
Referenced by cleaning_task(), and process_peer().
|
static |
Recalculate how much we want to be connected to the specified peer and let ATS know about the result.
pos | peer to consider connecting to |
Definition at line 298 of file gnunet-daemon-topology.c.
References ats, connection_count, friend_count, friends_only, gettext_noop, GNUNET_ATS_connectivity_suggest(), GNUNET_ATS_connectivity_suggest_cancel(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_i2s(), GNUNET_log, GNUNET_memcmp, GNUNET_NO, GNUNET_STATISTICS_update(), GNUNET_YES, Peer::is_friend, minimum_friend_count, Peer::mq, my_identity, Peer::pid, Peer::sh, stats, Peer::strength, and target_connection_count.
Referenced by process_peer(), and try_add_peers().
|
static |
Create a new entry in the peer list.
peer | identity of the new entry |
hello | hello message, can be NULL |
is_friend | is the new entry for a friend? |
Definition at line 351 of file gnunet-daemon-topology.c.
References GNUNET_break, GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY, GNUNET_CONTAINER_multipeermap_put(), GNUNET_HELLO_size(), GNUNET_malloc, GNUNET_memcpy, GNUNET_new, GNUNET_OK, Peer::hello, Peer::is_friend, peer, peers, and ret.
Referenced by connect_notify(), consider_for_advertising(), handle_friend(), and process_peer().
|
static |
Setup bloom filter for the given peer entry.
peer | entry to initialize |
Definition at line 381 of file gnunet-daemon-topology.c.
References GNUNET_CONTAINER_bloomfilter_add(), GNUNET_CONTAINER_bloomfilter_init(), GNUNET_CRYPTO_hash(), GNUNET_TIME_relative_to_absolute(), HELLO_ADVERTISEMENT_MIN_REPEAT_FREQUENCY, and peer.
Referenced by consider_for_advertising(), and find_advertisable_hello().
|
static |
Find a peer that would be reasonable for advertising.
cls | closure |
pid | identity of a peer |
value | 'struct Peer*' for the peer we are considering |
Definition at line 433 of file gnunet-daemon-topology.c.
References Peer::filter, Peer::filter_expiration, GNUNET_CONTAINER_bloomfilter_free(), GNUNET_CONTAINER_bloomfilter_test(), GNUNET_CRYPTO_hash(), GNUNET_HELLO_size(), GNUNET_NO, GNUNET_TIME_absolute_get_remaining(), GNUNET_TIME_relative_min(), GNUNET_YES, Peer::hello, FindAdvHelloContext::max_size, FindAdvHelloContext::next_adv, FindAdvHelloContext::peer, Peer::pid, GNUNET_TIME_Relative::rel_value_us, FindAdvHelloContext::result, setup_filter(), and value.
Referenced by schedule_next_hello().
|
static |
Calculate when we would like to send the next HELLO to this peer and ask for it.
cls | for which peer to schedule the HELLO |
Definition at line 474 of file gnunet-daemon-topology.c.
References delay, env, Peer::filter, find_advertisable_hello(), gettext_noop, GNUNET_assert, GNUNET_CONTAINER_bloomfilter_add(), GNUNET_CONTAINER_multipeermap_iterate(), GNUNET_CRYPTO_hash(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_HELLO_size(), GNUNET_log, GNUNET_MAX_MESSAGE_SIZE, GNUNET_MQ_msg_copy(), GNUNET_MQ_send(), GNUNET_NO, GNUNET_SCHEDULER_add_delayed(), GNUNET_SCHEDULER_add_now(), GNUNET_SCHEDULER_cancel(), GNUNET_STATISTICS_update(), GNUNET_TIME_absolute_get_remaining(), GNUNET_TIME_relative_to_absolute(), GNUNET_TIME_UNIT_FOREVER_REL, GNUNET_HELLO_Message::header, Peer::hello, HELLO_ADVERTISEMENT_MIN_FREQUENCY, Peer::hello_delay_task, FindAdvHelloContext::max_size, Peer::mq, FindAdvHelloContext::next_adv, Peer::next_hello_allowed, FindAdvHelloContext::peer, peers, Peer::pid, GNUNET_TIME_Relative::rel_value_us, FindAdvHelloContext::result, and stats.
Referenced by reschedule_hellos().
|
static |
Cancel existing requests for sending HELLOs to this peer and recalculate when we should send HELLOs to it based on our current state (something changed!).
cls | closure struct Peer to skip, or NULL |
pid | identity of a peer |
value | struct Peer * for the peer |
Definition at line 534 of file gnunet-daemon-topology.c.
References GNUNET_SCHEDULER_add_now(), GNUNET_SCHEDULER_cancel(), GNUNET_YES, peer, schedule_next_hello(), and value.
Referenced by connect_notify(), and consider_for_advertising().
|
static |
Method called whenever a peer connects.
cls | closure |
peer | peer identity this notification is about |
mq | message queue for communicating with peer |
struct Peer
for peer Definition at line 565 of file gnunet-daemon-topology.c.
References connection_count, friend_count, friends_only, gettext_noop, GNUNET_assert, GNUNET_CONTAINER_multipeermap_get(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_i2s(), GNUNET_log, GNUNET_memcmp, GNUNET_MQ_PRIO_BEST_EFFORT, GNUNET_MQ_set_options(), GNUNET_NO, GNUNET_STATISTICS_set(), GNUNET_YES, Peer::is_friend, make_peer(), minimum_friend_count, mq, Peer::mq, my_identity, peer, peers, reschedule_hellos(), stats, and whitelist_peers().
Referenced by reconnect(), and run().
|
static |
Try to add more peers to our connection set.
cls | closure, not used |
pid | identity of a peer |
value | struct Peer * for the peer |
Definition at line 616 of file gnunet-daemon-topology.c.
References attempt_connect(), GNUNET_YES, and value.
Referenced by add_peer_task().
|
static |
Add peers and schedule connection attempt.
cls | unused, NULL |
Definition at line 631 of file gnunet-daemon-topology.c.
References add_task, GNUNET_CONTAINER_multipeermap_iterate(), peers, and try_add_peers().
Referenced by disconnect_notify().
|
static |
Method called whenever a peer disconnects.
cls | closure |
peer | peer identity this notification is about |
internal_cls | the struct Peer for this peer |
Definition at line 647 of file gnunet-daemon-topology.c.
References add_peer_task(), add_task, blacklist, blacklist_check(), cfg, connection_count, friend_count, gettext_noop, GNUNET_break, GNUNET_ERROR_TYPE_DEBUG, GNUNET_i2s(), GNUNET_log, GNUNET_NO, GNUNET_SCHEDULER_add_now(), GNUNET_SCHEDULER_cancel(), GNUNET_STATISTICS_set(), GNUNET_TRANSPORT_blacklist(), Peer::hello_delay_task, Peer::is_friend, minimum_friend_count, Peer::mq, peer, stats, and target_connection_count.
Referenced by reconnect(), and run().
|
static |
Iterator called on each address.
cls | flag that we will set if we see any addresses |
address | the address of the peer |
expiration | when will the given address expire |
Definition at line 700 of file gnunet-daemon-topology.c.
References GNUNET_SYSERR, and GNUNET_YES.
Referenced by consider_for_advertising().
|
static |
We've gotten a HELLO from another peer.
Consider it for advertising.
hello | the HELLO we got |
Definition at line 718 of file gnunet-daemon-topology.c.
References GNUNET_TIME_Absolute::abs_value_us, address_iterator(), GNUNET_break, GNUNET_CONTAINER_bloomfilter_free(), GNUNET_CONTAINER_multipeermap_get(), GNUNET_CONTAINER_multipeermap_iterate(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_free, GNUNET_HELLO_equals(), GNUNET_HELLO_get_id(), GNUNET_HELLO_iterate_addresses(), GNUNET_HELLO_merge(), GNUNET_HELLO_size(), GNUNET_i2s(), GNUNET_log, GNUNET_malloc, GNUNET_memcmp, GNUNET_memcpy, GNUNET_NO, GNUNET_OK, GNUNET_TIME_absolute_get(), GNUNET_TIME_UNIT_FOREVER_ABS, Peer::hello, make_peer(), my_identity, nh, peer, peers, pid, reschedule_hellos(), setup_filter(), and size.
Referenced by process_peer().
|
static |
PEERINFO calls this function to let us know about a possible peer that we might want to connect to.
cls | closure (not used) |
peer | potential peer to connect to |
hello | HELLO for this peer (or NULL) |
err_msg | NULL if successful, otherwise contains error message |
Definition at line 789 of file gnunet-daemon-topology.c.
References _, attempt_connect(), cfg, consider_for_advertising(), Peer::filter, free_peer(), GNUNET_assert, GNUNET_CONTAINER_bloomfilter_free(), GNUNET_CONTAINER_multipeermap_get(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_free, GNUNET_log, GNUNET_memcmp, GNUNET_NO, GNUNET_PEERINFO_notify(), GNUNET_PEERINFO_notify_cancel(), Peer::hello, Peer::is_friend, make_peer(), Peer::mq, my_identity, peer, peerinfo_notify, peers, and Peer::pid.
Referenced by core_init().
|
static |
Function called after GNUNET_CORE_connect has succeeded (or failed for good).
cls | closure |
my_id | ID of this peer, NULL if we failed |
Definition at line 843 of file gnunet-daemon-topology.c.
References _, cfg, GNUNET_ERROR_TYPE_DEBUG, GNUNET_ERROR_TYPE_ERROR, GNUNET_i2s(), GNUNET_log, GNUNET_NO, GNUNET_PEERINFO_notify(), GNUNET_SCHEDULER_shutdown(), my_identity, peerinfo_notify, and process_peer().
Referenced by run().
|
static |
Process friend found in FRIENDS file.
cls | pointer to an unsigned int to be incremented per friend found |
pid | identity of the friend |
Definition at line 867 of file gnunet-daemon-topology.c.
References _, GNUNET_ERROR_TYPE_INFO, GNUNET_ERROR_TYPE_WARNING, GNUNET_i2s(), GNUNET_log, GNUNET_memcmp, GNUNET_YES, make_peer(), my_identity, Peer::pid, and pid.
Referenced by read_friends_file().
|
static |
Read the friends file.
Definition at line 891 of file gnunet-daemon-topology.c.
References _, cfg, friends_only, gettext_noop, GNUNET_ERROR_TYPE_WARNING, GNUNET_FRIENDS_parse(), GNUNET_log, GNUNET_NO, GNUNET_OK, GNUNET_STATISTICS_update(), GNUNET_YES, handle_friend(), minimum_friend_count, stats, and target_connection_count.
Referenced by run().
|
static |
This function is called whenever an encrypted HELLO message is received.
cls | closure with the peer identity of the sender |
message | the actual HELLO message |
Definition at line 934 of file gnunet-daemon-topology.c.
References GNUNET_break_op, GNUNET_HELLO_get_id(), GNUNET_OK, GNUNET_SYSERR, and pid.
|
static |
This function is called whenever an encrypted HELLO message is received.
cls | closure with the peer identity of the sender |
message | the actual HELLO message |
Definition at line 955 of file gnunet-daemon-topology.c.
References friend_count, friends_only, gettext_noop, GNUNET_assert, GNUNET_CONTAINER_multipeermap_get(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_HELLO_get_id(), GNUNET_i2s(), GNUNET_log, GNUNET_NO, GNUNET_OK, GNUNET_PEERINFO_add_peer(), GNUNET_STATISTICS_update(), GNUNET_YES, minimum_friend_count, peer, peers, pi, pid, and stats.
|
static |
Last task run during shutdown.
Disconnects us from the transport and core.
cls | unused, NULL |
Definition at line 994 of file gnunet-daemon-topology.c.
References add_task, ats, free_peer(), GNUNET_ATS_connectivity_done(), GNUNET_CONTAINER_multipeermap_destroy(), GNUNET_CONTAINER_multipeermap_iterate(), GNUNET_CORE_disconnect(), GNUNET_NO, GNUNET_PEERINFO_disconnect(), GNUNET_PEERINFO_notify_cancel(), GNUNET_SCHEDULER_cancel(), GNUNET_STATISTICS_destroy(), GNUNET_TRANSPORT_offer_hello_cancel(), handle, oh, peerinfo_notify, peers, pi, stats, and whitelist_peers().
Referenced by run().
|
static |
Main function that will be run.
cls | closure |
args | remaining command-line arguments |
cfgfile | name of the configuration file used (for saving, can be NULL!) |
c | configuration |
Definition at line 1047 of file gnunet-daemon-topology.c.
References _, ats, blacklist, blacklist_check(), cfg, cleaning_task(), connect_notify(), core_init(), disconnect_notify(), friends_only, GNUNET_ATS_connectivity_init(), GNUNET_CONFIGURATION_get_value_number(), GNUNET_CONFIGURATION_get_value_yesno(), GNUNET_CONTAINER_multipeermap_create(), GNUNET_CORE_connect(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_ERROR_TYPE_ERROR, GNUNET_log, GNUNET_MESSAGE_TYPE_HELLO, GNUNET_MQ_handler_end, GNUNET_MQ_hd_var_size, GNUNET_NO, GNUNET_OK, GNUNET_PEERINFO_connect(), GNUNET_SCHEDULER_add_shutdown(), GNUNET_SCHEDULER_shutdown(), GNUNET_STATISTICS_create(), GNUNET_TRANSPORT_blacklist(), GNUNET_YES, handle, handlers, consensus-simulation::int, minimum_friend_count, peers, pi, read_friends_file(), stats, and target_connection_count.
int main | ( | int | argc, |
char *const * | argv | ||
) |
The main function for the topology daemon.
argc | number of arguments from the command line |
argv | command line arguments |
Definition at line 1114 of file gnunet-daemon-topology.c.
|
static |
Our peerinfo notification context.
We use notification to instantly learn about new peers as they are discovered.
Definition at line 128 of file gnunet-daemon-topology.c.
Referenced by cleaning_task(), core_init(), and process_peer().
|
static |
Our configuration.
Definition at line 133 of file gnunet-daemon-topology.c.
Referenced by core_init(), disconnect_notify(), process_peer(), read_friends_file(), and run().
|
static |
Handle to the CORE service.
Definition at line 138 of file gnunet-daemon-topology.c.
Referenced by cleaning_task(), and run().
|
static |
Handle to the PEERINFO service.
Definition at line 143 of file gnunet-daemon-topology.c.
Referenced by cleaning_task(), handle_hello(), and run().
|
static |
Handle to the ATS service.
Definition at line 148 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), cleaning_task(), and run().
|
static |
Identity of this peer.
Definition at line 148 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), connect_notify(), consider_for_advertising(), core_init(), handle_friend(), and process_peer().
|
static |
All of our friends, all of our current neighbours and all peers for which we have HELLOs.
So pretty much everyone. Maps peer identities to struct Peer *
values.
Definition at line 160 of file gnunet-daemon-topology.c.
Referenced by add_peer_task(), blacklist_check(), cleaning_task(), connect_notify(), consider_for_advertising(), free_peer(), handle_hello(), make_peer(), process_peer(), run(), and schedule_next_hello().
|
static |
Handle for reporting statistics.
Definition at line 165 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), blacklist_check(), cleaning_task(), connect_notify(), disconnect_notify(), handle_hello(), read_friends_file(), run(), and schedule_next_hello().
|
static |
Blacklist (NULL if we have none).
Definition at line 170 of file gnunet-daemon-topology.c.
Referenced by disconnect_notify(), run(), and whitelist_peers().
|
static |
Task scheduled to asynchronously reconsider adding/removing peer connectivity suggestions.
Definition at line 176 of file gnunet-daemon-topology.c.
Referenced by add_peer_task(), cleaning_task(), and disconnect_notify().
|
static |
Active HELLO offering to transport service.
Definition at line 181 of file gnunet-daemon-topology.c.
Referenced by cleaning_task(), GNUNET_SET_accept(), GNUNET_SET_commit(), GNUNET_SET_operation_cancel(), GNUNET_SET_prepare(), GNUNET_SETI_accept(), GNUNET_SETI_commit(), GNUNET_SETI_operation_cancel(), GNUNET_SETI_prepare(), GNUNET_SETU_accept(), GNUNET_SETU_commit(), GNUNET_SETU_operation_cancel(), GNUNET_SETU_prepare(), handle_result(), and set_operation_destroy().
|
static |
Flag to disallow non-friend connections (pure F2F mode).
Definition at line 186 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), connect_notify(), handle_hello(), read_friends_file(), and run().
|
static |
Minimum number of friends to have in the connection set before we allow non-friends.
Definition at line 192 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), connect_notify(), disconnect_notify(), handle_hello(), read_friends_file(), and run().
|
static |
Number of peers (friends and others) that we are currently connected to.
Definition at line 197 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), connect_notify(), and disconnect_notify().
|
static |
Target number of connections.
Definition at line 202 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), disconnect_notify(), read_friends_file(), and run().
|
static |
Number of friends that we are currently connected to.
Definition at line 207 of file gnunet-daemon-topology.c.
Referenced by attempt_connect(), connect_notify(), disconnect_notify(), and handle_hello().