From c946a155b73e2adf2de3efbe8e9c97deb8682a5f Mon Sep 17 00:00:00 2001 From: niten Date: Wed, 2 Feb 2022 15:19:11 -0600 Subject: [PATCH] Some minor mistakes in SSHFP call Removed extra dot, used '-f ' to specify key filename --- dns-client.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dns-client.rb b/dns-client.rb index 11a4503..abe0012 100644 --- a/dns-client.rb +++ b/dns-client.rb @@ -220,9 +220,9 @@ end def host_sshfp(keys) keys.flat_map { |keyfile| - `ssh-keygen -r hostname #{keyfile}`.split("\n") + `ssh-keygen -r hostname -f #{keyfile}`.split("\n") }.map { |fp| - fp..match(/[0-9] [0-9] [a-fA-F0-9]{32,64}$/)[0] + fp.match(/[0-9] [0-9] [a-fA-F0-9]{32,64}$/)[0] }.compact end