bugfixing and rspec tests
This commit is contained in:
@@ -132,7 +132,7 @@ class WpTarget
|
||||
|
||||
def search_replace_db_2_exists?
|
||||
resp = Browser.instance.get(search_replace_db_2_url)
|
||||
resp.status == 200 && resp.body[%r{by interconnect}i]
|
||||
resp.code == 200 && resp.body[%r{by interconnect}i]
|
||||
end
|
||||
|
||||
# Should check wp-login.php if registration is enabled or not
|
||||
|
||||
@@ -124,12 +124,12 @@ class WpVersion < Vulnerable
|
||||
# http://code.google.com/p/wpscan/issues/detail?id=109
|
||||
def self.find_from_sitemap_generator(options)
|
||||
target_uri = options[:base_url]
|
||||
Browser.instance.get(target_uri.merge("sitemap.xml").to_s).body[%r{generator="wordpress/#{WpVersion.version_pattern}"}, 1]
|
||||
Browser.instance.get(target_uri.merge("sitemap.xml").to_s).body[%r{generator="wordpress/#{WpVersion.version_pattern}"}i, 1]
|
||||
end
|
||||
|
||||
def self.find_from_links_opml(options)
|
||||
target_uri = options[:base_url]
|
||||
Browser.instance.get(target_uri.merge("wp-links-opml.php").to_s).body[%r{generator="wordpress/#{WpVersion.version_pattern}"}, 1]
|
||||
Browser.instance.get(target_uri.merge("wp-links-opml.php").to_s).body[%r{generator="wordpress/#{WpVersion.version_pattern}"}i, 1]
|
||||
end
|
||||
|
||||
# Used to check if the version is correct : must contain at least one .
|
||||
|
||||
Reference in New Issue
Block a user