bug-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#54666: Installation without non-root user accounts


From: Ludovic Courtès
Subject: bug#54666: Installation without non-root user accounts
Date: Tue, 05 Apr 2022 09:44:32 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)

Hello!

Mathieu Othacehe <othacehe@gnu.org> skribis:

> From 829c3c2543ffd7f9b22a5e1fb40f7627b2c76414 Mon Sep 17 00:00:00 2001
> From: Mathieu Othacehe <othacehe@gnu.org>
> Date: Mon, 4 Apr 2022 16:36:07 +0200
> Subject: [PATCH 1/2] installer: user: Forbid root user creation.
>
> Forbid root user creation as it could lead to a system without any
> non-priviledged user accouts.
>
> Fixes: <https://issues.guix.gnu.org/54666>.
>
> * gnu/installer/newt/user.scm (run-user-add-page): Forbid it.

[...]

> +                  (cond
> +                   ;; Empty field.
> +                   ((or (string=? name "")
> +                        (string=? home-directory ""))
> +                    (begin
> +                      (error-empty-field-page)
> +                      (run-user-add-page)))
> +                   ;; Reject root account.
> +                   ((root-account? name)
> +                    (begin
> +                      (error-root-page)
> +                      (run-user-add-page)))

Nitpick: you can omit ‘begin’ here.

> From cc32729700caa4b76d112b561a09dd0ff3ada768 Mon Sep 17 00:00:00 2001
> From: Mathieu Othacehe <othacehe@gnu.org>
> Date: Mon, 4 Apr 2022 16:38:09 +0200
> Subject: [PATCH 2/2] installer: user: Remove useless filtering.
>
> * gnu/installer/user.scm (users->configuration): Remove root account filtering
> that is now performed in the "run-user-add-page" procedure.

LGTM, thanks for the quick fix!

Ludo’.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]