#define _DNS_H__
#include <stdint.h>
+#include <arpa/inet.h>
#define FLAG_RESPONSE 0x8000
#define FLAG_AUTHORATIVE 0x0400
#define MCAST_PORT 5353
#define CLASS_FLUSH 0x8000
+#define CLASS_UNICAST 0x8000
#define CLASS_IN 0x0001
#define MAX_NAME_LEN 8096
struct interface;
extern int cfg_proto;
+extern int cfg_no_subnet;
-void dns_send_question(struct interface *iface, const char *question, int type);
+void dns_send_question(struct interface *iface, const char *question, int type, int unicast);
void dns_init_answer(void);
void dns_add_answer(int type, const uint8_t *rdata, uint16_t rdlength, int ttl);
void dns_send_answer(struct interface *iface, const char *answer);
const char* dns_type_string(uint16_t type);
-void dns_handle_packet(struct interface *iface, uint8_t *buf, int len);
+void dns_handle_packet(struct interface *iface, struct sockaddr *s, uint16_t port, uint8_t *buf, int len);
#endif