mirror of
https://github.com/rootzoll/raspiblitz.git
synced 2024-11-20 18:22:01 +01:00
repeat word entry
This commit is contained in:
parent
073ef13874
commit
b457f7e0a3
@ -271,6 +271,9 @@ or having a complete LND rescue-backup from your old node.
|
||||
# get seed word list
|
||||
if [ "${CHOICE}" == "SEED+SCB" ] || [ "${CHOICE}" == "ONLYSEED" ]; then
|
||||
|
||||
wordsCorrect=0
|
||||
while [ ${wordsCorrect} -eq 0 ]
|
||||
do
|
||||
# dialog to enter
|
||||
dialog --backtitle "RaspiBlitz - LND Recover" --inputbox "Please enter/paste the SEED WORD LIST:\n(just the words, seperated by paces, in correct order as numbered)" 9 78 2>/home/admin/.seed.tmp
|
||||
wordstring=$( cat /home/admin/.seed.tmp | sed 's/[^a-zA-Z0-9,]//g' )
|
||||
@ -281,8 +284,12 @@ or having a complete LND rescue-backup from your old node.
|
||||
IFS=' ' read -r -a seedArray <<< "$wordstring"
|
||||
if [ ${#seedArray[@]} -eq 24 ]; then
|
||||
echo "OK - 24 words"
|
||||
wordsCorrect=1
|
||||
else
|
||||
whiptail --title " WARNING " --msgbox "
|
||||
whiptail --title " WARNING " \
|
||||
--yes-button "Try Again" \
|
||||
--no-button "Cancel" \
|
||||
--yesno "
|
||||
The word list has ${#seedArray[@]} words. But it must be 24.
|
||||
Please check your list and try again.
|
||||
|
||||
@ -293,9 +300,13 @@ The Word list should look like this:
|
||||
wordone wordtweo wordthree ...
|
||||
|
||||
" 16 52
|
||||
|
||||
if [ $? -eq 1 ]; then
|
||||
/home/admin/70initLND.sh
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
# ask if seed was protected by password D
|
||||
passwordD=""
|
||||
|
Loading…
Reference in New Issue
Block a user