[Dnsmasq-discuss] DNS64 support
Jima
jima at beer.tclug.org
Tue Dec 28 18:01:21 GMT 2010
First off, I understand if this notion gets shot down real fast; it's a
bit of a corner case (although maybe not so much in coming months).
With IPv4 address depletion looming (IANA in the next 2 months, the
first RIR likely before the end of 2011), I'm in the process of
experimenting with a NAT64 environment, a way for IPv6-only clients to
interact with IPv4 networks without a proxy. One of the steps required
is to enable DNS64. There are several pieces of software that can do
this, but it crossed my mind that since dnsmasq can already replace A
results, it might not be terribly involved to adapt it to add the
ability to replace them with AAAA results (rather than add another
daemon that might require ongoing TLC), but that ran into a stumbling
block: I'm REALLY rusty with C.
Ultimately, from my understanding, what DNS64 requires is replacing any
A responses with AAAA, with an IPv6 /96 prepended to the address from
the A record (i.e., 192.168.1.1 -> 2001:db8:ffff::192.168.1.1).
(Additionally, it might be prudent to drop the AA bit like --alias'd
results do; I'm not certain.) That /96 is then routed to a NAT64 router
via IPv6, which translates the traffic to IPv4.
As best as I can tell, the ideal place to do the magic is probably
within do_doctor() in src/rfc1035.c. Alas, the part I'm having trouble
grokking is how to switch qtype from T_A to T_AAAA in the resultant
packet. (Okay, and other parts, but that's the main blocker for me.)
I welcome any insights others might have, and I understand that the
best move may very well be to use something designed specifically for
this use case.
Thanks in advance; have a nice day.
Jima
More information about the Dnsmasq-discuss
mailing list