Changeset 556783e in mod_gnutls for src/gnutls_hooks.c


Ignore:
Timestamp:
Jul 24, 2019, 2:29:40 AM (2 years ago)
Author:
Fiona Klute <fiona.klute@…>
Branches:
asyncio, master, proxy-ticket
Children:
e376ed8
Parents:
81018a4
Message:

Provide OCSP response via gnutls_certificate_retrieve_function3 callback

This replaces the old OCSP callback function, which is still used
internally.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/gnutls_hooks.c

    r81018a4 r556783e  
    409409        *privkey = ctxt->sc->privkey_x509;
    410410        *flags = 0;
     411
     412        if (ctxt->sc->ocsp_staple == GNUTLS_ENABLED_TRUE)
     413        {
     414            gnutls_ocsp_data_st *resp =
     415                apr_palloc(ctxt->c->pool, sizeof(gnutls_ocsp_data_st));
     416            resp->version = 0;
     417            resp->exptime = 0;
     418
     419            int ret = mgs_get_ocsp_response(session, NULL, &resp->response);
     420            if (ret == GNUTLS_E_SUCCESS)
     421            {
     422                *ocsp = resp;
     423                *ocsp_length = 1;
     424            }
     425        }
     426
    411427        return 0;
    412428    } else {
Note: See TracChangeset for help on using the changeset viewer.