首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何摆脱这种反复无常的警告?(主机安全/主机指纹)

如何摆脱这种反复无常的警告?(主机安全/主机指纹)
EN

Stack Overflow用户
提问于 2018-05-03 22:37:19
回答 1查看 733关注 0票数 1

自从我使用Mercurial 4.5.3迁移到Ubuntu 18.04之后,我看到了以下警告:

(SHA-1 fingerprint for bitbucket.org found in legacy [hostfingerprints] section; if you trust this fingerprint, remove the old SHA-1 fingerprint from [hostfingerprints] and add the following entry to the new [hostsecurity] section: bitbucket.org:fingerprints=sha256:32:12:90:9a:70:64:82:1c:5b:52:cc:c3:0a:d0:79:db:e1:a8:62:1b:9a:9a:4c:f4:72:40:1c:a7:3a:d3:0a:8c)

现在我理解并感谢你的警告了。然而,我想要让它安静下来。最好通过在.hgrc中添加相应的部分和条目

代码语言:javascript
复制
[hostsecurity]
bitbucket.org:fingerprints=sha256:32:12:90:9a:70:64:82:1c:5b:52:cc:c3:0a:d0:79:db:e1:a8:62:1b:9a:9a:4c:f4:72:40:1c:a7:3a:d3:0a:8c

但是,无论我是否将新的[hostsecurity]部分放在旧的[hostfingerprints]部分之前,警告都会继续显示。因此,我正在寻找一种方法来使其静默,最好只针对该主机名和.hgrc内部。

不像一些快乐的人总是可以专门使用最新的发行版版本,我仍然有一些相当老的发行版版本在他们上面运行和Mercurial。因此,旧的条目是必需的,尤其是在那些较旧的Mercurial版本上。

EN

回答 1

Stack Overflow用户

发布于 2019-02-12 23:39:01

首先删除(注释掉) hostfingerprints部分:

代码语言:javascript
复制
# [hostfingerprints]
# bitbucket.org = ..:..:...

然后添加新的hostsecurity部分:

代码语言:javascript
复制
hostsecurity]
bitbucket.org = sha256:..:..:... (with whatever the error message suggests)

看起来您不能像警告所建议的那样使用bitbucket.org:fingerprints=...节。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/50157687

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档