mirror of
https://github.com/samba-team/samba.git
synced 2025-01-10 01:18:15 +03:00
s4:libnet_become_dc: make use of dcerpc_binding_[g|s]et_assoc_group_id()
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
This commit is contained in:
parent
fd5d86aa85
commit
84528b9ee0
@ -2276,6 +2276,7 @@ static void becomeDC_drsuapi1_add_entry_recv(struct tevent_req *subreq)
|
||||
struct drsuapi_DsAddEntry *r = talloc_get_type_abort(s->ndr_struct_ptr,
|
||||
struct drsuapi_DsAddEntry);
|
||||
char *binding_str;
|
||||
uint32_t assoc_group_id;
|
||||
|
||||
s->ndr_struct_ptr = NULL;
|
||||
|
||||
@ -2461,7 +2462,9 @@ static void becomeDC_drsuapi1_add_entry_recv(struct tevent_req *subreq)
|
||||
}
|
||||
|
||||
/* w2k3 uses the same assoc_group_id as on the first connection, so we do */
|
||||
s->drsuapi2.binding->assoc_group_id = s->drsuapi1.pipe->assoc_group_id;
|
||||
assoc_group_id = dcerpc_binding_get_assoc_group_id(s->drsuapi1.pipe->binding);
|
||||
c->status = dcerpc_binding_set_assoc_group_id(s->drsuapi2.binding, assoc_group_id);
|
||||
if (!composite_is_ok(c)) return;
|
||||
|
||||
becomeDC_drsuapi_connect_send(s, &s->drsuapi2, becomeDC_drsuapi2_connect_recv);
|
||||
}
|
||||
@ -2507,6 +2510,7 @@ static void becomeDC_drsuapi2_bind_recv(struct tevent_req *subreq)
|
||||
struct libnet_BecomeDC_state);
|
||||
struct composite_context *c = s->creq;
|
||||
char *binding_str;
|
||||
uint32_t assoc_group_id;
|
||||
WERROR status;
|
||||
|
||||
c->status = dcerpc_drsuapi_DsBind_r_recv(subreq, s);
|
||||
@ -2532,7 +2536,9 @@ static void becomeDC_drsuapi2_bind_recv(struct tevent_req *subreq)
|
||||
}
|
||||
|
||||
/* w2k3 uses the same assoc_group_id as on the first connection, so we do */
|
||||
s->drsuapi3.binding->assoc_group_id = s->drsuapi1.pipe->assoc_group_id;
|
||||
assoc_group_id = dcerpc_binding_get_assoc_group_id(s->drsuapi1.pipe->binding);
|
||||
c->status = dcerpc_binding_set_assoc_group_id(s->drsuapi3.binding, assoc_group_id);
|
||||
if (!composite_is_ok(c)) return;
|
||||
/* w2k3 uses the concurrent multiplex feature on the 3rd connection, so we do */
|
||||
s->drsuapi3.binding->flags |= DCERPC_CONCURRENT_MULTIPLEX;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user