我们希望使用开放ssl进行双向证书身份验证。
当我们按如下方式打开s_server时,客户端能够连接到我的服务器:
openssl s_server -accept 12345 -cert our-cert.pem(我们的证书是我们的证书。)
这个很好用。不过,我的要求是:
我试过这样做:
openssl s_server -accept 12345 -cert our-cert.pem -CApath /etc/ssl/certs/这允许客户端连接。但我的问题是:
发布于 2013-05-21 06:06:49
发布于 2014-04-10 07:55:16
要测试CA,请使用以下命令:
/usr/local/ssl/bin/openssl s_server -accept 7569 -cert /opt/GCTI/cert/host1_cert.pem -CAfile /opt/GCTI/cert/ca_cert.pem -key /opt/GCTI/cert/host1_priv_key.pem
-cert is the public key file for this host
-key is the private key file for this host
-CAfile is the CA file, needed for self signed certificate
-port is the port number to open up这将打开一个侦听端口7569,该端口将接受带有指定证书的TLS连接。
如果CA无效,则最后一行如下所示
Verify return code: 21 (unable to verify the first certificate)若要连接到此服务器,请进行完整的端到端测试(并不是询问的问题)。
openssl s_client -showcerts -connect host1:7569 -CAfile /opt/GCTI/cert/ca_cert.pem 用实际的主机替换host1。这将验证TLS服务是否有效,并运行由同一个CA签名的证书。
https://stackoverflow.com/questions/16646557
复制相似问题