@@ -14,7 +14,9 @@ class Metasploit3 < Msf::Post
14
14
def initialize ( info = { } )
15
15
super ( update_info ( info ,
16
16
'Name' => 'Windows Gather Prefetch File Information' ,
17
- 'Description' => %q{This module gathers prefetch file information from WinXP, Win2k3 and Win7 systems.} ,
17
+ 'Description' => %q{This module gathers prefetch file information from WinXP, Win2k3 and Win7 systems.
18
+ File offset reads for run count, hash and filename are collected from each prefetch file
19
+ using WinAPI through Railgun while Last Modified and Create times are file MACE values.} ,
18
20
'License' => MSF_LICENSE ,
19
21
'Author' => [ 'TJ Glad <fraktaali[at]gmail.com>' ] ,
20
22
'Platform' => [ 'win' ] ,
@@ -127,41 +129,27 @@ def run
127
129
sysnfo = client . sys . config . sysinfo [ 'OS' ]
128
130
error_msg = "You don't have enough privileges. Try getsystem."
129
131
130
- if sysnfo =~/(Windows XP)/
132
+ if sysnfo =~/(Windows XP|2003|.NET )/
131
133
if not is_system?
132
134
print_error ( error_msg )
133
135
return nil
134
136
end
135
- # Offsets for WinXP
136
- print_good ( "Detected Windows XP (max 128 entries)" )
137
+ # Offsets for WinXP & Win2k3
138
+ print_good ( "Detected #{ sysnfo } (max 128 entries)" )
137
139
name_offset = 0x10
138
140
hash_offset = 0x4C
139
141
lastrun_offset = 0x78
140
142
runcount_offset = 0x90
141
143
# Registry key for timezone
142
144
key_value = "StandardName"
143
145
144
- elsif sysnfo =~/(Windows .NET Server)/
145
- if not is_system?
146
- print_error ( error_msg )
147
- return nil
148
- end
149
- # Offsets for Win2k3
150
- print_good ( "Detected Windows 2k3 (max 128 entries)" )
151
- name_offset = 0x10
152
- hash_offset = 0x4C
153
- lastrun_offset = 0x78
154
- runcount_offset = 0x90
155
- # Registry key for timezone
156
- key_value = "StandardName"
157
-
158
146
elsif sysnfo =~/(Windows 7)/
159
147
if not is_admin?
160
148
print_error ( error_msg )
161
149
return nil
162
150
end
163
151
# Offsets for Win7
164
- print_good ( "Detected Windows 7 (max 128 entries)" )
152
+ print_good ( "Detected #{ sysnfo } (max 128 entries)" )
165
153
name_offset = 0x10
166
154
hash_offset = 0x4C
167
155
lastrun_offset = 0x80
0 commit comments