mirror of
https://github.com/systemd/systemd
synced 2024-09-18 15:42:03 +00:00
Merge pull request #14990 from keszybz/nss-homed-fix
Fix for lookup of groups defined by homed
This commit is contained in:
commit
ed87ce1d5d
|
@ -12,7 +12,7 @@
|
|||
|
||||
bool suitable_user_name(const char *name) {
|
||||
|
||||
/* Checks whether the specified name is suitable for management via home aread. Note that client-side
|
||||
/* Checks whether the specified name is suitable for management via homed. Note that client-side
|
||||
* we usually validate with the simple valid_user_group_name(), while server-side we are a bit more
|
||||
* restrictive, so that we can change the rules server-side without having to update things
|
||||
* client-side too. */
|
||||
|
|
|
@ -195,7 +195,7 @@ enum nss_status _nss_systemd_getgrnam_r(
|
|||
if (!valid_user_group_name(name))
|
||||
return NSS_STATUS_NOTFOUND;
|
||||
|
||||
/* Synthesize records for root and nobody, in case they are missing form /etc/group */
|
||||
/* Synthesize records for root and nobody, in case they are missing from /etc/group */
|
||||
if (getenv_bool_secure("SYSTEMD_NSS_BYPASS_SYNTHETIC") <= 0) {
|
||||
|
||||
if (streq(name, root_group.gr_name)) {
|
||||
|
|
|
@ -290,7 +290,7 @@ enum nss_status userdb_getgrgid(
|
|||
*errnop = -r;
|
||||
return NSS_STATUS_UNAVAIL;
|
||||
}
|
||||
if (r)
|
||||
if (!r)
|
||||
return NSS_STATUS_NOTFOUND;
|
||||
|
||||
r = groupdb_by_gid(gid, nss_glue_userdb_flags(), &g);
|
||||
|
|
Loading…
Reference in a new issue