@@ -54,8 +54,9 @@ def __init__(self):
54
54
self .major_version = 6
55
55
56
56
class Vol3Reader :
57
- def __init__ (self , vol_obj ):
57
+ def __init__ (self , vol_obj , framework_version ):
58
58
self .vol_obj = vol_obj
59
+ self .framework_version = framework_version
59
60
self .proc_layer_name = None
60
61
self .proc_layer = None
61
62
self .lsass_process = None
@@ -83,10 +84,18 @@ def get_sysinfo(self):
83
84
84
85
def find_lsass (self ):
85
86
filter_func = pslist .PsList .create_name_filter (['lsass.exe' ])
87
+ if self .framework_version == 1 :
88
+ layer_name = self .vol_obj .config ['primary' ]
89
+ symbol_table = self .vol_obj .config ['nt_symbols' ]
90
+ elif self .framework_version == 2 :
91
+ layer_name = self .vol_obj .context .modules [self .vol_obj .config ['kernel' ]].layer_name
92
+ symbol_table = self .vol_obj .context .modules [self .vol_obj .config ['kernel' ]].symbol_table_name
93
+ else :
94
+ raise Exception ('Unsupported Volatility Framework Version' )
86
95
for proc in pslist .PsList .list_processes (
87
96
context = self .vol_obj .context ,
88
- layer_name = self . vol_obj . config [ 'primary' ] ,
89
- symbol_table = self . vol_obj . config [ 'nt_symbols' ] ,
97
+ layer_name = layer_name ,
98
+ symbol_table = symbol_table ,
90
99
filter_func = filter_func
91
100
):
92
101
self .lsass_process = proc
@@ -112,8 +121,14 @@ def list_dlls(self):
112
121
113
122
def get_buildnumber (self ):
114
123
# https://github.com/volatilityfoundation/volatility3/blob/ee31ece0062ce762ed38f6d0a1c54e9f1cd37970/volatility/framework/plugins/windows/cmdline.py
124
+ if self .framework_version == 1 :
125
+ vol_object = self .vol_obj .config ["nt_symbols" ] + constants .BANG + "_PEB"
126
+ elif self .framework_version == 2 :
127
+ vol_object = self .vol_obj .context .modules [self .vol_obj .config ['kernel' ]].symbol_table_name + constants .BANG + "_PEB"
128
+ else :
129
+ raise Exception ('Unsupported Volatility Framework Version' )
115
130
peb = self .vol_obj .context .object (
116
- self . vol_obj . config [ "nt_symbols" ] + constants . BANG + "_PEB" ,
131
+ vol_object ,
117
132
layer_name = self .proc_layer_name ,
118
133
offset = self .lsass_process .Peb
119
134
)
@@ -126,7 +141,13 @@ def list_sections(self):
126
141
self .sections .append (VOL3Section .from_vad (vad ))
127
142
128
143
def get_arch (self ):
129
- if not symbols .symbol_table_is_64bit (self .vol_obj .context , self .vol_obj .config ["nt_symbols" ]):
144
+ if self .framework_version == 1 :
145
+ symbol_table_is_64bit = symbols .symbol_table_is_64bit (self .vol_obj .context , self .vol_obj .config ["nt_symbols" ])
146
+ elif self .framework_version == 2 :
147
+ symbol_table_is_64bit = symbols .symbol_table_is_64bit (self .vol_obj .context , self .vol_obj .context .modules [self .vol_obj .config ['kernel' ]].symbol_table_name )
148
+ else :
149
+ raise Exception ('Unsupported Volatility Framework Version' )
150
+ if not symbol_table_is_64bit :
130
151
self .processor_architecture = KatzSystemArchitecture .X86
131
152
self .processor_architecture = KatzSystemArchitecture .X64
132
153
@@ -229,6 +250,7 @@ def vol3_generator(mimi):
229
250
x = [str (t ['credtype' ]), '' , '' , '' , '' , '' , str (t ['masterkey' ]), str (t ['sha1_masterkey' ]), str (t ['key_guid' ]), '' ]
230
251
yield 0 , x
231
252
253
+
232
254
def vol3_treegrid (mimi ):
233
255
return renderers .TreeGrid ([
234
256
("credtype" , str ),
0 commit comments