forked from mir/linux-vm-tools
Merge pull request #40 from Microsoft/cwilhit-patch-1
Correct Polkit Policy
This commit is contained in:
commit
8b41356c10
@ -81,19 +81,13 @@ echo "hv_sock" > /etc/modules-load.d/hv_sock.conf
|
||||
fi
|
||||
|
||||
# Configure the policy xrdp session
|
||||
cat >/etc/polkit-1/localauthority.conf.d/02-allow-colord.conf <<EOF
|
||||
polkit.addRule(function(action, subject) {
|
||||
if ((action.id == "org.freedesktop.color-manager.create-device" ||
|
||||
action.id == "org.freedesktop.color-manager.modify-profile" ||
|
||||
action.id == "org.freedesktop.color-manager.delete-device" ||
|
||||
action.id == "org.freedesktop.color-manager.create-profile" ||
|
||||
action.id == "org.freedesktop.color-manager.modify-profile" ||
|
||||
action.id == "org.freedesktop.color-manager.delete-profile") &&
|
||||
subject.isInGroup("{group}"))
|
||||
{
|
||||
return polkit.Result.YES;
|
||||
}
|
||||
});
|
||||
cat >/etc/polkit-1/localauthority/50-local.d/45-allow-colord.pkla <<EOF
|
||||
[Allow Colord all Users]
|
||||
Identity=unix-user:*
|
||||
Action=org.freedesktop.color-manager.create-device;org.freedesktop.color-manager.create-profile;org.freedesktop.color-manager.delete-device;org.freedesktop.color-manager.delete-profile;org.freedesktop.color-manager.modify-device;org.freedesktop.color-manager.modify-profile
|
||||
ResultAny=no
|
||||
ResultInactive=no
|
||||
ResultActive=yes
|
||||
EOF
|
||||
|
||||
# reconfigure the service
|
||||
|
Loading…
x
Reference in New Issue
Block a user