kristovatlas / osx-config-check

Verify the configuration of your OS X machine.
MIT License
1.25k stars 112 forks source link

add config: ensure ssh passphrase is not stored ind macOS keychain #172

Open kristovatlas opened 7 years ago

kristovatlas commented 7 years ago

https://www.reddit.com/r/netsec/comments/56505q/macos_sierra_permanently_remembers_ssh_key/d8gxld3

Is appears that macOS Sierra is storing the keychain in ~/Library/Keychains//keychain-2.db Oddly, this database is not able to be opened with Keychain Access, due to the different file format. If you've got an ssh key passphrase that Sierra has stored, but you want to remove, it looks like you can delete the above directory. It's not clear what else might be stashed in there, so you may lose passwords other than your SSH key. Also, to prevent it from storing the passphrase in the future, add to ~/.ssh/config:

Host *
    UseKeyChain no