diff options
-rw-r--r-- | src/providers/ipa/ipa_s2n_exop.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/providers/ipa/ipa_s2n_exop.c b/src/providers/ipa/ipa_s2n_exop.c index f589a06f..e16ec149 100644 --- a/src/providers/ipa/ipa_s2n_exop.c +++ b/src/providers/ipa/ipa_s2n_exop.c @@ -654,6 +654,7 @@ static void ipa_s2n_get_user_done(struct tevent_req *subreq) char *realm; char *upn; struct berval *bv_req = NULL; + gid_t gid; ret = ipa_s2n_exop_recv(subreq, state, &retoid, &retdata); talloc_zfree(subreq); @@ -815,8 +816,14 @@ static void ipa_s2n_get_user_done(struct tevent_req *subreq) } } + gid = 0; + if (state->dom->mpg == false) { + gid = attrs->a.user.pw_gid; + } + ret = sysdb_store_user(state->dom->sysdb, state->dom, name, NULL, - attrs->a.user.pw_uid, 0, NULL, /* gecos */ + attrs->a.user.pw_uid, + gid, NULL, /* gecos */ homedir, NULL, NULL, user_attrs, NULL, timeout, now); break; |