Skip to content

Instantly share code, notes, and snippets.

@stkchp
Last active July 26, 2016 13:00
Show Gist options
  • Select an option

  • Save stkchp/aa61ed5ac23f22a80bb7da54d62c3ce7 to your computer and use it in GitHub Desktop.

Select an option

Save stkchp/aa61ed5ac23f22a80bb7da54d62c3ce7 to your computer and use it in GitHub Desktop.
crazy patch
--- dnsmasq-2.76/src/forward.c
+++ dnsmasq-2.76/src/forward.c
@@ -781,8 +781,8 @@
daemon->log_display_id = forward->log_id;
daemon->log_source_addr = &forward->source;
- if (daemon->ignore_addr && RCODE(header) == NOERROR &&
- check_for_ignored_address(header, n, daemon->ignore_addr))
+ if (RCODE(header) == NOERROR &&
+ check_for_ignored_address(header, n, NULL))
return;
/* Note: if we send extra options in the EDNS0 header, we can't recreate
--- dnsmasq-2.76/src/rfc1035.c
+++ dnsmasq-2.76/src/rfc1035.c
@@ -1037,9 +1037,7 @@
if (!CHECK_LEN(header, p, qlen, INADDRSZ))
return 0;
- for (baddrp = baddr; baddrp; baddrp = baddrp->next)
- if (memcmp(&baddrp->addr, p, INADDRSZ) == 0)
- return 1;
+ return 1;
}
if (!ADD_RDLEN(header, p, qlen, rdlen))
@stkchp
Copy link
Author

stkchp commented Jul 7, 2016

no response if ipv4 any data...

@stkchp
Copy link
Author

stkchp commented Jul 26, 2016

Finally, instead of this patch, i use unbound and write "private-address:0.0.0.0/0" to unbound.conf.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment