summaryrefslogtreecommitdiff
path: root/source4/libnet
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2010-02-27 10:59:14 +0100
committerStefan Metzmacher <metze@samba.org>2010-03-01 16:11:53 +0100
commitf995e596bbc0e1b44335b10bf23458ac7328188b (patch)
tree7bf6013e83f3d23e42bc309dff289de97dcdd96f /source4/libnet
parent5d33c6d4f9719e36a3ed0f6b54c4365324ff352c (diff)
downloadsamba-f995e596bbc0e1b44335b10bf23458ac7328188b.tar.gz
samba-f995e596bbc0e1b44335b10bf23458ac7328188b.tar.bz2
samba-f995e596bbc0e1b44335b10bf23458ac7328188b.zip
s4:libnet: make use of explicit dcerpc_*_recv functions
metze
Diffstat (limited to 'source4/libnet')
-rw-r--r--source4/libnet/groupinfo.c8
-rw-r--r--source4/libnet/groupman.c8
-rw-r--r--source4/libnet/libnet_domain.c20
-rw-r--r--source4/libnet/libnet_group.c5
-rw-r--r--source4/libnet/libnet_lookup.c2
-rw-r--r--source4/libnet/libnet_rpc.c6
-rw-r--r--source4/libnet/libnet_unbecome_dc.c4
-rw-r--r--source4/libnet/libnet_user.c4
-rw-r--r--source4/libnet/userinfo.c8
-rw-r--r--source4/libnet/userman.c16
10 files changed, 40 insertions, 41 deletions
diff --git a/source4/libnet/groupinfo.c b/source4/libnet/groupinfo.c
index 1779c2816e..4b60d45f7e 100644
--- a/source4/libnet/groupinfo.c
+++ b/source4/libnet/groupinfo.c
@@ -67,7 +67,7 @@ static void continue_groupinfo_lookup(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct groupinfo_state);
/* receive samr_Lookup reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_LookupNames_recv(req);
if (!composite_is_ok(c)) return;
/* there could be a problem with name resolving itself */
@@ -126,7 +126,7 @@ static void continue_groupinfo_opengroup(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct groupinfo_state);
/* receive samr_OpenGroup reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_OpenGroup_recv(req);
if (!composite_is_ok(c)) return;
if (!NT_STATUS_IS_OK(s->querygroupinfo.out.result)) {
@@ -175,7 +175,7 @@ static void continue_groupinfo_getgroup(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct groupinfo_state);
/* receive samr_QueryGroupInfo reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_QueryGroupInfo_recv(req);
if (!composite_is_ok(c)) return;
/* check if querygroup itself went ok */
@@ -223,7 +223,7 @@ static void continue_groupinfo_closegroup(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct groupinfo_state);
/* receive samr_Close reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_Close_recv(req);
if (!composite_is_ok(c)) return;
if (!NT_STATUS_IS_OK(s->samrclose.out.result)) {
diff --git a/source4/libnet/groupman.c b/source4/libnet/groupman.c
index 0f54db9705..8e84d3cdb9 100644
--- a/source4/libnet/groupman.c
+++ b/source4/libnet/groupman.c
@@ -107,7 +107,7 @@ static void continue_groupadd_created(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct groupadd_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_CreateDomainGroup_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->creategroup.out.result;
@@ -196,7 +196,7 @@ static void continue_groupdel_name_found(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct groupdel_state);
/* receive samr_LookupNames result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_LookupNames_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->lookupname.out.result;
@@ -242,7 +242,7 @@ static void continue_groupdel_group_opened(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct groupdel_state);
/* receive samr_OpenGroup result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_OpenGroup_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->opengroup.out.result;
@@ -273,7 +273,7 @@ static void continue_groupdel_deleted(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct groupdel_state);
/* receive samr_DeleteGroup result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_DeleteDomainGroup_recv(req);
if (!composite_is_ok(c)) return;
/* return the actual function call status */
diff --git a/source4/libnet/libnet_domain.c b/source4/libnet/libnet_domain.c
index 43a6a0e10b..cae8d2c2e1 100644
--- a/source4/libnet/libnet_domain.c
+++ b/source4/libnet/libnet_domain.c
@@ -98,7 +98,7 @@ static void continue_domain_open_close(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct domain_open_samr_state);
/* receive samr_Close reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_Close_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -143,7 +143,7 @@ static void continue_domain_open_connect(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct domain_open_samr_state);
/* receive samr_Connect reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_Connect_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -184,7 +184,7 @@ static void continue_domain_open_lookup(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct domain_open_samr_state);
/* receive samr_LookupDomain reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_LookupDomain_recv(req);
if (s->monitor_fn) {
struct monitor_msg msg;
@@ -234,7 +234,7 @@ static void continue_domain_open_open(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct domain_open_samr_state);
/* receive samr_OpenDomain reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_OpenDomain_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -521,7 +521,7 @@ static void continue_lsa_policy_open(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct domain_open_lsa_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_OpenPolicy2_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -721,7 +721,7 @@ static void continue_lsa_close(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct domain_close_lsa_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_Close_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -823,7 +823,7 @@ static void continue_samr_close(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct domain_close_samr_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_Close_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -987,7 +987,7 @@ static void continue_samr_connect(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct domain_list_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_Connect_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -1030,7 +1030,7 @@ static void continue_samr_enum_domains(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct domain_list_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_EnumDomains_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
@@ -1090,7 +1090,7 @@ static void continue_samr_close_handle(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct domain_list_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_Close_recv(req);
if (!composite_is_ok(c)) return;
if (s->monitor_fn) {
diff --git a/source4/libnet/libnet_group.c b/source4/libnet/libnet_group.c
index 9e7abe81b1..9e2c696ff8 100644
--- a/source4/libnet/libnet_group.c
+++ b/source4/libnet/libnet_group.c
@@ -449,7 +449,6 @@ struct grouplist_state {
static void continue_lsa_domain_opened(struct composite_context *ctx);
static void continue_domain_queried(struct rpc_request *req);
static void continue_samr_domain_opened(struct composite_context *ctx);
-static void continue_domain_queried(struct rpc_request *req);
static void continue_groups_enumerated(struct rpc_request *req);
@@ -554,7 +553,7 @@ static void continue_domain_queried(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct grouplist_state);
/* receive result of rpc request */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_QueryInfoPolicy_recv(req);
if (!composite_is_ok(c)) return;
/* get the returned domain info */
@@ -631,7 +630,7 @@ static void continue_groups_enumerated(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct grouplist_state);
/* receive result of rpc request */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_EnumDomainGroups_recv(req);
if (!composite_is_ok(c)) return;
/* get the actual status of the rpc call result
diff --git a/source4/libnet/libnet_lookup.c b/source4/libnet/libnet_lookup.c
index 4548864ba4..7771a64e6d 100644
--- a/source4/libnet/libnet_lookup.c
+++ b/source4/libnet/libnet_lookup.c
@@ -348,7 +348,7 @@ static void continue_name_found(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct lookup_name_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_LookupNames_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->lookup.out.result;
diff --git a/source4/libnet/libnet_rpc.c b/source4/libnet/libnet_rpc.c
index 1c3c5916d4..1c35ef6ca1 100644
--- a/source4/libnet/libnet_rpc.c
+++ b/source4/libnet/libnet_rpc.c
@@ -593,7 +593,7 @@ static void continue_lsa_policy(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct rpc_connect_dci_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_OpenPolicy2_recv(req);
if (!NT_STATUS_IS_OK(c->status)) {
composite_error(c, c->status);
return;
@@ -650,7 +650,7 @@ static void continue_lsa_query_info2(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct rpc_connect_dci_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_QueryInfoPolicy2_recv(req);
/* In case of error just null the realm and guid and proceed
to the next step. After all, it doesn't have to be AD domain
@@ -723,7 +723,7 @@ static void continue_lsa_query_info(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct rpc_connect_dci_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_QueryInfoPolicy_recv(req);
if (!NT_STATUS_IS_OK(c->status)) {
s->r.out.error_string = talloc_asprintf(c,
"lsa_QueryInfoPolicy failed: %s",
diff --git a/source4/libnet/libnet_unbecome_dc.c b/source4/libnet/libnet_unbecome_dc.c
index 5fd0d55602..2b1023aa74 100644
--- a/source4/libnet/libnet_unbecome_dc.c
+++ b/source4/libnet/libnet_unbecome_dc.c
@@ -605,7 +605,7 @@ static void unbecomeDC_drsuapi_bind_recv(struct rpc_request *req)
struct libnet_UnbecomeDC_state);
struct composite_context *c = s->creq;
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_drsuapi_DsBind_recv(req);
if (!composite_is_ok(c)) return;
if (!W_ERROR_IS_OK(s->drsuapi.bind_r.out.result)) {
@@ -672,7 +672,7 @@ static void unbecomeDC_drsuapi_remove_ds_server_recv(struct rpc_request *req)
struct composite_context *c = s->creq;
struct drsuapi_DsRemoveDSServer *r = &s->drsuapi.rm_ds_srv_r;
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_drsuapi_DsRemoveDSServer_recv(req);
if (!composite_is_ok(c)) return;
if (!W_ERROR_IS_OK(r->out.result)) {
diff --git a/source4/libnet/libnet_user.c b/source4/libnet/libnet_user.c
index dd4d501c17..2bc7eeaf8c 100644
--- a/source4/libnet/libnet_user.c
+++ b/source4/libnet/libnet_user.c
@@ -1015,7 +1015,7 @@ static void continue_domain_queried(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userlist_state);
/* receive result of rpc request */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_lsa_QueryInfoPolicy_recv(req);
if (!composite_is_ok(c)) return;
/* get the returned domain info */
@@ -1094,7 +1094,7 @@ static void continue_users_enumerated(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userlist_state);
/* receive result of rpc request */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_EnumDomainUsers_recv(req);
if (!composite_is_ok(c)) return;
/* get the actual status of the rpc call result
diff --git a/source4/libnet/userinfo.c b/source4/libnet/userinfo.c
index a718ab9e85..9bd01accdd 100644
--- a/source4/libnet/userinfo.c
+++ b/source4/libnet/userinfo.c
@@ -66,7 +66,7 @@ static void continue_userinfo_lookup(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userinfo_state);
/* receive samr_Lookup reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_LookupNames_recv(req);
if (!composite_is_ok(c)) return;
/* there could be a problem with name resolving itself */
@@ -125,7 +125,7 @@ static void continue_userinfo_openuser(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userinfo_state);
/* receive samr_OpenUser reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_OpenUser_recv(req);
if (!composite_is_ok(c)) return;
if (!NT_STATUS_IS_OK(s->queryuserinfo.out.result)) {
@@ -174,7 +174,7 @@ static void continue_userinfo_getuser(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userinfo_state);
/* receive samr_QueryUserInfo reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_QueryUserInfo_recv(req);
if (!composite_is_ok(c)) return;
/* check if queryuser itself went ok */
@@ -222,7 +222,7 @@ static void continue_userinfo_closeuser(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userinfo_state);
/* receive samr_Close reply */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_Close_recv(req);
if (!composite_is_ok(c)) return;
if (!NT_STATUS_IS_OK(s->samrclose.out.result)) {
diff --git a/source4/libnet/userman.c b/source4/libnet/userman.c
index 62d4e0edd2..da51ef5da2 100644
--- a/source4/libnet/userman.c
+++ b/source4/libnet/userman.c
@@ -58,7 +58,7 @@ static void continue_useradd_create(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct useradd_state);
/* check rpc layer status code */
- c->status = dcerpc_ndr_request_recv(s->req);
+ c->status = dcerpc_samr_CreateUser_recv(s->req);
if (!composite_is_ok(c)) return;
/* check create user call status code */
@@ -222,7 +222,7 @@ static void continue_userdel_name_found(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userdel_state);
/* receive samr_LookupNames result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_LookupNames_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->lookupname.out.result;
@@ -285,7 +285,7 @@ static void continue_userdel_user_opened(struct rpc_request* req)
s = talloc_get_type(c->private_data, struct userdel_state);
/* receive samr_OpenUser result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_OpenUser_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->openuser.out.result;
@@ -333,7 +333,7 @@ static void continue_userdel_deleted(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct userdel_state);
/* receive samr_DeleteUser result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_DeleteUser_recv(req);
if (!composite_is_ok(c)) return;
/* return the actual function call status */
@@ -490,7 +490,7 @@ static void continue_usermod_name_found(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct usermod_state);
/* receive samr_LookupNames result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_LookupNames_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->lookupname.out.result;
@@ -714,7 +714,7 @@ static void continue_usermod_user_opened(struct rpc_request *req)
c = talloc_get_type(req->async.private_data, struct composite_context);
s = talloc_get_type(c->private_data, struct usermod_state);
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_OpenUser_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->openuser.out.result;
@@ -744,7 +744,7 @@ static void continue_usermod_user_queried(struct rpc_request *req)
i = &s->info;
/* receive samr_QueryUserInfo result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_QueryUserInfo_recv(req);
if (!composite_is_ok(c)) return;
c->status = s->queryuser.out.result;
@@ -782,7 +782,7 @@ static void continue_usermod_user_changed(struct rpc_request *req)
s = talloc_get_type(c->private_data, struct usermod_state);
/* receive samr_SetUserInfo result */
- c->status = dcerpc_ndr_request_recv(req);
+ c->status = dcerpc_samr_SetUserInfo_recv(req);
if (!composite_is_ok(c)) return;
/* return the actual function call status */