enable password checker

This commit is contained in:
Bram Prieshof
2020-04-15 12:09:57 +02:00
parent ac346dbcd1
commit 2afb8f85f2

View File

@@ -59,7 +59,7 @@ fi
function PasswordQuest { function PasswordQuest {
passdia=$(whiptail --nocancel --passwordbox "Please enter your password (Must be the same as the mysql/root password)" 11 91 --title "Config" 3>&1 1>&2 2>&3) passdia=$(whiptail --nocancel --passwordbox "Please enter your password (Must be the same as the mysql/root password)" 11 91 --title "Config" 3>&1 1>&2 2>&3)
if [ -z $passdia ]; then PasswordQuest; fi if [ -z $passdia ]; then PasswordQuest; fi
#mysql -uroot -p"$passdia" -e "" > /dev/null 2>&1 mysql -uroot -p"$passdia" -e "" > /dev/null 2>&1
if [ $? = 0 ]; then if [ $? = 0 ]; then
password="$passdia" password="$passdia"
unset passdia unset passdia
@@ -74,7 +74,7 @@ function LegacyPasswordQuest {
echo "Enter password (Must be the same as the mysql/root password)" echo "Enter password (Must be the same as the mysql/root password)"
read -s passdia read -s passdia
if [ -z $passdia ]; then LegacyPasswordQuest; fi if [ -z $passdia ]; then LegacyPasswordQuest; fi
#mysql -uroot -p"$passdia" -e "" > /dev/null 2>&1 mysql -uroot -p"$passdia" -e "" > /dev/null 2>&1
if [ $? = 0 ]; then if [ $? = 0 ]; then
echo "Password is correct" echo "Password is correct"
password="$passdia" password="$passdia"