mirror of
https://github.com/lakinduakash/linux-wifi-hotspot.git
synced 2024-11-24 13:10:14 +00:00
Add wheel group in polkit rules
This commit is contained in:
parent
2bd4d5906b
commit
ed7002dcae
@ -19,7 +19,7 @@
|
||||
</action>
|
||||
|
||||
<action id="org.opensuse.policykit.create-ap">
|
||||
<message>Authentication is required to run the Wihotspot</message>
|
||||
<message>Authentication is required to run the create_ap</message>
|
||||
<icon_name>wihotspot</icon_name>
|
||||
<defaults>
|
||||
<allow_any>auth_admin</allow_any>
|
||||
|
@ -1,8 +1,8 @@
|
||||
/* Allow users in admin group to run GParted without authentication */
|
||||
/* Allow users in admin group to run create_ap without authentication */
|
||||
polkit.addRule(function(action, subject) {
|
||||
if ( action.id == "org.opensuse.policykit.create-ap" ) {
|
||||
|
||||
if (subject.isInGroup("sudo")) {
|
||||
if (subject.isInGroup("sudo") || subject.isInGroup("wheel")) {
|
||||
return polkit.Result.YES;
|
||||
} else {
|
||||
return polkit.Result.AUTH_ADMIN;
|
||||
|
Loading…
Reference in New Issue
Block a user