Adds Theme DFs

This commit is contained in:
erwanlr
2019-07-05 09:34:13 +01:00
parent 4d32749489
commit f1a7413e20
11 changed files with 798 additions and 9 deletions

View File

@@ -10,9 +10,8 @@ module WPScan
end
# @return [ Hash ]
def self.db_data
# true allows aliases to be loaded
@db_data ||= YAML.safe_load(File.read(db_file), [Regexp], [], true)
def self.raw_db_data
@raw_db_data ||= YAML.safe_load(File.read(db_file), [Regexp])
end
# @return [ Array<Symbol> ]

View File

@@ -6,7 +6,7 @@ module WPScan
class Plugin < Base
# @return [ Hash ]
def self.db_data
@db_data ||= super['plugins'] || {}
@db_data ||= raw_db_data['plugins'] || {}
end
def self.version_finder_module

View File

@@ -6,7 +6,7 @@ module WPScan
class Theme < Plugin
# @return [ Hash ]
def self.db_data
@db_data ||= super['themes'] || {}
@db_data ||= raw_db_data['themes'] || {}
end
def self.version_finder_module

View File

@@ -6,7 +6,7 @@ module WPScan
class Wordpress < Base
# @return [ Hash ]
def self.db_data
@db_data ||= super['wordpress'] || {}
@db_data ||= raw_db_data['wordpress'] || {}
end
# @return [ Constant ]