summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaiki Ueno <dueno@redhat.com>2019-06-15 10:31:25 +0200
committerDaiki Ueno <ueno@gnu.org>2019-06-18 14:17:28 +0200
commit6708ccf6126734b4d98cc849bc4542c45ffce191 (patch)
treecfa749df0dc81588576a0af0f6b9fd9c13890a2b
parent1e8ca781b983cb31d62e21a3a61f25be1fcc694f (diff)
conf: Skip root UID check on Windows
-rw-r--r--p11-kit/conf.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/p11-kit/conf.c b/p11-kit/conf.c
index 861231e..b26f54b 100644
--- a/p11-kit/conf.c
+++ b/p11-kit/conf.c
@@ -232,9 +232,11 @@ _p11_conf_load_globals (const char *system_conf, const char *user_conf,
if (getauxval (AT_SECURE)) {
p11_debug ("skipping user config in setuid or setgid program");
mode = CONF_USER_NONE;
+#ifdef OS_UNIX
} else if (getuid () == 0) {
p11_debug ("skipping user config in program running as root");
mode = CONF_USER_NONE;
+#endif
} else if (secure_getenv ("P11_KIT_NO_USER_CONFIG")) {
p11_debug ("skipping user config due to P11_NO_USER_CONFIG");
mode = CONF_USER_NONE;