Lines Matching refs:cert
477 /* verify code for cert validation error */
1755 #include "_ssl/cert.c"
1770 BIO *cert;
1773 if ((cert=BIO_new(BIO_s_file())) == NULL) {
1779 if (BIO_read_filename(cert, PyBytes_AsString(path)) <= 0) {
1785 x = PEM_read_bio_X509(cert, NULL, NULL, NULL);
1797 if (cert != NULL) BIO_free(cert);
1836 /* return cert in DER-encoded format */
1886 /* OpenSSL does not include peer cert for server side connections */
3978 X509 *cert = NULL;
3982 cert = d2i_X509_bio(biobuf, NULL);
3984 cert = PEM_read_bio_X509(biobuf, NULL,
3989 if (cert == NULL) {
3992 r = X509_STORE_add_cert(store, cert);
3993 X509_free(cert);
3998 /* cert already in hash table, not an error */
4584 inside the context's cert store.
4602 PyErr_SetString(PyExc_MemoryError, "failed to query cert store");
4657 PyErr_SetString(PyExc_MemoryError, "failed to query cert store");
4663 X509 *cert;
4667 /* not a x509 cert */
4671 cert = X509_OBJECT_get0_X509(obj);
4672 if (!X509_check_ca(cert)) {
4676 ci = _certificate_to_der(get_state_ctx(self), cert);
4678 ci = _decode_certificate(get_state_ctx(self), cert);
5539 Retrieve certificates from Windows' cert store.
5542 more cert storages, too. The function returns a list of (bytes,
5554 PyObject *keyusage = NULL, *cert = NULL, *enc = NULL, *tup = NULL;
5568 cert = PyBytes_FromStringAndSize((const char*)pCertCtx->pbCertEncoded,
5570 if (!cert) {
5591 PyTuple_SET_ITEM(tup, 0, cert);
5592 cert = NULL;
5609 /* In error cases cert, enc and tup may not be NULL */
5610 Py_XDECREF(cert);
5638 Retrieve CRLs from Windows' cert store.
5641 more cert storages, too. The function returns a list of (bytes,
5697 /* In error cases cert, enc and tup may not be NULL */
5859 /* cert requirements */