14

As stated in the title, I would like to import a key pair into Keychain Access.

What I have done:

  1. Obtaining an RSA public / private key pair by using OpenSSH

What I am going to do:

  1. Importing the key pair into the "login" keychain of Keychain Access
  2. Creating a CSR with OpenSSL
  3. Send the CSR to Apple for obtaining a developer certificate

Any suggestions are welcomed.

1 Answers1

21

Found the answer by myself:

Open Terminal.app:

$ security import developer_rsa_key -k login.keychain -t priv -f openssh2
1 key imported.
$ security import developer_rsa_key.pub -k login.keychain -t pub -f openssh2
1 key imported.
  • After importing the keys into the keychain, how were you able to use them? I would like to have `ssh` or `ssh-add` be able to use keys directly from the keychain but it seems they will only use the keychain for passphrases that protect the key files (which still have to exist on the file system), not for the keys themselves. – Old Pro May 08 '21 at 06:26