Heroku

Generate SSH Keys for Xcode

Generate SSH Keys for Xcode

When using a private repository with SwiftPackageManager, git@~ URL is used, but of course SSH setting is required at that time.
If you are using GitHub, set the public key to GitHub and the private key to Mac.
However, when I tried to fetch the Private repository as above in Xcode using the RSA key I’ve been using, I got the following error.

You're using an RSA key with SHA-1, which is no longer allowed. Please use a newer client or a different key type.

So I investigated how to avoid this, and I will summarize it as a memorandum.

Generate a key for Ed25519

The reason for the above error is that a new format of keys has appeared, and the security of the RSA format has become relatively weaker, so error says please use the new format! about it!

This time, I needed to use it on Heroku for another reason, so I made a key in the Ed25519 format that can be used on both SPM and Heroku!

$ ssh-keygen -o -a 100 -t ecdsa

This will generate a private/public key pair.

I successfully fetched the repository.!🎉

Reference

  • https://qiita.com/MachonglishproK/items/42a8380240629297743a
  • https://linuxfan.info/ssh-ed25519
0

COMMENT

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

CAPTCHA