Skip to contentSkip to conversation

package/polkit: add needed system changes

PATCH New aduskett at gmail.com 1 participant 1 message Dec 18, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/polkit: add needed system changes

From: Adam Duskett <[email protected]>

The polkit daemon requires a polkitd user with permission to access the following directories:
- /etc/polkit-1
- /usr/share/polkit-1

The /usr/bin/pkexec file must be owned by owned by root with the permissions 4755 or else the error "pkexec must be setuid root" is thrown when it's ran.

---
 package/polkit/polkit.mk | 10 ++++++++++
 1 file changed, 10 insertions(+)
package/polkit/polkit.mk +10 -0
index a98c138356..bc9e3580ab 100644
@@ -29,4 +29,14 @@ else
 POLKIT_CONF_OPTS += --with-authfw=shadow
 endif
 
+define POLKIT_USERS
+	polkitd -1 polkitd -1 * - - - Polkit Daemon
+endef
+
+define POLKIT_PERMISSIONS
+	/etc/polkit-1 r 750 root polkitd - - - - -
+	/usr/share/polkit-1 r 750 root polkitd - - - - -
+	/usr/bin/pkexec f 4755 root root - - - - -
+endef
+
 $(eval $(autotools-package))
Signature · 1 line
2.21.0 (Apple Git-122)