5 Example script for creating new user peer for GoVPN.
6 It generates random client's identity, ask for passphrase, generates
7 verifier and shows you example JSON entry for server configuration.
15 peerid=$(dd if=/dev/urandom bs=16 count=1 2>/dev/null | hexdump -ve '"%02x"')
16 [ $(echo -n $peerid | wc -c) = 32 ] || peerid=0"$peerid"
19 $(dirname $0)/storekey.sh $passphrase
20 verifier=$(govpn-verifier -id $peerid -key $passphrase)
27 Place the following JSON configuration entry on the server's side:
31 "up": "/path/to/up.sh",
32 "verifier": "$verifier"
35 Verifier was generated with:
37 $(dirname $0)/storekey.sh /tmp/passphrase
38 govpn-verifier -id $peerid -key /tmp/passphrase
40 Create up.sh script that will output on the first line TAP interface
41 name that must be used for the peer. For example:
51 % chmod +x /path/to/up.sh