This commit is contained in:
Jérémy Lecour 2020-05-05 15:06:15 +02:00 committed by Jérémy Lecour
parent fa5a344ef4
commit d9f866fc3a

View file

@ -212,7 +212,7 @@ verify_ca_password() {
ask_ca_password() { ask_ca_password() {
attempt=${1:-0} attempt=${1:-0}
max_attempt=3 max_attempts=3
trap 'unset CA_PASSWORD' 0 trap 'unset CA_PASSWORD' 0
@ -222,8 +222,8 @@ ask_ca_password() {
if [ "${attempt}" -gt 0 ]; then if [ "${attempt}" -gt 0 ]; then
warning "Invalid password, retry." warning "Invalid password, retry."
fi fi
if [ "${attempt}" -ge "${max_attempt}" ]; then if [ "${attempt}" -ge "${max_attempts}" ]; then
error "Maximum number of attempts reached (${max_attempt})." error "Maximum number of attempts reached (${max_attempts})."
fi fi
if [ -z "${CA_PASSWORD}" ]; then if [ -z "${CA_PASSWORD}" ]; then
stty -echo stty -echo