diff options
| author | Mikhail Osipov <mike.osipov@gmail.com> | 2020-02-23 17:13:30 +0300 |
|---|---|---|
| committer | Mikhail Osipov <mike.osipov@gmail.com> | 2020-02-23 17:13:30 +0300 |
| commit | 313241616373ad01413e20758b6edb36afc2762b (patch) | |
| tree | 8e7b46c117509f70e08294b7b29dce9255385645 | |
| parent | d3e48b2676c70ef20c33d70220c4a4b22f3a0e5b (diff) | |
auth simple test
| -rwxr-xr-x | test/auth.sh | 14 | ||||
| -rwxr-xr-x | test/env.sh (renamed from test/hello.sh) | 2 |
2 files changed, 15 insertions, 1 deletions
diff --git a/test/auth.sh b/test/auth.sh new file mode 100755 index 0000000..4f822c3 --- /dev/null +++ b/test/auth.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +ROOT=$(dirname $0)/.. +PATH=$PATH:$ROOT/cmd/tunnel + +tunnel add name T 2000,listen auth 3000 +tunnel add name X 3000,listen - auth 4000 +tunnel var set tunnel.T.secret secret +tunnel var set tunnel.X.secret secret +nc -l 4000 & +echo "Hello, World!" | nc -N localhost 2000 +tunnel var clear +tunnel del T +tunnel del X diff --git a/test/hello.sh b/test/env.sh index 81dcec8..bcff497 100755 --- a/test/hello.sh +++ b/test/env.sh @@ -3,9 +3,9 @@ ROOT=$(dirname $0)/.. PATH=$ROOT/cmd/tunnel -tunnel var clear tunnel var set cmd echo tunnel var set args ^"@x, @y!" tunnel var set x Hello tunnel var set y World tunnel @cmd @args +tunnel var clear |
