如何从命令行获得Ubuntu,而不是受信任的证书?我使用了以下命令:
true | openssl s_client -connect google.com:443 2>/dev/null | openssl x509
仅在受信任时才返回证书,但是如果不安全,则会报错
true | openssl s_client -connect google.com:443 2>/dev/null | openssl x509
unable to lead certificate
140452707443136:error:0906D06C:PEM routines:PEM_READ_BIO:no start
line:../crypto/pem/pem_lib.c691: Expecting: TRUSTED CERTIFICATE