Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tun_playground

Virtual network over a UDP tunnel PoC demonstration.

Usage(WIP)

Server

tun_playground --tun tunserver1 --virtual 10.0.0.1 --port 55555

Client (--gw public IP for routing packets to unknown peers in the virtual subnet)

tun_playground --tun tunclient1 --virtual 10.0.0.2 --port 55555 --gw <IP:port>

Performance

Benchmarked using iperfwith baseline throughput (directly) of 93Mbit/s achieved a throughput of 82Mbit/s on a local 100Mbit/s rated wired connection.

iperf -c 10.0.0.1 -t 30 -i 10 -P 8

TODO

  • Multithreading support
  • IP_MULTI_QUEUE support
  • Routing for multiple clients
  • Benchmarking tests & nix / std / socket2 / raw performance comparison
  • Separate readable & writeable Interest handling with a user-space write buffer
  • Implement keepalive option for NAT tunneling
  • Daemonize

Extensions

  • NAT traversal for P2P connections
  • WireGuard protocol implementation

Platforms

Tested on:

x86_64-unknown-linux-gnu
aarch64-linux-android (*)

* Through Termux on a rooted Android. Works either built with cross or termux distributed package rust.

Notes

iperf3 has a buggy TCP handshake code, reverted to iperf (version 2)

About

UDP network tunnel using a TUN interface

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages