Skip to content

Fix rootless xorg support #246

Closed

Description

@jleclanche
[10:48:14] <AnAkkk> after this change in the Xorg 1.16 arch package, SDDM no longer works correctly because at the time that X starts, it can't find the nvidia module https://bugs.archlinux.org/task/41259
[10:48:19] <AnAkkk> is that something we need to fix in sddm?
[10:48:44] <AnAkkk> I have to restart sddm with systemctl every time to make it work
[11:07:08] <AnAkkk> ok, actually it's related to the dkms systemd service + nvidia-dkms
[11:07:18] <AnAkkk> that I use to rebuild the nvidia module on kernel updates
[11:07:38] <AnAkkk> it seems to unload the nvidia module, X can't find it

Activity

  1. AnAkkk commented on Aug 2, 2014

    @AnAkkk

    Ignore my messages, they actually fixed that in the archlinux xorg package, and they were unrelated to rootless xorg.
    SDDM still needs support for that though, otherwise X is still ran as root.

  2. jleclanche commented on Aug 2, 2014

    @jleclanche
    MemberAuthor

    Ok.

  3. bchretien commented on Aug 10, 2014

    @bchretien
    Contributor

    👍 for rootless Xorg support (most Arch users would probably agree after the last Xorg update).

  4. jleclanche commented on Oct 16, 2015

    @jleclanche
    MemberAuthor

    @plfiorini Was there any progress on this?

  5. tugit commented on Nov 4, 2015

    @tugit

    Debian testing allows running x without root, see https://www.phoronix.com/scan.php?page=news_item&px=Debian-Non-Root-X
    I can start my Plasma 5 session by switching to a VT and type startx, then indeed X runs as the logged in user on the VT. When using sddm to login, X runs with root privileges.
    Any progress ahead?

  6. xiangzhai commented on Nov 5, 2015

    @xiangzhai

    oh yup #492

  7. added this to the 1.0 milestone on Nov 5, 2015
  8. tugit commented on Nov 5, 2015

    @tugit

    With major distributions supporting running x without root (fedora, arch, debian -> ubuntu) I consider it a security risk to run something as root when it does not have to.

    Related discussion in case of lightdm: https://bugs.launchpad.net/lightdm/+bug/1292324

  9. jleclanche commented on Nov 5, 2015

    @jleclanche
    MemberAuthor

    PRs welcome.

  10. modified the milestones: 0.14, 1.0 on Nov 6, 2015
  11. plfiorini commented on Nov 6, 2015

    @plfiorini
    Member

    Let's try to do this for 0.14, we have ~2 months to do so.

  12. self-assigned this
    on Nov 6, 2015
  13. 16 remaining items

  14. Rihannakitten commented on Nov 2, 2018

    @Rihannakitten

    PRs

    #673

  15. bionade24 commented on Jan 16, 2019

    @bionade24

    How is the progress at the moment? What has to be done?

  16. devurandom commented on Oct 6, 2019

    @devurandom

    Once you start X as user and want to get logind integration for it, you will need to pass it -keeptty.

    See-Also: https://bugs.gentoo.org/603294

  17. yan12125 commented on May 9, 2020

    @yan12125

    Any updates? I tried the following two branches and neither works :/

    [General]
    DisplayServer = x11-user
    

    However, sddm does not start. According to strace, Xorg.wrap reports "Only console users are allowed to run the X server". Seems Xorg check if one of stdin/stdout/stderr is /dev/ttyX [1], while strace tells me that all 3 file descriptors are FIFOs when Xorg.wrap is invoked.

    Environment: Arch Linux up-to-date

    [1] https://gitlab.freedesktop.org/xorg/xserver/-/blob/xorg-server-1.20.8/hw/xfree86/xorg-wrapper.c#L171

  18. eepymoonshine commented on Nov 4, 2020

    @eepymoonshine

    Any news on this?

  19. bionade24 commented on Nov 4, 2020

    @bionade24

    Any news on this?

    Afaik even gdm needs to be root for certain tasks and then downgrades itself. So it's not really easy to accomplish.
    No one wants to work on the X server anymore, focussing on wayland is more important. https://www.phoronix.com/scan.php?page=news_item&px=XServer-Abandonware<

    SDDM seems to support this behaviour (from the README):

    SDDM runs the greeter as a system user named "sddm" whose home directory needs to be set to /var/lib/sddm.
    

    Maybe just you distro maintainer never tried this because it's more pain than gain, in the Arch IRC channels there are various poeple trying to rootless gdm work and fails for couple of reasonsons.

    I guess this never will work perfectly because it' s using a piece of software made for big UNIX 36 years ago. Wayland support is more important, I hope.

  20. kugel- commented on Nov 4, 2020

    @kugel-

    Whether SDDM/GDM itself runs as root or not is a separate issue. This issue is about rootless X which is a subordinary process.

  21. eepymoonshine commented on Nov 15, 2020

    @eepymoonshine

    Any news on this?

    Afaik even gdm needs to be root for certain tasks and then downgrades itself. So it's not really easy to accomplish.
    No one wants to work on the X server anymore, focussing on wayland is more important. https://www.phoronix.com/scan.php?page=news_item&px=XServer-Abandonware<

    SDDM seems to support this behaviour (from the README):

    SDDM runs the greeter as a system user named "sddm" whose home directory needs to be set to /var/lib/sddm.
    

    Maybe just you distro maintainer never tried this because it's more pain than gain, in the Arch IRC channels there are various poeple trying to rootless gdm work and fails for couple of reasonsons.

    I guess this never will work perfectly because it' s using a piece of software made for big UNIX 36 years ago. Wayland support is more important, I hope.

    Whether wayland is more important or not is not the focus on this. Rootless X has been available for years, and it's not about the greeter running as root or not, it's about X itself (Xorg) running as a normal user instead of root.

  22. added a commit that references this issue on Feb 18, 2021
    b76b00f
  23. added a commit that references this issue on Apr 19, 2021
    9881225
  24. added a commit that references this issue on Jun 30, 2022
    7c5f5e5
  25. added a commit that references this issue on Jul 6, 2023
    d60aedd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions