Package rekall :: Package plugins :: Package renderers :: Module efilter
[frames] | no frames]

Source Code for Module rekall.plugins.renderers.efilter

 1  # Rekall Memory Forensics 
 2  # 
 3  # Copyright 2016 Google Inc. All Rights Reserved. 
 4  # 
 5  # Authors: 
 6  # Michael Cohen <scudette@google.com> 
 7  # 
 8  # This program is free software; you can redistribute it and/or modify 
 9  # it under the terms of the GNU General Public License as published by 
10  # the Free Software Foundation; either version 2 of the License, or (at 
11  # your option) any later version. 
12  # 
13  # This program is distributed in the hope that it will be useful, but 
14  # WITHOUT ANY WARRANTY; without even the implied warranty of 
15  # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 
16  # General Public License for more details. 
17  # 
18  # You should have received a copy of the GNU General Public License 
19  # along with this program; if not, write to the Free Software 
20  # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 
21  # 
22   
23  """Renderers for Efilter..""" 
24  from rekall.ui import renderer as renderer_module 
25  from rekall.ui import text 
26  from rekall.plugins.renderers import data_export 
27   
28   
29 -class RowTupleTextObjectRenderer(text.TextObjectRenderer):
30 renders_type = "RowTuple" 31 renderers = ["TextRenderer", "TestRenderer", "WideTextRenderer"] 32
33 - def render_row(self, item, **_):
34 result = [] 35 for element in item: 36 delegate_cls = renderer_module.ObjectRenderer.ForTarget( 37 element, renderer=self.renderer) 38 result.append(delegate_cls( 39 session=self.session, 40 renderer=self.renderer).render_row(element)) 41 42 return text.JoinedCell(*result)
43 44
45 -class RowTupleDataExportObjectRenderer(data_export.DataExportObjectRenderer):
46 renders_type = "RowTuple" 47
48 - def GetState(self, item, **_):
49 return dict(items=list(item))
50