HUSH DNS Seed https://hush.is
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

31 lines
658 B

// Copyright (c) 2018-2021 The Hush developers
// Distributed under the GPLv3 software license, see the accompanying
// file LICENSE or https://www.gnu.org/licenses/gpl-3.0.en.html
#ifndef _DNS_H_
#define _DNS_H_ 1
#include <stdint.h>
typedef struct {
int v;
union {
unsigned char v4[4];
unsigned char v6[16];
} data;
} addr_t;
typedef struct {
int port;
int datattl;
int nsttl;
const char *host;
const char *ns;
const char *mbox;
int (*cb)(void *opt, char *requested_hostname, addr_t *addr, int max, int ipv4, int ipv6);
// stats
uint64_t nRequests;
} dns_opt_t;
extern int dnsserver(dns_opt_t *opt);
#endif