示例#1
0
PRBool SSLInt_HasCertWithAuthType(PRFileDesc *fd, SSLAuthType authType) {
  sslSocket *ss = ssl_FindSocket(fd);
  if (!ss) {
    return PR_FALSE;
  }

  return (PRBool)(!!ssl_FindServerCertByAuthType(ss, authType));
}
示例#2
0
static void
ssl_RemoveCertAndKeyByAuthType(sslSocket *ss, SSLAuthType authType)
{
    sslServerCert *sc;

    sc = ssl_FindServerCertByAuthType(ss, authType);
    if (sc) {
        (void)ssl_PopulateServerCert(sc, NULL, NULL);
        (void)ssl_PopulateKeyPair(sc, NULL);
        /* Leave the entry linked here because the old API expects that.  There
         * might be OCSP stapling values or signed certificate timestamps still
         * present that will subsequently be used. */
        /* For ECC certificates, also leave the namedCurve parameter on the slot
         * unchanged; the value will be updated when a key is added. */
    }
}