TCP over DNS



tcp-over-dns contains a special dns server and a special dns client. The client and server work in tandem to provide a TCP (and UDP!) tunnel through the standard DNS protocol.

Features:
  • Windows, Linux, Solaris compatibility (BSD/OSX reports are welcome) (Anything with a Java 6 VM)
  • Sliding window packet transfers for increased speed and reliability.
  • Runtime selective LZMA compression.
  • TCP and UDP traffic tunneling.
Software Requirements:
  • Java runtime environment 6.0+
  • Server requires root/admin port 53 access.
Download Java Devlopment Kit (JDK)
http://java.sun.com/javase/downloads/index.jsp
pilih: Java SE Development Kit (JDK) - JDK 6 Update 14
ada 2 macam: jdk-6u14-linux-i586-rpm.bin dan jdk-6u14-linux-i586.bin

Install Java Devlopment Kit (JDK)
root@lare_ndusun:~# chmod a+x jdk-6u14-linux-i586-rpm.bin
root@lare_ndusun:~# ./jdk-6u14-linux-i586-rpm.bin
or
root@lare_ndusun:~# chmod a+x jdk-6u14-linux-i586.bin
root@lare_ndusun:~# ./jdk-6u14-linux-i586.bin

Domain Setting
domain1: orek2an.com A 64.233.189.191
domain2: orek2an-dns-tunnel.com NS orek2an.com
64.233.189.191 = IP server
http://freedns.afraid.org (GRATIS)

Command
server:
java -jar tcp-over-dns-server.jar --domain orek2an-dns-tunnel.com --forward-port 22
forward port bisa yang lain

client:
java -jar tcp-over-dns-client.jar --domain orek2an-dns-tunnel.com --listen-port 60022 --interval 100
listen port bisa yang lain, nilai interval bisa yang lain

Available options:
--domain


--dns-server


--listen-port

--listen-address


--interval

--mtu

--trunc-bytes

--log-level
a.b.com


a.b.c.d


portNum

a.b.c.d


time

bytes

bytes

0-5
The domain name that the dns server is sitting behind. This must match the server's domain argument.
Add a dns server to tunnel through. Overrides default servers. This option may be specified multiple times.
The port the client should listen on. Defaults to port 8080.
The address on which to listen for local connections. Defaults to all addresses.
The delay between sending packets, in milliseconds. Defaults to 200.
Set the udp maximum MTU. Defaults to 1500.
Tell the server to prevent truncation by sending less data when answering queries. Defaults to 0.
The amount of information to display. Defaults to 3.
0: Display nothing.
1: Display errors.
2: Display errors, warnings.
3: Display errors, warnings, general information.
4: Spam.
5: Megaspam.
NB:
I use CentOS.

8 comment: