[Git][NTPsec/ntpsec][master] ntpleapfetch: Fix hash computation, news file.

Matt Selsky (@selsky) gitlab at mg.gitlab.com
Fri Jun 18 23:26:23 UTC 2021



Matt Selsky pushed to branch master at NTPsec / ntpsec


Commits:
a0e5e050 by James Browning at 2021-06-18T13:58:48-07:00
ntpleapfetch: Fix hash computation, news file.

- - - - -


2 changed files:

- NEWS.adoc
- ntpclients/ntpleapfetch


Changes:

=====================================
NEWS.adoc
=====================================
@@ -12,6 +12,8 @@ on user-visible changes.
 
 == Reposatory Head ==
 
+Fix hash validation in ntpleapfetch again.
+
 == 2021-06-06: 1.2.1 ==
 
 Update ntpkeygen/keygone to properly filter `#` characters. (CVE-2021-22212)


=====================================
ntpclients/ntpleapfetch
=====================================
@@ -310,7 +310,7 @@ verifySHA1() {
     # or maybe a space and a tab.  remove the tab, wherever it may be.  Add some 0x
     # so it can be run through printf to restore missing leading zeros.
     #
-    local FSHA1="`grep '^#h' $1 | tr -d '[:cntrl:]' | sed -e's/^#h/0x/' -e's/ / 0x/g'`"
+    local FSHA1="`grep '^#h' $1 | tr -d '[:cntrl:]' | sed -e's/^#h[ \t]*/0x/' -e's/ / 0x/g'`"
     FSHA1=`printf '%08x%08x%08x%08x%08x' $FSHA1`
 
     if [ -n "$FSHA1" -a \( "$FSHA1" = "$DSHA1" \) ]; then



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/-/commit/a0e5e050dfbdb672459f74bf52562bc8fc50c3b9

-- 
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/-/commit/a0e5e050dfbdb672459f74bf52562bc8fc50c3b9
You're receiving this email because of your account on gitlab.com.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ntpsec.org/pipermail/vc/attachments/20210618/8f573fe2/attachment.htm>


More information about the vc mailing list