From d835a046edae4664b320a177270cb301b6e65191 Mon Sep 17 00:00:00 2001 From: Brandon McCann Date: Tue, 6 Nov 2012 14:53:11 -0600 Subject: [PATCH 1/2] fixed drupal_views_user_enum.rb so it displays to stdout and stores to loot --- .../scanner/http/drupal_views_user_enum.rb | 21 ++++++++++++------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/modules/auxiliary/scanner/http/drupal_views_user_enum.rb b/modules/auxiliary/scanner/http/drupal_views_user_enum.rb index 54ea300949..8ebff8f885 100644 --- a/modules/auxiliary/scanner/http/drupal_views_user_enum.rb +++ b/modules/auxiliary/scanner/http/drupal_views_user_enum.rb @@ -24,7 +24,8 @@ class Metasploit3 < Msf::Auxiliary 'Author' => [ 'Justin Klein Keane', #Original Discovery - 'Robin Francois ' + 'Robin Francois ', + 'Brandon McCann "zeknox" ' ], 'License' => MSF_LICENSE, 'References' => @@ -90,9 +91,9 @@ class Metasploit3 < Msf::Auxiliary if (res and res.message == "OK") user_list = res.body.scan(/\w+/) if user_list.empty? - vprint_line("\tFound: Nothing") + vprint_status("\tFound: Nothing") else - vprint_line("\tFound: #{user_list.inspect}") + vprint_status("\tFound: #{user_list.inspect}") results << user_list end else @@ -106,11 +107,15 @@ class Metasploit3 < Msf::Auxiliary print_status("Done. " + final_results.length.to_s + " usernames found...") final_results.each do |user| - report_auth_info( - :host => Rex::Socket.getaddress(datastore['RHOST']), - :port => datastore['RPORT'], - :user => user, - :type => "drupal_user" + print_good("Found User: #{user}") + + store_loot( + type, + 'text/plain', + Rex::Socket.getaddress(datastore['RHOST']), + user, + 'drupal_user.txt', + user ) end end From c4f35def81b810a6a167e74e431aca9a0dadc748 Mon Sep 17 00:00:00 2001 From: Brandon McCann Date: Tue, 6 Nov 2012 14:58:14 -0600 Subject: [PATCH 2/2] fixed vprint_line --- modules/auxiliary/scanner/http/drupal_views_user_enum.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/auxiliary/scanner/http/drupal_views_user_enum.rb b/modules/auxiliary/scanner/http/drupal_views_user_enum.rb index 8ebff8f885..59afebe256 100644 --- a/modules/auxiliary/scanner/http/drupal_views_user_enum.rb +++ b/modules/auxiliary/scanner/http/drupal_views_user_enum.rb @@ -91,9 +91,9 @@ class Metasploit3 < Msf::Auxiliary if (res and res.message == "OK") user_list = res.body.scan(/\w+/) if user_list.empty? - vprint_status("\tFound: Nothing") + vprint_line("\tFound: Nothing") else - vprint_status("\tFound: #{user_list.inspect}") + vprint_line("\tFound: #{user_list.inspect}") results << user_list end else