gpt4 book ai didi

ssl - 此证书缺少 "hosts"字段。这使得它不适用于网站

转载 作者:太空宇宙 更新时间:2023-11-03 13:58:27 24 4
gpt4 key购买 nike

当我执行此命令生成 kubernetes 证书时:

cfssl gencert -ca=ca.pem -ca-key=ca-key.pem \
-config=ca-config.json \
-profile=kubernetes \
kubernetes-csr.json | cfssljson -bare kubernetes

为什么 cfssl 采取显示:

[root@iZuf63refzweg1d9dh94t8Z ssl]# cfssl gencert -ca=ca.pem -ca-key=ca-key.pem \
> -config=ca-config.json \
> -profile=kubernetes \
> kubernetes-csr.json | cfssljson -bare kubernetes
2019/08/25 20:02:12 [INFO] generate received request
2019/08/25 20:02:12 [INFO] received CSR
2019/08/25 20:02:12 [INFO] generating key: rsa-2048
2019/08/25 20:02:13 [INFO] encoded CSR
2019/08/25 20:02:13 [INFO] signed certificate with serial number 540759253485135214776496461610290604881680785507
2019/08/25 20:02:13 [WARNING] This certificate lacks a "hosts" field. This makes it unsuitable for
websites. For more information see the Baseline Requirements for the Issuance and Management
of Publicly-Trusted Certificates, v.1.1.6, from the CA/Browser Forum (https://cabforum.org);
specifically, section 10.2.3 ("Information Requirements").

这是我的 kubernetes(kubernetes-csr.json) 配置:

{
"CN": "kubernetes",
"hosts": [
"127.0.0.1",
"172.19.104.230",
"172.19.150.82",
"172.19.104.231"
],
"key": {
"algo": "rsa",
"size": 2048
},
"names": [
{
"C": "CN",
"ST": "BeiJing",
"L": "BeiJing",
"O": "k8s",
"OU": "System"
}
]
}

显然它包含主机字段。我正在使用 cfssl 1.2 版。这是一个错误吗?

最佳答案

将 cfssl 版本从 v1.2 更新到 v1.3.4(最新版本):

go get -u github.com/cloudflare/cfssl/cmd/cfssl

关于ssl - 此证书缺少 "hosts"字段。这使得它不适用于网站,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57645888/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com