aboutsummaryrefslogtreecommitdiffstats
path: root/community/modemmanager/modemmanager.rules
diff options
context:
space:
mode:
Diffstat (limited to 'community/modemmanager/modemmanager.rules')
-rw-r--r--community/modemmanager/modemmanager.rules8
1 files changed, 8 insertions, 0 deletions
diff --git a/community/modemmanager/modemmanager.rules b/community/modemmanager/modemmanager.rules
new file mode 100644
index 0000000000..09e586e642
--- /dev/null
+++ b/community/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";
+ }
+});
+