summaryrefslogtreecommitdiffstats
path: root/polkit/policy
diff options
context:
space:
mode:
authorColin Guthrie <colin@mageia.org>2013-09-04 16:32:35 +0100
committerColin Guthrie <colin@mageia.org>2013-09-04 17:46:59 +0100
commit738779e2e5245a33c6e42720e153baa068d276b5 (patch)
tree81fc0d9d4da07d13cf2fa46f13d8214f159f7140 /polkit/policy
parent530835e736420dd9b0c464446e3130e3249f6078 (diff)
downloaddrakx-kbd-mouse-x11-738779e2e5245a33c6e42720e153baa068d276b5.tar
drakx-kbd-mouse-x11-738779e2e5245a33c6e42720e153baa068d276b5.tar.gz
drakx-kbd-mouse-x11-738779e2e5245a33c6e42720e153baa068d276b5.tar.bz2
drakx-kbd-mouse-x11-738779e2e5245a33c6e42720e153baa068d276b5.tar.xz
drakx-kbd-mouse-x11-738779e2e5245a33c6e42720e153baa068d276b5.zip
Convert to polkit from usermode consolehelper for gaining root privileges
polkit is better integrated into various environments, both console and GUI and offers better access rules and prevents the internal need to run su which is prone to errors and doesn't offer an environment agnostic prompt to the user. Under the old scheme, the binaries relating to the three main tools covered in this package behaved differently. Keyboard and Mouse are allowed to be run without any password prompts, whereas X11 prompts for the *user* password. This is only true when run as their 'old' names of keyboarddrake, mousedrake and XFdrake respectively. If they are called via their 'new' names of drakkeyboard, drakmouse and drakx11, they would prompt for the root password. This change also standardises that behaviour. The tools now follow the scheme specified for their old names, regardless of how they are called. mga#11125
Diffstat (limited to 'polkit/policy')
-rw-r--r--polkit/policy/org.mageia.drakkeyboard.policy22
-rw-r--r--polkit/policy/org.mageia.drakmouse.policy22
-rw-r--r--polkit/policy/org.mageia.drakx11.policy22
3 files changed, 66 insertions, 0 deletions
diff --git a/polkit/policy/org.mageia.drakkeyboard.policy b/polkit/policy/org.mageia.drakkeyboard.policy
new file mode 100644
index 0000000..e3cd5bd
--- /dev/null
+++ b/polkit/policy/org.mageia.drakkeyboard.policy
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE policyconfig PUBLIC
+"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
+"http://www.freedesktop.org/standards/PolicyKit/1/policyconfig.dtd">
+<policyconfig>
+
+ <vendor>Mageia</vendor>
+ <vendor_url>http://www.mageia.org/</vendor_url>
+
+ <action id="org.mageia.drakkeyboard.pkexec.run">
+ <description>Run Mageia Keyboard Configuration</description>
+ <message>Authentication is required to run Mageia Keyboard Configuration</message>
+ <icon_name>drakconf</icon_name>
+ <defaults>
+ <allow_any>no</allow_any>
+ <allow_inactive>no</allow_inactive>
+ <allow_active>yes</allow_active>
+ </defaults>
+ <annotate key="org.freedesktop.policykit.exec.path">/usr/libexec/drakkeyboard</annotate>
+ <annotate key="org.freedesktop.policykit.exec.allow_gui">true</annotate>
+ </action>
+</policyconfig>
diff --git a/polkit/policy/org.mageia.drakmouse.policy b/polkit/policy/org.mageia.drakmouse.policy
new file mode 100644
index 0000000..157e2d2
--- /dev/null
+++ b/polkit/policy/org.mageia.drakmouse.policy
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE policyconfig PUBLIC
+"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
+"http://www.freedesktop.org/standards/PolicyKit/1/policyconfig.dtd">
+<policyconfig>
+
+ <vendor>Mageia</vendor>
+ <vendor_url>http://www.mageia.org/</vendor_url>
+
+ <action id="org.mageia.drakmouse.pkexec.run">
+ <description>Run Mageia Mouse Configuration</description>
+ <message>Authentication is required to run Mageia Mouse Configuration</message>
+ <icon_name>drakconf</icon_name>
+ <defaults>
+ <allow_any>no</allow_any>
+ <allow_inactive>no</allow_inactive>
+ <allow_active>yes</allow_active>
+ </defaults>
+ <annotate key="org.freedesktop.policykit.exec.path">/usr/libexec/drakmouse</annotate>
+ <annotate key="org.freedesktop.policykit.exec.allow_gui">true</annotate>
+ </action>
+</policyconfig>
diff --git a/polkit/policy/org.mageia.drakx11.policy b/polkit/policy/org.mageia.drakx11.policy
new file mode 100644
index 0000000..efa8441
--- /dev/null
+++ b/polkit/policy/org.mageia.drakx11.policy
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE policyconfig PUBLIC
+"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
+"http://www.freedesktop.org/standards/PolicyKit/1/policyconfig.dtd">
+<policyconfig>
+
+ <vendor>Mageia</vendor>
+ <vendor_url>http://www.mageia.org/</vendor_url>
+
+ <action id="org.mageia.drakx11.pkexec.run">
+ <description>Run Mageia Graphics Configuration</description>
+ <message>Authentication is required to run Mageia Graphics Configuration</message>
+ <icon_name>drakconf</icon_name>
+ <defaults>
+ <allow_any>no</allow_any>
+ <allow_inactive>no</allow_inactive>
+ <allow_active>auth_self_keep</allow_active>
+ </defaults>
+ <annotate key="org.freedesktop.policykit.exec.path">/usr/libexec/drakx11</annotate>
+ <annotate key="org.freedesktop.policykit.exec.allow_gui">true</annotate>
+ </action>
+</policyconfig>