> Yup. Perhaps the bigger question is, should rpm _always_ use just the local
> passwd/group files?
Yes, nothing else is useful.
> I'm not sure if rpm needs to take into account nsswitch.
I don't think so. Firstly, it's not well defined what that would even mean. The
host's nsswitch is irrelevant, and the targets's nsswitch cannot be used
because `rpm` doesn't run code from the target. Secondly, nsswitch config would
generally include things like `nss_sss` and `nss_systemd`, which require the
system to be up to deliver results. So those additional modules cannot give any
useful answers to `rpm` anyway. Thirdly, `rpm` cares about system users. And
system users need to be resolvable early, before the network and most of the
system is up, so the users that rpm cares about would not be stored in those
additional nss modules anyway. So in practice hardcoding `nss_files` as the
method to resolve names is fine.
> Is it an option to use `fgetpwent()` and `fgetgrent()` to circumvent glibc's
> caching?
Whatever works.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/882#issuecomment-1504837548
You are receiving this because you are subscribed to this thread.
Message ID: <rpm-software-management/rpm/issues/882/1504837...@github.com>
_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint