Created
March 9, 2018 23:04
-
-
Save lekv/82d258803d634307fb3123dfc97601aa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import sys | |
from collections import namedtuple | |
from datetime import datetime | |
from struct import Struct | |
MDRawHeader = namedtuple("MDRawHeader", "signature version stream_count \ | |
stream_directory_rva checksum time_date_stamp flags") | |
minidump = sys.argv[1] | |
s = Struct("IIIiIIQ") | |
data = open(minidump, 'rb').read(s.size) | |
header = MDRawHeader(*s.unpack_from(data)) | |
created = datetime.utcfromtimestamp(header.time_date_stamp) | |
print "Minidump was created at: %s UTC (%s)" % (created, header.time_date_stamp) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment