Book Image

Python Digital Forensics Cookbook

By : Chapin Bryce, Preston Miller
Book Image

Python Digital Forensics Cookbook

By: Chapin Bryce, Preston Miller

Overview of this book

Technology plays an increasingly large role in our daily lives and shows no sign of stopping. Now, more than ever, it is paramount that an investigator develops programming expertise to deal with increasingly large datasets. By leveraging the Python recipes explored throughout this book, we make the complex simple, quickly extracting relevant information from large datasets. You will explore, develop, and deploy Python code and libraries to provide meaningful results that can be immediately applied to your investigations. Throughout the Python Digital Forensics Cookbook, recipes include topics such as working with forensic evidence containers, parsing mobile and desktop operating system artifacts, extracting embedded metadata from documents and executables, and identifying indicators of compromise. You will also learn to integrate scripts with Application Program Interfaces (APIs) such as VirusTotal and PassiveTotal, and tools such as Axiom, Cellebrite, and EnCase. By the end of the book, you will have a sound understanding of Python and how you can use it to process artifacts in your investigations.
Table of Contents (11 chapters)

About time

Recipe Difficulty: Easy

Python Version: 2.7 or 3.5

Operating System: Any

One important element of any good log file is the timestamp. This value conveys the date and time of the activity or event noted in the log. These date values can come in many formats and may be represented as numbers or hexadecimal values. Outside of logs, different files and artifacts store dates in different manners, even if the data type remains the same. A common differentiating factor is the epoch value, which is the date that the format counts time from. A common epoch is January 1, 1970, though other formats count from January 1, 1601. Another factor that differs between formats is the interval used for counting. While it is common to see formats that count seconds or milliseconds, some formats count blocks of time, such as the number of 100-nanoseconds since the epoch. Because of this...