Skip to content

X server runs as root #43984

Open
Open

Description

@lheckemann

Issue description

The X server runs as root rather than an unprivileged user. This shouldn't be necessary nowadays as far as I know.

Steps to reproduce

Set services.xserver.enable = true;.

Technical details

  • system: "x86_64-linux"
  • host os: Linux 4.14.55, NixOS, 18.03.132865.411cc559c05 (Impala)
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.0.4
  • channels(root): "nixos-18.03.132865.411cc559c05, nixos-unstable-18.09pre140099.f53d22edd68"
  • channels(linus): ""
  • nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs

Activity

  1. added
    1.severity: security
    0.kind: enhancement
    6.topic: nixos
    on Jul 22, 2018
  2. balsoft commented on Jul 24, 2018

    @balsoft
  3. 8573 commented on Jul 25, 2020

    @8573
    Contributor

    To add a data point, this doesn't seem to be an issue with GDM. For years I used LightDM, but, wondering whether some other display managers might not have this issue, I tried switching away from LightDM, and I found that the first other display manager I tried, GDM, indeed seems to run X as non-root, specifically running it under the account of the user who logs in. I switched circa 2020-06-19 and have had no major problems.

    cc @est31

    Edit: I suppose GDM still isn't running X "as [...] an unprivileged user", though.

  4. Atemu commented on Jan 5, 2021

    @Atemu
  5. TredwellGit commented on Apr 24, 2021

    @TredwellGit
    Member
  6. tomodachi94 commented on Oct 12, 2024

    @tomodachi94
    Member

    SDDM now supports rootless X11 as of the above PR, which removes a blocker for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: enhancement1.severity: security6.topic: nixos

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions