From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
To: "Ludovic Courtès" <ludovic.courtes@inria.fr>
Cc: <guix-devel@gnu.org>
Subject: Re: Supporting sssd, preparing for nscd sunset
Date: Fri, 23 Feb 2024 22:48:16 +0100 [thread overview]
Message-ID: <875xyebze5.fsf@mdc-berlin.de> (raw)
In-Reply-To: <87sf1jh8gq.fsf@inria.fr>
Hi Ludo,
thanks for getting the discussion started. This problem has been
weighing on me for the past months and I don't see a good way forward.
Ludovic Courtès <ludovic.courtes@inria.fr> writes:
> For the record, glibc maintainer Carlos O’Donell brought up our use case
> a while back on the glibc mailing list but it wasn’t particularly well
> received:
>
> https://sourceware.org/pipermail/libc-alpha/2022-February/136741.html
DJ Delorie's response makes it sound like they would prefer that all of
the host system's NSS *configuration* (alongside the NSS modules) be
duplicated in the Guix "container", because that's not guaranteed to be
compatible. That's not a way forward for us, because that would make
running Guix-built software much harder and require significant
configuration on the side of the user.
> [...] If sssd becomes dominant, we
> might just as well arrange to have NSS always load libnss_sss.so.
What are the other contenders here? I assumed that sssd was what
everyone™ used nowadays.
At the MDC we've been using sssd on RHEL for a long time and we've seen
some problems with the naïve approach of just having the Guix System's
NSS load libnss_sss.so:
- In a Guix System VM we also had to explicitly set LD_PRELOAD or
LD_LIBRARY_PATH in the current environment (not just nscd's
environment) to make things like "id" work. Having just NSS load the
library was not enough to work with user accounts that are defined in
LDAP, for example.
- A different Guix System VM was configured to use nss-pam-ldapd. Upon
reconfigure it attempted (and predictably failed) to delete all user
accounts on LDAP, because none of them were defined locally. I guess
Guix System needs to be a little less eager to manage remote accounts
that NSS plugins (including sssd) say exist.
- PAM in a container.
While this is not strictly related to the disappearance of nscd, it is
another obstacle relating to sssd. On foreign distros I use Guix
containers that bind-mount the host system's /var/lib/sss/pipes
directory. The hope was to use a native Guix build of libsss to talk
to the socket at /var/lib/sss/pipes/pam (and potentially others) for
authorizing users via the host system's sssd infrastructure.
In "guix shell -C" this won't work, because sssd refuses to talk over
that socket if the ownership is not root:root. In the Guix shell
container there is only ever *one* user account, so root-owned files
are assigned to the overflow user account, and thus communication with
the host system's pam socket is impossible. I failed to fix this with
subuids, because the "guix shell -C" process does not have sufficient
privileges to map more than one user id.
I'll note that /var/lib/sss/pipes also contains an "nss" socket; I don't
know if it checks ownership on that socket, but it's possible that it
also cannot be used in "guix shell -C".
--
Ricardo
next prev parent reply other threads:[~2024-02-23 22:50 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-23 8:48 Supporting sssd, preparing for nscd sunset Ludovic Courtès
2024-02-23 15:03 ` Felix Lechner via Development of GNU Guix and the GNU System distribution.
2024-02-23 21:48 ` Ricardo Wurmus [this message]
2024-02-24 8:26 ` Picnoir
2024-03-05 9:46 ` Ludovic Courtès
2024-03-05 12:34 ` Picnoir
2024-02-24 19:10 ` Maxim Cournoyer
2024-03-05 9:55 ` Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=875xyebze5.fsf@mdc-berlin.de \
--to=ricardo.wurmus@mdc-berlin.de \
--cc=guix-devel@gnu.org \
--cc=ludovic.courtes@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).