From dfb3e98feccb24bb90b7081232f4a2472e437216 Mon Sep 17 00:00:00 2001 From: Christian Mehlmauer Date: Thu, 10 Apr 2014 01:14:38 +0200 Subject: [PATCH] Fixes Issue #453 -) Fixed options -) Fixed "unrecognized method 'verbose' for nil:NilClass when supplying an unknown option --- lib/wpscan/wpscan_options.rb | 8 ++++---- wpscan.rb | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/wpscan/wpscan_options.rb b/lib/wpscan/wpscan_options.rb index 4ff92098..a7af28a3 100644 --- a/lib/wpscan/wpscan_options.rb +++ b/lib/wpscan/wpscan_options.rb @@ -252,10 +252,10 @@ class WpscanOptions ['--basic-auth', GetoptLong::REQUIRED_ARGUMENT], ['--debug-output', GetoptLong::NO_ARGUMENT], ['--version', GetoptLong::NO_ARGUMENT], - ['--cache_ttl', GetoptLong::REQUIRED_ARGUMENT], - ['--request_timeout', GetoptLong::REQUIRED_ARGUMENT], - ['--connect_timeout', GetoptLong::REQUIRED_ARGUMENT], - ['--max_threads', GetoptLong::REQUIRED_ARGUMENT] + ['--cache-ttl', GetoptLong::REQUIRED_ARGUMENT], + ['--request-timeout', GetoptLong::REQUIRED_ARGUMENT], + ['--connect-timeout', GetoptLong::REQUIRED_ARGUMENT], + ['--max-threads', GetoptLong::REQUIRED_ARGUMENT] ) end diff --git a/wpscan.rb b/wpscan.rb index 3ff1a42d..693c978f 100755 --- a/wpscan.rb +++ b/wpscan.rb @@ -369,7 +369,7 @@ def main puts puts red(e.message) - if wpscan_options.verbose + if wpscan_options && wpscan_options.verbose puts red('Trace:') puts red(e.backtrace.join("\n")) end