2 * Unix SMB/CIFS implementation.
3 * client auto-generated by pidl. DO NOT MODIFY!
7 #include "../librpc/gen_ndr/cli_epmapper.h"
9 struct rpccli_epm_Insert_state
{
10 struct epm_Insert orig
;
11 struct epm_Insert tmp
;
12 TALLOC_CTX
*out_mem_ctx
;
13 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
16 static void rpccli_epm_Insert_done(struct tevent_req
*subreq
);
18 struct tevent_req
*rpccli_epm_Insert_send(TALLOC_CTX
*mem_ctx
,
19 struct tevent_context
*ev
,
20 struct rpc_pipe_client
*cli
,
21 uint32_t _num_ents
/* [in] */,
22 struct epm_entry_t
*_entries
/* [in] [size_is(num_ents)] */,
23 uint32_t _replace
/* [in] */)
25 struct tevent_req
*req
;
26 struct rpccli_epm_Insert_state
*state
;
27 struct tevent_req
*subreq
;
29 req
= tevent_req_create(mem_ctx
, &state
,
30 struct rpccli_epm_Insert_state
);
34 state
->out_mem_ctx
= NULL
;
35 state
->dispatch_recv
= cli
->dispatch_recv
;
38 state
->orig
.in
.num_ents
= _num_ents
;
39 state
->orig
.in
.entries
= _entries
;
40 state
->orig
.in
.replace
= _replace
;
45 ZERO_STRUCT(state
->orig
.out
.result
);
47 if (DEBUGLEVEL
>= 10) {
48 NDR_PRINT_IN_DEBUG(epm_Insert
, &state
->orig
);
51 /* make a temporary copy, that we pass to the dispatch function */
52 state
->tmp
= state
->orig
;
54 subreq
= cli
->dispatch_send(state
, ev
, cli
,
58 if (tevent_req_nomem(subreq
, req
)) {
59 return tevent_req_post(req
, ev
);
61 tevent_req_set_callback(subreq
, rpccli_epm_Insert_done
, req
);
65 static void rpccli_epm_Insert_done(struct tevent_req
*subreq
)
67 struct tevent_req
*req
= tevent_req_callback_data(
68 subreq
, struct tevent_req
);
69 struct rpccli_epm_Insert_state
*state
= tevent_req_data(
70 req
, struct rpccli_epm_Insert_state
);
74 if (state
->out_mem_ctx
) {
75 mem_ctx
= state
->out_mem_ctx
;
80 status
= state
->dispatch_recv(subreq
, mem_ctx
);
82 if (!NT_STATUS_IS_OK(status
)) {
83 tevent_req_nterror(req
, status
);
87 /* Copy out parameters */
90 state
->orig
.out
.result
= state
->tmp
.out
.result
;
92 /* Reset temporary structure */
93 ZERO_STRUCT(state
->tmp
);
95 if (DEBUGLEVEL
>= 10) {
96 NDR_PRINT_OUT_DEBUG(epm_Insert
, &state
->orig
);
102 NTSTATUS
rpccli_epm_Insert_recv(struct tevent_req
*req
,
106 struct rpccli_epm_Insert_state
*state
= tevent_req_data(
107 req
, struct rpccli_epm_Insert_state
);
110 if (tevent_req_is_nterror(req
, &status
)) {
111 tevent_req_received(req
);
115 /* Steal possbile out parameters to the callers context */
116 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
119 *result
= state
->orig
.out
.result
;
121 tevent_req_received(req
);
125 NTSTATUS
rpccli_epm_Insert(struct rpc_pipe_client
*cli
,
127 uint32_t num_ents
/* [in] */,
128 struct epm_entry_t
*entries
/* [in] [size_is(num_ents)] */,
129 uint32_t replace
/* [in] */)
135 r
.in
.num_ents
= num_ents
;
136 r
.in
.entries
= entries
;
137 r
.in
.replace
= replace
;
139 if (DEBUGLEVEL
>= 10) {
140 NDR_PRINT_IN_DEBUG(epm_Insert
, &r
);
143 status
= cli
->dispatch(cli
,
149 if (!NT_STATUS_IS_OK(status
)) {
153 if (DEBUGLEVEL
>= 10) {
154 NDR_PRINT_OUT_DEBUG(epm_Insert
, &r
);
157 if (NT_STATUS_IS_ERR(status
)) {
161 /* Return variables */
167 struct rpccli_epm_Delete_state
{
168 struct epm_Delete orig
;
169 struct epm_Delete tmp
;
170 TALLOC_CTX
*out_mem_ctx
;
171 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
174 static void rpccli_epm_Delete_done(struct tevent_req
*subreq
);
176 struct tevent_req
*rpccli_epm_Delete_send(TALLOC_CTX
*mem_ctx
,
177 struct tevent_context
*ev
,
178 struct rpc_pipe_client
*cli
,
179 uint32_t _num_ents
/* [in] */,
180 struct epm_entry_t
*_entries
/* [in] [size_is(num_ents)] */)
182 struct tevent_req
*req
;
183 struct rpccli_epm_Delete_state
*state
;
184 struct tevent_req
*subreq
;
186 req
= tevent_req_create(mem_ctx
, &state
,
187 struct rpccli_epm_Delete_state
);
191 state
->out_mem_ctx
= NULL
;
192 state
->dispatch_recv
= cli
->dispatch_recv
;
195 state
->orig
.in
.num_ents
= _num_ents
;
196 state
->orig
.in
.entries
= _entries
;
201 ZERO_STRUCT(state
->orig
.out
.result
);
203 if (DEBUGLEVEL
>= 10) {
204 NDR_PRINT_IN_DEBUG(epm_Delete
, &state
->orig
);
207 /* make a temporary copy, that we pass to the dispatch function */
208 state
->tmp
= state
->orig
;
210 subreq
= cli
->dispatch_send(state
, ev
, cli
,
214 if (tevent_req_nomem(subreq
, req
)) {
215 return tevent_req_post(req
, ev
);
217 tevent_req_set_callback(subreq
, rpccli_epm_Delete_done
, req
);
221 static void rpccli_epm_Delete_done(struct tevent_req
*subreq
)
223 struct tevent_req
*req
= tevent_req_callback_data(
224 subreq
, struct tevent_req
);
225 struct rpccli_epm_Delete_state
*state
= tevent_req_data(
226 req
, struct rpccli_epm_Delete_state
);
230 if (state
->out_mem_ctx
) {
231 mem_ctx
= state
->out_mem_ctx
;
236 status
= state
->dispatch_recv(subreq
, mem_ctx
);
238 if (!NT_STATUS_IS_OK(status
)) {
239 tevent_req_nterror(req
, status
);
243 /* Copy out parameters */
246 state
->orig
.out
.result
= state
->tmp
.out
.result
;
248 /* Reset temporary structure */
249 ZERO_STRUCT(state
->tmp
);
251 if (DEBUGLEVEL
>= 10) {
252 NDR_PRINT_OUT_DEBUG(epm_Delete
, &state
->orig
);
255 tevent_req_done(req
);
258 NTSTATUS
rpccli_epm_Delete_recv(struct tevent_req
*req
,
262 struct rpccli_epm_Delete_state
*state
= tevent_req_data(
263 req
, struct rpccli_epm_Delete_state
);
266 if (tevent_req_is_nterror(req
, &status
)) {
267 tevent_req_received(req
);
271 /* Steal possbile out parameters to the callers context */
272 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
275 *result
= state
->orig
.out
.result
;
277 tevent_req_received(req
);
281 NTSTATUS
rpccli_epm_Delete(struct rpc_pipe_client
*cli
,
283 uint32_t num_ents
/* [in] */,
284 struct epm_entry_t
*entries
/* [in] [size_is(num_ents)] */)
290 r
.in
.num_ents
= num_ents
;
291 r
.in
.entries
= entries
;
293 if (DEBUGLEVEL
>= 10) {
294 NDR_PRINT_IN_DEBUG(epm_Delete
, &r
);
297 status
= cli
->dispatch(cli
,
303 if (!NT_STATUS_IS_OK(status
)) {
307 if (DEBUGLEVEL
>= 10) {
308 NDR_PRINT_OUT_DEBUG(epm_Delete
, &r
);
311 if (NT_STATUS_IS_ERR(status
)) {
315 /* Return variables */
321 struct rpccli_epm_Lookup_state
{
322 struct epm_Lookup orig
;
323 struct epm_Lookup tmp
;
324 TALLOC_CTX
*out_mem_ctx
;
325 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
328 static void rpccli_epm_Lookup_done(struct tevent_req
*subreq
);
330 struct tevent_req
*rpccli_epm_Lookup_send(TALLOC_CTX
*mem_ctx
,
331 struct tevent_context
*ev
,
332 struct rpc_pipe_client
*cli
,
333 uint32_t _inquiry_type
/* [in] */,
334 struct GUID
*_object
/* [in] [ptr] */,
335 struct rpc_if_id_t
*_interface_id
/* [in] [ptr] */,
336 uint32_t _vers_option
/* [in] */,
337 struct policy_handle
*_entry_handle
/* [in,out] [ref] */,
338 uint32_t _max_ents
/* [in] */,
339 uint32_t *_num_ents
/* [out] [ref] */,
340 struct epm_entry_t
*_entries
/* [out] [length_is(*num_ents),size_is(max_ents)] */)
342 struct tevent_req
*req
;
343 struct rpccli_epm_Lookup_state
*state
;
344 struct tevent_req
*subreq
;
346 req
= tevent_req_create(mem_ctx
, &state
,
347 struct rpccli_epm_Lookup_state
);
351 state
->out_mem_ctx
= NULL
;
352 state
->dispatch_recv
= cli
->dispatch_recv
;
355 state
->orig
.in
.inquiry_type
= _inquiry_type
;
356 state
->orig
.in
.object
= _object
;
357 state
->orig
.in
.interface_id
= _interface_id
;
358 state
->orig
.in
.vers_option
= _vers_option
;
359 state
->orig
.in
.entry_handle
= _entry_handle
;
360 state
->orig
.in
.max_ents
= _max_ents
;
363 state
->orig
.out
.entry_handle
= _entry_handle
;
364 state
->orig
.out
.num_ents
= _num_ents
;
365 state
->orig
.out
.entries
= _entries
;
368 ZERO_STRUCT(state
->orig
.out
.result
);
370 if (DEBUGLEVEL
>= 10) {
371 NDR_PRINT_IN_DEBUG(epm_Lookup
, &state
->orig
);
374 state
->out_mem_ctx
= talloc_named_const(state
, 0,
375 "rpccli_epm_Lookup_out_memory");
376 if (tevent_req_nomem(state
->out_mem_ctx
, req
)) {
377 return tevent_req_post(req
, ev
);
380 /* make a temporary copy, that we pass to the dispatch function */
381 state
->tmp
= state
->orig
;
383 subreq
= cli
->dispatch_send(state
, ev
, cli
,
387 if (tevent_req_nomem(subreq
, req
)) {
388 return tevent_req_post(req
, ev
);
390 tevent_req_set_callback(subreq
, rpccli_epm_Lookup_done
, req
);
394 static void rpccli_epm_Lookup_done(struct tevent_req
*subreq
)
396 struct tevent_req
*req
= tevent_req_callback_data(
397 subreq
, struct tevent_req
);
398 struct rpccli_epm_Lookup_state
*state
= tevent_req_data(
399 req
, struct rpccli_epm_Lookup_state
);
403 if (state
->out_mem_ctx
) {
404 mem_ctx
= state
->out_mem_ctx
;
409 status
= state
->dispatch_recv(subreq
, mem_ctx
);
411 if (!NT_STATUS_IS_OK(status
)) {
412 tevent_req_nterror(req
, status
);
416 /* Copy out parameters */
417 *state
->orig
.out
.entry_handle
= *state
->tmp
.out
.entry_handle
;
418 *state
->orig
.out
.num_ents
= *state
->tmp
.out
.num_ents
;
419 memcpy(state
->orig
.out
.entries
, state
->tmp
.out
.entries
, state
->tmp
.in
.max_ents
* sizeof(*state
->orig
.out
.entries
));
422 state
->orig
.out
.result
= state
->tmp
.out
.result
;
424 /* Reset temporary structure */
425 ZERO_STRUCT(state
->tmp
);
427 if (DEBUGLEVEL
>= 10) {
428 NDR_PRINT_OUT_DEBUG(epm_Lookup
, &state
->orig
);
431 tevent_req_done(req
);
434 NTSTATUS
rpccli_epm_Lookup_recv(struct tevent_req
*req
,
438 struct rpccli_epm_Lookup_state
*state
= tevent_req_data(
439 req
, struct rpccli_epm_Lookup_state
);
442 if (tevent_req_is_nterror(req
, &status
)) {
443 tevent_req_received(req
);
447 /* Steal possbile out parameters to the callers context */
448 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
451 *result
= state
->orig
.out
.result
;
453 tevent_req_received(req
);
457 NTSTATUS
rpccli_epm_Lookup(struct rpc_pipe_client
*cli
,
459 uint32_t inquiry_type
/* [in] */,
460 struct GUID
*object
/* [in] [ptr] */,
461 struct rpc_if_id_t
*interface_id
/* [in] [ptr] */,
462 uint32_t vers_option
/* [in] */,
463 struct policy_handle
*entry_handle
/* [in,out] [ref] */,
464 uint32_t max_ents
/* [in] */,
465 uint32_t *num_ents
/* [out] [ref] */,
466 struct epm_entry_t
*entries
/* [out] [length_is(*num_ents),size_is(max_ents)] */)
472 r
.in
.inquiry_type
= inquiry_type
;
473 r
.in
.object
= object
;
474 r
.in
.interface_id
= interface_id
;
475 r
.in
.vers_option
= vers_option
;
476 r
.in
.entry_handle
= entry_handle
;
477 r
.in
.max_ents
= max_ents
;
479 if (DEBUGLEVEL
>= 10) {
480 NDR_PRINT_IN_DEBUG(epm_Lookup
, &r
);
483 status
= cli
->dispatch(cli
,
489 if (!NT_STATUS_IS_OK(status
)) {
493 if (DEBUGLEVEL
>= 10) {
494 NDR_PRINT_OUT_DEBUG(epm_Lookup
, &r
);
497 if (NT_STATUS_IS_ERR(status
)) {
501 /* Return variables */
502 *entry_handle
= *r
.out
.entry_handle
;
503 *num_ents
= *r
.out
.num_ents
;
504 memcpy(entries
, r
.out
.entries
, r
.in
.max_ents
* sizeof(*entries
));
510 struct rpccli_epm_Map_state
{
513 TALLOC_CTX
*out_mem_ctx
;
514 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
517 static void rpccli_epm_Map_done(struct tevent_req
*subreq
);
519 struct tevent_req
*rpccli_epm_Map_send(TALLOC_CTX
*mem_ctx
,
520 struct tevent_context
*ev
,
521 struct rpc_pipe_client
*cli
,
522 struct GUID
*_object
/* [in] [ptr] */,
523 struct epm_twr_t
*_map_tower
/* [in] [ptr] */,
524 struct policy_handle
*_entry_handle
/* [in,out] [ref] */,
525 uint32_t _max_towers
/* [in] */,
526 uint32_t *_num_towers
/* [out] [ref] */,
527 struct epm_twr_p_t
*_towers
/* [out] [length_is(*num_towers),size_is(max_towers)] */)
529 struct tevent_req
*req
;
530 struct rpccli_epm_Map_state
*state
;
531 struct tevent_req
*subreq
;
533 req
= tevent_req_create(mem_ctx
, &state
,
534 struct rpccli_epm_Map_state
);
538 state
->out_mem_ctx
= NULL
;
539 state
->dispatch_recv
= cli
->dispatch_recv
;
542 state
->orig
.in
.object
= _object
;
543 state
->orig
.in
.map_tower
= _map_tower
;
544 state
->orig
.in
.entry_handle
= _entry_handle
;
545 state
->orig
.in
.max_towers
= _max_towers
;
548 state
->orig
.out
.entry_handle
= _entry_handle
;
549 state
->orig
.out
.num_towers
= _num_towers
;
550 state
->orig
.out
.towers
= _towers
;
553 ZERO_STRUCT(state
->orig
.out
.result
);
555 if (DEBUGLEVEL
>= 10) {
556 NDR_PRINT_IN_DEBUG(epm_Map
, &state
->orig
);
559 state
->out_mem_ctx
= talloc_named_const(state
, 0,
560 "rpccli_epm_Map_out_memory");
561 if (tevent_req_nomem(state
->out_mem_ctx
, req
)) {
562 return tevent_req_post(req
, ev
);
565 /* make a temporary copy, that we pass to the dispatch function */
566 state
->tmp
= state
->orig
;
568 subreq
= cli
->dispatch_send(state
, ev
, cli
,
572 if (tevent_req_nomem(subreq
, req
)) {
573 return tevent_req_post(req
, ev
);
575 tevent_req_set_callback(subreq
, rpccli_epm_Map_done
, req
);
579 static void rpccli_epm_Map_done(struct tevent_req
*subreq
)
581 struct tevent_req
*req
= tevent_req_callback_data(
582 subreq
, struct tevent_req
);
583 struct rpccli_epm_Map_state
*state
= tevent_req_data(
584 req
, struct rpccli_epm_Map_state
);
588 if (state
->out_mem_ctx
) {
589 mem_ctx
= state
->out_mem_ctx
;
594 status
= state
->dispatch_recv(subreq
, mem_ctx
);
596 if (!NT_STATUS_IS_OK(status
)) {
597 tevent_req_nterror(req
, status
);
601 /* Copy out parameters */
602 *state
->orig
.out
.entry_handle
= *state
->tmp
.out
.entry_handle
;
603 *state
->orig
.out
.num_towers
= *state
->tmp
.out
.num_towers
;
604 memcpy(state
->orig
.out
.towers
, state
->tmp
.out
.towers
, state
->tmp
.in
.max_towers
* sizeof(*state
->orig
.out
.towers
));
607 state
->orig
.out
.result
= state
->tmp
.out
.result
;
609 /* Reset temporary structure */
610 ZERO_STRUCT(state
->tmp
);
612 if (DEBUGLEVEL
>= 10) {
613 NDR_PRINT_OUT_DEBUG(epm_Map
, &state
->orig
);
616 tevent_req_done(req
);
619 NTSTATUS
rpccli_epm_Map_recv(struct tevent_req
*req
,
623 struct rpccli_epm_Map_state
*state
= tevent_req_data(
624 req
, struct rpccli_epm_Map_state
);
627 if (tevent_req_is_nterror(req
, &status
)) {
628 tevent_req_received(req
);
632 /* Steal possbile out parameters to the callers context */
633 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
636 *result
= state
->orig
.out
.result
;
638 tevent_req_received(req
);
642 NTSTATUS
rpccli_epm_Map(struct rpc_pipe_client
*cli
,
644 struct GUID
*object
/* [in] [ptr] */,
645 struct epm_twr_t
*map_tower
/* [in] [ptr] */,
646 struct policy_handle
*entry_handle
/* [in,out] [ref] */,
647 uint32_t max_towers
/* [in] */,
648 uint32_t *num_towers
/* [out] [ref] */,
649 struct epm_twr_p_t
*towers
/* [out] [length_is(*num_towers),size_is(max_towers)] */)
655 r
.in
.object
= object
;
656 r
.in
.map_tower
= map_tower
;
657 r
.in
.entry_handle
= entry_handle
;
658 r
.in
.max_towers
= max_towers
;
660 if (DEBUGLEVEL
>= 10) {
661 NDR_PRINT_IN_DEBUG(epm_Map
, &r
);
664 status
= cli
->dispatch(cli
,
670 if (!NT_STATUS_IS_OK(status
)) {
674 if (DEBUGLEVEL
>= 10) {
675 NDR_PRINT_OUT_DEBUG(epm_Map
, &r
);
678 if (NT_STATUS_IS_ERR(status
)) {
682 /* Return variables */
683 *entry_handle
= *r
.out
.entry_handle
;
684 *num_towers
= *r
.out
.num_towers
;
685 memcpy(towers
, r
.out
.towers
, r
.in
.max_towers
* sizeof(*towers
));
691 struct rpccli_epm_LookupHandleFree_state
{
692 struct epm_LookupHandleFree orig
;
693 struct epm_LookupHandleFree tmp
;
694 TALLOC_CTX
*out_mem_ctx
;
695 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
698 static void rpccli_epm_LookupHandleFree_done(struct tevent_req
*subreq
);
700 struct tevent_req
*rpccli_epm_LookupHandleFree_send(TALLOC_CTX
*mem_ctx
,
701 struct tevent_context
*ev
,
702 struct rpc_pipe_client
*cli
,
703 struct policy_handle
*_entry_handle
/* [in,out] [ref] */)
705 struct tevent_req
*req
;
706 struct rpccli_epm_LookupHandleFree_state
*state
;
707 struct tevent_req
*subreq
;
709 req
= tevent_req_create(mem_ctx
, &state
,
710 struct rpccli_epm_LookupHandleFree_state
);
714 state
->out_mem_ctx
= NULL
;
715 state
->dispatch_recv
= cli
->dispatch_recv
;
718 state
->orig
.in
.entry_handle
= _entry_handle
;
721 state
->orig
.out
.entry_handle
= _entry_handle
;
724 ZERO_STRUCT(state
->orig
.out
.result
);
726 if (DEBUGLEVEL
>= 10) {
727 NDR_PRINT_IN_DEBUG(epm_LookupHandleFree
, &state
->orig
);
730 state
->out_mem_ctx
= talloc_named_const(state
, 0,
731 "rpccli_epm_LookupHandleFree_out_memory");
732 if (tevent_req_nomem(state
->out_mem_ctx
, req
)) {
733 return tevent_req_post(req
, ev
);
736 /* make a temporary copy, that we pass to the dispatch function */
737 state
->tmp
= state
->orig
;
739 subreq
= cli
->dispatch_send(state
, ev
, cli
,
741 NDR_EPM_LOOKUPHANDLEFREE
,
743 if (tevent_req_nomem(subreq
, req
)) {
744 return tevent_req_post(req
, ev
);
746 tevent_req_set_callback(subreq
, rpccli_epm_LookupHandleFree_done
, req
);
750 static void rpccli_epm_LookupHandleFree_done(struct tevent_req
*subreq
)
752 struct tevent_req
*req
= tevent_req_callback_data(
753 subreq
, struct tevent_req
);
754 struct rpccli_epm_LookupHandleFree_state
*state
= tevent_req_data(
755 req
, struct rpccli_epm_LookupHandleFree_state
);
759 if (state
->out_mem_ctx
) {
760 mem_ctx
= state
->out_mem_ctx
;
765 status
= state
->dispatch_recv(subreq
, mem_ctx
);
767 if (!NT_STATUS_IS_OK(status
)) {
768 tevent_req_nterror(req
, status
);
772 /* Copy out parameters */
773 *state
->orig
.out
.entry_handle
= *state
->tmp
.out
.entry_handle
;
776 state
->orig
.out
.result
= state
->tmp
.out
.result
;
778 /* Reset temporary structure */
779 ZERO_STRUCT(state
->tmp
);
781 if (DEBUGLEVEL
>= 10) {
782 NDR_PRINT_OUT_DEBUG(epm_LookupHandleFree
, &state
->orig
);
785 tevent_req_done(req
);
788 NTSTATUS
rpccli_epm_LookupHandleFree_recv(struct tevent_req
*req
,
792 struct rpccli_epm_LookupHandleFree_state
*state
= tevent_req_data(
793 req
, struct rpccli_epm_LookupHandleFree_state
);
796 if (tevent_req_is_nterror(req
, &status
)) {
797 tevent_req_received(req
);
801 /* Steal possbile out parameters to the callers context */
802 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
805 *result
= state
->orig
.out
.result
;
807 tevent_req_received(req
);
811 NTSTATUS
rpccli_epm_LookupHandleFree(struct rpc_pipe_client
*cli
,
813 struct policy_handle
*entry_handle
/* [in,out] [ref] */)
815 struct epm_LookupHandleFree r
;
819 r
.in
.entry_handle
= entry_handle
;
821 if (DEBUGLEVEL
>= 10) {
822 NDR_PRINT_IN_DEBUG(epm_LookupHandleFree
, &r
);
825 status
= cli
->dispatch(cli
,
828 NDR_EPM_LOOKUPHANDLEFREE
,
831 if (!NT_STATUS_IS_OK(status
)) {
835 if (DEBUGLEVEL
>= 10) {
836 NDR_PRINT_OUT_DEBUG(epm_LookupHandleFree
, &r
);
839 if (NT_STATUS_IS_ERR(status
)) {
843 /* Return variables */
844 *entry_handle
= *r
.out
.entry_handle
;
850 struct rpccli_epm_InqObject_state
{
851 struct epm_InqObject orig
;
852 struct epm_InqObject tmp
;
853 TALLOC_CTX
*out_mem_ctx
;
854 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
857 static void rpccli_epm_InqObject_done(struct tevent_req
*subreq
);
859 struct tevent_req
*rpccli_epm_InqObject_send(TALLOC_CTX
*mem_ctx
,
860 struct tevent_context
*ev
,
861 struct rpc_pipe_client
*cli
,
862 struct GUID
*_epm_object
/* [in] [ref] */)
864 struct tevent_req
*req
;
865 struct rpccli_epm_InqObject_state
*state
;
866 struct tevent_req
*subreq
;
868 req
= tevent_req_create(mem_ctx
, &state
,
869 struct rpccli_epm_InqObject_state
);
873 state
->out_mem_ctx
= NULL
;
874 state
->dispatch_recv
= cli
->dispatch_recv
;
877 state
->orig
.in
.epm_object
= _epm_object
;
882 ZERO_STRUCT(state
->orig
.out
.result
);
884 if (DEBUGLEVEL
>= 10) {
885 NDR_PRINT_IN_DEBUG(epm_InqObject
, &state
->orig
);
888 /* make a temporary copy, that we pass to the dispatch function */
889 state
->tmp
= state
->orig
;
891 subreq
= cli
->dispatch_send(state
, ev
, cli
,
895 if (tevent_req_nomem(subreq
, req
)) {
896 return tevent_req_post(req
, ev
);
898 tevent_req_set_callback(subreq
, rpccli_epm_InqObject_done
, req
);
902 static void rpccli_epm_InqObject_done(struct tevent_req
*subreq
)
904 struct tevent_req
*req
= tevent_req_callback_data(
905 subreq
, struct tevent_req
);
906 struct rpccli_epm_InqObject_state
*state
= tevent_req_data(
907 req
, struct rpccli_epm_InqObject_state
);
911 if (state
->out_mem_ctx
) {
912 mem_ctx
= state
->out_mem_ctx
;
917 status
= state
->dispatch_recv(subreq
, mem_ctx
);
919 if (!NT_STATUS_IS_OK(status
)) {
920 tevent_req_nterror(req
, status
);
924 /* Copy out parameters */
927 state
->orig
.out
.result
= state
->tmp
.out
.result
;
929 /* Reset temporary structure */
930 ZERO_STRUCT(state
->tmp
);
932 if (DEBUGLEVEL
>= 10) {
933 NDR_PRINT_OUT_DEBUG(epm_InqObject
, &state
->orig
);
936 tevent_req_done(req
);
939 NTSTATUS
rpccli_epm_InqObject_recv(struct tevent_req
*req
,
943 struct rpccli_epm_InqObject_state
*state
= tevent_req_data(
944 req
, struct rpccli_epm_InqObject_state
);
947 if (tevent_req_is_nterror(req
, &status
)) {
948 tevent_req_received(req
);
952 /* Steal possbile out parameters to the callers context */
953 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
956 *result
= state
->orig
.out
.result
;
958 tevent_req_received(req
);
962 NTSTATUS
rpccli_epm_InqObject(struct rpc_pipe_client
*cli
,
964 struct GUID
*epm_object
/* [in] [ref] */)
966 struct epm_InqObject r
;
970 r
.in
.epm_object
= epm_object
;
972 if (DEBUGLEVEL
>= 10) {
973 NDR_PRINT_IN_DEBUG(epm_InqObject
, &r
);
976 status
= cli
->dispatch(cli
,
982 if (!NT_STATUS_IS_OK(status
)) {
986 if (DEBUGLEVEL
>= 10) {
987 NDR_PRINT_OUT_DEBUG(epm_InqObject
, &r
);
990 if (NT_STATUS_IS_ERR(status
)) {
994 /* Return variables */
1000 struct rpccli_epm_MgmtDelete_state
{
1001 struct epm_MgmtDelete orig
;
1002 struct epm_MgmtDelete tmp
;
1003 TALLOC_CTX
*out_mem_ctx
;
1004 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
1007 static void rpccli_epm_MgmtDelete_done(struct tevent_req
*subreq
);
1009 struct tevent_req
*rpccli_epm_MgmtDelete_send(TALLOC_CTX
*mem_ctx
,
1010 struct tevent_context
*ev
,
1011 struct rpc_pipe_client
*cli
,
1012 uint32_t _object_speced
/* [in] */,
1013 struct GUID
*_object
/* [in] [ptr] */,
1014 struct epm_twr_t
*_tower
/* [in] [ptr] */)
1016 struct tevent_req
*req
;
1017 struct rpccli_epm_MgmtDelete_state
*state
;
1018 struct tevent_req
*subreq
;
1020 req
= tevent_req_create(mem_ctx
, &state
,
1021 struct rpccli_epm_MgmtDelete_state
);
1025 state
->out_mem_ctx
= NULL
;
1026 state
->dispatch_recv
= cli
->dispatch_recv
;
1029 state
->orig
.in
.object_speced
= _object_speced
;
1030 state
->orig
.in
.object
= _object
;
1031 state
->orig
.in
.tower
= _tower
;
1033 /* Out parameters */
1036 ZERO_STRUCT(state
->orig
.out
.result
);
1038 if (DEBUGLEVEL
>= 10) {
1039 NDR_PRINT_IN_DEBUG(epm_MgmtDelete
, &state
->orig
);
1042 /* make a temporary copy, that we pass to the dispatch function */
1043 state
->tmp
= state
->orig
;
1045 subreq
= cli
->dispatch_send(state
, ev
, cli
,
1046 &ndr_table_epmapper
,
1049 if (tevent_req_nomem(subreq
, req
)) {
1050 return tevent_req_post(req
, ev
);
1052 tevent_req_set_callback(subreq
, rpccli_epm_MgmtDelete_done
, req
);
1056 static void rpccli_epm_MgmtDelete_done(struct tevent_req
*subreq
)
1058 struct tevent_req
*req
= tevent_req_callback_data(
1059 subreq
, struct tevent_req
);
1060 struct rpccli_epm_MgmtDelete_state
*state
= tevent_req_data(
1061 req
, struct rpccli_epm_MgmtDelete_state
);
1063 TALLOC_CTX
*mem_ctx
;
1065 if (state
->out_mem_ctx
) {
1066 mem_ctx
= state
->out_mem_ctx
;
1071 status
= state
->dispatch_recv(subreq
, mem_ctx
);
1072 TALLOC_FREE(subreq
);
1073 if (!NT_STATUS_IS_OK(status
)) {
1074 tevent_req_nterror(req
, status
);
1078 /* Copy out parameters */
1081 state
->orig
.out
.result
= state
->tmp
.out
.result
;
1083 /* Reset temporary structure */
1084 ZERO_STRUCT(state
->tmp
);
1086 if (DEBUGLEVEL
>= 10) {
1087 NDR_PRINT_OUT_DEBUG(epm_MgmtDelete
, &state
->orig
);
1090 tevent_req_done(req
);
1093 NTSTATUS
rpccli_epm_MgmtDelete_recv(struct tevent_req
*req
,
1094 TALLOC_CTX
*mem_ctx
,
1097 struct rpccli_epm_MgmtDelete_state
*state
= tevent_req_data(
1098 req
, struct rpccli_epm_MgmtDelete_state
);
1101 if (tevent_req_is_nterror(req
, &status
)) {
1102 tevent_req_received(req
);
1106 /* Steal possbile out parameters to the callers context */
1107 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
1110 *result
= state
->orig
.out
.result
;
1112 tevent_req_received(req
);
1113 return NT_STATUS_OK
;
1116 NTSTATUS
rpccli_epm_MgmtDelete(struct rpc_pipe_client
*cli
,
1117 TALLOC_CTX
*mem_ctx
,
1118 uint32_t object_speced
/* [in] */,
1119 struct GUID
*object
/* [in] [ptr] */,
1120 struct epm_twr_t
*tower
/* [in] [ptr] */)
1122 struct epm_MgmtDelete r
;
1126 r
.in
.object_speced
= object_speced
;
1127 r
.in
.object
= object
;
1130 if (DEBUGLEVEL
>= 10) {
1131 NDR_PRINT_IN_DEBUG(epm_MgmtDelete
, &r
);
1134 status
= cli
->dispatch(cli
,
1136 &ndr_table_epmapper
,
1140 if (!NT_STATUS_IS_OK(status
)) {
1144 if (DEBUGLEVEL
>= 10) {
1145 NDR_PRINT_OUT_DEBUG(epm_MgmtDelete
, &r
);
1148 if (NT_STATUS_IS_ERR(status
)) {
1152 /* Return variables */
1155 return NT_STATUS_OK
;
1158 struct rpccli_epm_MapAuth_state
{
1159 struct epm_MapAuth orig
;
1160 struct epm_MapAuth tmp
;
1161 TALLOC_CTX
*out_mem_ctx
;
1162 NTSTATUS (*dispatch_recv
)(struct tevent_req
*req
, TALLOC_CTX
*mem_ctx
);
1165 static void rpccli_epm_MapAuth_done(struct tevent_req
*subreq
);
1167 struct tevent_req
*rpccli_epm_MapAuth_send(TALLOC_CTX
*mem_ctx
,
1168 struct tevent_context
*ev
,
1169 struct rpc_pipe_client
*cli
)
1171 struct tevent_req
*req
;
1172 struct rpccli_epm_MapAuth_state
*state
;
1173 struct tevent_req
*subreq
;
1175 req
= tevent_req_create(mem_ctx
, &state
,
1176 struct rpccli_epm_MapAuth_state
);
1180 state
->out_mem_ctx
= NULL
;
1181 state
->dispatch_recv
= cli
->dispatch_recv
;
1185 /* Out parameters */
1188 ZERO_STRUCT(state
->orig
.out
.result
);
1190 if (DEBUGLEVEL
>= 10) {
1191 NDR_PRINT_IN_DEBUG(epm_MapAuth
, &state
->orig
);
1194 /* make a temporary copy, that we pass to the dispatch function */
1195 state
->tmp
= state
->orig
;
1197 subreq
= cli
->dispatch_send(state
, ev
, cli
,
1198 &ndr_table_epmapper
,
1201 if (tevent_req_nomem(subreq
, req
)) {
1202 return tevent_req_post(req
, ev
);
1204 tevent_req_set_callback(subreq
, rpccli_epm_MapAuth_done
, req
);
1208 static void rpccli_epm_MapAuth_done(struct tevent_req
*subreq
)
1210 struct tevent_req
*req
= tevent_req_callback_data(
1211 subreq
, struct tevent_req
);
1212 struct rpccli_epm_MapAuth_state
*state
= tevent_req_data(
1213 req
, struct rpccli_epm_MapAuth_state
);
1215 TALLOC_CTX
*mem_ctx
;
1217 if (state
->out_mem_ctx
) {
1218 mem_ctx
= state
->out_mem_ctx
;
1223 status
= state
->dispatch_recv(subreq
, mem_ctx
);
1224 TALLOC_FREE(subreq
);
1225 if (!NT_STATUS_IS_OK(status
)) {
1226 tevent_req_nterror(req
, status
);
1230 /* Copy out parameters */
1233 state
->orig
.out
.result
= state
->tmp
.out
.result
;
1235 /* Reset temporary structure */
1236 ZERO_STRUCT(state
->tmp
);
1238 if (DEBUGLEVEL
>= 10) {
1239 NDR_PRINT_OUT_DEBUG(epm_MapAuth
, &state
->orig
);
1242 tevent_req_done(req
);
1245 NTSTATUS
rpccli_epm_MapAuth_recv(struct tevent_req
*req
,
1246 TALLOC_CTX
*mem_ctx
,
1249 struct rpccli_epm_MapAuth_state
*state
= tevent_req_data(
1250 req
, struct rpccli_epm_MapAuth_state
);
1253 if (tevent_req_is_nterror(req
, &status
)) {
1254 tevent_req_received(req
);
1258 /* Steal possbile out parameters to the callers context */
1259 talloc_steal(mem_ctx
, state
->out_mem_ctx
);
1262 *result
= state
->orig
.out
.result
;
1264 tevent_req_received(req
);
1265 return NT_STATUS_OK
;
1268 NTSTATUS
rpccli_epm_MapAuth(struct rpc_pipe_client
*cli
,
1269 TALLOC_CTX
*mem_ctx
)
1271 struct epm_MapAuth r
;
1276 if (DEBUGLEVEL
>= 10) {
1277 NDR_PRINT_IN_DEBUG(epm_MapAuth
, &r
);
1280 status
= cli
->dispatch(cli
,
1282 &ndr_table_epmapper
,
1286 if (!NT_STATUS_IS_OK(status
)) {
1290 if (DEBUGLEVEL
>= 10) {
1291 NDR_PRINT_OUT_DEBUG(epm_MapAuth
, &r
);
1294 if (NT_STATUS_IS_ERR(status
)) {
1298 /* Return variables */
1301 return NT_STATUS_OK
;