aboutsummaryrefslogtreecommitdiffstats
path: root/src/libcharon/plugins/whitelist/whitelist_plugin.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libcharon/plugins/whitelist/whitelist_plugin.c')
-rw-r--r--src/libcharon/plugins/whitelist/whitelist_plugin.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/libcharon/plugins/whitelist/whitelist_plugin.c b/src/libcharon/plugins/whitelist/whitelist_plugin.c
index 5ba3e1449..4f397d76e 100644
--- a/src/libcharon/plugins/whitelist/whitelist_plugin.c
+++ b/src/libcharon/plugins/whitelist/whitelist_plugin.c
@@ -92,6 +92,12 @@ plugin_t *whitelist_plugin_create()
{
private_whitelist_plugin_t *this;
+ if (!lib->caps->keep(lib->caps, CAP_CHOWN))
+ { /* required to chown(2) control socket */
+ DBG1(DBG_CFG, "whitelist plugin requires CAP_CHOWN capability");
+ return NULL;
+ }
+
INIT(this,
.public = {
.plugin = {