From: Stefan Schantl Date: Tue, 15 Jun 2021 17:19:24 +0000 (+0200) Subject: remote.cgi: Fix splitting output from ssh-keygen. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=0ec10050f90262fced5a3e0608393f762b4be114;p=people%2Fstevee%2Fipfire-2.x.git remote.cgi: Fix splitting output from ssh-keygen. The split function requires an string as input. Signed-off-by: Stefan Schantl --- diff --git a/html/cgi-bin/remote.cgi b/html/cgi-bin/remote.cgi index 576e7628d9..83b8a892ab 100644 --- a/html/cgi-bin/remote.cgi +++ b/html/cgi-bin/remote.cgi @@ -255,9 +255,9 @@ sub viewkey if ( -e $key ) { # Use safe system_output function to call ssh-keygen and get the output from the tool. - my @ssh_keygen = &General::system_output("/usr/bin/ssh-keygen", "-l", -"-f", "$key"); + my @ssh_keygen = &General::system_output("/usr/bin/ssh-keygen", "-l", "-f", "$key"); - my @temp = split(/ /, @ssh_keygen); + my @temp = split(/ /, $ssh_keygen[0]); my $keysize = &Header::cleanhtml($temp[0],"y"); my $fingerprint = &Header::cleanhtml($temp[1],"y"); print "$key$name$fingerprint$keysize\n";