Repository navigation
Add support for iTunes/Finder backups. - #84
Conversation
…type to switches. Adds FileSeekerItunes class to search_files which opens up Manifest.db and builds a dict of each file path to the fileID. Then upon a search it copies out a file that matches to have the appropriate path in a temp folder. Creates this seeker from ileapp.py. Signed-off-by: Three Planets Software <[email protected]>
Thanks. Keeping it simple and readable is the point, so more people can contribute easily. I will test it out with the couple of itunes backups I have, then merge it. Seems straightforward, we should have done this a long time ago.. Thanks again! |
|
Few things:
|
|
Great point, fixing the first bullet to use os.path.join made the code I had not yet submitted for the GUI work (yes, the lack of a trailing slash was an issue). |
… not have permission to see.
|
Finally, I was going to open an issue and submit a separate PR, but figured I would just put it in here. I have a logical extraction which retained the original file properties (including ownership by root of some folders). When I ran the GUI to check if the above changes hurt anything, it died, due to lack of permission: [notta@cuppa iLEAPP]$ python ileappGUI.py
Traceback (most recent call last):
File "ileappGUI.py", line 153, in <module>
ileapp.crunch_artifacts(search_list, extracttype, input_path, out_params, len(ileapp.tosearch)/s_items)
File "/home/notta/data/programming/python/iLEAPP/ileapp.py", line 60, in crunch_artifacts
seeker = FileSeekerDir(input_path)
File "/home/notta/data/programming/python/iLEAPP/scripts/search_files.py", line 27, in __init__
self.build_files_list(directory)
File "/home/notta/data/programming/python/iLEAPP/scripts/search_files.py", line 35, in build_files_list
self.build_files_list(item.path)
File "/home/notta/data/programming/python/iLEAPP/scripts/search_files.py", line 35, in build_files_list
self.build_files_list(item.path)
File "/home/notta/data/programming/python/iLEAPP/scripts/search_files.py", line 35, in build_files_list
self.build_files_list(item.path)
File "/home/notta/data/programming/python/iLEAPP/scripts/search_files.py", line 31, in build_files_list
files_list = os.scandir(directory)
PermissionError: [Errno 13] Permission denied: '/home/notta/phone_rips/iphone/iOS13_logical/private/var/.DocumentRevisions-V100'I've added a try/except block around the directory read such that it will fail a bit nicer and log the resulting failure if found. The log after the run looks like: If you want this as a separate issue/PR for tracking, happy to mvoe it, but since this was in a file I already touched, I hope this is acceptable. |
That looks good. We can merge it all at once. Unfortunately it is still having path issues on windows -
If you use Pathlib, this may be easier as it can handle mixed style paths. If not, I can fix this later tomorrow and merge it all. |
|
My apologies. I broke a Windows evaluation copy out to test this last fix and this should hopefully work. The one thing I didn't do as you did in other areas was prepend |
|
Thank you all so much. This is good stuff!!! |
I do most of my research using a phone connected to a Mac, syncing via finder and SSH'ing the results over to the real development box. I noticed that iLEAPP didn't handle iTunes/Finder backups and wanted to see its output for something, so I added that in. This currently only handles the CLI-version, I haven't looked at the GUI yet.
I have to say, I generally dislike python, but you have some very easy to read code! Nice work.