diff options
author | Norbert Preining <preining@logic.at> | 2016-05-05 02:15:12 +0000 |
---|---|---|
committer | Norbert Preining <preining@logic.at> | 2016-05-05 02:15:12 +0000 |
commit | 5413e02cb51c0edb633e91c9d4392544deb8182a (patch) | |
tree | 5674dc42b0c4144ebab6cca526fda1ae81278ce5 /Master/texmf-dist/scripts | |
parent | 860db49e7ecadc88bfc288aaa53ff773ab0d2ef4 (diff) |
continue despite missing pubkey, report details for failed verification
git-svn-id: svn://tug.org/texlive/trunk@40898 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts')
-rwxr-xr-x | Master/texmf-dist/scripts/texlive/tlmgr.pl | 36 |
1 files changed, 27 insertions, 9 deletions
diff --git a/Master/texmf-dist/scripts/texlive/tlmgr.pl b/Master/texmf-dist/scripts/texlive/tlmgr.pl index 2162a198120..287c45a1a87 100755 --- a/Master/texmf-dist/scripts/texlive/tlmgr.pl +++ b/Master/texmf-dist/scripts/texlive/tlmgr.pl @@ -382,9 +382,9 @@ sub main { $action = shift @ARGV; if (!defined($action)) { - if ($opts{"gui"}) { # -gui = gui + if ($opts{"gui"}) { # -gui = gui $action = "gui"; - } elsif ($opts{"print-platform"}) { # -print-arch = print-arch + } elsif ($opts{"print-platform"}) { # -print-arch = print-arch $action = "print-platform"; } else { $action = ""; @@ -5933,14 +5933,24 @@ END_NO_CHECKSUMS # depend on it: print "location-url\t$locstr\n" if $::machinereadable; info("$prg: package repositories\n"); + my $verstat = ""; + if (!$remotetlpdb->virtual_get_tlpdb('main')->is_verified) { + $verstat = ": "; + $verstat .= $remotetlpdb->virtual_get_tlpdb('main')->verification_status; + } info("\tmain = " . $repos{'main'} . " (" . ($remotetlpdb->virtual_get_tlpdb('main')->is_verified ? "" : "not ") . - "verified)\n"); + "verified$verstat)\n"); for my $t (@tags) { if ($t ne 'main') { + $verstat = ""; + if (!$remotetlpdb->virtual_get_tlpdb($t)->is_verified) { + $verstat = ": "; + $verstat .= $remotetlpdb->virtual_get_tlpdb($t)->verification_status; + } info("\t$t = " . $repos{$t} . " (" . ($remotetlpdb->virtual_get_tlpdb($t)->is_verified ? "" : "not ") . - "verified)\n"); + "verified$verstat)\n"); } } return 1; @@ -5977,8 +5987,13 @@ sub _init_tlmedia { if ($::machinereadable) { print "location-url\t$location\n"; } else { + my $verstat = ""; + if (!$remotetlpdb->is_verified) { + $verstat = ": "; + $verstat .= $remotetlpdb->verification_status; + } info("$prg: package repository $location (" . - ($remotetlpdb->is_verified ? "" : "not ") . "verified)\n"); + ($remotetlpdb->is_verified ? "" : "not ") . "verified$verstat)\n"); } return 1; } @@ -6041,17 +6056,20 @@ END_NO_INTERNET $local_copy_tlpdb_used = 1; } elsif ($ret == -2) { # the remote database has not be signed, warn - debug("$0: remote database is not signed, continuing anyway!\n"); + debug("$prg: remote database is not signed, continuing anyway!\n"); } elsif ($ret == -3) { # no gpg available - debug("$0: no gpg available for verification, continuing anyway!\n"); + debug("$prg: no gpg available for verification, continuing anyway!\n"); + } elsif ($ret == -4) { + # pubkey missing + debug("$prg: $msg, continuing anyway!\n"); } elsif ($ret == 1) { # no problem, checksum is wrong, we need to get new tlpdb } elsif ($ret == 2) { # umpf, signature error # TODO should we die here? Probably yes because one of # checksum file or signature file has changed! - tldie("$0: verification of checksum for $location failed: $msg\n"); + tldie("$prg: verification of checksum for $location failed: $msg\n"); } elsif ($ret == 0) { $remotetlpdb = TeXLive::TLPDB->new(root => $location, tlpdbfile => $loc_copy_of_remote_tlpdb); @@ -6059,7 +6077,7 @@ END_NO_INTERNET # we did verify this tlpdb, make sure that is recorded $remotetlpdb->is_verified(1); } else { - tldie("$0: unexpected return value from verify_checksum: $ret\n"); + tldie("$prg: unexpected return value from verify_checksum: $ret\n"); } } } |