display module's fullname when dumping options or info, thanks chao-mu for the patch, fixes #3486

git-svn-id: file:///home/svn/framework3/trunk@11539 4d416f70-5f16-0410-b530-b9f4589650da
unstable
James Lee 2011-01-10 23:34:05 +00:00
parent 88eb09ac66
commit 972fdc8cc3
2 changed files with 5 additions and 1 deletions

View File

@ -121,6 +121,7 @@ class ReadableText
def self.dump_exploit_module(mod, indent = '')
output = "\n"
output << " Name: #{mod.name}\n"
output << " Module: #{mod.fullname}\n"
output << " Version: #{mod.version}\n"
output << " Platform: #{mod.platform_to_s}\n"
output << " Privileged: " + (mod.privileged? ? "Yes" : "No") + "\n"
@ -182,6 +183,7 @@ class ReadableText
def self.dump_auxiliary_module(mod, indent = '')
output = "\n"
output << " Name: #{mod.name}\n"
output << " Module: #{mod.fullname}\n"
output << " Version: #{mod.version}\n"
output << " License: #{mod.license}\n"
output << " Rank: #{mod.rank_to_s.capitalize}\n"
@ -225,6 +227,7 @@ class ReadableText
# General
output = "\n"
output << " Name: #{mod.name}\n"
output << " Module: #{mod.fullname}\n"
output << " Version: #{mod.version}\n"
output << " Platform: #{mod.platform_to_s}\n"
output << " Arch: #{mod.arch_to_s}\n"
@ -262,6 +265,7 @@ class ReadableText
# General
output = "\n"
output << " Name: #{mod.name}\n"
output << " Module: #{mod.fullname}\n"
output << " Version: #{mod.version}\n"
output << " Platform: #{mod.platform_to_s}\n"
output << " Arch: #{mod.arch_to_s}\n"

View File

@ -2317,7 +2317,7 @@ protected
def show_options(mod) # :nodoc:
mod_opt = Serializer::ReadableText.dump_options(mod, ' ')
print("\nModule options:\n\n#{mod_opt}\n") if (mod_opt and mod_opt.length > 0)
print("\nModule options (#{mod.fullname}):\n\n#{mod_opt}\n") if (mod_opt and mod_opt.length > 0)
# If it's an exploit and a payload is defined, create it and
# display the payload's options