mirror of
https://github.com/angristan/wireguard-install.git
synced 2024-10-31 18:52:31 +00:00
Use a random port for Wireguard server
This commit is contained in:
parent
7a360c668e
commit
2ede16075e
@ -52,7 +52,8 @@ read -rp "Server's WireGuard IPv4 " -e -i "$SERVER_WG_IPV4" SERVER_WG_IPV4
|
|||||||
SERVER_WG_IPV6="fd42:42:42::1"
|
SERVER_WG_IPV6="fd42:42:42::1"
|
||||||
read -rp "Server's WireGuard IPv6 " -e -i "$SERVER_WG_IPV6" SERVER_WG_IPV6
|
read -rp "Server's WireGuard IPv6 " -e -i "$SERVER_WG_IPV6" SERVER_WG_IPV6
|
||||||
|
|
||||||
SERVER_PORT=51820
|
# Generate random number within private ports range
|
||||||
|
SERVER_PORT=$(shuf -i49152-65535 -n1)
|
||||||
read -rp "Server's WireGuard port " -e -i "$SERVER_PORT" SERVER_PORT
|
read -rp "Server's WireGuard port " -e -i "$SERVER_PORT" SERVER_PORT
|
||||||
|
|
||||||
CLIENT_WG_IPV4="10.66.66.2"
|
CLIENT_WG_IPV4="10.66.66.2"
|
||||||
|
Loading…
Reference in New Issue
Block a user