vtun

command module
v1.2.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 26, 2021 License: MIT Imports: 4 Imported by: 0

README

vtun

A simple vpn.

Travis Go Report Card image image

Usage

Usage of ./vtun:
  -S    server mode
  -c string
        tun interface CIDR (default "172.16.0.1/24")
  -k string
        encryption key (default "6w9z$C&F)J@NcRfWjXn3r4u7x!A%D*G-")
  -l string
        local address (default "0.0.0.0:3000")
  -s string
        server address (default "0.0.0.0:3001")

Client

sudo ./vtun -l=:3000 -s=server-addr:3001 -c=172.16.0.10/24 -k=123456

Server

sudo ./vtun -S -l=:3001 -c=172.16.0.1/24 -k=123456

Enable IP forwarding on server

sudo sysctl -w net.ipv4.conf.vtun.route_localnet=1
sudo sysctl -w net.ipv4.conf.vtun.rp_filter=0
sudo sysctl -w net.ipv4.conf.all.rp_filter=0
sudo sysctl -w net.ipv4.ip_forward=1
sudo sysctl -p

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
common

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL