GNUnet  0.10.x
gnunet_transport_hello_service.h
Go to the documentation of this file.
1 /*
2  This file is part of GNUnet.
3  Copyright (C) 2009-2016 GNUnet e.V.
4 
5  GNUnet is free software: you can redistribute it and/or modify it
6  under the terms of the GNU Affero General Public License as published
7  by the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  GNUnet is distributed in the hope that it will be useful, but
11  WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Affero General Public License for more details.
14 
15  You should have received a copy of the GNU Affero General Public License
16  along with this program. If not, see <http://www.gnu.org/licenses/>.
17 
18  SPDX-License-Identifier: AGPL3.0-or-later
19 */
20 
36 #ifndef GNUNET_TRANSPORT_HELLO_SERVICE_H
37 #define GNUNET_TRANSPORT_HELLO_SERVICE_H
38 
39 #ifdef __cplusplus
40 extern "C" {
41 #if 0 /* keep Emacsens' auto-indent happy */
42 }
43 #endif
44 #endif
45 
46 #include "gnunet_util_lib.h"
47 #include "gnunet_ats_service.h"
48 
52 #define GNUNET_TRANSPORT_HELLO_VERSION 0x00000000
53 
54 
62 {
63 
68 
74 
80 
86 
93 
100 
106 
111 
112 };
113 
114 
123  void *cls,
124  const struct GNUNET_MessageHeader *hello);
125 
126 
131 
132 
147  void *rec_cls);
148 
149 
155 void
157 
158 
169  void *cls,
170  const struct GNUNET_PeerIdentity *peer,
171  const char *address,
172  enum GNUNET_NetworkType nt,
174 
175 
185 int
188  void *cb_cls);
189 
190 
191 #if 0 /* keep Emacsens' auto-indent happy */
192 {
193 #endif
194 #ifdef __cplusplus
195 }
196 #endif
197 
198 /* ifndef GNUNET_TRANSPORT_HELLO_SERVICE_H */
199 #endif
200  /* end of group */
202 
203 /* end of gnunet_transport_hello_service.h */
Addresses useful in the local wireless network, i.e.
static char * expiration
Credential TTL.
Addresses useful in the local wired network, i.e.
void(* GNUNET_TRANSPORT_HelloUpdateCallback)(void *cls, const struct GNUNET_MessageHeader *hello)
Function called whenever there is an update to the HELLO of this peer.
GNUNET_NetworkType
Types of networks (with separate quotas) we support.
Definition: gnunet_nt_lib.h:35
int GNUNET_TRANSPORT_hello_parse(const struct GNUNET_MessageHeader *hello, GNUNET_TRANSPORT_AddressCallback cb, void *cb_cls)
Parse a HELLO message that we have received into its constituent addresses.
GNUNET_TRANSPORT_HelloUpdateCallback rec
Callback to call once we got our HELLO.
static struct GNUNET_NAT_AUTO_Test * nt
Handle to a NAT test operation.
static struct GNUNET_CONFIGURATION_Handle * cfg
Our configuration.
Definition: gnunet-arm.c:104
struct GNUNET_TESTBED_Peer * peer
The peer associated with this model.
static struct GNUNET_MQ_Envelope * ac
Handle to current GNUNET_PEERINFO_add_peer() operation.
Addresses that are global and are insensitive (i.e.
static struct GNUNET_TRANSPORT_HelloGetHandle * ghh
Handle to get our current HELLO.
GNUNET_TRANSPORT_AddressClass
Some addresses contain sensitive information or are not suitable for global distribution.
Addresses that fall into no other category (i.e.
The identity of the host (wraps the signing key of the peer).
configuration data
Definition: configuration.c:85
struct GNUNET_TRANSPORT_HelloGetHandle * GNUNET_TRANSPORT_hello_get(const struct GNUNET_CONFIGURATION_Handle *cfg, enum GNUNET_TRANSPORT_AddressClass ac, GNUNET_TRANSPORT_HelloUpdateCallback rec, void *rec_cls)
Obtain updates on changes to the HELLO message for this peer.
Automatic transport selection and outbound bandwidth determination.
Functions to call with this peer&#39;s HELLO.
Header for all communications.
Time for absolute times used by GNUnet, in microseconds.
void(* GNUNET_TRANSPORT_AddressCallback)(void *cls, const struct GNUNET_PeerIdentity *peer, const char *address, enum GNUNET_NetworkType nt, struct GNUNET_TIME_Absolute expiration)
Function with addresses found in a HELLO.
Addresses useful in the local bluetooth network.
static char * address
GNS address for this phone.
void GNUNET_TRANSPORT_hello_get_cancel(struct GNUNET_TRANSPORT_HelloGetHandle *ghh)
Stop receiving updates about changes to our HELLO message.
Addresses that are global and are sensitive (i.e.