From 766fd7d46ebb82f9d0134886a3fc5228b4df3936 Mon Sep 17 00:00:00 2001 From: "Robin H. Johnson" Date: Tue, 12 Jan 2016 23:43:24 -0800 Subject: [PATCH] ukm: use new ssh fingerprint functions. UKM was never updated for new-style fingerprints at all. Signed-off-by: Robin H. Johnson --- contrib/commands/ukm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/contrib/commands/ukm b/contrib/commands/ukm index 8a2d361..3683154 100755 --- a/contrib/commands/ukm +++ b/contrib/commands/ukm @@ -220,10 +220,10 @@ sub cd_temp_clone { # compute the fingerprint from the full path of a pubkey file sub fingerprint { - my $fp = `ssh-keygen -l -f $_[0]`; - die "does not seem to be a valid pubkey\n" - unless $fp =~ /(([0-9a-f]+:)+[0-9a-f]+) /i; - return $1; + my ($fp, $output) = ssh_fingerprint_file(shift); + # Do not print the output of $output to an untrusted destination. + die "does not seem to be a valid pubkey\n" unless $fp; + return $fp; } -- 2.11.4.GIT