unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* User accounts
@ 2014-05-13  8:11 Ludovic Courtès
  2014-05-13  8:17 ` John Darrington
  0 siblings, 1 reply; 4+ messages in thread
From: Ludovic Courtès @ 2014-05-13  8:11 UTC (permalink / raw)
  To: guix-devel

Before commit ab6a279, /etc/{group,passwd,shadow} were all created from
a derivation.  Thus, /etc contained symlinks to those files, which were
actually in the store.  Being in the store, they were all immutable and
world-readable (you can see that in the VM image released with 0.6.)

That was obviously not desirable, because then everyone can read shadow,
and because that prevents passwords from being changed.

So commit ab6a279 changed accounts to be created at “activation
time”—i.e., when booting, or when switching to a new operating system
configuration.  What happens is that the activation code checks for all
the user accounts and groups required by the ‘operating-system’
declaration, and invokes ‘useradd’ and ‘groupadd’ for any missing
account/group.

That way, {group,passwd,shadow} are normal state files with the right
permissions, and everything works as expected.  NixOS uses the same
strategy.

Ludo’.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-05-13 12:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-13  8:11 User accounts Ludovic Courtès
2014-05-13  8:17 ` John Darrington
2014-05-13 12:12   ` Ludovic Courtès
2014-05-13 12:49     ` John Darrington

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).