MCPcopy Create free account
hub / github.com/apache/httpd / ssl_ext_status_hook

Function ssl_ext_status_hook

modules/ssl/ssl_scache.c:197–232  ·  view source on GitHub ↗

_________________________________________________________________ ** ** SSL Extension to mod_status ** _________________________________________________________________ */

Source from the content-addressed store, hash-verified

195** _________________________________________________________________
196*/
197static int ssl_ext_status_hook(request_rec *r, int flags)
198{
199 SSLModConfigRec *mc = myModConfig(r->server);
200
201 if (mc == NULL || mc->sesscache == NULL)
202 return OK;
203
204 if (!(flags & AP_STATUS_SHORT)) {
205 ap_rputs("<hr>\n", r);
206 ap_rputs("<table cellspacing=0 cellpadding=0>\n", r);
207 ap_rputs("<tr><td bgcolor=\"#000000\">\n", r);
208 ap_rputs("<b><font color=\"#ffffff\" face=\"Arial,Helvetica\">SSL/TLS Session Cache Status:</font></b>\r", r);
209 ap_rputs("</td></tr>\n", r);
210 ap_rputs("<tr><td bgcolor=\"#ffffff\">\n", r);
211 }
212 else {
213 ap_rputs("TLSSessionCacheStatus\n", r);
214 }
215
216 if (mc->sesscache->flags & AP_SOCACHE_FLAG_NOTMPSAFE) {
217 ssl_mutex_on(r->server);
218 }
219
220 mc->sesscache->status(mc->sesscache_context, r, flags);
221
222 if (mc->sesscache->flags & AP_SOCACHE_FLAG_NOTMPSAFE) {
223 ssl_mutex_off(r->server);
224 }
225
226 if (!(flags & AP_STATUS_SHORT)) {
227 ap_rputs("</td></tr>\n", r);
228 ap_rputs("</table>\n", r);
229 }
230
231 return OK;
232}
233
234void ssl_scache_status_register(apr_pool_t *p)
235{

Callers

nothing calls this directly

Calls 3

ap_rputsFunction · 0.85
ssl_mutex_onFunction · 0.85
ssl_mutex_offFunction · 0.85

Tested by

no test coverage detected