Move SMB2 constants to a separate file
[Samba/fernandojvsilva.git] / librpc / gen_ndr / ndr_dssetup.c
blob7ce80ddab2a870190b0d317fbfd332dc5db6d7f0
1 /* parser auto-generated by pidl */
3 #include "includes.h"
4 #include "../librpc/gen_ndr/ndr_dssetup.h"
6 #include "librpc/gen_ndr/ndr_misc.h"
7 static enum ndr_err_code ndr_push_dssetup_DsRole(struct ndr_push *ndr, int ndr_flags, enum dssetup_DsRole r)
9 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r));
10 return NDR_ERR_SUCCESS;
13 static enum ndr_err_code ndr_pull_dssetup_DsRole(struct ndr_pull *ndr, int ndr_flags, enum dssetup_DsRole *r)
15 uint16_t v;
16 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &v));
17 *r = v;
18 return NDR_ERR_SUCCESS;
21 _PUBLIC_ void ndr_print_dssetup_DsRole(struct ndr_print *ndr, const char *name, enum dssetup_DsRole r)
23 const char *val = NULL;
25 switch (r) {
26 case DS_ROLE_STANDALONE_WORKSTATION: val = "DS_ROLE_STANDALONE_WORKSTATION"; break;
27 case DS_ROLE_MEMBER_WORKSTATION: val = "DS_ROLE_MEMBER_WORKSTATION"; break;
28 case DS_ROLE_STANDALONE_SERVER: val = "DS_ROLE_STANDALONE_SERVER"; break;
29 case DS_ROLE_MEMBER_SERVER: val = "DS_ROLE_MEMBER_SERVER"; break;
30 case DS_ROLE_BACKUP_DC: val = "DS_ROLE_BACKUP_DC"; break;
31 case DS_ROLE_PRIMARY_DC: val = "DS_ROLE_PRIMARY_DC"; break;
33 ndr_print_enum(ndr, name, "ENUM", val, r);
36 static enum ndr_err_code ndr_push_dssetup_DsRoleFlags(struct ndr_push *ndr, int ndr_flags, uint32_t r)
38 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
39 return NDR_ERR_SUCCESS;
42 static enum ndr_err_code ndr_pull_dssetup_DsRoleFlags(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
44 uint32_t v;
45 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
46 *r = v;
47 return NDR_ERR_SUCCESS;
50 _PUBLIC_ void ndr_print_dssetup_DsRoleFlags(struct ndr_print *ndr, const char *name, uint32_t r)
52 ndr_print_uint32(ndr, name, r);
53 ndr->depth++;
54 ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DS_ROLE_PRIMARY_DS_RUNNING", DS_ROLE_PRIMARY_DS_RUNNING, r);
55 ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DS_ROLE_PRIMARY_DS_MIXED_MODE", DS_ROLE_PRIMARY_DS_MIXED_MODE, r);
56 ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DS_ROLE_UPGRADE_IN_PROGRESS", DS_ROLE_UPGRADE_IN_PROGRESS, r);
57 ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DS_ROLE_PRIMARY_DOMAIN_GUID_PRESENT", DS_ROLE_PRIMARY_DOMAIN_GUID_PRESENT, r);
58 ndr->depth--;
61 static enum ndr_err_code ndr_push_dssetup_DsRolePrimaryDomInfoBasic(struct ndr_push *ndr, int ndr_flags, const struct dssetup_DsRolePrimaryDomInfoBasic *r)
63 if (ndr_flags & NDR_SCALARS) {
64 NDR_CHECK(ndr_push_align(ndr, 4));
65 NDR_CHECK(ndr_push_dssetup_DsRole(ndr, NDR_SCALARS, r->role));
66 NDR_CHECK(ndr_push_dssetup_DsRoleFlags(ndr, NDR_SCALARS, r->flags));
67 NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain));
68 NDR_CHECK(ndr_push_unique_ptr(ndr, r->dns_domain));
69 NDR_CHECK(ndr_push_unique_ptr(ndr, r->forest));
70 NDR_CHECK(ndr_push_GUID(ndr, NDR_SCALARS, &r->domain_guid));
72 if (ndr_flags & NDR_BUFFERS) {
73 if (r->domain) {
74 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
75 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
76 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->domain, CH_UTF16)));
77 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain, ndr_charset_length(r->domain, CH_UTF16), sizeof(uint16_t), CH_UTF16));
79 if (r->dns_domain) {
80 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->dns_domain, CH_UTF16)));
81 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
82 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->dns_domain, CH_UTF16)));
83 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->dns_domain, ndr_charset_length(r->dns_domain, CH_UTF16), sizeof(uint16_t), CH_UTF16));
85 if (r->forest) {
86 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->forest, CH_UTF16)));
87 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
88 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_charset_length(r->forest, CH_UTF16)));
89 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->forest, ndr_charset_length(r->forest, CH_UTF16), sizeof(uint16_t), CH_UTF16));
92 return NDR_ERR_SUCCESS;
95 static enum ndr_err_code ndr_pull_dssetup_DsRolePrimaryDomInfoBasic(struct ndr_pull *ndr, int ndr_flags, struct dssetup_DsRolePrimaryDomInfoBasic *r)
97 uint32_t _ptr_domain;
98 TALLOC_CTX *_mem_save_domain_0;
99 uint32_t _ptr_dns_domain;
100 TALLOC_CTX *_mem_save_dns_domain_0;
101 uint32_t _ptr_forest;
102 TALLOC_CTX *_mem_save_forest_0;
103 if (ndr_flags & NDR_SCALARS) {
104 NDR_CHECK(ndr_pull_align(ndr, 4));
105 NDR_CHECK(ndr_pull_dssetup_DsRole(ndr, NDR_SCALARS, &r->role));
106 NDR_CHECK(ndr_pull_dssetup_DsRoleFlags(ndr, NDR_SCALARS, &r->flags));
107 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain));
108 if (_ptr_domain) {
109 NDR_PULL_ALLOC(ndr, r->domain);
110 } else {
111 r->domain = NULL;
113 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_dns_domain));
114 if (_ptr_dns_domain) {
115 NDR_PULL_ALLOC(ndr, r->dns_domain);
116 } else {
117 r->dns_domain = NULL;
119 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_forest));
120 if (_ptr_forest) {
121 NDR_PULL_ALLOC(ndr, r->forest);
122 } else {
123 r->forest = NULL;
125 NDR_CHECK(ndr_pull_GUID(ndr, NDR_SCALARS, &r->domain_guid));
127 if (ndr_flags & NDR_BUFFERS) {
128 if (r->domain) {
129 _mem_save_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
130 NDR_PULL_SET_MEM_CTX(ndr, r->domain, 0);
131 NDR_CHECK(ndr_pull_array_size(ndr, &r->domain));
132 NDR_CHECK(ndr_pull_array_length(ndr, &r->domain));
133 if (ndr_get_array_length(ndr, &r->domain) > ndr_get_array_size(ndr, &r->domain)) {
134 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->domain), ndr_get_array_length(ndr, &r->domain));
136 NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->domain), sizeof(uint16_t)));
137 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain, ndr_get_array_length(ndr, &r->domain), sizeof(uint16_t), CH_UTF16));
138 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_0, 0);
140 if (r->dns_domain) {
141 _mem_save_dns_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
142 NDR_PULL_SET_MEM_CTX(ndr, r->dns_domain, 0);
143 NDR_CHECK(ndr_pull_array_size(ndr, &r->dns_domain));
144 NDR_CHECK(ndr_pull_array_length(ndr, &r->dns_domain));
145 if (ndr_get_array_length(ndr, &r->dns_domain) > ndr_get_array_size(ndr, &r->dns_domain)) {
146 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->dns_domain), ndr_get_array_length(ndr, &r->dns_domain));
148 NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->dns_domain), sizeof(uint16_t)));
149 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->dns_domain, ndr_get_array_length(ndr, &r->dns_domain), sizeof(uint16_t), CH_UTF16));
150 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dns_domain_0, 0);
152 if (r->forest) {
153 _mem_save_forest_0 = NDR_PULL_GET_MEM_CTX(ndr);
154 NDR_PULL_SET_MEM_CTX(ndr, r->forest, 0);
155 NDR_CHECK(ndr_pull_array_size(ndr, &r->forest));
156 NDR_CHECK(ndr_pull_array_length(ndr, &r->forest));
157 if (ndr_get_array_length(ndr, &r->forest) > ndr_get_array_size(ndr, &r->forest)) {
158 return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", ndr_get_array_size(ndr, &r->forest), ndr_get_array_length(ndr, &r->forest));
160 NDR_CHECK(ndr_check_string_terminator(ndr, ndr_get_array_length(ndr, &r->forest), sizeof(uint16_t)));
161 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->forest, ndr_get_array_length(ndr, &r->forest), sizeof(uint16_t), CH_UTF16));
162 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_0, 0);
165 return NDR_ERR_SUCCESS;
168 _PUBLIC_ void ndr_print_dssetup_DsRolePrimaryDomInfoBasic(struct ndr_print *ndr, const char *name, const struct dssetup_DsRolePrimaryDomInfoBasic *r)
170 ndr_print_struct(ndr, name, "dssetup_DsRolePrimaryDomInfoBasic");
171 ndr->depth++;
172 ndr_print_dssetup_DsRole(ndr, "role", r->role);
173 ndr_print_dssetup_DsRoleFlags(ndr, "flags", r->flags);
174 ndr_print_ptr(ndr, "domain", r->domain);
175 ndr->depth++;
176 if (r->domain) {
177 ndr_print_string(ndr, "domain", r->domain);
179 ndr->depth--;
180 ndr_print_ptr(ndr, "dns_domain", r->dns_domain);
181 ndr->depth++;
182 if (r->dns_domain) {
183 ndr_print_string(ndr, "dns_domain", r->dns_domain);
185 ndr->depth--;
186 ndr_print_ptr(ndr, "forest", r->forest);
187 ndr->depth++;
188 if (r->forest) {
189 ndr_print_string(ndr, "forest", r->forest);
191 ndr->depth--;
192 ndr_print_GUID(ndr, "domain_guid", &r->domain_guid);
193 ndr->depth--;
196 static enum ndr_err_code ndr_push_dssetup_DsUpgrade(struct ndr_push *ndr, int ndr_flags, enum dssetup_DsUpgrade r)
198 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
199 return NDR_ERR_SUCCESS;
202 static enum ndr_err_code ndr_pull_dssetup_DsUpgrade(struct ndr_pull *ndr, int ndr_flags, enum dssetup_DsUpgrade *r)
204 uint32_t v;
205 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
206 *r = v;
207 return NDR_ERR_SUCCESS;
210 _PUBLIC_ void ndr_print_dssetup_DsUpgrade(struct ndr_print *ndr, const char *name, enum dssetup_DsUpgrade r)
212 const char *val = NULL;
214 switch (r) {
215 case DS_ROLE_NOT_UPGRADING: val = "DS_ROLE_NOT_UPGRADING"; break;
216 case DS_ROLE_UPGRADING: val = "DS_ROLE_UPGRADING"; break;
218 ndr_print_enum(ndr, name, "ENUM", val, r);
221 static enum ndr_err_code ndr_push_dssetup_DsPrevious(struct ndr_push *ndr, int ndr_flags, enum dssetup_DsPrevious r)
223 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r));
224 return NDR_ERR_SUCCESS;
227 static enum ndr_err_code ndr_pull_dssetup_DsPrevious(struct ndr_pull *ndr, int ndr_flags, enum dssetup_DsPrevious *r)
229 uint16_t v;
230 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &v));
231 *r = v;
232 return NDR_ERR_SUCCESS;
235 _PUBLIC_ void ndr_print_dssetup_DsPrevious(struct ndr_print *ndr, const char *name, enum dssetup_DsPrevious r)
237 const char *val = NULL;
239 switch (r) {
240 case DS_ROLE_PREVIOUS_UNKNOWN: val = "DS_ROLE_PREVIOUS_UNKNOWN"; break;
241 case DS_ROLE_PREVIOUS_PRIMARY: val = "DS_ROLE_PREVIOUS_PRIMARY"; break;
242 case DS_ROLE_PREVIOUS_BACKUP: val = "DS_ROLE_PREVIOUS_BACKUP"; break;
244 ndr_print_enum(ndr, name, "ENUM", val, r);
247 static enum ndr_err_code ndr_push_dssetup_DsRoleUpgradeStatus(struct ndr_push *ndr, int ndr_flags, const struct dssetup_DsRoleUpgradeStatus *r)
249 if (ndr_flags & NDR_SCALARS) {
250 NDR_CHECK(ndr_push_align(ndr, 4));
251 NDR_CHECK(ndr_push_dssetup_DsUpgrade(ndr, NDR_SCALARS, r->upgrading));
252 NDR_CHECK(ndr_push_dssetup_DsPrevious(ndr, NDR_SCALARS, r->previous_role));
254 if (ndr_flags & NDR_BUFFERS) {
256 return NDR_ERR_SUCCESS;
259 static enum ndr_err_code ndr_pull_dssetup_DsRoleUpgradeStatus(struct ndr_pull *ndr, int ndr_flags, struct dssetup_DsRoleUpgradeStatus *r)
261 if (ndr_flags & NDR_SCALARS) {
262 NDR_CHECK(ndr_pull_align(ndr, 4));
263 NDR_CHECK(ndr_pull_dssetup_DsUpgrade(ndr, NDR_SCALARS, &r->upgrading));
264 NDR_CHECK(ndr_pull_dssetup_DsPrevious(ndr, NDR_SCALARS, &r->previous_role));
266 if (ndr_flags & NDR_BUFFERS) {
268 return NDR_ERR_SUCCESS;
271 _PUBLIC_ void ndr_print_dssetup_DsRoleUpgradeStatus(struct ndr_print *ndr, const char *name, const struct dssetup_DsRoleUpgradeStatus *r)
273 ndr_print_struct(ndr, name, "dssetup_DsRoleUpgradeStatus");
274 ndr->depth++;
275 ndr_print_dssetup_DsUpgrade(ndr, "upgrading", r->upgrading);
276 ndr_print_dssetup_DsPrevious(ndr, "previous_role", r->previous_role);
277 ndr->depth--;
280 static enum ndr_err_code ndr_push_dssetup_DsRoleOp(struct ndr_push *ndr, int ndr_flags, enum dssetup_DsRoleOp r)
282 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r));
283 return NDR_ERR_SUCCESS;
286 static enum ndr_err_code ndr_pull_dssetup_DsRoleOp(struct ndr_pull *ndr, int ndr_flags, enum dssetup_DsRoleOp *r)
288 uint16_t v;
289 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &v));
290 *r = v;
291 return NDR_ERR_SUCCESS;
294 _PUBLIC_ void ndr_print_dssetup_DsRoleOp(struct ndr_print *ndr, const char *name, enum dssetup_DsRoleOp r)
296 const char *val = NULL;
298 switch (r) {
299 case DS_ROLE_OP_IDLE: val = "DS_ROLE_OP_IDLE"; break;
300 case DS_ROLE_OP_ACTIVE: val = "DS_ROLE_OP_ACTIVE"; break;
301 case DS_ROLE_OP_NEEDS_REBOOT: val = "DS_ROLE_OP_NEEDS_REBOOT"; break;
303 ndr_print_enum(ndr, name, "ENUM", val, r);
306 static enum ndr_err_code ndr_push_dssetup_DsRoleOpStatus(struct ndr_push *ndr, int ndr_flags, const struct dssetup_DsRoleOpStatus *r)
308 if (ndr_flags & NDR_SCALARS) {
309 NDR_CHECK(ndr_push_align(ndr, 2));
310 NDR_CHECK(ndr_push_dssetup_DsRoleOp(ndr, NDR_SCALARS, r->status));
312 if (ndr_flags & NDR_BUFFERS) {
314 return NDR_ERR_SUCCESS;
317 static enum ndr_err_code ndr_pull_dssetup_DsRoleOpStatus(struct ndr_pull *ndr, int ndr_flags, struct dssetup_DsRoleOpStatus *r)
319 if (ndr_flags & NDR_SCALARS) {
320 NDR_CHECK(ndr_pull_align(ndr, 2));
321 NDR_CHECK(ndr_pull_dssetup_DsRoleOp(ndr, NDR_SCALARS, &r->status));
323 if (ndr_flags & NDR_BUFFERS) {
325 return NDR_ERR_SUCCESS;
328 _PUBLIC_ void ndr_print_dssetup_DsRoleOpStatus(struct ndr_print *ndr, const char *name, const struct dssetup_DsRoleOpStatus *r)
330 ndr_print_struct(ndr, name, "dssetup_DsRoleOpStatus");
331 ndr->depth++;
332 ndr_print_dssetup_DsRoleOp(ndr, "status", r->status);
333 ndr->depth--;
336 static enum ndr_err_code ndr_push_dssetup_DsRoleInfoLevel(struct ndr_push *ndr, int ndr_flags, enum dssetup_DsRoleInfoLevel r)
338 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r));
339 return NDR_ERR_SUCCESS;
342 static enum ndr_err_code ndr_pull_dssetup_DsRoleInfoLevel(struct ndr_pull *ndr, int ndr_flags, enum dssetup_DsRoleInfoLevel *r)
344 uint16_t v;
345 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &v));
346 *r = v;
347 return NDR_ERR_SUCCESS;
350 _PUBLIC_ void ndr_print_dssetup_DsRoleInfoLevel(struct ndr_print *ndr, const char *name, enum dssetup_DsRoleInfoLevel r)
352 const char *val = NULL;
354 switch (r) {
355 case DS_ROLE_BASIC_INFORMATION: val = "DS_ROLE_BASIC_INFORMATION"; break;
356 case DS_ROLE_UPGRADE_STATUS: val = "DS_ROLE_UPGRADE_STATUS"; break;
357 case DS_ROLE_OP_STATUS: val = "DS_ROLE_OP_STATUS"; break;
359 ndr_print_enum(ndr, name, "ENUM", val, r);
362 static enum ndr_err_code ndr_push_dssetup_DsRoleInfo(struct ndr_push *ndr, int ndr_flags, const union dssetup_DsRoleInfo *r)
364 if (ndr_flags & NDR_SCALARS) {
365 int level = ndr_push_get_switch_value(ndr, r);
366 NDR_CHECK(ndr_push_dssetup_DsRoleInfoLevel(ndr, NDR_SCALARS, level));
367 switch (level) {
368 case DS_ROLE_BASIC_INFORMATION: {
369 NDR_CHECK(ndr_push_dssetup_DsRolePrimaryDomInfoBasic(ndr, NDR_SCALARS, &r->basic));
370 break; }
372 case DS_ROLE_UPGRADE_STATUS: {
373 NDR_CHECK(ndr_push_dssetup_DsRoleUpgradeStatus(ndr, NDR_SCALARS, &r->upgrade));
374 break; }
376 case DS_ROLE_OP_STATUS: {
377 NDR_CHECK(ndr_push_dssetup_DsRoleOpStatus(ndr, NDR_SCALARS, &r->opstatus));
378 break; }
380 default:
381 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
384 if (ndr_flags & NDR_BUFFERS) {
385 int level = ndr_push_get_switch_value(ndr, r);
386 switch (level) {
387 case DS_ROLE_BASIC_INFORMATION:
388 NDR_CHECK(ndr_push_dssetup_DsRolePrimaryDomInfoBasic(ndr, NDR_BUFFERS, &r->basic));
389 break;
391 case DS_ROLE_UPGRADE_STATUS:
392 break;
394 case DS_ROLE_OP_STATUS:
395 break;
397 default:
398 return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
401 return NDR_ERR_SUCCESS;
404 static enum ndr_err_code ndr_pull_dssetup_DsRoleInfo(struct ndr_pull *ndr, int ndr_flags, union dssetup_DsRoleInfo *r)
406 int level;
407 uint16_t _level;
408 level = ndr_pull_get_switch_value(ndr, r);
409 if (ndr_flags & NDR_SCALARS) {
410 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
411 if (_level != level) {
412 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r", _level);
414 switch (level) {
415 case DS_ROLE_BASIC_INFORMATION: {
416 NDR_CHECK(ndr_pull_dssetup_DsRolePrimaryDomInfoBasic(ndr, NDR_SCALARS, &r->basic));
417 break; }
419 case DS_ROLE_UPGRADE_STATUS: {
420 NDR_CHECK(ndr_pull_dssetup_DsRoleUpgradeStatus(ndr, NDR_SCALARS, &r->upgrade));
421 break; }
423 case DS_ROLE_OP_STATUS: {
424 NDR_CHECK(ndr_pull_dssetup_DsRoleOpStatus(ndr, NDR_SCALARS, &r->opstatus));
425 break; }
427 default:
428 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
431 if (ndr_flags & NDR_BUFFERS) {
432 switch (level) {
433 case DS_ROLE_BASIC_INFORMATION:
434 NDR_CHECK(ndr_pull_dssetup_DsRolePrimaryDomInfoBasic(ndr, NDR_BUFFERS, &r->basic));
435 break;
437 case DS_ROLE_UPGRADE_STATUS:
438 break;
440 case DS_ROLE_OP_STATUS:
441 break;
443 default:
444 return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
447 return NDR_ERR_SUCCESS;
450 _PUBLIC_ void ndr_print_dssetup_DsRoleInfo(struct ndr_print *ndr, const char *name, const union dssetup_DsRoleInfo *r)
452 int level;
453 level = ndr_print_get_switch_value(ndr, r);
454 ndr_print_union(ndr, name, level, "dssetup_DsRoleInfo");
455 switch (level) {
456 case DS_ROLE_BASIC_INFORMATION:
457 ndr_print_dssetup_DsRolePrimaryDomInfoBasic(ndr, "basic", &r->basic);
458 break;
460 case DS_ROLE_UPGRADE_STATUS:
461 ndr_print_dssetup_DsRoleUpgradeStatus(ndr, "upgrade", &r->upgrade);
462 break;
464 case DS_ROLE_OP_STATUS:
465 ndr_print_dssetup_DsRoleOpStatus(ndr, "opstatus", &r->opstatus);
466 break;
468 default:
469 ndr_print_bad_level(ndr, name, level);
473 static enum ndr_err_code ndr_push_dssetup_DsRoleGetPrimaryDomainInformation(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleGetPrimaryDomainInformation *r)
475 if (flags & NDR_IN) {
476 NDR_CHECK(ndr_push_dssetup_DsRoleInfoLevel(ndr, NDR_SCALARS, r->in.level));
478 if (flags & NDR_OUT) {
479 NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.info));
480 if (r->out.info) {
481 NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
482 NDR_CHECK(ndr_push_dssetup_DsRoleInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
484 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
486 return NDR_ERR_SUCCESS;
489 static enum ndr_err_code ndr_pull_dssetup_DsRoleGetPrimaryDomainInformation(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleGetPrimaryDomainInformation *r)
491 uint32_t _ptr_info;
492 TALLOC_CTX *_mem_save_info_0;
493 if (flags & NDR_IN) {
494 ZERO_STRUCT(r->out);
496 NDR_CHECK(ndr_pull_dssetup_DsRoleInfoLevel(ndr, NDR_SCALARS, &r->in.level));
498 if (flags & NDR_OUT) {
499 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
500 if (_ptr_info) {
501 NDR_PULL_ALLOC(ndr, r->out.info);
502 } else {
503 r->out.info = NULL;
505 if (r->out.info) {
506 _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
507 NDR_PULL_SET_MEM_CTX(ndr, r->out.info, 0);
508 NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
509 NDR_CHECK(ndr_pull_dssetup_DsRoleInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
510 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, 0);
512 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
514 return NDR_ERR_SUCCESS;
517 _PUBLIC_ void ndr_print_dssetup_DsRoleGetPrimaryDomainInformation(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleGetPrimaryDomainInformation *r)
519 ndr_print_struct(ndr, name, "dssetup_DsRoleGetPrimaryDomainInformation");
520 ndr->depth++;
521 if (flags & NDR_SET_VALUES) {
522 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
524 if (flags & NDR_IN) {
525 ndr_print_struct(ndr, "in", "dssetup_DsRoleGetPrimaryDomainInformation");
526 ndr->depth++;
527 ndr_print_dssetup_DsRoleInfoLevel(ndr, "level", r->in.level);
528 ndr->depth--;
530 if (flags & NDR_OUT) {
531 ndr_print_struct(ndr, "out", "dssetup_DsRoleGetPrimaryDomainInformation");
532 ndr->depth++;
533 ndr_print_ptr(ndr, "info", r->out.info);
534 ndr->depth++;
535 if (r->out.info) {
536 ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
537 ndr_print_dssetup_DsRoleInfo(ndr, "info", r->out.info);
539 ndr->depth--;
540 ndr_print_WERROR(ndr, "result", r->out.result);
541 ndr->depth--;
543 ndr->depth--;
546 static enum ndr_err_code ndr_push_dssetup_DsRoleDnsNameToFlatName(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleDnsNameToFlatName *r)
548 if (flags & NDR_IN) {
550 if (flags & NDR_OUT) {
551 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
553 return NDR_ERR_SUCCESS;
556 static enum ndr_err_code ndr_pull_dssetup_DsRoleDnsNameToFlatName(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleDnsNameToFlatName *r)
558 if (flags & NDR_IN) {
560 if (flags & NDR_OUT) {
561 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
563 return NDR_ERR_SUCCESS;
566 _PUBLIC_ void ndr_print_dssetup_DsRoleDnsNameToFlatName(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleDnsNameToFlatName *r)
568 ndr_print_struct(ndr, name, "dssetup_DsRoleDnsNameToFlatName");
569 ndr->depth++;
570 if (flags & NDR_SET_VALUES) {
571 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
573 if (flags & NDR_IN) {
574 ndr_print_struct(ndr, "in", "dssetup_DsRoleDnsNameToFlatName");
575 ndr->depth++;
576 ndr->depth--;
578 if (flags & NDR_OUT) {
579 ndr_print_struct(ndr, "out", "dssetup_DsRoleDnsNameToFlatName");
580 ndr->depth++;
581 ndr_print_WERROR(ndr, "result", r->out.result);
582 ndr->depth--;
584 ndr->depth--;
587 static enum ndr_err_code ndr_push_dssetup_DsRoleDcAsDc(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleDcAsDc *r)
589 if (flags & NDR_IN) {
591 if (flags & NDR_OUT) {
592 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
594 return NDR_ERR_SUCCESS;
597 static enum ndr_err_code ndr_pull_dssetup_DsRoleDcAsDc(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleDcAsDc *r)
599 if (flags & NDR_IN) {
601 if (flags & NDR_OUT) {
602 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
604 return NDR_ERR_SUCCESS;
607 _PUBLIC_ void ndr_print_dssetup_DsRoleDcAsDc(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleDcAsDc *r)
609 ndr_print_struct(ndr, name, "dssetup_DsRoleDcAsDc");
610 ndr->depth++;
611 if (flags & NDR_SET_VALUES) {
612 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
614 if (flags & NDR_IN) {
615 ndr_print_struct(ndr, "in", "dssetup_DsRoleDcAsDc");
616 ndr->depth++;
617 ndr->depth--;
619 if (flags & NDR_OUT) {
620 ndr_print_struct(ndr, "out", "dssetup_DsRoleDcAsDc");
621 ndr->depth++;
622 ndr_print_WERROR(ndr, "result", r->out.result);
623 ndr->depth--;
625 ndr->depth--;
628 static enum ndr_err_code ndr_push_dssetup_DsRoleDcAsReplica(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleDcAsReplica *r)
630 if (flags & NDR_IN) {
632 if (flags & NDR_OUT) {
633 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
635 return NDR_ERR_SUCCESS;
638 static enum ndr_err_code ndr_pull_dssetup_DsRoleDcAsReplica(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleDcAsReplica *r)
640 if (flags & NDR_IN) {
642 if (flags & NDR_OUT) {
643 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
645 return NDR_ERR_SUCCESS;
648 _PUBLIC_ void ndr_print_dssetup_DsRoleDcAsReplica(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleDcAsReplica *r)
650 ndr_print_struct(ndr, name, "dssetup_DsRoleDcAsReplica");
651 ndr->depth++;
652 if (flags & NDR_SET_VALUES) {
653 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
655 if (flags & NDR_IN) {
656 ndr_print_struct(ndr, "in", "dssetup_DsRoleDcAsReplica");
657 ndr->depth++;
658 ndr->depth--;
660 if (flags & NDR_OUT) {
661 ndr_print_struct(ndr, "out", "dssetup_DsRoleDcAsReplica");
662 ndr->depth++;
663 ndr_print_WERROR(ndr, "result", r->out.result);
664 ndr->depth--;
666 ndr->depth--;
669 static enum ndr_err_code ndr_push_dssetup_DsRoleDemoteDc(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleDemoteDc *r)
671 if (flags & NDR_IN) {
673 if (flags & NDR_OUT) {
674 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
676 return NDR_ERR_SUCCESS;
679 static enum ndr_err_code ndr_pull_dssetup_DsRoleDemoteDc(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleDemoteDc *r)
681 if (flags & NDR_IN) {
683 if (flags & NDR_OUT) {
684 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
686 return NDR_ERR_SUCCESS;
689 _PUBLIC_ void ndr_print_dssetup_DsRoleDemoteDc(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleDemoteDc *r)
691 ndr_print_struct(ndr, name, "dssetup_DsRoleDemoteDc");
692 ndr->depth++;
693 if (flags & NDR_SET_VALUES) {
694 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
696 if (flags & NDR_IN) {
697 ndr_print_struct(ndr, "in", "dssetup_DsRoleDemoteDc");
698 ndr->depth++;
699 ndr->depth--;
701 if (flags & NDR_OUT) {
702 ndr_print_struct(ndr, "out", "dssetup_DsRoleDemoteDc");
703 ndr->depth++;
704 ndr_print_WERROR(ndr, "result", r->out.result);
705 ndr->depth--;
707 ndr->depth--;
710 static enum ndr_err_code ndr_push_dssetup_DsRoleGetDcOperationProgress(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleGetDcOperationProgress *r)
712 if (flags & NDR_IN) {
714 if (flags & NDR_OUT) {
715 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
717 return NDR_ERR_SUCCESS;
720 static enum ndr_err_code ndr_pull_dssetup_DsRoleGetDcOperationProgress(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleGetDcOperationProgress *r)
722 if (flags & NDR_IN) {
724 if (flags & NDR_OUT) {
725 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
727 return NDR_ERR_SUCCESS;
730 _PUBLIC_ void ndr_print_dssetup_DsRoleGetDcOperationProgress(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleGetDcOperationProgress *r)
732 ndr_print_struct(ndr, name, "dssetup_DsRoleGetDcOperationProgress");
733 ndr->depth++;
734 if (flags & NDR_SET_VALUES) {
735 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
737 if (flags & NDR_IN) {
738 ndr_print_struct(ndr, "in", "dssetup_DsRoleGetDcOperationProgress");
739 ndr->depth++;
740 ndr->depth--;
742 if (flags & NDR_OUT) {
743 ndr_print_struct(ndr, "out", "dssetup_DsRoleGetDcOperationProgress");
744 ndr->depth++;
745 ndr_print_WERROR(ndr, "result", r->out.result);
746 ndr->depth--;
748 ndr->depth--;
751 static enum ndr_err_code ndr_push_dssetup_DsRoleGetDcOperationResults(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleGetDcOperationResults *r)
753 if (flags & NDR_IN) {
755 if (flags & NDR_OUT) {
756 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
758 return NDR_ERR_SUCCESS;
761 static enum ndr_err_code ndr_pull_dssetup_DsRoleGetDcOperationResults(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleGetDcOperationResults *r)
763 if (flags & NDR_IN) {
765 if (flags & NDR_OUT) {
766 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
768 return NDR_ERR_SUCCESS;
771 _PUBLIC_ void ndr_print_dssetup_DsRoleGetDcOperationResults(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleGetDcOperationResults *r)
773 ndr_print_struct(ndr, name, "dssetup_DsRoleGetDcOperationResults");
774 ndr->depth++;
775 if (flags & NDR_SET_VALUES) {
776 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
778 if (flags & NDR_IN) {
779 ndr_print_struct(ndr, "in", "dssetup_DsRoleGetDcOperationResults");
780 ndr->depth++;
781 ndr->depth--;
783 if (flags & NDR_OUT) {
784 ndr_print_struct(ndr, "out", "dssetup_DsRoleGetDcOperationResults");
785 ndr->depth++;
786 ndr_print_WERROR(ndr, "result", r->out.result);
787 ndr->depth--;
789 ndr->depth--;
792 static enum ndr_err_code ndr_push_dssetup_DsRoleCancel(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleCancel *r)
794 if (flags & NDR_IN) {
796 if (flags & NDR_OUT) {
797 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
799 return NDR_ERR_SUCCESS;
802 static enum ndr_err_code ndr_pull_dssetup_DsRoleCancel(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleCancel *r)
804 if (flags & NDR_IN) {
806 if (flags & NDR_OUT) {
807 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
809 return NDR_ERR_SUCCESS;
812 _PUBLIC_ void ndr_print_dssetup_DsRoleCancel(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleCancel *r)
814 ndr_print_struct(ndr, name, "dssetup_DsRoleCancel");
815 ndr->depth++;
816 if (flags & NDR_SET_VALUES) {
817 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
819 if (flags & NDR_IN) {
820 ndr_print_struct(ndr, "in", "dssetup_DsRoleCancel");
821 ndr->depth++;
822 ndr->depth--;
824 if (flags & NDR_OUT) {
825 ndr_print_struct(ndr, "out", "dssetup_DsRoleCancel");
826 ndr->depth++;
827 ndr_print_WERROR(ndr, "result", r->out.result);
828 ndr->depth--;
830 ndr->depth--;
833 static enum ndr_err_code ndr_push_dssetup_DsRoleServerSaveStateForUpgrade(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleServerSaveStateForUpgrade *r)
835 if (flags & NDR_IN) {
837 if (flags & NDR_OUT) {
838 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
840 return NDR_ERR_SUCCESS;
843 static enum ndr_err_code ndr_pull_dssetup_DsRoleServerSaveStateForUpgrade(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleServerSaveStateForUpgrade *r)
845 if (flags & NDR_IN) {
847 if (flags & NDR_OUT) {
848 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
850 return NDR_ERR_SUCCESS;
853 _PUBLIC_ void ndr_print_dssetup_DsRoleServerSaveStateForUpgrade(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleServerSaveStateForUpgrade *r)
855 ndr_print_struct(ndr, name, "dssetup_DsRoleServerSaveStateForUpgrade");
856 ndr->depth++;
857 if (flags & NDR_SET_VALUES) {
858 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
860 if (flags & NDR_IN) {
861 ndr_print_struct(ndr, "in", "dssetup_DsRoleServerSaveStateForUpgrade");
862 ndr->depth++;
863 ndr->depth--;
865 if (flags & NDR_OUT) {
866 ndr_print_struct(ndr, "out", "dssetup_DsRoleServerSaveStateForUpgrade");
867 ndr->depth++;
868 ndr_print_WERROR(ndr, "result", r->out.result);
869 ndr->depth--;
871 ndr->depth--;
874 static enum ndr_err_code ndr_push_dssetup_DsRoleUpgradeDownlevelServer(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleUpgradeDownlevelServer *r)
876 if (flags & NDR_IN) {
878 if (flags & NDR_OUT) {
879 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
881 return NDR_ERR_SUCCESS;
884 static enum ndr_err_code ndr_pull_dssetup_DsRoleUpgradeDownlevelServer(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleUpgradeDownlevelServer *r)
886 if (flags & NDR_IN) {
888 if (flags & NDR_OUT) {
889 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
891 return NDR_ERR_SUCCESS;
894 _PUBLIC_ void ndr_print_dssetup_DsRoleUpgradeDownlevelServer(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleUpgradeDownlevelServer *r)
896 ndr_print_struct(ndr, name, "dssetup_DsRoleUpgradeDownlevelServer");
897 ndr->depth++;
898 if (flags & NDR_SET_VALUES) {
899 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
901 if (flags & NDR_IN) {
902 ndr_print_struct(ndr, "in", "dssetup_DsRoleUpgradeDownlevelServer");
903 ndr->depth++;
904 ndr->depth--;
906 if (flags & NDR_OUT) {
907 ndr_print_struct(ndr, "out", "dssetup_DsRoleUpgradeDownlevelServer");
908 ndr->depth++;
909 ndr_print_WERROR(ndr, "result", r->out.result);
910 ndr->depth--;
912 ndr->depth--;
915 static enum ndr_err_code ndr_push_dssetup_DsRoleAbortDownlevelServerUpgrade(struct ndr_push *ndr, int flags, const struct dssetup_DsRoleAbortDownlevelServerUpgrade *r)
917 if (flags & NDR_IN) {
919 if (flags & NDR_OUT) {
920 NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
922 return NDR_ERR_SUCCESS;
925 static enum ndr_err_code ndr_pull_dssetup_DsRoleAbortDownlevelServerUpgrade(struct ndr_pull *ndr, int flags, struct dssetup_DsRoleAbortDownlevelServerUpgrade *r)
927 if (flags & NDR_IN) {
929 if (flags & NDR_OUT) {
930 NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
932 return NDR_ERR_SUCCESS;
935 _PUBLIC_ void ndr_print_dssetup_DsRoleAbortDownlevelServerUpgrade(struct ndr_print *ndr, const char *name, int flags, const struct dssetup_DsRoleAbortDownlevelServerUpgrade *r)
937 ndr_print_struct(ndr, name, "dssetup_DsRoleAbortDownlevelServerUpgrade");
938 ndr->depth++;
939 if (flags & NDR_SET_VALUES) {
940 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
942 if (flags & NDR_IN) {
943 ndr_print_struct(ndr, "in", "dssetup_DsRoleAbortDownlevelServerUpgrade");
944 ndr->depth++;
945 ndr->depth--;
947 if (flags & NDR_OUT) {
948 ndr_print_struct(ndr, "out", "dssetup_DsRoleAbortDownlevelServerUpgrade");
949 ndr->depth++;
950 ndr_print_WERROR(ndr, "result", r->out.result);
951 ndr->depth--;
953 ndr->depth--;
956 static const struct ndr_interface_call dssetup_calls[] = {
958 "dssetup_DsRoleGetPrimaryDomainInformation",
959 sizeof(struct dssetup_DsRoleGetPrimaryDomainInformation),
960 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleGetPrimaryDomainInformation,
961 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleGetPrimaryDomainInformation,
962 (ndr_print_function_t) ndr_print_dssetup_DsRoleGetPrimaryDomainInformation,
963 false,
966 "dssetup_DsRoleDnsNameToFlatName",
967 sizeof(struct dssetup_DsRoleDnsNameToFlatName),
968 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleDnsNameToFlatName,
969 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleDnsNameToFlatName,
970 (ndr_print_function_t) ndr_print_dssetup_DsRoleDnsNameToFlatName,
971 false,
974 "dssetup_DsRoleDcAsDc",
975 sizeof(struct dssetup_DsRoleDcAsDc),
976 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleDcAsDc,
977 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleDcAsDc,
978 (ndr_print_function_t) ndr_print_dssetup_DsRoleDcAsDc,
979 false,
982 "dssetup_DsRoleDcAsReplica",
983 sizeof(struct dssetup_DsRoleDcAsReplica),
984 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleDcAsReplica,
985 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleDcAsReplica,
986 (ndr_print_function_t) ndr_print_dssetup_DsRoleDcAsReplica,
987 false,
990 "dssetup_DsRoleDemoteDc",
991 sizeof(struct dssetup_DsRoleDemoteDc),
992 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleDemoteDc,
993 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleDemoteDc,
994 (ndr_print_function_t) ndr_print_dssetup_DsRoleDemoteDc,
995 false,
998 "dssetup_DsRoleGetDcOperationProgress",
999 sizeof(struct dssetup_DsRoleGetDcOperationProgress),
1000 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleGetDcOperationProgress,
1001 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleGetDcOperationProgress,
1002 (ndr_print_function_t) ndr_print_dssetup_DsRoleGetDcOperationProgress,
1003 false,
1006 "dssetup_DsRoleGetDcOperationResults",
1007 sizeof(struct dssetup_DsRoleGetDcOperationResults),
1008 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleGetDcOperationResults,
1009 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleGetDcOperationResults,
1010 (ndr_print_function_t) ndr_print_dssetup_DsRoleGetDcOperationResults,
1011 false,
1014 "dssetup_DsRoleCancel",
1015 sizeof(struct dssetup_DsRoleCancel),
1016 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleCancel,
1017 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleCancel,
1018 (ndr_print_function_t) ndr_print_dssetup_DsRoleCancel,
1019 false,
1022 "dssetup_DsRoleServerSaveStateForUpgrade",
1023 sizeof(struct dssetup_DsRoleServerSaveStateForUpgrade),
1024 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleServerSaveStateForUpgrade,
1025 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleServerSaveStateForUpgrade,
1026 (ndr_print_function_t) ndr_print_dssetup_DsRoleServerSaveStateForUpgrade,
1027 false,
1030 "dssetup_DsRoleUpgradeDownlevelServer",
1031 sizeof(struct dssetup_DsRoleUpgradeDownlevelServer),
1032 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleUpgradeDownlevelServer,
1033 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleUpgradeDownlevelServer,
1034 (ndr_print_function_t) ndr_print_dssetup_DsRoleUpgradeDownlevelServer,
1035 false,
1038 "dssetup_DsRoleAbortDownlevelServerUpgrade",
1039 sizeof(struct dssetup_DsRoleAbortDownlevelServerUpgrade),
1040 (ndr_push_flags_fn_t) ndr_push_dssetup_DsRoleAbortDownlevelServerUpgrade,
1041 (ndr_pull_flags_fn_t) ndr_pull_dssetup_DsRoleAbortDownlevelServerUpgrade,
1042 (ndr_print_function_t) ndr_print_dssetup_DsRoleAbortDownlevelServerUpgrade,
1043 false,
1045 { NULL, 0, NULL, NULL, NULL, false }
1048 static const char * const dssetup_endpoint_strings[] = {
1049 "ncacn_np:[\\pipe\\lsarpc]",
1050 "ncacn_np:[\\pipe\\lsass]",
1051 "ncacn_ip_tcp:",
1052 "ncalrpc:",
1055 static const struct ndr_interface_string_array dssetup_endpoints = {
1056 .count = 4,
1057 .names = dssetup_endpoint_strings
1060 static const char * const dssetup_authservice_strings[] = {
1061 "host",
1064 static const struct ndr_interface_string_array dssetup_authservices = {
1065 .count = 1,
1066 .names = dssetup_authservice_strings
1070 const struct ndr_interface_table ndr_table_dssetup = {
1071 .name = "dssetup",
1072 .syntax_id = {
1073 {0x3919286a,0xb10c,0x11d0,{0x9b,0xa8},{0x00,0xc0,0x4f,0xd9,0x2e,0xf5}},
1074 NDR_DSSETUP_VERSION
1076 .helpstring = NDR_DSSETUP_HELPSTRING,
1077 .num_calls = 11,
1078 .calls = dssetup_calls,
1079 .endpoints = &dssetup_endpoints,
1080 .authservices = &dssetup_authservices