From fb198b17e29de739482a52b05f24f523d4d1c95c Mon Sep 17 00:00:00 2001 From: Richard T Bonhomme Date: Tue, 29 Nov 2022 23:34:46 +0000 Subject: [PATCH 1/2] Remove global options '--verbose' and '--quiet' as not required Signed-off-by: Richard T Bonhomme --- easyrsa3/easyrsa | 31 ++++++++----------------------- 1 file changed, 8 insertions(+), 23 deletions(-) diff --git a/easyrsa3/easyrsa b/easyrsa3/easyrsa index 77fe729..7098716 100755 --- a/easyrsa3/easyrsa +++ b/easyrsa3/easyrsa @@ -457,7 +457,6 @@ General options: --batch : Set automatic (no-prompts when possible) mode --silent|-s : Disable all warnings, notices and information --sbatch : Combined --silent and --batch operating mode ---quiet|-q : Quiet mode, disable information messages only --no-pass : Do not use passwords Can not be used with --passin or --passout @@ -548,29 +547,19 @@ $1 # informational notices to stdout notice() { [ "$EASYRSA_SILENT" ] && return - [ "$EASYRSA_BATCH" ] && return print " Notice ------ -$1 -" +$1" } # => notice() # Helpful information information() { [ "$EASYRSA_SILENT" ] && return - [ "$EASYRSA_BATCH" ] && return - [ "$EASYRSA_QUIET" ] && return print " * $1" } # => information() -# Verbose status reports -verbose() { - [ "$EASYRSA_VERBOSE" ] || return 0 - print "$1" -} # => verbose() - # intent confirmation helper func # returns without prompting in EASYRSA_BATCH confirm() { @@ -1074,7 +1063,8 @@ Your newly created PKI dir is: if [ "$new_vars_true" ]; then information "\ IMPORTANT: Easy-RSA 'vars' template file has been created in your new PKI. - Edit this 'vars' file to customise the settings for your PKI." + Edit this 'vars' file to customise the settings for your PKI. + To use a global vars file, use global option --vars=" elif [ "$user_vars_true" ] || [ "$old_vars_true" ] || [ "$no_new_vars" ] then @@ -3824,7 +3814,8 @@ expire_status() { # db serial must match certificate serial, otherwise this # is a renewed cert which has been replaced by an issued cert if [ "$db_serial" != "$cert_serial" ]; then - verbose "* serial mismatch: + information "\ +serial mismatch: db_serial: $db_serial cert_serial: $cert_serial cert_issued: $cert_issued" @@ -3904,7 +3895,8 @@ renew_status() { # db serial must match certificate serial, otherwise this # is an issued cert that replaces a renewed cert if [ "$db_serial" != "$cert_serial" ]; then - verbose "* serial mismatch: + information "\ +serial mismatch: db_serial: $db_serial cert_serial: $cert_serial cert_file_in: $cert_file_in" @@ -4060,8 +4052,8 @@ detect_host() { # Extra diagnostics show_host() { + [ "$EASYRSA_SILENT" ] && return print_version - [ "$EASYRSA_VERBOSE" ] || return 0 print "$host_out" [ "$EASYRSA_DEBUG" ] || return 0 case "$easyrsa_host_os" in @@ -5122,13 +5114,6 @@ while :; do export EASYRSA_SILENT=1 export EASYRSA_BATCH=1 ;; - -q|--quiet) - empty_ok=1 - export EASYRSA_QUIET=1 ;; - -v|--verbose) - empty_ok=1 - export EASYRSA_VERBOSE=1 - ;; --nopass|--no-pass) empty_ok=1 export EASYRSA_NO_PASS=1 From 195d6e6c7343e115130eb78ba8244e75dae57570 Mon Sep 17 00:00:00 2001 From: Richard T Bonhomme Date: Tue, 29 Nov 2022 23:52:36 +0000 Subject: [PATCH 2/2] Update: Remove option '--quiet' Signed-off-by: Richard T Bonhomme --- ChangeLog | 1 - 1 file changed, 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 5c422ad..bf5a768 100644 --- a/ChangeLog +++ b/ChangeLog @@ -17,7 +17,6 @@ Easy-RSA 3 ChangeLog * Always ensure X509-types files exist (#581 #696) * Expand alias '--days' to all suitable options with a period (#674) * Introduce --keep-tmp, keep temp files for debugging (#667) - * Introduce Option -q|--quiet, disable information output (#703) * Add serialNumber (OID 2.5.4.5) to DN 'org' mode (#606) * Support ampersand and dollar-sign in vars file (#590) * Introduce 'rewind-renew' (#579)