Trees | Indices | Help |
|
---|
|
1 # Rekall Memory Forensics 2 # 3 # Copyright 2014 Google Inc. All Rights Reserved. 4 # 5 # This program is free software; you can redistribute it and/or modify 6 # it under the terms of the GNU General Public License as published by 7 # the Free Software Foundation; either version 2 of the License, or (at 8 # your option) any later version. 9 # 10 # This program is distributed in the hope that it will be useful, but 11 # WITHOUT ANY WARRANTY; without even the implied warranty of 12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 # General Public License for more details. 14 # 15 # You should have received a copy of the GNU General Public License 16 # along with this program; if not, write to the Free Software 17 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 # 19 20 """ 21 Darwin Session collectors and plugins. 22 """ 23 __author__ = "Adam Sindelar <adamsh@google.com>" 24 25 from rekall import plugin 26 27 from rekall.plugins.darwin import common 28 2931 """Finds sessions by walking their global hashtable.""" 32 33 name = "sessions" 34 type_name = "session" 3554 55 7237 session_hash_table_size = self.profile.get_constant_object( 38 "_sesshash", "unsigned long") 39 40 # The hashtable is an array to session list heads. 41 session_hash_table = self.profile.get_constant_object( 42 "_sesshashtbl", 43 target="Pointer", 44 target_args=dict( 45 target="Array", 46 target_args=dict( 47 target="sesshashhead", 48 count=session_hash_table_size.v()))) 49 50 # We iterate over the table and then over each list. 51 for sesshashhead in session_hash_table: 52 for session in sesshashhead.lh_first.walk_list("s_hash.le_next"): 53 yield [session]
Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Mon Oct 9 03:29:50 2017 | http://epydoc.sourceforge.net |