Skip to contentSkip to conversation

package/polkit: fix permissions after version bump to 125

PATCH Julien Olivain 1 participant 1 message Dec 15, 2024 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Hi Martin,

Quoted 6 lines · Martin Böh

Hey Julien!

I modified it to 0xxx because of the post build step message found here:

https://github.com/polkit-org/polkit/blob/c1369cd4ffb975e177035392837ff91373774407/meson_post_install.py#L62

Ok, understood. Thanks for the explanation. Buildroot is using "makedevs" which always scans permissions in octal representation. See [1] [2]. So those leading zeroes are unneeded here. I removed those when applying the patch in [3], to keep all Buildroot _PERMISSIONS to the same format.

Out of curiosity: what was your use case showing the failure?

There is a polkit runtime test in Buildroot [4] which did not detected this permission issue. See [5]. We could maybe improve this test with your use case.

Quoted 33 lines

Kind regards
Martin

Quoted 28 lines · Julien Olivain

Hi Martin,

Quoted 5 lines · Martin Böh via buildroot

From: Martin Böh <[email protected]>

The service failed to start correctly if any custom rules were installed.
This commit aligns the permissions with the upstream meson build

step.

Quoted 13 lines

-------------------------
package/polkit/polkit.mk | 8 ++++----

1 file changed, 4 insertions(+), 4 deletions(-)
package/polkit/polkit.mk +0 -0
index fb49f6ce2a..6cd2aa6042 100644
@@ -56,10 +56,10 @@ define POLKIT_USERS

endef

Quoted 5 lines

define POLKIT_PERMISSIONS
- /etc/polkit-1/rules.d d 700 polkitd root - - - - -
- /usr/share/polkit-1/rules.d d 700 polkitd root - - - - -
- /usr/bin/pkexec f 4755 root root - - - - -
- /usr/lib/polkit-1/polkit-agent-helper-1 f 4755 root root - - - -

-

Quoted 32 lines
Quoted 7 lines
Quoted 2 lines

+ /etc/polkit-1/rules.d d 750 root polkitd - - - - -
+ /usr/share/polkit-1/rules.d d 750 root polkitd - - - - -

I understand those two directories needs those updates, due to upstream
changes such as:

https://github.com/polkit-org/polkit/commit/b6169f3113b3ce5ed822e66adcc962850c24660a

Quoted 24 lines
Quoted 4 lines

+ /usr/bin/pkexec f 04755 root root - - - - -
+ /usr/lib/polkit-1/polkit-agent-helper-1 f 04755 root root - - -

- -

Why did you updated /usr/bin/pkexec and /usr/lib/polkit-1/polkit-agent-helper-1
to replace 4755 by 04755? (there is no justification in the commit log).

Quoted 9 lines

endef

define POLKIT_INSTALL_INIT_SYSTEMD
--
2.47.1
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot

Best regards,

Julien.

Best regards,

Julien.

[1] https://gitlab.com/buildroot.org/buildroot/-/blob/2024.11/package/makedevs/makedevs.c#L531
[2] https://gitlab.com/buildroot.org/buildroot/-/blob/master/docs/manual/makedev-syntax.adoc
[3] https://gitlab.com/buildroot.org/buildroot/-/commit/6884127cbe98cd7881a6f3cba5bfae4f753763b0
[4] https://gitlab.com/buildroot.org/buildroot/-/blob/master/support/testing/tests/package/test_polkit.py
[5] https://gitlab.com/buildroot.org/buildroot/-/jobs?name=tests.package.test_polkit.TestPolkitSystemd
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot