/*++ /* NAME /* tlsmgrmem 3 /* SUMMARY /* Memory-based TLS manager interface for tlsfinger(1). /* SYNOPSIS /* #ifdef USE_TLS /* #include <tlsmgrmem.h> /* /* void tlsmgrmem_disable() /* /* void tlsmgrmem_status(enable, count, hits) /* int *enable; /* int *count; /* int *hits; /* /* void tlsmgrmem_flush() /* #endif /* DESCRIPTION /* tlsmgrmem_disable() disables the in-memory TLS session cache. /* /* tlsmgrmem_status() reports whether the cache is enabled, the /* number of entries in the cache, and the number of cache hits. /* If any of the return pointers are null, that item is not reported. /* /* tlsmgrmem_flush() flushes any cached data and frees the cache. /* LICENSE /* .ad /* .fi /* The Secure Mailer license must be distributed with this software. /* AUTHOR(S) /* Wietse Venema /* IBM T.J. Watson Research /* P.O. Box 704 /* Yorktown Heights, NY 10598, USA /* /* Viktor Dukhovni
/*--*/
void tlsmgrmem_flush(void)
{ if (!tls_cache) return;
htable_free(tls_cache, free_value);
}
void tlsmgrmem_status(int *enabled, int *count, int *hits)
{ if (enabled)
*enabled = cache_enabled; if (count)
*count = cache_count; if (hits)
*hits = cache_hits;
}
/* tls_mgr_* - Local cache and stubs that do not talk to the TLS manager */
int tls_mgr_seed(VSTRING *buf, int len)
{ return (TLS_MGR_STAT_OK);
}
int tls_mgr_policy(constchar *unused_type, int *cachable, int *timeout)
{ if (cache_enabled && tls_cache == 0)
tls_cache = htable_create(1);
*cachable = cache_enabled;
*timeout = TLS_SESSION_LIFEMIN; return (TLS_MGR_STAT_OK);
}
int tls_mgr_lookup(constchar *unused_type, constchar *key, VSTRING *buf)
{
VSTRING *s;
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.