output wordpress url on all items
This commit is contained in:
@@ -43,7 +43,14 @@ class WpItem < Vulnerable
|
|||||||
# The wordpress.org plugins directory URL
|
# The wordpress.org plugins directory URL
|
||||||
# See: https://github.com/wpscanteam/wpscan/issues/100
|
# See: https://github.com/wpscanteam/wpscan/issues/100
|
||||||
def wp_org_url
|
def wp_org_url
|
||||||
URI('http://wordpress.org/extend/plugins/').merge("#@name/")
|
case @type
|
||||||
|
when "themes"
|
||||||
|
return URI("http://wordpress.org/extend/themes/").merge("#@name/")
|
||||||
|
when "plugins"
|
||||||
|
return URI("http://wordpress.org/extend/plugins/").merge("#@name/")
|
||||||
|
else
|
||||||
|
raise("No Wordpress URL for #@type")
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def get_sub_folder
|
def get_sub_folder
|
||||||
|
|||||||
11
wpscan.rb
11
wpscan.rb
@@ -135,13 +135,20 @@ begin
|
|||||||
if wp_theme
|
if wp_theme
|
||||||
# Theme version is handled in wp_item.to_s
|
# Theme version is handled in wp_item.to_s
|
||||||
puts green("[+]") + " The WordPress theme in use is #{wp_theme}"
|
puts green("[+]") + " The WordPress theme in use is #{wp_theme}"
|
||||||
|
puts
|
||||||
|
puts " | Name: #{wp_theme}" #this will also output the version number if detected
|
||||||
|
puts " | Location: #{wp_theme.get_url_without_filename}"
|
||||||
|
puts " | WordPress: #{wp_theme.wp_org_url}"
|
||||||
|
puts " | Directory listing enabled: Yes" if wp_theme.directory_listing?
|
||||||
|
puts " | Readme: #{wp_theme.readme_url}" if wp_theme.has_readme?
|
||||||
|
puts " | Changelog: #{wp_theme.changelog_url}" if wp_theme.has_changelog?
|
||||||
|
|
||||||
theme_vulnerabilities = wp_theme.vulnerabilities
|
theme_vulnerabilities = wp_theme.vulnerabilities
|
||||||
unless theme_vulnerabilities.empty?
|
unless theme_vulnerabilities.empty?
|
||||||
puts red("[!]") + " We have identified #{theme_vulnerabilities.size} vulnerabilities for this theme :"
|
puts red("[!]") + " We have identified #{theme_vulnerabilities.size} vulnerabilities for this theme :"
|
||||||
output_vulnerabilities(theme_vulnerabilities)
|
output_vulnerabilities(theme_vulnerabilities)
|
||||||
puts
|
|
||||||
end
|
end
|
||||||
|
puts
|
||||||
end
|
end
|
||||||
|
|
||||||
if wp_target.has_readme?
|
if wp_target.has_readme?
|
||||||
@@ -249,6 +256,7 @@ begin
|
|||||||
puts
|
puts
|
||||||
puts " | Name: #{plugin}" #this will also output the version number if detected
|
puts " | Name: #{plugin}" #this will also output the version number if detected
|
||||||
puts " | Location: #{plugin.get_url_without_filename}"
|
puts " | Location: #{plugin.get_url_without_filename}"
|
||||||
|
puts " | WordPress: #{plugin.wp_org_url}"
|
||||||
puts " | Directory listing enabled: Yes" if plugin.directory_listing?
|
puts " | Directory listing enabled: Yes" if plugin.directory_listing?
|
||||||
puts " | Readme: #{plugin.readme_url}" if plugin.has_readme?
|
puts " | Readme: #{plugin.readme_url}" if plugin.has_readme?
|
||||||
puts " | Changelog: #{plugin.changelog_url}" if plugin.has_changelog?
|
puts " | Changelog: #{plugin.changelog_url}" if plugin.has_changelog?
|
||||||
@@ -292,6 +300,7 @@ begin
|
|||||||
puts
|
puts
|
||||||
puts " | Name: #{theme}" #this will also output the version number if detected
|
puts " | Name: #{theme}" #this will also output the version number if detected
|
||||||
puts " | Location: #{theme.get_url_without_filename}"
|
puts " | Location: #{theme.get_url_without_filename}"
|
||||||
|
puts " | WordPress: #{theme.wp_org_url}"
|
||||||
puts " | Directory listing enabled: Yes" if theme.directory_listing?
|
puts " | Directory listing enabled: Yes" if theme.directory_listing?
|
||||||
puts " | Readme: #{theme.readme_url}" if theme.has_readme?
|
puts " | Readme: #{theme.readme_url}" if theme.has_readme?
|
||||||
puts " | Changelog: #{theme.changelog_url}" if theme.has_changelog?
|
puts " | Changelog: #{theme.changelog_url}" if theme.has_changelog?
|
||||||
|
|||||||
Reference in New Issue
Block a user