Accept SSH keys with whitespace in comments

`ssh-keygen -l` returns more than four tokens when there is whitespace
in the key comment.

Fixes FS#45488.

Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
This commit is contained in:
Lukas Fleischer 2015-06-29 08:57:28 +02:00
parent c89bf51af2
commit feeda37bb7

View file

@ -1250,7 +1250,7 @@ function ssh_key_fingerprint($ssh_key) {
unlink($tmpfile);
$tokens = explode(' ', $out[0]);
if (count($tokens) != 4) {
if (count($tokens) < 4) {
return false;
}