initial code for dumping imessages in a reasonable format

This commit is contained in:
Jeffrey Paul committed 2014-02-09 00:30:49 +01:00
1 parent c0021efb13
commit 9dd7628f04
157 files changed
+24178

No files matched your search

@@ -0,0 +1,12 @@
import sqlite3
from keychain3 import Keychain3
from keychain4 import Keychain4
def keychain_load(filename, keybag, key835):
version = sqlite3.connect(filename).execute("SELECT version FROM tversion").fetchone()[0]
#print "Keychain version : %d" % version
if version == 3:
return Keychain3(filename, key835)
elif version >= 4:
return Keychain4(filename, keybag)
raise Exception("Unknown keychain version %d" % version)