arandomdev / DyldExtractor

Extract Binaries from Apple's Dyld Shared Cache

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cache's magic does not start with 'dyld', most likely given a file that's not a cache or the file is broken.

zy364601065 opened this issue · comments

system % dyldex_all dyld_shared_cache_arm64e
Traceback (most recent call last):
File "/usr/local/bin/dyldex_all", line 299, in
_main()
File "/usr/local/bin/dyldex_all", line 228, in _main
dyldCtx = DyldContext(f)
File "/usr/local/lib/python3.10/site-packages/DyldExtractor/dyld/dyld_context.py", line 36, in init
raise ValueError("Cache's magic does not start with 'dyld', most likely given a file that's not a cache or the file is broken.") # noqa
ValueError: Cache's magic does not start with 'dyld', most likely given a file that's not a cache or the file is broken.

Where did you get the cache file from?

Get from /System/Library/Caches/com.apple.dyld/
iPhone system is iOS 13.1.3

It says that it's probably broken, are you able to open the cache file in a hex editor and tell me what the first few bytes are? It should be like something here, where the first 4 are dyld.

If not, can you send the file to me? My email is haow6449@gmail.com.

I will send the document to you. Thank you for your reply

Okay, I looked at your file, and it seems that the first 0x2c580 bytes are all zeros, which is not correct.
I don't know how you got your file, but I suggest using SCP if you have a jail broken phone, or directly extracting it from an IPSW. https://github.com/blacktop/ipsw.