tlsSocket.getCertificate()
- 返回:<Object>
返回一个表示本地证书的对象。返回的对象具有一些对应证书字段的属性。
🌐 Returns an object representing the local certificate. The returned object has some properties corresponding to the fields of the certificate.
有关证书结构的示例,请参见 tls.TLSSocket.getPeerCertificate()。
🌐 See tls.TLSSocket.getPeerCertificate() for an example of the certificate
structure.
如果没有本地证书,将返回一个空对象。如果套接字已被销毁,将返回 null。
🌐 If there is no local certificate, an empty object will be returned. If the
socket has been destroyed, null will be returned.