Changeset 506e64a in mod_gnutls


Ignore:
Timestamp:
Apr 19, 2018, 2:13:09 PM (3 years ago)
Author:
Fiona Klute <fiona.klute@…>
Branches:
asyncio, debian/master, master, proxy-ticket
Children:
a467635
Parents:
0e3f8c6
Message:

Optionally return cache expiry time when caching an OCSP response

This will be needed to adjust intervals of OCSP watchdog callbacks.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/gnutls_ocsp.c

    r0e3f8c6 r506e64a  
    594594
    595595
    596 apr_status_t mgs_cache_ocsp_response(server_rec *s)
     596/**
     597 * Get a fresh OCSP response and put it into the cache.
     598 *
     599 * @param s server that needs a new response
     600 *
     601 * @param cache_expiry If not `NULL`, this `apr_time_t` will be set to
     602 * the expiration time of the cache entry. Remains unchanged on
     603 * failure.
     604 *
     605 * @return APR_SUCCESS or an APR error code
     606 */
     607static apr_status_t mgs_cache_ocsp_response(server_rec *s,
     608                                            apr_time_t *cache_expiry)
    597609{
    598610    mgs_srvconf_rec *sc = (mgs_srvconf_rec *)
     
    700712        return APR_EGENERAL;
    701713    }
     714
     715    if (cache_expiry != NULL)
     716        *cache_expiry = expiry;
    702717    return APR_SUCCESS;
    703718}
     
    801816    }
    802817
    803     rv = mgs_cache_ocsp_response(ctxt->c->base_server);
     818    rv = mgs_cache_ocsp_response(ctxt->c->base_server, NULL);
    804819    if (rv != APR_SUCCESS)
    805820    {
Note: See TracChangeset for help on using the changeset viewer.