Setting Up SSH Keys on macOS with Touch ID

(nmattia.com)

17 points | by civilchaos 2 hours ago

6 comments

  • QGQBGdeZREunxLe 3 minutes ago
    Sounds complicated. Just install https://secretive.dev/
  • maratc 55 minutes ago
    > No key files (like ~/.ssh/id_ed25519.pub and friends) littering the file system; and there’s no risk of mistakenly deleting them either.

    Or backing them up, or copying them to your new computer. You're just one spilled coffee cup away from losing the key.

    • jiehong 24 minutes ago
      Yes, this only works if you can register more than 1 ssh keys on the services you want.
  • vr46 29 minutes ago
    As cool as this is, this does limit the functionality of your keys, because not everything can access the secure enclave in the way it wants to - and as others point out, this is a one-way street and locks your mac hardware into the flow.

    I went with this system for some months but it ultimately broke my workflow. I switched to a system of my own devising, in which my local security key decrypts the SSH keys I require.

  • ggm 2 hours ago
    If you do this, have at least one backup key (if need be on paper) or a guaranteed alternate path into the hosts you depend on this key to access. Because if the secure enclave is as good as we're told, if you lose access to ->THIS<- secure enclave, its game over for the keys.

    Secure enclave protecting Keychain, the keychain is backed up. Not the contents of the enclave.

    Too many failed access attempts? poof the key is gone. Could be as low as 10.

    (happy to be corrected. This is what I gather from a quick read-around. I was a bit surprised the site didn't seem to discuss this)

    • solatic 5 minutes ago
      Your backup key should also be in a secure enclave, just in a different secure enclave. Both keys should be accepted by the system.

      The truly paranoid can multiple types of secure enclaves - TouchID for primary, a YubiKey for backup.

      > If need be on paper

      Your security is only as strong as its weakest link. Paper has a way of getting photographed, and the privacy of your key depends on your OCR software, unless you really want to painstakingly copy it in by hand, and even then, it turns into a file-based key on the filesystem, with all its attendant risks.

  • elmcrest 39 minutes ago
    happy 1Password user since years, provides this too and you'll have you ssh keys in the 1P keychain (yes, not open source, I know - only flaw imho)
    • lmz 37 minutes ago
      That would make it extractable and syncable to other hosts. That's fine if that's what you want but it's an important distinction.
  • rektlessness 4 minutes ago
    [dead]