0

My Mac used as a developing machine was down a few days ago. It turned out an issue of the HDD. Unfortunately, I forgot to backup my private keys for iOS development and distribution. So, I can't debug or distribute my apps now. I find that the old driver is still readable as a mobile HDD, but I just can't start the system on it(I've tried all well-known tools to recover but none of them worked).

Is it possible to get my private keys back from that driver? If not, what can I do as remediation?

Thanks in advance!

Derek

4

1 回答 1

0

I'm not an iOS developer, but I'm pretty sure the keys are handled the same was as for a Mac developer: stored in your keychain. If this is the case, and you can mount the old HD, you should be able to recover the old keychain pretty easily:

  1. Mount the old HD, and navigate into your old home folder in the Finder.
  2. Open the hidden Library folder by choosing File menu > Go to Folder, then entering "Library" in the dialog.
  3. Inside the Library, open the Keychains subfolder.
  4. Copy Login.keychain to your new HD. This would also be a really good time to make a backup copy somewhere else as well.

At this point, you have a couple of choices. You can either migrate the relevant entries from your old keychain to the one in your new account (which may be tricky, 'cause they may not be easy to spot among all the other things stored in your old keychain), or just replace your new account's keychain with the old one (which means any new passwords etc you've memorized since swapping HDs will be unavailable). For the first option:

  1. Rename the old keychain (to something like Old Login.keychain), then double-click it to open it in Keychain Access.
  2. Unlock the old keychain by selecting it in the sidebar, then clicking the padlock icon near the top and entering your old login password.
  3. Select the relevant items (good luck finding them all!), and drag them over to your current "Login" keychain in the sidebar. Authenticate as requested.

For the second option:

  1. Quit everything except the Finder.
  2. Open your current user Library folder (the easiest way to do this is to hold the Option key, pull down the Go menu, and choose Library.
  3. Rename the current Login.keychain to something else, then move the old Login.keychain into its place.
  4. Log out and back in. If your old login password was different than your new one, you'll get an error unlocking the keychain with an option to fix it by entering the old login password.
于 2013-02-06T18:02:47.450 回答