[Rpm-maint] [rpm-software-management/rpm] Make user/group info reliable operation across chroot (PR #2503)
Colin Walters
notifications at github.com
Thu Feb 20 19:45:17 UTC 2025
@cgwalters commented on this pull request.
> #include <rpm/rpmlog.h>
#include <rpm/rpmstring.h>
#include "lib/misc.h"
#include "lib/rpmug.h"
#include "debug.h"
+#define PWFILE "/etc/passwd"
+#define GRPFILE "/etc/group"
Most ostree systems use https://github.com/aperezdc/nss-altfiles - but it's also used by other operating systems that don't use ostree, like Flatcar.
As far as a "configuration macro", yeah I guess we could ship one from the nss-altfiles package. A bit ugly, but that's fine.
In the end we are planning to slowly move away from nss-altfiles.
Note however that beyond nss-altfiles there's also https://systemd.io/USER_RECORD/ as implemented by nss-systemd, and while there isn't much update of using static JSON user records as it relates to RPMs (as opposed to sysusers) so we probably don't need to worry about it in the short term, I think in the longer term RPM should fix this by not using chroot() per below discussion.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/2503#discussion_r1964237678
You are receiving this because you are subscribed to this thread.
Message ID: <rpm-software-management/rpm/pull/2503/review/2630973623 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20250220/3edb73c8/attachment-0001.htm>
More information about the Rpm-maint
mailing list