add top level response

This commit is contained in:
xenia 2022-09-13 12:24:45 -04:00
parent df49fd6f3d
commit d77ec85675
1 changed files with 7 additions and 0 deletions

View File

@ -1708,6 +1708,13 @@ tunnel_dns(int tun_fd, int dns_fd, struct dnsfd *dns_fds, int bind_fd)
return 0;
}
/* Handle A-type query for topdomain - this allows us to actually use it for things besides
* iodine */
if (domain_len == 0 && q.type == T_A) {
handle_a_request(dns_fd, &q, 0);
return 0;
}
/* Handle A-type query for www.topdomain, for anyone that's
poking around */
if (domain_len == 4 && q.type == T_A &&