1 .\" groff -man -Tascii iodine.8
2 .TH IODINE 8 "JUL 2008" "User Manuals"
4 iodine, iodined \- tunnel IPv4 over DNS
30 .B iodined [-c] [-s] [-f] [-D] [-u
56 lets you tunnel IPv4 data through a DNS
57 server. This can be useful in situations where Internet access is firewalled,
58 but DNS queries are allowed. It needs a TUN/TAP device to operate. The
59 bandwidth is asymmetrical with limited upstream and up to 1 Mbit/s downstream.
61 is the client application,
68 Print version info and exit.
71 Print usage info and exit.
74 Keep running in foreground.
77 Drop privileges and run as user 'user' after setting up tunnel.
80 Chroot to 'chrootdir' after setting up tunnel.
83 Use the TUN device 'device' instead of the normal one, which is dnsX on Linux
87 Use 'password' to authenticate. If not used,
89 will be used as input. Only the first 32 characters will be used.
93 Maximum downstream fragsize. Not setting this will cause the client to probe
94 the maximum accepted downstream packet size.
98 Disable checks on client IP on all incoming requests.
101 Don't try to configure IP address or MTU. This should only be used if
102 you have already configured the device that will be used.
105 Increase debug level. Level 1 prints info about each RX/TX packet.
108 Set 'mtu' as mtu size for the tunnel device. This will be sent to the client
109 on connect, and the client will use the same mtu.
112 Make the server listen only on 'listen_ip' instead of on 0.0.0.0 for incoming
116 Make the server listen on 'port' instead of 53 for traffic.
118 You must make sure the dns requests are forwarded to this port yourself.
121 The IP address to return in NS responses. Default is to return the address used
122 as destination in the query.
125 If this port is specified, all incoming requests not inside the tunnel domain
126 will be forwarded to this port on localhost, to be handled by a real dns.
127 .SS Client Arguments:
130 The nameserver to use to relay the dns traffic. This can be any relaying
131 nameserver or the ip number of the server running iodined if reachable.
132 This argument is optional, and if not specified a nameserver will be read
138 The dns traffic will be sent as querys of type NULL for subdomains under
139 \'topdomain'. This is normally a subdomain to a domain you own. Use a short
140 domain name to get better throughput. If
142 is the iodined server, then the topdomain can be chosen freely. This argument
143 must be the same on both the client and the server.
144 .SS Server Arguments:
146 .B tunnel_ip[/netmask]
147 This is the servers ip address on the tunnel interface. The client will be
148 given the next ip number in the range. It is recommended to use the
149 10.0.0.0 or 172.16.0.0 ranges. The default netmask is /27, can be overriden
150 by specifying it here. Using a smaller network will limit the number of
154 The dns traffic will is expected to be sent as querys of type NULL for
155 subdomains under 'topdomain'. This is normally a subdomain to a domain you
156 own. Use a short domain name to get better throughput. This argument must be
157 the same on both the client and the server.
161 Try it out within your own LAN! Follow these simple steps:
163 - On your server, run: ./iodined \-f 10.0.0.1 test.asdf
164 (If you already use the 10.0.0.0 network, use another internal net like
169 - On the client, run: ./iodine \-f 192.168.0.1 test.asdf
170 (Replace 192.168.0.1 with the server's ip address)
172 - Enter the same password
174 - Now the client has the tunnel ip 10.0.0.2 and the server has 10.0.0.1
176 - Try pinging each other through the tunnel
180 To actually use it through a relaying nameserver, see below.
185 To use this tunnel, you need control over a real domain (like mytunnel.com),
186 and a server with a public IP number. If the server already runs a DNS
187 server, change the listening port and then use the \-b option to let
188 iodined forward the DNS requests. Then, delegate a subdomain
189 (say, tunnel1.mytunnel.com) to the server. If you use BIND for the domain,
190 add these lines to the zone file (replace 10.15.213.99 with your server ip):
193 tunnel1host IN A 10.15.213.99
194 tunnel1 IN NS tunnel1host.mytunnel.com.
197 Now any DNS querys for domains ending with tunnel1.mytunnnel.com will be sent
198 to your server. Start iodined on the server. The first argument is the tunnel
199 IP address (like 192.168.99.1) and the second is the assigned domain (in this
200 case tunnel1.mytunnel.com). The \-f argument will keep iodined running in the
201 foreground, which helps when testing. iodined will start a virtual interface,
202 and also start listening for DNS queries on UDP port 53. Either enter a
203 password on the commandline (\-P pass) or after the server has started. Now
204 everything is ready for the client.
207 All the setup is done, just start iodine. It also takes two
208 arguments, the first is the local relaying DNS server and the second is the
209 domain used (tunnel1.mytunnnel.com). If DNS queries are allowed to any
210 computer, you can use the tunnel endpoint (example: 10.15.213.99 or
211 tunnel1host.mytunnel.com) as the first argument. The tunnel interface will get
212 an IP close to the servers (in this case 192.168.99.2) and a suitable MTU.
213 Enter the same password as on the server either by argument or after the client
214 has started. Now you should be able to ping the other end of the tunnel from
218 The normal case is to route all traffic through the DNS tunnel. To do this, first
219 add a route to the nameserver you use with the default gateway as gateway. Then
220 replace the default gateway with the servers IP address within the DNS tunnel,
221 and configure the server to do NAT.
224 These issues should be solved now, with automatic fragmentation of downstream
225 packets. There should be no need to set the MTU explicitly on the server.
227 File bugs at http://dev.kryo.se/iodine/
229 Erik Ekman <yarrick@kryo.se> and Bjorn Andersson <flex@kryo.se>