tlstun

simple go program to add tls support to other listeners
git clone https://git.parazyd.org/tlstun
Log | Files | Refs | README | LICENSE

commit ea0fec9f844e309b25c944e503057fbd43a5264e
parent c808513eecdeaaff1673909cf3bb9fe6550ab200
Author: parazyd <parazyd@dyne.org>
Date:   Wed, 13 Feb 2019 21:25:06 +0100

Shorten commandline flags.

Diffstat:
MREADME.md | 12+++++-------
Mtlstun.go | 10+++++-----
2 files changed, 10 insertions(+), 12 deletions(-)

diff --git a/README.md b/README.md @@ -24,15 +24,13 @@ Usage ``` Usage of ./tlstun: - -cert string + -c string Path for Certificate file (default "server.pem") - -forward string + -f string Forward address (default "127.0.0.1:72") - -key string + -k string Path for Key file (default "server-key.pem") - -listen string + -l string Listen address (default "127.0.0.1:7443") - -verbose - Verbose mode - + -v Verbose mode ``` diff --git a/tlstun.go b/tlstun.go @@ -29,11 +29,11 @@ import ( ) var ( - cert = flag.String("cert", "server.pem", "Path for Certificate file") - key = flag.String("key", "server-key.pem", "Path for Key file") - listen = flag.String("listen", "127.0.0.1:7443", "Listen address") - forward = flag.String("forward", "127.0.0.1:72", "Forward address") - verbose = flag.Bool("verbose", false, "Verbose mode") + cert = flag.String("c", "server.pem", "Path for Certificate file") + key = flag.String("k", "server-key.pem", "Path for Key file") + listen = flag.String("l", "127.0.0.1:7443", "Listen address") + forward = flag.String("f", "127.0.0.1:72", "Forward address") + verbose = flag.Bool("v", false, "Verbose mode") ) func tlsConfig(cert, key string) (*tls.Config, error) {