Skip to content

Trutun creates secret tunnel by IP address using Teonet TRU transport.

License

Notifications You must be signed in to change notification settings

teonet-go/trutun

Folders and files

NameName
Last commit message
Last commit date

Latest commit

33f2f07 · Sep 2, 2023

History

28 Commits
Sep 2, 2023
May 30, 2022
May 30, 2022
May 31, 2022
Jul 28, 2022
Jul 28, 2022
Sep 2, 2023
May 30, 2022

Repository files navigation

Teonet TRU tunnel

Trutun creates secret tunnel by IP address using Teonet TRU transport. TRU create reliable, low latency and encrypted channel between connected peers.

GoDoc Go Report Card

Usage example

Create regular tunnel between two hosts

Server:

# Start tunnel server
TRU=tru1 && sudo go run ./cmd/trutun -name=$TRU -p=9000 -loglevel=Debug -stat -hotkey

# Post connect commands, run it in other terminal
TRU=tru1 && sudo ip addr add 10.1.1.10/24 dev $TRU && sudo ip link set up dev $TRU

Client:

# Start tunnel client
TRU=tru2 && sudo go run ./cmd/trutun -name=$TRU -a=host.name:9000 -loglevel=Debug -stat -hotkey

# Post connect commands, run it in other terminal
TRU=tru2 && sudo ip addr add 10.1.1.11/24 dev $TRU && sudo ip link set up dev $TRU

You can simplify this commands by using post connection parameter and predefined shell script if_up.sh

Server:

# Start tunnel server
TRU=tru1 && sudo go run ./cmd/trutun -name=$TRU -p=9000 -loglevel=Debug -stat -hotkey -pc="./if_up.sh $TRU 10.1.1.10/24"

Client:

# Start tunnel client
TRU=tru2 && sudo go run ./cmd/trutun -name=$TRU -a=host.name:9000 -loglevel=Debug -stat -hotkey -pc="./if_up.sh $TRU 10.1.1.11/24"

Parameters -loglevel=Debug, -stat, -hotkey are unnessesary and you can remove it from Start tunnel parameters. They are used to show statistic and log information.

License

BSD