|
|
59dcbd |
From 1457b4a7623a8ae58fb8d6a652d1cc44904b8863 Mon Sep 17 00:00:00 2001
|
|
|
59dcbd |
From: Sumit Bose <sbose@redhat.com>
|
|
|
59dcbd |
Date: Mon, 18 Mar 2019 11:02:57 +0100
|
|
|
59dcbd |
Subject: [PATCH 1/2] create-user: add nis-domain option
|
|
|
59dcbd |
|
|
|
59dcbd |
Related to https://gitlab.freedesktop.org/realmd/adcli/issues/2
|
|
|
59dcbd |
---
|
|
|
59dcbd |
doc/adcli.xml | 8 ++++++++
|
|
|
59dcbd |
tools/entry.c | 6 ++++++
|
|
|
59dcbd |
2 files changed, 14 insertions(+)
|
|
|
59dcbd |
|
|
|
59dcbd |
diff --git a/doc/adcli.xml b/doc/adcli.xml
|
|
|
59dcbd |
index 4722c3a..18620c0 100644
|
|
|
59dcbd |
--- a/doc/adcli.xml
|
|
|
59dcbd |
+++ b/doc/adcli.xml
|
|
|
59dcbd |
@@ -531,6 +531,14 @@ $ adcli create-user Fry --domain=domain.example.com \
|
|
|
59dcbd |
the new created user account, which should be the user's
|
|
|
59dcbd |
numeric primary user id.</para></listitem>
|
|
|
59dcbd |
</varlistentry>
|
|
|
59dcbd |
+ <varlistentry>
|
|
|
59dcbd |
+ <term><option>--nis-domain=<parameter>nis_domain</parameter></option></term>
|
|
|
59dcbd |
+ <listitem><para>Set the msSFU30NisDomain attribute of
|
|
|
59dcbd |
+ the new created user account, which should be the user's
|
|
|
59dcbd |
+ NIS domain is the NIS/YP service of Active Directory's Services for Unix (SFU)
|
|
|
59dcbd |
+ are used. This is needed to let the 'UNIX attributes' tab of older Active
|
|
|
59dcbd |
+ Directoy versions show the set UNIX specific attributes.</para></listitem>
|
|
|
59dcbd |
+ </varlistentry>
|
|
|
59dcbd |
</variablelist>
|
|
|
59dcbd |
|
|
|
59dcbd |
</refsect1>
|
|
|
59dcbd |
diff --git a/tools/entry.c b/tools/entry.c
|
|
|
59dcbd |
index 7b6a200..69ce62c 100644
|
|
|
59dcbd |
--- a/tools/entry.c
|
|
|
59dcbd |
+++ b/tools/entry.c
|
|
|
59dcbd |
@@ -52,6 +52,7 @@ typedef enum {
|
|
|
59dcbd |
opt_unix_uid,
|
|
|
59dcbd |
opt_unix_gid,
|
|
|
59dcbd |
opt_unix_shell,
|
|
|
59dcbd |
+ opt_nis_domain,
|
|
|
59dcbd |
} Option;
|
|
|
59dcbd |
|
|
|
59dcbd |
static adcli_tool_desc common_usages[] = {
|
|
|
59dcbd |
@@ -62,6 +63,7 @@ static adcli_tool_desc common_usages[] = {
|
|
|
59dcbd |
{ opt_unix_uid, "unix uid number" },
|
|
|
59dcbd |
{ opt_unix_gid, "unix gid number" },
|
|
|
59dcbd |
{ opt_unix_shell, "unix shell" },
|
|
|
59dcbd |
+ { opt_nis_domain, "NIS domain" },
|
|
|
59dcbd |
{ opt_domain, "active directory domain name" },
|
|
|
59dcbd |
{ opt_domain_realm, "kerberos realm for the domain" },
|
|
|
59dcbd |
{ opt_domain_controller, "domain directory server to connect to" },
|
|
|
59dcbd |
@@ -159,6 +161,7 @@ adcli_tool_user_create (adcli_conn *conn,
|
|
|
59dcbd |
{ "unix-uid", required_argument, NULL, opt_unix_uid },
|
|
|
59dcbd |
{ "unix-gid", required_argument, NULL, opt_unix_gid },
|
|
|
59dcbd |
{ "unix-shell", required_argument, NULL, opt_unix_shell },
|
|
|
59dcbd |
+ { "nis-domain", required_argument, NULL, opt_nis_domain },
|
|
|
59dcbd |
{ "domain-ou", required_argument, NULL, opt_domain_ou },
|
|
|
59dcbd |
{ "domain", required_argument, NULL, opt_domain },
|
|
|
59dcbd |
{ "domain-realm", required_argument, NULL, opt_domain_realm },
|
|
|
59dcbd |
@@ -200,6 +203,9 @@ adcli_tool_user_create (adcli_conn *conn,
|
|
|
59dcbd |
case opt_unix_shell:
|
|
|
59dcbd |
adcli_attrs_add (attrs, "loginShell", optarg, NULL);
|
|
|
59dcbd |
break;
|
|
|
59dcbd |
+ case opt_nis_domain:
|
|
|
59dcbd |
+ adcli_attrs_add (attrs, "msSFU30NisDomain", optarg, NULL);
|
|
|
59dcbd |
+ break;
|
|
|
59dcbd |
case opt_domain_ou:
|
|
|
59dcbd |
ou = optarg;
|
|
|
59dcbd |
break;
|
|
|
59dcbd |
--
|
|
|
59dcbd |
2.20.1
|
|
|
59dcbd |
|