In Mac OS X 10.11 (“El Capitan”) Apple replaced the good old “Disk Utility.app” with a completely overhauled and colorful but less powerful version. Many features have been sacrificed in favor of an easier and more usable UI. This post explains how to get that old version back.
DISCLAIMER: Using an outdated version of a system utility bears a lot of risks and may result in the complete loss or corruption of your data. If you’re doing this, you are on your own and Apple will certainly not support you in a way. This is where the fun begins! 😀
I cannot provide the binary of the patched Disk Utility as a download since that would violate Apple’s copyright. Instead, I will explain how you can patch the file yourself:
- Open Time Machine to get a copy of the pre-“El Capitan” Disk Utility:
- Go to the Utilities folder (or simply press Command + Shift + U)
- Browse back in time to a backup before you installed El Capitan. Select the Disk Utility app and restore it to a place of your choosing. I use the Desktop. You will have to enter your password, that’s okay.
- Download a Hex editor like the free Hex Fiend.
- Open the Terminal app (which also resides in the Utilities folder, remember: Command + Shift + U) and verify that you have the same version of Disk Utility as me because otherwise the patch will not work (you may have to adapt this to your paths):
$ openssl dgst -sha256 ~/Desktop/Disk\ Utility.app/Contents/MacOS/Disk\ Utility SHA256(/Users/demo/Desktop/Disk Utility.app/Contents/MacOS/Disk Utility)= 48529e0206d5f238b96f59bd0a4be7817ebe5d63cf4abee0d8c1529c54bf2d78
If the computed hash value (that long hex number) is the same for you as it is for me you can continue.
- Open the restored Disk Utility in Hex Fiend with admin privileges with this command (again adapt the paths to your own):
$ sudo ~/Downloads/Hex\ Fiend.app/Contents/MacOS/Hex\ Fiend ~/Desktop/Disk\ Utility.app/Contents/MacOS/Disk\ Utility
- Scroll down to offset 25056, which is the line where this number appears on the grey’ish bar on the left side of the editor:
- As in the screenshot above you should see these two words (yes, they are called like that):
- Select the ’85’ in the right word and change it for ’84’. Take care that you overwrite the number instead of insert it. Afterwards it should read:
- Save the file and close Hex Fiend.
- You can make sure that you did the patch right by calculating another SHA256 hash on the patched file like this (again compare the long hex number):
openssl dgst -sha256 ~/Desktop/Disk\ Utility.app/Contents/MacOS/Disk\ Utility SHA256(/Users/demo/Desktop/Disk Utility.app/Contents/MacOS/Disk Utility)= 0b9683c6193e011169f39ab7a5565b9eac84d5d1e83f055abc9a5d8ab2e896b0
- Done: Run the app from your desktop.
You just changed a processor instruction in the application from JNE (Jump Not Equal, opcode 0F 85) to JE (Jump Equal, opcode 0F 84). Basically it is like this: Disk Utility checks if your system version matches its expectation. If this is not the case (= not equal), it shows a message and terminates. The patch above changes that check: The code now says that if the version does match the expectation (i.e. is equal), it will complain. In other words: This patched version of Disk Utility will not work on any system it was intended to work on, but will start just fine on any other.