From 56515f351565cbd66fa20c76a7ac297e047299c7 Mon Sep 17 00:00:00 2001 From: Jebtrix Date: Mon, 28 May 2018 17:25:45 -0400 Subject: [PATCH 1/3] [FIX] Unable to select AdGuard DNS choice --- openvpn-install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openvpn-install.sh b/openvpn-install.sh index cc05a99..e74d854 100644 --- a/openvpn-install.sh +++ b/openvpn-install.sh @@ -242,8 +242,8 @@ else echo " 7) Google (Anycast: worldwide)" echo " 8) Yandex Basic (Russia)" echo " 9) AdGuard DNS (Russia)" - while [[ $DNS != "1" && $DNS != "2" && $DNS != "3" && $DNS != "4" && $DNS != "5" && $DNS != "6" && $DNS != "7" && $DNS != "8" ]]; do - read -p "DNS [1-8]: " -e -i 1 DNS + while [[ $DNS != "1" && $DNS != "2" && $DNS != "3" && $DNS != "4" && $DNS != "5" && $DNS != "6" && $DNS != "7" && $DNS != "8" && $DNS != "9" ]]; do + read -p "DNS [1-9]: " -e -i 1 DNS done echo "" echo "See https://github.com/Angristan/OpenVPN-install#encryption to learn more about " From 0f0f1484fa94422ed8f86fe7c63de174dc88af2f Mon Sep 17 00:00:00 2001 From: Jebtrix Date: Mon, 28 May 2018 20:53:44 -0400 Subject: [PATCH 2/3] [ENHANCEMENT] Server log level option --- openvpn-install.sh | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/openvpn-install.sh b/openvpn-install.sh index e74d854..1646cc1 100644 --- a/openvpn-install.sh +++ b/openvpn-install.sh @@ -326,6 +326,15 @@ else ;; esac echo "" + echo "Choose server log level:" + echo " 1) Normal (verbose level 3)" + echo " 2) High (verbose level 4)" + echo " 3) Debug (verbose level 6)" + echo " 4) Off (verbose level 0, logs to /dev/null)" + while [[ $SERVER_LOG_LEVEL != "1" && $SERVER_LOG_LEVEL != "2" && $SERVER_LOG_LEVEL != "3" && $SERVER_LOG_LEVEL != "4" ]]; do + read -p "Server log level [1-4]: " -e -i 1 SERVER_LOG_LEVEL + done + echo "" echo "Finally, tell me a name for the client certificate and configuration" while [[ $CLIENT = "" ]]; do echo "Please, use one word only, no special characters" @@ -566,9 +575,26 @@ auth SHA256 $CIPHER tls-server tls-version-min 1.2 -tls-cipher TLS-DHE-RSA-WITH-AES-128-GCM-SHA256 -status openvpn.log +tls-cipher TLS-DHE-RSA-WITH-AES-128-GCM-SHA256" >> /etc/openvpn/server.conf + case $SERVER_LOG_LEVEL in + 1) # Normal + echo "status openvpn.log verb 3" >> /etc/openvpn/server.conf + ;; + 2) # High + echo "status openvpn.log +verb 4" >> /etc/openvpn/server.conf + ;; + 3) # Debug + echo "status openvpn.log +verb 6" >> /etc/openvpn/server.conf + ;; + 4) # Off + echo "log /dev/null +status /dev/null +verb 0" >> /etc/openvpn/server.conf + ;; + esac # Create the sysctl configuration file if needed (mainly for Arch Linux) if [[ ! -e $SYSCTL ]]; then From 6dd33b631b656b411cd76cd5886776f373495900 Mon Sep 17 00:00:00 2001 From: Angristan Date: Tue, 29 May 2018 11:00:29 +0200 Subject: [PATCH 3/3] Revert "[FIX] Unable to select AdGuard DNS choice" This reverts commit 56515f351565cbd66fa20c76a7ac297e047299c7. --- openvpn-install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openvpn-install.sh b/openvpn-install.sh index 1646cc1..e9e7e94 100644 --- a/openvpn-install.sh +++ b/openvpn-install.sh @@ -242,8 +242,8 @@ else echo " 7) Google (Anycast: worldwide)" echo " 8) Yandex Basic (Russia)" echo " 9) AdGuard DNS (Russia)" - while [[ $DNS != "1" && $DNS != "2" && $DNS != "3" && $DNS != "4" && $DNS != "5" && $DNS != "6" && $DNS != "7" && $DNS != "8" && $DNS != "9" ]]; do - read -p "DNS [1-9]: " -e -i 1 DNS + while [[ $DNS != "1" && $DNS != "2" && $DNS != "3" && $DNS != "4" && $DNS != "5" && $DNS != "6" && $DNS != "7" && $DNS != "8" ]]; do + read -p "DNS [1-8]: " -e -i 1 DNS done echo "" echo "See https://github.com/Angristan/OpenVPN-install#encryption to learn more about "