GNUnet  0.11.x
setu.h
Go to the documentation of this file.
1 /*
2  This file is part of GNUnet.
3  Copyright (C) 2012-2014, 2020 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  */
26 #ifndef SET_H
27 #define SET_H
28 
29 #include "platform.h"
30 #include "gnunet_common.h"
31 #include "gnunet_set_service.h"
32 
34 
41 {
46 
47 };
48 
49 
56 {
60  struct GNUNET_MessageHeader header;
61 
66 
71 };
72 
73 
79 {
83  struct GNUNET_MessageHeader header;
84 
88  uint32_t accept_reject_id GNUNET_PACKED;
89 
93  uint32_t request_id GNUNET_PACKED;
94 
99  uint8_t force_delta;
100 
105  uint8_t force_full;
106 
111  uint8_t byzantine;
112 
117  uint8_t symmetric;
118 
124 
125 };
126 
127 
133 {
137  struct GNUNET_MessageHeader header;
138 
142  uint32_t accept_reject_id GNUNET_PACKED;
143 };
144 
145 
150 {
154  struct GNUNET_MessageHeader header;
155 
160  uint32_t accept_id GNUNET_PACKED;
161 
166 
167  /* rest: context message, that is, application-specific
168  message to convince listener to pick up */
169 };
170 
171 
178 {
182  struct GNUNET_MessageHeader header;
183 
188  uint32_t request_id GNUNET_PACKED;
189 
194 
198  struct GNUNET_HashCode app_id;
199 
204  uint8_t force_delta;
205 
210  uint8_t force_full;
211 
216  uint8_t byzantine;
217 
221  uint8_t symmetric;
222 
228 
229  /* rest: context message, that is, application-specific
230  message to convince listener to pick up */
231 };
232 
233 
241 {
245  struct GNUNET_MessageHeader header;
246 
250  uint64_t current_size;
251 
255  uint32_t request_id GNUNET_PACKED;
256 
261  uint16_t result_status GNUNET_PACKED;
262 
266  uint16_t element_type GNUNET_PACKED;
267 
268  /* rest: the actual element */
269 };
270 
271 
277 {
281  struct GNUNET_MessageHeader header;
282 
286  uint16_t element_type GNUNET_PACKED;
287 
292 
293  /* rest: the actual element */
294 };
295 
296 
301 {
305  struct GNUNET_MessageHeader header;
306 
310  uint32_t request_id GNUNET_PACKED;
311 };
312 
313 
315 
316 #endif
Message sent by the client to the service to start listening for incoming requests to perform a certa...
Definition: setu.h:55
uint8_t symmetric
Also return set elements we are sending to the remote peer.
Definition: setu.h:221
struct GNUNET_MessageHeader header
Type: GNUNET_MESSAGE_TYPE_SETU_CREATE.
Definition: setu.h:45
static char * peer_id
Option –peer.
Definition: gnunet-cadet.c:42
static struct GNUNET_HashCode app_id
uint8_t byzantine
GNUNET_YES to fail operations where Byzantine faults are suspected
Definition: setu.h:111
Message sent by the client to the service to ask starting a new set to perform operations with...
Definition: setu.h:40
#define GNUNET_NETWORK_STRUCT_BEGIN
Define as empty, GNUNET_PACKED should suffice, but this won&#39;t work on W32.
uint8_t force_full
Always send full sets, even if delta operations would be more efficient.
Definition: setu.h:210
uint8_t symmetric
GNUNET_YES to also send back set elements we are sending to the remote peer.
Definition: setu.h:117
Message sent by client to service to initiate a set operation as a client (not as listener)...
Definition: setu.h:177
uint32_t byzantine_lower_bound
Lower bound for the set size, used only when byzantine mode is enabled.
Definition: setu.h:227
A 512-bit hashcode.
Message sent by a listening client to the service to accept performing the operation with the other p...
Definition: setu.h:78
uint8_t force_delta
Always use delta operation instead of sending full sets, even it it&#39;s less efficient.
Definition: setu.h:204
uint8_t byzantine
GNUNET_YES to fail operations where Byzantine faults are suspected
Definition: setu.h:216
uint64_t current_size
Current set size.
Definition: setu.h:250
Message sent by client to the service to add an element to the set.
Definition: setu.h:276
A request for an operation with another client.
Definition: setu.h:149
static struct GNUNET_PeerIdentity * target_peer
ID of the targeted peer.
#define GNUNET_NETWORK_STRUCT_END
Define as empty, GNUNET_PACKED should suffice, but this won&#39;t work on W32;.
The identity of the host (wraps the signing key of the peer).
uint8_t force_full
Always send full sets, even if delta operations would be more efficient.
Definition: setu.h:105
#define GNUNET_PACKED
gcc-ism to get packed structs.
Message sent by the service to the client to indicate an element that is removed (set intersection) o...
Definition: setu.h:240
Sent to the service by the client in order to cancel a set operation.
Definition: setu.h:300
Header for all communications.
uint8_t force_delta
Always use delta operation instead of sending full sets, even it it&#39;s less efficient.
Definition: setu.h:99
commonly used definitions; globals in this file are exempt from the rule that the module name ("commo...
static unsigned long long reserved
How much space have we currently reserved?
uint32_t byzantine_lower_bound
Lower bound for the set size, used only when byzantine mode is enabled.
Definition: setu.h:123
Message sent by a listening client to the service to reject performing the operation with the other p...
Definition: setu.h:132