【问题标题】:Pulling from Git fails and gives me following error: client_global_hostkeys_private_confirm: server gave bad signature for RSA key 0从 Git 中提取失败并出现以下错误:client_global_hostkeys_private_confirm: server given bad signature for RSA key 0
【发布时间】:2021-07-27 18:15:58
【问题描述】:

我正在和我的队友一起做一个项目。几周前,我成功地从 git 中提取了项目。但是今天当我想通过命令“git pull origin >”拉取更新的项目时,它给了我以下错误

client_global_hostkeys_private_confirm:服务器为 RSA 密钥 0 提供了错误的签名

我已经使用命令 ssh-keygen 生成了公钥,然后将新生成的文件 id_rsa.pub 的内容粘贴到“Add an Git 的 SSH 密钥”部分,但是 pull 命令不起作用。有人可以帮我吗?

【问题讨论】:

标签: git rsa pull-request ssh-keys git-pull


【解决方案1】:

您忘记告诉我们您使用的是哪个 git 提供程序。

我打赌你正在使用 GitLab。

现在从 GitLab 收到消息“client_global_hostkeys_private_confirm: server give bad signature for RSA key 0”,不是错误,这是一个警告,它与 GitLab 当前遇到的一些 ssh 版本控制问题有关。

如果您希望它消失,您可以确保您的 ~/.ssh/config 包含以下内容:

Host gitlab.com
    UpdateHostKeys no

但是,如果您实际上被阻止拉取,那么这个错误的签名警告可能是不是的原因。一旦你让警告消失,你仍然需要找到你遇到的真正问题,我们对此一无所知,因为问题就在眼前。

【讨论】:

  • 这会有什么潜在的副作用?在其他情况下是否有掩盖严重问题的风险?
  • 如果这是您第一次创建 ~/.ssh/config,请确保您还使用 chmod 0600 ~/.ssh/config 为其授予正确的权限,以防止出现错误“错误的所有者或 [..] 上的权限”
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2015-04-08
  • 1970-01-01
  • 2014-11-04
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多