From 659122c6c0cd68cc30e28a33f74eba0f7c1898c5 Mon Sep 17 00:00:00 2001 From: Jonathan Claudius Date: Mon, 2 Oct 2017 15:38:29 -0400 Subject: [PATCH 1/2] Fix bug #420 --- bin/ssh_scan | 2 +- lib/ssh_scan/policy_manager.rb | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/bin/ssh_scan b/bin/ssh_scan index 5982a372..ffca12a1 100755 --- a/bin/ssh_scan +++ b/bin/ssh_scan @@ -261,7 +261,7 @@ puts JSON.pretty_generate(results) if options["unit_test"] == true results.each do |result| - if result.compliant == false + if result["compliance"] && result["compliance"]["compliant"] == false exit 1 #non-zero means a false else exit 0 #non-zero means pass diff --git a/lib/ssh_scan/policy_manager.rb b/lib/ssh_scan/policy_manager.rb index 5fe1e770..9f390101 100644 --- a/lib/ssh_scan/policy_manager.rb +++ b/lib/ssh_scan/policy_manager.rb @@ -212,10 +212,10 @@ def recommendations def compliance_results { - :policy => @policy.name, - :compliant => compliant?, - :recommendations => recommendations, - :references => @policy.references, + "policy" => @policy.name, + "compliant" => compliant?, + "recommendations" => recommendations, + "references" => @policy.references, } end end From 2925900aab590ffd55d8c7d9ed20a52c9eb0b658 Mon Sep 17 00:00:00 2001 From: Jonathan Claudius Date: Mon, 2 Oct 2017 15:38:48 -0400 Subject: [PATCH 2/2] Bump for 29 --- lib/ssh_scan/version.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ssh_scan/version.rb b/lib/ssh_scan/version.rb index a36e0317..2c0c1ce5 100644 --- a/lib/ssh_scan/version.rb +++ b/lib/ssh_scan/version.rb @@ -1,3 +1,3 @@ module SSHScan - VERSION = '0.0.28' + VERSION = '0.0.29' end