From 9d3464055a4daaad67a1ec604141b18089bdb1ff Mon Sep 17 00:00:00 2001 From: erwanlr Date: Fri, 2 Nov 2018 08:36:22 +0000 Subject: [PATCH] Updates deps --- app/controllers/enumeration/cli_options.rb | 26 +++++++++---------- .../interesting_findings/upload_sql_dump.rb | 2 +- .../woo_framework_meta_generator.rb | 6 ++--- lib/wpscan/target/platform/wordpress.rb | 2 +- wpscan.gemspec | 2 +- 5 files changed, 19 insertions(+), 19 deletions(-) diff --git a/app/controllers/enumeration/cli_options.rb b/app/controllers/enumeration/cli_options.rb index ee6b8d5b..bc91ade6 100644 --- a/app/controllers/enumeration/cli_options.rb +++ b/app/controllers/enumeration/cli_options.rb @@ -15,20 +15,20 @@ module WPScan OptMultiChoices.new( ['-e', '--enumerate [OPTS]', 'Enumeration Process'], choices: { - vp: OptBoolean.new(['--vulnerable-plugins']), - ap: OptBoolean.new(['--all-plugins']), - p: OptBoolean.new(['--plugins']), - vt: OptBoolean.new(['--vulnerable-themes']), - at: OptBoolean.new(['--all-themes']), - t: OptBoolean.new(['--themes']), - tt: OptBoolean.new(['--timthumbs']), - cb: OptBoolean.new(['--config-backups']), + vp: OptBoolean.new(['--vulnerable-plugins']), + ap: OptBoolean.new(['--all-plugins']), + p: OptBoolean.new(['--plugins']), + vt: OptBoolean.new(['--vulnerable-themes']), + at: OptBoolean.new(['--all-themes']), + t: OptBoolean.new(['--themes']), + tt: OptBoolean.new(['--timthumbs']), + cb: OptBoolean.new(['--config-backups']), dbe: OptBoolean.new(['--db-exports']), - u: OptIntegerRange.new(['--users', 'User IDs range. e.g: u1-5'], value_if_empty: '1-10'), - m: OptIntegerRange.new(['--medias', - 'Media IDs range. e.g m1-15', - 'Note: Permalink setting must be set to "Plain" for those to be detected'], - value_if_empty: '1-100') + u: OptIntegerRange.new(['--users', 'User IDs range. e.g: u1-5'], value_if_empty: '1-10'), + m: OptIntegerRange.new(['--medias', + 'Media IDs range. e.g m1-15', + 'Note: Permalink setting must be set to "Plain" for those to be detected'], + value_if_empty: '1-100') }, value_if_empty: 'vp,vt,tt,cb,dbe,u,m', incompatible: [%i[vp ap p], %i[vt at t]], diff --git a/app/finders/interesting_findings/upload_sql_dump.rb b/app/finders/interesting_findings/upload_sql_dump.rb index 48b2c47d..81bd1ee2 100644 --- a/app/finders/interesting_findings/upload_sql_dump.rb +++ b/app/finders/interesting_findings/upload_sql_dump.rb @@ -3,7 +3,7 @@ module WPScan module InterestingFindings # UploadSQLDump finder class UploadSQLDump < CMSScanner::Finders::Finder - SQL_PATTERN = /(?:(?:(?:DROP|CREATE) TABLE)|INSERT INTO)/ + SQL_PATTERN = /(?:(?:(?:DROP|CREATE) TABLE)|INSERT INTO)/.freeze # @return [ InterestingFinding ] def aggressive(_opts = {}) diff --git a/app/finders/main_theme/woo_framework_meta_generator.rb b/app/finders/main_theme/woo_framework_meta_generator.rb index 62b7e6d6..b4ffee6f 100644 --- a/app/finders/main_theme/woo_framework_meta_generator.rb +++ b/app/finders/main_theme/woo_framework_meta_generator.rb @@ -3,9 +3,9 @@ module WPScan module MainTheme # From the WooFramework meta generators class WooFrameworkMetaGenerator < CMSScanner::Finders::Finder - THEME_PATTERN = %r{} - FRAMEWORK_PATTERN = %r{} - PATTERN = /#{THEME_PATTERN}\s+#{FRAMEWORK_PATTERN}/i + THEME_PATTERN = %r{}.freeze + FRAMEWORK_PATTERN = %r{}.freeze + PATTERN = /#{THEME_PATTERN}\s+#{FRAMEWORK_PATTERN}/i.freeze def passive(opts = {}) return unless target.homepage_res.body =~ PATTERN diff --git a/lib/wpscan/target/platform/wordpress.rb b/lib/wpscan/target/platform/wordpress.rb index ba98b11b..9c86613c 100644 --- a/lib/wpscan/target/platform/wordpress.rb +++ b/lib/wpscan/target/platform/wordpress.rb @@ -9,7 +9,7 @@ module WPScan module WordPress include CMSScanner::Target::Platform::PHP - WORDPRESS_PATTERN = %r{/(?:(?:wp-content/(?:themes|(?:mu\-)?plugins|uploads))|wp-includes)/}i + WORDPRESS_PATTERN = %r{/(?:(?:wp-content/(?:themes|(?:mu\-)?plugins|uploads))|wp-includes)/}i.freeze # These methods are used in the associated interesting_findings finders # to keep the boolean state of the finding rather than re-check the whole thing again diff --git a/wpscan.gemspec b/wpscan.gemspec index 96b35a68..f7f28b42 100644 --- a/wpscan.gemspec +++ b/wpscan.gemspec @@ -32,7 +32,7 @@ Gem::Specification.new do |s| s.add_development_dependency 'rake', '~> 12.3' s.add_development_dependency 'rspec', '~> 3.8.0' s.add_development_dependency 'rspec-its', '~> 1.2.0' - s.add_development_dependency 'rubocop', '~> 0.59.2' + s.add_development_dependency 'rubocop', '~> 0.60.0' s.add_development_dependency 'simplecov', '~> 0.16.1' s.add_development_dependency 'webmock', '~> 3.4.2' end