for w32 port
[oweals/gnunet.git] / src / include / gnunet_block_dns.h
1 #ifndef _GNVPN_BLOCKDNS_H_
2 #define _GNVPN_BLOCKDNS_H_
3
4 #include "gnunet_common.h"
5
6 /**
7  * Bitmask describing what ip-services are supported by services
8  * It is 2 bytes long
9  */
10 struct GNUNET_ipservices {
11   unsigned UDP:1 GNUNET_PACKED;
12   unsigned TCP:1 GNUNET_PACKED;
13   unsigned RESERVED:14 GNUNET_PACKED;
14 };
15
16 /**
17  * This is the structure describing an dns-record such as www.gnunet.
18  */
19 struct GNUNET_DNS_Record
20 {
21   /**
22    * The peer providing this service
23    */
24   struct GNUNET_PeerIdentity peer;
25
26   /**
27    * The descriptor for the service
28    * (a peer may provide more than one service)
29    */
30   GNUNET_HashCode service_descriptor;
31
32   /**
33    * What connection-types (UDP, TCP, ...) are supported by the service
34    */
35   struct GNUNET_ipservices connectiontypes;
36
37   /**
38    * The length of the name of the service
39    */
40   unsigned char namelen;
41
42   /**
43    * The name of the service
44    * This is namelen bytes
45    */
46   char name[1];
47 };
48
49 #endif