maintains list of known peers More...
#include "platform.h"
#include "gnunet_util_lib.h"
#include "gnunet_hello_lib.h"
#include "gnunet_protocols.h"
#include "gnunet_statistics_service.h"
#include "peerinfo.h"
Go to the source code of this file.
Data Structures | |
struct | HostEntry |
In-memory cache of known hosts. More... | |
struct | ReadHostFileContext |
Result of reading a file. More... | |
struct | DirScanContext |
Closure for hosts_directory_scan_callback(). More... | |
struct | TransmitContext |
Closure for add_to_tc() More... | |
Macros | |
#define | DATA_HOST_FREQ GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 15) |
How often do we scan the HOST_DIR for new entries? More... | |
#define | DATA_HOST_CLEAN_FREQ GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 60) |
How often do we discard old entries in data/hosts/? More... | |
Functions | |
static struct InfoMessage * | make_info_message (const struct HostEntry *he, int include_friend_only) |
Notify all clients in the notify list about the given host entry changing. More... | |
static int | discard_expired (void *cls, const struct GNUNET_HELLO_Address *address, struct GNUNET_TIME_Absolute expiration) |
Address iterator that causes expired entries to be discarded. More... | |
static int | count_addresses (void *cls, const struct GNUNET_HELLO_Address *address, struct GNUNET_TIME_Absolute expiration) |
Address iterator that counts the remaining addresses. More... | |
static char * | get_host_filename (const struct GNUNET_PeerIdentity *id) |
Get the filename under which we would store the GNUNET_HELLO_Message for the given host and protocol. More... | |
static void | notify_all (struct HostEntry *entry) |
Broadcast information about the given entry to all clients that care. More... | |
static void | update_hello (const struct GNUNET_PeerIdentity *peer, const struct GNUNET_HELLO_Message *hello) |
Bind a host address (hello) to a hostId. More... | |
static void | read_host_file (const char *fn, int unlink_garbage, struct ReadHostFileContext *r) |
Try to read the HELLOs in the given filename and discard expired addresses. More... | |
static struct HostEntry * | add_host_to_known_hosts (const struct GNUNET_PeerIdentity *identity) |
Add a host to the list and notify clients about this event. More... | |
static void | remove_garbage (const char *fullname) |
Remove a file that should not be there. More... | |
static int | hosts_directory_scan_callback (void *cls, const char *fullname) |
Function that is called on each HELLO file in a particular directory. More... | |
static void | cron_scan_directory_data_hosts (void *cls) |
Call this method periodically to scan data/hosts for new hosts. More... | |
static struct GNUNET_HELLO_Message * | update_friend_hello (const struct GNUNET_HELLO_Message *hello, const struct GNUNET_HELLO_Message *friend_hello) |
Update the HELLO of a friend by merging the addresses. More... | |
static int | add_to_tc (void *cls, const struct GNUNET_PeerIdentity *key, void *value) |
Do transmit info about peer to given host. More... | |
static int | discard_hosts_helper (void *cls, const char *fn) |
delete expired HELLO entries in directory More... | |
static void | cron_clean_data_hosts (void *cls) |
Call this method periodically to scan peerinfo/ for ancient HELLOs to expire. More... | |
static int | check_hello (void *cls, const struct GNUNET_HELLO_Message *hello) |
Check HELLO-message. More... | |
static void | handle_hello (void *cls, const struct GNUNET_HELLO_Message *hello) |
Handle HELLO-message. More... | |
static void | handle_get (void *cls, const struct ListPeerMessage *lpm) |
Handle GET-message. More... | |
static void | handle_get_all (void *cls, const struct ListAllPeersMessage *lapm) |
Handle GET-ALL-message. More... | |
static void | handle_notify (void *cls, const struct NotifyMessage *nm) |
Handle NOTIFY-message. More... | |
static void * | client_connect_cb (void *cls, struct GNUNET_SERVICE_Client *client, struct GNUNET_MQ_Handle *mq) |
Client connect callback. More... | |
static void | client_disconnect_cb (void *cls, struct GNUNET_SERVICE_Client *client, void *app_ctx) |
Client disconnect callback. More... | |
static int | free_host_entry (void *cls, const struct GNUNET_PeerIdentity *key, void *value) |
Release memory taken by a host entry. More... | |
static void | shutdown_task (void *cls) |
Clean up our state. More... | |
static void | run (void *cls, const struct GNUNET_CONFIGURATION_Handle *cfg, struct GNUNET_SERVICE_Handle *service) |
Start up peerinfo service. More... | |
GNUNET_SERVICE_MAIN ("peerinfo", GNUNET_SERVICE_OPTION_NONE, &run, &client_connect_cb, &client_disconnect_cb, NULL, GNUNET_MQ_hd_var_size(hello, GNUNET_MESSAGE_TYPE_HELLO, struct GNUNET_HELLO_Message, NULL), GNUNET_MQ_hd_fixed_size(get, GNUNET_MESSAGE_TYPE_PEERINFO_GET, struct ListPeerMessage, NULL), GNUNET_MQ_hd_fixed_size(get_all, GNUNET_MESSAGE_TYPE_PEERINFO_GET_ALL, struct ListAllPeersMessage, NULL), GNUNET_MQ_hd_fixed_size(notify, GNUNET_MESSAGE_TYPE_PEERINFO_NOTIFY, struct NotifyMessage, NULL), GNUNET_MQ_handler_end()) | |
Define "main" method using service macro. More... | |
Variables | |
static struct GNUNET_CONTAINER_MultiPeerMap * | hostmap |
The in-memory list of known hosts, mapping of host IDs to 'struct HostEntry*' values. More... | |
static struct GNUNET_NotificationContext * | notify_list |
Clients to immediately notify about all changes. More... | |
static struct GNUNET_NotificationContext * | notify_friend_only_list |
Clients to immediately notify about all changes, even for friend-only HELLOs. More... | |
static char * | networkIdDirectory |
Directory where the hellos are stored in (peerinfo/) More... | |
static struct GNUNET_STATISTICS_Handle * | stats |
Handle for reporting statistics. More... | |
static struct GNUNET_SCHEDULER_Task * | cron_clean |
Handle for task to run cron_clean_data_hosts() More... | |
static struct GNUNET_SCHEDULER_Task * | cron_scan |
Handle for task to run cron_scan_directory_data_hosts() More... | |
maintains list of known peers
Code to maintain the list of currently known hosts (in memory structure of data/hosts/).
Definition in file gnunet-service-peerinfo.c.
#define DATA_HOST_FREQ GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 15) |
How often do we scan the HOST_DIR for new entries?
Definition at line 41 of file gnunet-service-peerinfo.c.
#define DATA_HOST_CLEAN_FREQ GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 60) |
How often do we discard old entries in data/hosts/?
Definition at line 47 of file gnunet-service-peerinfo.c.
|
static |
Notify all clients in the notify list about the given host entry changing.
he | entry of the host for which we generate a notification |
include_friend_only | create public of friend-only message |
Definition at line 137 of file gnunet-service-peerinfo.c.
References HostEntry::friend_only_hello, GNUNET_HELLO_size(), GNUNET_malloc, GNUNET_memcpy, GNUNET_MESSAGE_TYPE_PEERINFO_INFO, GNUNET_YES, InfoMessage::header, HostEntry::hello, HostEntry::identity, include_friend_only, InfoMessage::peer, GNUNET_MessageHeader::size, and GNUNET_MessageHeader::type.
Referenced by notify_all().
|
static |
Address iterator that causes expired entries to be discarded.
cls | pointer to the current time |
address | the address |
expiration | expiration time for the address |
Definition at line 166 of file gnunet-service-peerinfo.c.
References _, GNUNET_TIME_Absolute::abs_value_us, address, expiration, GNUNET_ERROR_TYPE_INFO, GNUNET_log, GNUNET_NO, and GNUNET_OK.
Referenced by discard_hosts_helper(), and read_host_file().
|
static |
Address iterator that counts the remaining addresses.
cls | pointer to the counter |
address | the address |
expiration | expiration time for the address |
Definition at line 192 of file gnunet-service-peerinfo.c.
References address, expiration, and GNUNET_OK.
Referenced by discard_hosts_helper(), distribute_bandwidth(), read_host_file(), and update_hello().
|
static |
Get the filename under which we would store the GNUNET_HELLO_Message for the given host and protocol.
id | peer for which we need the filename for the HELLO |
Definition at line 213 of file gnunet-service-peerinfo.c.
References DIR_SEPARATOR_STR, GNUNET_asprintf(), GNUNET_i2s_full(), and networkIdDirectory.
Referenced by add_host_to_known_hosts(), and update_hello().
|
static |
Broadcast information about the given entry to all clients that care.
entry | entry to broadcast about |
Definition at line 235 of file gnunet-service-peerinfo.c.
References GNUNET_ERROR_TYPE_DEBUG, GNUNET_free, GNUNET_i2s(), GNUNET_log, GNUNET_NO, GNUNET_notification_context_broadcast(), GNUNET_YES, InfoMessage::header, HostEntry::identity, make_info_message(), notify_friend_only_list, and notify_list.
Referenced by add_host_to_known_hosts(), and update_hello().
|
static |
Bind a host address (hello) to a hostId.
peer | the peer for which this is a hello |
hello | the verified (!) hello message |
Definition at line 683 of file gnunet-service-peerinfo.c.
References count_addresses(), delta, warningfilter::dest, HostEntry::friend_only_hello, get_host_filename(), GNUNET_assert, GNUNET_CONTAINER_multipeermap_get(), GNUNET_DISK_directory_create_for_file(), GNUNET_DISK_fn_write(), GNUNET_DISK_PERM_GROUP_READ, GNUNET_DISK_PERM_OTHER_READ, GNUNET_DISK_PERM_USER_READ, GNUNET_DISK_PERM_USER_WRITE, GNUNET_ERROR_TYPE_DEBUG, GNUNET_ERROR_TYPE_WARNING, GNUNET_free, GNUNET_HELLO_equals(), GNUNET_HELLO_is_friend_only(), GNUNET_HELLO_iterate_addresses(), GNUNET_HELLO_merge(), GNUNET_HELLO_size(), GNUNET_i2s(), GNUNET_log, GNUNET_log_strerror_file, GNUNET_malloc, GNUNET_memcpy, GNUNET_NO, GNUNET_OK, GNUNET_SYSERR, GNUNET_TIME_absolute_get(), GNUNET_TIME_UNIT_FOREVER_ABS, GNUNET_YES, HostEntry::hello, hostmap, notify_all(), peer, size, and update_friend_hello().
Referenced by add_host_to_known_hosts(), handle_hello(), and hosts_directory_scan_callback().
|
static |
Try to read the HELLOs in the given filename and discard expired addresses.
Removes the file if one the HELLO is malformed. If all addresses are expired, the HELLO is also removed (but the HELLO with the public key is still returned if it was found and valid). The file can contain multiple HELLO messages.
fn | name of the file |
unlink_garbage | if GNUNET_YES, try to remove useless files |
r | ReadHostFileContext to store the resutl |
Definition at line 279 of file gnunet-service-peerinfo.c.
References _, count_addresses(), discard_expired(), ReadHostFileContext::friend_only_hello, GNUNET_ALIGN, GNUNET_break, GNUNET_DISK_file_test(), GNUNET_DISK_fn_read(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_ERROR_TYPE_ERROR, GNUNET_ERROR_TYPE_WARNING, GNUNET_free, GNUNET_HELLO_is_friend_only(), GNUNET_HELLO_iterate_addresses(), GNUNET_HELLO_size(), GNUNET_log, GNUNET_log_strerror_file, GNUNET_MAX_MESSAGE_SIZE, GNUNET_NO, GNUNET_TIME_absolute_get(), GNUNET_YES, and ReadHostFileContext::hello.
Referenced by add_host_to_known_hosts(), and hosts_directory_scan_callback().
|
static |
Add a host to the list and notify clients about this event.
identity | the identity of the host |
Definition at line 413 of file gnunet-service-peerinfo.c.
References ReadHostFileContext::friend_only_hello, get_host_filename(), gettext_noop, GNUNET_assert, GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY, GNUNET_CONTAINER_multipeermap_get(), GNUNET_CONTAINER_multipeermap_put(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_free, GNUNET_i2s(), GNUNET_log, GNUNET_new, GNUNET_NO, GNUNET_OK, GNUNET_STATISTICS_update(), GNUNET_YES, ReadHostFileContext::hello, hostmap, identity, HostEntry::identity, notify_all(), read_host_file(), stats, and update_hello().
Referenced by handle_hello(), and hosts_directory_scan_callback().
|
static |
Remove a file that should not be there.
LOG success or failure.
fullname | name of the file to remove |
Definition at line 462 of file gnunet-service-peerinfo.c.
References _, GNUNET_ERROR_TYPE_BULK, GNUNET_ERROR_TYPE_ERROR, GNUNET_ERROR_TYPE_WARNING, GNUNET_log, GNUNET_log_strerror_file, and networkIdDirectory.
Referenced by hosts_directory_scan_callback().
|
static |
Function that is called on each HELLO file in a particular directory.
Try to parse the file and add the HELLO to our list.
cls | pointer to 'unsigned int' to increment for each file, or NULL if the file is from a read-only, read-once resource directory |
fullname | name of the file to parse |
Definition at line 508 of file gnunet-service-peerinfo.c.
References add_host_to_known_hosts(), DIR_SEPARATOR, filename, ReadHostFileContext::friend_only_hello, GNUNET_break, GNUNET_CRYPTO_eddsa_public_key_from_string(), GNUNET_DISK_file_test(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_free, GNUNET_HELLO_get_id(), GNUNET_i2s(), GNUNET_log, GNUNET_memcmp, GNUNET_OK, GNUNET_YES, ReadHostFileContext::hello, id, identity, DirScanContext::matched, read_host_file(), DirScanContext::remove_files, remove_garbage(), and update_hello().
Referenced by cron_scan_directory_data_hosts(), and run().
|
static |
Call this method periodically to scan data/hosts for new hosts.
cls | unused |
Definition at line 604 of file gnunet-service-peerinfo.c.
References _, cron_scan, DATA_HOST_FREQ, GNUNET_DISK_directory_create(), GNUNET_DISK_directory_scan(), GNUNET_ERROR_TYPE_BULK, GNUNET_ERROR_TYPE_INFO, GNUNET_ERROR_TYPE_WARNING, GNUNET_log, GNUNET_SCHEDULER_add_delayed_with_priority(), GNUNET_SCHEDULER_PRIORITY_IDLE, GNUNET_SYSERR, GNUNET_YES, hosts_directory_scan_callback(), DirScanContext::matched, networkIdDirectory, and DirScanContext::remove_files.
Referenced by run().
|
static |
Update the HELLO of a friend by merging the addresses.
hello | original hello |
friend_hello | hello with additional addresses |
Definition at line 649 of file gnunet-service-peerinfo.c.
References GNUNET_assert, GNUNET_break, GNUNET_free, GNUNET_HELLO_create(), GNUNET_HELLO_get_id(), GNUNET_HELLO_is_friend_only(), GNUNET_HELLO_merge(), GNUNET_OK, GNUNET_YES, pid, GNUNET_PeerIdentity::public_key, and res.
Referenced by update_hello().
|
static |
Do transmit info about peer to given host.
cls | NULL to hit all hosts, otherwise specifies a particular target |
key | hostID |
value | information to transmit |
Definition at line 860 of file gnunet-service-peerinfo.c.
References env, HostEntry::friend_only_hello, GNUNET_assert, GNUNET_ERROR_TYPE_DEBUG, GNUNET_HELLO_size(), GNUNET_i2s(), GNUNET_log, GNUNET_MAX_MESSAGE_SIZE, GNUNET_memcpy, GNUNET_MESSAGE_TYPE_PEERINFO_INFO, GNUNET_MQ_msg, GNUNET_MQ_msg_extra, GNUNET_MQ_send(), GNUNET_NO, GNUNET_SERVICE_client_get_mq(), GNUNET_YES, HostEntry::hello, HostEntry::identity, key, InfoMessage::peer, tc, and value.
Referenced by handle_get(), handle_get_all(), and handle_notify().
|
static |
delete expired HELLO entries in directory
cls | pointer to current time (struct GNUNET_TIME_Absolute * ) |
fn | filename to test to see if the HELLO expired |
Definition at line 915 of file gnunet-service-peerinfo.c.
References count_addresses(), discard_expired(), GNUNET_ALIGN, GNUNET_assert, GNUNET_DISK_directory_remove(), GNUNET_DISK_file_size(), GNUNET_DISK_fn_read(), GNUNET_DISK_fn_write(), GNUNET_DISK_PERM_GROUP_READ, GNUNET_DISK_PERM_OTHER_READ, GNUNET_DISK_PERM_USER_READ, GNUNET_DISK_PERM_USER_WRITE, GNUNET_ERROR_TYPE_BULK, GNUNET_ERROR_TYPE_WARNING, GNUNET_free, GNUNET_HELLO_iterate_addresses(), GNUNET_HELLO_size(), GNUNET_log_strerror_file, GNUNET_malloc, GNUNET_MAX_MESSAGE_SIZE, GNUNET_memcpy, GNUNET_NO, GNUNET_OK, and GNUNET_YES.
Referenced by cron_clean_data_hosts().
|
static |
Call this method periodically to scan peerinfo/ for ancient HELLOs to expire.
cls | unused |
Definition at line 1019 of file gnunet-service-peerinfo.c.
References _, cron_clean, DATA_HOST_CLEAN_FREQ, discard_hosts_helper(), GNUNET_DISK_directory_scan(), GNUNET_ERROR_TYPE_BULK, GNUNET_ERROR_TYPE_INFO, GNUNET_log, GNUNET_SCHEDULER_add_delayed(), GNUNET_TIME_absolute_get(), and networkIdDirectory.
Referenced by run().
|
static |
Check HELLO-message.
cls | identification of the client |
hello | the actual message |
Definition at line 1044 of file gnunet-service-peerinfo.c.
References GNUNET_break, GNUNET_HELLO_get_id(), GNUNET_OK, GNUNET_SYSERR, and pid.
|
static |
Handle HELLO-message.
cls | identification of the client |
hello | the actual message |
Definition at line 1065 of file gnunet-service-peerinfo.c.
References add_host_to_known_hosts(), GNUNET_assert, GNUNET_ERROR_TYPE_DEBUG, GNUNET_HELLO_get_id(), GNUNET_i2s(), GNUNET_log, GNUNET_OK, GNUNET_SERVICE_client_continue(), pid, and update_hello().
|
static |
Handle GET-message.
cls | identification of the client |
lpm | the actual message |
Definition at line 1087 of file gnunet-service-peerinfo.c.
References add_to_tc(), TransmitContext::client, env, TransmitContext::friend_only, GNUNET_CONTAINER_multipeermap_get_multiple(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_i2s(), GNUNET_log, GNUNET_MESSAGE_TYPE_PEERINFO_INFO_END, GNUNET_MQ_msg, GNUNET_MQ_send(), GNUNET_SERVICE_client_continue(), GNUNET_SERVICE_client_get_mq(), hostmap, ListPeerMessage::include_friend_only, msg, and ListPeerMessage::peer.
|
static |
Handle GET-ALL-message.
cls | identification of the client |
lapm | the actual message |
Definition at line 1116 of file gnunet-service-peerinfo.c.
References add_to_tc(), TransmitContext::client, env, TransmitContext::friend_only, GNUNET_CONTAINER_multipeermap_iterate(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_log, GNUNET_MESSAGE_TYPE_PEERINFO_INFO_END, GNUNET_MQ_msg, GNUNET_MQ_send(), GNUNET_SERVICE_client_continue(), GNUNET_SERVICE_client_get_mq(), hostmap, ListAllPeersMessage::include_friend_only, and msg.
|
static |
Handle NOTIFY-message.
cls | identification of the client |
nm | the actual message |
Definition at line 1140 of file gnunet-service-peerinfo.c.
References add_to_tc(), TransmitContext::client, env, TransmitContext::friend_only, GNUNET_CONTAINER_multipeermap_iterate(), GNUNET_ERROR_TYPE_DEBUG, GNUNET_log, GNUNET_MESSAGE_TYPE_PEERINFO_INFO_END, GNUNET_MQ_msg, GNUNET_MQ_send(), GNUNET_notification_context_add(), GNUNET_SERVICE_client_continue(), GNUNET_SERVICE_client_get_mq(), GNUNET_SERVICE_client_mark_monitor(), hostmap, NotifyMessage::include_friend_only, mq, msg, notify_friend_only_list, and notify_list.
|
static |
Client connect callback.
cls | unused |
client | server client |
mq | for client |
Definition at line 1173 of file gnunet-service-peerinfo.c.
References mq.
|
static |
Client disconnect callback.
cls | unused |
client | server client |
app_ctx | should be client |
Definition at line 1191 of file gnunet-service-peerinfo.c.
References GNUNET_assert.
|
static |
Release memory taken by a host entry.
cls | NULL |
key | key of the host entry |
value | the struct HostEntry to free |
Definition at line 1209 of file gnunet-service-peerinfo.c.
References HostEntry::friend_only_hello, GNUNET_free, GNUNET_YES, HostEntry::hello, key, and value.
Referenced by shutdown_task().
|
static |
Clean up our state.
Called during shutdown.
cls | unused |
Definition at line 1228 of file gnunet-service-peerinfo.c.
References cron_clean, cron_scan, free_host_entry(), GNUNET_CONTAINER_multipeermap_destroy(), GNUNET_CONTAINER_multipeermap_iterate(), GNUNET_free, GNUNET_NO, GNUNET_notification_context_destroy(), GNUNET_SCHEDULER_cancel(), GNUNET_STATISTICS_destroy(), hostmap, networkIdDirectory, notify_friend_only_list, notify_list, and stats.
Referenced by run().
|
static |
Start up peerinfo service.
cls | closure |
cfg | configuration to use |
service | the initialized service |
Definition at line 1269 of file gnunet-service-peerinfo.c.
References _, cfg, cron_clean, cron_clean_data_hosts(), cron_scan, cron_scan_directory_data_hosts(), GNUNET_asprintf(), GNUNET_assert, GNUNET_CONFIGURATION_get_value_filename(), GNUNET_CONFIGURATION_get_value_yesno(), GNUNET_CONTAINER_multipeermap_create(), GNUNET_DISK_directory_create(), GNUNET_DISK_directory_scan(), GNUNET_ERROR_TYPE_INFO, GNUNET_free, GNUNET_log, GNUNET_NO, GNUNET_notification_context_create(), GNUNET_OK, GNUNET_OS_installation_get_path(), GNUNET_OS_IPK_DATADIR, GNUNET_SCHEDULER_add_shutdown(), GNUNET_SCHEDULER_add_with_priority(), GNUNET_SCHEDULER_PRIORITY_IDLE, GNUNET_SCHEDULER_shutdown(), GNUNET_STATISTICS_create(), GNUNET_SYSERR, GNUNET_YES, hostmap, hosts_directory_scan_callback(), DirScanContext::matched, networkIdDirectory, notify_friend_only_list, notify_list, DirScanContext::remove_files, service, shutdown_task(), and stats.
GNUNET_SERVICE_MAIN | ( | "peerinfo" | , |
GNUNET_SERVICE_OPTION_NONE | , | ||
& | run, | ||
& | client_connect_cb, | ||
& | client_disconnect_cb, | ||
NULL | , | ||
GNUNET_MQ_hd_var_size(hello, GNUNET_MESSAGE_TYPE_HELLO, struct GNUNET_HELLO_Message, NULL) | , | ||
GNUNET_MQ_hd_fixed_size(get, GNUNET_MESSAGE_TYPE_PEERINFO_GET, struct ListPeerMessage, NULL) | , | ||
GNUNET_MQ_hd_fixed_size(get_all, GNUNET_MESSAGE_TYPE_PEERINFO_GET_ALL, struct ListAllPeersMessage, NULL) | , | ||
GNUNET_MQ_hd_fixed_size(notify, GNUNET_MESSAGE_TYPE_PEERINFO_NOTIFY, struct NotifyMessage, NULL) | , | ||
GNUNET_MQ_handler_end() | |||
) |
Define "main" method using service macro.
|
static |
The in-memory list of known hosts, mapping of host IDs to 'struct HostEntry*' values.
Definition at line 94 of file gnunet-service-peerinfo.c.
Referenced by add_host_to_known_hosts(), handle_get(), handle_get_all(), handle_notify(), run(), shutdown_task(), and update_hello().
|
static |
Clients to immediately notify about all changes.
Definition at line 99 of file gnunet-service-peerinfo.c.
Referenced by handle_notify(), notify_all(), run(), and shutdown_task().
|
static |
Clients to immediately notify about all changes, even for friend-only HELLOs.
Definition at line 105 of file gnunet-service-peerinfo.c.
Referenced by handle_notify(), notify_all(), run(), and shutdown_task().
|
static |
Directory where the hellos are stored in (peerinfo/)
Definition at line 110 of file gnunet-service-peerinfo.c.
Referenced by cron_clean_data_hosts(), cron_scan_directory_data_hosts(), get_host_filename(), remove_garbage(), run(), and shutdown_task().
|
static |
Handle for reporting statistics.
Definition at line 115 of file gnunet-service-peerinfo.c.
Referenced by add_host_to_known_hosts(), run(), and shutdown_task().
|
static |
Handle for task to run cron_clean_data_hosts()
Definition at line 120 of file gnunet-service-peerinfo.c.
Referenced by cron_clean_data_hosts(), run(), and shutdown_task().
|
static |
Handle for task to run cron_scan_directory_data_hosts()
Definition at line 125 of file gnunet-service-peerinfo.c.
Referenced by cron_scan_directory_data_hosts(), run(), and shutdown_task().