Visitar URL original
`ssh_keygen()` needs to add requirements to RSA keys · Issue #23 · r-lib/credentials · GitHub
Skip to content

ssh_keygen() needs to add requirements to RSA keys #23

Closed

Description

@psychelzh

Currently, ssh_keygen() creates an RSA key with SHA-1, which is not allowed now. See this Github blog.

This might cause error in usethis::use_github_release() (r-lib/usethis#1634).

Error in libgit2::git_remote_fetch : 
  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.
Please see https://github.blog/2021-09-01-improving-git-protocol-security-github/ for more information.

Activity

  1. jeroen commented on Sep 5, 2022

    @jeroen
    Member

    Thanks I am aware. The SHA-1 is not part of the key, but generated by the ssh client. I am aware of the problem, sadly SHA-2 is not available yet in the latest release version of libssh2 (which is what libgit2 uses). Hopefully soon:

    Maybe we should switch the default key to ecdsa in the mean while.

  2. jeroen commented on Sep 5, 2022

    @jeroen
    Member

    I have changed ssh_keygen to generate ECDSA keys by default. Can you try again?

  3. psychelzh commented on Sep 5, 2022

    @psychelzh
    Author

    Thanks! It works now! 👍

  4. jeroen commented on Sep 6, 2022

    @jeroen
    Member

    FYI I implemented a fix in gert 1.8.0 such that RSA keys work again, so I may revert this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions