summaryrefslogtreecommitdiff
path: root/test/auth.sh
blob: 311b8ffabb20f7803f93a6c3537b19f91983737f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/bash

ROOT=$(dirname $0)/..
PATH=$PATH:$ROOT/cmd/tunnel

tunnel add name T 2000,listen auth aes 3000
tunnel add name X 3000,listen -aes -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