clearlinux / distribution

Placeholder repository to allow filing of general bugs/issues/etc against the Clear Linux OS for Intel Architecture linux distribution
521 stars 29 forks source link

sddmthemeinstaller segfaults #680

Closed shelterx closed 5 years ago

shelterx commented 5 years ago

NAME="Clear Linux OS" VERSION=1 VERSION_ID=29250

sddmthemeinstaller segfaults when trying to install a theme online. I tried it on two different installs and it happend on both.

anselmolsm commented 5 years ago

Hi @shelterx . Which steps did you follow to install the theme? I can't reproduce the segfault installing themes online (also 29250) running "Login Screen (SDDM)" on krunner, then "Get New Login Screens".

shelterx commented 5 years ago

I search for login screen on the app menu then selected Get new login screens Then it crashes when install one of the top rated themes

First window i get is from "ibus backe...irectory" (can't see the full title) saying it can't install the theme. Then I get a bug report notification that contains this stack trace:

Application: sddmthemeinstaller (sddmthemeinstaller), signal: Segmentation fault
[KCrash Handler]
#5  0x0000555c17a49a5e in  ()
#6  0x00007f5be799af23 in __libc_start_main () at /usr/lib64/libc.so.6
#7  0x0000555c17a49e3e in _start ()
[Inferior 1 (process 23161) detached]
sunnyflunk commented 5 years ago

So when looking at other authentication issues on plasma, it was essentially the same as this one (dbus). Via the default install:

May 08 07:15:01 crimson dbus-daemon[472]: [system] Activating service name='org.kde.kcontrol.kcmsddm' requested by ':1.317' (uid=1000 pid=3229 comm="sddmthemeinstaller -i /tmp/plasma-chili.tar.gz ") (using servicehelper)
May 08 07:15:01 crimson dbus-daemon[472]: [system] Activated service 'org.kde.kcontrol.kcmsddm' failed: Failed to execute program org.kde.kcontrol.kcmsddm: No such file or directory

/usr/libexec/dbus-daemon-launch-helper isn't present (file excluded in dbus build due to requiring too many deps) which is used to load system-services such as this one, see https://dbus.freedesktop.org/doc/system-activation.txt

Once adding the file with the correct restricted permissions, it now requests authentication and installs as expected. -rwsr-x--- 1 root messagebus 63656 Apr 15 14:16 /usr/libexec/dbus-daemon-launch-helper

May 08 07:25:35 crimson dbus-daemon[472]: [system] Activating service name='org.kde.kcontrol.kcmsddm' requested by ':1.392' (uid=1000 pid=3620 comm="sddmthemeinstaller -i /tmp/plasma-chili.tar.gz ") (using servicehelper)
May 08 07:25:35 crimson dbus-daemon[472]: [system] Successfully activated service 'org.kde.kcontrol.kcmsddm'
May 08 07:25:39 crimson polkitd[518]: Operator of unix-session:2 successfully authenticated as unix-user:crimson to gain TEMPORARY authorization for action org.kde.kcontrol.kcmsddm.installtheme for system-bus-name::1.392 [sddmthemeinstaller -i /tmp/plasma-chili.tar.gz] (owned by unix-user:crimson)

I'm unsure why it segfaults when it fails to install, but there's no segfault when it installs successfully.

anselmolsm commented 5 years ago

Good point, @sunnyflunk . My system has dbus-daemon-launch-helper because I did some changes in order to make the plasma display brightness control work...

sunnyflunk commented 5 years ago

So I was talking about that file yesterday on IRC, so it's now included as part of dbus-extras which will need to be added to the desktop-kde bundle.

I removed my file and installed one of the bundles that included it to check the permissions (root:root 0755). When trying to install the theme I now get: May 08 18:05:31 crimson dbus-daemon[472]: [system] Activated service 'org.kde.kcontrol.kcmsddm' failed: The permission of the setuid helper is not correct

I'm not sure how autospec/swupd handles permissions, but after setting the permissions, it then works as expected.

$ sudo chown root:messagebus /usr/libexec/dbus-daemon-launch-helper
$ sudo chmod 4750 /usr/libexec/dbus-daemon-launch-helper
AthenasJimenez commented 5 years ago

I'm already working on this issue, I'll push the changes soon :)

thiagomacieira commented 5 years ago

Should be in tomorrow's build.

shelterx commented 5 years ago

Just wanted to confirm, it works like a charm. AND as a plus, setting screen brightness works too! :+1: