Added underscore to user regex in smart_hashdump.rb to support usernames that contain underscores. Issue #4349.

bug/bundler_fix
Mark Judice 2014-12-23 22:27:44 -06:00
parent ebb05a64ea
commit 30228bcfe7
1 changed files with 1 additions and 1 deletions

View File

@ -323,7 +323,7 @@ class Metasploit3 < Msf::Post
# skip if it returns nil for an entry # skip if it returns nil for an entry
next if h == nil next if h == nil
begin begin
user = returned_hash[0].scan(/^[a-zA-Z0-9\-$.]*/).join.gsub(/\.$/,"") user = returned_hash[0].scan(/^[a-zA-Z0-9_\-$.]*/).join.gsub(/\.$/,"")
lmhash = returned_hash[2].scan(/[a-f0-9]*/).join lmhash = returned_hash[2].scan(/[a-f0-9]*/).join
next if lmhash == nil next if lmhash == nil
hash_entry = "#{user}:#{rid}:#{lmhash}:#{returned_hash[3]}" hash_entry = "#{user}:#{rid}:#{lmhash}:#{returned_hash[3]}"