summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2006-05-05 08:26:34 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:16:48 -0500
commit4137c63d0236d429c33b718674b365c6efcba695 (patch)
tree792eee54b774e740eac800baf9694e41f0706bcc
parent212b832e4a3a368d14f061aeffcc034650e247da (diff)
downloadsamba-4137c63d0236d429c33b718674b365c6efcba695.tar.gz
samba-4137c63d0236d429c33b718674b365c6efcba695.tar.bz2
samba-4137c63d0236d429c33b718674b365c6efcba695.zip
r15455: Add rpccli_samr_query_dom_info2() and return the comment string in
samr_query_domain_info(2) for consistency reasons. Guenther (This used to be commit 870495e2c8628deee0498e68cc1d93abfbc56da4)
-rw-r--r--source3/rpc_client/cli_samr.c42
-rw-r--r--source3/rpc_server/srv_samr_nt.c3
2 files changed, 45 insertions, 0 deletions
diff --git a/source3/rpc_client/cli_samr.c b/source3/rpc_client/cli_samr.c
index 09fb997413..1da7a47ea6 100644
--- a/source3/rpc_client/cli_samr.c
+++ b/source3/rpc_client/cli_samr.c
@@ -1124,6 +1124,48 @@ NTSTATUS rpccli_samr_query_dom_info(struct rpc_pipe_client *cli,
return result;
}
+/* Query domain info2 */
+
+NTSTATUS rpccli_samr_query_dom_info2(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx,
+ POLICY_HND *domain_pol,
+ uint16 switch_value,
+ SAM_UNK_CTR *ctr)
+{
+ prs_struct qbuf, rbuf;
+ SAMR_Q_QUERY_DOMAIN_INFO2 q;
+ SAMR_R_QUERY_DOMAIN_INFO2 r;
+ NTSTATUS result = NT_STATUS_UNSUCCESSFUL;
+
+ DEBUG(10,("cli_samr_query_dom_info2\n"));
+
+ ZERO_STRUCT(q);
+ ZERO_STRUCT(r);
+
+ /* Marshall data and send request */
+
+ init_samr_q_query_domain_info2(&q, domain_pol, switch_value);
+
+ r.ctr = ctr;
+
+ CLI_DO_RPC(cli, mem_ctx, PI_SAMR, SAMR_QUERY_DOMAIN_INFO2,
+ q, r,
+ qbuf, rbuf,
+ samr_io_q_query_domain_info2,
+ samr_io_r_query_domain_info2,
+ NT_STATUS_UNSUCCESSFUL);
+
+ /* Return output parameters */
+
+ if (!NT_STATUS_IS_OK(result = r.status)) {
+ goto done;
+ }
+
+ done:
+
+ return result;
+}
+
/* Set domain info */
NTSTATUS rpccli_samr_set_domain_info(struct rpc_pipe_client *cli,
diff --git a/source3/rpc_server/srv_samr_nt.c b/source3/rpc_server/srv_samr_nt.c
index 4507c1c88b..c9e6b552c8 100644
--- a/source3/rpc_server/srv_samr_nt.c
+++ b/source3/rpc_server/srv_samr_nt.c
@@ -2302,6 +2302,9 @@ NTSTATUS _samr_query_domain_info(pipes_struct *p,
init_unk_info3(&ctr->info.inf3, nt_logout);
break;
+ case 0x04:
+ init_unk_info4(&ctr->info.inf4, lp_serverstring());
+ break;
case 0x05:
init_unk_info5(&ctr->info.inf5, get_global_sam_name());
break;