/* Licensed to the Apache Software Foundation (ASF) under one or more *contributorlicenseagreements.SeetheNOTICEfiledistributedwith *thisworkforadditionalinformationregardingcopyrightownership. *TheASFlicensesthisfiletoYouundertheApacheLicense,Version2.0 *(the"License");youmaynotusethisfileexceptincompliancewith *theLicense.YoumayobtainacopyoftheLicenseat * *http://www.apache.org/licenses/LICENSE-2.0 * *Unlessrequiredbyapplicablelaworagreedtoinwriting,software *distributedundertheLicenseisdistributedonan"ASIS"BASIS, *WITHOUTWARRANTIESORCONDITIONSOFANYKIND,eitherexpressorimplied. *SeetheLicenseforthespecificlanguagegoverningpermissionsand *limitationsundertheLicense.
*/
/* mod_watchdog invoked us as a single thread inside the whole server (on this machine). *Thismightbearepeatedruninsidethesamechild(mod_watchdogkeepsaffinityas *longasthechildlives)oranother/newchild.
*/ switch (state) { case AP_WATCHDOG_STATE_STARTING:
ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, octx->s, APLOGNO(10197) "md ocsp watchdog start, ocsp stapling %d certificates",
(int)md_ocsp_count(octx->mc->ocsp)); break;
/* Process all drive jobs. They will update their next_run property *andwescheduleourselfattheearliestofall.Ajobmayspecify0 *asnext_runtoindicatethatitwantstoparticipateinthenormal
* regular runs. */
next_run = next_run_default();
if (!wd_get_instance || !wd_register_callback || !wd_set_interval) {
ap_log_error(APLOG_MARK, APLOG_CRIT, 0, s, APLOGNO(10201) "mod_watchdog is required for OCSP stapling"); return APR_EGENERAL;
}
/* We want our own pool with own allocator to keep data across watchdog invocations. *Sincewe'llruninasinglewatchdogthread,usingourownallocatorwillprevent
* any confusion in the parent pool. */
apr_allocator_create(&allocator);
apr_allocator_max_free_set(allocator, 1);
rv = apr_pool_create_ex(&octxp, p, NULL, allocator); if (rv != APR_SUCCESS) {
ap_log_error(APLOG_MARK, APLOG_ERR, rv, s, APLOGNO(10205) "md_ocsp_watchdog: create pool"); return rv;
}
apr_allocator_owner_set(allocator, octxp);
apr_pool_tag(octxp, "md_ocsp_watchdog");
/* Time for some house keeping, before the server goes live (again): *-westoreOCSPresponsesforeachcertificateindividuallybyitsSHA-1id *-thismeans,aslongascertificatedonotchange,thenumberofresponse *filesremainsstable. *-Butwhenacertificatechanges(isreplaced),theresponseisobsolete *-wedonotgetnotifiedwhenacertificateisnolongerused.Anadmin *mightjustreconfigureorchangethecontentofafile(backup/restoreetc.) *-also,certificatesmightbeaddedbysomeopensslconfigcommandsorother *modulesthatwedonotimmediatelyseerightatstartup.Wecannotassume *thatanyOCSPresponsewecannotrelatetoacertificateRIGHTNOW,isno *longerneeded. *-sincetheresponsefilesarerelativelysmall,wehavenoproblemwith *keepingthemaroundforawhile.Wejustdonotwantanevergrowingstore. *-Thesimplestandeffectivewayseemstobetojustremovefilesolder *acertainamountoftime.Takea7daydefaultandlettheadminconfigure *itforveryspecialsetups.
*/
ocsp_remove_old_responses(mc, octx->p);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.