diff --git a/bin/vulcano b/bin/vulcano index 86d5b3cb8..5df21f069 100755 --- a/bin/vulcano +++ b/bin/vulcano @@ -65,10 +65,10 @@ class VulcanoCLI < Thor desc: 'Specify a sudo password, if it is required.' option :sudo_options, type: :string, default: '', desc: 'Additional sudo options for a remote scan.' - option :winrm_self_signed, type: :boolean, default: false, - desc: 'Allow remote scans with WinRM to run on self-signed certificates.' - option :winrm_ssl, type: :boolean, default: false, - desc: 'Configure WinRM scans to run via SSL instead of pure HTTP.' + option :ssl, type: :boolean, default: false, + desc: 'Use SSL for transport layer encryptiong (WinRM).' + option :self_signed, type: :boolean, default: false, + desc: 'Allow remote scans with self-signed certificates (WinRM).' end desc 'exec PATHS', 'run all test files' diff --git a/lib/vulcano/backend/specinfra.rb b/lib/vulcano/backend/specinfra.rb index 804ab8a45..771952307 100644 --- a/lib/vulcano/backend/specinfra.rb +++ b/lib/vulcano/backend/specinfra.rb @@ -38,7 +38,8 @@ module Vulcano::Backends when 'ssh' spec_backend = Specinfra::Backend::Ssh backend_helper = Ssh - when 'winrm' + when 'winrm', 'winrms' + @conf['ssl'] = true if type == 'winrms' spec_backend = Specinfra::Backend::Winrm backend_helper = Winrm else diff --git a/lib/vulcano/backend/specinfra_winrm.rb b/lib/vulcano/backend/specinfra_winrm.rb index 087857f90..c50b7a66f 100644 --- a/lib/vulcano/backend/specinfra_winrm.rb +++ b/lib/vulcano/backend/specinfra_winrm.rb @@ -10,7 +10,7 @@ class Vulcano::Backends::SpecinfraHelper fail 'You must configure a target host.' if host.empty? # SSL configuration - if conf['winrm_ssl'] + if conf['ssl'] scheme = 'https' port ||= 5986 else @@ -47,7 +47,7 @@ class Vulcano::Backends::SpecinfraHelper user: user, pass: pass, basic_auth_only: true, - no_ssl_peer_verification: conf['winrm_self_signed'], + no_ssl_peer_verification: conf['self_signed'], ) si.winrm = winrm end