Changeset 08ba205 in mod_gnutls for src/gnutls_ocsp.c


Ignore:
Timestamp:
Jan 11, 2020, 12:59:30 PM (3 years ago)
Author:
Fiona Klute <fiona.klute@…>
Branches:
asyncio, main, master, proxy-ticket
Children:
1c3853a
Parents:
4e60dd8
Message:

Turn per-vhost OCSP data into an array

Size 1 for now, but it's a required step towards multi-staple.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/gnutls_ocsp.c

    r4e60dd8 r08ba205  
    10401040     * mgs_get_ocsp_response. */
    10411041    apr_global_mutex_lock(sc->ocsp_mutex);
    1042     apr_status_t rv = mgs_cache_ocsp_response(server, sc->ocsp, &expiry);
     1042    apr_status_t rv = mgs_cache_ocsp_response(server, sc->ocsp[0], &expiry);
    10431043
    10441044    apr_interval_time_t next_interval;
     
    11141114
    11151115        apr_status_t rv = mgs_cache_fetch(sc->ocsp_cache, server,
    1116                                           sc->ocsp->fingerprint,
     1116                                          sc->ocsp[0]->fingerprint,
    11171117                                          &ocsp_response,
    11181118                                          pool);
     
    11231123                         "Caching OCSP request failure for %s:%d.",
    11241124                         server->server_hostname, server->addrs->host_port);
    1125             mgs_cache_ocsp_failure(server, sc->ocsp,
     1125            mgs_cache_ocsp_failure(server, sc->ocsp[0],
    11261126                                   sc->ocsp_failure_timeout * 2);
    11271127        }
     
    11481148        return "No issuer (CA) certificate available, cannot enable "
    11491149            "stapling. Please add it to the GnuTLSCertificateFile.";
     1150
     1151    /* array for ocsp data, currently size 1 */
     1152    sc->ocsp = apr_palloc(pconf, sizeof(mgs_ocsp_data_t));
    11501153
    11511154    mgs_ocsp_data_t ocsp = apr_palloc(pconf, sizeof(struct mgs_ocsp_data));
     
    11821185                              apr_pool_cleanup_null);
    11831186
    1184     sc->ocsp = ocsp;
     1187    sc->ocsp[0] = ocsp;
    11851188    return NULL;
    11861189}
Note: See TracChangeset for help on using the changeset viewer.