GNUnet  0.10.x
exit.h
Go to the documentation of this file.
1 /*
2  This file is part of GNUnet.
3  Copyright (C) 2012 Christian Grothoff
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 
26 #ifndef EXIT_H
27 #define EXIT_H
28 
29 #include "gnunet_util_lib.h"
30 
32 
38 {
43 
48 
54 
55  /* followed by TCP payload */
56 };
57 
58 
64 {
69 
73  int32_t af GNUNET_PACKED;
74 
79  struct GNUNET_TUN_TcpHeader tcp_header;
80 
81  /* followed by IP address of the destination; either
82  'struct in_addr' or 'struct in6_addr', depending on af */
83 
84  /* followed by TCP payload */
85 };
86 
87 
95 {
100 
105 
110  struct GNUNET_TUN_TcpHeader tcp_header;
111 
112  /* followed by TCP payload */
113 };
114 
115 
121 {
126 
130  uint16_t source_port GNUNET_PACKED;
131 
135  uint16_t destination_port GNUNET_PACKED;
136 
137  /* followed by UDP payload */
138 };
139 
140 
146 {
151 
155  int32_t af GNUNET_PACKED;
156 
160  uint16_t source_port GNUNET_PACKED;
161 
165  uint16_t destination_port GNUNET_PACKED;
166 
167  /* followed by IP address of the destination; either
168  'struct in_addr' or 'struct in6_addr', depending on af */
169 
170  /* followed by UDP payload */
171 };
172 
173 
179 {
184 
189  uint16_t source_port GNUNET_PACKED;
190 
195  uint16_t destination_port GNUNET_PACKED;
196 
197  /* followed by UDP payload */
198 };
199 
200 
206 {
211 
218  int32_t af GNUNET_PACKED;
219 
223  struct GNUNET_TUN_IcmpHeader icmp_header;
224 
225  /* followed by ICMP payload; however, for certain ICMP message
226  types where the payload is the original IP packet, the payload
227  is omitted as it is useless for the receiver (who will need
228  to create some fake payload manually) */
229 };
230 
231 
237 {
242 
249  int32_t af GNUNET_PACKED;
250 
255  struct GNUNET_TUN_IcmpHeader icmp_header;
256 
257  /* followed by IP address of the destination; either
258  'struct in_addr' or 'struct in6_addr', depending on af */
259 
260  /* followed by ICMP payload; however, for certain ICMP message
261  types where the payload is the original IP packet, the payload
262  is omitted as it is useless for the receiver (who will need
263  to create some fake payload manually) */
264 };
265 
266 
272 {
277 
282  int32_t af GNUNET_PACKED;
283 
287  struct GNUNET_TUN_IcmpHeader icmp_header;
288 
289  /* followed by ICMP payload; however, for certain ICMP message
290  types where the payload is the original IP packet, the payload
291  is omitted as it is useless for the receiver (who will need
292  to create some fake payload manually) */
293 };
294 
295 
297 
298 #endif
struct GNUNET_TUN_TcpHeader tcp_header
Skeleton of the TCP header to send.
Definition: exit.h:53
#define GNUNET_NETWORK_STRUCT_BEGIN
Define as empty, GNUNET_PACKED should suffice, but this won&#39;t work on W32.
Message send via cadet to an exit daemon to send ICMP data to a local service.
Definition: exit.h:205
uint32_t reserved
Always 0.
Definition: exit.h:47
Message send via cadet to an exit daemon to forward ICMP data to the Internet.
Definition: exit.h:236
Message send from exit daemon back to the UDP entry point (used for both Internet and Service exit re...
Definition: exit.h:178
Message send via cadet to the vpn service to send ICMP data to the VPN&#39;s TUN interface.
Definition: exit.h:271
TCP packet header.
Message send via cadet to an exit daemon to send UDP data to a local service.
Definition: exit.h:120
#define GNUNET_NETWORK_STRUCT_END
Define as empty, GNUNET_PACKED should suffice, but this won&#39;t work on W32;.
#define GNUNET_PACKED
gcc-ism to get packed structs.
Message send via cadet to an exit daemon to initiate forwarding of TCP data to the Internet...
Definition: exit.h:63
Header for all communications.
struct GNUNET_MessageHeader header
Type is GNUNET_MESSAGE_TYPE_VPN_TCP_TO_SERVICE_START.
Definition: exit.h:42
Message send via cadet to an exit daemon to initiate forwarding of TCP data to a local service...
Definition: exit.h:37
Message send via cadet between VPN and entry and an exit daemon to transmit TCP data between the VPN ...
Definition: exit.h:94
Message send via cadet to an exit daemon to forward UDP data to the Internet.
Definition: exit.h:145