yarrick / iodine

Official git repo for iodine dns tunnel
https://code.kryo.se/iodine
ISC License
6.25k stars 507 forks source link

Connectivity errors between two linux machines #71

Closed kqvanity closed 2 years ago

kqvanity commented 2 years ago

I'm trying to connect two linux machine via dns tunneling. I've setup duckdns dynamic dns subdomain i.e. crappyhorse.duckdns.org on the server machine, and i also registered a free domain name at freenom with the current dns configuration. The command i issue at the server is

$ sudo iodined -f -c -P justphrase 192.168.99.1 t.vodafonegenericavail.cf
Opened dns0
Setting IP of dns0 to 192.168.1.7
Setting MTU of dns0 to 1130
Opened IPv4 UDP socket
Listening to dns for domain t.vodafonegenericavail.cf

$ sudo iodine -f -P justphrase t.vodafonegenericavail.cf
Opened dns0
Opened IPv4 UDP socket
Sending DNS queries for t.vodafonegenericavail.cf to 127.0.0.53
Autodetecting DNS query type (use -T to override).iodine: Got NOTIMP as reply: server does not support our request
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NOTIMP as reply: server does not support our request
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NOTIMP as reply: server does not support our request
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist
.iodine: Got NXDOMAIN as reply: domain does not exist

iodine: No suitable DNS query type found. Are you connected to a network?
iodine: If you expect very long roundtrip delays, use -T explicitly.
iodine: (Also, connecting to an "ancient" version of iodined won't work.)

$ dig t.vodafonegenericavail.cf

; <<>> DiG 9.16.1-Ubuntu <<>> t.vodafonegenericavail.cf
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 27729
;; flags: qr rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 65494
;; QUESTION SECTION:
;t.vodafonegenericavail.cf. IN  A

;; ANSWER SECTION:
t.vodafonegenericavail.cf. 3600 IN  CNAME   dnsrecord.vodafonegenericavail.cf.
dnsrecord.vodafonegenericavail.cf. 3599 IN CNAME crappyhorse.duckdns.org.
crappyhorse.duckdns.org. 59 IN  A   41.36.193.3

;; Query time: 219 msec
;; SERVER: 127.0.0.53#53(127.0.0.53)
;; WHEN: Tue Mar 15 15:02:53 EET 2022
;; MSG SIZE  rcvd: 131

The output of https://code.kryo.se/iodine

Troubleshoot your iodine setup

Analyzing DNS setup for tunnel domain 't.vodafonegenericavail.cf'... (might take some time)

Looking for nameserver for vodafonegenericavail.cf.. got ns04.freenom.com (at 104.155.29.241).
Resolving delegation of t.vodafonegenericavail.cf at 104.155.29.241... not known.

Error: The tunnel name t.vodafonegenericavail.cf is not delegated to any host according to nameserver ns04.freenom.com.

I'm currently incapable of getting my head around what's the culprit of the problem or wrong with this setup. Any ideas ?

yarrick commented 2 years ago

The tunnel domain name should be an NS record, not a CNAME record.