Skip to content

mythosking/udptun

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

UDPTUN

Simple UDP Tunnel program.

Usage

Client:

sudo ./client.elf -s <server_ip>

After client up and running, route packet into the network interface called clienttun which created by this program. For example:

route add default dev clienttun # this will route all your traffic into clienttun
route add 123.123.123.123 clienttun # or like this, route traffic of a specify ip (123.123.123.123)
route add <server_ip> gw <your_gateway_ip> dev <your_original_eth_dev> # use `route -n` to see your gateway

Server:

sudo ./server.elf

Server will create a tun named servertun. If you'd like to watch the traffic:

tcpdump -i servertun -vv -n

FYI

This is a learning purpose program. May contains bug.

Associate blog about this program: cnblogs:Make a simple udp-tunnel program (Chinese).

About

Simple UDP tunnel

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 61.9%
  • C 33.9%
  • Makefile 4.2%