]> git.openstreetmap.org Git - dns.git/commitdiff
Suppress some warnings from sshfp
authorTom Hughes <tom@compton.nu>
Fri, 27 Mar 2020 10:25:43 +0000 (10:25 +0000)
committerTom Hughes <tom@compton.nu>
Fri, 27 Mar 2020 10:30:23 +0000 (10:30 +0000)
bin/mksshfp

index 3c1cd1dd49c4e327f8dd81d7629696b5ca63e148..ef8dda051137d24f081c0ad3fdf7f1fe7c1542ad 100755 (executable)
@@ -4,7 +4,7 @@ my %hosts;
 
 if (-f "/etc/ssh/ssh_known_hosts")
 {
-    open(SSHFP, "-|","sshfp", "-k", "/etc/ssh/ssh_known_hosts") || die $!;
+    open(SSHFP, "-|","sshfp -k /etc/ssh/ssh_known_hosts 2>&1") || die $!;
 
     while (my $line = <SSHFP>)
     {
@@ -45,7 +45,7 @@ if (-f "/etc/ssh/ssh_known_hosts")
                 }
             }
         }
-        else
+        elsif ($line !~ /^WARNING: Assuming /)
         {
             warn $line;
         }