diff options
author | Martin Willi <martin@strongswan.org> | 2008-12-09 09:11:37 +0000 |
---|---|---|
committer | Martin Willi <martin@strongswan.org> | 2008-12-09 09:11:37 +0000 |
commit | 15ed045c87e5d75ecdcb6ab34ebe12f9bc4851a4 (patch) | |
tree | 3ef44d28bff2f3ae00a86948a07f2ce78feb6e19 /src | |
parent | 5bdc8fc794dd2c64a201bee7292c9f0d915e9ff1 (diff) | |
download | strongswan-15ed045c87e5d75ecdcb6ab34ebe12f9bc4851a4.tar.bz2 strongswan-15ed045c87e5d75ecdcb6ab34ebe12f9bc4851a4.tar.xz |
require explicit enabling of load-testing plugin
Diffstat (limited to 'src')
-rw-r--r-- | src/charon/plugins/load_tester/load_tester_plugin.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/charon/plugins/load_tester/load_tester_plugin.c b/src/charon/plugins/load_tester/load_tester_plugin.c index 257c7451b..1f6cbf289 100644 --- a/src/charon/plugins/load_tester/load_tester_plugin.c +++ b/src/charon/plugins/load_tester/load_tester_plugin.c @@ -176,9 +176,17 @@ static void destroy(private_load_tester_plugin_t *this) */ plugin_t *plugin_create() { - private_load_tester_plugin_t *this = malloc_thing(private_load_tester_plugin_t); + private_load_tester_plugin_t *this; int i; + if (!lib->settings->get_bool(lib->settings, + "charon.plugins.load_tester.enable", FALSE)) + { + DBG1(DBG_CFG, "disabling load-tester plugin, not configured"); + return NULL; + } + + this = malloc_thing(private_load_tester_plugin_t); this->public.plugin.destroy = (void(*)(plugin_t*))destroy; lib->crypto->add_dh(lib->crypto, MODP_NULL, |