我正在尝试使用visual studio克隆存储库,但此消息显示
Host key verification failed.
fatal: Could not read from remote repository.
我已经创建了一个ssh密钥并复制了pub密钥
ssh-keygen
cat /c/Users/Toshiba/.ssh/id_rsa.pub
并添加到我的gitlab帐户当我试图从git bash中克隆它时,我得到
The authenticity of host 'gitlab.com (2606:4700:90:0:f22e:fbec:5bed:a9b9)' can't be established.
ED25519 key fingerprint is SHA256:eUXGGm1YGsMAS7vkcx6JOJdOGHPem5gQp4taiCfCLB8.
This key is not known by any other names
Are you sure you want to continue connecting (yes/no/[fingerprint])?
我该怎么办?
输入yes是一回事。但是如果提出的指纹确实是远程GitLab服务器的指纹,那么首先检查是明智的。
gitlab.com
的结果如下图所示。
由于您看到的(SHA256:eUXGGm1YGsMAS7vkcx6JOJdOGHPem5gQp4taiCfCLB8
)与其中一个匹配,您可以键入yes,并更新您自己的c/Users/Toshiba/.ssh/known_hosts
文件。
有一个建议(issue 25142)在服务器端暴露这些指纹,在GitLab 10.2(2017年11月)中使用MR 13850(并提交f913f7a)实现。