From: James Bunton Date: Sat, 17 Nov 2018 11:34:02 +0000 (+1100) Subject: updated polkit rules X-Git-Url: https://code.delx.au/monosys/commitdiff_plain/921fc0f02cc9f1f72efccfc6733fd9a14cf48b6a updated polkit rules --- diff --git a/etc/polkit-1/rules.d/99-blueman.rules b/etc/polkit-1/rules.d/99-blueman.rules index 79c7b6e..3ab8768 100644 --- a/etc/polkit-1/rules.d/99-blueman.rules +++ b/etc/polkit-1/rules.d/99-blueman.rules @@ -1,10 +1,9 @@ -/* Allow users in sudo group to use blueman feature requiring root without authentication */ polkit.addRule(function(action, subject) { - if ((action.id == "org.blueman.network.setup" || - action.id == "org.blueman.dhcp.client" || - action.id == "org.blueman.rfkill.setstate" || - action.id == "org.blueman.pppd.pppconnect") && - subject.isInGroup("sudo")) { - return polkit.Result.YES; + if (subject.user == "some-user") { + if (action.id.indexOf("org.blueman.") == 0) { + polkit.log("action=" + action); + polkit.log("subject=" + subject); + return polkit.Result.YES; + } } });