OS X Mavericks and Keychain Not Accepting Password

I just spent way too long on the phone troubleshooting an issue with my father who was unable to unlock his keychain after upgrading to Mavericks and so could not check his e-mail in Apple Mail. He had not setup the iCloud keychain yet. Here’s a completely unedited brain-dump of what I just had him do to fix his problem.

It turns out that the problem was his default keychain was not named “login.” That’s right, it seems like Mavericks Mail.app is looking in login.keychain for your e-mail passwords and not <insert name of default keychain>.keychain.

Here’s how to confirm this is your situation:

Keychain Access without login keychain as default

  • Open Keychain Access (Applications > Utilities > Keychain Access.app)
  • Look in the upper-left of the window
    • The bolded keychain is your default keychain. In this case, gfiumara and not “login.”
  • If login is not bolded, select login and look in the list to the right
    • Are there just a handful of items in the list to the right?
  • Select the bolded keychain
    • Are there many more items in this list?

If you answered affirmative above, you’re in the same situation. The Mavericks installer created you a login.keychain and now Mail is looking there for your mail passwords.  Unfortunately, you have no idea what the password for that keychain is.  Let’s just change the name of your default keychain.

  • Quit Keychain Access
  • Open Terminal (Applications > Utilities > Terminal.app)
  • cd ~/Library/Keychains
  • mv login.keychain login_backup.keychain
  • mv gfiumara.keychain login.keychain
  • open -a Keychain\ Access.app
    • This opened Keychain Access again.
    • login and gfiumara in this list (where gfiumara is the name of the bolded keychain in the steps above), now have a square next to them instead of a lock.
    • Select each and press the delete key on your keyboard choosing Delete References and not Delete References and Files
    • Switch back to Terminal
  • open login.keychain
    • This opens Keychain Access again, and you should see login in the Keychains list in the top left
    • Right click login and choose “Make Keychain “login” Default”
  • Restart your Mac

You’ve renamed your default keychain login and backed up the old login keychain to ~/Library/Keychains/login_back.keychain. If you did have passwords in that keychain, you can open that file and add it to Keychain Access again. It will be in the list as “login_back.”

7 thoughts on “OS X Mavericks and Keychain Not Accepting Password

  1. Hey, really interesting post.

    But let’s say I added my old keychain to Mavericks and I set it as default, reads all passwords etc etc, so works fine.

    However, every time I use a password on Safari from my login keychain, the password is now added to a keychain called “local items”.

    -And what intrigues me the most is that if I were to add new passwords, they all go to “local items” keychain, and bypass my old “login” keychain, regardless of it being marked as default.

  2. I’m not having that problem, but I think Local Items has something to do with the new iCloud Keychain sync, which I have turned off. I think Local Items is a local copy of what’s in iCloud. This might be what you’re seeing.

  3. Thanks that really helped. Long ago, I had created default a keychain based on my user name. (Or maybe that was how Apple did it long ago? I have been using OS X since BETA.)

  4. Your blog saved me! Thank you so much! I had tried to solve the problem by creating a link from a keychain with my name to login.keychain. But this did not help. Only copying the keychain “my_name.keychain” to login.keychain worked: After this, in “Keychain Access” only “login” appears now, and Mail finally works after an eternity. I am keeping my fingers crossed that this didn’t create other issues …

  5. Hi – I don’t see login in the Keychains list in the top left after doing what you said. Should I restart?

  6. In terminal I typed again the last command to open and it says “login.keychain does not exist”. I did only delete references and not files. What to do? Thanks.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.