From 988bf594215007c96903b4a646b0cf024fb8f596 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Mon, 4 Aug 2014 18:13:14 +0200 Subject: Move some options out of globals --- src/nix-daemon/nix-daemon.cc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/nix-daemon') diff --git a/src/nix-daemon/nix-daemon.cc b/src/nix-daemon/nix-daemon.cc index 2d6a3c4c4..77c63f1e6 100644 --- a/src/nix-daemon/nix-daemon.cc +++ b/src/nix-daemon/nix-daemon.cc @@ -743,6 +743,9 @@ static void daemonLoop() struct group * gr = getgrgid(cred.gid); string group = gr ? gr->gr_name : int2String(cred.gid); + Strings trustedUsers = settings.get("trusted-users", Strings({"root"})); + Strings allowedUsers = settings.get("allowed-users", Strings({"*"})); + if (matchUser(user, group, settings.trustedUsers)) trusted = true; -- cgit v1.2.3