mirror of
https://github.com/pivpn/pivpn.git
synced 2024-12-20 03:40:17 +00:00
Last commit that fixes #10
This commit is contained in:
parent
63970e2678
commit
c553311efe
1 changed files with 22 additions and 14 deletions
|
@ -552,6 +552,8 @@ confOpenVPN() {
|
||||||
|
|
||||||
whiptail --title "Certificate Information" --msgbox "You will now be shown the default values for fields that will be used in the certificate. \nIt is fine to leave these as-is since only you and the clients you create will ever see this. \nHowever, if you want to change the values, simply select the ones you wish to modify." $r $c
|
whiptail --title "Certificate Information" --msgbox "You will now be shown the default values for fields that will be used in the certificate. \nIt is fine to leave these as-is since only you and the clients you create will ever see this. \nHowever, if you want to change the values, simply select the ones you wish to modify." $r $c
|
||||||
|
|
||||||
|
until [[ $CERTVALCorrect = True ]]
|
||||||
|
do
|
||||||
CERTVAL=$(whiptail --title "Certificate Information" --checklist "Choose any certificate values you want to change" $r $c 7 \
|
CERTVAL=$(whiptail --title "Certificate Information" --checklist "Choose any certificate values you want to change" $r $c 7 \
|
||||||
"COUNTRY" "= US" OFF \
|
"COUNTRY" "= US" OFF \
|
||||||
"STATE" "= CA" OFF \
|
"STATE" "= CA" OFF \
|
||||||
|
@ -607,6 +609,12 @@ confOpenVPN() {
|
||||||
$SUDO sed -i "s/\(KEY_NAME=\"\).*/\1${KEY_NAME}\"/" vars
|
$SUDO sed -i "s/\(KEY_NAME=\"\).*/\1${KEY_NAME}\"/" vars
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
if (whiptail --backtitle "Confirm Certificate Fields" --title "Confirm Certificate Fields" --yesno "Are these values correct?\n\n Country: $COUNTRY\n State: $STATE\n City: $CITY\n Org: $ORG\n Email: $EMAIL\n Server Name: $SERVER_NAME\n Key Name: $KEY_NAME" $r $c) then
|
||||||
|
CERTVALCorrect=True
|
||||||
|
else
|
||||||
|
CERTVALCorrect=False
|
||||||
|
fi
|
||||||
|
done
|
||||||
# Make PiVPN the OU
|
# Make PiVPN the OU
|
||||||
KEY_OU=PiVPN
|
KEY_OU=PiVPN
|
||||||
$SUDO sed -i "s/\(KEY_OU=\"\).*/\1${KEY_OU}\"/" vars
|
$SUDO sed -i "s/\(KEY_OU=\"\).*/\1${KEY_OU}\"/" vars
|
||||||
|
|
Loading…
Reference in a new issue