aboutsummaryrefslogtreecommitdiffstats
path: root/testing/modemmanager/modemmanager.rules
diff options
context:
space:
mode:
Diffstat (limited to 'testing/modemmanager/modemmanager.rules')
-rw-r--r--testing/modemmanager/modemmanager.rules8
1 files changed, 8 insertions, 0 deletions
diff --git a/testing/modemmanager/modemmanager.rules b/testing/modemmanager/modemmanager.rules
new file mode 100644
index 0000000000..09e586e642
--- /dev/null
+++ b/testing/modemmanager/modemmanager.rules
@@ -0,0 +1,8 @@
+// Let users in plugdev group modify ModemManager
+polkit.addRule(function(action, subject) {
+ if (/^org\.freedesktop\.ModemManager1\.(Device\.Control|Contacts|Messaging|Location)$/.test(action.id) &&
+ subject.isInGroup("plugdev") && subject.active) {
+ return "yes";
+ }
+});
+