Fixed crash when using single quotes in encryption password.

This commit is contained in:
2026-01-29 19:18:24 -05:00
parent 2af076e6c0
commit 42591e44b0

View File

@@ -191,7 +191,7 @@ prompt() {
print "$prompt_msg" print "$prompt_msg"
read -r response read -r response
eval "$var_name='$response'" eval "$var_name='${response//\'/\'\\\'\'}'"
} }
# Prompt for secret input (no echo) # Prompt for secret input (no echo)
@@ -206,7 +206,7 @@ prompt_secret() {
print "$prompt_msg" print "$prompt_msg"
read -rs response read -rs response
echo echo
eval "$var_name='$response'" eval "$var_name='${response//\'/\'\\\'\'}'"
} }
# Prompt for password with confirmation # Prompt for password with confirmation
@@ -234,7 +234,7 @@ prompt_password() {
return 1 return 1
fi fi
eval "$var_name='$password'" eval "$var_name='${password//\'/\'\\\'\'}'"
unset password password_confirm unset password password_confirm
return 0 return 0
} }