goniz / dtunnel

A Simple plaintext L2/L3 Tunnel written in D using TunTap/Linux

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

dtunnel

A simple Layer2/3 tunnel created in D for educational purposes.

  • TCP is used briefly for establishing the tunnel
  • UDP is used for the tunnel itself.
  • tun.ko (/dev/net/tun) is used for the virtual interface.

development

  • linux (archlinux)
  • MonoDevelop (5.9.5)
  • dmd compiler (v2.068)
  • tun driver (1.6)

usage

  • sudo ./DTunnel -d {tap/tun} -m {client/server} -i {ip/hostname} -p {port}

example

Server: (192.168.1.5)

  • sudo ./DTunnel -d tap -m server -p 9999
  • sudo ifconfig tap0 1.1.1.1/24
  • sudo ifconfig tap0 mtu 1300

Client: (192.168.1.6)

  • sudo ./DTunnel -d tap -m client -i 192.168.1.5 -p 9999
  • sudo ifconfig tap0 1.1.1.2/24
  • sudo ifconfig tap0 mtu 1300

About

A Simple plaintext L2/L3 Tunnel written in D using TunTap/Linux


Languages

Language:D 100.0%