Ник | Пост | Дата | |||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Quiescence | As the title says, I can’t seem to connect to provider that has DNS cookies. For example this DNS Dig response it like this:
Is there any solutions for it to work? When using a DNS provider like Quad9, it works well, but when using DNS provider that has cookies it wont work. | 2024-05-10T07:00:43.921Z | |||||||||||||||||||||||||||||||||||||||
tango | Thanks for this report. I also cannot make a tunnel work with I am not sure the problem is caused by DNS cookies, though. For one thing, when I query 76.76.19.19 without a client cookie (
But also, I’ve only found one computer where querying 76.76.19.19 works at all. From other computers, I get
If I add some debugging logs to dnstt-client, I can see that its queries are getting the same kind of
I get logs like this:
The important thing to notice is After a quick look, I wasn’t able to find another public recursive DNS resolver that support DNS cookies. My question for you:
| 2024-05-13T03:00:17.793Z | |||||||||||||||||||||||||||||||||||||||
Quiescence | I’ll try that, also i have more DNS IP that has Cookies also doesn’t work with DNSTT. Could you check these too on your end? | 2024-05-18T07:30:35.310Z | |||||||||||||||||||||||||||||||||||||||
Quiescence | I tried it just now, and compared it to UDP dns ip that is working. Results
While on both
Edit: Edit 1.1: My question, do other DNS record would be supported in future? | 2024-05-18T08:56:16.877Z | |||||||||||||||||||||||||||||||||||||||
tango | Thank you for the detailed test results. I tested 124.6.190.249 and 124.6.190.88. The problem is that their limit on the size of is smaller than the default assumed by dnstt-server. The default is 1232 and these resolvers only support 512 or 1220. To solve the problem, provide the command line option dnstt-server -mtu 512 -udp addr:port -privkey-file filename domain upstreamaddr:upstreamport The MTU issue is lightly documented at the home page and in the dnstt-server man page, but reading them just now, the documentation on this point is not clear and should be improved. More detailsThe problem is not with TXT resource records. Both 124.6.190.249 and 124.6.190.88 can do TXT records:
The clue is actually this: ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags:; udp: 1220 This number 1220 is the maximum size of a UDP packet the resolver is able to receive. The default assumed by dnstt-server is 1232 bytes, which is a compromise between performance and compatibility. But I tried The symptom of the MTU problem is
With 124.6.190.249 as a resolver I see a mix of 512 and 1220:
In either case, Ideally it would be possible to have the MTU be determined dynamically on the server according to the capabilities of each resolver. I think it’s possible, but it’s not trivial to implement, because the MTU is a global option of KCP. You can see some general discussion on this point here:
| 2024-05-18T16:34:13.524Z | |||||||||||||||||||||||||||||||||||||||
tango |
No, currently I have no plans to use other resource types. TXT seems to be widely supported by resolvers, and TXT permits low-overhead and high-capacity encoding of downstream data. Another DNS tunnel implementation, dnscat2, supports multiple resource types: TXT, MX, CNAME, A, AAAA. The ones other than TXT are somewhat less efficient (A and AAAA are much less efficient). My estimation is that the potential added flexibility is not worth an increase in complexity. | 2024-05-18T16:44:33.187Z | |||||||||||||||||||||||||||||||||||||||
Quiescence | That was impormative, So the problem is the server-side, by optimizing MTU… I wouldn’t expect MTU would solve this problem, I guess my suspicion of cookies and TXT records is an utter miss, although its weird how i got SERVFAIL when querying TXT using my domain but when using other resolver doesn’t appear to have problem at all. I guess i have to grind and read more of documentations. Anyways, Thanks for this tunneling tool, it helps me bypass ISP’s firewall. I’ll just comment here after i test the MTU adjustments on my server’s end, and make it work on mine… One last Question, Do MTU affects the speed of the tunneling? Or DNS tunneling is just slow as it is? If you’re gonna compare the speed of ICMP tunneling to DNS, which of them would go smoother/faster? (Sorry if its quite unrelated) | 2024-05-18T17:18:56.250Z | |||||||||||||||||||||||||||||||||||||||
tango |
dnstt-server will return an NXDOMAIN for TXT queries that don’t make sense or cannot be decoded. Maybe the recursive resolver converts the NXDOMAIN to a SERVFAIL. DNS tunnels are just generally slower than other circumvention techniques. dnstt is faster than other tunnels, but it can never be as fast as a TCP Shadowsocks proxy, or something like that. The MTU does affect performance. That’s why the default is 1232, and not 512 which would be compatible with more resolvers by default. The MTU limits the amount of data that can be returned in each DNS response. The problem is that DNS is a 1-to-1 query–response protocol. The client needs to send a query for each response. So if less data can fit into a response, that not only means more DNS traffic in the downstream direction (responses), but also more traffic in the upstream direction (queries). DNS tunnel performance is also highly dependent on the resolver. Some resolvers are slow, some resolvers are fast. Even difference protocols from the same provider can have different performance. The last time I tested it, Google DoT was slow while Google DoH was fast. Here’s an excerpt from some download speed tests in 2021. The numbers may have changed since then, but this gives you an idea of how variable it can be.
| 2024-05-18T18:17:03.506Z | |||||||||||||||||||||||||||||||||||||||
tango |
I don’t have experience with ICMP tunnels, but I would guess an ICMP tunnel could go faster than a DNS tunnel. The main reason is the upstream data capacity: in DNS, there is not really any place to encode upstream data (that I know of) other than the QNAME, and that is very limited in size. You can only send about 100 bytes of encoded data per query. Downstream is not so bad, with TXT you can encode data up to the MTU with little overhead. In ICMP, I think the data payloads can be arbitrary binary strings, and there’s no asymmetry between upstream/downstream. The reason why I think DNS is interesting for circumvention, and ICMP is not, is that with DNS there are recursive resolvers, which act as network-layer proxies so you don’t contact the circumvention server directly. As far as I know, there’s no such thing as an ICMP proxy or ICMP forwarder that could do the same for ICMP. (Even if there were such things, they would probably not be used for much, which means a censor could easily block them.) And with DNS, there are encrypted transports like DoH and DoT. encrypted DNS, which hides the contents of DNS messages from a censor. There’s nothing like that for ICMP, which means that ICMP tunneling would only work against a naive censor that doesn’t know to look at packet payloads. Without DNS encryption, it’s easy to identify DNS tunnels by looking at the message payloads. | 2024-05-18T18:37:29.690Z |