From d96414050330297abdcf73890db15aae7ac5f284 Mon Sep 17 00:00:00 2001 From: Tony Mountifield Date: Tue, 9 Feb 2021 11:54:12 +0000 Subject: [PATCH 1/2] Prevent listing the complete file if version tag missing Also added missing (2.34) tag to end of the change log. Couple of minor changes to output messages. --- getssl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/getssl b/getssl index f0e40ab..da65999 100755 --- a/getssl +++ b/getssl @@ -253,7 +253,7 @@ # 2021-01-22 Add FTP_OPTIONS # 2021-01-27 Add the ability to set several reload commands (atisne) # 2021-01-29 Use dig -r (if supported) to ignore.digrc (#630) -# 2021-02-07 Allow -u --upgrade without any domain, so that one can only update the script +# 2021-02-07 Allow -u --upgrade without any domain, so that one can only update the script (2.34) # ---------------------------------------------------------------------------------------- case :$SHELLOPTS: in @@ -753,10 +753,10 @@ check_getssl_upgrade() { # check if a more recent version of code is available a fi if [[ ${_MUTE} -eq 0 ]]; then echo "Updated getssl from v${VERSION} to v${latestversion}" - echo "these update notification can be turned off using the -Q option" + echo "These update notifications can be turned off using the -Q option" echo "" echo "Updates are;" - awk "/\(${VERSION}\)$/ {s=1} s; /\(${latestversion}\)$/ {s=0}" "$TEMP_UPGRADE_FILE" | awk '{if(NR>1)print}' + awk "/\(${VERSION}\)$/ {s=1} s; /\(${latestversion}\)$/ || /^# ----/ {s=0}" "$TEMP_UPGRADE_FILE" | awk '{if(NR>1)print}' echo "" fi if [[ -n "$_KEEP_VERSIONS" ]] && [[ "$_KEEP_VERSIONS" =~ ^[0-9]+$ ]]; then @@ -786,7 +786,7 @@ check_getssl_upgrade() { # check if a more recent version of code is available a else info "" info "A more recent version (v${latestversion}) of getssl is available, please update" - info "the easiest way is to use the -u or --upgrade flag" + info "The easiest way is to use the -u or --upgrade flag" info "" fi fi From a5512c00ff7f3c10c884f6e9cfe238e3bba2ead2 Mon Sep 17 00:00:00 2001 From: Tony Mountifield Date: Tue, 9 Feb 2021 11:58:43 +0000 Subject: [PATCH 2/2] Add description of change to the change log. --- getssl | 1 + 1 file changed, 1 insertion(+) diff --git a/getssl b/getssl index da65999..583f88a 100755 --- a/getssl +++ b/getssl @@ -254,6 +254,7 @@ # 2021-01-27 Add the ability to set several reload commands (atisne) # 2021-01-29 Use dig -r (if supported) to ignore.digrc (#630) # 2021-02-07 Allow -u --upgrade without any domain, so that one can only update the script (2.34) +# 2021-02-09 Prevent listing the complete file if version tag missing (#637) # ---------------------------------------------------------------------------------------- case :$SHELLOPTS: in