From 3c6b3c84c968c38b4331ff5aa3625238a5c970d9 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Tue, 12 Apr 2016 06:12:20 +0000 Subject: switch consistently to sha512 for all checksums, sign installer and iso etc git-svn-id: svn://tug.org/texlive/trunk@40455 c570f23f-e606-0410-a88d-b1316a301751 --- Master/tlpkg/TeXLive/TLConfig.pm | 3 +++ Master/tlpkg/TeXLive/TLUtils.pm | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-) (limited to 'Master/tlpkg/TeXLive') diff --git a/Master/tlpkg/TeXLive/TLConfig.pm b/Master/tlpkg/TeXLive/TLConfig.pm index 1242ce98b30..27bafd41df5 100644 --- a/Master/tlpkg/TeXLive/TLConfig.pm +++ b/Master/tlpkg/TeXLive/TLConfig.pm @@ -52,6 +52,7 @@ BEGIN { $F_OK $F_WARNING $F_ERROR $F_NOPOSTACTION $ChecksumLength $ChecksumProgram + $ChecksumExtension ); @EXPORT = @EXPORT_OK; } @@ -224,6 +225,8 @@ $ChecksumLength = 128; # argument $ChecksumProgram = "sha512sum"; +# The extension of the checksum file +$ChecksumExtension = "sha512"; 1; diff --git a/Master/tlpkg/TeXLive/TLUtils.pm b/Master/tlpkg/TeXLive/TLUtils.pm index 115b98cb6dd..72c01ef7713 100644 --- a/Master/tlpkg/TeXLive/TLUtils.pm +++ b/Master/tlpkg/TeXLive/TLUtils.pm @@ -3747,8 +3747,8 @@ sub download_to_temp_or_file { =item C<< verify_download($file, $url) >> -Verifies a download of C<$url> into C<$file> by checking C<$url.checksum> -and if gpg is available, verifying that with C<$url.checksum.asc>. +Verifies a download of C<$url> into C<$file> by checking C<$url.sha512> +and if gpg is available, verifying that with C<$url.sha512.asc>. Returns 0 on success, -1 on connection error, 1 on checksum error. In case of errors returns an informal message as second argument. @@ -3758,7 +3758,7 @@ In case of errors returns an informal message as second argument. sub verify_download { my ($file, $url) = @_; # download checksum file - my $checksum_url = "$url.checksum"; + my $checksum_url = "$url.$TeXLive::TLConfig::ChecksumExtension"; my $signature_url = "$checksum_url.asc"; my $checksum_file = download_to_temp_or_file($checksum_url); -- cgit v1.2.3