Allow a winbind client to obtain the server's domain name.
authorAndrew Bartlett <abartlet@samba.org>
Sat, 26 Jan 2002 09:52:55 +0000 (09:52 +0000)
committerAndrew Bartlett <abartlet@samba.org>
Sat, 26 Jan 2002 09:52:55 +0000 (09:52 +0000)
(This used to be commit 85018fecfad1f7f6ef44b511bac937881a7bf937)

source3/nsswitch/winbindd_misc.c

index 883f9a4e22fc32cde9a24dec8b32d9090cc7d478..64eaea3153a234802c1f96dba6582078bb300a7f 100644 (file)
@@ -167,7 +167,7 @@ enum winbindd_result winbindd_info(struct winbindd_cli_state *state)
        return WINBINDD_OK;
 }
 
-/* List various tidbits of information */
+/* Tell the client the current interface version */
 
 enum winbindd_result winbindd_interface_version(struct winbindd_cli_state *state)
 {
@@ -178,3 +178,15 @@ enum winbindd_result winbindd_interface_version(struct winbindd_cli_state *state
 
        return WINBINDD_OK;
 }
+
+/* What domain are we a member of? */
+
+enum winbindd_result winbindd_domain_name(struct winbindd_cli_state *state)
+{
+
+       DEBUG(3, ("[%5d]: request domain name\n", state->pid));
+       
+       fstrcpy(state->response.data.domain_name, lp_workgroup());
+
+       return WINBINDD_OK;
+}