2 This file is part of GNUnet.
3 (C) 2010 Christian Grothoff
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 3, or (at your
8 option) any later version.
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.
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.
22 * @file vpn/gnunet-daemon-vpn-dns.h
24 * @author Philipp Toelke
26 #ifndef GNUNET_DAEMON_VPN_DNS_H
27 #define GNUNET_DAEMON_VPN_DNS_H
30 * a list of outgoing dns-query-packets
32 extern struct query_packet_list *head;
35 * The last element of the list of outgoing dns-query-packets
37 extern struct query_packet_list *tail;
40 * Callback called by notify_transmit_ready; sends dns-queries or rehijack-messages
43 size_t send_query(void* cls, size_t size, void* buf);
46 * Connect to the service-dns
48 void connect_to_service_dns (void *cls,
49 const struct GNUNET_SCHEDULER_TaskContext *tc);
52 * This receives packets from the service-dns and schedules process_answer to
55 void dns_answer_handler(void* cls, const struct GNUNET_MessageHeader *msg);
58 * The connection to the service-dns
60 extern struct GNUNET_CLIENT_Connection *dns_connection;
63 * A flag to show that the service-dns has to rehijack the outbound dns-packets
65 * This gets set when the helper restarts as the routing-tables are flushed when
66 * the interface vanishes.
68 extern unsigned char restart_hijack;
71 * A list of processed dns-responses.
73 * "processed" means that the packet is complete and can be sent out via udp
76 extern struct answer_packet_list *answer_proc_head;
79 * The last element of the list of processed dns-responses.
81 extern struct answer_packet_list *answer_proc_tail;
83 extern GNUNET_SCHEDULER_TaskIdentifier conn_task;
85 #endif /* end of include guard: GNUNET-DAEMON-VPN-DNS_H */