From a6d42784d02e1b0305a6616f4f7d5eb350447d75 Mon Sep 17 00:00:00 2001 From: Günther Deschner Date: Tue, 16 Mar 2010 14:01:27 +0100 Subject: s3: re-run make samba3-idl. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Guenther Signed-off-by: Günther Deschner --- librpc/gen_ndr/cli_lsa.c | 67 ++++++-- librpc/gen_ndr/cli_lsa.h | 22 ++- librpc/gen_ndr/lsa.h | 53 +++++- librpc/gen_ndr/ndr_lsa.c | 439 +++++++++++++++++++++++++++++++++++++++++++++-- librpc/gen_ndr/ndr_lsa.h | 10 +- librpc/gen_ndr/srv_lsa.c | 31 +++- librpc/gen_ndr/srv_lsa.h | 4 +- 7 files changed, 579 insertions(+), 47 deletions(-) diff --git a/librpc/gen_ndr/cli_lsa.c b/librpc/gen_ndr/cli_lsa.c index aa329b14e5..c75fb8fd6a 100644 --- a/librpc/gen_ndr/cli_lsa.c +++ b/librpc/gen_ndr/cli_lsa.c @@ -10840,25 +10840,31 @@ NTSTATUS rpccli_lsa_lsaRQueryForestTrustInformation(struct rpc_pipe_client *cli, return r.out.result; } -struct rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_state { - struct lsa_LSARSETFORESTTRUSTINFORMATION orig; - struct lsa_LSARSETFORESTTRUSTINFORMATION tmp; +struct rpccli_lsa_lsaRSetForestTrustInformation_state { + struct lsa_lsaRSetForestTrustInformation orig; + struct lsa_lsaRSetForestTrustInformation tmp; TALLOC_CTX *out_mem_ctx; NTSTATUS (*dispatch_recv)(struct tevent_req *req, TALLOC_CTX *mem_ctx); }; -static void rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_done(struct tevent_req *subreq); +static void rpccli_lsa_lsaRSetForestTrustInformation_done(struct tevent_req *subreq); -struct tevent_req *rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_send(TALLOC_CTX *mem_ctx, +struct tevent_req *rpccli_lsa_lsaRSetForestTrustInformation_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, - struct rpc_pipe_client *cli) + struct rpc_pipe_client *cli, + struct policy_handle *_handle /* [in] [ref] */, + struct lsa_StringLarge *_trusted_domain_name /* [in] [ref] */, + uint16_t _highest_record_type /* [in] */, + struct lsa_ForestTrustInformation *_forest_trust_info /* [in] [ref] */, + uint8_t _check_only /* [in] */, + struct lsa_ForestTrustCollisionInfo **_collision_info /* [out] [ref] */) { struct tevent_req *req; - struct rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_state *state; + struct rpccli_lsa_lsaRSetForestTrustInformation_state *state; struct tevent_req *subreq; req = tevent_req_create(mem_ctx, &state, - struct rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_state); + struct rpccli_lsa_lsaRSetForestTrustInformation_state); if (req == NULL) { return NULL; } @@ -10866,12 +10872,24 @@ struct tevent_req *rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_send(TALLOC_CTX *mem state->dispatch_recv = cli->dispatch_recv; /* In parameters */ + state->orig.in.handle = _handle; + state->orig.in.trusted_domain_name = _trusted_domain_name; + state->orig.in.highest_record_type = _highest_record_type; + state->orig.in.forest_trust_info = _forest_trust_info; + state->orig.in.check_only = _check_only; /* Out parameters */ + state->orig.out.collision_info = _collision_info; /* Result */ ZERO_STRUCT(state->orig.out.result); + state->out_mem_ctx = talloc_named_const(state, 0, + "rpccli_lsa_lsaRSetForestTrustInformation_out_memory"); + if (tevent_req_nomem(state->out_mem_ctx, req)) { + return tevent_req_post(req, ev); + } + /* make a temporary copy, that we pass to the dispatch function */ state->tmp = state->orig; @@ -10882,16 +10900,16 @@ struct tevent_req *rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_send(TALLOC_CTX *mem if (tevent_req_nomem(subreq, req)) { return tevent_req_post(req, ev); } - tevent_req_set_callback(subreq, rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_done, req); + tevent_req_set_callback(subreq, rpccli_lsa_lsaRSetForestTrustInformation_done, req); return req; } -static void rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_done(struct tevent_req *subreq) +static void rpccli_lsa_lsaRSetForestTrustInformation_done(struct tevent_req *subreq) { struct tevent_req *req = tevent_req_callback_data( subreq, struct tevent_req); - struct rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_state *state = tevent_req_data( - req, struct rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_state); + struct rpccli_lsa_lsaRSetForestTrustInformation_state *state = tevent_req_data( + req, struct rpccli_lsa_lsaRSetForestTrustInformation_state); NTSTATUS status; TALLOC_CTX *mem_ctx; @@ -10909,6 +10927,7 @@ static void rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_done(struct tevent_req *sub } /* Copy out parameters */ + *state->orig.out.collision_info = *state->tmp.out.collision_info; /* Copy result */ state->orig.out.result = state->tmp.out.result; @@ -10919,12 +10938,12 @@ static void rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_done(struct tevent_req *sub tevent_req_done(req); } -NTSTATUS rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_recv(struct tevent_req *req, +NTSTATUS rpccli_lsa_lsaRSetForestTrustInformation_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx, NTSTATUS *result) { - struct rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_state *state = tevent_req_data( - req, struct rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_state); + struct rpccli_lsa_lsaRSetForestTrustInformation_state *state = tevent_req_data( + req, struct rpccli_lsa_lsaRSetForestTrustInformation_state); NTSTATUS status; if (tevent_req_is_nterror(req, &status)) { @@ -10942,13 +10961,24 @@ NTSTATUS rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_recv(struct tevent_req *req, return NT_STATUS_OK; } -NTSTATUS rpccli_lsa_LSARSETFORESTTRUSTINFORMATION(struct rpc_pipe_client *cli, - TALLOC_CTX *mem_ctx) +NTSTATUS rpccli_lsa_lsaRSetForestTrustInformation(struct rpc_pipe_client *cli, + TALLOC_CTX *mem_ctx, + struct policy_handle *handle /* [in] [ref] */, + struct lsa_StringLarge *trusted_domain_name /* [in] [ref] */, + uint16_t highest_record_type /* [in] */, + struct lsa_ForestTrustInformation *forest_trust_info /* [in] [ref] */, + uint8_t check_only /* [in] */, + struct lsa_ForestTrustCollisionInfo **collision_info /* [out] [ref] */) { - struct lsa_LSARSETFORESTTRUSTINFORMATION r; + struct lsa_lsaRSetForestTrustInformation r; NTSTATUS status; /* In parameters */ + r.in.handle = handle; + r.in.trusted_domain_name = trusted_domain_name; + r.in.highest_record_type = highest_record_type; + r.in.forest_trust_info = forest_trust_info; + r.in.check_only = check_only; status = cli->dispatch(cli, mem_ctx, @@ -10965,6 +10995,7 @@ NTSTATUS rpccli_lsa_LSARSETFORESTTRUSTINFORMATION(struct rpc_pipe_client *cli, } /* Return variables */ + *collision_info = *r.out.collision_info; /* Return result */ return r.out.result; diff --git a/librpc/gen_ndr/cli_lsa.h b/librpc/gen_ndr/cli_lsa.h index d49c0ff155..3caeb847c3 100644 --- a/librpc/gen_ndr/cli_lsa.h +++ b/librpc/gen_ndr/cli_lsa.h @@ -1013,14 +1013,26 @@ NTSTATUS rpccli_lsa_lsaRQueryForestTrustInformation(struct rpc_pipe_client *cli, struct lsa_String *trusted_domain_name /* [in] [ref] */, uint16_t unknown /* [in] */, struct lsa_ForestTrustInformation **forest_trust_info /* [out] [ref] */); -struct tevent_req *rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_send(TALLOC_CTX *mem_ctx, +struct tevent_req *rpccli_lsa_lsaRSetForestTrustInformation_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, - struct rpc_pipe_client *cli); -NTSTATUS rpccli_lsa_LSARSETFORESTTRUSTINFORMATION_recv(struct tevent_req *req, + struct rpc_pipe_client *cli, + struct policy_handle *_handle /* [in] [ref] */, + struct lsa_StringLarge *_trusted_domain_name /* [in] [ref] */, + uint16_t _highest_record_type /* [in] */, + struct lsa_ForestTrustInformation *_forest_trust_info /* [in] [ref] */, + uint8_t _check_only /* [in] */, + struct lsa_ForestTrustCollisionInfo **_collision_info /* [out] [ref] */); +NTSTATUS rpccli_lsa_lsaRSetForestTrustInformation_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx, NTSTATUS *result); -NTSTATUS rpccli_lsa_LSARSETFORESTTRUSTINFORMATION(struct rpc_pipe_client *cli, - TALLOC_CTX *mem_ctx); +NTSTATUS rpccli_lsa_lsaRSetForestTrustInformation(struct rpc_pipe_client *cli, + TALLOC_CTX *mem_ctx, + struct policy_handle *handle /* [in] [ref] */, + struct lsa_StringLarge *trusted_domain_name /* [in] [ref] */, + uint16_t highest_record_type /* [in] */, + struct lsa_ForestTrustInformation *forest_trust_info /* [in] [ref] */, + uint8_t check_only /* [in] */, + struct lsa_ForestTrustCollisionInfo **collision_info /* [out] [ref] */); struct tevent_req *rpccli_lsa_CREDRRENAME_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct rpc_pipe_client *cli); diff --git a/librpc/gen_ndr/lsa.h b/librpc/gen_ndr/lsa.h index 1c6323fafd..82c377f454 100644 --- a/librpc/gen_ndr/lsa.h +++ b/librpc/gen_ndr/lsa.h @@ -773,6 +773,48 @@ struct lsa_ForestTrustInformation { struct lsa_ForestTrustRecord **entries;/* [unique,size_is(count)] */ }/* [public] */; +enum lsa_ForestTrustCollisionRecordType +#ifndef USE_UINT_ENUMS + { + LSA_FOREST_TRUST_COLLISION_TDO=(int)(0), + LSA_FOREST_TRUST_COLLISION_XREF=(int)(1), + LSA_FOREST_TRUST_COLLISION_OTHER=(int)(2) +} +#else + { __donnot_use_enum_lsa_ForestTrustCollisionRecordType=0x7FFFFFFF} +#define LSA_FOREST_TRUST_COLLISION_TDO ( 0 ) +#define LSA_FOREST_TRUST_COLLISION_XREF ( 1 ) +#define LSA_FOREST_TRUST_COLLISION_OTHER ( 2 ) +#endif +; + +/* bitmap lsa_ForestTrustCollisionTDOFlags */ +#define LSA_TLN_DISABLED_NEW ( 0x00000001 ) +#define LSA_TLN_DISABLED_ADMIN ( 0x00000002 ) +#define LSA_TLN_DISABLED_CONFLICT ( 0x00000004 ) + +/* bitmap lsa_ForestTrustCollisionXrefFlags */ +#define LSA_SID_DISABLED_ADMIN ( 0x00000001 ) +#define LSA_SID_DISABLED_CONFLICT ( 0x00000002 ) +#define LSA_NB_DISABLED_ADMIN ( 0x00000004 ) +#define LSA_NB_DISABLED_CONFLICT ( 0x00000008 ) + +union lsa_ForestTrustCollisionFlags { + uint32_t flags;/* [case(LSA_FOREST_TRUST_COLLISION_TDO)] */ +}/* [nodiscriminant] */; + +struct lsa_ForestTrustCollisionRecord { + uint32_t index; + enum lsa_ForestTrustCollisionRecordType type; + union lsa_ForestTrustCollisionFlags flags;/* [switch_is(type)] */ + struct lsa_String name; +}; + +struct lsa_ForestTrustCollisionInfo { + uint32_t count; + struct lsa_ForestTrustCollisionRecord **entries;/* [unique,size_is(count)] */ +}; + struct lsa_Close { struct { @@ -1771,8 +1813,17 @@ struct lsa_lsaRQueryForestTrustInformation { }; -struct lsa_LSARSETFORESTTRUSTINFORMATION { +struct lsa_lsaRSetForestTrustInformation { + struct { + struct policy_handle *handle;/* [ref] */ + struct lsa_StringLarge *trusted_domain_name;/* [ref] */ + uint16_t highest_record_type; + struct lsa_ForestTrustInformation *forest_trust_info;/* [ref] */ + uint8_t check_only; + } in; + struct { + struct lsa_ForestTrustCollisionInfo **collision_info;/* [ref] */ NTSTATUS result; } out; diff --git a/librpc/gen_ndr/ndr_lsa.c b/librpc/gen_ndr/ndr_lsa.c index 55f876a3fa..4389b9589d 100644 --- a/librpc/gen_ndr/ndr_lsa.c +++ b/librpc/gen_ndr/ndr_lsa.c @@ -5355,6 +5355,328 @@ _PUBLIC_ void ndr_print_lsa_ForestTrustInformation(struct ndr_print *ndr, const ndr->depth--; } +static enum ndr_err_code ndr_push_lsa_ForestTrustCollisionRecordType(struct ndr_push *ndr, int ndr_flags, enum lsa_ForestTrustCollisionRecordType r) +{ + NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r)); + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionRecordType(struct ndr_pull *ndr, int ndr_flags, enum lsa_ForestTrustCollisionRecordType *r) +{ + uint32_t v; + NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v)); + *r = v; + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_lsa_ForestTrustCollisionRecordType(struct ndr_print *ndr, const char *name, enum lsa_ForestTrustCollisionRecordType r) +{ + const char *val = NULL; + + switch (r) { + case LSA_FOREST_TRUST_COLLISION_TDO: val = "LSA_FOREST_TRUST_COLLISION_TDO"; break; + case LSA_FOREST_TRUST_COLLISION_XREF: val = "LSA_FOREST_TRUST_COLLISION_XREF"; break; + case LSA_FOREST_TRUST_COLLISION_OTHER: val = "LSA_FOREST_TRUST_COLLISION_OTHER"; break; + } + ndr_print_enum(ndr, name, "ENUM", val, r); +} + +static enum ndr_err_code ndr_push_lsa_ForestTrustCollisionTDOFlags(struct ndr_push *ndr, int ndr_flags, uint32_t r) +{ + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r)); + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionTDOFlags(struct ndr_pull *ndr, int ndr_flags, uint32_t *r) +{ + uint32_t v; + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v)); + *r = v; + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_lsa_ForestTrustCollisionTDOFlags(struct ndr_print *ndr, const char *name, uint32_t r) +{ + ndr_print_uint32(ndr, name, r); + ndr->depth++; + ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TLN_DISABLED_NEW", LSA_TLN_DISABLED_NEW, r); + ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TLN_DISABLED_ADMIN", LSA_TLN_DISABLED_ADMIN, r); + ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TLN_DISABLED_CONFLICT", LSA_TLN_DISABLED_CONFLICT, r); + ndr->depth--; +} + +static enum ndr_err_code ndr_push_lsa_ForestTrustCollisionXrefFlags(struct ndr_push *ndr, int ndr_flags, uint32_t r) +{ + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r)); + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionXrefFlags(struct ndr_pull *ndr, int ndr_flags, uint32_t *r) +{ + uint32_t v; + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v)); + *r = v; + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_lsa_ForestTrustCollisionXrefFlags(struct ndr_print *ndr, const char *name, uint32_t r) +{ + ndr_print_uint32(ndr, name, r); + ndr->depth++; + ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_SID_DISABLED_ADMIN", LSA_SID_DISABLED_ADMIN, r); + ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_SID_DISABLED_CONFLICT", LSA_SID_DISABLED_CONFLICT, r); + ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_NB_DISABLED_ADMIN", LSA_NB_DISABLED_ADMIN, r); + ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_NB_DISABLED_CONFLICT", LSA_NB_DISABLED_CONFLICT, r); + ndr->depth--; +} + +static enum ndr_err_code ndr_push_lsa_ForestTrustCollisionFlags(struct ndr_push *ndr, int ndr_flags, const union lsa_ForestTrustCollisionFlags *r) +{ + if (ndr_flags & NDR_SCALARS) { + int level = ndr_push_get_switch_value(ndr, r); + NDR_CHECK(ndr_push_union_align(ndr, 4)); + switch (level) { + case LSA_FOREST_TRUST_COLLISION_TDO: { + NDR_CHECK(ndr_push_lsa_ForestTrustCollisionTDOFlags(ndr, NDR_SCALARS, r->flags)); + break; } + + case LSA_FOREST_TRUST_COLLISION_XREF: { + NDR_CHECK(ndr_push_lsa_ForestTrustCollisionXrefFlags(ndr, NDR_SCALARS, r->flags)); + break; } + + default: { + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->flags)); + break; } + + } + } + if (ndr_flags & NDR_BUFFERS) { + int level = ndr_push_get_switch_value(ndr, r); + switch (level) { + case LSA_FOREST_TRUST_COLLISION_TDO: + break; + + case LSA_FOREST_TRUST_COLLISION_XREF: + break; + + default: + break; + + } + } + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionFlags(struct ndr_pull *ndr, int ndr_flags, union lsa_ForestTrustCollisionFlags *r) +{ + int level; + level = ndr_pull_get_switch_value(ndr, r); + if (ndr_flags & NDR_SCALARS) { + NDR_CHECK(ndr_pull_union_align(ndr, 4)); + switch (level) { + case LSA_FOREST_TRUST_COLLISION_TDO: { + NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionTDOFlags(ndr, NDR_SCALARS, &r->flags)); + break; } + + case LSA_FOREST_TRUST_COLLISION_XREF: { + NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionXrefFlags(ndr, NDR_SCALARS, &r->flags)); + break; } + + default: { + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->flags)); + break; } + + } + } + if (ndr_flags & NDR_BUFFERS) { + switch (level) { + case LSA_FOREST_TRUST_COLLISION_TDO: + break; + + case LSA_FOREST_TRUST_COLLISION_XREF: + break; + + default: + break; + + } + } + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_lsa_ForestTrustCollisionFlags(struct ndr_print *ndr, const char *name, const union lsa_ForestTrustCollisionFlags *r) +{ + int level; + level = ndr_print_get_switch_value(ndr, r); + ndr_print_union(ndr, name, level, "lsa_ForestTrustCollisionFlags"); + switch (level) { + case LSA_FOREST_TRUST_COLLISION_TDO: + ndr_print_lsa_ForestTrustCollisionTDOFlags(ndr, "flags", r->flags); + break; + + case LSA_FOREST_TRUST_COLLISION_XREF: + ndr_print_lsa_ForestTrustCollisionXrefFlags(ndr, "flags", r->flags); + break; + + default: + ndr_print_uint32(ndr, "flags", r->flags); + break; + + } +} + +static enum ndr_err_code ndr_push_lsa_ForestTrustCollisionRecord(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustCollisionRecord *r) +{ + if (ndr_flags & NDR_SCALARS) { + NDR_CHECK(ndr_push_align(ndr, 5)); + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->index)); + NDR_CHECK(ndr_push_lsa_ForestTrustCollisionRecordType(ndr, NDR_SCALARS, r->type)); + NDR_CHECK(ndr_push_set_switch_value(ndr, &r->flags, r->type)); + NDR_CHECK(ndr_push_lsa_ForestTrustCollisionFlags(ndr, NDR_SCALARS, &r->flags)); + NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name)); + NDR_CHECK(ndr_push_trailer_align(ndr, 5)); + } + if (ndr_flags & NDR_BUFFERS) { + NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name)); + } + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionRecord(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustCollisionRecord *r) +{ + if (ndr_flags & NDR_SCALARS) { + NDR_CHECK(ndr_pull_align(ndr, 5)); + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->index)); + NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionRecordType(ndr, NDR_SCALARS, &r->type)); + NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->flags, r->type)); + NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionFlags(ndr, NDR_SCALARS, &r->flags)); + NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name)); + NDR_CHECK(ndr_pull_trailer_align(ndr, 5)); + } + if (ndr_flags & NDR_BUFFERS) { + NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name)); + } + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_lsa_ForestTrustCollisionRecord(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustCollisionRecord *r) +{ + ndr_print_struct(ndr, name, "lsa_ForestTrustCollisionRecord"); + ndr->depth++; + ndr_print_uint32(ndr, "index", r->index); + ndr_print_lsa_ForestTrustCollisionRecordType(ndr, "type", r->type); + ndr_print_set_switch_value(ndr, &r->flags, r->type); + ndr_print_lsa_ForestTrustCollisionFlags(ndr, "flags", &r->flags); + ndr_print_lsa_String(ndr, "name", &r->name); + ndr->depth--; +} + +static enum ndr_err_code ndr_push_lsa_ForestTrustCollisionInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustCollisionInfo *r) +{ + uint32_t cntr_entries_1; + if (ndr_flags & NDR_SCALARS) { + NDR_CHECK(ndr_push_align(ndr, 5)); + NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count)); + NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries)); + NDR_CHECK(ndr_push_trailer_align(ndr, 5)); + } + if (ndr_flags & NDR_BUFFERS) { + if (r->entries) { + NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count)); + for (cntr_entries_1 = 0; cntr_entries_1 < r->count; cntr_entries_1++) { + NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries[cntr_entries_1])); + } + for (cntr_entries_1 = 0; cntr_entries_1 < r->count; cntr_entries_1++) { + if (r->entries[cntr_entries_1]) { + NDR_CHECK(ndr_push_lsa_ForestTrustCollisionRecord(ndr, NDR_SCALARS|NDR_BUFFERS, r->entries[cntr_entries_1])); + } + } + } + } + return NDR_ERR_SUCCESS; +} + +static enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustCollisionInfo *r) +{ + uint32_t _ptr_entries; + uint32_t cntr_entries_1; + TALLOC_CTX *_mem_save_entries_0; + TALLOC_CTX *_mem_save_entries_1; + TALLOC_CTX *_mem_save_entries_2; + if (ndr_flags & NDR_SCALARS) { + NDR_CHECK(ndr_pull_align(ndr, 5)); + NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count)); + NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries)); + if (_ptr_entries) { + NDR_PULL_ALLOC(ndr, r->entries); + } else { + r->entries = NULL; + } + NDR_CHECK(ndr_pull_trailer_align(ndr, 5)); + } + if (ndr_flags & NDR_BUFFERS) { + if (r->entries) { + _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0); + NDR_CHECK(ndr_pull_array_size(ndr, &r->entries)); + NDR_PULL_ALLOC_N(ndr, r->entries, ndr_get_array_size(ndr, &r->entries)); + _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0); + for (cntr_entries_1 = 0; cntr_entries_1 < r->count; cntr_entries_1++) { + NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries)); + if (_ptr_entries) { + NDR_PULL_ALLOC(ndr, r->entries[cntr_entries_1]); + } else { + r->entries[cntr_entries_1] = NULL; + } + } + for (cntr_entries_1 = 0; cntr_entries_1 < r->count; cntr_entries_1++) { + if (r->entries[cntr_entries_1]) { + _mem_save_entries_2 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, r->entries[cntr_entries_1], 0); + NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionRecord(ndr, NDR_SCALARS|NDR_BUFFERS, r->entries[cntr_entries_1])); + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_2, 0); + } + } + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0); + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0); + } + if (r->entries) { + NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count)); + } + } + return NDR_ERR_SUCCESS; +} + +_PUBLIC_ void ndr_print_lsa_ForestTrustCollisionInfo(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustCollisionInfo *r) +{ + uint32_t cntr_entries_1; + ndr_print_struct(ndr, name, "lsa_ForestTrustCollisionInfo"); + ndr->depth++; + ndr_print_uint32(ndr, "count", r->count); + ndr_print_ptr(ndr, "entries", r->entries); + ndr->depth++; + if (r->entries) { + ndr->print(ndr, "%s: ARRAY(%d)", "entries", (int)r->count); + ndr->depth++; + for (cntr_entries_1=0;cntr_entries_1count;cntr_entries_1++) { + char *idx_1=NULL; + if (asprintf(&idx_1, "[%d]", cntr_entries_1) != -1) { + ndr_print_ptr(ndr, "entries", r->entries[cntr_entries_1]); + ndr->depth++; + if (r->entries[cntr_entries_1]) { + ndr_print_lsa_ForestTrustCollisionRecord(ndr, "entries", r->entries[cntr_entries_1]); + } + ndr->depth--; + free(idx_1); + } + } + ndr->depth--; + } + ndr->depth--; + ndr->depth--; +} + static enum ndr_err_code ndr_push_lsa_Close(struct ndr_push *ndr, int flags, const struct lsa_Close *r) { if (flags & NDR_IN) { @@ -12345,41 +12667,136 @@ _PUBLIC_ void ndr_print_lsa_lsaRQueryForestTrustInformation(struct ndr_print *nd ndr->depth--; } -static enum ndr_err_code ndr_push_lsa_LSARSETFORESTTRUSTINFORMATION(struct ndr_push *ndr, int flags, const struct lsa_LSARSETFORESTTRUSTINFORMATION *r) +_PUBLIC_ enum ndr_err_code ndr_push_lsa_lsaRSetForestTrustInformation(struct ndr_push *ndr, int flags, const struct lsa_lsaRSetForestTrustInformation *r) { if (flags & NDR_IN) { + if (r->in.handle == NULL) { + return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer"); + } + NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle)); + if (r->in.trusted_domain_name == NULL) { + return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer"); + } + NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain_name)); + NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.highest_record_type)); + if (r->in.forest_trust_info == NULL) { + return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer"); + } + NDR_CHECK(ndr_push_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.forest_trust_info)); + NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.check_only)); } if (flags & NDR_OUT) { + if (r->out.collision_info == NULL) { + return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer"); + } + NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.collision_info)); + if (*r->out.collision_info) { + NDR_CHECK(ndr_push_lsa_ForestTrustCollisionInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.collision_info)); + } NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result)); } return NDR_ERR_SUCCESS; } -static enum ndr_err_code ndr_pull_lsa_LSARSETFORESTTRUSTINFORMATION(struct ndr_pull *ndr, int flags, struct lsa_LSARSETFORESTTRUSTINFORMATION *r) +_PUBLIC_ enum ndr_err_code ndr_pull_lsa_lsaRSetForestTrustInformation(struct ndr_pull *ndr, int flags, struct lsa_lsaRSetForestTrustInformation *r) { + uint32_t _ptr_collision_info; + TALLOC_CTX *_mem_save_handle_0; + TALLOC_CTX *_mem_save_trusted_domain_name_0; + TALLOC_CTX *_mem_save_forest_trust_info_0; + TALLOC_CTX *_mem_save_collision_info_0; + TALLOC_CTX *_mem_save_collision_info_1; if (flags & NDR_IN) { + ZERO_STRUCT(r->out); + + if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) { + NDR_PULL_ALLOC(ndr, r->in.handle); + } + _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC); + NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle)); + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC); + if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) { + NDR_PULL_ALLOC(ndr, r->in.trusted_domain_name); + } + _mem_save_trusted_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, r->in.trusted_domain_name, LIBNDR_FLAG_REF_ALLOC); + NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain_name)); + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trusted_domain_name_0, LIBNDR_FLAG_REF_ALLOC); + NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.highest_record_type)); + if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) { + NDR_PULL_ALLOC(ndr, r->in.forest_trust_info); + } + _mem_save_forest_trust_info_0 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, r->in.forest_trust_info, LIBNDR_FLAG_REF_ALLOC); + NDR_CHECK(ndr_pull_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.forest_trust_info)); + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_trust_info_0, LIBNDR_FLAG_REF_ALLOC); + NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.check_only)); + NDR_PULL_ALLOC(ndr, r->out.collision_info); + ZERO_STRUCTP(r->out.collision_info); } if (flags & NDR_OUT) { + if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) { + NDR_PULL_ALLOC(ndr, r->out.collision_info); + } + _mem_save_collision_info_0 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, r->out.collision_info, LIBNDR_FLAG_REF_ALLOC); + NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_collision_info)); + if (_ptr_collision_info) { + NDR_PULL_ALLOC(ndr, *r->out.collision_info); + } else { + *r->out.collision_info = NULL; + } + if (*r->out.collision_info) { + _mem_save_collision_info_1 = NDR_PULL_GET_MEM_CTX(ndr); + NDR_PULL_SET_MEM_CTX(ndr, *r->out.collision_info, 0); + NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.collision_info)); + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_collision_info_1, 0); + } + NDR_PULL_SET_MEM_CTX(ndr, _mem_save_collision_info_0, LIBNDR_FLAG_REF_ALLOC); NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result)); } return NDR_ERR_SUCCESS; } -_PUBLIC_ void ndr_print_lsa_LSARSETFORESTTRUSTINFORMATION(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARSETFORESTTRUSTINFORMATION *r) +_PUBLIC_ void ndr_print_lsa_lsaRSetForestTrustInformation(struct ndr_print *ndr, const char *name, int flags, const struct lsa_lsaRSetForestTrustInformation *r) { - ndr_print_struct(ndr, name, "lsa_LSARSETFORESTTRUSTINFORMATION"); + ndr_print_struct(ndr, name, "lsa_lsaRSetForestTrustInformation"); ndr->depth++; if (flags & NDR_SET_VALUES) { ndr->flags |= LIBNDR_PRINT_SET_VALUES; } if (flags & NDR_IN) { - ndr_print_struct(ndr, "in", "lsa_LSARSETFORESTTRUSTINFORMATION"); + ndr_print_struct(ndr, "in", "lsa_lsaRSetForestTrustInformation"); ndr->depth++; + ndr_print_ptr(ndr, "handle", r->in.handle); + ndr->depth++; + ndr_print_policy_handle(ndr, "handle", r->in.handle); + ndr->depth--; + ndr_print_ptr(ndr, "trusted_domain_name", r->in.trusted_domain_name); + ndr->depth++; + ndr_print_lsa_StringLarge(ndr, "trusted_domain_name", r->in.trusted_domain_name); + ndr->depth--; + ndr_print_uint16(ndr, "highest_record_type", r->in.highest_record_type); + ndr_print_ptr(ndr, "forest_trust_info", r->in.forest_trust_info); + ndr->depth++; + ndr_print_lsa_ForestTrustInformation(ndr, "forest_trust_info", r->in.forest_trust_info); + ndr->depth--; + ndr_print_uint8(ndr, "check_only", r->in.check_only); ndr->depth--; } if (flags & NDR_OUT) { - ndr_print_struct(ndr, "out", "lsa_LSARSETFORESTTRUSTINFORMATION"); + ndr_print_struct(ndr, "out", "lsa_lsaRSetForestTrustInformation"); + ndr->depth++; + ndr_print_ptr(ndr, "collision_info", r->out.collision_info); ndr->depth++; + ndr_print_ptr(ndr, "collision_info", *r->out.collision_info); + ndr->depth++; + if (*r->out.collision_info) { + ndr_print_lsa_ForestTrustCollisionInfo(ndr, "collision_info", *r->out.collision_info); + } + ndr->depth--; + ndr->depth--; ndr_print_NTSTATUS(ndr, "result", r->out.result); ndr->depth--; } @@ -13556,11 +13973,11 @@ static const struct ndr_interface_call lsarpc_calls[] = { false, }, { - "lsa_LSARSETFORESTTRUSTINFORMATION", - sizeof(struct lsa_LSARSETFORESTTRUSTINFORMATION), - (ndr_push_flags_fn_t) ndr_push_lsa_LSARSETFORESTTRUSTINFORMATION, - (ndr_pull_flags_fn_t) ndr_pull_lsa_LSARSETFORESTTRUSTINFORMATION, - (ndr_print_function_t) ndr_print_lsa_LSARSETFORESTTRUSTINFORMATION, + "lsa_lsaRSetForestTrustInformation", + sizeof(struct lsa_lsaRSetForestTrustInformation), + (ndr_push_flags_fn_t) ndr_push_lsa_lsaRSetForestTrustInformation, + (ndr_pull_flags_fn_t) ndr_pull_lsa_lsaRSetForestTrustInformation, + (ndr_print_function_t) ndr_print_lsa_lsaRSetForestTrustInformation, false, }, { diff --git a/librpc/gen_ndr/ndr_lsa.h b/librpc/gen_ndr/ndr_lsa.h index cb7628a1fb..5ff7451cca 100644 --- a/librpc/gen_ndr/ndr_lsa.h +++ b/librpc/gen_ndr/ndr_lsa.h @@ -292,6 +292,12 @@ void ndr_print_lsa_ForestTrustRecord(struct ndr_print *ndr, const char *name, co enum ndr_err_code ndr_push_lsa_ForestTrustInformation(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustInformation *r); enum ndr_err_code ndr_pull_lsa_ForestTrustInformation(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustInformation *r); void ndr_print_lsa_ForestTrustInformation(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustInformation *r); +void ndr_print_lsa_ForestTrustCollisionRecordType(struct ndr_print *ndr, const char *name, enum lsa_ForestTrustCollisionRecordType r); +void ndr_print_lsa_ForestTrustCollisionTDOFlags(struct ndr_print *ndr, const char *name, uint32_t r); +void ndr_print_lsa_ForestTrustCollisionXrefFlags(struct ndr_print *ndr, const char *name, uint32_t r); +void ndr_print_lsa_ForestTrustCollisionFlags(struct ndr_print *ndr, const char *name, const union lsa_ForestTrustCollisionFlags *r); +void ndr_print_lsa_ForestTrustCollisionRecord(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustCollisionRecord *r); +void ndr_print_lsa_ForestTrustCollisionInfo(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustCollisionInfo *r); void ndr_print_lsa_Close(struct ndr_print *ndr, const char *name, int flags, const struct lsa_Close *r); enum ndr_err_code ndr_push_lsa_Delete(struct ndr_push *ndr, int flags, const struct lsa_Delete *r); enum ndr_err_code ndr_pull_lsa_Delete(struct ndr_pull *ndr, int flags, struct lsa_Delete *r); @@ -398,7 +404,9 @@ void ndr_print_lsa_LSARREGISTERAUDITEVENT(struct ndr_print *ndr, const char *nam void ndr_print_lsa_LSARGENAUDITEVENT(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARGENAUDITEVENT *r); void ndr_print_lsa_LSARUNREGISTERAUDITEVENT(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARUNREGISTERAUDITEVENT *r); void ndr_print_lsa_lsaRQueryForestTrustInformation(struct ndr_print *ndr, const char *name, int flags, const struct lsa_lsaRQueryForestTrustInformation *r); -void ndr_print_lsa_LSARSETFORESTTRUSTINFORMATION(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARSETFORESTTRUSTINFORMATION *r); +enum ndr_err_code ndr_push_lsa_lsaRSetForestTrustInformation(struct ndr_push *ndr, int flags, const struct lsa_lsaRSetForestTrustInformation *r); +enum ndr_err_code ndr_pull_lsa_lsaRSetForestTrustInformation(struct ndr_pull *ndr, int flags, struct lsa_lsaRSetForestTrustInformation *r); +void ndr_print_lsa_lsaRSetForestTrustInformation(struct ndr_print *ndr, const char *name, int flags, const struct lsa_lsaRSetForestTrustInformation *r); void ndr_print_lsa_CREDRRENAME(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRRENAME *r); enum ndr_err_code ndr_push_lsa_LookupSids3(struct ndr_push *ndr, int flags, const struct lsa_LookupSids3 *r); enum ndr_err_code ndr_pull_lsa_LookupSids3(struct ndr_pull *ndr, int flags, struct lsa_LookupSids3 *r); diff --git a/librpc/gen_ndr/srv_lsa.c b/librpc/gen_ndr/srv_lsa.c index f1b4a06d0d..a70de2a2c6 100644 --- a/librpc/gen_ndr/srv_lsa.c +++ b/librpc/gen_ndr/srv_lsa.c @@ -5689,18 +5689,18 @@ static bool api_lsa_lsaRQueryForestTrustInformation(pipes_struct *p) return true; } -static bool api_lsa_LSARSETFORESTTRUSTINFORMATION(pipes_struct *p) +static bool api_lsa_lsaRSetForestTrustInformation(pipes_struct *p) { const struct ndr_interface_call *call; struct ndr_pull *pull; struct ndr_push *push; enum ndr_err_code ndr_err; DATA_BLOB blob; - struct lsa_LSARSETFORESTTRUSTINFORMATION *r; + struct lsa_lsaRSetForestTrustInformation *r; call = &ndr_table_lsarpc.calls[NDR_LSA_LSARSETFORESTTRUSTINFORMATION]; - r = talloc(talloc_tos(), struct lsa_LSARSETFORESTTRUSTINFORMATION); + r = talloc(talloc_tos(), struct lsa_lsaRSetForestTrustInformation); if (r == NULL) { return false; } @@ -5724,10 +5724,17 @@ static bool api_lsa_LSARSETFORESTTRUSTINFORMATION(pipes_struct *p) } if (DEBUGLEVEL >= 10) { - NDR_PRINT_IN_DEBUG(lsa_LSARSETFORESTTRUSTINFORMATION, r); + NDR_PRINT_IN_DEBUG(lsa_lsaRSetForestTrustInformation, r); } - r->out.result = _lsa_LSARSETFORESTTRUSTINFORMATION(p, r); + ZERO_STRUCT(r->out); + r->out.collision_info = talloc_zero(r, struct lsa_ForestTrustCollisionInfo *); + if (r->out.collision_info == NULL) { + talloc_free(r); + return false; + } + + r->out.result = _lsa_lsaRSetForestTrustInformation(p, r); if (p->rng_fault_state) { talloc_free(r); @@ -5736,7 +5743,7 @@ static bool api_lsa_LSARSETFORESTTRUSTINFORMATION(pipes_struct *p) } if (DEBUGLEVEL >= 10) { - NDR_PRINT_OUT_DEBUG(lsa_LSARSETFORESTTRUSTINFORMATION, r); + NDR_PRINT_OUT_DEBUG(lsa_lsaRSetForestTrustInformation, r); } push = ndr_push_init_ctx(r, NULL); @@ -6369,7 +6376,7 @@ static struct api_struct api_lsarpc_cmds[] = {"LSA_LSARGENAUDITEVENT", NDR_LSA_LSARGENAUDITEVENT, api_lsa_LSARGENAUDITEVENT}, {"LSA_LSARUNREGISTERAUDITEVENT", NDR_LSA_LSARUNREGISTERAUDITEVENT, api_lsa_LSARUNREGISTERAUDITEVENT}, {"LSA_LSARQUERYFORESTTRUSTINFORMATION", NDR_LSA_LSARQUERYFORESTTRUSTINFORMATION, api_lsa_lsaRQueryForestTrustInformation}, - {"LSA_LSARSETFORESTTRUSTINFORMATION", NDR_LSA_LSARSETFORESTTRUSTINFORMATION, api_lsa_LSARSETFORESTTRUSTINFORMATION}, + {"LSA_LSARSETFORESTTRUSTINFORMATION", NDR_LSA_LSARSETFORESTTRUSTINFORMATION, api_lsa_lsaRSetForestTrustInformation}, {"LSA_CREDRRENAME", NDR_LSA_CREDRRENAME, api_lsa_CREDRRENAME}, {"LSA_LOOKUPSIDS3", NDR_LSA_LOOKUPSIDS3, api_lsa_LookupSids3}, {"LSA_LOOKUPNAMES4", NDR_LSA_LOOKUPNAMES4, api_lsa_LookupNames4}, @@ -7083,8 +7090,14 @@ NTSTATUS rpc_lsarpc_dispatch(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, c } case NDR_LSA_LSARSETFORESTTRUSTINFORMATION: { - struct lsa_LSARSETFORESTTRUSTINFORMATION *r = (struct lsa_LSARSETFORESTTRUSTINFORMATION *)_r; - r->out.result = _lsa_LSARSETFORESTTRUSTINFORMATION(cli->pipes_struct, r); + struct lsa_lsaRSetForestTrustInformation *r = (struct lsa_lsaRSetForestTrustInformation *)_r; + ZERO_STRUCT(r->out); + r->out.collision_info = talloc_zero(mem_ctx, struct lsa_ForestTrustCollisionInfo *); + if (r->out.collision_info == NULL) { + return NT_STATUS_NO_MEMORY; + } + + r->out.result = _lsa_lsaRSetForestTrustInformation(cli->pipes_struct, r); return NT_STATUS_OK; } diff --git a/librpc/gen_ndr/srv_lsa.h b/librpc/gen_ndr/srv_lsa.h index 3e9eb1b42f..080710902c 100644 --- a/librpc/gen_ndr/srv_lsa.h +++ b/librpc/gen_ndr/srv_lsa.h @@ -75,7 +75,7 @@ NTSTATUS _lsa_LSARREGISTERAUDITEVENT(pipes_struct *p, struct lsa_LSARREGISTERAUD NTSTATUS _lsa_LSARGENAUDITEVENT(pipes_struct *p, struct lsa_LSARGENAUDITEVENT *r); NTSTATUS _lsa_LSARUNREGISTERAUDITEVENT(pipes_struct *p, struct lsa_LSARUNREGISTERAUDITEVENT *r); NTSTATUS _lsa_lsaRQueryForestTrustInformation(pipes_struct *p, struct lsa_lsaRQueryForestTrustInformation *r); -NTSTATUS _lsa_LSARSETFORESTTRUSTINFORMATION(pipes_struct *p, struct lsa_LSARSETFORESTTRUSTINFORMATION *r); +NTSTATUS _lsa_lsaRSetForestTrustInformation(pipes_struct *p, struct lsa_lsaRSetForestTrustInformation *r); NTSTATUS _lsa_CREDRRENAME(pipes_struct *p, struct lsa_CREDRRENAME *r); NTSTATUS _lsa_LookupSids3(pipes_struct *p, struct lsa_LookupSids3 *r); NTSTATUS _lsa_LookupNames4(pipes_struct *p, struct lsa_LookupNames4 *r); @@ -159,7 +159,7 @@ NTSTATUS _lsa_LSARREGISTERAUDITEVENT(pipes_struct *p, struct lsa_LSARREGISTERAUD NTSTATUS _lsa_LSARGENAUDITEVENT(pipes_struct *p, struct lsa_LSARGENAUDITEVENT *r); NTSTATUS _lsa_LSARUNREGISTERAUDITEVENT(pipes_struct *p, struct lsa_LSARUNREGISTERAUDITEVENT *r); NTSTATUS _lsa_lsaRQueryForestTrustInformation(pipes_struct *p, struct lsa_lsaRQueryForestTrustInformation *r); -NTSTATUS _lsa_LSARSETFORESTTRUSTINFORMATION(pipes_struct *p, struct lsa_LSARSETFORESTTRUSTINFORMATION *r); +NTSTATUS _lsa_lsaRSetForestTrustInformation(pipes_struct *p, struct lsa_lsaRSetForestTrustInformation *r); NTSTATUS _lsa_CREDRRENAME(pipes_struct *p, struct lsa_CREDRRENAME *r); NTSTATUS _lsa_LookupSids3(pipes_struct *p, struct lsa_LookupSids3 *r); NTSTATUS _lsa_LookupNames4(pipes_struct *p, struct lsa_LookupNames4 *r); -- cgit