allow build once more
[oweals/gnunet.git] / src / include / gnunet_protocols.h
1 /*
2      This file is part of GNUnet.
3      (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009, 2010 Christian Grothoff (and other contributing authors)
4
5      GNUnet is free software; you can redistribute it and/or modify
6      it under the terms of the GNU General Public License as published
7      by the Free Software Foundation; either version 2, or (at your
8      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      General Public License for more details.
14
15      You should have received a copy of the GNU General Public License
16      along with GNUnet; see the file COPYING.  If not, write to the
17      Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18      Boston, MA 02111-1307, USA.
19 */
20
21 /**
22  * @file include/gnunet_protocols.h
23  * @brief constants for network protocols
24  * @author Christian Grothoff
25  */
26
27 #ifndef GNUNET_PROTOCOLS_H
28 #define GNUNET_PROTOCOLS_H
29
30 #ifdef __cplusplus
31 extern "C"
32 {
33 #if 0                           /* keep Emacsens' auto-indent happy */
34 }
35 #endif
36 #endif
37
38 /**
39  * Test if service is online.
40  */
41 #define GNUNET_MESSAGE_TYPE_TEST 1
42
43
44 /**
45  * Request DNS resolution.
46  */
47 #define GNUNET_MESSAGE_TYPE_RESOLVER_REQUEST 2
48
49 /**
50  * Response to a DNS resolution request.
51  */
52 #define GNUNET_MESSAGE_TYPE_RESOLVER_RESPONSE 3
53
54
55
56 /**
57  * Request to ARM to start a service.
58  */
59 #define GNUNET_MESSAGE_TYPE_ARM_START 8
60
61 /**
62  * Request to ARM to stop a service.
63  */
64 #define GNUNET_MESSAGE_TYPE_ARM_STOP 9
65
66 /**
67  * Response from ARM: service is now up.
68  */
69 #define GNUNET_MESSAGE_TYPE_ARM_IS_UP 10
70
71 /**
72  * Response from ARM: service is now down.
73  * (failed to start it or shut it down).
74  */
75 #define GNUNET_MESSAGE_TYPE_ARM_IS_DOWN 11
76
77 /**
78  * Response from ARM: service status is unknown.
79  */
80 #define GNUNET_MESSAGE_TYPE_ARM_IS_UNKNOWN 12
81
82 /**
83  * Request ARM service shutdown.
84  */
85 #define GNUNET_MESSAGE_TYPE_ARM_SHUTDOWN 13
86
87 /**
88  * Acknowledge service shutting down, disconnect
89  * indicates service stopped.
90  */
91 #define GNUNET_MESSAGE_TYPE_ARM_SHUTDOWN_ACK 14
92
93 /**
94  * HELLO message used for communicating peer addresses.
95  * Managed by libgnunethello.
96  */
97 #define GNUNET_MESSAGE_TYPE_HELLO 16
98
99 /**
100  * FRAGMENT of a larger message.
101  * Managed by libgnunetfragment.
102  */
103 #define GNUNET_MESSAGE_TYPE_FRAGMENT 18
104
105 /**
106  * Acknowledgement of a FRAGMENT of a larger message.
107  * Managed by libgnunetfragment.
108  */
109 #define GNUNET_MESSAGE_TYPE_FRAGMENT_ACK 19
110
111 /**
112  * Message from the core saying that the transport
113  * server should start giving it messages.  This
114  * should automatically trigger the transmission of
115  * a HELLO message.
116  */
117 #define GNUNET_MESSAGE_TYPE_TRANSPORT_START 20
118
119 /**
120  * Message from TRANSPORT notifying about a
121  * client that connected to us.
122  */
123 #define GNUNET_MESSAGE_TYPE_TRANSPORT_CONNECT 21
124
125 /**
126  * Message from TRANSPORT notifying about a
127  * client that disconnected from us.
128  */
129 #define GNUNET_MESSAGE_TYPE_TRANSPORT_DISCONNECT 22
130
131 /**
132  * Request to TRANSPORT to transmit a message.
133  */
134 #define GNUNET_MESSAGE_TYPE_TRANSPORT_SEND 23
135
136 /**
137  * Confirmation from TRANSPORT that message for
138  * transmission has been queued (and that the next
139  * message to this peer can now be passed to the
140  * service).  Note that this confirmation does NOT
141  * imply that the message was fully transmitted.
142  */
143 #define GNUNET_MESSAGE_TYPE_TRANSPORT_SEND_OK 24
144
145 /**
146  * Message from TRANSPORT notifying about a
147  * message that was received.
148  */
149 #define GNUNET_MESSAGE_TYPE_TRANSPORT_RECV 25
150
151 /**
152  * Message telling transport to limit its receive rate.
153  */
154 #define GNUNET_MESSAGE_TYPE_TRANSPORT_SET_QUOTA 26
155
156 /**
157  * Request to look addresses of peers in server.
158  */
159 #define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_LOOKUP 27
160
161 /**
162  * Response to the address lookup request.
163  */
164 #define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_REPLY 28
165
166 /**
167  * Register a client that wants to do blacklisting.
168  */
169 #define GNUNET_MESSAGE_TYPE_TRANSPORT_BLACKLIST_INIT 29
170
171 /**
172  * Query to a blacklisting client (is this peer blacklisted)?
173  */
174 #define GNUNET_MESSAGE_TYPE_TRANSPORT_BLACKLIST_QUERY 30
175
176
177 /**
178  * Reply from blacklisting client (answer to blacklist query).
179  */
180 #define GNUNET_MESSAGE_TYPE_TRANSPORT_BLACKLIST_REPLY 31
181
182 /**
183  * Transport PING message
184  */
185 #define GNUNET_MESSAGE_TYPE_TRANSPORT_PING 32
186
187 /**
188  * Transport PONG message
189  */
190 #define GNUNET_MESSAGE_TYPE_TRANSPORT_PONG 33
191
192 /**
193  * Message for TRANSPORT asking that a connection
194  * be initiated with a peer.
195  */
196 #define GNUNET_MESSAGE_TYPE_TRANSPORT_REQUEST_CONNECT 34
197
198 /**
199  * Request update and listing of a peer.
200  */
201 #define GNUNET_MESSAGE_TYPE_PEERINFO_GET 37
202
203 /**
204  * Request update and listing of all peers.
205  */
206 #define GNUNET_MESSAGE_TYPE_PEERINFO_GET_ALL 38
207
208 /**
209  * Information about one of the peers.
210  */
211 #define GNUNET_MESSAGE_TYPE_PEERINFO_INFO 39
212
213 /**
214  * End of information about other peers.
215  */
216 #define GNUNET_MESSAGE_TYPE_PEERINFO_INFO_END 40
217
218 /**
219  * Start notifying this client about all changes to
220  * the known peers until it disconnects.
221  */
222 #define GNUNET_MESSAGE_TYPE_PEERINFO_NOTIFY 41
223
224 /**
225  * DV service to DV Plugin message, when a message is
226  * unwrapped by the DV service and handed to the plugin
227  * for processing
228  */
229 #define GNUNET_MESSAGE_TYPE_TRANSPORT_DV_RECEIVE 44
230
231 /**
232  * DV Plugin to DV service message, indicating a message
233  * should be sent out.
234  */
235 #define GNUNET_MESSAGE_TYPE_TRANSPORT_DV_SEND 45
236
237 /**
238  * DV service to DV api message, containing a confirmation
239  * or failure of a DV_SEND message.
240  */
241 #define GNUNET_MESSAGE_TYPE_TRANSPORT_DV_SEND_RESULT 46
242
243 /**
244  * P2P DV message encapsulating some real message
245  */
246 #define GNUNET_MESSAGE_TYPE_DV_DATA 47
247
248 /**
249  * P2P DV message gossipping peer information
250  */
251 #define GNUNET_MESSAGE_TYPE_DV_GOSSIP 48
252
253 /**
254  * DV Plugin to DV service message, indicating
255  * startup.
256  */
257 #define GNUNET_MESSAGE_TYPE_DV_START 49
258
259 /**
260  * P2P DV message notifying connected peers of a disconnect
261  */
262 #define GNUNET_MESSAGE_TYPE_DV_DISCONNECT 50
263
264 /**
265  * TCP NAT probe message, send from NAT'd peer to
266  * other peer to establish bi-directional communication
267  */
268 #define GNUNET_MESSAGE_TYPE_TRANSPORT_TCP_NAT_PROBE 51
269
270 /**
271  * Normal UDP message type.
272  */
273 #define GNUNET_MESSAGE_TYPE_TRANSPORT_UDP_MESSAGE 52
274
275 /**
276  * UDP ACK.
277  */
278 #define GNUNET_MESSAGE_TYPE_TRANSPORT_UDP_ACK 53
279
280 /**
281  * Request to look up addresses of peers.
282  */
283 #define GNUNET_MESSAGE_TYPE_TRANSPORT_PEER_ADDRESS_LOOKUP 59
284
285 /**
286  * Request to iterate over all known addresses.
287  */
288 #define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_ITERATE 60
289
290 /**
291  * Welcome message between TCP transports.
292  */
293 #define GNUNET_MESSAGE_TYPE_TRANSPORT_TCP_WELCOME 61
294
295 /**
296  * Message to force transport to update bandwidth assignment
297  */
298 #define GNUNET_MESSAGE_TYPE_TRANSPORT_ATS 62
299
300 /**
301  * Message to ask NAT server to perform traversal test
302  */
303 #define GNUNET_MESSAGE_TYPE_NAT_TEST 63
304
305 /**
306  * Initial setup message from core client to core.
307  */
308 #define GNUNET_MESSAGE_TYPE_CORE_INIT 64
309
310 /**
311  * Response from core to core client to INIT message.
312  */
313 #define GNUNET_MESSAGE_TYPE_CORE_INIT_REPLY 65
314
315 /**
316  * Notify clients about new peer-to-peer connections (before
317  * key exchange and authentication).
318  */
319 #define GNUNET_MESSAGE_TYPE_CORE_NOTIFY_PRE_CONNECT 66
320
321 /**
322  * Notify clients about new peer-to-peer connections (triggered
323  * after key exchange).
324  */
325 #define GNUNET_MESSAGE_TYPE_CORE_NOTIFY_CONNECT 67
326
327 /**
328  * Notify clients about peer disconnecting.
329  */
330 #define GNUNET_MESSAGE_TYPE_CORE_NOTIFY_DISCONNECT 68
331
332 /**
333  * Notify clients about peer status change.
334  */
335 #define GNUNET_MESSAGE_TYPE_CORE_NOTIFY_STATUS_CHANGE 69
336
337 /**
338  * Notify clients about incoming P2P messages.
339  */
340 #define GNUNET_MESSAGE_TYPE_CORE_NOTIFY_INBOUND 70
341
342 /**
343  * Notify clients about outgoing P2P transmissions.
344  */
345 #define GNUNET_MESSAGE_TYPE_CORE_NOTIFY_OUTBOUND 71
346
347 /**
348  * Request from client to "configure" P2P connection.
349  */
350 #define GNUNET_MESSAGE_TYPE_CORE_REQUEST_INFO 72
351
352 /**
353  * Response from server about (possibly updated) P2P
354  * connection configuration.
355  */
356 #define GNUNET_MESSAGE_TYPE_CORE_CONFIGURATION_INFO 73
357
358 /**
359  * Request from client to transmit message.
360  */
361 #define GNUNET_MESSAGE_TYPE_CORE_SEND_REQUEST 74
362
363 /**
364  * Confirmation from core that message can now be sent
365  */
366 #define GNUNET_MESSAGE_TYPE_CORE_SEND_READY 75
367
368 /**
369  * Client with message to transmit (after SEND_READY confirmation
370  * was received).
371  */
372 #define GNUNET_MESSAGE_TYPE_CORE_SEND 76
373
374 /**
375  * Request from client asking to connect to a peer.
376  */
377 #define GNUNET_MESSAGE_TYPE_CORE_REQUEST_CONNECT 77
378
379 /**
380  * Request for peer iteration from CORE service.
381  */
382 #define GNUNET_MESSAGE_TYPE_CORE_ITERATE_PEERS 78
383
384 /**
385  * Last reply from core to request for peer iteration from CORE service.
386  */
387 #define GNUNET_MESSAGE_TYPE_CORE_ITERATE_PEERS_END 79
388
389 /**
390  * Check whether a given peer is currently connected to CORE.
391  */
392 #define GNUNET_MESSAGE_TYPE_CORE_PEER_CONNECTED 80
393
394 /**
395  * Session key exchange between peers.
396  */
397 #define GNUNET_MESSAGE_TYPE_CORE_SET_KEY 81
398
399 /**
400  * Encapsulation for an encrypted message between peers.
401  */
402 #define GNUNET_MESSAGE_TYPE_CORE_ENCRYPTED_MESSAGE 82
403
404 /**
405  * Check that other peer is alive (challenge).
406  */
407 #define GNUNET_MESSAGE_TYPE_CORE_PING 83
408
409 /**
410  * Confirmation that other peer is alive.
411  */
412 #define GNUNET_MESSAGE_TYPE_CORE_PONG 84
413
414 /**
415  * Request by the other peer to terminate the connection.
416  */
417 #define GNUNET_MESSAGE_TYPE_CORE_HANGUP 85
418
419 /**
420  * Message sent by datastore client on join.
421  */
422 #define GNUNET_MESSAGE_TYPE_DATASTORE_RESERVE 92
423
424 /**
425  * Message sent by datastore client on join.
426  */
427 #define GNUNET_MESSAGE_TYPE_DATASTORE_RELEASE_RESERVE 93
428
429 /**
430  * Message sent by datastore to client informing about status
431  * processing a request
432  * (in response to RESERVE, RELEASE_RESERVE, PUT, UPDATE and REMOVE requests).
433  */
434 #define GNUNET_MESSAGE_TYPE_DATASTORE_STATUS 94
435
436 /**
437  * Message sent by datastore client to store data.
438  */
439 #define GNUNET_MESSAGE_TYPE_DATASTORE_PUT 95
440
441 /**
442  * Message sent by datastore client to update data.
443  */
444 #define GNUNET_MESSAGE_TYPE_DATASTORE_UPDATE 96
445
446 /**
447  * Message sent by datastore client to get data.
448  */
449 #define GNUNET_MESSAGE_TYPE_DATASTORE_GET 97
450
451 /**
452  * Message sent by datastore client to get random data.
453  */
454 #define GNUNET_MESSAGE_TYPE_DATASTORE_GET_REPLICATION 98
455
456 /**
457  * Message sent by datastore client to get random data.
458  */
459 #define GNUNET_MESSAGE_TYPE_DATASTORE_GET_ZERO_ANONYMITY 99
460
461 /**
462  * Message sent by datastore to client providing requested data
463  * (in response to GET or GET_RANDOM request).
464  */
465 #define GNUNET_MESSAGE_TYPE_DATASTORE_DATA 100
466
467 /**
468  * Message sent by datastore to client signaling end of matching data.
469  * This message will also be sent for "GET_RANDOM", even though
470  * "GET_RANDOM" returns at most one data item.
471  */
472 #define GNUNET_MESSAGE_TYPE_DATASTORE_DATA_END 101
473
474 /**
475  * Message sent by datastore client to remove data.
476  */
477 #define GNUNET_MESSAGE_TYPE_DATASTORE_REMOVE 102
478
479 /**
480  * Message sent by datastore client to drop the database.
481  */
482 #define GNUNET_MESSAGE_TYPE_DATASTORE_DROP 103
483
484
485 /**
486  * Message sent by fs client to start indexing.
487  */
488 #define GNUNET_MESSAGE_TYPE_FS_INDEX_START 128
489
490 /**
491  * Affirmative response to a request for start indexing.
492  */
493 #define GNUNET_MESSAGE_TYPE_FS_INDEX_START_OK 129
494
495 /**
496  * Response to a request for start indexing that
497  * refuses.
498  */
499 #define GNUNET_MESSAGE_TYPE_FS_INDEX_START_FAILED 130
500
501 /**
502  * Request from client for list of indexed files.
503  */
504 #define GNUNET_MESSAGE_TYPE_FS_INDEX_LIST_GET 131
505
506 /**
507  * Reply to client with an indexed file name.
508  */
509 #define GNUNET_MESSAGE_TYPE_FS_INDEX_LIST_ENTRY 132
510
511 /**
512  * Reply to client indicating end of list.
513  */
514 #define GNUNET_MESSAGE_TYPE_FS_INDEX_LIST_END 133
515
516 /**
517  * Request from client to unindex a file.
518  */
519 #define GNUNET_MESSAGE_TYPE_FS_UNINDEX 134
520
521 /**
522  * Reply to client indicating unindex receipt.
523  */
524 #define GNUNET_MESSAGE_TYPE_FS_UNINDEX_OK 135
525
526 /**
527  * Client asks FS service to start a (keyword) search.
528  */
529 #define GNUNET_MESSAGE_TYPE_FS_START_SEARCH 136
530
531 /**
532  * P2P request for content (one FS to another).
533  */
534 #define GNUNET_MESSAGE_TYPE_FS_GET 137
535
536 /**
537  * P2P response with content or active migration of content.  Also
538  * used between the service and clients (in response to START_SEARCH).
539  */
540 #define GNUNET_MESSAGE_TYPE_FS_PUT 138
541
542 /**
543  * Peer asks us to stop migrating content towards it for a while.
544  */
545 #define GNUNET_MESSAGE_TYPE_FS_MIGRATION_STOP 139
546
547
548 /**
549  * DHT Message Types
550  */
551
552 /**
553  * Local DHT route request type
554  */
555 #define GNUNET_MESSAGE_TYPE_DHT_LOCAL_ROUTE 142
556
557 /**
558  * Local generic DHT route result type
559  */
560 #define GNUNET_MESSAGE_TYPE_DHT_LOCAL_ROUTE_RESULT 143
561
562 /**
563  * P2P DHT route request type
564  */
565 #define GNUNET_MESSAGE_TYPE_DHT_P2P_ROUTE 144
566
567 /**
568  * P2P DHT route result type
569  */
570 #define GNUNET_MESSAGE_TYPE_DHT_P2P_ROUTE_RESULT 145
571
572 /**
573  * Local generic DHT message stop type
574  */
575 #define GNUNET_MESSAGE_TYPE_DHT_LOCAL_ROUTE_STOP 146
576
577 /**
578  * Local and P2P DHT PUT message
579  * (encapsulated in DHT_ROUTE message)
580  */
581 #define GNUNET_MESSAGE_TYPE_DHT_PUT 147
582
583 /**
584  * Local and P2P DHT GET message
585  * (encapsulated in DHT_ROUTE message)
586  */
587 #define GNUNET_MESSAGE_TYPE_DHT_GET 148
588
589 /**
590  * Local and P2P DHT Get result message
591  */
592 #define GNUNET_MESSAGE_TYPE_DHT_GET_RESULT 149
593
594 /**
595  * Local and P2P DHT find peer message
596  */
597 #define GNUNET_MESSAGE_TYPE_DHT_FIND_PEER 150
598
599 /**
600  * Local and P2P DHT find peer result message
601  */
602 #define GNUNET_MESSAGE_TYPE_DHT_FIND_PEER_RESULT 151
603
604 /**
605  * P2P DHT PING request type
606  */
607 #define GNUNET_MESSAGE_TYPE_DHT_P2P_PING 152
608
609 /**
610  * DHT Control message type, for telling the
611  * DHT to alter its current operation somehow.
612  */
613 #define GNUNET_MESSAGE_TYPE_DHT_CONTROL 153
614
615 /**
616  * Local control message type, tells peer to start
617  * issuing malicious GET requests.
618  */
619 #define GNUNET_MESSAGE_TYPE_DHT_MALICIOUS_GET 154
620
621 /**
622  * Local control message type, tells peer to start
623  * issuing malicious PUT requests.
624  */
625 #define GNUNET_MESSAGE_TYPE_DHT_MALICIOUS_PUT 155
626
627 /**
628  * Local control message type, tells peer to start
629  * dropping all requests.
630  */
631 #define GNUNET_MESSAGE_TYPE_DHT_MALICIOUS_DROP  156
632
633 /**
634  * Hostlist advertisement message
635  */
636 #define GNUNET_MESSAGE_TYPE_HOSTLIST_ADVERTISEMENT 160
637
638
639 /**
640  * Set a statistical value.
641  */
642 #define GNUNET_MESSAGE_TYPE_STATISTICS_SET 168
643
644 /**
645  * Get a statistical value(s).
646  */
647 #define GNUNET_MESSAGE_TYPE_STATISTICS_GET 169
648
649 /**
650  * Response to a STATISTICS_GET message (with value).
651  */
652 #define GNUNET_MESSAGE_TYPE_STATISTICS_VALUE 170
653
654 /**
655  * Response to a STATISTICS_GET message (end of value stream).
656  */
657 #define GNUNET_MESSAGE_TYPE_STATISTICS_END 171
658
659 /**
660  * Watch changes to a statistical value.  Message format is the same
661  * as for GET, except that the subsystem and entry name must be given.
662  */
663 #define GNUNET_MESSAGE_TYPE_STATISTICS_WATCH 172
664
665 /**
666  * Changes to a watched value.
667  */
668 #define GNUNET_MESSAGE_TYPE_STATISTICS_WATCH_VALUE 173
669
670
671 /**
672  * Type of messages between the gnunet-vpn-helper and the daemon
673  */
674 #define GNUNET_MESSAGE_TYPE_VPN_HELPER 185
675
676 /**
677  * Type of messages containing an UDP packet for a service
678  */
679 #define GNUNET_MESSAGE_TYPE_SERVICE_UDP 186
680
681 /**
682  * Type of messages containing an UDP packet from a service
683  */
684 #define GNUNET_MESSAGE_TYPE_SERVICE_UDP_BACK 187
685
686 /**
687  * Type of messages containing an TCP packet for a service
688  */
689 #define GNUNET_MESSAGE_TYPE_SERVICE_TCP 188
690
691 /**
692  * Type of messages containing an TCP packet from a service
693  */
694 #define GNUNET_MESSAGE_TYPE_SERVICE_TCP_BACK 189
695
696 /**
697  * Type of messages containing an UDP packet for a remote host
698  */
699 #define GNUNET_MESSAGE_TYPE_REMOTE_UDP 190
700
701 /**
702  * Type of messages containing an UDP packet from a remote host
703  */
704 #define GNUNET_MESSAGE_TYPE_REMOTE_UDP_BACK 191
705
706 /**
707  * Type of messages containing an TCP packet for a remote host
708  */
709 #define GNUNET_MESSAGE_TYPE_REMOTE_TCP 192
710
711 /**
712  * Type of messages containing an TCP packet from a remote host
713  */
714 #define GNUNET_MESSAGE_TYPE_REMOTE_TCP_BACK 193
715
716
717 /**
718  * Type of messages between the gnunet-wlan-helper and the daemon
719  *
720  */
721
722 #define GNUNET_MESSAGE_TYPE_WLAN_HELPER_DATA 195
723
724 /**
725  * Control messages between the gnunet-wlan-helper and the daemon
726  */
727
728 #define GNUNET_MESSAGE_TYPE_WLAN_HELPER_CONTROL 196
729
730 /**
731  * Type of messages for advertisement over wlan
732  */
733 #define GNUNET_MESSAGE_TYPE_WLAN_ADVERTISEMENT 197
734
735 /**
736  * Type of messages for data over the wlan
737  */
738
739 #define GNUNET_MESSAGE_TYPE_WLAN_DATA 198
740
741 /**
742  * Fragment of a message
743  */
744
745 #define GNUNET_MESSAGE_TYPE_WLAN_FRAGMENT 199
746
747 /**
748  * Fragment ack of a message
749  */
750
751 #define GNUNET_MESSAGE_TYPE_WLAN_FRAGMENT_ACK 200
752
753
754 /**
755  * Type of messages to query the local service-dns
756  */
757 #define GNUNET_MESSAGE_TYPE_LOCAL_QUERY_DNS 205
758 /**
759  * Type of messages the local service-dns responds with
760  */
761 #define GNUNET_MESSAGE_TYPE_LOCAL_RESPONSE_DNS 206
762 /**
763  * Type of messages to instruct the local service-dns to rehijack the dns
764  */
765 #define GNUNET_MESSAGE_TYPE_REHIJACK 207
766 /**
767  * Type of messages to send a DNS-query to another peer
768  */
769 #define GNUNET_MESSAGE_TYPE_REMOTE_QUERY_DNS 208
770 /**
771  * Type of messages to send a DNS-answer to another peer
772  */
773 #define GNUNET_MESSAGE_TYPE_REMOTE_ANSWER_DNS 209
774
775
776 /**
777  * Type of message used to transport messages throug a MESH-tunnel
778  */
779 #define GNUNET_MESSAGE_TYPE_MESH 215
780
781 /**
782  * Type of message used to send another peer which messages we want to receive
783  * through a mesh-tunnel.
784  */
785 #define GNUNET_MESSAGE_TYPE_MESH_HELLO 216
786
787
788 /*******************************************************************************
789  * MESH message types (WiP)
790  ******************************************************************************/
791
792 /**
793  * Request the creation of a path
794  */
795 #define GNUNET_MESSAGE_TYPE_MESH_PATH_CREATE   256
796
797 /**
798  * Request the modification of an existing path
799  */
800 #define GNUNET_MESSAGE_TYPE_MESH_PATH_CHANGE   257
801
802 /**
803  * Request the addition to a new branch to a path
804  */
805 #define GNUNET_MESSAGE_TYPE_MESH_PATH_ADD      258
806
807 /**
808  * At some point, the route will spontaneously change
809  */
810 #define GNUNET_MESSAGE_TYPE_MESH_PATH_CHANGED  259
811
812 /**
813  * Transport data in the mesh (origin->end) unicast
814  */
815 #define GNUNET_MESSAGE_TYPE_DATA_MESSAGE_FROM_ORIGIN    260
816
817 /**
818  * Transport data to all peers in a tunnel
819  */
820 #define GNUNET_MESSAGE_TYPE_DATA_MULTICAST              261
821
822 /**
823  * Transport data back in the mesh (end->origin)
824  * (not sure if this is the right way, should be some other solution)
825  */
826 #define GNUNET_MESSAGE_TYPE_DATA_MESSAGE_TO_ORIGIN      262
827
828
829 /**
830  * We need flow control
831  */
832 #define GNUNET_MESSAGE_TYPE_MESH_SPEED_NOTIFY           270
833
834 /**
835  * Connect to the mesh service, specifying subscriptions
836  */
837 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_CONNECT                  272
838
839 /**
840  * Ask the mesh service to create a new tunnel
841  */
842 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_TUNNEL_CREATE            273
843
844 /**
845  * Ask the mesh service to destroy a tunnel
846  */
847 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_TUNNEL_DESTROY           274
848
849 /**
850  * Ask the mesh service to add a peer to an existing tunnel
851  */
852 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_CONNECT_PEER_ADD         275
853
854 /**
855  * Ask the mesh service to remove a peer from a tunnel
856  */
857 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_CONNECT_PEER_DEL         276
858
859 /**
860  * Ask the mesh service to add a peer offering a service to an existing tunnel
861  */
862 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_CONNECT_PEER_BY_TYPE     277
863
864 /**
865  * Ask the mesh service to cancel a peer connection request
866  */
867 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_CONNECT_PEER_CANCEL      278
868
869 /**
870  * Notify a mesh client that a peer has connected to a tunnel
871  */
872 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_PEER_CONNECTED           279
873
874 /**
875  * Notify a mesh client that a peer has disconnected from a tunnel
876  */
877 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_PEER_DISCONNECTED        280
878
879 /* FIXME needed? */
880 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_REQUEST_TRANSMIT_READY   281
881 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_NOTIFY_TRANSMIT_READY    282
882
883 /**
884  * Message client <-> mesh service to transport payload
885  */
886 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_DATA                     283
887
888 /**
889  * Message client->mesh to send data to all peers connected to a tunnel
890  */
891 #define GNUNET_MESSAGE_TYPE_MESH_LOCAL_DATA_BROADCAST           284
892
893 /**
894  * 640kb should be enough for everybody
895  */
896 #define GNUNET_MESSAGE_TYPE_MESH_RESERVE_END   288
897
898 /*******************************************************************************
899  * MESH message types END
900  ******************************************************************************/
901
902
903
904 /*******************************************************************************
905  * CHAT message types START
906  ******************************************************************************/
907
908 /**
909  * Message sent from client to join a chat room.
910  */
911 #define GNUNET_MESSAGE_TYPE_CHAT_JOIN_REQUEST 300
912
913 /**
914  * Message sent to client to indicate joining of another room member.
915  */
916 #define GNUNET_MESSAGE_TYPE_CHAT_JOIN_NOTIFICATION 301
917
918 /**
919  * Message sent to client to indicate leaving of another room member.
920  */
921 #define GNUNET_MESSAGE_TYPE_CHAT_LEAVE_NOTIFICATION 302
922
923 /**
924  * Notification sent by service to client indicating that we've received a chat
925  * message.
926  */
927 #define GNUNET_MESSAGE_TYPE_CHAT_MESSAGE_NOTIFICATION 303
928
929 /**
930  * Request sent by client to transmit a chat message to another room members.
931  */
932 #define GNUNET_MESSAGE_TYPE_CHAT_TRANSMIT_REQUEST 304
933
934 /**
935  * Receipt sent from a message receiver to the service to confirm delivery of
936  * a chat message.
937  */
938 #define GNUNET_MESSAGE_TYPE_CHAT_CONFIRMATION_RECEIPT 305
939
940 /**
941  * Notification sent from the service to the original sender
942  * to acknowledge delivery of a chat message.
943  */
944 #define GNUNET_MESSAGE_TYPE_CHAT_CONFIRMATION_NOTIFICATION 306
945
946 /**
947  * P2P message sent to indicate joining of another room member.
948  */
949 #define GNUNET_MESSAGE_TYPE_CHAT_P2P_JOIN_NOTIFICATION 307
950
951 /**
952  * P2P message sent to indicate leaving of another room member.
953  */
954 #define GNUNET_MESSAGE_TYPE_CHAT_P2P_LEAVE_NOTIFICATION 308
955
956 /**
957  * P2P message sent to a newly connected peer to request its known clients in
958  * order to synchronize room members.
959  */
960 #define GNUNET_MESSAGE_TYPE_CHAT_P2P_SYNC_REQUEST 309
961
962 /**
963  * Notification sent from one peer to another to indicate that we have received
964  * a chat message.
965  */
966 #define GNUNET_MESSAGE_TYPE_CHAT_P2P_MESSAGE_NOTIFICATION 310
967
968 /**
969  * P2P receipt confirming delivery of a chat message.
970  */
971 #define GNUNET_MESSAGE_TYPE_CHAT_P2P_CONFIRMATION_RECEIPT 311
972
973 /*******************************************************************************
974  * CHAT message types END
975  ******************************************************************************/
976
977 /*******************************************************************************
978  * NSE (network size estimation) message types START
979  ******************************************************************************/
980
981 /**
982  * client->service message indicating start
983  */
984 #define GNUNET_MESSAGE_TYPE_NSE_START 321
985
986 /**
987  * P2P message sent from nearest peer
988  */
989 #define GNUNET_MESSAGE_TYPE_NSE_P2P_FLOOD 322
990
991 /**
992  * service->client message indicating
993  */
994 #define GNUNET_MESSAGE_TYPE_NSE_ESTIMATE 323
995
996 /**
997  * Type used to match 'all' message types.
998  */
999 #define GNUNET_MESSAGE_TYPE_ALL 65535
1000
1001 /*
1002   TODO:
1003   - applications (FS, VPN, TRACEKIT, TBENCH)
1004 */
1005
1006
1007
1008
1009 /* BELOW: experimental student-DHT protocol codes */
1010
1011 /**
1012  * Request to join a CAN DHT
1013  */
1014 #define GNUNET_MESSAGE_TYPE_DHT_CAN_JOIN_REQUEST 1174
1015
1016 /**
1017  * Response to join request of a CAN DHT
1018  */
1019 #define GNUNET_MESSAGE_TYPE_DHT_CAN_JOIN_REPLY 1175
1020
1021 /**
1022  * Messages for swapping locations
1023  */
1024 #define GNUNET_MESSAGE_TYPE_DHT_GET_NEIGHBOURLIST_REQUEST 1180
1025
1026 #define GNUNET_MESSAGE_TYPE_DHT_GET_NEIGHBOURLIST_RESULT 1181
1027
1028 #define GNUNET_MESSAGE_TYPE_DHT_SWAP_LOCATION_REQUEST 1182
1029
1030 #define GNUNET_MESSAGE_TYPE_DHT_SWAP_LOCATION_ACK 1183
1031
1032 /**
1033  * Freenet hello message
1034  */
1035 #define GNUNET_MESSAGE_TYPE_DHT_FREENET_HELLO 1184
1036
1037
1038 #if 0                           /* keep Emacsens' auto-indent happy */
1039 {
1040 #endif
1041 #ifdef __cplusplus
1042 }
1043 #endif
1044
1045 /* ifndef GNUNET_PROTOCOLS_H */
1046 #endif
1047 /* end of gnunet_protocols.h */