bin/ssh_scan in ssh_scan-0.0.18 vs bin/ssh_scan in ssh_scan-0.0.19

- old
+ new

@@ -16,11 +16,11 @@ "unit_test" => false, "timeout" => 2, "threads" => 5, "verbosity" => nil, "logger" => Logger.new(STDERR), - "fingerprint_database" => File.join(File.dirname(__FILE__),"../data/fingerprints.db") + "fingerprint_database" => File.join(File.dirname(__FILE__),"../data/fingerprints.yml") } # Reorder arguments before parsing def reorder_args!(order, opt_parser) old_args = opt_parser.default_argv @@ -242,9 +242,14 @@ options["logger"].info( "You're using the latest version of ssh_scan #{SSHScan::VERSION}" ) end end +end + +# Limit scope of fingerprints DB to (per scan) +if options["fingerprint_database"] && File.exists?(options["fingerprint_database"]) + File.unlink(options["fingerprint_database"]) end options["policy_file"] = SSHScan::Policy.from_file(options["policy"]) # Perform scan and get results