Line data Source code
1 : /* parser auto-generated by pidl */
2 :
3 : #include "includes.h"
4 : #include "bin/default/librpc/gen_ndr/ndr_lsa.h"
5 :
6 : #include "librpc/gen_ndr/ndr_misc.h"
7 : #include "librpc/gen_ndr/ndr_security.h"
8 1133590 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_String(struct ndr_push *ndr, int ndr_flags, const struct lsa_String *r)
9 : {
10 1133590 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
11 1133590 : if (ndr_flags & NDR_SCALARS) {
12 573661 : NDR_CHECK(ndr_push_align(ndr, 5));
13 573661 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->string)));
14 573661 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->string)));
15 573661 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
16 573661 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
17 : }
18 1133590 : if (ndr_flags & NDR_BUFFERS) {
19 573661 : if (r->string) {
20 549826 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 2 * strlen_m(r->string) / 2));
21 549826 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
22 549826 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 2 * strlen_m(r->string) / 2));
23 549826 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->string, 2 * strlen_m(r->string) / 2, sizeof(uint16_t), CH_UTF16));
24 : }
25 : }
26 1133590 : return NDR_ERR_SUCCESS;
27 : }
28 :
29 1281336 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_String(struct ndr_pull *ndr, int ndr_flags, struct lsa_String *r)
30 : {
31 : uint32_t _ptr_string;
32 1281336 : uint32_t size_string_1 = 0;
33 1281336 : uint32_t length_string_1 = 0;
34 1281336 : TALLOC_CTX *_mem_save_string_0 = NULL;
35 1281336 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
36 1281336 : if (ndr_flags & NDR_SCALARS) {
37 647764 : NDR_CHECK(ndr_pull_align(ndr, 5));
38 647764 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->length));
39 647764 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
40 647764 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
41 647764 : if (_ptr_string) {
42 624132 : NDR_PULL_ALLOC(ndr, r->string);
43 : } else {
44 23632 : r->string = NULL;
45 : }
46 647764 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
47 : }
48 1281336 : if (ndr_flags & NDR_BUFFERS) {
49 647764 : if (r->string) {
50 624132 : _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
51 624132 : NDR_PULL_SET_MEM_CTX(ndr, r->string, 0);
52 624132 : NDR_CHECK(ndr_pull_array_size(ndr, &r->string));
53 624132 : NDR_CHECK(ndr_pull_array_length(ndr, &r->string));
54 624132 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->string, &size_string_1));
55 624132 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->string, &length_string_1));
56 624132 : if (length_string_1 > size_string_1) {
57 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_string_1, length_string_1);
58 : }
59 624132 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->string, length_string_1, sizeof(uint16_t), CH_UTF16));
60 624132 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, 0);
61 : }
62 647764 : if (r->string) {
63 624132 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->string, r->size / 2));
64 : }
65 647764 : if (r->string) {
66 624132 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->string, r->length / 2));
67 : }
68 : }
69 1281336 : return NDR_ERR_SUCCESS;
70 : }
71 :
72 0 : static void ndr_print_flags_lsa_String(struct ndr_print *ndr, const char *name, int unused, const struct lsa_String *r)
73 : {
74 0 : ndr_print_lsa_String(ndr, name, r);
75 0 : }
76 :
77 21570 : _PUBLIC_ void ndr_print_lsa_String(struct ndr_print *ndr, const char *name, const struct lsa_String *r)
78 : {
79 21570 : ndr_print_struct(ndr, name, "lsa_String");
80 21570 : if (r == NULL) { ndr_print_null(ndr); return; }
81 21570 : ndr->depth++;
82 21570 : ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->string):r->length);
83 21570 : ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->string):r->size);
84 21570 : ndr_print_ptr(ndr, "string", r->string);
85 21570 : ndr->depth++;
86 21570 : if (r->string) {
87 21194 : ndr_print_string(ndr, "string", r->string);
88 : }
89 21570 : ndr->depth--;
90 21570 : ndr->depth--;
91 : }
92 :
93 299281 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_StringLarge(struct ndr_push *ndr, int ndr_flags, const struct lsa_StringLarge *r)
94 : {
95 299281 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
96 299281 : if (ndr_flags & NDR_SCALARS) {
97 149819 : NDR_CHECK(ndr_push_align(ndr, 5));
98 149819 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->string)));
99 149819 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m_term(r->string)));
100 149819 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
101 149819 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
102 : }
103 299281 : if (ndr_flags & NDR_BUFFERS) {
104 149819 : if (r->string) {
105 148521 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 2 * strlen_m_term(r->string) / 2));
106 148521 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
107 148521 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 2 * strlen_m(r->string) / 2));
108 148521 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->string, 2 * strlen_m(r->string) / 2, sizeof(uint16_t), CH_UTF16));
109 : }
110 : }
111 299281 : return NDR_ERR_SUCCESS;
112 : }
113 :
114 360812 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_StringLarge(struct ndr_pull *ndr, int ndr_flags, struct lsa_StringLarge *r)
115 : {
116 : uint32_t _ptr_string;
117 360812 : uint32_t size_string_1 = 0;
118 360812 : uint32_t length_string_1 = 0;
119 360812 : TALLOC_CTX *_mem_save_string_0 = NULL;
120 360812 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
121 360812 : if (ndr_flags & NDR_SCALARS) {
122 180564 : NDR_CHECK(ndr_pull_align(ndr, 5));
123 180564 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->length));
124 180564 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
125 180564 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
126 180564 : if (_ptr_string) {
127 179479 : NDR_PULL_ALLOC(ndr, r->string);
128 : } else {
129 1085 : r->string = NULL;
130 : }
131 180564 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
132 : }
133 360812 : if (ndr_flags & NDR_BUFFERS) {
134 180564 : if (r->string) {
135 179479 : _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
136 179479 : NDR_PULL_SET_MEM_CTX(ndr, r->string, 0);
137 179479 : NDR_CHECK(ndr_pull_array_size(ndr, &r->string));
138 179479 : NDR_CHECK(ndr_pull_array_length(ndr, &r->string));
139 179479 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->string, &size_string_1));
140 179479 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->string, &length_string_1));
141 179479 : if (length_string_1 > size_string_1) {
142 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_string_1, length_string_1);
143 : }
144 179479 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->string, length_string_1, sizeof(uint16_t), CH_UTF16));
145 179479 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, 0);
146 : }
147 180564 : if (r->string) {
148 179479 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->string, r->size / 2));
149 : }
150 180564 : if (r->string) {
151 179479 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->string, r->length / 2));
152 : }
153 : }
154 360812 : return NDR_ERR_SUCCESS;
155 : }
156 :
157 0 : static void ndr_print_flags_lsa_StringLarge(struct ndr_print *ndr, const char *name, int unused, const struct lsa_StringLarge *r)
158 : {
159 0 : ndr_print_lsa_StringLarge(ndr, name, r);
160 0 : }
161 :
162 8317 : _PUBLIC_ void ndr_print_lsa_StringLarge(struct ndr_print *ndr, const char *name, const struct lsa_StringLarge *r)
163 : {
164 8317 : ndr_print_struct(ndr, name, "lsa_StringLarge");
165 8317 : if (r == NULL) { ndr_print_null(ndr); return; }
166 8317 : ndr->depth++;
167 8317 : ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->string):r->length);
168 8317 : ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m_term(r->string):r->size);
169 8317 : ndr_print_ptr(ndr, "string", r->string);
170 8317 : ndr->depth++;
171 8317 : if (r->string) {
172 7889 : ndr_print_string(ndr, "string", r->string);
173 : }
174 8317 : ndr->depth--;
175 8317 : ndr->depth--;
176 : }
177 :
178 169 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_Strings(struct ndr_push *ndr, int ndr_flags, const struct lsa_Strings *r)
179 : {
180 : uint32_t cntr_names_1;
181 169 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
182 169 : if (ndr_flags & NDR_SCALARS) {
183 169 : NDR_CHECK(ndr_push_align(ndr, 5));
184 169 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
185 169 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->names));
186 169 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
187 : }
188 169 : if (ndr_flags & NDR_BUFFERS) {
189 169 : if (r->names) {
190 165 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
191 402 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
192 237 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
193 : }
194 402 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
195 237 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
196 : }
197 : }
198 : }
199 169 : return NDR_ERR_SUCCESS;
200 : }
201 :
202 129 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_Strings(struct ndr_pull *ndr, int ndr_flags, struct lsa_Strings *r)
203 : {
204 : uint32_t _ptr_names;
205 129 : uint32_t size_names_1 = 0;
206 : uint32_t cntr_names_1;
207 129 : TALLOC_CTX *_mem_save_names_0 = NULL;
208 129 : TALLOC_CTX *_mem_save_names_1 = NULL;
209 129 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
210 129 : if (ndr_flags & NDR_SCALARS) {
211 129 : NDR_CHECK(ndr_pull_align(ndr, 5));
212 129 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
213 129 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_names));
214 129 : if (_ptr_names) {
215 125 : NDR_PULL_ALLOC(ndr, r->names);
216 : } else {
217 4 : r->names = NULL;
218 : }
219 129 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
220 : }
221 129 : if (ndr_flags & NDR_BUFFERS) {
222 129 : if (r->names) {
223 125 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
224 125 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
225 125 : NDR_CHECK(ndr_pull_array_size(ndr, &r->names));
226 125 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->names, &size_names_1));
227 125 : NDR_PULL_ALLOC_N(ndr, r->names, size_names_1);
228 125 : _mem_save_names_1 = NDR_PULL_GET_MEM_CTX(ndr);
229 125 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
230 251 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
231 126 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
232 : }
233 251 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
234 126 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
235 : }
236 125 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_1, 0);
237 125 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
238 : }
239 129 : if (r->names) {
240 125 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->names, r->count));
241 : }
242 129 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
243 : }
244 : }
245 129 : return NDR_ERR_SUCCESS;
246 : }
247 :
248 0 : static void ndr_print_flags_lsa_Strings(struct ndr_print *ndr, const char *name, int unused, const struct lsa_Strings *r)
249 : {
250 0 : ndr_print_lsa_Strings(ndr, name, r);
251 0 : }
252 :
253 60 : _PUBLIC_ void ndr_print_lsa_Strings(struct ndr_print *ndr, const char *name, const struct lsa_Strings *r)
254 : {
255 : uint32_t cntr_names_1;
256 60 : ndr_print_struct(ndr, name, "lsa_Strings");
257 60 : if (r == NULL) { ndr_print_null(ndr); return; }
258 60 : ndr->depth++;
259 60 : ndr_print_uint32(ndr, "count", r->count);
260 60 : ndr_print_ptr(ndr, "names", r->names);
261 60 : ndr->depth++;
262 60 : if (r->names) {
263 60 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->count);
264 60 : ndr->depth++;
265 120 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
266 60 : ndr_print_lsa_String(ndr, "names", &r->names[cntr_names_1]);
267 : }
268 60 : ndr->depth--;
269 : }
270 60 : ndr->depth--;
271 60 : ndr->depth--;
272 : }
273 :
274 48 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_AsciiString(struct ndr_push *ndr, int ndr_flags, const struct lsa_AsciiString *r)
275 : {
276 48 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
277 48 : if (ndr_flags & NDR_SCALARS) {
278 48 : NDR_CHECK(ndr_push_align(ndr, 5));
279 48 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m(r->string)));
280 48 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m(r->string)));
281 48 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
282 48 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
283 : }
284 48 : if (ndr_flags & NDR_BUFFERS) {
285 48 : if (r->string) {
286 48 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, strlen_m(r->string)));
287 48 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
288 48 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, strlen_m(r->string)));
289 48 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->string, strlen_m(r->string), sizeof(uint8_t), CH_DOS));
290 : }
291 : }
292 48 : return NDR_ERR_SUCCESS;
293 : }
294 :
295 48 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_AsciiString(struct ndr_pull *ndr, int ndr_flags, struct lsa_AsciiString *r)
296 : {
297 : uint32_t _ptr_string;
298 48 : uint32_t size_string_1 = 0;
299 48 : uint32_t length_string_1 = 0;
300 48 : TALLOC_CTX *_mem_save_string_0 = NULL;
301 48 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
302 48 : if (ndr_flags & NDR_SCALARS) {
303 48 : NDR_CHECK(ndr_pull_align(ndr, 5));
304 48 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->length));
305 48 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
306 48 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
307 48 : if (_ptr_string) {
308 48 : NDR_PULL_ALLOC(ndr, r->string);
309 : } else {
310 0 : r->string = NULL;
311 : }
312 48 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
313 : }
314 48 : if (ndr_flags & NDR_BUFFERS) {
315 48 : if (r->string) {
316 48 : _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
317 48 : NDR_PULL_SET_MEM_CTX(ndr, r->string, 0);
318 48 : NDR_CHECK(ndr_pull_array_size(ndr, &r->string));
319 48 : NDR_CHECK(ndr_pull_array_length(ndr, &r->string));
320 48 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->string, &size_string_1));
321 48 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->string, &length_string_1));
322 48 : if (length_string_1 > size_string_1) {
323 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_string_1, length_string_1);
324 : }
325 48 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->string, length_string_1, sizeof(uint8_t), CH_DOS));
326 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, 0);
327 : }
328 48 : if (r->string) {
329 48 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->string, r->size));
330 : }
331 48 : if (r->string) {
332 48 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->string, r->length));
333 : }
334 : }
335 48 : return NDR_ERR_SUCCESS;
336 : }
337 :
338 0 : static void ndr_print_flags_lsa_AsciiString(struct ndr_print *ndr, const char *name, int unused, const struct lsa_AsciiString *r)
339 : {
340 0 : ndr_print_lsa_AsciiString(ndr, name, r);
341 0 : }
342 :
343 0 : _PUBLIC_ void ndr_print_lsa_AsciiString(struct ndr_print *ndr, const char *name, const struct lsa_AsciiString *r)
344 : {
345 0 : ndr_print_struct(ndr, name, "lsa_AsciiString");
346 0 : if (r == NULL) { ndr_print_null(ndr); return; }
347 0 : ndr->depth++;
348 0 : ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m(r->string):r->length);
349 0 : ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m(r->string):r->size);
350 0 : ndr_print_ptr(ndr, "string", r->string);
351 0 : ndr->depth++;
352 0 : if (r->string) {
353 0 : ndr_print_string(ndr, "string", r->string);
354 : }
355 0 : ndr->depth--;
356 0 : ndr->depth--;
357 : }
358 :
359 1386 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_AsciiStringLarge(struct ndr_push *ndr, int ndr_flags, const struct lsa_AsciiStringLarge *r)
360 : {
361 1386 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
362 1386 : if (ndr_flags & NDR_SCALARS) {
363 693 : NDR_CHECK(ndr_push_align(ndr, 5));
364 693 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m(r->string)));
365 693 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m_term(r->string)));
366 693 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->string));
367 693 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
368 : }
369 1386 : if (ndr_flags & NDR_BUFFERS) {
370 693 : if (r->string) {
371 693 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, strlen_m_term(r->string)));
372 693 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
373 693 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, strlen_m(r->string)));
374 693 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->string, strlen_m(r->string), sizeof(uint8_t), CH_DOS));
375 : }
376 : }
377 1386 : return NDR_ERR_SUCCESS;
378 : }
379 :
380 1386 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_AsciiStringLarge(struct ndr_pull *ndr, int ndr_flags, struct lsa_AsciiStringLarge *r)
381 : {
382 : uint32_t _ptr_string;
383 1386 : uint32_t size_string_1 = 0;
384 1386 : uint32_t length_string_1 = 0;
385 1386 : TALLOC_CTX *_mem_save_string_0 = NULL;
386 1386 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
387 1386 : if (ndr_flags & NDR_SCALARS) {
388 693 : NDR_CHECK(ndr_pull_align(ndr, 5));
389 693 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->length));
390 693 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
391 693 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string));
392 693 : if (_ptr_string) {
393 693 : NDR_PULL_ALLOC(ndr, r->string);
394 : } else {
395 0 : r->string = NULL;
396 : }
397 693 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
398 : }
399 1386 : if (ndr_flags & NDR_BUFFERS) {
400 693 : if (r->string) {
401 693 : _mem_save_string_0 = NDR_PULL_GET_MEM_CTX(ndr);
402 693 : NDR_PULL_SET_MEM_CTX(ndr, r->string, 0);
403 693 : NDR_CHECK(ndr_pull_array_size(ndr, &r->string));
404 693 : NDR_CHECK(ndr_pull_array_length(ndr, &r->string));
405 693 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->string, &size_string_1));
406 693 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->string, &length_string_1));
407 693 : if (length_string_1 > size_string_1) {
408 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_string_1, length_string_1);
409 : }
410 693 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->string, length_string_1, sizeof(uint8_t), CH_DOS));
411 693 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_0, 0);
412 : }
413 693 : if (r->string) {
414 693 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->string, r->size));
415 : }
416 693 : if (r->string) {
417 693 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->string, r->length));
418 : }
419 : }
420 1386 : return NDR_ERR_SUCCESS;
421 : }
422 :
423 0 : static void ndr_print_flags_lsa_AsciiStringLarge(struct ndr_print *ndr, const char *name, int unused, const struct lsa_AsciiStringLarge *r)
424 : {
425 0 : ndr_print_lsa_AsciiStringLarge(ndr, name, r);
426 0 : }
427 :
428 0 : _PUBLIC_ void ndr_print_lsa_AsciiStringLarge(struct ndr_print *ndr, const char *name, const struct lsa_AsciiStringLarge *r)
429 : {
430 0 : ndr_print_struct(ndr, name, "lsa_AsciiStringLarge");
431 0 : if (r == NULL) { ndr_print_null(ndr); return; }
432 0 : ndr->depth++;
433 0 : ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m(r->string):r->length);
434 0 : ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m_term(r->string):r->size);
435 0 : ndr_print_ptr(ndr, "string", r->string);
436 0 : ndr->depth++;
437 0 : if (r->string) {
438 0 : ndr_print_string(ndr, "string", r->string);
439 : }
440 0 : ndr->depth--;
441 0 : ndr->depth--;
442 : }
443 :
444 28716 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_BinaryString(struct ndr_push *ndr, int ndr_flags, const struct lsa_BinaryString *r)
445 : {
446 : uint32_t cntr_array_1;
447 28716 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
448 28716 : if (ndr_flags & NDR_SCALARS) {
449 14358 : NDR_CHECK(ndr_push_align(ndr, 5));
450 14358 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->length));
451 14358 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->size));
452 14358 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->array));
453 14358 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
454 : }
455 28716 : if (ndr_flags & NDR_BUFFERS) {
456 14358 : if (r->array) {
457 1075 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->size / 2));
458 1075 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
459 1075 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->length / 2));
460 9774 : for (cntr_array_1 = 0; cntr_array_1 < (r->length / 2); cntr_array_1++) {
461 8699 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->array[cntr_array_1]));
462 : }
463 : }
464 : }
465 28716 : return NDR_ERR_SUCCESS;
466 : }
467 :
468 28452 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_BinaryString(struct ndr_pull *ndr, int ndr_flags, struct lsa_BinaryString *r)
469 : {
470 : uint32_t _ptr_array;
471 28452 : uint32_t size_array_1 = 0;
472 28452 : uint32_t length_array_1 = 0;
473 : uint32_t cntr_array_1;
474 28452 : TALLOC_CTX *_mem_save_array_0 = NULL;
475 28452 : TALLOC_CTX *_mem_save_array_1 = NULL;
476 28452 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
477 28452 : if (ndr_flags & NDR_SCALARS) {
478 14226 : NDR_CHECK(ndr_pull_align(ndr, 5));
479 14226 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->length));
480 14226 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
481 14226 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_array));
482 14226 : if (_ptr_array) {
483 1075 : NDR_PULL_ALLOC(ndr, r->array);
484 : } else {
485 13151 : r->array = NULL;
486 : }
487 14226 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
488 : }
489 28452 : if (ndr_flags & NDR_BUFFERS) {
490 14226 : if (r->array) {
491 1075 : _mem_save_array_0 = NDR_PULL_GET_MEM_CTX(ndr);
492 1075 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
493 1075 : NDR_CHECK(ndr_pull_array_size(ndr, &r->array));
494 1075 : NDR_CHECK(ndr_pull_array_length(ndr, &r->array));
495 1075 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->array, &size_array_1));
496 1075 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->array, &length_array_1));
497 1075 : if (length_array_1 > size_array_1) {
498 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_array_1, length_array_1);
499 : }
500 1075 : NDR_PULL_ALLOC_N(ndr, r->array, size_array_1);
501 1075 : _mem_save_array_1 = NDR_PULL_GET_MEM_CTX(ndr);
502 1075 : NDR_PULL_SET_MEM_CTX(ndr, r->array, 0);
503 9774 : for (cntr_array_1 = 0; cntr_array_1 < (length_array_1); cntr_array_1++) {
504 8699 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->array[cntr_array_1]));
505 : }
506 1075 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_1, 0);
507 1075 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_array_0, 0);
508 : }
509 14226 : if (r->array) {
510 1075 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->array, r->size / 2));
511 : }
512 14226 : if (r->array) {
513 1075 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->array, r->length / 2));
514 : }
515 : }
516 28452 : return NDR_ERR_SUCCESS;
517 : }
518 :
519 0 : static void ndr_print_flags_lsa_BinaryString(struct ndr_print *ndr, const char *name, int unused, const struct lsa_BinaryString *r)
520 : {
521 0 : ndr_print_lsa_BinaryString(ndr, name, r);
522 0 : }
523 :
524 258 : _PUBLIC_ void ndr_print_lsa_BinaryString(struct ndr_print *ndr, const char *name, const struct lsa_BinaryString *r)
525 : {
526 : uint32_t cntr_array_1;
527 258 : ndr_print_struct(ndr, name, "lsa_BinaryString");
528 258 : if (r == NULL) { ndr_print_null(ndr); return; }
529 258 : ndr->depth++;
530 258 : ndr_print_uint16(ndr, "length", r->length);
531 258 : ndr_print_uint16(ndr, "size", r->size);
532 258 : ndr_print_ptr(ndr, "array", r->array);
533 258 : ndr->depth++;
534 258 : if (r->array) {
535 0 : ndr->print(ndr, "%s: ARRAY(%d)", "array", (int)r->length / 2);
536 0 : ndr->depth++;
537 0 : for (cntr_array_1 = 0; cntr_array_1 < (r->length / 2); cntr_array_1++) {
538 0 : ndr_print_uint16(ndr, "array", r->array[cntr_array_1]);
539 : }
540 0 : ndr->depth--;
541 : }
542 258 : ndr->depth--;
543 258 : ndr->depth--;
544 : }
545 :
546 578 : static enum ndr_err_code ndr_push_lsa_LUID(struct ndr_push *ndr, int ndr_flags, const struct lsa_LUID *r)
547 : {
548 578 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
549 578 : if (ndr_flags & NDR_SCALARS) {
550 578 : NDR_CHECK(ndr_push_align(ndr, 4));
551 578 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->low));
552 578 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->high));
553 578 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
554 : }
555 578 : if (ndr_flags & NDR_BUFFERS) {
556 : }
557 578 : return NDR_ERR_SUCCESS;
558 : }
559 :
560 496 : static enum ndr_err_code ndr_pull_lsa_LUID(struct ndr_pull *ndr, int ndr_flags, struct lsa_LUID *r)
561 : {
562 496 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
563 496 : if (ndr_flags & NDR_SCALARS) {
564 496 : NDR_CHECK(ndr_pull_align(ndr, 4));
565 496 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->low));
566 496 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->high));
567 496 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
568 : }
569 496 : if (ndr_flags & NDR_BUFFERS) {
570 : }
571 496 : return NDR_ERR_SUCCESS;
572 : }
573 :
574 164 : _PUBLIC_ void ndr_print_lsa_LUID(struct ndr_print *ndr, const char *name, const struct lsa_LUID *r)
575 : {
576 164 : ndr_print_struct(ndr, name, "lsa_LUID");
577 164 : if (r == NULL) { ndr_print_null(ndr); return; }
578 164 : ndr->depth++;
579 164 : ndr_print_uint32(ndr, "low", r->low);
580 164 : ndr_print_uint32(ndr, "high", r->high);
581 164 : ndr->depth--;
582 : }
583 :
584 250 : static enum ndr_err_code ndr_push_lsa_PrivEntry(struct ndr_push *ndr, int ndr_flags, const struct lsa_PrivEntry *r)
585 : {
586 250 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
587 250 : if (ndr_flags & NDR_SCALARS) {
588 125 : NDR_CHECK(ndr_push_align(ndr, 5));
589 125 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->name));
590 125 : NDR_CHECK(ndr_push_lsa_LUID(ndr, NDR_SCALARS, &r->luid));
591 125 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
592 : }
593 250 : if (ndr_flags & NDR_BUFFERS) {
594 125 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->name));
595 : }
596 250 : return NDR_ERR_SUCCESS;
597 : }
598 :
599 200 : static enum ndr_err_code ndr_pull_lsa_PrivEntry(struct ndr_pull *ndr, int ndr_flags, struct lsa_PrivEntry *r)
600 : {
601 200 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
602 200 : if (ndr_flags & NDR_SCALARS) {
603 100 : NDR_CHECK(ndr_pull_align(ndr, 5));
604 100 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->name));
605 100 : NDR_CHECK(ndr_pull_lsa_LUID(ndr, NDR_SCALARS, &r->luid));
606 100 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
607 : }
608 200 : if (ndr_flags & NDR_BUFFERS) {
609 100 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->name));
610 : }
611 200 : return NDR_ERR_SUCCESS;
612 : }
613 :
614 50 : _PUBLIC_ void ndr_print_lsa_PrivEntry(struct ndr_print *ndr, const char *name, const struct lsa_PrivEntry *r)
615 : {
616 50 : ndr_print_struct(ndr, name, "lsa_PrivEntry");
617 50 : if (r == NULL) { ndr_print_null(ndr); return; }
618 50 : ndr->depth++;
619 50 : ndr_print_lsa_StringLarge(ndr, "name", &r->name);
620 50 : ndr_print_lsa_LUID(ndr, "luid", &r->luid);
621 50 : ndr->depth--;
622 : }
623 :
624 5 : static enum ndr_err_code ndr_push_lsa_PrivArray(struct ndr_push *ndr, int ndr_flags, const struct lsa_PrivArray *r)
625 : {
626 : uint32_t cntr_privs_1;
627 5 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
628 5 : if (ndr_flags & NDR_SCALARS) {
629 5 : NDR_CHECK(ndr_push_align(ndr, 5));
630 5 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
631 5 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->privs));
632 5 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
633 : }
634 5 : if (ndr_flags & NDR_BUFFERS) {
635 5 : if (r->privs) {
636 5 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
637 130 : for (cntr_privs_1 = 0; cntr_privs_1 < (r->count); cntr_privs_1++) {
638 125 : NDR_CHECK(ndr_push_lsa_PrivEntry(ndr, NDR_SCALARS, &r->privs[cntr_privs_1]));
639 : }
640 130 : for (cntr_privs_1 = 0; cntr_privs_1 < (r->count); cntr_privs_1++) {
641 125 : NDR_CHECK(ndr_push_lsa_PrivEntry(ndr, NDR_BUFFERS, &r->privs[cntr_privs_1]));
642 : }
643 : }
644 : }
645 5 : return NDR_ERR_SUCCESS;
646 : }
647 :
648 4 : static enum ndr_err_code ndr_pull_lsa_PrivArray(struct ndr_pull *ndr, int ndr_flags, struct lsa_PrivArray *r)
649 : {
650 : uint32_t _ptr_privs;
651 4 : uint32_t size_privs_1 = 0;
652 : uint32_t cntr_privs_1;
653 4 : TALLOC_CTX *_mem_save_privs_0 = NULL;
654 4 : TALLOC_CTX *_mem_save_privs_1 = NULL;
655 4 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
656 4 : if (ndr_flags & NDR_SCALARS) {
657 4 : NDR_CHECK(ndr_pull_align(ndr, 5));
658 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
659 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_privs));
660 4 : if (_ptr_privs) {
661 4 : NDR_PULL_ALLOC(ndr, r->privs);
662 : } else {
663 0 : r->privs = NULL;
664 : }
665 4 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
666 : }
667 4 : if (ndr_flags & NDR_BUFFERS) {
668 4 : if (r->privs) {
669 4 : _mem_save_privs_0 = NDR_PULL_GET_MEM_CTX(ndr);
670 4 : NDR_PULL_SET_MEM_CTX(ndr, r->privs, 0);
671 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->privs));
672 4 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->privs, &size_privs_1));
673 4 : NDR_PULL_ALLOC_N(ndr, r->privs, size_privs_1);
674 4 : _mem_save_privs_1 = NDR_PULL_GET_MEM_CTX(ndr);
675 4 : NDR_PULL_SET_MEM_CTX(ndr, r->privs, 0);
676 104 : for (cntr_privs_1 = 0; cntr_privs_1 < (size_privs_1); cntr_privs_1++) {
677 100 : NDR_CHECK(ndr_pull_lsa_PrivEntry(ndr, NDR_SCALARS, &r->privs[cntr_privs_1]));
678 : }
679 104 : for (cntr_privs_1 = 0; cntr_privs_1 < (size_privs_1); cntr_privs_1++) {
680 100 : NDR_CHECK(ndr_pull_lsa_PrivEntry(ndr, NDR_BUFFERS, &r->privs[cntr_privs_1]));
681 : }
682 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_1, 0);
683 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_0, 0);
684 : }
685 4 : if (r->privs) {
686 4 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->privs, r->count));
687 : }
688 4 : for (cntr_privs_1 = 0; cntr_privs_1 < (size_privs_1); cntr_privs_1++) {
689 : }
690 : }
691 4 : return NDR_ERR_SUCCESS;
692 : }
693 :
694 2 : _PUBLIC_ void ndr_print_lsa_PrivArray(struct ndr_print *ndr, const char *name, const struct lsa_PrivArray *r)
695 : {
696 : uint32_t cntr_privs_1;
697 2 : ndr_print_struct(ndr, name, "lsa_PrivArray");
698 2 : if (r == NULL) { ndr_print_null(ndr); return; }
699 2 : ndr->depth++;
700 2 : ndr_print_uint32(ndr, "count", r->count);
701 2 : ndr_print_ptr(ndr, "privs", r->privs);
702 2 : ndr->depth++;
703 2 : if (r->privs) {
704 2 : ndr->print(ndr, "%s: ARRAY(%d)", "privs", (int)r->count);
705 2 : ndr->depth++;
706 52 : for (cntr_privs_1 = 0; cntr_privs_1 < (r->count); cntr_privs_1++) {
707 50 : ndr_print_lsa_PrivEntry(ndr, "privs", &r->privs[cntr_privs_1]);
708 : }
709 2 : ndr->depth--;
710 : }
711 2 : ndr->depth--;
712 2 : ndr->depth--;
713 : }
714 :
715 2476 : static enum ndr_err_code ndr_push_lsa_QosInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_QosInfo *r)
716 : {
717 2476 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
718 2476 : if (ndr_flags & NDR_SCALARS) {
719 2476 : NDR_CHECK(ndr_push_align(ndr, 5));
720 2476 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->len));
721 2476 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->impersonation_level));
722 2476 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->context_mode));
723 2476 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->effective_only));
724 2476 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
725 : }
726 2476 : if (ndr_flags & NDR_BUFFERS) {
727 : }
728 2476 : return NDR_ERR_SUCCESS;
729 : }
730 :
731 2795 : static enum ndr_err_code ndr_pull_lsa_QosInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_QosInfo *r)
732 : {
733 2795 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
734 2795 : if (ndr_flags & NDR_SCALARS) {
735 2795 : NDR_CHECK(ndr_pull_align(ndr, 5));
736 2795 : NDR_CHECK(ndr_pull_uint3264(ndr, NDR_SCALARS, &r->len));
737 2795 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->impersonation_level));
738 2795 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->context_mode));
739 2795 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->effective_only));
740 2795 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
741 : }
742 2795 : if (ndr_flags & NDR_BUFFERS) {
743 : }
744 2795 : return NDR_ERR_SUCCESS;
745 : }
746 :
747 0 : _PUBLIC_ void ndr_print_lsa_QosInfo(struct ndr_print *ndr, const char *name, const struct lsa_QosInfo *r)
748 : {
749 0 : ndr_print_struct(ndr, name, "lsa_QosInfo");
750 0 : if (r == NULL) { ndr_print_null(ndr); return; }
751 0 : ndr->depth++;
752 0 : ndr_print_uint3264(ndr, "len", r->len);
753 0 : ndr_print_uint16(ndr, "impersonation_level", r->impersonation_level);
754 0 : ndr_print_uint8(ndr, "context_mode", r->context_mode);
755 0 : ndr_print_uint8(ndr, "effective_only", r->effective_only);
756 0 : ndr->depth--;
757 : }
758 :
759 2732 : static enum ndr_err_code ndr_push_lsa_ObjectAttribute(struct ndr_push *ndr, int ndr_flags, const struct lsa_ObjectAttribute *r)
760 : {
761 2732 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
762 2732 : if (ndr_flags & NDR_SCALARS) {
763 2732 : NDR_CHECK(ndr_push_align(ndr, 5));
764 2732 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->len));
765 2732 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->root_dir));
766 2732 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->object_name));
767 2732 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->attributes));
768 2732 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sec_desc));
769 2732 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sec_qos));
770 2732 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
771 : }
772 2732 : if (ndr_flags & NDR_BUFFERS) {
773 2732 : if (r->root_dir) {
774 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, *r->root_dir));
775 : }
776 2732 : if (r->object_name) {
777 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->object_name, CH_UTF16)));
778 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
779 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->object_name, CH_UTF16)));
780 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->object_name, ndr_charset_length(r->object_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
781 : }
782 2732 : if (r->sec_desc) {
783 0 : NDR_CHECK(ndr_push_security_descriptor(ndr, NDR_SCALARS|NDR_BUFFERS, r->sec_desc));
784 : }
785 2732 : if (r->sec_qos) {
786 2476 : NDR_CHECK(ndr_push_lsa_QosInfo(ndr, NDR_SCALARS, r->sec_qos));
787 : }
788 : }
789 2732 : return NDR_ERR_SUCCESS;
790 : }
791 :
792 3042 : static enum ndr_err_code ndr_pull_lsa_ObjectAttribute(struct ndr_pull *ndr, int ndr_flags, struct lsa_ObjectAttribute *r)
793 : {
794 : uint32_t _ptr_root_dir;
795 3042 : TALLOC_CTX *_mem_save_root_dir_0 = NULL;
796 : uint32_t _ptr_object_name;
797 3042 : uint32_t size_object_name_1 = 0;
798 3042 : uint32_t length_object_name_1 = 0;
799 3042 : TALLOC_CTX *_mem_save_object_name_0 = NULL;
800 : uint32_t _ptr_sec_desc;
801 3042 : TALLOC_CTX *_mem_save_sec_desc_0 = NULL;
802 : uint32_t _ptr_sec_qos;
803 3042 : TALLOC_CTX *_mem_save_sec_qos_0 = NULL;
804 3042 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
805 3042 : if (ndr_flags & NDR_SCALARS) {
806 3042 : NDR_CHECK(ndr_pull_align(ndr, 5));
807 3042 : NDR_CHECK(ndr_pull_uint3264(ndr, NDR_SCALARS, &r->len));
808 3042 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_root_dir));
809 3042 : if (_ptr_root_dir) {
810 0 : NDR_PULL_ALLOC(ndr, r->root_dir);
811 : } else {
812 3042 : r->root_dir = NULL;
813 : }
814 3042 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_object_name));
815 3042 : if (_ptr_object_name) {
816 0 : NDR_PULL_ALLOC(ndr, r->object_name);
817 : } else {
818 3042 : r->object_name = NULL;
819 : }
820 3042 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->attributes));
821 3042 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sec_desc));
822 3042 : if (_ptr_sec_desc) {
823 0 : NDR_PULL_ALLOC(ndr, r->sec_desc);
824 : } else {
825 3042 : r->sec_desc = NULL;
826 : }
827 3042 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sec_qos));
828 3042 : if (_ptr_sec_qos) {
829 2795 : NDR_PULL_ALLOC(ndr, r->sec_qos);
830 : } else {
831 247 : r->sec_qos = NULL;
832 : }
833 3042 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
834 : }
835 3042 : if (ndr_flags & NDR_BUFFERS) {
836 3042 : if (r->root_dir) {
837 0 : _mem_save_root_dir_0 = NDR_PULL_GET_MEM_CTX(ndr);
838 0 : NDR_PULL_SET_MEM_CTX(ndr, r->root_dir, 0);
839 0 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, r->root_dir));
840 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_root_dir_0, 0);
841 : }
842 3042 : if (r->object_name) {
843 0 : _mem_save_object_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
844 0 : NDR_PULL_SET_MEM_CTX(ndr, r->object_name, 0);
845 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->object_name));
846 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->object_name));
847 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->object_name, &size_object_name_1));
848 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->object_name, &length_object_name_1));
849 0 : if (length_object_name_1 > size_object_name_1) {
850 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_object_name_1, length_object_name_1);
851 : }
852 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_object_name_1, sizeof(uint16_t)));
853 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->object_name, length_object_name_1, sizeof(uint16_t), CH_UTF16));
854 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_object_name_0, 0);
855 : }
856 3042 : if (r->sec_desc) {
857 0 : _mem_save_sec_desc_0 = NDR_PULL_GET_MEM_CTX(ndr);
858 0 : NDR_PULL_SET_MEM_CTX(ndr, r->sec_desc, 0);
859 0 : NDR_CHECK(ndr_pull_security_descriptor(ndr, NDR_SCALARS|NDR_BUFFERS, r->sec_desc));
860 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sec_desc_0, 0);
861 : }
862 3042 : if (r->sec_qos) {
863 2795 : _mem_save_sec_qos_0 = NDR_PULL_GET_MEM_CTX(ndr);
864 2795 : NDR_PULL_SET_MEM_CTX(ndr, r->sec_qos, 0);
865 2795 : NDR_CHECK(ndr_pull_lsa_QosInfo(ndr, NDR_SCALARS, r->sec_qos));
866 2795 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sec_qos_0, 0);
867 : }
868 : }
869 3042 : return NDR_ERR_SUCCESS;
870 : }
871 :
872 0 : _PUBLIC_ void ndr_print_lsa_ObjectAttribute(struct ndr_print *ndr, const char *name, const struct lsa_ObjectAttribute *r)
873 : {
874 0 : ndr_print_struct(ndr, name, "lsa_ObjectAttribute");
875 0 : if (r == NULL) { ndr_print_null(ndr); return; }
876 0 : ndr->depth++;
877 0 : ndr_print_uint3264(ndr, "len", r->len);
878 0 : ndr_print_ptr(ndr, "root_dir", r->root_dir);
879 0 : ndr->depth++;
880 0 : if (r->root_dir) {
881 0 : ndr_print_uint8(ndr, "root_dir", *r->root_dir);
882 : }
883 0 : ndr->depth--;
884 0 : ndr_print_ptr(ndr, "object_name", r->object_name);
885 0 : ndr->depth++;
886 0 : if (r->object_name) {
887 0 : ndr_print_string(ndr, "object_name", r->object_name);
888 : }
889 0 : ndr->depth--;
890 0 : ndr_print_uint32(ndr, "attributes", r->attributes);
891 0 : ndr_print_ptr(ndr, "sec_desc", r->sec_desc);
892 0 : ndr->depth++;
893 0 : if (r->sec_desc) {
894 0 : ndr_print_security_descriptor(ndr, "sec_desc", r->sec_desc);
895 : }
896 0 : ndr->depth--;
897 0 : ndr_print_ptr(ndr, "sec_qos", r->sec_qos);
898 0 : ndr->depth++;
899 0 : if (r->sec_qos) {
900 0 : ndr_print_lsa_QosInfo(ndr, "sec_qos", r->sec_qos);
901 : }
902 0 : ndr->depth--;
903 0 : ndr->depth--;
904 : }
905 :
906 2732 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_PolicyAccessMask(struct ndr_push *ndr, int ndr_flags, uint32_t r)
907 : {
908 2732 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
909 2732 : return NDR_ERR_SUCCESS;
910 : }
911 :
912 3042 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_PolicyAccessMask(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
913 : {
914 : uint32_t v;
915 3042 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
916 3042 : *r = v;
917 3042 : return NDR_ERR_SUCCESS;
918 : }
919 :
920 0 : _PUBLIC_ void ndr_print_lsa_PolicyAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
921 : {
922 0 : ndr_print_uint32(ndr, name, r);
923 0 : ndr->depth++;
924 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_VIEW_LOCAL_INFORMATION", LSA_POLICY_VIEW_LOCAL_INFORMATION, r);
925 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_VIEW_AUDIT_INFORMATION", LSA_POLICY_VIEW_AUDIT_INFORMATION, r);
926 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_GET_PRIVATE_INFORMATION", LSA_POLICY_GET_PRIVATE_INFORMATION, r);
927 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_TRUST_ADMIN", LSA_POLICY_TRUST_ADMIN, r);
928 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_CREATE_ACCOUNT", LSA_POLICY_CREATE_ACCOUNT, r);
929 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_CREATE_SECRET", LSA_POLICY_CREATE_SECRET, r);
930 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_CREATE_PRIVILEGE", LSA_POLICY_CREATE_PRIVILEGE, r);
931 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_SET_DEFAULT_QUOTA_LIMITS", LSA_POLICY_SET_DEFAULT_QUOTA_LIMITS, r);
932 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_SET_AUDIT_REQUIREMENTS", LSA_POLICY_SET_AUDIT_REQUIREMENTS, r);
933 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_AUDIT_LOG_ADMIN", LSA_POLICY_AUDIT_LOG_ADMIN, r);
934 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_SERVER_ADMIN", LSA_POLICY_SERVER_ADMIN, r);
935 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_LOOKUP_NAMES", LSA_POLICY_LOOKUP_NAMES, r);
936 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_NOTIFICATION", LSA_POLICY_NOTIFICATION, r);
937 0 : ndr->depth--;
938 0 : }
939 :
940 74 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_AccountAccessMask(struct ndr_push *ndr, int ndr_flags, uint32_t r)
941 : {
942 74 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
943 74 : return NDR_ERR_SUCCESS;
944 : }
945 :
946 68 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_AccountAccessMask(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
947 : {
948 : uint32_t v;
949 68 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
950 68 : *r = v;
951 68 : return NDR_ERR_SUCCESS;
952 : }
953 :
954 12 : _PUBLIC_ void ndr_print_lsa_AccountAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
955 : {
956 12 : ndr_print_uint32(ndr, name, r);
957 12 : ndr->depth++;
958 12 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_ACCOUNT_VIEW", LSA_ACCOUNT_VIEW, r);
959 12 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_ACCOUNT_ADJUST_PRIVILEGES", LSA_ACCOUNT_ADJUST_PRIVILEGES, r);
960 12 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_ACCOUNT_ADJUST_QUOTAS", LSA_ACCOUNT_ADJUST_QUOTAS, r);
961 12 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_ACCOUNT_ADJUST_SYSTEM_ACCESS", LSA_ACCOUNT_ADJUST_SYSTEM_ACCESS, r);
962 12 : ndr->depth--;
963 12 : }
964 :
965 1698 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_SecretAccessMask(struct ndr_push *ndr, int ndr_flags, uint32_t r)
966 : {
967 1698 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
968 1698 : return NDR_ERR_SUCCESS;
969 : }
970 :
971 1698 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_SecretAccessMask(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
972 : {
973 : uint32_t v;
974 1698 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
975 1698 : *r = v;
976 1698 : return NDR_ERR_SUCCESS;
977 : }
978 :
979 0 : _PUBLIC_ void ndr_print_lsa_SecretAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
980 : {
981 0 : ndr_print_uint32(ndr, name, r);
982 0 : ndr->depth++;
983 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_SECRET_SET_VALUE", LSA_SECRET_SET_VALUE, r);
984 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_SECRET_QUERY_VALUE", LSA_SECRET_QUERY_VALUE, r);
985 0 : ndr->depth--;
986 0 : }
987 :
988 458 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TrustedAccessMask(struct ndr_push *ndr, int ndr_flags, uint32_t r)
989 : {
990 458 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
991 458 : return NDR_ERR_SUCCESS;
992 : }
993 :
994 458 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TrustedAccessMask(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
995 : {
996 : uint32_t v;
997 458 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
998 458 : *r = v;
999 458 : return NDR_ERR_SUCCESS;
1000 : }
1001 :
1002 0 : _PUBLIC_ void ndr_print_lsa_TrustedAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
1003 : {
1004 0 : ndr_print_uint32(ndr, name, r);
1005 0 : ndr->depth++;
1006 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUSTED_QUERY_DOMAIN_NAME", LSA_TRUSTED_QUERY_DOMAIN_NAME, r);
1007 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUSTED_QUERY_CONTROLLERS", LSA_TRUSTED_QUERY_CONTROLLERS, r);
1008 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUSTED_SET_CONTROLLERS", LSA_TRUSTED_SET_CONTROLLERS, r);
1009 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUSTED_QUERY_POSIX", LSA_TRUSTED_QUERY_POSIX, r);
1010 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUSTED_SET_POSIX", LSA_TRUSTED_SET_POSIX, r);
1011 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUSTED_SET_AUTH", LSA_TRUSTED_SET_AUTH, r);
1012 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUSTED_QUERY_AUTH", LSA_TRUSTED_QUERY_AUTH, r);
1013 0 : ndr->depth--;
1014 0 : }
1015 :
1016 20 : static enum ndr_err_code ndr_push_lsa_AuditLogInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_AuditLogInfo *r)
1017 : {
1018 20 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1019 20 : if (ndr_flags & NDR_SCALARS) {
1020 20 : NDR_CHECK(ndr_push_align(ndr, 8));
1021 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->percent_full));
1022 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->maximum_log_size));
1023 20 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->retention_time));
1024 20 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->shutdown_in_progress));
1025 20 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->time_to_shutdown));
1026 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->next_audit_record));
1027 20 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
1028 : }
1029 20 : if (ndr_flags & NDR_BUFFERS) {
1030 : }
1031 20 : return NDR_ERR_SUCCESS;
1032 : }
1033 :
1034 16 : static enum ndr_err_code ndr_pull_lsa_AuditLogInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_AuditLogInfo *r)
1035 : {
1036 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1037 16 : if (ndr_flags & NDR_SCALARS) {
1038 16 : NDR_CHECK(ndr_pull_align(ndr, 8));
1039 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->percent_full));
1040 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->maximum_log_size));
1041 16 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->retention_time));
1042 16 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->shutdown_in_progress));
1043 16 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->time_to_shutdown));
1044 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->next_audit_record));
1045 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
1046 : }
1047 16 : if (ndr_flags & NDR_BUFFERS) {
1048 : }
1049 16 : return NDR_ERR_SUCCESS;
1050 : }
1051 :
1052 8 : _PUBLIC_ void ndr_print_lsa_AuditLogInfo(struct ndr_print *ndr, const char *name, const struct lsa_AuditLogInfo *r)
1053 : {
1054 8 : ndr_print_struct(ndr, name, "lsa_AuditLogInfo");
1055 8 : if (r == NULL) { ndr_print_null(ndr); return; }
1056 8 : ndr->depth++;
1057 8 : ndr_print_uint32(ndr, "percent_full", r->percent_full);
1058 8 : ndr_print_uint32(ndr, "maximum_log_size", r->maximum_log_size);
1059 8 : ndr_print_hyper(ndr, "retention_time", r->retention_time);
1060 8 : ndr_print_uint8(ndr, "shutdown_in_progress", r->shutdown_in_progress);
1061 8 : ndr_print_hyper(ndr, "time_to_shutdown", r->time_to_shutdown);
1062 8 : ndr_print_uint32(ndr, "next_audit_record", r->next_audit_record);
1063 8 : ndr->depth--;
1064 : }
1065 :
1066 0 : static enum ndr_err_code ndr_push_lsa_PolicyAuditPolicy(struct ndr_push *ndr, int ndr_flags, enum lsa_PolicyAuditPolicy r)
1067 : {
1068 0 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
1069 0 : return NDR_ERR_SUCCESS;
1070 : }
1071 :
1072 0 : static enum ndr_err_code ndr_pull_lsa_PolicyAuditPolicy(struct ndr_pull *ndr, int ndr_flags, enum lsa_PolicyAuditPolicy *r)
1073 : {
1074 : uint32_t v;
1075 0 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
1076 0 : *r = v;
1077 0 : return NDR_ERR_SUCCESS;
1078 : }
1079 :
1080 0 : _PUBLIC_ void ndr_print_lsa_PolicyAuditPolicy(struct ndr_print *ndr, const char *name, enum lsa_PolicyAuditPolicy r)
1081 : {
1082 0 : const char *val = NULL;
1083 :
1084 0 : switch (r) {
1085 0 : case LSA_AUDIT_POLICY_NONE: val = "LSA_AUDIT_POLICY_NONE"; break;
1086 0 : case LSA_AUDIT_POLICY_SUCCESS: val = "LSA_AUDIT_POLICY_SUCCESS"; break;
1087 0 : case LSA_AUDIT_POLICY_FAILURE: val = "LSA_AUDIT_POLICY_FAILURE"; break;
1088 0 : case LSA_AUDIT_POLICY_ALL: val = "LSA_AUDIT_POLICY_ALL"; break;
1089 0 : case LSA_AUDIT_POLICY_CLEAR: val = "LSA_AUDIT_POLICY_CLEAR"; break;
1090 : }
1091 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
1092 0 : }
1093 :
1094 40 : static enum ndr_err_code ndr_push_lsa_AuditEventsInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_AuditEventsInfo *r)
1095 : {
1096 : uint32_t cntr_settings_1;
1097 40 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1098 40 : if (ndr_flags & NDR_SCALARS) {
1099 20 : NDR_CHECK(ndr_push_align(ndr, 5));
1100 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->auditing_mode));
1101 20 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->settings));
1102 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
1103 20 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1104 : }
1105 40 : if (ndr_flags & NDR_BUFFERS) {
1106 20 : if (r->settings) {
1107 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
1108 0 : for (cntr_settings_1 = 0; cntr_settings_1 < (r->count); cntr_settings_1++) {
1109 0 : NDR_CHECK(ndr_push_lsa_PolicyAuditPolicy(ndr, NDR_SCALARS, r->settings[cntr_settings_1]));
1110 : }
1111 : }
1112 : }
1113 40 : return NDR_ERR_SUCCESS;
1114 : }
1115 :
1116 32 : static enum ndr_err_code ndr_pull_lsa_AuditEventsInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_AuditEventsInfo *r)
1117 : {
1118 : uint32_t _ptr_settings;
1119 32 : uint32_t size_settings_1 = 0;
1120 : uint32_t cntr_settings_1;
1121 32 : TALLOC_CTX *_mem_save_settings_0 = NULL;
1122 32 : TALLOC_CTX *_mem_save_settings_1 = NULL;
1123 32 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1124 32 : if (ndr_flags & NDR_SCALARS) {
1125 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
1126 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->auditing_mode));
1127 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_settings));
1128 16 : if (_ptr_settings) {
1129 0 : NDR_PULL_ALLOC(ndr, r->settings);
1130 : } else {
1131 16 : r->settings = NULL;
1132 : }
1133 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
1134 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1135 : }
1136 32 : if (ndr_flags & NDR_BUFFERS) {
1137 16 : if (r->settings) {
1138 0 : _mem_save_settings_0 = NDR_PULL_GET_MEM_CTX(ndr);
1139 0 : NDR_PULL_SET_MEM_CTX(ndr, r->settings, 0);
1140 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->settings));
1141 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->settings, &size_settings_1));
1142 0 : NDR_PULL_ALLOC_N(ndr, r->settings, size_settings_1);
1143 0 : _mem_save_settings_1 = NDR_PULL_GET_MEM_CTX(ndr);
1144 0 : NDR_PULL_SET_MEM_CTX(ndr, r->settings, 0);
1145 0 : for (cntr_settings_1 = 0; cntr_settings_1 < (size_settings_1); cntr_settings_1++) {
1146 0 : NDR_CHECK(ndr_pull_lsa_PolicyAuditPolicy(ndr, NDR_SCALARS, &r->settings[cntr_settings_1]));
1147 : }
1148 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_settings_1, 0);
1149 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_settings_0, 0);
1150 : }
1151 16 : if (r->settings) {
1152 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->settings, r->count));
1153 : }
1154 : }
1155 32 : return NDR_ERR_SUCCESS;
1156 : }
1157 :
1158 8 : _PUBLIC_ void ndr_print_lsa_AuditEventsInfo(struct ndr_print *ndr, const char *name, const struct lsa_AuditEventsInfo *r)
1159 : {
1160 : uint32_t cntr_settings_1;
1161 8 : ndr_print_struct(ndr, name, "lsa_AuditEventsInfo");
1162 8 : if (r == NULL) { ndr_print_null(ndr); return; }
1163 8 : ndr->depth++;
1164 8 : ndr_print_uint32(ndr, "auditing_mode", r->auditing_mode);
1165 8 : ndr_print_ptr(ndr, "settings", r->settings);
1166 8 : ndr->depth++;
1167 8 : if (r->settings) {
1168 0 : ndr->print(ndr, "%s: ARRAY(%d)", "settings", (int)r->count);
1169 0 : ndr->depth++;
1170 0 : for (cntr_settings_1 = 0; cntr_settings_1 < (r->count); cntr_settings_1++) {
1171 0 : ndr_print_lsa_PolicyAuditPolicy(ndr, "settings", r->settings[cntr_settings_1]);
1172 : }
1173 0 : ndr->depth--;
1174 : }
1175 8 : ndr->depth--;
1176 8 : ndr_print_uint32(ndr, "count", r->count);
1177 8 : ndr->depth--;
1178 : }
1179 :
1180 8198 : static enum ndr_err_code ndr_push_lsa_DomainInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_DomainInfo *r)
1181 : {
1182 8198 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1183 8198 : if (ndr_flags & NDR_SCALARS) {
1184 4123 : NDR_CHECK(ndr_push_align(ndr, 5));
1185 4123 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->name));
1186 4123 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sid));
1187 4123 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1188 : }
1189 8198 : if (ndr_flags & NDR_BUFFERS) {
1190 4123 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->name));
1191 4123 : if (r->sid) {
1192 4123 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
1193 : }
1194 : }
1195 8198 : return NDR_ERR_SUCCESS;
1196 : }
1197 :
1198 3814 : static enum ndr_err_code ndr_pull_lsa_DomainInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_DomainInfo *r)
1199 : {
1200 : uint32_t _ptr_sid;
1201 3814 : TALLOC_CTX *_mem_save_sid_0 = NULL;
1202 3814 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1203 3814 : if (ndr_flags & NDR_SCALARS) {
1204 1931 : NDR_CHECK(ndr_pull_align(ndr, 5));
1205 1931 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->name));
1206 1931 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
1207 1931 : if (_ptr_sid) {
1208 1931 : NDR_PULL_ALLOC(ndr, r->sid);
1209 : } else {
1210 0 : r->sid = NULL;
1211 : }
1212 1931 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1213 : }
1214 3814 : if (ndr_flags & NDR_BUFFERS) {
1215 1931 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->name));
1216 1931 : if (r->sid) {
1217 1931 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1218 1931 : NDR_PULL_SET_MEM_CTX(ndr, r->sid, 0);
1219 1931 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
1220 1931 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, 0);
1221 : }
1222 : }
1223 3814 : return NDR_ERR_SUCCESS;
1224 : }
1225 :
1226 678 : _PUBLIC_ void ndr_print_lsa_DomainInfo(struct ndr_print *ndr, const char *name, const struct lsa_DomainInfo *r)
1227 : {
1228 678 : ndr_print_struct(ndr, name, "lsa_DomainInfo");
1229 678 : if (r == NULL) { ndr_print_null(ndr); return; }
1230 678 : ndr->depth++;
1231 678 : ndr_print_lsa_StringLarge(ndr, "name", &r->name);
1232 678 : ndr_print_ptr(ndr, "sid", r->sid);
1233 678 : ndr->depth++;
1234 678 : if (r->sid) {
1235 678 : ndr_print_dom_sid2(ndr, "sid", r->sid);
1236 : }
1237 678 : ndr->depth--;
1238 678 : ndr->depth--;
1239 : }
1240 :
1241 40 : static enum ndr_err_code ndr_push_lsa_PDAccountInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_PDAccountInfo *r)
1242 : {
1243 40 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1244 40 : if (ndr_flags & NDR_SCALARS) {
1245 20 : NDR_CHECK(ndr_push_align(ndr, 5));
1246 20 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
1247 20 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1248 : }
1249 40 : if (ndr_flags & NDR_BUFFERS) {
1250 20 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
1251 : }
1252 40 : return NDR_ERR_SUCCESS;
1253 : }
1254 :
1255 32 : static enum ndr_err_code ndr_pull_lsa_PDAccountInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_PDAccountInfo *r)
1256 : {
1257 32 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1258 32 : if (ndr_flags & NDR_SCALARS) {
1259 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
1260 16 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
1261 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1262 : }
1263 32 : if (ndr_flags & NDR_BUFFERS) {
1264 16 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
1265 : }
1266 32 : return NDR_ERR_SUCCESS;
1267 : }
1268 :
1269 8 : _PUBLIC_ void ndr_print_lsa_PDAccountInfo(struct ndr_print *ndr, const char *name, const struct lsa_PDAccountInfo *r)
1270 : {
1271 8 : ndr_print_struct(ndr, name, "lsa_PDAccountInfo");
1272 8 : if (r == NULL) { ndr_print_null(ndr); return; }
1273 8 : ndr->depth++;
1274 8 : ndr_print_lsa_String(ndr, "name", &r->name);
1275 8 : ndr->depth--;
1276 : }
1277 :
1278 20 : static enum ndr_err_code ndr_push_lsa_Role(struct ndr_push *ndr, int ndr_flags, enum lsa_Role r)
1279 : {
1280 20 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
1281 20 : return NDR_ERR_SUCCESS;
1282 : }
1283 :
1284 16 : static enum ndr_err_code ndr_pull_lsa_Role(struct ndr_pull *ndr, int ndr_flags, enum lsa_Role *r)
1285 : {
1286 : uint32_t v;
1287 16 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
1288 16 : *r = v;
1289 16 : return NDR_ERR_SUCCESS;
1290 : }
1291 :
1292 8 : _PUBLIC_ void ndr_print_lsa_Role(struct ndr_print *ndr, const char *name, enum lsa_Role r)
1293 : {
1294 8 : const char *val = NULL;
1295 :
1296 8 : switch (r) {
1297 0 : case LSA_ROLE_BACKUP: val = "LSA_ROLE_BACKUP"; break;
1298 8 : case LSA_ROLE_PRIMARY: val = "LSA_ROLE_PRIMARY"; break;
1299 : }
1300 8 : ndr_print_enum(ndr, name, "ENUM", val, r);
1301 8 : }
1302 :
1303 20 : static enum ndr_err_code ndr_push_lsa_ServerRole(struct ndr_push *ndr, int ndr_flags, const struct lsa_ServerRole *r)
1304 : {
1305 20 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1306 20 : if (ndr_flags & NDR_SCALARS) {
1307 20 : NDR_CHECK(ndr_push_align(ndr, 4));
1308 20 : NDR_CHECK(ndr_push_lsa_Role(ndr, NDR_SCALARS, r->role));
1309 20 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
1310 : }
1311 20 : if (ndr_flags & NDR_BUFFERS) {
1312 : }
1313 20 : return NDR_ERR_SUCCESS;
1314 : }
1315 :
1316 16 : static enum ndr_err_code ndr_pull_lsa_ServerRole(struct ndr_pull *ndr, int ndr_flags, struct lsa_ServerRole *r)
1317 : {
1318 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1319 16 : if (ndr_flags & NDR_SCALARS) {
1320 16 : NDR_CHECK(ndr_pull_align(ndr, 4));
1321 16 : NDR_CHECK(ndr_pull_lsa_Role(ndr, NDR_SCALARS, &r->role));
1322 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
1323 : }
1324 16 : if (ndr_flags & NDR_BUFFERS) {
1325 : }
1326 16 : return NDR_ERR_SUCCESS;
1327 : }
1328 :
1329 8 : _PUBLIC_ void ndr_print_lsa_ServerRole(struct ndr_print *ndr, const char *name, const struct lsa_ServerRole *r)
1330 : {
1331 8 : ndr_print_struct(ndr, name, "lsa_ServerRole");
1332 8 : if (r == NULL) { ndr_print_null(ndr); return; }
1333 8 : ndr->depth++;
1334 8 : ndr_print_lsa_Role(ndr, "role", r->role);
1335 8 : ndr->depth--;
1336 : }
1337 :
1338 40 : static enum ndr_err_code ndr_push_lsa_ReplicaSourceInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_ReplicaSourceInfo *r)
1339 : {
1340 40 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1341 40 : if (ndr_flags & NDR_SCALARS) {
1342 20 : NDR_CHECK(ndr_push_align(ndr, 5));
1343 20 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->source));
1344 20 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account));
1345 20 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1346 : }
1347 40 : if (ndr_flags & NDR_BUFFERS) {
1348 20 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->source));
1349 20 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account));
1350 : }
1351 40 : return NDR_ERR_SUCCESS;
1352 : }
1353 :
1354 32 : static enum ndr_err_code ndr_pull_lsa_ReplicaSourceInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_ReplicaSourceInfo *r)
1355 : {
1356 32 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1357 32 : if (ndr_flags & NDR_SCALARS) {
1358 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
1359 16 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->source));
1360 16 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account));
1361 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1362 : }
1363 32 : if (ndr_flags & NDR_BUFFERS) {
1364 16 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->source));
1365 16 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account));
1366 : }
1367 32 : return NDR_ERR_SUCCESS;
1368 : }
1369 :
1370 8 : _PUBLIC_ void ndr_print_lsa_ReplicaSourceInfo(struct ndr_print *ndr, const char *name, const struct lsa_ReplicaSourceInfo *r)
1371 : {
1372 8 : ndr_print_struct(ndr, name, "lsa_ReplicaSourceInfo");
1373 8 : if (r == NULL) { ndr_print_null(ndr); return; }
1374 8 : ndr->depth++;
1375 8 : ndr_print_lsa_String(ndr, "source", &r->source);
1376 8 : ndr_print_lsa_String(ndr, "account", &r->account);
1377 8 : ndr->depth--;
1378 : }
1379 :
1380 20 : static enum ndr_err_code ndr_push_lsa_DefaultQuotaInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_DefaultQuotaInfo *r)
1381 : {
1382 20 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1383 20 : if (ndr_flags & NDR_SCALARS) {
1384 20 : NDR_CHECK(ndr_push_align(ndr, 8));
1385 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->paged_pool));
1386 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->non_paged_pool));
1387 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->min_wss));
1388 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->max_wss));
1389 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->pagefile));
1390 20 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->unknown));
1391 20 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
1392 : }
1393 20 : if (ndr_flags & NDR_BUFFERS) {
1394 : }
1395 20 : return NDR_ERR_SUCCESS;
1396 : }
1397 :
1398 16 : static enum ndr_err_code ndr_pull_lsa_DefaultQuotaInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_DefaultQuotaInfo *r)
1399 : {
1400 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1401 16 : if (ndr_flags & NDR_SCALARS) {
1402 16 : NDR_CHECK(ndr_pull_align(ndr, 8));
1403 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->paged_pool));
1404 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->non_paged_pool));
1405 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->min_wss));
1406 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->max_wss));
1407 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->pagefile));
1408 16 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->unknown));
1409 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
1410 : }
1411 16 : if (ndr_flags & NDR_BUFFERS) {
1412 : }
1413 16 : return NDR_ERR_SUCCESS;
1414 : }
1415 :
1416 8 : _PUBLIC_ void ndr_print_lsa_DefaultQuotaInfo(struct ndr_print *ndr, const char *name, const struct lsa_DefaultQuotaInfo *r)
1417 : {
1418 8 : ndr_print_struct(ndr, name, "lsa_DefaultQuotaInfo");
1419 8 : if (r == NULL) { ndr_print_null(ndr); return; }
1420 8 : ndr->depth++;
1421 8 : ndr_print_uint32(ndr, "paged_pool", r->paged_pool);
1422 8 : ndr_print_uint32(ndr, "non_paged_pool", r->non_paged_pool);
1423 8 : ndr_print_uint32(ndr, "min_wss", r->min_wss);
1424 8 : ndr_print_uint32(ndr, "max_wss", r->max_wss);
1425 8 : ndr_print_uint32(ndr, "pagefile", r->pagefile);
1426 8 : ndr_print_hyper(ndr, "unknown", r->unknown);
1427 8 : ndr->depth--;
1428 : }
1429 :
1430 0 : static enum ndr_err_code ndr_push_lsa_ModificationInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_ModificationInfo *r)
1431 : {
1432 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1433 0 : if (ndr_flags & NDR_SCALARS) {
1434 0 : NDR_CHECK(ndr_push_align(ndr, 8));
1435 0 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->modified_id));
1436 0 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, r->db_create_time));
1437 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
1438 : }
1439 0 : if (ndr_flags & NDR_BUFFERS) {
1440 : }
1441 0 : return NDR_ERR_SUCCESS;
1442 : }
1443 :
1444 0 : static enum ndr_err_code ndr_pull_lsa_ModificationInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_ModificationInfo *r)
1445 : {
1446 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1447 0 : if (ndr_flags & NDR_SCALARS) {
1448 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
1449 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->modified_id));
1450 0 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, &r->db_create_time));
1451 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
1452 : }
1453 0 : if (ndr_flags & NDR_BUFFERS) {
1454 : }
1455 0 : return NDR_ERR_SUCCESS;
1456 : }
1457 :
1458 0 : _PUBLIC_ void ndr_print_lsa_ModificationInfo(struct ndr_print *ndr, const char *name, const struct lsa_ModificationInfo *r)
1459 : {
1460 0 : ndr_print_struct(ndr, name, "lsa_ModificationInfo");
1461 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1462 0 : ndr->depth++;
1463 0 : ndr_print_hyper(ndr, "modified_id", r->modified_id);
1464 0 : ndr_print_NTTIME_hyper(ndr, "db_create_time", r->db_create_time);
1465 0 : ndr->depth--;
1466 : }
1467 :
1468 0 : static enum ndr_err_code ndr_push_lsa_AuditFullSetInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_AuditFullSetInfo *r)
1469 : {
1470 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1471 0 : if (ndr_flags & NDR_SCALARS) {
1472 0 : NDR_CHECK(ndr_push_align(ndr, 1));
1473 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->shutdown_on_full));
1474 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
1475 : }
1476 0 : if (ndr_flags & NDR_BUFFERS) {
1477 : }
1478 0 : return NDR_ERR_SUCCESS;
1479 : }
1480 :
1481 0 : static enum ndr_err_code ndr_pull_lsa_AuditFullSetInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_AuditFullSetInfo *r)
1482 : {
1483 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1484 0 : if (ndr_flags & NDR_SCALARS) {
1485 0 : NDR_CHECK(ndr_pull_align(ndr, 1));
1486 0 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->shutdown_on_full));
1487 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
1488 : }
1489 0 : if (ndr_flags & NDR_BUFFERS) {
1490 : }
1491 0 : return NDR_ERR_SUCCESS;
1492 : }
1493 :
1494 0 : _PUBLIC_ void ndr_print_lsa_AuditFullSetInfo(struct ndr_print *ndr, const char *name, const struct lsa_AuditFullSetInfo *r)
1495 : {
1496 0 : ndr_print_struct(ndr, name, "lsa_AuditFullSetInfo");
1497 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1498 0 : ndr->depth++;
1499 0 : ndr_print_uint8(ndr, "shutdown_on_full", r->shutdown_on_full);
1500 0 : ndr->depth--;
1501 : }
1502 :
1503 0 : static enum ndr_err_code ndr_push_lsa_AuditFullQueryInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_AuditFullQueryInfo *r)
1504 : {
1505 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1506 0 : if (ndr_flags & NDR_SCALARS) {
1507 0 : NDR_CHECK(ndr_push_align(ndr, 1));
1508 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->shutdown_on_full));
1509 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->log_is_full));
1510 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
1511 : }
1512 0 : if (ndr_flags & NDR_BUFFERS) {
1513 : }
1514 0 : return NDR_ERR_SUCCESS;
1515 : }
1516 :
1517 0 : static enum ndr_err_code ndr_pull_lsa_AuditFullQueryInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_AuditFullQueryInfo *r)
1518 : {
1519 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1520 0 : if (ndr_flags & NDR_SCALARS) {
1521 0 : NDR_CHECK(ndr_pull_align(ndr, 1));
1522 0 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->shutdown_on_full));
1523 0 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->log_is_full));
1524 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
1525 : }
1526 0 : if (ndr_flags & NDR_BUFFERS) {
1527 : }
1528 0 : return NDR_ERR_SUCCESS;
1529 : }
1530 :
1531 0 : _PUBLIC_ void ndr_print_lsa_AuditFullQueryInfo(struct ndr_print *ndr, const char *name, const struct lsa_AuditFullQueryInfo *r)
1532 : {
1533 0 : ndr_print_struct(ndr, name, "lsa_AuditFullQueryInfo");
1534 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1535 0 : ndr->depth++;
1536 0 : ndr_print_uint8(ndr, "shutdown_on_full", r->shutdown_on_full);
1537 0 : ndr_print_uint8(ndr, "log_is_full", r->log_is_full);
1538 0 : ndr->depth--;
1539 : }
1540 :
1541 1510 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_DnsDomainInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_DnsDomainInfo *r)
1542 : {
1543 1510 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1544 1510 : if (ndr_flags & NDR_SCALARS) {
1545 755 : NDR_CHECK(ndr_push_align(ndr, 5));
1546 755 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->name));
1547 755 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->dns_domain));
1548 755 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->dns_forest));
1549 755 : NDR_CHECK(ndr_push_GUID(ndr, NDR_SCALARS, &r->domain_guid));
1550 755 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sid));
1551 755 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1552 : }
1553 1510 : if (ndr_flags & NDR_BUFFERS) {
1554 755 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->name));
1555 755 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->dns_domain));
1556 755 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->dns_forest));
1557 755 : if (r->sid) {
1558 755 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
1559 : }
1560 : }
1561 1510 : return NDR_ERR_SUCCESS;
1562 : }
1563 :
1564 7894 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_DnsDomainInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_DnsDomainInfo *r)
1565 : {
1566 : uint32_t _ptr_sid;
1567 7894 : TALLOC_CTX *_mem_save_sid_0 = NULL;
1568 7894 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1569 7894 : if (ndr_flags & NDR_SCALARS) {
1570 3947 : NDR_CHECK(ndr_pull_align(ndr, 5));
1571 3947 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->name));
1572 3947 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->dns_domain));
1573 3947 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->dns_forest));
1574 3947 : NDR_CHECK(ndr_pull_GUID(ndr, NDR_SCALARS, &r->domain_guid));
1575 3947 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
1576 3947 : if (_ptr_sid) {
1577 3947 : NDR_PULL_ALLOC(ndr, r->sid);
1578 : } else {
1579 0 : r->sid = NULL;
1580 : }
1581 3947 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1582 : }
1583 7894 : if (ndr_flags & NDR_BUFFERS) {
1584 3947 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->name));
1585 3947 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->dns_domain));
1586 3947 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->dns_forest));
1587 3947 : if (r->sid) {
1588 3947 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1589 3947 : NDR_PULL_SET_MEM_CTX(ndr, r->sid, 0);
1590 3947 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
1591 3947 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, 0);
1592 : }
1593 : }
1594 7894 : return NDR_ERR_SUCCESS;
1595 : }
1596 :
1597 0 : static void ndr_print_flags_lsa_DnsDomainInfo(struct ndr_print *ndr, const char *name, int unused, const struct lsa_DnsDomainInfo *r)
1598 : {
1599 0 : ndr_print_lsa_DnsDomainInfo(ndr, name, r);
1600 0 : }
1601 :
1602 155 : _PUBLIC_ void ndr_print_lsa_DnsDomainInfo(struct ndr_print *ndr, const char *name, const struct lsa_DnsDomainInfo *r)
1603 : {
1604 155 : ndr_print_struct(ndr, name, "lsa_DnsDomainInfo");
1605 155 : if (r == NULL) { ndr_print_null(ndr); return; }
1606 155 : ndr->depth++;
1607 155 : ndr_print_lsa_StringLarge(ndr, "name", &r->name);
1608 155 : ndr_print_lsa_StringLarge(ndr, "dns_domain", &r->dns_domain);
1609 155 : ndr_print_lsa_StringLarge(ndr, "dns_forest", &r->dns_forest);
1610 155 : ndr_print_GUID(ndr, "domain_guid", &r->domain_guid);
1611 155 : ndr_print_ptr(ndr, "sid", r->sid);
1612 155 : ndr->depth++;
1613 155 : if (r->sid) {
1614 155 : ndr_print_dom_sid2(ndr, "sid", r->sid);
1615 : }
1616 155 : ndr->depth--;
1617 155 : ndr->depth--;
1618 : }
1619 :
1620 1300 : static enum ndr_err_code ndr_push_lsa_PolicyInfo(struct ndr_push *ndr, int ndr_flags, enum lsa_PolicyInfo r)
1621 : {
1622 1300 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
1623 1300 : return NDR_ERR_SUCCESS;
1624 : }
1625 :
1626 1362 : static enum ndr_err_code ndr_pull_lsa_PolicyInfo(struct ndr_pull *ndr, int ndr_flags, enum lsa_PolicyInfo *r)
1627 : {
1628 : uint16_t v;
1629 1362 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
1630 1362 : *r = v;
1631 1362 : return NDR_ERR_SUCCESS;
1632 : }
1633 :
1634 0 : _PUBLIC_ void ndr_print_lsa_PolicyInfo(struct ndr_print *ndr, const char *name, enum lsa_PolicyInfo r)
1635 : {
1636 0 : const char *val = NULL;
1637 :
1638 0 : switch (r) {
1639 0 : case LSA_POLICY_INFO_AUDIT_LOG: val = "LSA_POLICY_INFO_AUDIT_LOG"; break;
1640 0 : case LSA_POLICY_INFO_AUDIT_EVENTS: val = "LSA_POLICY_INFO_AUDIT_EVENTS"; break;
1641 0 : case LSA_POLICY_INFO_DOMAIN: val = "LSA_POLICY_INFO_DOMAIN"; break;
1642 0 : case LSA_POLICY_INFO_PD: val = "LSA_POLICY_INFO_PD"; break;
1643 0 : case LSA_POLICY_INFO_ACCOUNT_DOMAIN: val = "LSA_POLICY_INFO_ACCOUNT_DOMAIN"; break;
1644 0 : case LSA_POLICY_INFO_ROLE: val = "LSA_POLICY_INFO_ROLE"; break;
1645 0 : case LSA_POLICY_INFO_REPLICA: val = "LSA_POLICY_INFO_REPLICA"; break;
1646 0 : case LSA_POLICY_INFO_QUOTA: val = "LSA_POLICY_INFO_QUOTA"; break;
1647 0 : case LSA_POLICY_INFO_MOD: val = "LSA_POLICY_INFO_MOD"; break;
1648 0 : case LSA_POLICY_INFO_AUDIT_FULL_SET: val = "LSA_POLICY_INFO_AUDIT_FULL_SET"; break;
1649 0 : case LSA_POLICY_INFO_AUDIT_FULL_QUERY: val = "LSA_POLICY_INFO_AUDIT_FULL_QUERY"; break;
1650 0 : case LSA_POLICY_INFO_DNS: val = "LSA_POLICY_INFO_DNS"; break;
1651 0 : case LSA_POLICY_INFO_DNS_INT: val = "LSA_POLICY_INFO_DNS_INT"; break;
1652 0 : case LSA_POLICY_INFO_L_ACCOUNT_DOMAIN: val = "LSA_POLICY_INFO_L_ACCOUNT_DOMAIN"; break;
1653 : }
1654 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
1655 0 : }
1656 :
1657 1478 : static enum ndr_err_code ndr_push_lsa_PolicyInformation(struct ndr_push *ndr, int ndr_flags, const union lsa_PolicyInformation *r)
1658 : {
1659 : uint32_t level;
1660 1478 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1661 1478 : if (ndr_flags & NDR_SCALARS) {
1662 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1663 1478 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1664 1478 : NDR_CHECK(ndr_push_union_align(ndr, 8));
1665 1478 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
1666 1478 : NDR_CHECK(ndr_push_union_align(ndr, 8));
1667 1478 : switch (level) {
1668 20 : case LSA_POLICY_INFO_AUDIT_LOG: {
1669 20 : NDR_CHECK(ndr_push_lsa_AuditLogInfo(ndr, NDR_SCALARS, &r->audit_log));
1670 20 : break; }
1671 :
1672 20 : case LSA_POLICY_INFO_AUDIT_EVENTS: {
1673 20 : NDR_CHECK(ndr_push_lsa_AuditEventsInfo(ndr, NDR_SCALARS, &r->audit_events));
1674 20 : break; }
1675 :
1676 437 : case LSA_POLICY_INFO_DOMAIN: {
1677 437 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_SCALARS, &r->domain));
1678 437 : break; }
1679 :
1680 20 : case LSA_POLICY_INFO_PD: {
1681 20 : NDR_CHECK(ndr_push_lsa_PDAccountInfo(ndr, NDR_SCALARS, &r->pd));
1682 20 : break; }
1683 :
1684 177 : case LSA_POLICY_INFO_ACCOUNT_DOMAIN: {
1685 177 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_SCALARS, &r->account_domain));
1686 177 : break; }
1687 :
1688 20 : case LSA_POLICY_INFO_ROLE: {
1689 20 : NDR_CHECK(ndr_push_lsa_ServerRole(ndr, NDR_SCALARS, &r->role));
1690 20 : break; }
1691 :
1692 20 : case LSA_POLICY_INFO_REPLICA: {
1693 20 : NDR_CHECK(ndr_push_lsa_ReplicaSourceInfo(ndr, NDR_SCALARS, &r->replica));
1694 20 : break; }
1695 :
1696 20 : case LSA_POLICY_INFO_QUOTA: {
1697 20 : NDR_CHECK(ndr_push_lsa_DefaultQuotaInfo(ndr, NDR_SCALARS, &r->quota));
1698 20 : break; }
1699 :
1700 0 : case LSA_POLICY_INFO_MOD: {
1701 0 : NDR_CHECK(ndr_push_lsa_ModificationInfo(ndr, NDR_SCALARS, &r->mod));
1702 0 : break; }
1703 :
1704 0 : case LSA_POLICY_INFO_AUDIT_FULL_SET: {
1705 0 : NDR_CHECK(ndr_push_lsa_AuditFullSetInfo(ndr, NDR_SCALARS, &r->auditfullset));
1706 0 : break; }
1707 :
1708 0 : case LSA_POLICY_INFO_AUDIT_FULL_QUERY: {
1709 0 : NDR_CHECK(ndr_push_lsa_AuditFullQueryInfo(ndr, NDR_SCALARS, &r->auditfullquery));
1710 0 : break; }
1711 :
1712 704 : case LSA_POLICY_INFO_DNS: {
1713 704 : NDR_CHECK(ndr_push_lsa_DnsDomainInfo(ndr, NDR_SCALARS, &r->dns));
1714 704 : break; }
1715 :
1716 20 : case LSA_POLICY_INFO_DNS_INT: {
1717 20 : NDR_CHECK(ndr_push_lsa_DnsDomainInfo(ndr, NDR_SCALARS, &r->dns));
1718 20 : break; }
1719 :
1720 20 : case LSA_POLICY_INFO_L_ACCOUNT_DOMAIN: {
1721 20 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_SCALARS, &r->l_account_domain));
1722 20 : break; }
1723 :
1724 0 : default:
1725 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
1726 : }
1727 0 : }
1728 1478 : if (ndr_flags & NDR_BUFFERS) {
1729 1478 : if (!(ndr_flags & NDR_SCALARS)) {
1730 : /* We didn't get it above, and the token is not needed after this. */
1731 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1732 : }
1733 1478 : switch (level) {
1734 20 : case LSA_POLICY_INFO_AUDIT_LOG:
1735 20 : break;
1736 :
1737 20 : case LSA_POLICY_INFO_AUDIT_EVENTS:
1738 20 : NDR_CHECK(ndr_push_lsa_AuditEventsInfo(ndr, NDR_BUFFERS, &r->audit_events));
1739 20 : break;
1740 :
1741 437 : case LSA_POLICY_INFO_DOMAIN:
1742 437 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->domain));
1743 437 : break;
1744 :
1745 20 : case LSA_POLICY_INFO_PD:
1746 20 : NDR_CHECK(ndr_push_lsa_PDAccountInfo(ndr, NDR_BUFFERS, &r->pd));
1747 20 : break;
1748 :
1749 177 : case LSA_POLICY_INFO_ACCOUNT_DOMAIN:
1750 177 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->account_domain));
1751 177 : break;
1752 :
1753 20 : case LSA_POLICY_INFO_ROLE:
1754 20 : break;
1755 :
1756 20 : case LSA_POLICY_INFO_REPLICA:
1757 20 : NDR_CHECK(ndr_push_lsa_ReplicaSourceInfo(ndr, NDR_BUFFERS, &r->replica));
1758 20 : break;
1759 :
1760 20 : case LSA_POLICY_INFO_QUOTA:
1761 20 : break;
1762 :
1763 0 : case LSA_POLICY_INFO_MOD:
1764 0 : break;
1765 :
1766 0 : case LSA_POLICY_INFO_AUDIT_FULL_SET:
1767 0 : break;
1768 :
1769 0 : case LSA_POLICY_INFO_AUDIT_FULL_QUERY:
1770 0 : break;
1771 :
1772 704 : case LSA_POLICY_INFO_DNS:
1773 704 : NDR_CHECK(ndr_push_lsa_DnsDomainInfo(ndr, NDR_BUFFERS, &r->dns));
1774 704 : break;
1775 :
1776 20 : case LSA_POLICY_INFO_DNS_INT:
1777 20 : NDR_CHECK(ndr_push_lsa_DnsDomainInfo(ndr, NDR_BUFFERS, &r->dns));
1778 20 : break;
1779 :
1780 20 : case LSA_POLICY_INFO_L_ACCOUNT_DOMAIN:
1781 20 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->l_account_domain));
1782 20 : break;
1783 :
1784 0 : default:
1785 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
1786 : }
1787 0 : }
1788 1478 : return NDR_ERR_SUCCESS;
1789 : }
1790 :
1791 1250 : static enum ndr_err_code ndr_pull_lsa_PolicyInformation(struct ndr_pull *ndr, int ndr_flags, union lsa_PolicyInformation *r)
1792 : {
1793 : uint32_t level;
1794 : uint16_t _level;
1795 1250 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1796 1250 : if (ndr_flags & NDR_SCALARS) {
1797 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1798 1250 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1799 1250 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
1800 1250 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
1801 1250 : if (_level != level) {
1802 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r at %s", _level, __location__);
1803 : }
1804 1250 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
1805 1250 : switch (level) {
1806 16 : case LSA_POLICY_INFO_AUDIT_LOG: {
1807 16 : NDR_CHECK(ndr_pull_lsa_AuditLogInfo(ndr, NDR_SCALARS, &r->audit_log));
1808 16 : break; }
1809 :
1810 16 : case LSA_POLICY_INFO_AUDIT_EVENTS: {
1811 16 : NDR_CHECK(ndr_pull_lsa_AuditEventsInfo(ndr, NDR_SCALARS, &r->audit_events));
1812 16 : break; }
1813 :
1814 365 : case LSA_POLICY_INFO_DOMAIN: {
1815 365 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_SCALARS, &r->domain));
1816 365 : break; }
1817 :
1818 16 : case LSA_POLICY_INFO_PD: {
1819 16 : NDR_CHECK(ndr_pull_lsa_PDAccountInfo(ndr, NDR_SCALARS, &r->pd));
1820 16 : break; }
1821 :
1822 158 : case LSA_POLICY_INFO_ACCOUNT_DOMAIN: {
1823 158 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_SCALARS, &r->account_domain));
1824 158 : break; }
1825 :
1826 16 : case LSA_POLICY_INFO_ROLE: {
1827 16 : NDR_CHECK(ndr_pull_lsa_ServerRole(ndr, NDR_SCALARS, &r->role));
1828 16 : break; }
1829 :
1830 16 : case LSA_POLICY_INFO_REPLICA: {
1831 16 : NDR_CHECK(ndr_pull_lsa_ReplicaSourceInfo(ndr, NDR_SCALARS, &r->replica));
1832 16 : break; }
1833 :
1834 16 : case LSA_POLICY_INFO_QUOTA: {
1835 16 : NDR_CHECK(ndr_pull_lsa_DefaultQuotaInfo(ndr, NDR_SCALARS, &r->quota));
1836 16 : break; }
1837 :
1838 0 : case LSA_POLICY_INFO_MOD: {
1839 0 : NDR_CHECK(ndr_pull_lsa_ModificationInfo(ndr, NDR_SCALARS, &r->mod));
1840 0 : break; }
1841 :
1842 0 : case LSA_POLICY_INFO_AUDIT_FULL_SET: {
1843 0 : NDR_CHECK(ndr_pull_lsa_AuditFullSetInfo(ndr, NDR_SCALARS, &r->auditfullset));
1844 0 : break; }
1845 :
1846 0 : case LSA_POLICY_INFO_AUDIT_FULL_QUERY: {
1847 0 : NDR_CHECK(ndr_pull_lsa_AuditFullQueryInfo(ndr, NDR_SCALARS, &r->auditfullquery));
1848 0 : break; }
1849 :
1850 599 : case LSA_POLICY_INFO_DNS: {
1851 599 : NDR_CHECK(ndr_pull_lsa_DnsDomainInfo(ndr, NDR_SCALARS, &r->dns));
1852 599 : break; }
1853 :
1854 16 : case LSA_POLICY_INFO_DNS_INT: {
1855 16 : NDR_CHECK(ndr_pull_lsa_DnsDomainInfo(ndr, NDR_SCALARS, &r->dns));
1856 16 : break; }
1857 :
1858 16 : case LSA_POLICY_INFO_L_ACCOUNT_DOMAIN: {
1859 16 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_SCALARS, &r->l_account_domain));
1860 16 : break; }
1861 :
1862 0 : default:
1863 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
1864 : }
1865 0 : }
1866 1250 : if (ndr_flags & NDR_BUFFERS) {
1867 1250 : if (!(ndr_flags & NDR_SCALARS)) {
1868 : /* We didn't get it above, and the token is not needed after this. */
1869 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1870 : }
1871 1250 : switch (level) {
1872 16 : case LSA_POLICY_INFO_AUDIT_LOG:
1873 16 : break;
1874 :
1875 16 : case LSA_POLICY_INFO_AUDIT_EVENTS:
1876 16 : NDR_CHECK(ndr_pull_lsa_AuditEventsInfo(ndr, NDR_BUFFERS, &r->audit_events));
1877 16 : break;
1878 :
1879 365 : case LSA_POLICY_INFO_DOMAIN:
1880 365 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->domain));
1881 365 : break;
1882 :
1883 16 : case LSA_POLICY_INFO_PD:
1884 16 : NDR_CHECK(ndr_pull_lsa_PDAccountInfo(ndr, NDR_BUFFERS, &r->pd));
1885 16 : break;
1886 :
1887 158 : case LSA_POLICY_INFO_ACCOUNT_DOMAIN:
1888 158 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->account_domain));
1889 158 : break;
1890 :
1891 16 : case LSA_POLICY_INFO_ROLE:
1892 16 : break;
1893 :
1894 16 : case LSA_POLICY_INFO_REPLICA:
1895 16 : NDR_CHECK(ndr_pull_lsa_ReplicaSourceInfo(ndr, NDR_BUFFERS, &r->replica));
1896 16 : break;
1897 :
1898 16 : case LSA_POLICY_INFO_QUOTA:
1899 16 : break;
1900 :
1901 0 : case LSA_POLICY_INFO_MOD:
1902 0 : break;
1903 :
1904 0 : case LSA_POLICY_INFO_AUDIT_FULL_SET:
1905 0 : break;
1906 :
1907 0 : case LSA_POLICY_INFO_AUDIT_FULL_QUERY:
1908 0 : break;
1909 :
1910 599 : case LSA_POLICY_INFO_DNS:
1911 599 : NDR_CHECK(ndr_pull_lsa_DnsDomainInfo(ndr, NDR_BUFFERS, &r->dns));
1912 599 : break;
1913 :
1914 16 : case LSA_POLICY_INFO_DNS_INT:
1915 16 : NDR_CHECK(ndr_pull_lsa_DnsDomainInfo(ndr, NDR_BUFFERS, &r->dns));
1916 16 : break;
1917 :
1918 16 : case LSA_POLICY_INFO_L_ACCOUNT_DOMAIN:
1919 16 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->l_account_domain));
1920 16 : break;
1921 :
1922 0 : default:
1923 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
1924 : }
1925 0 : }
1926 1250 : return NDR_ERR_SUCCESS;
1927 : }
1928 :
1929 362 : _PUBLIC_ void ndr_print_lsa_PolicyInformation(struct ndr_print *ndr, const char *name, const union lsa_PolicyInformation *r)
1930 : {
1931 : uint32_t level;
1932 362 : level = ndr_print_steal_switch_value(ndr, r);
1933 362 : ndr_print_union(ndr, name, level, "lsa_PolicyInformation");
1934 362 : switch (level) {
1935 8 : case LSA_POLICY_INFO_AUDIT_LOG:
1936 8 : ndr_print_lsa_AuditLogInfo(ndr, "audit_log", &r->audit_log);
1937 8 : break;
1938 :
1939 8 : case LSA_POLICY_INFO_AUDIT_EVENTS:
1940 8 : ndr_print_lsa_AuditEventsInfo(ndr, "audit_events", &r->audit_events);
1941 8 : break;
1942 :
1943 144 : case LSA_POLICY_INFO_DOMAIN:
1944 144 : ndr_print_lsa_DomainInfo(ndr, "domain", &r->domain);
1945 144 : break;
1946 :
1947 8 : case LSA_POLICY_INFO_PD:
1948 8 : ndr_print_lsa_PDAccountInfo(ndr, "pd", &r->pd);
1949 8 : break;
1950 :
1951 8 : case LSA_POLICY_INFO_ACCOUNT_DOMAIN:
1952 8 : ndr_print_lsa_DomainInfo(ndr, "account_domain", &r->account_domain);
1953 8 : break;
1954 :
1955 8 : case LSA_POLICY_INFO_ROLE:
1956 8 : ndr_print_lsa_ServerRole(ndr, "role", &r->role);
1957 8 : break;
1958 :
1959 8 : case LSA_POLICY_INFO_REPLICA:
1960 8 : ndr_print_lsa_ReplicaSourceInfo(ndr, "replica", &r->replica);
1961 8 : break;
1962 :
1963 8 : case LSA_POLICY_INFO_QUOTA:
1964 8 : ndr_print_lsa_DefaultQuotaInfo(ndr, "quota", &r->quota);
1965 8 : break;
1966 :
1967 0 : case LSA_POLICY_INFO_MOD:
1968 0 : ndr_print_lsa_ModificationInfo(ndr, "mod", &r->mod);
1969 0 : break;
1970 :
1971 0 : case LSA_POLICY_INFO_AUDIT_FULL_SET:
1972 0 : ndr_print_lsa_AuditFullSetInfo(ndr, "auditfullset", &r->auditfullset);
1973 0 : break;
1974 :
1975 0 : case LSA_POLICY_INFO_AUDIT_FULL_QUERY:
1976 0 : ndr_print_lsa_AuditFullQueryInfo(ndr, "auditfullquery", &r->auditfullquery);
1977 0 : break;
1978 :
1979 146 : case LSA_POLICY_INFO_DNS:
1980 146 : ndr_print_lsa_DnsDomainInfo(ndr, "dns", &r->dns);
1981 146 : break;
1982 :
1983 8 : case LSA_POLICY_INFO_DNS_INT:
1984 8 : ndr_print_lsa_DnsDomainInfo(ndr, "dns", &r->dns);
1985 8 : break;
1986 :
1987 8 : case LSA_POLICY_INFO_L_ACCOUNT_DOMAIN:
1988 8 : ndr_print_lsa_DomainInfo(ndr, "l_account_domain", &r->l_account_domain);
1989 8 : break;
1990 :
1991 0 : default:
1992 0 : ndr_print_bad_level(ndr, name, level);
1993 : }
1994 362 : }
1995 :
1996 34372 : static enum ndr_err_code ndr_push_lsa_SidPtr(struct ndr_push *ndr, int ndr_flags, const struct lsa_SidPtr *r)
1997 : {
1998 34372 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1999 34372 : if (ndr_flags & NDR_SCALARS) {
2000 17186 : NDR_CHECK(ndr_push_align(ndr, 5));
2001 17186 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sid));
2002 17186 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2003 : }
2004 34372 : if (ndr_flags & NDR_BUFFERS) {
2005 17186 : if (r->sid) {
2006 17186 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
2007 : }
2008 : }
2009 34372 : return NDR_ERR_SUCCESS;
2010 : }
2011 :
2012 37024 : static enum ndr_err_code ndr_pull_lsa_SidPtr(struct ndr_pull *ndr, int ndr_flags, struct lsa_SidPtr *r)
2013 : {
2014 : uint32_t _ptr_sid;
2015 37024 : TALLOC_CTX *_mem_save_sid_0 = NULL;
2016 37024 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2017 37024 : if (ndr_flags & NDR_SCALARS) {
2018 18512 : NDR_CHECK(ndr_pull_align(ndr, 5));
2019 18512 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
2020 18512 : if (_ptr_sid) {
2021 18512 : NDR_PULL_ALLOC(ndr, r->sid);
2022 : } else {
2023 0 : r->sid = NULL;
2024 : }
2025 18512 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2026 : }
2027 37024 : if (ndr_flags & NDR_BUFFERS) {
2028 18512 : if (r->sid) {
2029 18512 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
2030 18512 : NDR_PULL_SET_MEM_CTX(ndr, r->sid, 0);
2031 18512 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
2032 18512 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, 0);
2033 : }
2034 : }
2035 37024 : return NDR_ERR_SUCCESS;
2036 : }
2037 :
2038 76 : _PUBLIC_ void ndr_print_lsa_SidPtr(struct ndr_print *ndr, const char *name, const struct lsa_SidPtr *r)
2039 : {
2040 76 : ndr_print_struct(ndr, name, "lsa_SidPtr");
2041 76 : if (r == NULL) { ndr_print_null(ndr); return; }
2042 76 : ndr->depth++;
2043 76 : ndr_print_ptr(ndr, "sid", r->sid);
2044 76 : ndr->depth++;
2045 76 : if (r->sid) {
2046 76 : ndr_print_dom_sid2(ndr, "sid", r->sid);
2047 : }
2048 76 : ndr->depth--;
2049 76 : ndr->depth--;
2050 : }
2051 :
2052 1071 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_SidArray(struct ndr_push *ndr, int ndr_flags, const struct lsa_SidArray *r)
2053 : {
2054 : uint32_t cntr_sids_1;
2055 1071 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2056 1071 : if (ndr_flags & NDR_SCALARS) {
2057 1071 : NDR_CHECK(ndr_push_align(ndr, 5));
2058 1071 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_sids));
2059 1071 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sids));
2060 1071 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2061 : }
2062 1071 : if (ndr_flags & NDR_BUFFERS) {
2063 1071 : if (r->sids) {
2064 971 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_sids));
2065 18157 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->num_sids); cntr_sids_1++) {
2066 17186 : NDR_CHECK(ndr_push_lsa_SidPtr(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
2067 : }
2068 18157 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->num_sids); cntr_sids_1++) {
2069 17186 : NDR_CHECK(ndr_push_lsa_SidPtr(ndr, NDR_BUFFERS, &r->sids[cntr_sids_1]));
2070 : }
2071 : }
2072 : }
2073 1071 : return NDR_ERR_SUCCESS;
2074 : }
2075 :
2076 1959 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_SidArray(struct ndr_pull *ndr, int ndr_flags, struct lsa_SidArray *r)
2077 : {
2078 : uint32_t _ptr_sids;
2079 1959 : uint32_t size_sids_1 = 0;
2080 : uint32_t cntr_sids_1;
2081 1959 : TALLOC_CTX *_mem_save_sids_0 = NULL;
2082 1959 : TALLOC_CTX *_mem_save_sids_1 = NULL;
2083 1959 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2084 1959 : if (ndr_flags & NDR_SCALARS) {
2085 1959 : NDR_CHECK(ndr_pull_align(ndr, 5));
2086 1959 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_sids));
2087 1959 : if (r->num_sids > 20480) {
2088 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2089 : }
2090 1959 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sids));
2091 1959 : if (_ptr_sids) {
2092 1864 : NDR_PULL_ALLOC(ndr, r->sids);
2093 : } else {
2094 95 : r->sids = NULL;
2095 : }
2096 1959 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2097 : }
2098 1959 : if (ndr_flags & NDR_BUFFERS) {
2099 1959 : if (r->sids) {
2100 1864 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
2101 1864 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
2102 1864 : NDR_CHECK(ndr_pull_array_size(ndr, &r->sids));
2103 1864 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->sids, &size_sids_1));
2104 1864 : NDR_PULL_ALLOC_N(ndr, r->sids, size_sids_1);
2105 1864 : _mem_save_sids_1 = NDR_PULL_GET_MEM_CTX(ndr);
2106 1864 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
2107 20376 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
2108 18512 : NDR_CHECK(ndr_pull_lsa_SidPtr(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
2109 : }
2110 20376 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
2111 18512 : NDR_CHECK(ndr_pull_lsa_SidPtr(ndr, NDR_BUFFERS, &r->sids[cntr_sids_1]));
2112 : }
2113 1864 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_1, 0);
2114 1864 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, 0);
2115 : }
2116 1959 : if (r->sids) {
2117 1864 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->sids, r->num_sids));
2118 : }
2119 2715 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
2120 : }
2121 : }
2122 1959 : return NDR_ERR_SUCCESS;
2123 : }
2124 :
2125 0 : static void ndr_print_flags_lsa_SidArray(struct ndr_print *ndr, const char *name, int unused, const struct lsa_SidArray *r)
2126 : {
2127 0 : ndr_print_lsa_SidArray(ndr, name, r);
2128 0 : }
2129 :
2130 54 : _PUBLIC_ void ndr_print_lsa_SidArray(struct ndr_print *ndr, const char *name, const struct lsa_SidArray *r)
2131 : {
2132 : uint32_t cntr_sids_1;
2133 54 : ndr_print_struct(ndr, name, "lsa_SidArray");
2134 54 : if (r == NULL) { ndr_print_null(ndr); return; }
2135 54 : ndr->depth++;
2136 54 : ndr_print_uint32(ndr, "num_sids", r->num_sids);
2137 54 : ndr_print_ptr(ndr, "sids", r->sids);
2138 54 : ndr->depth++;
2139 54 : if (r->sids) {
2140 44 : ndr->print(ndr, "%s: ARRAY(%d)", "sids", (int)r->num_sids);
2141 44 : ndr->depth++;
2142 120 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->num_sids); cntr_sids_1++) {
2143 76 : ndr_print_lsa_SidPtr(ndr, "sids", &r->sids[cntr_sids_1]);
2144 : }
2145 44 : ndr->depth--;
2146 : }
2147 54 : ndr->depth--;
2148 54 : ndr->depth--;
2149 : }
2150 :
2151 85 : static enum ndr_err_code ndr_push_lsa_DomainList(struct ndr_push *ndr, int ndr_flags, const struct lsa_DomainList *r)
2152 : {
2153 : uint32_t cntr_domains_1;
2154 85 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2155 85 : if (ndr_flags & NDR_SCALARS) {
2156 85 : NDR_CHECK(ndr_push_align(ndr, 5));
2157 85 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2158 85 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domains));
2159 85 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2160 : }
2161 85 : if (ndr_flags & NDR_BUFFERS) {
2162 85 : if (r->domains) {
2163 60 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2164 255 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
2165 195 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_SCALARS, &r->domains[cntr_domains_1]));
2166 : }
2167 255 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
2168 195 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->domains[cntr_domains_1]));
2169 : }
2170 : }
2171 : }
2172 85 : return NDR_ERR_SUCCESS;
2173 : }
2174 :
2175 68 : static enum ndr_err_code ndr_pull_lsa_DomainList(struct ndr_pull *ndr, int ndr_flags, struct lsa_DomainList *r)
2176 : {
2177 : uint32_t _ptr_domains;
2178 68 : uint32_t size_domains_1 = 0;
2179 : uint32_t cntr_domains_1;
2180 68 : TALLOC_CTX *_mem_save_domains_0 = NULL;
2181 68 : TALLOC_CTX *_mem_save_domains_1 = NULL;
2182 68 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2183 68 : if (ndr_flags & NDR_SCALARS) {
2184 68 : NDR_CHECK(ndr_pull_align(ndr, 5));
2185 68 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2186 68 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
2187 68 : if (_ptr_domains) {
2188 48 : NDR_PULL_ALLOC(ndr, r->domains);
2189 : } else {
2190 20 : r->domains = NULL;
2191 : }
2192 68 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2193 : }
2194 68 : if (ndr_flags & NDR_BUFFERS) {
2195 68 : if (r->domains) {
2196 48 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
2197 48 : NDR_PULL_SET_MEM_CTX(ndr, r->domains, 0);
2198 48 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domains));
2199 48 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->domains, &size_domains_1));
2200 48 : NDR_PULL_ALLOC_N(ndr, r->domains, size_domains_1);
2201 48 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
2202 48 : NDR_PULL_SET_MEM_CTX(ndr, r->domains, 0);
2203 204 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
2204 156 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_SCALARS, &r->domains[cntr_domains_1]));
2205 : }
2206 204 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
2207 156 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->domains[cntr_domains_1]));
2208 : }
2209 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
2210 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
2211 : }
2212 68 : if (r->domains) {
2213 48 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->domains, r->count));
2214 : }
2215 68 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
2216 : }
2217 : }
2218 68 : return NDR_ERR_SUCCESS;
2219 : }
2220 :
2221 34 : _PUBLIC_ void ndr_print_lsa_DomainList(struct ndr_print *ndr, const char *name, const struct lsa_DomainList *r)
2222 : {
2223 : uint32_t cntr_domains_1;
2224 34 : ndr_print_struct(ndr, name, "lsa_DomainList");
2225 34 : if (r == NULL) { ndr_print_null(ndr); return; }
2226 34 : ndr->depth++;
2227 34 : ndr_print_uint32(ndr, "count", r->count);
2228 34 : ndr_print_ptr(ndr, "domains", r->domains);
2229 34 : ndr->depth++;
2230 34 : if (r->domains) {
2231 24 : ndr->print(ndr, "%s: ARRAY(%d)", "domains", (int)r->count);
2232 24 : ndr->depth++;
2233 102 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
2234 78 : ndr_print_lsa_DomainInfo(ndr, "domains", &r->domains[cntr_domains_1]);
2235 : }
2236 24 : ndr->depth--;
2237 : }
2238 34 : ndr->depth--;
2239 34 : ndr->depth--;
2240 : }
2241 :
2242 40197 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_SidType(struct ndr_push *ndr, int ndr_flags, enum lsa_SidType r)
2243 : {
2244 40197 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
2245 40197 : return NDR_ERR_SUCCESS;
2246 : }
2247 :
2248 48086 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_SidType(struct ndr_pull *ndr, int ndr_flags, enum lsa_SidType *r)
2249 : {
2250 : uint16_t v;
2251 48086 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
2252 48086 : *r = v;
2253 48086 : return NDR_ERR_SUCCESS;
2254 : }
2255 :
2256 15750 : _PUBLIC_ void ndr_print_lsa_SidType(struct ndr_print *ndr, const char *name, enum lsa_SidType r)
2257 : {
2258 15750 : const char *val = NULL;
2259 :
2260 15750 : switch (r) {
2261 0 : case SID_NAME_USE_NONE: val = "SID_NAME_USE_NONE"; break;
2262 198 : case SID_NAME_USER: val = "SID_NAME_USER"; break;
2263 2 : case SID_NAME_DOM_GRP: val = "SID_NAME_DOM_GRP"; break;
2264 74 : case SID_NAME_DOMAIN: val = "SID_NAME_DOMAIN"; break;
2265 15462 : case SID_NAME_ALIAS: val = "SID_NAME_ALIAS"; break;
2266 10 : case SID_NAME_WKN_GRP: val = "SID_NAME_WKN_GRP"; break;
2267 0 : case SID_NAME_DELETED: val = "SID_NAME_DELETED"; break;
2268 0 : case SID_NAME_INVALID: val = "SID_NAME_INVALID"; break;
2269 4 : case SID_NAME_UNKNOWN: val = "SID_NAME_UNKNOWN"; break;
2270 0 : case SID_NAME_COMPUTER: val = "SID_NAME_COMPUTER"; break;
2271 0 : case SID_NAME_LABEL: val = "SID_NAME_LABEL"; break;
2272 : }
2273 15750 : ndr_print_enum(ndr, name, "ENUM", val, r);
2274 15750 : }
2275 :
2276 1875 : static enum ndr_err_code ndr_push_lsa_TranslatedSid(struct ndr_push *ndr, int ndr_flags, const struct lsa_TranslatedSid *r)
2277 : {
2278 1875 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2279 1875 : if (ndr_flags & NDR_SCALARS) {
2280 1875 : NDR_CHECK(ndr_push_align(ndr, 4));
2281 1875 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, r->sid_type));
2282 1875 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
2283 1875 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sid_index));
2284 1875 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
2285 : }
2286 1875 : if (ndr_flags & NDR_BUFFERS) {
2287 : }
2288 1875 : return NDR_ERR_SUCCESS;
2289 : }
2290 :
2291 1537 : static enum ndr_err_code ndr_pull_lsa_TranslatedSid(struct ndr_pull *ndr, int ndr_flags, struct lsa_TranslatedSid *r)
2292 : {
2293 1537 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2294 1537 : if (ndr_flags & NDR_SCALARS) {
2295 1537 : NDR_CHECK(ndr_pull_align(ndr, 4));
2296 1537 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, &r->sid_type));
2297 1537 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
2298 1537 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sid_index));
2299 1537 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
2300 : }
2301 1537 : if (ndr_flags & NDR_BUFFERS) {
2302 : }
2303 1537 : return NDR_ERR_SUCCESS;
2304 : }
2305 :
2306 696 : _PUBLIC_ void ndr_print_lsa_TranslatedSid(struct ndr_print *ndr, const char *name, const struct lsa_TranslatedSid *r)
2307 : {
2308 696 : ndr_print_struct(ndr, name, "lsa_TranslatedSid");
2309 696 : if (r == NULL) { ndr_print_null(ndr); return; }
2310 696 : ndr->depth++;
2311 696 : ndr_print_lsa_SidType(ndr, "sid_type", r->sid_type);
2312 696 : ndr_print_uint32(ndr, "rid", r->rid);
2313 696 : ndr_print_uint32(ndr, "sid_index", r->sid_index);
2314 696 : ndr->depth--;
2315 : }
2316 :
2317 647 : static enum ndr_err_code ndr_push_lsa_TransSidArray(struct ndr_push *ndr, int ndr_flags, const struct lsa_TransSidArray *r)
2318 : {
2319 : uint32_t cntr_sids_1;
2320 647 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2321 647 : if (ndr_flags & NDR_SCALARS) {
2322 647 : NDR_CHECK(ndr_push_align(ndr, 5));
2323 647 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2324 647 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sids));
2325 647 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2326 : }
2327 647 : if (ndr_flags & NDR_BUFFERS) {
2328 647 : if (r->sids) {
2329 339 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2330 2214 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->count); cntr_sids_1++) {
2331 1875 : NDR_CHECK(ndr_push_lsa_TranslatedSid(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
2332 : }
2333 : }
2334 : }
2335 647 : return NDR_ERR_SUCCESS;
2336 : }
2337 :
2338 606 : static enum ndr_err_code ndr_pull_lsa_TransSidArray(struct ndr_pull *ndr, int ndr_flags, struct lsa_TransSidArray *r)
2339 : {
2340 : uint32_t _ptr_sids;
2341 606 : uint32_t size_sids_1 = 0;
2342 : uint32_t cntr_sids_1;
2343 606 : TALLOC_CTX *_mem_save_sids_0 = NULL;
2344 606 : TALLOC_CTX *_mem_save_sids_1 = NULL;
2345 606 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2346 606 : if (ndr_flags & NDR_SCALARS) {
2347 606 : NDR_CHECK(ndr_pull_align(ndr, 5));
2348 606 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2349 606 : if (r->count > 1000) {
2350 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2351 : }
2352 606 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sids));
2353 606 : if (_ptr_sids) {
2354 308 : NDR_PULL_ALLOC(ndr, r->sids);
2355 : } else {
2356 298 : r->sids = NULL;
2357 : }
2358 606 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2359 : }
2360 606 : if (ndr_flags & NDR_BUFFERS) {
2361 606 : if (r->sids) {
2362 308 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
2363 308 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
2364 308 : NDR_CHECK(ndr_pull_array_size(ndr, &r->sids));
2365 308 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->sids, &size_sids_1));
2366 308 : NDR_PULL_ALLOC_N(ndr, r->sids, size_sids_1);
2367 308 : _mem_save_sids_1 = NDR_PULL_GET_MEM_CTX(ndr);
2368 308 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
2369 1845 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
2370 1537 : NDR_CHECK(ndr_pull_lsa_TranslatedSid(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
2371 : }
2372 308 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_1, 0);
2373 308 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, 0);
2374 : }
2375 606 : if (r->sids) {
2376 308 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->sids, r->count));
2377 : }
2378 : }
2379 606 : return NDR_ERR_SUCCESS;
2380 : }
2381 :
2382 82 : _PUBLIC_ void ndr_print_lsa_TransSidArray(struct ndr_print *ndr, const char *name, const struct lsa_TransSidArray *r)
2383 : {
2384 : uint32_t cntr_sids_1;
2385 82 : ndr_print_struct(ndr, name, "lsa_TransSidArray");
2386 82 : if (r == NULL) { ndr_print_null(ndr); return; }
2387 82 : ndr->depth++;
2388 82 : ndr_print_uint32(ndr, "count", r->count);
2389 82 : ndr_print_ptr(ndr, "sids", r->sids);
2390 82 : ndr->depth++;
2391 82 : if (r->sids) {
2392 82 : ndr->print(ndr, "%s: ARRAY(%d)", "sids", (int)r->count);
2393 82 : ndr->depth++;
2394 778 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->count); cntr_sids_1++) {
2395 696 : ndr_print_lsa_TranslatedSid(ndr, "sids", &r->sids[cntr_sids_1]);
2396 : }
2397 82 : ndr->depth--;
2398 : }
2399 82 : ndr->depth--;
2400 82 : ndr->depth--;
2401 : }
2402 :
2403 4047 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_RefDomainList(struct ndr_push *ndr, int ndr_flags, const struct lsa_RefDomainList *r)
2404 : {
2405 : uint32_t cntr_domains_1;
2406 4047 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2407 4047 : if (ndr_flags & NDR_SCALARS) {
2408 4047 : NDR_CHECK(ndr_push_align(ndr, 5));
2409 4047 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2410 4047 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domains));
2411 4047 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->max_size));
2412 4047 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2413 : }
2414 4047 : if (ndr_flags & NDR_BUFFERS) {
2415 4047 : if (r->domains) {
2416 3246 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2417 6492 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
2418 3246 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_SCALARS, &r->domains[cntr_domains_1]));
2419 : }
2420 6492 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
2421 3246 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->domains[cntr_domains_1]));
2422 : }
2423 : }
2424 : }
2425 4047 : return NDR_ERR_SUCCESS;
2426 : }
2427 :
2428 1368 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_RefDomainList(struct ndr_pull *ndr, int ndr_flags, struct lsa_RefDomainList *r)
2429 : {
2430 : uint32_t _ptr_domains;
2431 1368 : uint32_t size_domains_1 = 0;
2432 : uint32_t cntr_domains_1;
2433 1368 : TALLOC_CTX *_mem_save_domains_0 = NULL;
2434 1368 : TALLOC_CTX *_mem_save_domains_1 = NULL;
2435 1368 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2436 1368 : if (ndr_flags & NDR_SCALARS) {
2437 1368 : NDR_CHECK(ndr_pull_align(ndr, 5));
2438 1368 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2439 1368 : if (r->count > 1000) {
2440 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2441 : }
2442 1368 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
2443 1368 : if (_ptr_domains) {
2444 1188 : NDR_PULL_ALLOC(ndr, r->domains);
2445 : } else {
2446 180 : r->domains = NULL;
2447 : }
2448 1368 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->max_size));
2449 1368 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2450 : }
2451 1368 : if (ndr_flags & NDR_BUFFERS) {
2452 1368 : if (r->domains) {
2453 1188 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
2454 1188 : NDR_PULL_SET_MEM_CTX(ndr, r->domains, 0);
2455 1188 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domains));
2456 1188 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->domains, &size_domains_1));
2457 1188 : NDR_PULL_ALLOC_N(ndr, r->domains, size_domains_1);
2458 1188 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
2459 1188 : NDR_PULL_SET_MEM_CTX(ndr, r->domains, 0);
2460 2376 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
2461 1188 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_SCALARS, &r->domains[cntr_domains_1]));
2462 : }
2463 2376 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
2464 1188 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_BUFFERS, &r->domains[cntr_domains_1]));
2465 : }
2466 1188 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
2467 1188 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
2468 : }
2469 1368 : if (r->domains) {
2470 1188 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->domains, r->count));
2471 : }
2472 1514 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
2473 : }
2474 : }
2475 1368 : return NDR_ERR_SUCCESS;
2476 : }
2477 :
2478 0 : static void ndr_print_flags_lsa_RefDomainList(struct ndr_print *ndr, const char *name, int unused, const struct lsa_RefDomainList *r)
2479 : {
2480 0 : ndr_print_lsa_RefDomainList(ndr, name, r);
2481 0 : }
2482 :
2483 516 : _PUBLIC_ void ndr_print_lsa_RefDomainList(struct ndr_print *ndr, const char *name, const struct lsa_RefDomainList *r)
2484 : {
2485 : uint32_t cntr_domains_1;
2486 516 : ndr_print_struct(ndr, name, "lsa_RefDomainList");
2487 516 : if (r == NULL) { ndr_print_null(ndr); return; }
2488 516 : ndr->depth++;
2489 516 : ndr_print_uint32(ndr, "count", r->count);
2490 516 : ndr_print_ptr(ndr, "domains", r->domains);
2491 516 : ndr->depth++;
2492 516 : if (r->domains) {
2493 440 : ndr->print(ndr, "%s: ARRAY(%d)", "domains", (int)r->count);
2494 440 : ndr->depth++;
2495 880 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
2496 440 : ndr_print_lsa_DomainInfo(ndr, "domains", &r->domains[cntr_domains_1]);
2497 : }
2498 440 : ndr->depth--;
2499 : }
2500 516 : ndr->depth--;
2501 516 : ndr_print_uint32(ndr, "max_size", r->max_size);
2502 516 : ndr->depth--;
2503 : }
2504 :
2505 1297 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupNamesLevel(struct ndr_push *ndr, int ndr_flags, enum lsa_LookupNamesLevel r)
2506 : {
2507 1297 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
2508 1297 : return NDR_ERR_SUCCESS;
2509 : }
2510 :
2511 2431 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNamesLevel(struct ndr_pull *ndr, int ndr_flags, enum lsa_LookupNamesLevel *r)
2512 : {
2513 : uint16_t v;
2514 2431 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
2515 2431 : *r = v;
2516 2431 : return NDR_ERR_SUCCESS;
2517 : }
2518 :
2519 0 : _PUBLIC_ void ndr_print_lsa_LookupNamesLevel(struct ndr_print *ndr, const char *name, enum lsa_LookupNamesLevel r)
2520 : {
2521 0 : const char *val = NULL;
2522 :
2523 0 : switch (r) {
2524 0 : case LSA_LOOKUP_NAMES_ALL: val = "LSA_LOOKUP_NAMES_ALL"; break;
2525 0 : case LSA_LOOKUP_NAMES_DOMAINS_ONLY: val = "LSA_LOOKUP_NAMES_DOMAINS_ONLY"; break;
2526 0 : case LSA_LOOKUP_NAMES_PRIMARY_DOMAIN_ONLY: val = "LSA_LOOKUP_NAMES_PRIMARY_DOMAIN_ONLY"; break;
2527 0 : case LSA_LOOKUP_NAMES_UPLEVEL_TRUSTS_ONLY: val = "LSA_LOOKUP_NAMES_UPLEVEL_TRUSTS_ONLY"; break;
2528 0 : case LSA_LOOKUP_NAMES_FOREST_TRUSTS_ONLY: val = "LSA_LOOKUP_NAMES_FOREST_TRUSTS_ONLY"; break;
2529 0 : case LSA_LOOKUP_NAMES_UPLEVEL_TRUSTS_ONLY2: val = "LSA_LOOKUP_NAMES_UPLEVEL_TRUSTS_ONLY2"; break;
2530 0 : case LSA_LOOKUP_NAMES_RODC_REFERRAL_TO_FULL_DC: val = "LSA_LOOKUP_NAMES_RODC_REFERRAL_TO_FULL_DC"; break;
2531 : }
2532 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
2533 0 : }
2534 :
2535 3112 : static enum ndr_err_code ndr_push_lsa_TranslatedName(struct ndr_push *ndr, int ndr_flags, const struct lsa_TranslatedName *r)
2536 : {
2537 3112 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2538 3112 : if (ndr_flags & NDR_SCALARS) {
2539 1556 : NDR_CHECK(ndr_push_align(ndr, 5));
2540 1556 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, r->sid_type));
2541 1556 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
2542 1556 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sid_index));
2543 1556 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2544 : }
2545 3112 : if (ndr_flags & NDR_BUFFERS) {
2546 1556 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
2547 : }
2548 3112 : return NDR_ERR_SUCCESS;
2549 : }
2550 :
2551 2804 : static enum ndr_err_code ndr_pull_lsa_TranslatedName(struct ndr_pull *ndr, int ndr_flags, struct lsa_TranslatedName *r)
2552 : {
2553 2804 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2554 2804 : if (ndr_flags & NDR_SCALARS) {
2555 1402 : NDR_CHECK(ndr_pull_align(ndr, 5));
2556 1402 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, &r->sid_type));
2557 1402 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
2558 1402 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sid_index));
2559 1402 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2560 : }
2561 2804 : if (ndr_flags & NDR_BUFFERS) {
2562 1402 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
2563 : }
2564 2804 : return NDR_ERR_SUCCESS;
2565 : }
2566 :
2567 614 : _PUBLIC_ void ndr_print_lsa_TranslatedName(struct ndr_print *ndr, const char *name, const struct lsa_TranslatedName *r)
2568 : {
2569 614 : ndr_print_struct(ndr, name, "lsa_TranslatedName");
2570 614 : if (r == NULL) { ndr_print_null(ndr); return; }
2571 614 : ndr->depth++;
2572 614 : ndr_print_lsa_SidType(ndr, "sid_type", r->sid_type);
2573 614 : ndr_print_lsa_String(ndr, "name", &r->name);
2574 614 : ndr_print_uint32(ndr, "sid_index", r->sid_index);
2575 614 : ndr->depth--;
2576 : }
2577 :
2578 978 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TransNameArray(struct ndr_push *ndr, int ndr_flags, const struct lsa_TransNameArray *r)
2579 : {
2580 : uint32_t cntr_names_1;
2581 978 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2582 978 : if (ndr_flags & NDR_SCALARS) {
2583 978 : NDR_CHECK(ndr_push_align(ndr, 5));
2584 978 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2585 978 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->names));
2586 978 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2587 : }
2588 978 : if (ndr_flags & NDR_BUFFERS) {
2589 978 : if (r->names) {
2590 541 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2591 2097 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
2592 1556 : NDR_CHECK(ndr_push_lsa_TranslatedName(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
2593 : }
2594 2097 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
2595 1556 : NDR_CHECK(ndr_push_lsa_TranslatedName(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
2596 : }
2597 : }
2598 : }
2599 978 : return NDR_ERR_SUCCESS;
2600 : }
2601 :
2602 979 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TransNameArray(struct ndr_pull *ndr, int ndr_flags, struct lsa_TransNameArray *r)
2603 : {
2604 : uint32_t _ptr_names;
2605 979 : uint32_t size_names_1 = 0;
2606 : uint32_t cntr_names_1;
2607 979 : TALLOC_CTX *_mem_save_names_0 = NULL;
2608 979 : TALLOC_CTX *_mem_save_names_1 = NULL;
2609 979 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2610 979 : if (ndr_flags & NDR_SCALARS) {
2611 979 : NDR_CHECK(ndr_pull_align(ndr, 5));
2612 979 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2613 979 : if (r->count > 20480) {
2614 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2615 : }
2616 979 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_names));
2617 979 : if (_ptr_names) {
2618 542 : NDR_PULL_ALLOC(ndr, r->names);
2619 : } else {
2620 437 : r->names = NULL;
2621 : }
2622 979 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2623 : }
2624 979 : if (ndr_flags & NDR_BUFFERS) {
2625 979 : if (r->names) {
2626 542 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
2627 542 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
2628 542 : NDR_CHECK(ndr_pull_array_size(ndr, &r->names));
2629 542 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->names, &size_names_1));
2630 542 : NDR_PULL_ALLOC_N(ndr, r->names, size_names_1);
2631 542 : _mem_save_names_1 = NDR_PULL_GET_MEM_CTX(ndr);
2632 542 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
2633 1944 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
2634 1402 : NDR_CHECK(ndr_pull_lsa_TranslatedName(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
2635 : }
2636 1944 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
2637 1402 : NDR_CHECK(ndr_pull_lsa_TranslatedName(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
2638 : }
2639 542 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_1, 0);
2640 542 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
2641 : }
2642 979 : if (r->names) {
2643 542 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->names, r->count));
2644 : }
2645 1061 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
2646 : }
2647 : }
2648 979 : return NDR_ERR_SUCCESS;
2649 : }
2650 :
2651 0 : static void ndr_print_flags_lsa_TransNameArray(struct ndr_print *ndr, const char *name, int unused, const struct lsa_TransNameArray *r)
2652 : {
2653 0 : ndr_print_lsa_TransNameArray(ndr, name, r);
2654 0 : }
2655 :
2656 208 : _PUBLIC_ void ndr_print_lsa_TransNameArray(struct ndr_print *ndr, const char *name, const struct lsa_TransNameArray *r)
2657 : {
2658 : uint32_t cntr_names_1;
2659 208 : ndr_print_struct(ndr, name, "lsa_TransNameArray");
2660 208 : if (r == NULL) { ndr_print_null(ndr); return; }
2661 208 : ndr->depth++;
2662 208 : ndr_print_uint32(ndr, "count", r->count);
2663 208 : ndr_print_ptr(ndr, "names", r->names);
2664 208 : ndr->depth++;
2665 208 : if (r->names) {
2666 208 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->count);
2667 208 : ndr->depth++;
2668 822 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
2669 614 : ndr_print_lsa_TranslatedName(ndr, "names", &r->names[cntr_names_1]);
2670 : }
2671 208 : ndr->depth--;
2672 : }
2673 208 : ndr->depth--;
2674 208 : ndr->depth--;
2675 : }
2676 :
2677 200 : static enum ndr_err_code ndr_push_lsa_LUIDAttribute(struct ndr_push *ndr, int ndr_flags, const struct lsa_LUIDAttribute *r)
2678 : {
2679 200 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2680 200 : if (ndr_flags & NDR_SCALARS) {
2681 200 : NDR_CHECK(ndr_push_align(ndr, 4));
2682 200 : NDR_CHECK(ndr_push_lsa_LUID(ndr, NDR_SCALARS, &r->luid));
2683 200 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->attribute));
2684 200 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
2685 : }
2686 200 : if (ndr_flags & NDR_BUFFERS) {
2687 : }
2688 200 : return NDR_ERR_SUCCESS;
2689 : }
2690 :
2691 168 : static enum ndr_err_code ndr_pull_lsa_LUIDAttribute(struct ndr_pull *ndr, int ndr_flags, struct lsa_LUIDAttribute *r)
2692 : {
2693 168 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2694 168 : if (ndr_flags & NDR_SCALARS) {
2695 168 : NDR_CHECK(ndr_pull_align(ndr, 4));
2696 168 : NDR_CHECK(ndr_pull_lsa_LUID(ndr, NDR_SCALARS, &r->luid));
2697 168 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->attribute));
2698 168 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
2699 : }
2700 168 : if (ndr_flags & NDR_BUFFERS) {
2701 : }
2702 168 : return NDR_ERR_SUCCESS;
2703 : }
2704 :
2705 64 : _PUBLIC_ void ndr_print_lsa_LUIDAttribute(struct ndr_print *ndr, const char *name, const struct lsa_LUIDAttribute *r)
2706 : {
2707 64 : ndr_print_struct(ndr, name, "lsa_LUIDAttribute");
2708 64 : if (r == NULL) { ndr_print_null(ndr); return; }
2709 64 : ndr->depth++;
2710 64 : ndr_print_lsa_LUID(ndr, "luid", &r->luid);
2711 64 : ndr_print_uint32(ndr, "attribute", r->attribute);
2712 64 : ndr->depth--;
2713 : }
2714 :
2715 70 : static enum ndr_err_code ndr_push_lsa_PrivilegeSet(struct ndr_push *ndr, int ndr_flags, const struct lsa_PrivilegeSet *r)
2716 : {
2717 : uint32_t cntr_set_0;
2718 70 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2719 70 : if (ndr_flags & NDR_SCALARS) {
2720 70 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
2721 70 : NDR_CHECK(ndr_push_align(ndr, 4));
2722 70 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
2723 70 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown));
2724 270 : for (cntr_set_0 = 0; cntr_set_0 < (r->count); cntr_set_0++) {
2725 200 : NDR_CHECK(ndr_push_lsa_LUIDAttribute(ndr, NDR_SCALARS, &r->set[cntr_set_0]));
2726 : }
2727 70 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
2728 : }
2729 70 : if (ndr_flags & NDR_BUFFERS) {
2730 : }
2731 70 : return NDR_ERR_SUCCESS;
2732 : }
2733 :
2734 64 : static enum ndr_err_code ndr_pull_lsa_PrivilegeSet(struct ndr_pull *ndr, int ndr_flags, struct lsa_PrivilegeSet *r)
2735 : {
2736 64 : uint32_t size_set_0 = 0;
2737 : uint32_t cntr_set_0;
2738 64 : TALLOC_CTX *_mem_save_set_0 = NULL;
2739 64 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2740 64 : if (ndr_flags & NDR_SCALARS) {
2741 64 : NDR_CHECK(ndr_pull_array_size(ndr, &r->set));
2742 64 : NDR_CHECK(ndr_pull_align(ndr, 4));
2743 64 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
2744 64 : if (r->count > 1000) {
2745 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2746 : }
2747 64 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown));
2748 64 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->set, &size_set_0));
2749 64 : NDR_PULL_ALLOC_N(ndr, r->set, size_set_0);
2750 64 : _mem_save_set_0 = NDR_PULL_GET_MEM_CTX(ndr);
2751 64 : NDR_PULL_SET_MEM_CTX(ndr, r->set, 0);
2752 232 : for (cntr_set_0 = 0; cntr_set_0 < (size_set_0); cntr_set_0++) {
2753 168 : NDR_CHECK(ndr_pull_lsa_LUIDAttribute(ndr, NDR_SCALARS, &r->set[cntr_set_0]));
2754 : }
2755 64 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_set_0, 0);
2756 64 : if (r->set) {
2757 64 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->set, r->count));
2758 : }
2759 64 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
2760 : }
2761 64 : if (ndr_flags & NDR_BUFFERS) {
2762 : }
2763 64 : return NDR_ERR_SUCCESS;
2764 : }
2765 :
2766 12 : _PUBLIC_ void ndr_print_lsa_PrivilegeSet(struct ndr_print *ndr, const char *name, const struct lsa_PrivilegeSet *r)
2767 : {
2768 : uint32_t cntr_set_0;
2769 12 : ndr_print_struct(ndr, name, "lsa_PrivilegeSet");
2770 12 : if (r == NULL) { ndr_print_null(ndr); return; }
2771 12 : ndr->depth++;
2772 12 : ndr_print_uint32(ndr, "count", r->count);
2773 12 : ndr_print_uint32(ndr, "unknown", r->unknown);
2774 12 : ndr->print(ndr, "%s: ARRAY(%d)", "set", (int)r->count);
2775 12 : ndr->depth++;
2776 76 : for (cntr_set_0 = 0; cntr_set_0 < (r->count); cntr_set_0++) {
2777 64 : ndr_print_lsa_LUIDAttribute(ndr, "set", &r->set[cntr_set_0]);
2778 : }
2779 12 : ndr->depth--;
2780 12 : ndr->depth--;
2781 : }
2782 :
2783 3590 : static enum ndr_err_code ndr_push_lsa_DATA_BUF(struct ndr_push *ndr, int ndr_flags, const struct lsa_DATA_BUF *r)
2784 : {
2785 : {
2786 3590 : uint32_t _flags_save_STRUCT = ndr->flags;
2787 3590 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2788 3590 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2789 3590 : if (ndr_flags & NDR_SCALARS) {
2790 3590 : NDR_CHECK(ndr_push_align(ndr, 5));
2791 3590 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->length));
2792 3590 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->size));
2793 3590 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->data));
2794 3590 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2795 : }
2796 3590 : if (ndr_flags & NDR_BUFFERS) {
2797 3590 : if (r->data) {
2798 3590 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->size));
2799 3590 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2800 3590 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->length));
2801 3590 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->data, r->length));
2802 : }
2803 : }
2804 3590 : ndr->flags = _flags_save_STRUCT;
2805 : }
2806 3590 : return NDR_ERR_SUCCESS;
2807 : }
2808 :
2809 3574 : static enum ndr_err_code ndr_pull_lsa_DATA_BUF(struct ndr_pull *ndr, int ndr_flags, struct lsa_DATA_BUF *r)
2810 : {
2811 : uint32_t _ptr_data;
2812 3574 : uint32_t size_data_1 = 0;
2813 3574 : uint32_t length_data_1 = 0;
2814 3574 : TALLOC_CTX *_mem_save_data_0 = NULL;
2815 : {
2816 3574 : uint32_t _flags_save_STRUCT = ndr->flags;
2817 3574 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2818 3574 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2819 3574 : if (ndr_flags & NDR_SCALARS) {
2820 3574 : NDR_CHECK(ndr_pull_align(ndr, 5));
2821 3574 : NDR_CHECK(ndr_pull_uint3264(ndr, NDR_SCALARS, &r->length));
2822 3574 : NDR_CHECK(ndr_pull_uint3264(ndr, NDR_SCALARS, &r->size));
2823 3574 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_data));
2824 3574 : if (_ptr_data) {
2825 3574 : NDR_PULL_ALLOC(ndr, r->data);
2826 : } else {
2827 0 : r->data = NULL;
2828 : }
2829 3574 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2830 : }
2831 3574 : if (ndr_flags & NDR_BUFFERS) {
2832 3574 : if (r->data) {
2833 3574 : _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
2834 3574 : NDR_PULL_SET_MEM_CTX(ndr, r->data, 0);
2835 3574 : NDR_CHECK(ndr_pull_array_size(ndr, &r->data));
2836 3574 : NDR_CHECK(ndr_pull_array_length(ndr, &r->data));
2837 3574 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->data, &size_data_1));
2838 3574 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->data, &length_data_1));
2839 3574 : if (length_data_1 > size_data_1) {
2840 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_data_1, length_data_1);
2841 : }
2842 3574 : NDR_PULL_ALLOC_N(ndr, r->data, size_data_1);
2843 3574 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->data, length_data_1));
2844 3574 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, 0);
2845 : }
2846 3574 : if (r->data) {
2847 3574 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->data, r->size));
2848 : }
2849 3574 : if (r->data) {
2850 3574 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->data, r->length));
2851 : }
2852 : }
2853 3574 : ndr->flags = _flags_save_STRUCT;
2854 : }
2855 3574 : return NDR_ERR_SUCCESS;
2856 : }
2857 :
2858 32 : _PUBLIC_ void ndr_print_lsa_DATA_BUF(struct ndr_print *ndr, const char *name, const struct lsa_DATA_BUF *r)
2859 : {
2860 32 : ndr_print_struct(ndr, name, "lsa_DATA_BUF");
2861 32 : if (r == NULL) { ndr_print_null(ndr); return; }
2862 : {
2863 32 : uint32_t _flags_save_STRUCT = ndr->flags;
2864 32 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2865 32 : ndr->depth++;
2866 32 : ndr_print_uint3264(ndr, "length", r->length);
2867 32 : ndr_print_uint3264(ndr, "size", r->size);
2868 32 : ndr_print_ptr(ndr, "data", r->data);
2869 32 : ndr->depth++;
2870 32 : if (r->data) {
2871 32 : ndr_print_array_uint8(ndr, "data", r->data, r->length);
2872 : }
2873 32 : ndr->depth--;
2874 32 : ndr->depth--;
2875 32 : ndr->flags = _flags_save_STRUCT;
2876 : }
2877 : }
2878 :
2879 532 : static enum ndr_err_code ndr_push_lsa_DATA_BUF2(struct ndr_push *ndr, int ndr_flags, const struct lsa_DATA_BUF2 *r)
2880 : {
2881 : {
2882 532 : uint32_t _flags_save_STRUCT = ndr->flags;
2883 532 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2884 532 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2885 532 : if (ndr_flags & NDR_SCALARS) {
2886 266 : NDR_CHECK(ndr_push_align(ndr, 5));
2887 266 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->size));
2888 266 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->data));
2889 266 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2890 : }
2891 532 : if (ndr_flags & NDR_BUFFERS) {
2892 266 : if (r->data) {
2893 266 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->size));
2894 266 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->data, r->size));
2895 : }
2896 : }
2897 532 : ndr->flags = _flags_save_STRUCT;
2898 : }
2899 532 : return NDR_ERR_SUCCESS;
2900 : }
2901 :
2902 532 : static enum ndr_err_code ndr_pull_lsa_DATA_BUF2(struct ndr_pull *ndr, int ndr_flags, struct lsa_DATA_BUF2 *r)
2903 : {
2904 : uint32_t _ptr_data;
2905 532 : uint32_t size_data_1 = 0;
2906 532 : TALLOC_CTX *_mem_save_data_0 = NULL;
2907 : {
2908 532 : uint32_t _flags_save_STRUCT = ndr->flags;
2909 532 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2910 532 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2911 532 : if (ndr_flags & NDR_SCALARS) {
2912 266 : NDR_CHECK(ndr_pull_align(ndr, 5));
2913 266 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->size));
2914 266 : if (r->size > 65536) {
2915 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
2916 : }
2917 266 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_data));
2918 266 : if (_ptr_data) {
2919 266 : NDR_PULL_ALLOC(ndr, r->data);
2920 : } else {
2921 0 : r->data = NULL;
2922 : }
2923 266 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2924 : }
2925 532 : if (ndr_flags & NDR_BUFFERS) {
2926 266 : if (r->data) {
2927 266 : _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
2928 266 : NDR_PULL_SET_MEM_CTX(ndr, r->data, 0);
2929 266 : NDR_CHECK(ndr_pull_array_size(ndr, &r->data));
2930 266 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->data, &size_data_1));
2931 266 : NDR_PULL_ALLOC_N(ndr, r->data, size_data_1);
2932 266 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->data, size_data_1));
2933 266 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, 0);
2934 : }
2935 266 : if (r->data) {
2936 266 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->data, r->size));
2937 : }
2938 : }
2939 532 : ndr->flags = _flags_save_STRUCT;
2940 : }
2941 532 : return NDR_ERR_SUCCESS;
2942 : }
2943 :
2944 0 : _PUBLIC_ void ndr_print_lsa_DATA_BUF2(struct ndr_print *ndr, const char *name, const struct lsa_DATA_BUF2 *r)
2945 : {
2946 0 : ndr_print_struct(ndr, name, "lsa_DATA_BUF2");
2947 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2948 : {
2949 0 : uint32_t _flags_save_STRUCT = ndr->flags;
2950 0 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2951 0 : ndr->depth++;
2952 0 : ndr_print_uint32(ndr, "size", r->size);
2953 0 : ndr_print_ptr(ndr, "data", r->data);
2954 0 : ndr->depth++;
2955 0 : if (r->data) {
2956 0 : ndr_print_array_uint8(ndr, "data", r->data, r->size);
2957 : }
2958 0 : ndr->depth--;
2959 0 : ndr->depth--;
2960 0 : ndr->flags = _flags_save_STRUCT;
2961 : }
2962 : }
2963 :
2964 12701 : static enum ndr_err_code ndr_push_lsa_TrustDomInfoEnum(struct ndr_push *ndr, int ndr_flags, enum lsa_TrustDomInfoEnum r)
2965 : {
2966 12701 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
2967 12701 : return NDR_ERR_SUCCESS;
2968 : }
2969 :
2970 7976 : static enum ndr_err_code ndr_pull_lsa_TrustDomInfoEnum(struct ndr_pull *ndr, int ndr_flags, enum lsa_TrustDomInfoEnum *r)
2971 : {
2972 : uint16_t v;
2973 7976 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
2974 7976 : *r = v;
2975 7976 : return NDR_ERR_SUCCESS;
2976 : }
2977 :
2978 0 : _PUBLIC_ void ndr_print_lsa_TrustDomInfoEnum(struct ndr_print *ndr, const char *name, enum lsa_TrustDomInfoEnum r)
2979 : {
2980 0 : const char *val = NULL;
2981 :
2982 0 : switch (r) {
2983 0 : case LSA_TRUSTED_DOMAIN_INFO_NAME: val = "LSA_TRUSTED_DOMAIN_INFO_NAME"; break;
2984 0 : case LSA_TRUSTED_DOMAIN_INFO_CONTROLLERS: val = "LSA_TRUSTED_DOMAIN_INFO_CONTROLLERS"; break;
2985 0 : case LSA_TRUSTED_DOMAIN_INFO_POSIX_OFFSET: val = "LSA_TRUSTED_DOMAIN_INFO_POSIX_OFFSET"; break;
2986 0 : case LSA_TRUSTED_DOMAIN_INFO_PASSWORD: val = "LSA_TRUSTED_DOMAIN_INFO_PASSWORD"; break;
2987 0 : case LSA_TRUSTED_DOMAIN_INFO_BASIC: val = "LSA_TRUSTED_DOMAIN_INFO_BASIC"; break;
2988 0 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX: val = "LSA_TRUSTED_DOMAIN_INFO_INFO_EX"; break;
2989 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO: val = "LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO"; break;
2990 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO: val = "LSA_TRUSTED_DOMAIN_INFO_FULL_INFO"; break;
2991 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO_INTERNAL: val = "LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO_INTERNAL"; break;
2992 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_INTERNAL: val = "LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_INTERNAL"; break;
2993 0 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX2_INTERNAL: val = "LSA_TRUSTED_DOMAIN_INFO_INFO_EX2_INTERNAL"; break;
2994 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_2_INTERNAL: val = "LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_2_INTERNAL"; break;
2995 0 : case LSA_TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES: val = "LSA_TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES"; break;
2996 : }
2997 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
2998 0 : }
2999 :
3000 2882 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TrustDirection(struct ndr_push *ndr, int ndr_flags, uint32_t r)
3001 : {
3002 2882 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
3003 2882 : return NDR_ERR_SUCCESS;
3004 : }
3005 :
3006 2298 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TrustDirection(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
3007 : {
3008 : uint32_t v;
3009 2298 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
3010 2298 : *r = v;
3011 2298 : return NDR_ERR_SUCCESS;
3012 : }
3013 :
3014 1022 : _PUBLIC_ void ndr_print_lsa_TrustDirection(struct ndr_print *ndr, const char *name, uint32_t r)
3015 : {
3016 1022 : ndr_print_uint32(ndr, name, r);
3017 1022 : ndr->depth++;
3018 1022 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_DIRECTION_INBOUND", LSA_TRUST_DIRECTION_INBOUND, r);
3019 1022 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_DIRECTION_OUTBOUND", LSA_TRUST_DIRECTION_OUTBOUND, r);
3020 1022 : ndr->depth--;
3021 1022 : }
3022 :
3023 3120 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TrustType(struct ndr_push *ndr, int ndr_flags, enum lsa_TrustType r)
3024 : {
3025 3120 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
3026 3120 : return NDR_ERR_SUCCESS;
3027 : }
3028 :
3029 5801 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TrustType(struct ndr_pull *ndr, int ndr_flags, enum lsa_TrustType *r)
3030 : {
3031 : uint32_t v;
3032 5801 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
3033 5801 : *r = v;
3034 5801 : return NDR_ERR_SUCCESS;
3035 : }
3036 :
3037 1071 : _PUBLIC_ void ndr_print_lsa_TrustType(struct ndr_print *ndr, const char *name, enum lsa_TrustType r)
3038 : {
3039 1071 : const char *val = NULL;
3040 :
3041 1071 : switch (r) {
3042 507 : case LSA_TRUST_TYPE_DOWNLEVEL: val = "LSA_TRUST_TYPE_DOWNLEVEL"; break;
3043 396 : case LSA_TRUST_TYPE_UPLEVEL: val = "LSA_TRUST_TYPE_UPLEVEL"; break;
3044 168 : case LSA_TRUST_TYPE_MIT: val = "LSA_TRUST_TYPE_MIT"; break;
3045 0 : case LSA_TRUST_TYPE_DCE: val = "LSA_TRUST_TYPE_DCE"; break;
3046 : }
3047 1071 : ndr_print_enum(ndr, name, "ENUM", val, r);
3048 1071 : }
3049 :
3050 3120 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TrustAttributes(struct ndr_push *ndr, int ndr_flags, uint32_t r)
3051 : {
3052 3120 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
3053 3120 : return NDR_ERR_SUCCESS;
3054 : }
3055 :
3056 5801 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TrustAttributes(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
3057 : {
3058 : uint32_t v;
3059 5801 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
3060 5801 : *r = v;
3061 5801 : return NDR_ERR_SUCCESS;
3062 : }
3063 :
3064 1071 : _PUBLIC_ void ndr_print_lsa_TrustAttributes(struct ndr_print *ndr, const char *name, uint32_t r)
3065 : {
3066 1071 : ndr_print_uint32(ndr, name, r);
3067 1071 : ndr->depth++;
3068 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_NON_TRANSITIVE", LSA_TRUST_ATTRIBUTE_NON_TRANSITIVE, r);
3069 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_UPLEVEL_ONLY", LSA_TRUST_ATTRIBUTE_UPLEVEL_ONLY, r);
3070 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_QUARANTINED_DOMAIN", LSA_TRUST_ATTRIBUTE_QUARANTINED_DOMAIN, r);
3071 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_FOREST_TRANSITIVE", LSA_TRUST_ATTRIBUTE_FOREST_TRANSITIVE, r);
3072 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_CROSS_ORGANIZATION", LSA_TRUST_ATTRIBUTE_CROSS_ORGANIZATION, r);
3073 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_WITHIN_FOREST", LSA_TRUST_ATTRIBUTE_WITHIN_FOREST, r);
3074 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_TREAT_AS_EXTERNAL", LSA_TRUST_ATTRIBUTE_TREAT_AS_EXTERNAL, r);
3075 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_USES_RC4_ENCRYPTION", LSA_TRUST_ATTRIBUTE_USES_RC4_ENCRYPTION, r);
3076 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_CROSS_ORGANIZATION_NO_TGT_DELEGATION", LSA_TRUST_ATTRIBUTE_CROSS_ORGANIZATION_NO_TGT_DELEGATION, r);
3077 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_PIM_TRUST", LSA_TRUST_ATTRIBUTE_PIM_TRUST, r);
3078 1071 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TRUST_ATTRIBUTE_CROSS_ORGANIZATION_ENABLE_TGT_DELEGATION", LSA_TRUST_ATTRIBUTE_CROSS_ORGANIZATION_ENABLE_TGT_DELEGATION, r);
3079 1071 : ndr->depth--;
3080 1071 : }
3081 :
3082 1458 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoName(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoName *r)
3083 : {
3084 1458 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3085 1458 : if (ndr_flags & NDR_SCALARS) {
3086 729 : NDR_CHECK(ndr_push_align(ndr, 5));
3087 729 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_name));
3088 729 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3089 : }
3090 1458 : if (ndr_flags & NDR_BUFFERS) {
3091 729 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_name));
3092 : }
3093 1458 : return NDR_ERR_SUCCESS;
3094 : }
3095 :
3096 1168 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoName(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoName *r)
3097 : {
3098 1168 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3099 1168 : if (ndr_flags & NDR_SCALARS) {
3100 584 : NDR_CHECK(ndr_pull_align(ndr, 5));
3101 584 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_name));
3102 584 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3103 : }
3104 1168 : if (ndr_flags & NDR_BUFFERS) {
3105 584 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_name));
3106 : }
3107 1168 : return NDR_ERR_SUCCESS;
3108 : }
3109 :
3110 290 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoName(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoName *r)
3111 : {
3112 290 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoName");
3113 290 : if (r == NULL) { ndr_print_null(ndr); return; }
3114 290 : ndr->depth++;
3115 290 : ndr_print_lsa_StringLarge(ndr, "netbios_name", &r->netbios_name);
3116 290 : ndr->depth--;
3117 : }
3118 :
3119 0 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoControllers(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoControllers *r)
3120 : {
3121 : uint32_t cntr_netbios_names_1;
3122 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3123 0 : if (ndr_flags & NDR_SCALARS) {
3124 0 : NDR_CHECK(ndr_push_align(ndr, 5));
3125 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->entries));
3126 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->netbios_names));
3127 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3128 : }
3129 0 : if (ndr_flags & NDR_BUFFERS) {
3130 0 : if (r->netbios_names) {
3131 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->entries));
3132 0 : for (cntr_netbios_names_1 = 0; cntr_netbios_names_1 < (r->entries); cntr_netbios_names_1++) {
3133 0 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_names[cntr_netbios_names_1]));
3134 : }
3135 0 : for (cntr_netbios_names_1 = 0; cntr_netbios_names_1 < (r->entries); cntr_netbios_names_1++) {
3136 0 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_names[cntr_netbios_names_1]));
3137 : }
3138 : }
3139 : }
3140 0 : return NDR_ERR_SUCCESS;
3141 : }
3142 :
3143 0 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoControllers(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoControllers *r)
3144 : {
3145 : uint32_t _ptr_netbios_names;
3146 0 : uint32_t size_netbios_names_1 = 0;
3147 : uint32_t cntr_netbios_names_1;
3148 0 : TALLOC_CTX *_mem_save_netbios_names_0 = NULL;
3149 0 : TALLOC_CTX *_mem_save_netbios_names_1 = NULL;
3150 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3151 0 : if (ndr_flags & NDR_SCALARS) {
3152 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
3153 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->entries));
3154 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_netbios_names));
3155 0 : if (_ptr_netbios_names) {
3156 0 : NDR_PULL_ALLOC(ndr, r->netbios_names);
3157 : } else {
3158 0 : r->netbios_names = NULL;
3159 : }
3160 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3161 : }
3162 0 : if (ndr_flags & NDR_BUFFERS) {
3163 0 : if (r->netbios_names) {
3164 0 : _mem_save_netbios_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
3165 0 : NDR_PULL_SET_MEM_CTX(ndr, r->netbios_names, 0);
3166 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->netbios_names));
3167 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->netbios_names, &size_netbios_names_1));
3168 0 : NDR_PULL_ALLOC_N(ndr, r->netbios_names, size_netbios_names_1);
3169 0 : _mem_save_netbios_names_1 = NDR_PULL_GET_MEM_CTX(ndr);
3170 0 : NDR_PULL_SET_MEM_CTX(ndr, r->netbios_names, 0);
3171 0 : for (cntr_netbios_names_1 = 0; cntr_netbios_names_1 < (size_netbios_names_1); cntr_netbios_names_1++) {
3172 0 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_names[cntr_netbios_names_1]));
3173 : }
3174 0 : for (cntr_netbios_names_1 = 0; cntr_netbios_names_1 < (size_netbios_names_1); cntr_netbios_names_1++) {
3175 0 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_names[cntr_netbios_names_1]));
3176 : }
3177 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_netbios_names_1, 0);
3178 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_netbios_names_0, 0);
3179 : }
3180 0 : if (r->netbios_names) {
3181 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->netbios_names, r->entries));
3182 : }
3183 0 : for (cntr_netbios_names_1 = 0; cntr_netbios_names_1 < (size_netbios_names_1); cntr_netbios_names_1++) {
3184 : }
3185 : }
3186 0 : return NDR_ERR_SUCCESS;
3187 : }
3188 :
3189 0 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoControllers(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoControllers *r)
3190 : {
3191 : uint32_t cntr_netbios_names_1;
3192 0 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoControllers");
3193 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3194 0 : ndr->depth++;
3195 0 : ndr_print_uint32(ndr, "entries", r->entries);
3196 0 : ndr_print_ptr(ndr, "netbios_names", r->netbios_names);
3197 0 : ndr->depth++;
3198 0 : if (r->netbios_names) {
3199 0 : ndr->print(ndr, "%s: ARRAY(%d)", "netbios_names", (int)r->entries);
3200 0 : ndr->depth++;
3201 0 : for (cntr_netbios_names_1 = 0; cntr_netbios_names_1 < (r->entries); cntr_netbios_names_1++) {
3202 0 : ndr_print_lsa_StringLarge(ndr, "netbios_names", &r->netbios_names[cntr_netbios_names_1]);
3203 : }
3204 0 : ndr->depth--;
3205 : }
3206 0 : ndr->depth--;
3207 0 : ndr->depth--;
3208 : }
3209 :
3210 2211 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoPosixOffset(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoPosixOffset *r)
3211 : {
3212 2211 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3213 2211 : if (ndr_flags & NDR_SCALARS) {
3214 2211 : NDR_CHECK(ndr_push_align(ndr, 4));
3215 2211 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->posix_offset));
3216 2211 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
3217 : }
3218 2211 : if (ndr_flags & NDR_BUFFERS) {
3219 : }
3220 2211 : return NDR_ERR_SUCCESS;
3221 : }
3222 :
3223 1776 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoPosixOffset(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoPosixOffset *r)
3224 : {
3225 1776 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3226 1776 : if (ndr_flags & NDR_SCALARS) {
3227 1776 : NDR_CHECK(ndr_pull_align(ndr, 4));
3228 1776 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->posix_offset));
3229 1776 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
3230 : }
3231 1776 : if (ndr_flags & NDR_BUFFERS) {
3232 : }
3233 1776 : return NDR_ERR_SUCCESS;
3234 : }
3235 :
3236 870 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoPosixOffset(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoPosixOffset *r)
3237 : {
3238 870 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoPosixOffset");
3239 870 : if (r == NULL) { ndr_print_null(ndr); return; }
3240 870 : ndr->depth++;
3241 870 : ndr_print_uint32(ndr, "posix_offset", r->posix_offset);
3242 870 : ndr->depth--;
3243 : }
3244 :
3245 0 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoPassword(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoPassword *r)
3246 : {
3247 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3248 0 : if (ndr_flags & NDR_SCALARS) {
3249 0 : NDR_CHECK(ndr_push_align(ndr, 5));
3250 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->password));
3251 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->old_password));
3252 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3253 : }
3254 0 : if (ndr_flags & NDR_BUFFERS) {
3255 0 : if (r->password) {
3256 0 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->password));
3257 : }
3258 0 : if (r->old_password) {
3259 0 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->old_password));
3260 : }
3261 : }
3262 0 : return NDR_ERR_SUCCESS;
3263 : }
3264 :
3265 0 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoPassword(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoPassword *r)
3266 : {
3267 : uint32_t _ptr_password;
3268 0 : TALLOC_CTX *_mem_save_password_0 = NULL;
3269 : uint32_t _ptr_old_password;
3270 0 : TALLOC_CTX *_mem_save_old_password_0 = NULL;
3271 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3272 0 : if (ndr_flags & NDR_SCALARS) {
3273 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
3274 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_password));
3275 0 : if (_ptr_password) {
3276 0 : NDR_PULL_ALLOC(ndr, r->password);
3277 : } else {
3278 0 : r->password = NULL;
3279 : }
3280 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_password));
3281 0 : if (_ptr_old_password) {
3282 0 : NDR_PULL_ALLOC(ndr, r->old_password);
3283 : } else {
3284 0 : r->old_password = NULL;
3285 : }
3286 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3287 : }
3288 0 : if (ndr_flags & NDR_BUFFERS) {
3289 0 : if (r->password) {
3290 0 : _mem_save_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
3291 0 : NDR_PULL_SET_MEM_CTX(ndr, r->password, 0);
3292 0 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->password));
3293 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_password_0, 0);
3294 : }
3295 0 : if (r->old_password) {
3296 0 : _mem_save_old_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
3297 0 : NDR_PULL_SET_MEM_CTX(ndr, r->old_password, 0);
3298 0 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->old_password));
3299 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_password_0, 0);
3300 : }
3301 : }
3302 0 : return NDR_ERR_SUCCESS;
3303 : }
3304 :
3305 0 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoPassword(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoPassword *r)
3306 : {
3307 0 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoPassword");
3308 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3309 0 : ndr->depth++;
3310 0 : ndr_print_ptr(ndr, "password", r->password);
3311 0 : ndr->depth++;
3312 0 : if (r->password) {
3313 0 : ndr_print_lsa_DATA_BUF(ndr, "password", r->password);
3314 : }
3315 0 : ndr->depth--;
3316 0 : ndr_print_ptr(ndr, "old_password", r->old_password);
3317 0 : ndr->depth++;
3318 0 : if (r->old_password) {
3319 0 : ndr_print_lsa_DATA_BUF(ndr, "old_password", r->old_password);
3320 : }
3321 0 : ndr->depth--;
3322 0 : ndr->depth--;
3323 : }
3324 :
3325 0 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoBasic(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoBasic *r)
3326 : {
3327 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3328 0 : if (ndr_flags & NDR_SCALARS) {
3329 0 : NDR_CHECK(ndr_push_align(ndr, 5));
3330 0 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->netbios_name));
3331 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sid));
3332 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3333 : }
3334 0 : if (ndr_flags & NDR_BUFFERS) {
3335 0 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->netbios_name));
3336 0 : if (r->sid) {
3337 0 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
3338 : }
3339 : }
3340 0 : return NDR_ERR_SUCCESS;
3341 : }
3342 :
3343 0 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoBasic(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoBasic *r)
3344 : {
3345 : uint32_t _ptr_sid;
3346 0 : TALLOC_CTX *_mem_save_sid_0 = NULL;
3347 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3348 0 : if (ndr_flags & NDR_SCALARS) {
3349 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
3350 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->netbios_name));
3351 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
3352 0 : if (_ptr_sid) {
3353 0 : NDR_PULL_ALLOC(ndr, r->sid);
3354 : } else {
3355 0 : r->sid = NULL;
3356 : }
3357 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3358 : }
3359 0 : if (ndr_flags & NDR_BUFFERS) {
3360 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->netbios_name));
3361 0 : if (r->sid) {
3362 0 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
3363 0 : NDR_PULL_SET_MEM_CTX(ndr, r->sid, 0);
3364 0 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
3365 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, 0);
3366 : }
3367 : }
3368 0 : return NDR_ERR_SUCCESS;
3369 : }
3370 :
3371 0 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoBasic(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoBasic *r)
3372 : {
3373 0 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoBasic");
3374 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3375 0 : ndr->depth++;
3376 0 : ndr_print_lsa_String(ndr, "netbios_name", &r->netbios_name);
3377 0 : ndr_print_ptr(ndr, "sid", r->sid);
3378 0 : ndr->depth++;
3379 0 : if (r->sid) {
3380 0 : ndr_print_dom_sid2(ndr, "sid", r->sid);
3381 : }
3382 0 : ndr->depth--;
3383 0 : ndr->depth--;
3384 : }
3385 :
3386 5642 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TrustDomainInfoInfoEx(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoInfoEx *r)
3387 : {
3388 5642 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3389 5642 : if (ndr_flags & NDR_SCALARS) {
3390 2882 : NDR_CHECK(ndr_push_align(ndr, 5));
3391 2882 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->domain_name));
3392 2882 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_name));
3393 2882 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sid));
3394 2882 : NDR_CHECK(ndr_push_lsa_TrustDirection(ndr, NDR_SCALARS, r->trust_direction));
3395 2882 : NDR_CHECK(ndr_push_lsa_TrustType(ndr, NDR_SCALARS, r->trust_type));
3396 2882 : NDR_CHECK(ndr_push_lsa_TrustAttributes(ndr, NDR_SCALARS, r->trust_attributes));
3397 2882 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3398 : }
3399 5642 : if (ndr_flags & NDR_BUFFERS) {
3400 2882 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->domain_name));
3401 2882 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_name));
3402 2882 : if (r->sid) {
3403 2882 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
3404 : }
3405 : }
3406 5642 : return NDR_ERR_SUCCESS;
3407 : }
3408 :
3409 4474 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TrustDomainInfoInfoEx(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoInfoEx *r)
3410 : {
3411 : uint32_t _ptr_sid;
3412 4474 : TALLOC_CTX *_mem_save_sid_0 = NULL;
3413 4474 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3414 4474 : if (ndr_flags & NDR_SCALARS) {
3415 2298 : NDR_CHECK(ndr_pull_align(ndr, 5));
3416 2298 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->domain_name));
3417 2298 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_name));
3418 2298 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
3419 2298 : if (_ptr_sid) {
3420 2298 : NDR_PULL_ALLOC(ndr, r->sid);
3421 : } else {
3422 0 : r->sid = NULL;
3423 : }
3424 2298 : NDR_CHECK(ndr_pull_lsa_TrustDirection(ndr, NDR_SCALARS, &r->trust_direction));
3425 2298 : NDR_CHECK(ndr_pull_lsa_TrustType(ndr, NDR_SCALARS, &r->trust_type));
3426 2298 : NDR_CHECK(ndr_pull_lsa_TrustAttributes(ndr, NDR_SCALARS, &r->trust_attributes));
3427 2298 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3428 : }
3429 4474 : if (ndr_flags & NDR_BUFFERS) {
3430 2298 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->domain_name));
3431 2298 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_name));
3432 2298 : if (r->sid) {
3433 2298 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
3434 2298 : NDR_PULL_SET_MEM_CTX(ndr, r->sid, 0);
3435 2298 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
3436 2298 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, 0);
3437 : }
3438 : }
3439 4474 : return NDR_ERR_SUCCESS;
3440 : }
3441 :
3442 0 : static void ndr_print_flags_lsa_TrustDomainInfoInfoEx(struct ndr_print *ndr, const char *name, int unused, const struct lsa_TrustDomainInfoInfoEx *r)
3443 : {
3444 0 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, name, r);
3445 0 : }
3446 :
3447 1022 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoInfoEx(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoInfoEx *r)
3448 : {
3449 1022 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoInfoEx");
3450 1022 : if (r == NULL) { ndr_print_null(ndr); return; }
3451 1022 : ndr->depth++;
3452 1022 : ndr_print_lsa_StringLarge(ndr, "domain_name", &r->domain_name);
3453 1022 : ndr_print_lsa_StringLarge(ndr, "netbios_name", &r->netbios_name);
3454 1022 : ndr_print_ptr(ndr, "sid", r->sid);
3455 1022 : ndr->depth++;
3456 1022 : if (r->sid) {
3457 1022 : ndr_print_dom_sid2(ndr, "sid", r->sid);
3458 : }
3459 1022 : ndr->depth--;
3460 1022 : ndr_print_lsa_TrustDirection(ndr, "trust_direction", r->trust_direction);
3461 1022 : ndr_print_lsa_TrustType(ndr, "trust_type", r->trust_type);
3462 1022 : ndr_print_lsa_TrustAttributes(ndr, "trust_attributes", r->trust_attributes);
3463 1022 : ndr->depth--;
3464 : }
3465 :
3466 4960 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TrustAuthType(struct ndr_push *ndr, int ndr_flags, enum lsa_TrustAuthType r)
3467 : {
3468 4960 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
3469 4960 : return NDR_ERR_SUCCESS;
3470 : }
3471 :
3472 5851 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TrustAuthType(struct ndr_pull *ndr, int ndr_flags, enum lsa_TrustAuthType *r)
3473 : {
3474 : uint32_t v;
3475 5851 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
3476 5851 : *r = v;
3477 5851 : return NDR_ERR_SUCCESS;
3478 : }
3479 :
3480 0 : _PUBLIC_ void ndr_print_lsa_TrustAuthType(struct ndr_print *ndr, const char *name, enum lsa_TrustAuthType r)
3481 : {
3482 0 : const char *val = NULL;
3483 :
3484 0 : switch (r) {
3485 0 : case TRUST_AUTH_TYPE_NONE: val = "TRUST_AUTH_TYPE_NONE"; break;
3486 0 : case TRUST_AUTH_TYPE_NT4OWF: val = "TRUST_AUTH_TYPE_NT4OWF"; break;
3487 0 : case TRUST_AUTH_TYPE_CLEAR: val = "TRUST_AUTH_TYPE_CLEAR"; break;
3488 0 : case TRUST_AUTH_TYPE_VERSION: val = "TRUST_AUTH_TYPE_VERSION"; break;
3489 : }
3490 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
3491 0 : }
3492 :
3493 192 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoBuffer(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoBuffer *r)
3494 : {
3495 192 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3496 192 : if (ndr_flags & NDR_SCALARS) {
3497 192 : NDR_CHECK(ndr_push_align(ndr, 8));
3498 192 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, r->last_update_time));
3499 192 : NDR_CHECK(ndr_push_lsa_TrustAuthType(ndr, NDR_SCALARS, r->AuthType));
3500 192 : NDR_CHECK(ndr_push_lsa_DATA_BUF2(ndr, NDR_SCALARS, &r->data));
3501 192 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
3502 : }
3503 192 : if (ndr_flags & NDR_BUFFERS) {
3504 192 : NDR_CHECK(ndr_push_lsa_DATA_BUF2(ndr, NDR_BUFFERS, &r->data));
3505 : }
3506 192 : return NDR_ERR_SUCCESS;
3507 : }
3508 :
3509 192 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoBuffer(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoBuffer *r)
3510 : {
3511 192 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3512 192 : if (ndr_flags & NDR_SCALARS) {
3513 192 : NDR_CHECK(ndr_pull_align(ndr, 8));
3514 192 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, &r->last_update_time));
3515 192 : NDR_CHECK(ndr_pull_lsa_TrustAuthType(ndr, NDR_SCALARS, &r->AuthType));
3516 192 : NDR_CHECK(ndr_pull_lsa_DATA_BUF2(ndr, NDR_SCALARS, &r->data));
3517 192 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
3518 : }
3519 192 : if (ndr_flags & NDR_BUFFERS) {
3520 192 : NDR_CHECK(ndr_pull_lsa_DATA_BUF2(ndr, NDR_BUFFERS, &r->data));
3521 : }
3522 192 : return NDR_ERR_SUCCESS;
3523 : }
3524 :
3525 0 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoBuffer(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoBuffer *r)
3526 : {
3527 0 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoBuffer");
3528 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3529 0 : ndr->depth++;
3530 0 : ndr_print_NTTIME_hyper(ndr, "last_update_time", r->last_update_time);
3531 0 : ndr_print_lsa_TrustAuthType(ndr, "AuthType", r->AuthType);
3532 0 : ndr_print_lsa_DATA_BUF2(ndr, "data", &r->data);
3533 0 : ndr->depth--;
3534 : }
3535 :
3536 3012 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_TrustDomainInfoAuthInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoAuthInfo *r)
3537 : {
3538 3012 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3539 3012 : if (ndr_flags & NDR_SCALARS) {
3540 1530 : NDR_CHECK(ndr_push_align(ndr, 5));
3541 1530 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->incoming_count));
3542 1530 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->incoming_current_auth_info));
3543 1530 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->incoming_previous_auth_info));
3544 1530 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->outgoing_count));
3545 1530 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->outgoing_current_auth_info));
3546 1530 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->outgoing_previous_auth_info));
3547 1530 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3548 : }
3549 3012 : if (ndr_flags & NDR_BUFFERS) {
3550 1530 : if (r->incoming_current_auth_info) {
3551 48 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->incoming_current_auth_info));
3552 : }
3553 1530 : if (r->incoming_previous_auth_info) {
3554 48 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->incoming_previous_auth_info));
3555 : }
3556 1530 : if (r->outgoing_current_auth_info) {
3557 48 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->outgoing_current_auth_info));
3558 : }
3559 1530 : if (r->outgoing_previous_auth_info) {
3560 48 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->outgoing_previous_auth_info));
3561 : }
3562 : }
3563 3012 : return NDR_ERR_SUCCESS;
3564 : }
3565 :
3566 2432 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_TrustDomainInfoAuthInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoAuthInfo *r)
3567 : {
3568 : uint32_t _ptr_incoming_current_auth_info;
3569 2432 : TALLOC_CTX *_mem_save_incoming_current_auth_info_0 = NULL;
3570 : uint32_t _ptr_incoming_previous_auth_info;
3571 2432 : TALLOC_CTX *_mem_save_incoming_previous_auth_info_0 = NULL;
3572 : uint32_t _ptr_outgoing_current_auth_info;
3573 2432 : TALLOC_CTX *_mem_save_outgoing_current_auth_info_0 = NULL;
3574 : uint32_t _ptr_outgoing_previous_auth_info;
3575 2432 : TALLOC_CTX *_mem_save_outgoing_previous_auth_info_0 = NULL;
3576 2432 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3577 2432 : if (ndr_flags & NDR_SCALARS) {
3578 1240 : NDR_CHECK(ndr_pull_align(ndr, 5));
3579 1240 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->incoming_count));
3580 1240 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_incoming_current_auth_info));
3581 1240 : if (_ptr_incoming_current_auth_info) {
3582 48 : NDR_PULL_ALLOC(ndr, r->incoming_current_auth_info);
3583 : } else {
3584 1192 : r->incoming_current_auth_info = NULL;
3585 : }
3586 1240 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_incoming_previous_auth_info));
3587 1240 : if (_ptr_incoming_previous_auth_info) {
3588 48 : NDR_PULL_ALLOC(ndr, r->incoming_previous_auth_info);
3589 : } else {
3590 1192 : r->incoming_previous_auth_info = NULL;
3591 : }
3592 1240 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->outgoing_count));
3593 1240 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_outgoing_current_auth_info));
3594 1240 : if (_ptr_outgoing_current_auth_info) {
3595 48 : NDR_PULL_ALLOC(ndr, r->outgoing_current_auth_info);
3596 : } else {
3597 1192 : r->outgoing_current_auth_info = NULL;
3598 : }
3599 1240 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_outgoing_previous_auth_info));
3600 1240 : if (_ptr_outgoing_previous_auth_info) {
3601 48 : NDR_PULL_ALLOC(ndr, r->outgoing_previous_auth_info);
3602 : } else {
3603 1192 : r->outgoing_previous_auth_info = NULL;
3604 : }
3605 1240 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3606 : }
3607 2432 : if (ndr_flags & NDR_BUFFERS) {
3608 1240 : if (r->incoming_current_auth_info) {
3609 48 : _mem_save_incoming_current_auth_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
3610 48 : NDR_PULL_SET_MEM_CTX(ndr, r->incoming_current_auth_info, 0);
3611 48 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->incoming_current_auth_info));
3612 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_incoming_current_auth_info_0, 0);
3613 : }
3614 1240 : if (r->incoming_previous_auth_info) {
3615 48 : _mem_save_incoming_previous_auth_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
3616 48 : NDR_PULL_SET_MEM_CTX(ndr, r->incoming_previous_auth_info, 0);
3617 48 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->incoming_previous_auth_info));
3618 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_incoming_previous_auth_info_0, 0);
3619 : }
3620 1240 : if (r->outgoing_current_auth_info) {
3621 48 : _mem_save_outgoing_current_auth_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
3622 48 : NDR_PULL_SET_MEM_CTX(ndr, r->outgoing_current_auth_info, 0);
3623 48 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->outgoing_current_auth_info));
3624 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_outgoing_current_auth_info_0, 0);
3625 : }
3626 1240 : if (r->outgoing_previous_auth_info) {
3627 48 : _mem_save_outgoing_previous_auth_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
3628 48 : NDR_PULL_SET_MEM_CTX(ndr, r->outgoing_previous_auth_info, 0);
3629 48 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoBuffer(ndr, NDR_SCALARS|NDR_BUFFERS, r->outgoing_previous_auth_info));
3630 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_outgoing_previous_auth_info_0, 0);
3631 : }
3632 : }
3633 2432 : return NDR_ERR_SUCCESS;
3634 : }
3635 :
3636 0 : static void ndr_print_flags_lsa_TrustDomainInfoAuthInfo(struct ndr_print *ndr, const char *name, int unused, const struct lsa_TrustDomainInfoAuthInfo *r)
3637 : {
3638 0 : ndr_print_lsa_TrustDomainInfoAuthInfo(ndr, name, r);
3639 0 : }
3640 :
3641 580 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoAuthInfo(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoAuthInfo *r)
3642 : {
3643 580 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoAuthInfo");
3644 580 : if (r == NULL) { ndr_print_null(ndr); return; }
3645 580 : ndr->depth++;
3646 580 : ndr_print_uint32(ndr, "incoming_count", r->incoming_count);
3647 580 : ndr_print_ptr(ndr, "incoming_current_auth_info", r->incoming_current_auth_info);
3648 580 : ndr->depth++;
3649 580 : if (r->incoming_current_auth_info) {
3650 0 : ndr_print_lsa_TrustDomainInfoBuffer(ndr, "incoming_current_auth_info", r->incoming_current_auth_info);
3651 : }
3652 580 : ndr->depth--;
3653 580 : ndr_print_ptr(ndr, "incoming_previous_auth_info", r->incoming_previous_auth_info);
3654 580 : ndr->depth++;
3655 580 : if (r->incoming_previous_auth_info) {
3656 0 : ndr_print_lsa_TrustDomainInfoBuffer(ndr, "incoming_previous_auth_info", r->incoming_previous_auth_info);
3657 : }
3658 580 : ndr->depth--;
3659 580 : ndr_print_uint32(ndr, "outgoing_count", r->outgoing_count);
3660 580 : ndr_print_ptr(ndr, "outgoing_current_auth_info", r->outgoing_current_auth_info);
3661 580 : ndr->depth++;
3662 580 : if (r->outgoing_current_auth_info) {
3663 0 : ndr_print_lsa_TrustDomainInfoBuffer(ndr, "outgoing_current_auth_info", r->outgoing_current_auth_info);
3664 : }
3665 580 : ndr->depth--;
3666 580 : ndr_print_ptr(ndr, "outgoing_previous_auth_info", r->outgoing_previous_auth_info);
3667 580 : ndr->depth++;
3668 580 : if (r->outgoing_previous_auth_info) {
3669 0 : ndr_print_lsa_TrustDomainInfoBuffer(ndr, "outgoing_previous_auth_info", r->outgoing_previous_auth_info);
3670 : }
3671 580 : ndr->depth--;
3672 580 : ndr->depth--;
3673 : }
3674 :
3675 1506 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoFullInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoFullInfo *r)
3676 : {
3677 1506 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3678 1506 : if (ndr_flags & NDR_SCALARS) {
3679 753 : NDR_CHECK(ndr_push_align(ndr, 5));
3680 753 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
3681 753 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
3682 753 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS, &r->auth_info));
3683 753 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3684 : }
3685 1506 : if (ndr_flags & NDR_BUFFERS) {
3686 753 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
3687 753 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfo(ndr, NDR_BUFFERS, &r->auth_info));
3688 : }
3689 1506 : return NDR_ERR_SUCCESS;
3690 : }
3691 :
3692 1216 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoFullInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoFullInfo *r)
3693 : {
3694 1216 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3695 1216 : if (ndr_flags & NDR_SCALARS) {
3696 608 : NDR_CHECK(ndr_pull_align(ndr, 5));
3697 608 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
3698 608 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
3699 608 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS, &r->auth_info));
3700 608 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3701 : }
3702 1216 : if (ndr_flags & NDR_BUFFERS) {
3703 608 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
3704 608 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfo(ndr, NDR_BUFFERS, &r->auth_info));
3705 : }
3706 1216 : return NDR_ERR_SUCCESS;
3707 : }
3708 :
3709 290 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoFullInfo(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoFullInfo *r)
3710 : {
3711 290 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoFullInfo");
3712 290 : if (r == NULL) { ndr_print_null(ndr); return; }
3713 290 : ndr->depth++;
3714 290 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "info_ex", &r->info_ex);
3715 290 : ndr_print_lsa_TrustDomainInfoPosixOffset(ndr, "posix_offset", &r->posix_offset);
3716 290 : ndr_print_lsa_TrustDomainInfoAuthInfo(ndr, "auth_info", &r->auth_info);
3717 290 : ndr->depth--;
3718 : }
3719 :
3720 74 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoAuthInfoInternal(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoAuthInfoInternal *r)
3721 : {
3722 74 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3723 74 : if (ndr_flags & NDR_SCALARS) {
3724 74 : NDR_CHECK(ndr_push_align(ndr, 5));
3725 74 : NDR_CHECK(ndr_push_lsa_DATA_BUF2(ndr, NDR_SCALARS, &r->auth_blob));
3726 74 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3727 : }
3728 74 : if (ndr_flags & NDR_BUFFERS) {
3729 74 : NDR_CHECK(ndr_push_lsa_DATA_BUF2(ndr, NDR_BUFFERS, &r->auth_blob));
3730 : }
3731 74 : return NDR_ERR_SUCCESS;
3732 : }
3733 :
3734 74 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoAuthInfoInternal(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoAuthInfoInternal *r)
3735 : {
3736 74 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3737 74 : if (ndr_flags & NDR_SCALARS) {
3738 74 : NDR_CHECK(ndr_pull_align(ndr, 5));
3739 74 : NDR_CHECK(ndr_pull_lsa_DATA_BUF2(ndr, NDR_SCALARS, &r->auth_blob));
3740 74 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3741 : }
3742 74 : if (ndr_flags & NDR_BUFFERS) {
3743 74 : NDR_CHECK(ndr_pull_lsa_DATA_BUF2(ndr, NDR_BUFFERS, &r->auth_blob));
3744 : }
3745 74 : return NDR_ERR_SUCCESS;
3746 : }
3747 :
3748 0 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoAuthInfoInternal(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoAuthInfoInternal *r)
3749 : {
3750 0 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoAuthInfoInternal");
3751 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3752 0 : ndr->depth++;
3753 0 : ndr_print_lsa_DATA_BUF2(ndr, "auth_blob", &r->auth_blob);
3754 0 : ndr->depth--;
3755 : }
3756 :
3757 0 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoFullInfoInternal(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoFullInfoInternal *r)
3758 : {
3759 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3760 0 : if (ndr_flags & NDR_SCALARS) {
3761 0 : NDR_CHECK(ndr_push_align(ndr, 5));
3762 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
3763 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
3764 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_SCALARS, &r->auth_info));
3765 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3766 : }
3767 0 : if (ndr_flags & NDR_BUFFERS) {
3768 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
3769 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_BUFFERS, &r->auth_info));
3770 : }
3771 0 : return NDR_ERR_SUCCESS;
3772 : }
3773 :
3774 0 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoFullInfoInternal(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoFullInfoInternal *r)
3775 : {
3776 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3777 0 : if (ndr_flags & NDR_SCALARS) {
3778 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
3779 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
3780 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
3781 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_SCALARS, &r->auth_info));
3782 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3783 : }
3784 0 : if (ndr_flags & NDR_BUFFERS) {
3785 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
3786 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_BUFFERS, &r->auth_info));
3787 : }
3788 0 : return NDR_ERR_SUCCESS;
3789 : }
3790 :
3791 0 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoFullInfoInternal(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoFullInfoInternal *r)
3792 : {
3793 0 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoFullInfoInternal");
3794 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3795 0 : ndr->depth++;
3796 0 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "info_ex", &r->info_ex);
3797 0 : ndr_print_lsa_TrustDomainInfoPosixOffset(ndr, "posix_offset", &r->posix_offset);
3798 0 : ndr_print_lsa_TrustDomainInfoAuthInfoInternal(ndr, "auth_info", &r->auth_info);
3799 0 : ndr->depth--;
3800 : }
3801 :
3802 1458 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoInfoEx2Internal(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoInfoEx2Internal *r)
3803 : {
3804 1458 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3805 1458 : if (ndr_flags & NDR_SCALARS) {
3806 729 : NDR_CHECK(ndr_push_align(ndr, 5));
3807 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
3808 729 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->forest_trust_length));
3809 729 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->forest_trust_data));
3810 729 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3811 : }
3812 1458 : if (ndr_flags & NDR_BUFFERS) {
3813 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
3814 729 : if (r->forest_trust_data) {
3815 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->forest_trust_length));
3816 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->forest_trust_data, r->forest_trust_length));
3817 : }
3818 : }
3819 1458 : return NDR_ERR_SUCCESS;
3820 : }
3821 :
3822 1168 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoInfoEx2Internal(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoInfoEx2Internal *r)
3823 : {
3824 : uint32_t _ptr_forest_trust_data;
3825 1168 : uint32_t size_forest_trust_data_1 = 0;
3826 1168 : TALLOC_CTX *_mem_save_forest_trust_data_0 = NULL;
3827 1168 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3828 1168 : if (ndr_flags & NDR_SCALARS) {
3829 584 : NDR_CHECK(ndr_pull_align(ndr, 5));
3830 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
3831 584 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->forest_trust_length));
3832 584 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_forest_trust_data));
3833 584 : if (_ptr_forest_trust_data) {
3834 0 : NDR_PULL_ALLOC(ndr, r->forest_trust_data);
3835 : } else {
3836 584 : r->forest_trust_data = NULL;
3837 : }
3838 584 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3839 : }
3840 1168 : if (ndr_flags & NDR_BUFFERS) {
3841 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
3842 584 : if (r->forest_trust_data) {
3843 0 : _mem_save_forest_trust_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
3844 0 : NDR_PULL_SET_MEM_CTX(ndr, r->forest_trust_data, 0);
3845 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->forest_trust_data));
3846 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->forest_trust_data, &size_forest_trust_data_1));
3847 0 : NDR_PULL_ALLOC_N(ndr, r->forest_trust_data, size_forest_trust_data_1);
3848 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->forest_trust_data, size_forest_trust_data_1));
3849 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_trust_data_0, 0);
3850 : }
3851 584 : if (r->forest_trust_data) {
3852 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->forest_trust_data, r->forest_trust_length));
3853 : }
3854 : }
3855 1168 : return NDR_ERR_SUCCESS;
3856 : }
3857 :
3858 290 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoInfoEx2Internal(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoInfoEx2Internal *r)
3859 : {
3860 290 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoInfoEx2Internal");
3861 290 : if (r == NULL) { ndr_print_null(ndr); return; }
3862 290 : ndr->depth++;
3863 290 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "info_ex", &r->info_ex);
3864 290 : ndr_print_uint32(ndr, "forest_trust_length", r->forest_trust_length);
3865 290 : ndr_print_ptr(ndr, "forest_trust_data", r->forest_trust_data);
3866 290 : ndr->depth++;
3867 290 : if (r->forest_trust_data) {
3868 0 : ndr_print_array_uint8(ndr, "forest_trust_data", r->forest_trust_data, r->forest_trust_length);
3869 : }
3870 290 : ndr->depth--;
3871 290 : ndr->depth--;
3872 : }
3873 :
3874 1458 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoFullInfo2Internal(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoFullInfo2Internal *r)
3875 : {
3876 1458 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3877 1458 : if (ndr_flags & NDR_SCALARS) {
3878 729 : NDR_CHECK(ndr_push_align(ndr, 5));
3879 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_SCALARS, &r->info));
3880 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
3881 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS, &r->auth_info));
3882 729 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3883 : }
3884 1458 : if (ndr_flags & NDR_BUFFERS) {
3885 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_BUFFERS, &r->info));
3886 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfo(ndr, NDR_BUFFERS, &r->auth_info));
3887 : }
3888 1458 : return NDR_ERR_SUCCESS;
3889 : }
3890 :
3891 1168 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoFullInfo2Internal(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoFullInfo2Internal *r)
3892 : {
3893 1168 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3894 1168 : if (ndr_flags & NDR_SCALARS) {
3895 584 : NDR_CHECK(ndr_pull_align(ndr, 5));
3896 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_SCALARS, &r->info));
3897 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
3898 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS, &r->auth_info));
3899 584 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3900 : }
3901 1168 : if (ndr_flags & NDR_BUFFERS) {
3902 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_BUFFERS, &r->info));
3903 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfo(ndr, NDR_BUFFERS, &r->auth_info));
3904 : }
3905 1168 : return NDR_ERR_SUCCESS;
3906 : }
3907 :
3908 290 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoFullInfo2Internal(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoFullInfo2Internal *r)
3909 : {
3910 290 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoFullInfo2Internal");
3911 290 : if (r == NULL) { ndr_print_null(ndr); return; }
3912 290 : ndr->depth++;
3913 290 : ndr_print_lsa_TrustDomainInfoInfoEx2Internal(ndr, "info", &r->info);
3914 290 : ndr_print_lsa_TrustDomainInfoPosixOffset(ndr, "posix_offset", &r->posix_offset);
3915 290 : ndr_print_lsa_TrustDomainInfoAuthInfo(ndr, "auth_info", &r->auth_info);
3916 290 : ndr->depth--;
3917 : }
3918 :
3919 775 : static enum ndr_err_code ndr_push_lsa_TrustDomainInfoSupportedEncTypes(struct ndr_push *ndr, int ndr_flags, const struct lsa_TrustDomainInfoSupportedEncTypes *r)
3920 : {
3921 775 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3922 775 : if (ndr_flags & NDR_SCALARS) {
3923 775 : NDR_CHECK(ndr_push_align(ndr, 4));
3924 775 : NDR_CHECK(ndr_push_kerb_EncTypes(ndr, NDR_SCALARS, r->enc_types));
3925 775 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
3926 : }
3927 775 : if (ndr_flags & NDR_BUFFERS) {
3928 : }
3929 775 : return NDR_ERR_SUCCESS;
3930 : }
3931 :
3932 630 : static enum ndr_err_code ndr_pull_lsa_TrustDomainInfoSupportedEncTypes(struct ndr_pull *ndr, int ndr_flags, struct lsa_TrustDomainInfoSupportedEncTypes *r)
3933 : {
3934 630 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3935 630 : if (ndr_flags & NDR_SCALARS) {
3936 630 : NDR_CHECK(ndr_pull_align(ndr, 4));
3937 630 : NDR_CHECK(ndr_pull_kerb_EncTypes(ndr, NDR_SCALARS, &r->enc_types));
3938 630 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
3939 : }
3940 630 : if (ndr_flags & NDR_BUFFERS) {
3941 : }
3942 630 : return NDR_ERR_SUCCESS;
3943 : }
3944 :
3945 290 : _PUBLIC_ void ndr_print_lsa_TrustDomainInfoSupportedEncTypes(struct ndr_print *ndr, const char *name, const struct lsa_TrustDomainInfoSupportedEncTypes *r)
3946 : {
3947 290 : ndr_print_struct(ndr, name, "lsa_TrustDomainInfoSupportedEncTypes");
3948 290 : if (r == NULL) { ndr_print_null(ndr); return; }
3949 290 : ndr->depth++;
3950 290 : ndr_print_kerb_EncTypes(ndr, "enc_types", r->enc_types);
3951 290 : ndr->depth--;
3952 : }
3953 :
3954 4798 : static enum ndr_err_code ndr_push_lsa_TrustedDomainInfo(struct ndr_push *ndr, int ndr_flags, const union lsa_TrustedDomainInfo *r)
3955 : {
3956 : uint32_t level;
3957 4798 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3958 4798 : if (ndr_flags & NDR_SCALARS) {
3959 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
3960 4798 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
3961 4798 : NDR_CHECK(ndr_push_union_align(ndr, 5));
3962 4798 : NDR_CHECK(ndr_push_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, level));
3963 4798 : NDR_CHECK(ndr_push_union_align(ndr, 5));
3964 4798 : switch (level) {
3965 729 : case LSA_TRUSTED_DOMAIN_INFO_NAME: {
3966 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoName(ndr, NDR_SCALARS, &r->name));
3967 729 : break; }
3968 :
3969 0 : case LSA_TRUSTED_DOMAIN_INFO_CONTROLLERS: {
3970 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoControllers(ndr, NDR_SCALARS, &r->controllers));
3971 0 : break; }
3972 :
3973 729 : case LSA_TRUSTED_DOMAIN_INFO_POSIX_OFFSET: {
3974 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
3975 729 : break; }
3976 :
3977 0 : case LSA_TRUSTED_DOMAIN_INFO_PASSWORD: {
3978 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoPassword(ndr, NDR_SCALARS, &r->password));
3979 0 : break; }
3980 :
3981 0 : case LSA_TRUSTED_DOMAIN_INFO_BASIC: {
3982 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoBasic(ndr, NDR_SCALARS, &r->info_basic));
3983 0 : break; }
3984 :
3985 1083 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX: {
3986 1083 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
3987 1083 : break; }
3988 :
3989 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO: {
3990 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS, &r->auth_info));
3991 0 : break; }
3992 :
3993 753 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO: {
3994 753 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoFullInfo(ndr, NDR_SCALARS, &r->full_info));
3995 753 : break; }
3996 :
3997 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO_INTERNAL: {
3998 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_SCALARS, &r->auth_info_internal));
3999 0 : break; }
4000 :
4001 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_INTERNAL: {
4002 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoFullInfoInternal(ndr, NDR_SCALARS, &r->full_info_internal));
4003 0 : break; }
4004 :
4005 0 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX2_INTERNAL: {
4006 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_SCALARS, &r->info_ex2_internal));
4007 0 : break; }
4008 :
4009 729 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_2_INTERNAL: {
4010 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoFullInfo2Internal(ndr, NDR_SCALARS, &r->full_info2_internal));
4011 729 : break; }
4012 :
4013 775 : case LSA_TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES: {
4014 775 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoSupportedEncTypes(ndr, NDR_SCALARS, &r->enc_types));
4015 775 : break; }
4016 :
4017 0 : default:
4018 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
4019 : }
4020 0 : }
4021 4798 : if (ndr_flags & NDR_BUFFERS) {
4022 4798 : if (!(ndr_flags & NDR_SCALARS)) {
4023 : /* We didn't get it above, and the token is not needed after this. */
4024 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
4025 : }
4026 4798 : switch (level) {
4027 729 : case LSA_TRUSTED_DOMAIN_INFO_NAME:
4028 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoName(ndr, NDR_BUFFERS, &r->name));
4029 729 : break;
4030 :
4031 0 : case LSA_TRUSTED_DOMAIN_INFO_CONTROLLERS:
4032 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoControllers(ndr, NDR_BUFFERS, &r->controllers));
4033 0 : break;
4034 :
4035 729 : case LSA_TRUSTED_DOMAIN_INFO_POSIX_OFFSET:
4036 729 : break;
4037 :
4038 0 : case LSA_TRUSTED_DOMAIN_INFO_PASSWORD:
4039 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoPassword(ndr, NDR_BUFFERS, &r->password));
4040 0 : break;
4041 :
4042 0 : case LSA_TRUSTED_DOMAIN_INFO_BASIC:
4043 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoBasic(ndr, NDR_BUFFERS, &r->info_basic));
4044 0 : break;
4045 :
4046 1083 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX:
4047 1083 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
4048 1083 : break;
4049 :
4050 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO:
4051 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfo(ndr, NDR_BUFFERS, &r->auth_info));
4052 0 : break;
4053 :
4054 753 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO:
4055 753 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoFullInfo(ndr, NDR_BUFFERS, &r->full_info));
4056 753 : break;
4057 :
4058 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO_INTERNAL:
4059 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_BUFFERS, &r->auth_info_internal));
4060 0 : break;
4061 :
4062 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_INTERNAL:
4063 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoFullInfoInternal(ndr, NDR_BUFFERS, &r->full_info_internal));
4064 0 : break;
4065 :
4066 0 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX2_INTERNAL:
4067 0 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_BUFFERS, &r->info_ex2_internal));
4068 0 : break;
4069 :
4070 729 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_2_INTERNAL:
4071 729 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoFullInfo2Internal(ndr, NDR_BUFFERS, &r->full_info2_internal));
4072 729 : break;
4073 :
4074 775 : case LSA_TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES:
4075 775 : break;
4076 :
4077 0 : default:
4078 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
4079 : }
4080 0 : }
4081 4798 : return NDR_ERR_SUCCESS;
4082 : }
4083 :
4084 3818 : static enum ndr_err_code ndr_pull_lsa_TrustedDomainInfo(struct ndr_pull *ndr, int ndr_flags, union lsa_TrustedDomainInfo *r)
4085 : {
4086 : uint32_t level;
4087 : uint16_t _level;
4088 3818 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4089 3818 : if (ndr_flags & NDR_SCALARS) {
4090 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
4091 3818 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
4092 3818 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
4093 3818 : NDR_CHECK(ndr_pull_uint1632(ndr, NDR_SCALARS, &_level));
4094 3818 : if (_level != level) {
4095 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r at %s", _level, __location__);
4096 : }
4097 3818 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
4098 3818 : switch (level) {
4099 584 : case LSA_TRUSTED_DOMAIN_INFO_NAME: {
4100 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoName(ndr, NDR_SCALARS, &r->name));
4101 584 : break; }
4102 :
4103 0 : case LSA_TRUSTED_DOMAIN_INFO_CONTROLLERS: {
4104 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoControllers(ndr, NDR_SCALARS, &r->controllers));
4105 0 : break; }
4106 :
4107 584 : case LSA_TRUSTED_DOMAIN_INFO_POSIX_OFFSET: {
4108 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoPosixOffset(ndr, NDR_SCALARS, &r->posix_offset));
4109 584 : break; }
4110 :
4111 0 : case LSA_TRUSTED_DOMAIN_INFO_PASSWORD: {
4112 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoPassword(ndr, NDR_SCALARS, &r->password));
4113 0 : break; }
4114 :
4115 0 : case LSA_TRUSTED_DOMAIN_INFO_BASIC: {
4116 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoBasic(ndr, NDR_SCALARS, &r->info_basic));
4117 0 : break; }
4118 :
4119 828 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX: {
4120 828 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->info_ex));
4121 828 : break; }
4122 :
4123 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO: {
4124 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS, &r->auth_info));
4125 0 : break; }
4126 :
4127 608 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO: {
4128 608 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoFullInfo(ndr, NDR_SCALARS, &r->full_info));
4129 608 : break; }
4130 :
4131 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO_INTERNAL: {
4132 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_SCALARS, &r->auth_info_internal));
4133 0 : break; }
4134 :
4135 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_INTERNAL: {
4136 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoFullInfoInternal(ndr, NDR_SCALARS, &r->full_info_internal));
4137 0 : break; }
4138 :
4139 0 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX2_INTERNAL: {
4140 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_SCALARS, &r->info_ex2_internal));
4141 0 : break; }
4142 :
4143 584 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_2_INTERNAL: {
4144 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoFullInfo2Internal(ndr, NDR_SCALARS, &r->full_info2_internal));
4145 584 : break; }
4146 :
4147 630 : case LSA_TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES: {
4148 630 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoSupportedEncTypes(ndr, NDR_SCALARS, &r->enc_types));
4149 630 : break; }
4150 :
4151 0 : default:
4152 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
4153 : }
4154 0 : }
4155 3818 : if (ndr_flags & NDR_BUFFERS) {
4156 3818 : if (!(ndr_flags & NDR_SCALARS)) {
4157 : /* We didn't get it above, and the token is not needed after this. */
4158 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
4159 : }
4160 3818 : switch (level) {
4161 584 : case LSA_TRUSTED_DOMAIN_INFO_NAME:
4162 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoName(ndr, NDR_BUFFERS, &r->name));
4163 584 : break;
4164 :
4165 0 : case LSA_TRUSTED_DOMAIN_INFO_CONTROLLERS:
4166 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoControllers(ndr, NDR_BUFFERS, &r->controllers));
4167 0 : break;
4168 :
4169 584 : case LSA_TRUSTED_DOMAIN_INFO_POSIX_OFFSET:
4170 584 : break;
4171 :
4172 0 : case LSA_TRUSTED_DOMAIN_INFO_PASSWORD:
4173 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoPassword(ndr, NDR_BUFFERS, &r->password));
4174 0 : break;
4175 :
4176 0 : case LSA_TRUSTED_DOMAIN_INFO_BASIC:
4177 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoBasic(ndr, NDR_BUFFERS, &r->info_basic));
4178 0 : break;
4179 :
4180 828 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX:
4181 828 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->info_ex));
4182 828 : break;
4183 :
4184 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO:
4185 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfo(ndr, NDR_BUFFERS, &r->auth_info));
4186 0 : break;
4187 :
4188 608 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO:
4189 608 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoFullInfo(ndr, NDR_BUFFERS, &r->full_info));
4190 608 : break;
4191 :
4192 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO_INTERNAL:
4193 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_BUFFERS, &r->auth_info_internal));
4194 0 : break;
4195 :
4196 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_INTERNAL:
4197 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoFullInfoInternal(ndr, NDR_BUFFERS, &r->full_info_internal));
4198 0 : break;
4199 :
4200 0 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX2_INTERNAL:
4201 0 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx2Internal(ndr, NDR_BUFFERS, &r->info_ex2_internal));
4202 0 : break;
4203 :
4204 584 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_2_INTERNAL:
4205 584 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoFullInfo2Internal(ndr, NDR_BUFFERS, &r->full_info2_internal));
4206 584 : break;
4207 :
4208 630 : case LSA_TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES:
4209 630 : break;
4210 :
4211 0 : default:
4212 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
4213 : }
4214 0 : }
4215 3818 : return NDR_ERR_SUCCESS;
4216 : }
4217 :
4218 1814 : _PUBLIC_ void ndr_print_lsa_TrustedDomainInfo(struct ndr_print *ndr, const char *name, const union lsa_TrustedDomainInfo *r)
4219 : {
4220 : uint32_t level;
4221 1814 : level = ndr_print_steal_switch_value(ndr, r);
4222 1814 : ndr_print_union(ndr, name, level, "lsa_TrustedDomainInfo");
4223 1814 : switch (level) {
4224 290 : case LSA_TRUSTED_DOMAIN_INFO_NAME:
4225 290 : ndr_print_lsa_TrustDomainInfoName(ndr, "name", &r->name);
4226 290 : break;
4227 :
4228 0 : case LSA_TRUSTED_DOMAIN_INFO_CONTROLLERS:
4229 0 : ndr_print_lsa_TrustDomainInfoControllers(ndr, "controllers", &r->controllers);
4230 0 : break;
4231 :
4232 290 : case LSA_TRUSTED_DOMAIN_INFO_POSIX_OFFSET:
4233 290 : ndr_print_lsa_TrustDomainInfoPosixOffset(ndr, "posix_offset", &r->posix_offset);
4234 290 : break;
4235 :
4236 0 : case LSA_TRUSTED_DOMAIN_INFO_PASSWORD:
4237 0 : ndr_print_lsa_TrustDomainInfoPassword(ndr, "password", &r->password);
4238 0 : break;
4239 :
4240 0 : case LSA_TRUSTED_DOMAIN_INFO_BASIC:
4241 0 : ndr_print_lsa_TrustDomainInfoBasic(ndr, "info_basic", &r->info_basic);
4242 0 : break;
4243 :
4244 364 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX:
4245 364 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "info_ex", &r->info_ex);
4246 364 : break;
4247 :
4248 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO:
4249 0 : ndr_print_lsa_TrustDomainInfoAuthInfo(ndr, "auth_info", &r->auth_info);
4250 0 : break;
4251 :
4252 290 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO:
4253 290 : ndr_print_lsa_TrustDomainInfoFullInfo(ndr, "full_info", &r->full_info);
4254 290 : break;
4255 :
4256 0 : case LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO_INTERNAL:
4257 0 : ndr_print_lsa_TrustDomainInfoAuthInfoInternal(ndr, "auth_info_internal", &r->auth_info_internal);
4258 0 : break;
4259 :
4260 0 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_INTERNAL:
4261 0 : ndr_print_lsa_TrustDomainInfoFullInfoInternal(ndr, "full_info_internal", &r->full_info_internal);
4262 0 : break;
4263 :
4264 0 : case LSA_TRUSTED_DOMAIN_INFO_INFO_EX2_INTERNAL:
4265 0 : ndr_print_lsa_TrustDomainInfoInfoEx2Internal(ndr, "info_ex2_internal", &r->info_ex2_internal);
4266 0 : break;
4267 :
4268 290 : case LSA_TRUSTED_DOMAIN_INFO_FULL_INFO_2_INTERNAL:
4269 290 : ndr_print_lsa_TrustDomainInfoFullInfo2Internal(ndr, "full_info2_internal", &r->full_info2_internal);
4270 290 : break;
4271 :
4272 290 : case LSA_TRUSTED_DOMAIN_SUPPORTED_ENCRYPTION_TYPES:
4273 290 : ndr_print_lsa_TrustDomainInfoSupportedEncTypes(ndr, "enc_types", &r->enc_types);
4274 290 : break;
4275 :
4276 0 : default:
4277 0 : ndr_print_bad_level(ndr, name, level);
4278 : }
4279 1814 : }
4280 :
4281 2476 : static enum ndr_err_code ndr_push_lsa_DATA_BUF_PTR(struct ndr_push *ndr, int ndr_flags, const struct lsa_DATA_BUF_PTR *r)
4282 : {
4283 2476 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4284 2476 : if (ndr_flags & NDR_SCALARS) {
4285 2476 : NDR_CHECK(ndr_push_align(ndr, 5));
4286 2476 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->buf));
4287 2476 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4288 : }
4289 2476 : if (ndr_flags & NDR_BUFFERS) {
4290 2476 : if (r->buf) {
4291 1230 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->buf));
4292 : }
4293 : }
4294 2476 : return NDR_ERR_SUCCESS;
4295 : }
4296 :
4297 2456 : static enum ndr_err_code ndr_pull_lsa_DATA_BUF_PTR(struct ndr_pull *ndr, int ndr_flags, struct lsa_DATA_BUF_PTR *r)
4298 : {
4299 : uint32_t _ptr_buf;
4300 2456 : TALLOC_CTX *_mem_save_buf_0 = NULL;
4301 2456 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4302 2456 : if (ndr_flags & NDR_SCALARS) {
4303 2456 : NDR_CHECK(ndr_pull_align(ndr, 5));
4304 2456 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_buf));
4305 2456 : if (_ptr_buf) {
4306 1214 : NDR_PULL_ALLOC(ndr, r->buf);
4307 : } else {
4308 1242 : r->buf = NULL;
4309 : }
4310 2456 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4311 : }
4312 2456 : if (ndr_flags & NDR_BUFFERS) {
4313 2456 : if (r->buf) {
4314 1214 : _mem_save_buf_0 = NDR_PULL_GET_MEM_CTX(ndr);
4315 1214 : NDR_PULL_SET_MEM_CTX(ndr, r->buf, 0);
4316 1214 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->buf));
4317 1214 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buf_0, 0);
4318 : }
4319 : }
4320 2456 : return NDR_ERR_SUCCESS;
4321 : }
4322 :
4323 40 : _PUBLIC_ void ndr_print_lsa_DATA_BUF_PTR(struct ndr_print *ndr, const char *name, const struct lsa_DATA_BUF_PTR *r)
4324 : {
4325 40 : ndr_print_struct(ndr, name, "lsa_DATA_BUF_PTR");
4326 40 : if (r == NULL) { ndr_print_null(ndr); return; }
4327 40 : ndr->depth++;
4328 40 : ndr_print_ptr(ndr, "buf", r->buf);
4329 40 : ndr->depth++;
4330 40 : if (r->buf) {
4331 32 : ndr_print_lsa_DATA_BUF(ndr, "buf", r->buf);
4332 : }
4333 40 : ndr->depth--;
4334 40 : ndr->depth--;
4335 : }
4336 :
4337 54 : static enum ndr_err_code ndr_push_lsa_RightSet(struct ndr_push *ndr, int ndr_flags, const struct lsa_RightSet *r)
4338 : {
4339 : uint32_t cntr_names_1;
4340 54 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4341 54 : if (ndr_flags & NDR_SCALARS) {
4342 54 : NDR_CHECK(ndr_push_align(ndr, 5));
4343 54 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4344 54 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->names));
4345 54 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4346 : }
4347 54 : if (ndr_flags & NDR_BUFFERS) {
4348 54 : if (r->names) {
4349 46 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4350 270 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
4351 224 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
4352 : }
4353 270 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
4354 224 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
4355 : }
4356 : }
4357 : }
4358 54 : return NDR_ERR_SUCCESS;
4359 : }
4360 :
4361 48 : static enum ndr_err_code ndr_pull_lsa_RightSet(struct ndr_pull *ndr, int ndr_flags, struct lsa_RightSet *r)
4362 : {
4363 : uint32_t _ptr_names;
4364 48 : uint32_t size_names_1 = 0;
4365 : uint32_t cntr_names_1;
4366 48 : TALLOC_CTX *_mem_save_names_0 = NULL;
4367 48 : TALLOC_CTX *_mem_save_names_1 = NULL;
4368 48 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4369 48 : if (ndr_flags & NDR_SCALARS) {
4370 48 : NDR_CHECK(ndr_pull_align(ndr, 5));
4371 48 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4372 48 : if (r->count > 256) {
4373 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4374 : }
4375 48 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_names));
4376 48 : if (_ptr_names) {
4377 40 : NDR_PULL_ALLOC(ndr, r->names);
4378 : } else {
4379 8 : r->names = NULL;
4380 : }
4381 48 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4382 : }
4383 48 : if (ndr_flags & NDR_BUFFERS) {
4384 48 : if (r->names) {
4385 40 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
4386 40 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
4387 40 : NDR_CHECK(ndr_pull_array_size(ndr, &r->names));
4388 40 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->names, &size_names_1));
4389 40 : NDR_PULL_ALLOC_N(ndr, r->names, size_names_1);
4390 40 : _mem_save_names_1 = NDR_PULL_GET_MEM_CTX(ndr);
4391 40 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
4392 224 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
4393 184 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
4394 : }
4395 224 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
4396 184 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
4397 : }
4398 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_1, 0);
4399 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
4400 : }
4401 48 : if (r->names) {
4402 40 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->names, r->count));
4403 : }
4404 48 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
4405 : }
4406 : }
4407 48 : return NDR_ERR_SUCCESS;
4408 : }
4409 :
4410 12 : _PUBLIC_ void ndr_print_lsa_RightSet(struct ndr_print *ndr, const char *name, const struct lsa_RightSet *r)
4411 : {
4412 : uint32_t cntr_names_1;
4413 12 : ndr_print_struct(ndr, name, "lsa_RightSet");
4414 12 : if (r == NULL) { ndr_print_null(ndr); return; }
4415 12 : ndr->depth++;
4416 12 : ndr_print_uint32(ndr, "count", r->count);
4417 12 : ndr_print_ptr(ndr, "names", r->names);
4418 12 : ndr->depth++;
4419 12 : if (r->names) {
4420 12 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->count);
4421 12 : ndr->depth++;
4422 92 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
4423 80 : ndr_print_lsa_StringLarge(ndr, "names", &r->names[cntr_names_1]);
4424 : }
4425 12 : ndr->depth--;
4426 : }
4427 12 : ndr->depth--;
4428 12 : ndr->depth--;
4429 : }
4430 :
4431 70 : static enum ndr_err_code ndr_push_lsa_DomainListEx(struct ndr_push *ndr, int ndr_flags, const struct lsa_DomainListEx *r)
4432 : {
4433 : uint32_t cntr_domains_1;
4434 70 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4435 70 : if (ndr_flags & NDR_SCALARS) {
4436 70 : NDR_CHECK(ndr_push_align(ndr, 5));
4437 70 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4438 70 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domains));
4439 70 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4440 : }
4441 70 : if (ndr_flags & NDR_BUFFERS) {
4442 70 : if (r->domains) {
4443 60 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4444 255 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
4445 195 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->domains[cntr_domains_1]));
4446 : }
4447 255 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
4448 195 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->domains[cntr_domains_1]));
4449 : }
4450 : }
4451 : }
4452 70 : return NDR_ERR_SUCCESS;
4453 : }
4454 :
4455 56 : static enum ndr_err_code ndr_pull_lsa_DomainListEx(struct ndr_pull *ndr, int ndr_flags, struct lsa_DomainListEx *r)
4456 : {
4457 : uint32_t _ptr_domains;
4458 56 : uint32_t size_domains_1 = 0;
4459 : uint32_t cntr_domains_1;
4460 56 : TALLOC_CTX *_mem_save_domains_0 = NULL;
4461 56 : TALLOC_CTX *_mem_save_domains_1 = NULL;
4462 56 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4463 56 : if (ndr_flags & NDR_SCALARS) {
4464 56 : NDR_CHECK(ndr_pull_align(ndr, 5));
4465 56 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4466 56 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
4467 56 : if (_ptr_domains) {
4468 48 : NDR_PULL_ALLOC(ndr, r->domains);
4469 : } else {
4470 8 : r->domains = NULL;
4471 : }
4472 56 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4473 : }
4474 56 : if (ndr_flags & NDR_BUFFERS) {
4475 56 : if (r->domains) {
4476 48 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
4477 48 : NDR_PULL_SET_MEM_CTX(ndr, r->domains, 0);
4478 48 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domains));
4479 48 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->domains, &size_domains_1));
4480 48 : NDR_PULL_ALLOC_N(ndr, r->domains, size_domains_1);
4481 48 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
4482 48 : NDR_PULL_SET_MEM_CTX(ndr, r->domains, 0);
4483 204 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
4484 156 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS, &r->domains[cntr_domains_1]));
4485 : }
4486 204 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
4487 156 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_BUFFERS, &r->domains[cntr_domains_1]));
4488 : }
4489 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
4490 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, 0);
4491 : }
4492 56 : if (r->domains) {
4493 48 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->domains, r->count));
4494 : }
4495 56 : for (cntr_domains_1 = 0; cntr_domains_1 < (size_domains_1); cntr_domains_1++) {
4496 : }
4497 : }
4498 56 : return NDR_ERR_SUCCESS;
4499 : }
4500 :
4501 28 : _PUBLIC_ void ndr_print_lsa_DomainListEx(struct ndr_print *ndr, const char *name, const struct lsa_DomainListEx *r)
4502 : {
4503 : uint32_t cntr_domains_1;
4504 28 : ndr_print_struct(ndr, name, "lsa_DomainListEx");
4505 28 : if (r == NULL) { ndr_print_null(ndr); return; }
4506 28 : ndr->depth++;
4507 28 : ndr_print_uint32(ndr, "count", r->count);
4508 28 : ndr_print_ptr(ndr, "domains", r->domains);
4509 28 : ndr->depth++;
4510 28 : if (r->domains) {
4511 24 : ndr->print(ndr, "%s: ARRAY(%d)", "domains", (int)r->count);
4512 24 : ndr->depth++;
4513 102 : for (cntr_domains_1 = 0; cntr_domains_1 < (r->count); cntr_domains_1++) {
4514 78 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "domains", &r->domains[cntr_domains_1]);
4515 : }
4516 24 : ndr->depth--;
4517 : }
4518 28 : ndr->depth--;
4519 28 : ndr->depth--;
4520 : }
4521 :
4522 10 : static enum ndr_err_code ndr_push_lsa_krbAuthenticationOptions(struct ndr_push *ndr, int ndr_flags, uint32_t r)
4523 : {
4524 10 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
4525 10 : return NDR_ERR_SUCCESS;
4526 : }
4527 :
4528 8 : static enum ndr_err_code ndr_pull_lsa_krbAuthenticationOptions(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
4529 : {
4530 : uint32_t v;
4531 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
4532 8 : *r = v;
4533 8 : return NDR_ERR_SUCCESS;
4534 : }
4535 :
4536 4 : _PUBLIC_ void ndr_print_lsa_krbAuthenticationOptions(struct ndr_print *ndr, const char *name, uint32_t r)
4537 : {
4538 4 : ndr_print_uint32(ndr, name, r);
4539 4 : ndr->depth++;
4540 4 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_KERBEROS_VALIDATE_CLIENT", LSA_POLICY_KERBEROS_VALIDATE_CLIENT, r);
4541 4 : ndr->depth--;
4542 4 : }
4543 :
4544 10 : static enum ndr_err_code ndr_push_lsa_DomainInfoKerberos(struct ndr_push *ndr, int ndr_flags, const struct lsa_DomainInfoKerberos *r)
4545 : {
4546 10 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4547 10 : if (ndr_flags & NDR_SCALARS) {
4548 10 : NDR_CHECK(ndr_push_align(ndr, 8));
4549 10 : NDR_CHECK(ndr_push_lsa_krbAuthenticationOptions(ndr, NDR_SCALARS, r->authentication_options));
4550 10 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->service_tkt_lifetime));
4551 10 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->user_tkt_lifetime));
4552 10 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->user_tkt_renewaltime));
4553 10 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->clock_skew));
4554 10 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->reserved));
4555 10 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
4556 : }
4557 10 : if (ndr_flags & NDR_BUFFERS) {
4558 : }
4559 10 : return NDR_ERR_SUCCESS;
4560 : }
4561 :
4562 8 : static enum ndr_err_code ndr_pull_lsa_DomainInfoKerberos(struct ndr_pull *ndr, int ndr_flags, struct lsa_DomainInfoKerberos *r)
4563 : {
4564 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4565 8 : if (ndr_flags & NDR_SCALARS) {
4566 8 : NDR_CHECK(ndr_pull_align(ndr, 8));
4567 8 : NDR_CHECK(ndr_pull_lsa_krbAuthenticationOptions(ndr, NDR_SCALARS, &r->authentication_options));
4568 8 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->service_tkt_lifetime));
4569 8 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->user_tkt_lifetime));
4570 8 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->user_tkt_renewaltime));
4571 8 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->clock_skew));
4572 8 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->reserved));
4573 8 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
4574 : }
4575 8 : if (ndr_flags & NDR_BUFFERS) {
4576 : }
4577 8 : return NDR_ERR_SUCCESS;
4578 : }
4579 :
4580 4 : _PUBLIC_ void ndr_print_lsa_DomainInfoKerberos(struct ndr_print *ndr, const char *name, const struct lsa_DomainInfoKerberos *r)
4581 : {
4582 4 : ndr_print_struct(ndr, name, "lsa_DomainInfoKerberos");
4583 4 : if (r == NULL) { ndr_print_null(ndr); return; }
4584 4 : ndr->depth++;
4585 4 : ndr_print_lsa_krbAuthenticationOptions(ndr, "authentication_options", r->authentication_options);
4586 4 : ndr_print_hyper(ndr, "service_tkt_lifetime", r->service_tkt_lifetime);
4587 4 : ndr_print_hyper(ndr, "user_tkt_lifetime", r->user_tkt_lifetime);
4588 4 : ndr_print_hyper(ndr, "user_tkt_renewaltime", r->user_tkt_renewaltime);
4589 4 : ndr_print_hyper(ndr, "clock_skew", r->clock_skew);
4590 4 : ndr_print_hyper(ndr, "reserved", r->reserved);
4591 4 : ndr->depth--;
4592 : }
4593 :
4594 0 : static enum ndr_err_code ndr_push_lsa_DomainInfoEfs(struct ndr_push *ndr, int ndr_flags, const struct lsa_DomainInfoEfs *r)
4595 : {
4596 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4597 0 : if (ndr_flags & NDR_SCALARS) {
4598 0 : NDR_CHECK(ndr_push_align(ndr, 5));
4599 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->blob_size));
4600 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->efs_blob));
4601 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4602 : }
4603 0 : if (ndr_flags & NDR_BUFFERS) {
4604 0 : if (r->efs_blob) {
4605 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->blob_size));
4606 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->efs_blob, r->blob_size));
4607 : }
4608 : }
4609 0 : return NDR_ERR_SUCCESS;
4610 : }
4611 :
4612 0 : static enum ndr_err_code ndr_pull_lsa_DomainInfoEfs(struct ndr_pull *ndr, int ndr_flags, struct lsa_DomainInfoEfs *r)
4613 : {
4614 : uint32_t _ptr_efs_blob;
4615 0 : uint32_t size_efs_blob_1 = 0;
4616 0 : TALLOC_CTX *_mem_save_efs_blob_0 = NULL;
4617 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4618 0 : if (ndr_flags & NDR_SCALARS) {
4619 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
4620 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->blob_size));
4621 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_efs_blob));
4622 0 : if (_ptr_efs_blob) {
4623 0 : NDR_PULL_ALLOC(ndr, r->efs_blob);
4624 : } else {
4625 0 : r->efs_blob = NULL;
4626 : }
4627 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4628 : }
4629 0 : if (ndr_flags & NDR_BUFFERS) {
4630 0 : if (r->efs_blob) {
4631 0 : _mem_save_efs_blob_0 = NDR_PULL_GET_MEM_CTX(ndr);
4632 0 : NDR_PULL_SET_MEM_CTX(ndr, r->efs_blob, 0);
4633 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->efs_blob));
4634 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->efs_blob, &size_efs_blob_1));
4635 0 : NDR_PULL_ALLOC_N(ndr, r->efs_blob, size_efs_blob_1);
4636 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->efs_blob, size_efs_blob_1));
4637 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_efs_blob_0, 0);
4638 : }
4639 0 : if (r->efs_blob) {
4640 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->efs_blob, r->blob_size));
4641 : }
4642 : }
4643 0 : return NDR_ERR_SUCCESS;
4644 : }
4645 :
4646 0 : _PUBLIC_ void ndr_print_lsa_DomainInfoEfs(struct ndr_print *ndr, const char *name, const struct lsa_DomainInfoEfs *r)
4647 : {
4648 0 : ndr_print_struct(ndr, name, "lsa_DomainInfoEfs");
4649 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4650 0 : ndr->depth++;
4651 0 : ndr_print_uint32(ndr, "blob_size", r->blob_size);
4652 0 : ndr_print_ptr(ndr, "efs_blob", r->efs_blob);
4653 0 : ndr->depth++;
4654 0 : if (r->efs_blob) {
4655 0 : ndr_print_array_uint8(ndr, "efs_blob", r->efs_blob, r->blob_size);
4656 : }
4657 0 : ndr->depth--;
4658 0 : ndr->depth--;
4659 : }
4660 :
4661 10 : static enum ndr_err_code ndr_push_lsa_DomainInformationPolicy(struct ndr_push *ndr, int ndr_flags, const union lsa_DomainInformationPolicy *r)
4662 : {
4663 : uint32_t level;
4664 10 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4665 10 : if (ndr_flags & NDR_SCALARS) {
4666 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
4667 10 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
4668 10 : NDR_CHECK(ndr_push_union_align(ndr, 8));
4669 10 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
4670 10 : NDR_CHECK(ndr_push_union_align(ndr, 8));
4671 10 : switch (level) {
4672 0 : case LSA_DOMAIN_INFO_POLICY_EFS: {
4673 0 : NDR_CHECK(ndr_push_lsa_DomainInfoEfs(ndr, NDR_SCALARS, &r->efs_info));
4674 0 : break; }
4675 :
4676 10 : case LSA_DOMAIN_INFO_POLICY_KERBEROS: {
4677 10 : NDR_CHECK(ndr_push_lsa_DomainInfoKerberos(ndr, NDR_SCALARS, &r->kerberos_info));
4678 10 : break; }
4679 :
4680 0 : default:
4681 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
4682 : }
4683 0 : }
4684 10 : if (ndr_flags & NDR_BUFFERS) {
4685 10 : if (!(ndr_flags & NDR_SCALARS)) {
4686 : /* We didn't get it above, and the token is not needed after this. */
4687 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
4688 : }
4689 10 : switch (level) {
4690 0 : case LSA_DOMAIN_INFO_POLICY_EFS:
4691 0 : NDR_CHECK(ndr_push_lsa_DomainInfoEfs(ndr, NDR_BUFFERS, &r->efs_info));
4692 0 : break;
4693 :
4694 10 : case LSA_DOMAIN_INFO_POLICY_KERBEROS:
4695 10 : break;
4696 :
4697 0 : default:
4698 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u", level);
4699 : }
4700 0 : }
4701 10 : return NDR_ERR_SUCCESS;
4702 : }
4703 :
4704 8 : static enum ndr_err_code ndr_pull_lsa_DomainInformationPolicy(struct ndr_pull *ndr, int ndr_flags, union lsa_DomainInformationPolicy *r)
4705 : {
4706 : uint32_t level;
4707 : uint16_t _level;
4708 8 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4709 8 : if (ndr_flags & NDR_SCALARS) {
4710 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
4711 8 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
4712 8 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
4713 8 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
4714 8 : if (_level != level) {
4715 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r at %s", _level, __location__);
4716 : }
4717 8 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
4718 8 : switch (level) {
4719 0 : case LSA_DOMAIN_INFO_POLICY_EFS: {
4720 0 : NDR_CHECK(ndr_pull_lsa_DomainInfoEfs(ndr, NDR_SCALARS, &r->efs_info));
4721 0 : break; }
4722 :
4723 8 : case LSA_DOMAIN_INFO_POLICY_KERBEROS: {
4724 8 : NDR_CHECK(ndr_pull_lsa_DomainInfoKerberos(ndr, NDR_SCALARS, &r->kerberos_info));
4725 8 : break; }
4726 :
4727 0 : default:
4728 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
4729 : }
4730 0 : }
4731 8 : if (ndr_flags & NDR_BUFFERS) {
4732 8 : if (!(ndr_flags & NDR_SCALARS)) {
4733 : /* We didn't get it above, and the token is not needed after this. */
4734 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
4735 : }
4736 8 : switch (level) {
4737 0 : case LSA_DOMAIN_INFO_POLICY_EFS:
4738 0 : NDR_CHECK(ndr_pull_lsa_DomainInfoEfs(ndr, NDR_BUFFERS, &r->efs_info));
4739 0 : break;
4740 :
4741 8 : case LSA_DOMAIN_INFO_POLICY_KERBEROS:
4742 8 : break;
4743 :
4744 0 : default:
4745 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u at %s", level, __location__);
4746 : }
4747 0 : }
4748 8 : return NDR_ERR_SUCCESS;
4749 : }
4750 :
4751 4 : _PUBLIC_ void ndr_print_lsa_DomainInformationPolicy(struct ndr_print *ndr, const char *name, const union lsa_DomainInformationPolicy *r)
4752 : {
4753 : uint32_t level;
4754 4 : level = ndr_print_steal_switch_value(ndr, r);
4755 4 : ndr_print_union(ndr, name, level, "lsa_DomainInformationPolicy");
4756 4 : switch (level) {
4757 0 : case LSA_DOMAIN_INFO_POLICY_EFS:
4758 0 : ndr_print_lsa_DomainInfoEfs(ndr, "efs_info", &r->efs_info);
4759 0 : break;
4760 :
4761 4 : case LSA_DOMAIN_INFO_POLICY_KERBEROS:
4762 4 : ndr_print_lsa_DomainInfoKerberos(ndr, "kerberos_info", &r->kerberos_info);
4763 4 : break;
4764 :
4765 0 : default:
4766 0 : ndr_print_bad_level(ndr, name, level);
4767 : }
4768 4 : }
4769 :
4770 36780 : static enum ndr_err_code ndr_push_lsa_TranslatedName2(struct ndr_push *ndr, int ndr_flags, const struct lsa_TranslatedName2 *r)
4771 : {
4772 36780 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4773 36780 : if (ndr_flags & NDR_SCALARS) {
4774 18390 : NDR_CHECK(ndr_push_align(ndr, 5));
4775 18390 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, r->sid_type));
4776 18390 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
4777 18390 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sid_index));
4778 18390 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown));
4779 18390 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4780 : }
4781 36780 : if (ndr_flags & NDR_BUFFERS) {
4782 18390 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
4783 : }
4784 36780 : return NDR_ERR_SUCCESS;
4785 : }
4786 :
4787 28912 : static enum ndr_err_code ndr_pull_lsa_TranslatedName2(struct ndr_pull *ndr, int ndr_flags, struct lsa_TranslatedName2 *r)
4788 : {
4789 28912 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4790 28912 : if (ndr_flags & NDR_SCALARS) {
4791 14456 : NDR_CHECK(ndr_pull_align(ndr, 5));
4792 14456 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, &r->sid_type));
4793 14456 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
4794 14456 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sid_index));
4795 14456 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown));
4796 14456 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4797 : }
4798 28912 : if (ndr_flags & NDR_BUFFERS) {
4799 14456 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
4800 : }
4801 28912 : return NDR_ERR_SUCCESS;
4802 : }
4803 :
4804 7212 : _PUBLIC_ void ndr_print_lsa_TranslatedName2(struct ndr_print *ndr, const char *name, const struct lsa_TranslatedName2 *r)
4805 : {
4806 7212 : ndr_print_struct(ndr, name, "lsa_TranslatedName2");
4807 7212 : if (r == NULL) { ndr_print_null(ndr); return; }
4808 7212 : ndr->depth++;
4809 7212 : ndr_print_lsa_SidType(ndr, "sid_type", r->sid_type);
4810 7212 : ndr_print_lsa_String(ndr, "name", &r->name);
4811 7212 : ndr_print_uint32(ndr, "sid_index", r->sid_index);
4812 7212 : ndr_print_uint32(ndr, "unknown", r->unknown);
4813 7212 : ndr->depth--;
4814 : }
4815 :
4816 1268 : static enum ndr_err_code ndr_push_lsa_TransNameArray2(struct ndr_push *ndr, int ndr_flags, const struct lsa_TransNameArray2 *r)
4817 : {
4818 : uint32_t cntr_names_1;
4819 1268 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4820 1268 : if (ndr_flags & NDR_SCALARS) {
4821 1268 : NDR_CHECK(ndr_push_align(ndr, 5));
4822 1268 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4823 1268 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->names));
4824 1268 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4825 : }
4826 1268 : if (ndr_flags & NDR_BUFFERS) {
4827 1268 : if (r->names) {
4828 1087 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4829 19477 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
4830 18390 : NDR_CHECK(ndr_push_lsa_TranslatedName2(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
4831 : }
4832 19477 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
4833 18390 : NDR_CHECK(ndr_push_lsa_TranslatedName2(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
4834 : }
4835 : }
4836 : }
4837 1268 : return NDR_ERR_SUCCESS;
4838 : }
4839 :
4840 1231 : static enum ndr_err_code ndr_pull_lsa_TransNameArray2(struct ndr_pull *ndr, int ndr_flags, struct lsa_TransNameArray2 *r)
4841 : {
4842 : uint32_t _ptr_names;
4843 1231 : uint32_t size_names_1 = 0;
4844 : uint32_t cntr_names_1;
4845 1231 : TALLOC_CTX *_mem_save_names_0 = NULL;
4846 1231 : TALLOC_CTX *_mem_save_names_1 = NULL;
4847 1231 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4848 1231 : if (ndr_flags & NDR_SCALARS) {
4849 1231 : NDR_CHECK(ndr_pull_align(ndr, 5));
4850 1231 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4851 1231 : if (r->count > 1000) {
4852 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
4853 : }
4854 1231 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_names));
4855 1231 : if (_ptr_names) {
4856 180 : NDR_PULL_ALLOC(ndr, r->names);
4857 : } else {
4858 1051 : r->names = NULL;
4859 : }
4860 1231 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4861 : }
4862 1231 : if (ndr_flags & NDR_BUFFERS) {
4863 1231 : if (r->names) {
4864 180 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
4865 180 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
4866 180 : NDR_CHECK(ndr_pull_array_size(ndr, &r->names));
4867 180 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->names, &size_names_1));
4868 180 : NDR_PULL_ALLOC_N(ndr, r->names, size_names_1);
4869 180 : _mem_save_names_1 = NDR_PULL_GET_MEM_CTX(ndr);
4870 180 : NDR_PULL_SET_MEM_CTX(ndr, r->names, 0);
4871 14636 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
4872 14456 : NDR_CHECK(ndr_pull_lsa_TranslatedName2(ndr, NDR_SCALARS, &r->names[cntr_names_1]));
4873 : }
4874 14636 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
4875 14456 : NDR_CHECK(ndr_pull_lsa_TranslatedName2(ndr, NDR_BUFFERS, &r->names[cntr_names_1]));
4876 : }
4877 180 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_1, 0);
4878 180 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
4879 : }
4880 1231 : if (r->names) {
4881 180 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->names, r->count));
4882 : }
4883 1241 : for (cntr_names_1 = 0; cntr_names_1 < (size_names_1); cntr_names_1++) {
4884 : }
4885 : }
4886 1231 : return NDR_ERR_SUCCESS;
4887 : }
4888 :
4889 74 : _PUBLIC_ void ndr_print_lsa_TransNameArray2(struct ndr_print *ndr, const char *name, const struct lsa_TransNameArray2 *r)
4890 : {
4891 : uint32_t cntr_names_1;
4892 74 : ndr_print_struct(ndr, name, "lsa_TransNameArray2");
4893 74 : if (r == NULL) { ndr_print_null(ndr); return; }
4894 74 : ndr->depth++;
4895 74 : ndr_print_uint32(ndr, "count", r->count);
4896 74 : ndr_print_ptr(ndr, "names", r->names);
4897 74 : ndr->depth++;
4898 74 : if (r->names) {
4899 74 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->count);
4900 74 : ndr->depth++;
4901 7286 : for (cntr_names_1 = 0; cntr_names_1 < (r->count); cntr_names_1++) {
4902 7212 : ndr_print_lsa_TranslatedName2(ndr, "names", &r->names[cntr_names_1]);
4903 : }
4904 74 : ndr->depth--;
4905 : }
4906 74 : ndr->depth--;
4907 74 : ndr->depth--;
4908 : }
4909 :
4910 552 : static enum ndr_err_code ndr_push_lsa_LookupOptions(struct ndr_push *ndr, int ndr_flags, enum lsa_LookupOptions r)
4911 : {
4912 552 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
4913 552 : return NDR_ERR_SUCCESS;
4914 : }
4915 :
4916 1696 : static enum ndr_err_code ndr_pull_lsa_LookupOptions(struct ndr_pull *ndr, int ndr_flags, enum lsa_LookupOptions *r)
4917 : {
4918 : uint32_t v;
4919 1696 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
4920 1696 : *r = v;
4921 1696 : return NDR_ERR_SUCCESS;
4922 : }
4923 :
4924 0 : _PUBLIC_ void ndr_print_lsa_LookupOptions(struct ndr_print *ndr, const char *name, enum lsa_LookupOptions r)
4925 : {
4926 0 : const char *val = NULL;
4927 :
4928 0 : switch (r) {
4929 0 : case LSA_LOOKUP_OPTION_SEARCH_ISOLATED_NAMES: val = "LSA_LOOKUP_OPTION_SEARCH_ISOLATED_NAMES"; break;
4930 0 : case LSA_LOOKUP_OPTION_SEARCH_ISOLATED_NAMES_LOCAL: val = "LSA_LOOKUP_OPTION_SEARCH_ISOLATED_NAMES_LOCAL"; break;
4931 : }
4932 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
4933 0 : }
4934 :
4935 552 : static enum ndr_err_code ndr_push_lsa_ClientRevision(struct ndr_push *ndr, int ndr_flags, enum lsa_ClientRevision r)
4936 : {
4937 552 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
4938 552 : return NDR_ERR_SUCCESS;
4939 : }
4940 :
4941 1696 : static enum ndr_err_code ndr_pull_lsa_ClientRevision(struct ndr_pull *ndr, int ndr_flags, enum lsa_ClientRevision *r)
4942 : {
4943 : uint32_t v;
4944 1696 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
4945 1696 : *r = v;
4946 1696 : return NDR_ERR_SUCCESS;
4947 : }
4948 :
4949 0 : _PUBLIC_ void ndr_print_lsa_ClientRevision(struct ndr_print *ndr, const char *name, enum lsa_ClientRevision r)
4950 : {
4951 0 : const char *val = NULL;
4952 :
4953 0 : switch (r) {
4954 0 : case LSA_CLIENT_REVISION_1: val = "LSA_CLIENT_REVISION_1"; break;
4955 0 : case LSA_CLIENT_REVISION_2: val = "LSA_CLIENT_REVISION_2"; break;
4956 : }
4957 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
4958 0 : }
4959 :
4960 35 : static enum ndr_err_code ndr_push_lsa_TranslatedSid2(struct ndr_push *ndr, int ndr_flags, const struct lsa_TranslatedSid2 *r)
4961 : {
4962 35 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4963 35 : if (ndr_flags & NDR_SCALARS) {
4964 35 : NDR_CHECK(ndr_push_align(ndr, 4));
4965 35 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, r->sid_type));
4966 35 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
4967 35 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sid_index));
4968 35 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown));
4969 35 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
4970 : }
4971 35 : if (ndr_flags & NDR_BUFFERS) {
4972 : }
4973 35 : return NDR_ERR_SUCCESS;
4974 : }
4975 :
4976 28 : static enum ndr_err_code ndr_pull_lsa_TranslatedSid2(struct ndr_pull *ndr, int ndr_flags, struct lsa_TranslatedSid2 *r)
4977 : {
4978 28 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4979 28 : if (ndr_flags & NDR_SCALARS) {
4980 28 : NDR_CHECK(ndr_pull_align(ndr, 4));
4981 28 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, &r->sid_type));
4982 28 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
4983 28 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sid_index));
4984 28 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown));
4985 28 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
4986 : }
4987 28 : if (ndr_flags & NDR_BUFFERS) {
4988 : }
4989 28 : return NDR_ERR_SUCCESS;
4990 : }
4991 :
4992 14 : _PUBLIC_ void ndr_print_lsa_TranslatedSid2(struct ndr_print *ndr, const char *name, const struct lsa_TranslatedSid2 *r)
4993 : {
4994 14 : ndr_print_struct(ndr, name, "lsa_TranslatedSid2");
4995 14 : if (r == NULL) { ndr_print_null(ndr); return; }
4996 14 : ndr->depth++;
4997 14 : ndr_print_lsa_SidType(ndr, "sid_type", r->sid_type);
4998 14 : ndr_print_uint32(ndr, "rid", r->rid);
4999 14 : ndr_print_uint32(ndr, "sid_index", r->sid_index);
5000 14 : ndr_print_uint32(ndr, "unknown", r->unknown);
5001 14 : ndr->depth--;
5002 : }
5003 :
5004 18 : static enum ndr_err_code ndr_push_lsa_TransSidArray2(struct ndr_push *ndr, int ndr_flags, const struct lsa_TransSidArray2 *r)
5005 : {
5006 : uint32_t cntr_sids_1;
5007 18 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5008 18 : if (ndr_flags & NDR_SCALARS) {
5009 18 : NDR_CHECK(ndr_push_align(ndr, 5));
5010 18 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5011 18 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sids));
5012 18 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5013 : }
5014 18 : if (ndr_flags & NDR_BUFFERS) {
5015 18 : if (r->sids) {
5016 10 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5017 45 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->count); cntr_sids_1++) {
5018 35 : NDR_CHECK(ndr_push_lsa_TranslatedSid2(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
5019 : }
5020 : }
5021 : }
5022 18 : return NDR_ERR_SUCCESS;
5023 : }
5024 :
5025 16 : static enum ndr_err_code ndr_pull_lsa_TransSidArray2(struct ndr_pull *ndr, int ndr_flags, struct lsa_TransSidArray2 *r)
5026 : {
5027 : uint32_t _ptr_sids;
5028 16 : uint32_t size_sids_1 = 0;
5029 : uint32_t cntr_sids_1;
5030 16 : TALLOC_CTX *_mem_save_sids_0 = NULL;
5031 16 : TALLOC_CTX *_mem_save_sids_1 = NULL;
5032 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5033 16 : if (ndr_flags & NDR_SCALARS) {
5034 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
5035 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5036 16 : if (r->count > 1000) {
5037 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5038 : }
5039 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sids));
5040 16 : if (_ptr_sids) {
5041 8 : NDR_PULL_ALLOC(ndr, r->sids);
5042 : } else {
5043 8 : r->sids = NULL;
5044 : }
5045 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5046 : }
5047 16 : if (ndr_flags & NDR_BUFFERS) {
5048 16 : if (r->sids) {
5049 8 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
5050 8 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
5051 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->sids));
5052 8 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->sids, &size_sids_1));
5053 8 : NDR_PULL_ALLOC_N(ndr, r->sids, size_sids_1);
5054 8 : _mem_save_sids_1 = NDR_PULL_GET_MEM_CTX(ndr);
5055 8 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
5056 36 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
5057 28 : NDR_CHECK(ndr_pull_lsa_TranslatedSid2(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
5058 : }
5059 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_1, 0);
5060 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, 0);
5061 : }
5062 16 : if (r->sids) {
5063 8 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->sids, r->count));
5064 : }
5065 : }
5066 16 : return NDR_ERR_SUCCESS;
5067 : }
5068 :
5069 4 : _PUBLIC_ void ndr_print_lsa_TransSidArray2(struct ndr_print *ndr, const char *name, const struct lsa_TransSidArray2 *r)
5070 : {
5071 : uint32_t cntr_sids_1;
5072 4 : ndr_print_struct(ndr, name, "lsa_TransSidArray2");
5073 4 : if (r == NULL) { ndr_print_null(ndr); return; }
5074 4 : ndr->depth++;
5075 4 : ndr_print_uint32(ndr, "count", r->count);
5076 4 : ndr_print_ptr(ndr, "sids", r->sids);
5077 4 : ndr->depth++;
5078 4 : if (r->sids) {
5079 4 : ndr->print(ndr, "%s: ARRAY(%d)", "sids", (int)r->count);
5080 4 : ndr->depth++;
5081 18 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->count); cntr_sids_1++) {
5082 14 : ndr_print_lsa_TranslatedSid2(ndr, "sids", &r->sids[cntr_sids_1]);
5083 : }
5084 4 : ndr->depth--;
5085 : }
5086 4 : ndr->depth--;
5087 4 : ndr->depth--;
5088 : }
5089 :
5090 36682 : static enum ndr_err_code ndr_push_lsa_TranslatedSid3(struct ndr_push *ndr, int ndr_flags, const struct lsa_TranslatedSid3 *r)
5091 : {
5092 36682 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5093 36682 : if (ndr_flags & NDR_SCALARS) {
5094 18341 : NDR_CHECK(ndr_push_align(ndr, 5));
5095 18341 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, r->sid_type));
5096 18341 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sid));
5097 18341 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sid_index));
5098 18341 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->flags));
5099 18341 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5100 : }
5101 36682 : if (ndr_flags & NDR_BUFFERS) {
5102 18341 : if (r->sid) {
5103 18263 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
5104 : }
5105 : }
5106 36682 : return NDR_ERR_SUCCESS;
5107 : }
5108 :
5109 28936 : static enum ndr_err_code ndr_pull_lsa_TranslatedSid3(struct ndr_pull *ndr, int ndr_flags, struct lsa_TranslatedSid3 *r)
5110 : {
5111 : uint32_t _ptr_sid;
5112 28936 : TALLOC_CTX *_mem_save_sid_0 = NULL;
5113 28936 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5114 28936 : if (ndr_flags & NDR_SCALARS) {
5115 14468 : NDR_CHECK(ndr_pull_align(ndr, 5));
5116 14468 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, &r->sid_type));
5117 14468 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
5118 14468 : if (_ptr_sid) {
5119 14468 : NDR_PULL_ALLOC(ndr, r->sid);
5120 : } else {
5121 0 : r->sid = NULL;
5122 : }
5123 14468 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sid_index));
5124 14468 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->flags));
5125 14468 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5126 : }
5127 28936 : if (ndr_flags & NDR_BUFFERS) {
5128 14468 : if (r->sid) {
5129 14468 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
5130 14468 : NDR_PULL_SET_MEM_CTX(ndr, r->sid, 0);
5131 14468 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->sid));
5132 14468 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, 0);
5133 : }
5134 : }
5135 28936 : return NDR_ERR_SUCCESS;
5136 : }
5137 :
5138 7214 : _PUBLIC_ void ndr_print_lsa_TranslatedSid3(struct ndr_print *ndr, const char *name, const struct lsa_TranslatedSid3 *r)
5139 : {
5140 7214 : ndr_print_struct(ndr, name, "lsa_TranslatedSid3");
5141 7214 : if (r == NULL) { ndr_print_null(ndr); return; }
5142 7214 : ndr->depth++;
5143 7214 : ndr_print_lsa_SidType(ndr, "sid_type", r->sid_type);
5144 7214 : ndr_print_ptr(ndr, "sid", r->sid);
5145 7214 : ndr->depth++;
5146 7214 : if (r->sid) {
5147 7214 : ndr_print_dom_sid2(ndr, "sid", r->sid);
5148 : }
5149 7214 : ndr->depth--;
5150 7214 : ndr_print_uint32(ndr, "sid_index", r->sid_index);
5151 7214 : ndr_print_uint32(ndr, "flags", r->flags);
5152 7214 : ndr->depth--;
5153 : }
5154 :
5155 1041 : static enum ndr_err_code ndr_push_lsa_TransSidArray3(struct ndr_push *ndr, int ndr_flags, const struct lsa_TransSidArray3 *r)
5156 : {
5157 : uint32_t cntr_sids_1;
5158 1041 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5159 1041 : if (ndr_flags & NDR_SCALARS) {
5160 1041 : NDR_CHECK(ndr_push_align(ndr, 5));
5161 1041 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5162 1041 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sids));
5163 1041 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5164 : }
5165 1041 : if (ndr_flags & NDR_BUFFERS) {
5166 1041 : if (r->sids) {
5167 683 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5168 19024 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->count); cntr_sids_1++) {
5169 18341 : NDR_CHECK(ndr_push_lsa_TranslatedSid3(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
5170 : }
5171 19024 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->count); cntr_sids_1++) {
5172 18341 : NDR_CHECK(ndr_push_lsa_TranslatedSid3(ndr, NDR_BUFFERS, &r->sids[cntr_sids_1]));
5173 : }
5174 : }
5175 : }
5176 1041 : return NDR_ERR_SUCCESS;
5177 : }
5178 :
5179 967 : static enum ndr_err_code ndr_pull_lsa_TransSidArray3(struct ndr_pull *ndr, int ndr_flags, struct lsa_TransSidArray3 *r)
5180 : {
5181 : uint32_t _ptr_sids;
5182 967 : uint32_t size_sids_1 = 0;
5183 : uint32_t cntr_sids_1;
5184 967 : TALLOC_CTX *_mem_save_sids_0 = NULL;
5185 967 : TALLOC_CTX *_mem_save_sids_1 = NULL;
5186 967 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5187 967 : if (ndr_flags & NDR_SCALARS) {
5188 967 : NDR_CHECK(ndr_pull_align(ndr, 5));
5189 967 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5190 967 : if (r->count > 1000) {
5191 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5192 : }
5193 967 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sids));
5194 967 : if (_ptr_sids) {
5195 335 : NDR_PULL_ALLOC(ndr, r->sids);
5196 : } else {
5197 632 : r->sids = NULL;
5198 : }
5199 967 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5200 : }
5201 967 : if (ndr_flags & NDR_BUFFERS) {
5202 967 : if (r->sids) {
5203 335 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
5204 335 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
5205 335 : NDR_CHECK(ndr_pull_array_size(ndr, &r->sids));
5206 335 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->sids, &size_sids_1));
5207 335 : NDR_PULL_ALLOC_N(ndr, r->sids, size_sids_1);
5208 335 : _mem_save_sids_1 = NDR_PULL_GET_MEM_CTX(ndr);
5209 335 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
5210 14803 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
5211 14468 : NDR_CHECK(ndr_pull_lsa_TranslatedSid3(ndr, NDR_SCALARS, &r->sids[cntr_sids_1]));
5212 : }
5213 14803 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
5214 14468 : NDR_CHECK(ndr_pull_lsa_TranslatedSid3(ndr, NDR_BUFFERS, &r->sids[cntr_sids_1]));
5215 : }
5216 335 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_1, 0);
5217 335 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, 0);
5218 : }
5219 967 : if (r->sids) {
5220 335 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->sids, r->count));
5221 : }
5222 983 : for (cntr_sids_1 = 0; cntr_sids_1 < (size_sids_1); cntr_sids_1++) {
5223 : }
5224 : }
5225 967 : return NDR_ERR_SUCCESS;
5226 : }
5227 :
5228 148 : _PUBLIC_ void ndr_print_lsa_TransSidArray3(struct ndr_print *ndr, const char *name, const struct lsa_TransSidArray3 *r)
5229 : {
5230 : uint32_t cntr_sids_1;
5231 148 : ndr_print_struct(ndr, name, "lsa_TransSidArray3");
5232 148 : if (r == NULL) { ndr_print_null(ndr); return; }
5233 148 : ndr->depth++;
5234 148 : ndr_print_uint32(ndr, "count", r->count);
5235 148 : ndr_print_ptr(ndr, "sids", r->sids);
5236 148 : ndr->depth++;
5237 148 : if (r->sids) {
5238 148 : ndr->print(ndr, "%s: ARRAY(%d)", "sids", (int)r->count);
5239 148 : ndr->depth++;
5240 7362 : for (cntr_sids_1 = 0; cntr_sids_1 < (r->count); cntr_sids_1++) {
5241 7214 : ndr_print_lsa_TranslatedSid3(ndr, "sids", &r->sids[cntr_sids_1]);
5242 : }
5243 148 : ndr->depth--;
5244 : }
5245 148 : ndr->depth--;
5246 148 : ndr->depth--;
5247 : }
5248 :
5249 3244 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_ForestTrustRecordFlags(struct ndr_push *ndr, int ndr_flags, uint32_t r)
5250 : {
5251 3244 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
5252 3244 : return NDR_ERR_SUCCESS;
5253 : }
5254 :
5255 8776 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_ForestTrustRecordFlags(struct ndr_pull *ndr, int ndr_flags, uint32_t *r)
5256 : {
5257 : uint32_t v;
5258 8776 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
5259 8776 : *r = v;
5260 8776 : return NDR_ERR_SUCCESS;
5261 : }
5262 :
5263 20 : _PUBLIC_ void ndr_print_lsa_ForestTrustRecordFlags(struct ndr_print *ndr, const char *name, uint32_t r)
5264 : {
5265 20 : ndr_print_uint32(ndr, name, r);
5266 20 : ndr->depth++;
5267 20 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TLN_DISABLED_NEW", LSA_TLN_DISABLED_NEW, r);
5268 20 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TLN_DISABLED_ADMIN", LSA_TLN_DISABLED_ADMIN, r);
5269 20 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_TLN_DISABLED_CONFLICT", LSA_TLN_DISABLED_CONFLICT, r);
5270 20 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_SID_DISABLED_ADMIN", LSA_SID_DISABLED_ADMIN, r);
5271 20 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_SID_DISABLED_CONFLICT", LSA_SID_DISABLED_CONFLICT, r);
5272 20 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_NB_DISABLED_ADMIN", LSA_NB_DISABLED_ADMIN, r);
5273 20 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_NB_DISABLED_CONFLICT", LSA_NB_DISABLED_CONFLICT, r);
5274 20 : ndr->depth--;
5275 20 : }
5276 :
5277 4684 : static enum ndr_err_code ndr_push_lsa_ForestTrustRecordType(struct ndr_push *ndr, int ndr_flags, enum lsa_ForestTrustRecordType r)
5278 : {
5279 4684 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
5280 4684 : return NDR_ERR_SUCCESS;
5281 : }
5282 :
5283 2422 : static enum ndr_err_code ndr_pull_lsa_ForestTrustRecordType(struct ndr_pull *ndr, int ndr_flags, enum lsa_ForestTrustRecordType *r)
5284 : {
5285 : uint16_t v;
5286 2422 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
5287 2422 : *r = v;
5288 2422 : return NDR_ERR_SUCCESS;
5289 : }
5290 :
5291 20 : _PUBLIC_ void ndr_print_lsa_ForestTrustRecordType(struct ndr_print *ndr, const char *name, enum lsa_ForestTrustRecordType r)
5292 : {
5293 20 : const char *val = NULL;
5294 :
5295 20 : switch (r) {
5296 12 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME: val = "LSA_FOREST_TRUST_TOP_LEVEL_NAME"; break;
5297 0 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME_EX: val = "LSA_FOREST_TRUST_TOP_LEVEL_NAME_EX"; break;
5298 8 : case LSA_FOREST_TRUST_DOMAIN_INFO: val = "LSA_FOREST_TRUST_DOMAIN_INFO"; break;
5299 0 : case LSA_FOREST_TRUST_RECORD_TYPE_LAST: val = "LSA_FOREST_TRUST_RECORD_TYPE_LAST"; break;
5300 : }
5301 20 : ndr_print_enum(ndr, name, "ENUM", val, r);
5302 20 : }
5303 :
5304 0 : static enum ndr_err_code ndr_push_lsa_ForestTrustBinaryData(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustBinaryData *r)
5305 : {
5306 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5307 0 : if (ndr_flags & NDR_SCALARS) {
5308 0 : NDR_CHECK(ndr_push_align(ndr, 5));
5309 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->length));
5310 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->data));
5311 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5312 : }
5313 0 : if (ndr_flags & NDR_BUFFERS) {
5314 0 : if (r->data) {
5315 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->length));
5316 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->data, r->length));
5317 : }
5318 : }
5319 0 : return NDR_ERR_SUCCESS;
5320 : }
5321 :
5322 0 : static enum ndr_err_code ndr_pull_lsa_ForestTrustBinaryData(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustBinaryData *r)
5323 : {
5324 : uint32_t _ptr_data;
5325 0 : uint32_t size_data_1 = 0;
5326 0 : TALLOC_CTX *_mem_save_data_0 = NULL;
5327 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5328 0 : if (ndr_flags & NDR_SCALARS) {
5329 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
5330 0 : NDR_CHECK(ndr_pull_uint3264(ndr, NDR_SCALARS, &r->length));
5331 0 : if (r->length > 131072) {
5332 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5333 : }
5334 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_data));
5335 0 : if (_ptr_data) {
5336 0 : NDR_PULL_ALLOC(ndr, r->data);
5337 : } else {
5338 0 : r->data = NULL;
5339 : }
5340 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5341 : }
5342 0 : if (ndr_flags & NDR_BUFFERS) {
5343 0 : if (r->data) {
5344 0 : _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
5345 0 : NDR_PULL_SET_MEM_CTX(ndr, r->data, 0);
5346 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->data));
5347 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->data, &size_data_1));
5348 0 : NDR_PULL_ALLOC_N(ndr, r->data, size_data_1);
5349 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->data, size_data_1));
5350 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, 0);
5351 : }
5352 0 : if (r->data) {
5353 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->data, r->length));
5354 : }
5355 : }
5356 0 : return NDR_ERR_SUCCESS;
5357 : }
5358 :
5359 0 : _PUBLIC_ void ndr_print_lsa_ForestTrustBinaryData(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustBinaryData *r)
5360 : {
5361 0 : ndr_print_struct(ndr, name, "lsa_ForestTrustBinaryData");
5362 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5363 0 : ndr->depth++;
5364 0 : ndr_print_uint3264(ndr, "length", r->length);
5365 0 : ndr_print_ptr(ndr, "data", r->data);
5366 0 : ndr->depth++;
5367 0 : if (r->data) {
5368 0 : ndr_print_array_uint8(ndr, "data", r->data, r->length);
5369 : }
5370 0 : ndr->depth--;
5371 0 : ndr->depth--;
5372 : }
5373 :
5374 824 : static enum ndr_err_code ndr_push_lsa_ForestTrustDomainInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustDomainInfo *r)
5375 : {
5376 824 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5377 824 : if (ndr_flags & NDR_SCALARS) {
5378 412 : NDR_CHECK(ndr_push_align(ndr, 5));
5379 412 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain_sid));
5380 412 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->dns_domain_name));
5381 412 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_domain_name));
5382 412 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5383 : }
5384 824 : if (ndr_flags & NDR_BUFFERS) {
5385 412 : if (r->domain_sid) {
5386 412 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->domain_sid));
5387 : }
5388 412 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->dns_domain_name));
5389 412 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_domain_name));
5390 : }
5391 824 : return NDR_ERR_SUCCESS;
5392 : }
5393 :
5394 784 : static enum ndr_err_code ndr_pull_lsa_ForestTrustDomainInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustDomainInfo *r)
5395 : {
5396 : uint32_t _ptr_domain_sid;
5397 784 : TALLOC_CTX *_mem_save_domain_sid_0 = NULL;
5398 784 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5399 784 : if (ndr_flags & NDR_SCALARS) {
5400 392 : NDR_CHECK(ndr_pull_align(ndr, 5));
5401 392 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain_sid));
5402 392 : if (_ptr_domain_sid) {
5403 392 : NDR_PULL_ALLOC(ndr, r->domain_sid);
5404 : } else {
5405 0 : r->domain_sid = NULL;
5406 : }
5407 392 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->dns_domain_name));
5408 392 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->netbios_domain_name));
5409 392 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5410 : }
5411 784 : if (ndr_flags & NDR_BUFFERS) {
5412 392 : if (r->domain_sid) {
5413 392 : _mem_save_domain_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
5414 392 : NDR_PULL_SET_MEM_CTX(ndr, r->domain_sid, 0);
5415 392 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->domain_sid));
5416 392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_sid_0, 0);
5417 : }
5418 392 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->dns_domain_name));
5419 392 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->netbios_domain_name));
5420 : }
5421 784 : return NDR_ERR_SUCCESS;
5422 : }
5423 :
5424 8 : _PUBLIC_ void ndr_print_lsa_ForestTrustDomainInfo(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustDomainInfo *r)
5425 : {
5426 8 : ndr_print_struct(ndr, name, "lsa_ForestTrustDomainInfo");
5427 8 : if (r == NULL) { ndr_print_null(ndr); return; }
5428 8 : ndr->depth++;
5429 8 : ndr_print_ptr(ndr, "domain_sid", r->domain_sid);
5430 8 : ndr->depth++;
5431 8 : if (r->domain_sid) {
5432 8 : ndr_print_dom_sid2(ndr, "domain_sid", r->domain_sid);
5433 : }
5434 8 : ndr->depth--;
5435 8 : ndr_print_lsa_StringLarge(ndr, "dns_domain_name", &r->dns_domain_name);
5436 8 : ndr_print_lsa_StringLarge(ndr, "netbios_domain_name", &r->netbios_domain_name);
5437 8 : ndr->depth--;
5438 : }
5439 :
5440 4488 : static enum ndr_err_code ndr_push_lsa_ForestTrustData(struct ndr_push *ndr, int ndr_flags, const union lsa_ForestTrustData *r)
5441 : {
5442 : uint32_t level;
5443 4488 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5444 4488 : if (ndr_flags & NDR_SCALARS) {
5445 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5446 2244 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5447 2244 : NDR_CHECK(ndr_push_union_align(ndr, 5));
5448 2244 : NDR_CHECK(ndr_push_lsa_ForestTrustRecordType(ndr, NDR_SCALARS, level));
5449 2244 : NDR_CHECK(ndr_push_union_align(ndr, 5));
5450 2244 : switch (level) {
5451 1776 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME: {
5452 1776 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->top_level_name));
5453 1776 : break; }
5454 :
5455 56 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME_EX: {
5456 56 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->top_level_name_ex));
5457 56 : break; }
5458 :
5459 412 : case LSA_FOREST_TRUST_DOMAIN_INFO: {
5460 412 : NDR_CHECK(ndr_push_lsa_ForestTrustDomainInfo(ndr, NDR_SCALARS, &r->domain_info));
5461 412 : break; }
5462 :
5463 0 : default: {
5464 0 : NDR_CHECK(ndr_push_lsa_ForestTrustBinaryData(ndr, NDR_SCALARS, &r->data));
5465 0 : break; }
5466 :
5467 : }
5468 1214 : }
5469 4488 : if (ndr_flags & NDR_BUFFERS) {
5470 2244 : if (!(ndr_flags & NDR_SCALARS)) {
5471 : /* We didn't get it above, and the token is not needed after this. */
5472 2244 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5473 : }
5474 2244 : switch (level) {
5475 1776 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME:
5476 1776 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->top_level_name));
5477 1776 : break;
5478 :
5479 56 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME_EX:
5480 56 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->top_level_name_ex));
5481 56 : break;
5482 :
5483 412 : case LSA_FOREST_TRUST_DOMAIN_INFO:
5484 412 : NDR_CHECK(ndr_push_lsa_ForestTrustDomainInfo(ndr, NDR_BUFFERS, &r->domain_info));
5485 412 : break;
5486 :
5487 0 : default:
5488 0 : NDR_CHECK(ndr_push_lsa_ForestTrustBinaryData(ndr, NDR_BUFFERS, &r->data));
5489 0 : break;
5490 :
5491 : }
5492 1214 : }
5493 4488 : return NDR_ERR_SUCCESS;
5494 : }
5495 :
5496 4340 : static enum ndr_err_code ndr_pull_lsa_ForestTrustData(struct ndr_pull *ndr, int ndr_flags, union lsa_ForestTrustData *r)
5497 : {
5498 : uint32_t level;
5499 : uint16_t _level;
5500 4340 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5501 4340 : if (ndr_flags & NDR_SCALARS) {
5502 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5503 2170 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
5504 2170 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
5505 2170 : NDR_CHECK(ndr_pull_uint1632(ndr, NDR_SCALARS, &_level));
5506 2170 : if (_level != level) {
5507 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %u for r at %s", _level, __location__);
5508 : }
5509 2170 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
5510 2170 : switch (level) {
5511 1722 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME: {
5512 1722 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->top_level_name));
5513 1722 : break; }
5514 :
5515 56 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME_EX: {
5516 56 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->top_level_name_ex));
5517 56 : break; }
5518 :
5519 392 : case LSA_FOREST_TRUST_DOMAIN_INFO: {
5520 392 : NDR_CHECK(ndr_pull_lsa_ForestTrustDomainInfo(ndr, NDR_SCALARS, &r->domain_info));
5521 392 : break; }
5522 :
5523 0 : default: {
5524 0 : NDR_CHECK(ndr_pull_lsa_ForestTrustBinaryData(ndr, NDR_SCALARS, &r->data));
5525 0 : break; }
5526 :
5527 : }
5528 1172 : }
5529 4340 : if (ndr_flags & NDR_BUFFERS) {
5530 2170 : if (!(ndr_flags & NDR_SCALARS)) {
5531 : /* We didn't get it above, and the token is not needed after this. */
5532 2170 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
5533 : }
5534 2170 : switch (level) {
5535 1722 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME:
5536 1722 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->top_level_name));
5537 1722 : break;
5538 :
5539 56 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME_EX:
5540 56 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->top_level_name_ex));
5541 56 : break;
5542 :
5543 392 : case LSA_FOREST_TRUST_DOMAIN_INFO:
5544 392 : NDR_CHECK(ndr_pull_lsa_ForestTrustDomainInfo(ndr, NDR_BUFFERS, &r->domain_info));
5545 392 : break;
5546 :
5547 0 : default:
5548 0 : NDR_CHECK(ndr_pull_lsa_ForestTrustBinaryData(ndr, NDR_BUFFERS, &r->data));
5549 0 : break;
5550 :
5551 : }
5552 1172 : }
5553 4340 : return NDR_ERR_SUCCESS;
5554 : }
5555 :
5556 20 : _PUBLIC_ void ndr_print_lsa_ForestTrustData(struct ndr_print *ndr, const char *name, const union lsa_ForestTrustData *r)
5557 : {
5558 : uint32_t level;
5559 20 : level = ndr_print_steal_switch_value(ndr, r);
5560 20 : ndr_print_union(ndr, name, level, "lsa_ForestTrustData");
5561 20 : switch (level) {
5562 12 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME:
5563 12 : ndr_print_lsa_StringLarge(ndr, "top_level_name", &r->top_level_name);
5564 12 : break;
5565 :
5566 0 : case LSA_FOREST_TRUST_TOP_LEVEL_NAME_EX:
5567 0 : ndr_print_lsa_StringLarge(ndr, "top_level_name_ex", &r->top_level_name_ex);
5568 0 : break;
5569 :
5570 8 : case LSA_FOREST_TRUST_DOMAIN_INFO:
5571 8 : ndr_print_lsa_ForestTrustDomainInfo(ndr, "domain_info", &r->domain_info);
5572 8 : break;
5573 :
5574 0 : default:
5575 0 : ndr_print_lsa_ForestTrustBinaryData(ndr, "data", &r->data);
5576 0 : break;
5577 :
5578 : }
5579 20 : }
5580 :
5581 2244 : static enum ndr_err_code ndr_push_lsa_ForestTrustRecord(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustRecord *r)
5582 : {
5583 2244 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5584 2244 : if (ndr_flags & NDR_SCALARS) {
5585 2244 : NDR_CHECK(ndr_push_align(ndr, 8));
5586 2244 : NDR_CHECK(ndr_push_lsa_ForestTrustRecordFlags(ndr, NDR_SCALARS, r->flags));
5587 2244 : NDR_CHECK(ndr_push_lsa_ForestTrustRecordType(ndr, NDR_SCALARS, r->type));
5588 2244 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, r->time));
5589 2244 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->forest_trust_data, r->type));
5590 2244 : NDR_CHECK(ndr_push_lsa_ForestTrustData(ndr, NDR_SCALARS, &r->forest_trust_data));
5591 2244 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
5592 : }
5593 2244 : if (ndr_flags & NDR_BUFFERS) {
5594 2244 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->forest_trust_data, r->type));
5595 2244 : NDR_CHECK(ndr_push_lsa_ForestTrustData(ndr, NDR_BUFFERS, &r->forest_trust_data));
5596 : }
5597 2244 : return NDR_ERR_SUCCESS;
5598 : }
5599 :
5600 2170 : static enum ndr_err_code ndr_pull_lsa_ForestTrustRecord(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustRecord *r)
5601 : {
5602 2170 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5603 2170 : if (ndr_flags & NDR_SCALARS) {
5604 2170 : NDR_CHECK(ndr_pull_align(ndr, 8));
5605 2170 : NDR_CHECK(ndr_pull_lsa_ForestTrustRecordFlags(ndr, NDR_SCALARS, &r->flags));
5606 2170 : NDR_CHECK(ndr_pull_lsa_ForestTrustRecordType(ndr, NDR_SCALARS, &r->type));
5607 2170 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, &r->time));
5608 2170 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->forest_trust_data, r->type));
5609 2170 : NDR_CHECK(ndr_pull_lsa_ForestTrustData(ndr, NDR_SCALARS, &r->forest_trust_data));
5610 2170 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
5611 : }
5612 2170 : if (ndr_flags & NDR_BUFFERS) {
5613 2170 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->forest_trust_data, r->type));
5614 2170 : NDR_CHECK(ndr_pull_lsa_ForestTrustData(ndr, NDR_BUFFERS, &r->forest_trust_data));
5615 : }
5616 2170 : return NDR_ERR_SUCCESS;
5617 : }
5618 :
5619 20 : _PUBLIC_ void ndr_print_lsa_ForestTrustRecord(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustRecord *r)
5620 : {
5621 20 : ndr_print_struct(ndr, name, "lsa_ForestTrustRecord");
5622 20 : if (r == NULL) { ndr_print_null(ndr); return; }
5623 20 : ndr->depth++;
5624 20 : ndr_print_lsa_ForestTrustRecordFlags(ndr, "flags", r->flags);
5625 20 : ndr_print_lsa_ForestTrustRecordType(ndr, "type", r->type);
5626 20 : ndr_print_NTTIME_hyper(ndr, "time", r->time);
5627 20 : ndr_print_set_switch_value(ndr, &r->forest_trust_data, r->type);
5628 20 : ndr_print_lsa_ForestTrustData(ndr, "forest_trust_data", &r->forest_trust_data);
5629 20 : ndr->depth--;
5630 : }
5631 :
5632 412 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_ForestTrustInformation(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustInformation *r)
5633 : {
5634 : uint32_t cntr_entries_1;
5635 412 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5636 412 : if (ndr_flags & NDR_SCALARS) {
5637 412 : NDR_CHECK(ndr_push_align(ndr, 5));
5638 412 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5639 412 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries));
5640 412 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5641 : }
5642 412 : if (ndr_flags & NDR_BUFFERS) {
5643 412 : if (r->entries) {
5644 412 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5645 2656 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
5646 2244 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries[cntr_entries_1]));
5647 : }
5648 2656 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
5649 2244 : if (r->entries[cntr_entries_1]) {
5650 2244 : NDR_CHECK(ndr_push_lsa_ForestTrustRecord(ndr, NDR_SCALARS|NDR_BUFFERS, r->entries[cntr_entries_1]));
5651 : }
5652 : }
5653 : }
5654 : }
5655 412 : return NDR_ERR_SUCCESS;
5656 : }
5657 :
5658 392 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_ForestTrustInformation(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustInformation *r)
5659 : {
5660 : uint32_t _ptr_entries;
5661 392 : uint32_t size_entries_1 = 0;
5662 : uint32_t cntr_entries_1;
5663 392 : TALLOC_CTX *_mem_save_entries_0 = NULL;
5664 392 : TALLOC_CTX *_mem_save_entries_1 = NULL;
5665 392 : TALLOC_CTX *_mem_save_entries_2 = NULL;
5666 392 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5667 392 : if (ndr_flags & NDR_SCALARS) {
5668 392 : NDR_CHECK(ndr_pull_align(ndr, 5));
5669 392 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5670 392 : if (r->count > 4000) {
5671 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
5672 : }
5673 392 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
5674 392 : if (_ptr_entries) {
5675 392 : NDR_PULL_ALLOC(ndr, r->entries);
5676 : } else {
5677 0 : r->entries = NULL;
5678 : }
5679 392 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5680 : }
5681 392 : if (ndr_flags & NDR_BUFFERS) {
5682 392 : if (r->entries) {
5683 392 : _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
5684 392 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
5685 392 : NDR_CHECK(ndr_pull_array_size(ndr, &r->entries));
5686 392 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->entries, &size_entries_1));
5687 392 : NDR_PULL_ALLOC_N(ndr, r->entries, size_entries_1);
5688 392 : _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
5689 392 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
5690 2562 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
5691 2170 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
5692 2170 : if (_ptr_entries) {
5693 2170 : NDR_PULL_ALLOC(ndr, r->entries[cntr_entries_1]);
5694 : } else {
5695 0 : r->entries[cntr_entries_1] = NULL;
5696 : }
5697 : }
5698 2562 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
5699 2170 : if (r->entries[cntr_entries_1]) {
5700 2170 : _mem_save_entries_2 = NDR_PULL_GET_MEM_CTX(ndr);
5701 2170 : NDR_PULL_SET_MEM_CTX(ndr, r->entries[cntr_entries_1], 0);
5702 2170 : NDR_CHECK(ndr_pull_lsa_ForestTrustRecord(ndr, NDR_SCALARS|NDR_BUFFERS, r->entries[cntr_entries_1]));
5703 2170 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_2, 0);
5704 : }
5705 : }
5706 392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0);
5707 392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
5708 : }
5709 392 : if (r->entries) {
5710 392 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count));
5711 : }
5712 1390 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
5713 : }
5714 : }
5715 392 : return NDR_ERR_SUCCESS;
5716 : }
5717 :
5718 0 : static void ndr_print_flags_lsa_ForestTrustInformation(struct ndr_print *ndr, const char *name, int unused, const struct lsa_ForestTrustInformation *r)
5719 : {
5720 0 : ndr_print_lsa_ForestTrustInformation(ndr, name, r);
5721 0 : }
5722 :
5723 8 : _PUBLIC_ void ndr_print_lsa_ForestTrustInformation(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustInformation *r)
5724 : {
5725 : uint32_t cntr_entries_1;
5726 8 : ndr_print_struct(ndr, name, "lsa_ForestTrustInformation");
5727 8 : if (r == NULL) { ndr_print_null(ndr); return; }
5728 8 : ndr->depth++;
5729 8 : ndr_print_uint32(ndr, "count", r->count);
5730 8 : ndr_print_ptr(ndr, "entries", r->entries);
5731 8 : ndr->depth++;
5732 8 : if (r->entries) {
5733 8 : ndr->print(ndr, "%s: ARRAY(%d)", "entries", (int)r->count);
5734 8 : ndr->depth++;
5735 28 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
5736 20 : ndr_print_ptr(ndr, "entries", r->entries[cntr_entries_1]);
5737 20 : ndr->depth++;
5738 20 : if (r->entries[cntr_entries_1]) {
5739 20 : ndr_print_lsa_ForestTrustRecord(ndr, "entries", r->entries[cntr_entries_1]);
5740 : }
5741 20 : ndr->depth--;
5742 : }
5743 8 : ndr->depth--;
5744 : }
5745 8 : ndr->depth--;
5746 8 : ndr->depth--;
5747 : }
5748 :
5749 36 : static enum ndr_err_code ndr_push_lsa_ForestTrustCollisionRecordType(struct ndr_push *ndr, int ndr_flags, enum lsa_ForestTrustCollisionRecordType r)
5750 : {
5751 36 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
5752 36 : return NDR_ERR_SUCCESS;
5753 : }
5754 :
5755 32 : static enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionRecordType(struct ndr_pull *ndr, int ndr_flags, enum lsa_ForestTrustCollisionRecordType *r)
5756 : {
5757 : uint32_t v;
5758 32 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
5759 32 : *r = v;
5760 32 : return NDR_ERR_SUCCESS;
5761 : }
5762 :
5763 0 : _PUBLIC_ void ndr_print_lsa_ForestTrustCollisionRecordType(struct ndr_print *ndr, const char *name, enum lsa_ForestTrustCollisionRecordType r)
5764 : {
5765 0 : const char *val = NULL;
5766 :
5767 0 : switch (r) {
5768 0 : case LSA_FOREST_TRUST_COLLISION_TDO: val = "LSA_FOREST_TRUST_COLLISION_TDO"; break;
5769 0 : case LSA_FOREST_TRUST_COLLISION_XREF: val = "LSA_FOREST_TRUST_COLLISION_XREF"; break;
5770 0 : case LSA_FOREST_TRUST_COLLISION_OTHER: val = "LSA_FOREST_TRUST_COLLISION_OTHER"; break;
5771 : }
5772 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
5773 0 : }
5774 :
5775 36 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_ForestTrustCollisionRecord(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustCollisionRecord *r)
5776 : {
5777 36 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5778 36 : if (ndr_flags & NDR_SCALARS) {
5779 36 : NDR_CHECK(ndr_push_align(ndr, 5));
5780 36 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->index));
5781 36 : NDR_CHECK(ndr_push_lsa_ForestTrustCollisionRecordType(ndr, NDR_SCALARS, r->type));
5782 36 : NDR_CHECK(ndr_push_lsa_ForestTrustRecordFlags(ndr, NDR_SCALARS, r->flags));
5783 36 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
5784 36 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5785 : }
5786 36 : if (ndr_flags & NDR_BUFFERS) {
5787 36 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
5788 : }
5789 36 : return NDR_ERR_SUCCESS;
5790 : }
5791 :
5792 32 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionRecord(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustCollisionRecord *r)
5793 : {
5794 32 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5795 32 : if (ndr_flags & NDR_SCALARS) {
5796 32 : NDR_CHECK(ndr_pull_align(ndr, 5));
5797 32 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->index));
5798 32 : NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionRecordType(ndr, NDR_SCALARS, &r->type));
5799 32 : NDR_CHECK(ndr_pull_lsa_ForestTrustRecordFlags(ndr, NDR_SCALARS, &r->flags));
5800 32 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
5801 32 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5802 : }
5803 32 : if (ndr_flags & NDR_BUFFERS) {
5804 32 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
5805 : }
5806 32 : return NDR_ERR_SUCCESS;
5807 : }
5808 :
5809 0 : static void ndr_print_flags_lsa_ForestTrustCollisionRecord(struct ndr_print *ndr, const char *name, int unused, const struct lsa_ForestTrustCollisionRecord *r)
5810 : {
5811 0 : ndr_print_lsa_ForestTrustCollisionRecord(ndr, name, r);
5812 0 : }
5813 :
5814 0 : _PUBLIC_ void ndr_print_lsa_ForestTrustCollisionRecord(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustCollisionRecord *r)
5815 : {
5816 0 : ndr_print_struct(ndr, name, "lsa_ForestTrustCollisionRecord");
5817 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5818 0 : ndr->depth++;
5819 0 : ndr_print_uint32(ndr, "index", r->index);
5820 0 : ndr_print_lsa_ForestTrustCollisionRecordType(ndr, "type", r->type);
5821 0 : ndr_print_lsa_ForestTrustRecordFlags(ndr, "flags", r->flags);
5822 0 : ndr_print_lsa_String(ndr, "name", &r->name);
5823 0 : ndr->depth--;
5824 : }
5825 :
5826 20 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_ForestTrustCollisionInfo(struct ndr_push *ndr, int ndr_flags, const struct lsa_ForestTrustCollisionInfo *r)
5827 : {
5828 : uint32_t cntr_entries_1;
5829 20 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5830 20 : if (ndr_flags & NDR_SCALARS) {
5831 20 : NDR_CHECK(ndr_push_align(ndr, 5));
5832 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
5833 20 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries));
5834 20 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5835 : }
5836 20 : if (ndr_flags & NDR_BUFFERS) {
5837 20 : if (r->entries) {
5838 20 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
5839 56 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
5840 36 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries[cntr_entries_1]));
5841 : }
5842 56 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
5843 36 : if (r->entries[cntr_entries_1]) {
5844 36 : NDR_CHECK(ndr_push_lsa_ForestTrustCollisionRecord(ndr, NDR_SCALARS|NDR_BUFFERS, r->entries[cntr_entries_1]));
5845 : }
5846 : }
5847 : }
5848 : }
5849 20 : return NDR_ERR_SUCCESS;
5850 : }
5851 :
5852 16 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_ForestTrustCollisionInfo(struct ndr_pull *ndr, int ndr_flags, struct lsa_ForestTrustCollisionInfo *r)
5853 : {
5854 : uint32_t _ptr_entries;
5855 16 : uint32_t size_entries_1 = 0;
5856 : uint32_t cntr_entries_1;
5857 16 : TALLOC_CTX *_mem_save_entries_0 = NULL;
5858 16 : TALLOC_CTX *_mem_save_entries_1 = NULL;
5859 16 : TALLOC_CTX *_mem_save_entries_2 = NULL;
5860 16 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5861 16 : if (ndr_flags & NDR_SCALARS) {
5862 16 : NDR_CHECK(ndr_pull_align(ndr, 5));
5863 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
5864 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
5865 16 : if (_ptr_entries) {
5866 16 : NDR_PULL_ALLOC(ndr, r->entries);
5867 : } else {
5868 0 : r->entries = NULL;
5869 : }
5870 16 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5871 : }
5872 16 : if (ndr_flags & NDR_BUFFERS) {
5873 16 : if (r->entries) {
5874 16 : _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
5875 16 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
5876 16 : NDR_CHECK(ndr_pull_array_size(ndr, &r->entries));
5877 16 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->entries, &size_entries_1));
5878 16 : NDR_PULL_ALLOC_N(ndr, r->entries, size_entries_1);
5879 16 : _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
5880 16 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
5881 48 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
5882 32 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
5883 32 : if (_ptr_entries) {
5884 32 : NDR_PULL_ALLOC(ndr, r->entries[cntr_entries_1]);
5885 : } else {
5886 0 : r->entries[cntr_entries_1] = NULL;
5887 : }
5888 : }
5889 48 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
5890 32 : if (r->entries[cntr_entries_1]) {
5891 32 : _mem_save_entries_2 = NDR_PULL_GET_MEM_CTX(ndr);
5892 32 : NDR_PULL_SET_MEM_CTX(ndr, r->entries[cntr_entries_1], 0);
5893 32 : NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionRecord(ndr, NDR_SCALARS|NDR_BUFFERS, r->entries[cntr_entries_1]));
5894 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_2, 0);
5895 : }
5896 : }
5897 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0);
5898 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
5899 : }
5900 16 : if (r->entries) {
5901 16 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count));
5902 : }
5903 32 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
5904 : }
5905 : }
5906 16 : return NDR_ERR_SUCCESS;
5907 : }
5908 :
5909 0 : static void ndr_print_flags_lsa_ForestTrustCollisionInfo(struct ndr_print *ndr, const char *name, int unused, const struct lsa_ForestTrustCollisionInfo *r)
5910 : {
5911 0 : ndr_print_lsa_ForestTrustCollisionInfo(ndr, name, r);
5912 0 : }
5913 :
5914 0 : _PUBLIC_ void ndr_print_lsa_ForestTrustCollisionInfo(struct ndr_print *ndr, const char *name, const struct lsa_ForestTrustCollisionInfo *r)
5915 : {
5916 : uint32_t cntr_entries_1;
5917 0 : ndr_print_struct(ndr, name, "lsa_ForestTrustCollisionInfo");
5918 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5919 0 : ndr->depth++;
5920 0 : ndr_print_uint32(ndr, "count", r->count);
5921 0 : ndr_print_ptr(ndr, "entries", r->entries);
5922 0 : ndr->depth++;
5923 0 : if (r->entries) {
5924 0 : ndr->print(ndr, "%s: ARRAY(%d)", "entries", (int)r->count);
5925 0 : ndr->depth++;
5926 0 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
5927 0 : ndr_print_ptr(ndr, "entries", r->entries[cntr_entries_1]);
5928 0 : ndr->depth++;
5929 0 : if (r->entries[cntr_entries_1]) {
5930 0 : ndr_print_lsa_ForestTrustCollisionRecord(ndr, "entries", r->entries[cntr_entries_1]);
5931 : }
5932 0 : ndr->depth--;
5933 : }
5934 0 : ndr->depth--;
5935 : }
5936 0 : ndr->depth--;
5937 0 : ndr->depth--;
5938 : }
5939 :
5940 1681 : static enum ndr_err_code ndr_push_lsa_Close(struct ndr_push *ndr, int flags, const struct lsa_Close *r)
5941 : {
5942 1681 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
5943 1681 : if (flags & NDR_IN) {
5944 843 : if (r->in.handle == NULL) {
5945 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5946 : }
5947 843 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
5948 : }
5949 1681 : if (flags & NDR_OUT) {
5950 838 : if (r->out.handle == NULL) {
5951 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
5952 : }
5953 838 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
5954 838 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
5955 : }
5956 1681 : return NDR_ERR_SUCCESS;
5957 : }
5958 :
5959 1583 : static enum ndr_err_code ndr_pull_lsa_Close(struct ndr_pull *ndr, int flags, struct lsa_Close *r)
5960 : {
5961 1583 : TALLOC_CTX *_mem_save_handle_0 = NULL;
5962 1583 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
5963 1583 : if (flags & NDR_IN) {
5964 836 : NDR_ZERO_STRUCT(r->out);
5965 :
5966 836 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5967 836 : NDR_PULL_ALLOC(ndr, r->in.handle);
5968 : }
5969 836 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
5970 836 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
5971 836 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
5972 836 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
5973 836 : NDR_PULL_ALLOC(ndr, r->out.handle);
5974 836 : *r->out.handle = *r->in.handle;
5975 : }
5976 1583 : if (flags & NDR_OUT) {
5977 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
5978 : if (r->in.handle == NULL) {
5979 : NDR_PULL_ALLOC(ndr, r->in.handle);
5980 : NDR_ZERO_STRUCTP(r->in.handle);
5981 : }
5982 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
5983 747 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
5984 421 : NDR_PULL_ALLOC(ndr, r->out.handle);
5985 : }
5986 747 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
5987 747 : NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
5988 747 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
5989 747 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
5990 747 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
5991 : }
5992 1583 : return NDR_ERR_SUCCESS;
5993 : }
5994 :
5995 196 : _PUBLIC_ void ndr_print_lsa_Close(struct ndr_print *ndr, const char *name, int flags, const struct lsa_Close *r)
5996 : {
5997 196 : ndr_print_struct(ndr, name, "lsa_Close");
5998 196 : if (r == NULL) { ndr_print_null(ndr); return; }
5999 196 : ndr->depth++;
6000 196 : if (flags & NDR_SET_VALUES) {
6001 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6002 : }
6003 196 : if (flags & NDR_IN) {
6004 0 : ndr_print_struct(ndr, "in", "lsa_Close");
6005 0 : ndr->depth++;
6006 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6007 0 : ndr->depth++;
6008 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6009 0 : ndr->depth--;
6010 0 : ndr->depth--;
6011 : }
6012 196 : if (flags & NDR_OUT) {
6013 196 : ndr_print_struct(ndr, "out", "lsa_Close");
6014 196 : ndr->depth++;
6015 196 : ndr_print_ptr(ndr, "handle", r->out.handle);
6016 196 : ndr->depth++;
6017 196 : ndr_print_policy_handle(ndr, "handle", r->out.handle);
6018 196 : ndr->depth--;
6019 196 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6020 196 : ndr->depth--;
6021 : }
6022 196 : ndr->depth--;
6023 : }
6024 :
6025 59 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_Delete(struct ndr_push *ndr, int flags, const struct lsa_Delete *r)
6026 : {
6027 59 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6028 59 : if (flags & NDR_IN) {
6029 26 : if (r->in.handle == NULL) {
6030 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6031 : }
6032 26 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6033 : }
6034 59 : if (flags & NDR_OUT) {
6035 33 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6036 : }
6037 59 : return NDR_ERR_SUCCESS;
6038 : }
6039 :
6040 52 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_Delete(struct ndr_pull *ndr, int flags, struct lsa_Delete *r)
6041 : {
6042 52 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6043 52 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6044 52 : if (flags & NDR_IN) {
6045 26 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6046 26 : NDR_PULL_ALLOC(ndr, r->in.handle);
6047 : }
6048 26 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6049 26 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6050 26 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6051 26 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6052 : }
6053 52 : if (flags & NDR_OUT) {
6054 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6055 : if (r->in.handle == NULL) {
6056 : NDR_PULL_ALLOC(ndr, r->in.handle);
6057 : NDR_ZERO_STRUCTP(r->in.handle);
6058 : }
6059 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6060 26 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6061 : }
6062 52 : return NDR_ERR_SUCCESS;
6063 : }
6064 :
6065 14 : _PUBLIC_ void ndr_print_lsa_Delete(struct ndr_print *ndr, const char *name, int flags, const struct lsa_Delete *r)
6066 : {
6067 14 : ndr_print_struct(ndr, name, "lsa_Delete");
6068 14 : if (r == NULL) { ndr_print_null(ndr); return; }
6069 14 : ndr->depth++;
6070 14 : if (flags & NDR_SET_VALUES) {
6071 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6072 : }
6073 14 : if (flags & NDR_IN) {
6074 0 : ndr_print_struct(ndr, "in", "lsa_Delete");
6075 0 : ndr->depth++;
6076 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6077 0 : ndr->depth++;
6078 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6079 0 : ndr->depth--;
6080 0 : ndr->depth--;
6081 : }
6082 14 : if (flags & NDR_OUT) {
6083 14 : ndr_print_struct(ndr, "out", "lsa_Delete");
6084 14 : ndr->depth++;
6085 14 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6086 14 : ndr->depth--;
6087 : }
6088 14 : ndr->depth--;
6089 : }
6090 :
6091 9 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_EnumPrivs(struct ndr_push *ndr, int flags, const struct lsa_EnumPrivs *r)
6092 : {
6093 9 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6094 9 : if (flags & NDR_IN) {
6095 4 : if (r->in.handle == NULL) {
6096 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6097 : }
6098 4 : if (r->in.resume_handle == NULL) {
6099 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6100 : }
6101 4 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6102 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
6103 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_count));
6104 : }
6105 9 : if (flags & NDR_OUT) {
6106 5 : if (r->out.resume_handle == NULL) {
6107 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6108 : }
6109 5 : if (r->out.privs == NULL) {
6110 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6111 : }
6112 5 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
6113 5 : NDR_CHECK(ndr_push_lsa_PrivArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.privs));
6114 5 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6115 : }
6116 9 : return NDR_ERR_SUCCESS;
6117 : }
6118 :
6119 8 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_EnumPrivs(struct ndr_pull *ndr, int flags, struct lsa_EnumPrivs *r)
6120 : {
6121 8 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6122 8 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
6123 8 : TALLOC_CTX *_mem_save_privs_0 = NULL;
6124 8 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6125 8 : if (flags & NDR_IN) {
6126 4 : NDR_ZERO_STRUCT(r->out);
6127 :
6128 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6129 4 : NDR_PULL_ALLOC(ndr, r->in.handle);
6130 : }
6131 4 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6132 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6133 4 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6134 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6135 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6136 4 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
6137 : }
6138 4 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6139 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
6140 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
6141 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
6142 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_count));
6143 4 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
6144 4 : *r->out.resume_handle = *r->in.resume_handle;
6145 4 : NDR_PULL_ALLOC(ndr, r->out.privs);
6146 4 : NDR_ZERO_STRUCTP(r->out.privs);
6147 : }
6148 8 : if (flags & NDR_OUT) {
6149 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6150 : if (r->in.handle == NULL) {
6151 : NDR_PULL_ALLOC(ndr, r->in.handle);
6152 : NDR_ZERO_STRUCTP(r->in.handle);
6153 : }
6154 : if (r->in.resume_handle == NULL) {
6155 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
6156 : NDR_ZERO_STRUCTP(r->in.resume_handle);
6157 : }
6158 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6159 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6160 1 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
6161 : }
6162 4 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6163 4 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
6164 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
6165 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
6166 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6167 1 : NDR_PULL_ALLOC(ndr, r->out.privs);
6168 : }
6169 4 : _mem_save_privs_0 = NDR_PULL_GET_MEM_CTX(ndr);
6170 4 : NDR_PULL_SET_MEM_CTX(ndr, r->out.privs, LIBNDR_FLAG_REF_ALLOC);
6171 4 : NDR_CHECK(ndr_pull_lsa_PrivArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.privs));
6172 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_0, LIBNDR_FLAG_REF_ALLOC);
6173 4 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6174 : }
6175 8 : return NDR_ERR_SUCCESS;
6176 : }
6177 :
6178 2 : _PUBLIC_ void ndr_print_lsa_EnumPrivs(struct ndr_print *ndr, const char *name, int flags, const struct lsa_EnumPrivs *r)
6179 : {
6180 2 : ndr_print_struct(ndr, name, "lsa_EnumPrivs");
6181 2 : if (r == NULL) { ndr_print_null(ndr); return; }
6182 2 : ndr->depth++;
6183 2 : if (flags & NDR_SET_VALUES) {
6184 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6185 : }
6186 2 : if (flags & NDR_IN) {
6187 0 : ndr_print_struct(ndr, "in", "lsa_EnumPrivs");
6188 0 : ndr->depth++;
6189 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6190 0 : ndr->depth++;
6191 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6192 0 : ndr->depth--;
6193 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
6194 0 : ndr->depth++;
6195 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
6196 0 : ndr->depth--;
6197 0 : ndr_print_uint32(ndr, "max_count", r->in.max_count);
6198 0 : ndr->depth--;
6199 : }
6200 2 : if (flags & NDR_OUT) {
6201 2 : ndr_print_struct(ndr, "out", "lsa_EnumPrivs");
6202 2 : ndr->depth++;
6203 2 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
6204 2 : ndr->depth++;
6205 2 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
6206 2 : ndr->depth--;
6207 2 : ndr_print_ptr(ndr, "privs", r->out.privs);
6208 2 : ndr->depth++;
6209 2 : ndr_print_lsa_PrivArray(ndr, "privs", r->out.privs);
6210 2 : ndr->depth--;
6211 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6212 2 : ndr->depth--;
6213 : }
6214 2 : ndr->depth--;
6215 : }
6216 :
6217 36 : static enum ndr_err_code ndr_push_lsa_QuerySecurity(struct ndr_push *ndr, int flags, const struct lsa_QuerySecurity *r)
6218 : {
6219 36 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6220 36 : if (flags & NDR_IN) {
6221 16 : if (r->in.handle == NULL) {
6222 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6223 : }
6224 16 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6225 16 : NDR_CHECK(ndr_push_security_secinfo(ndr, NDR_SCALARS, r->in.sec_info));
6226 : }
6227 36 : if (flags & NDR_OUT) {
6228 20 : if (r->out.sdbuf == NULL) {
6229 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6230 : }
6231 20 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sdbuf));
6232 20 : if (*r->out.sdbuf) {
6233 20 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sdbuf));
6234 : }
6235 20 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6236 : }
6237 36 : return NDR_ERR_SUCCESS;
6238 : }
6239 :
6240 32 : static enum ndr_err_code ndr_pull_lsa_QuerySecurity(struct ndr_pull *ndr, int flags, struct lsa_QuerySecurity *r)
6241 : {
6242 : uint32_t _ptr_sdbuf;
6243 32 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6244 32 : TALLOC_CTX *_mem_save_sdbuf_0 = NULL;
6245 32 : TALLOC_CTX *_mem_save_sdbuf_1 = NULL;
6246 32 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6247 32 : if (flags & NDR_IN) {
6248 16 : NDR_ZERO_STRUCT(r->out);
6249 :
6250 16 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6251 16 : NDR_PULL_ALLOC(ndr, r->in.handle);
6252 : }
6253 16 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6254 16 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6255 16 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6256 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6257 16 : NDR_CHECK(ndr_pull_security_secinfo(ndr, NDR_SCALARS, &r->in.sec_info));
6258 16 : NDR_PULL_ALLOC(ndr, r->out.sdbuf);
6259 16 : NDR_ZERO_STRUCTP(r->out.sdbuf);
6260 : }
6261 32 : if (flags & NDR_OUT) {
6262 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6263 : if (r->in.handle == NULL) {
6264 : NDR_PULL_ALLOC(ndr, r->in.handle);
6265 : NDR_ZERO_STRUCTP(r->in.handle);
6266 : }
6267 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6268 16 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6269 4 : NDR_PULL_ALLOC(ndr, r->out.sdbuf);
6270 : }
6271 16 : _mem_save_sdbuf_0 = NDR_PULL_GET_MEM_CTX(ndr);
6272 16 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sdbuf, LIBNDR_FLAG_REF_ALLOC);
6273 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sdbuf));
6274 16 : if (_ptr_sdbuf) {
6275 16 : NDR_PULL_ALLOC(ndr, *r->out.sdbuf);
6276 : } else {
6277 0 : *r->out.sdbuf = NULL;
6278 : }
6279 16 : if (*r->out.sdbuf) {
6280 16 : _mem_save_sdbuf_1 = NDR_PULL_GET_MEM_CTX(ndr);
6281 16 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sdbuf, 0);
6282 16 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sdbuf));
6283 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sdbuf_1, 0);
6284 : }
6285 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sdbuf_0, LIBNDR_FLAG_REF_ALLOC);
6286 16 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6287 : }
6288 32 : return NDR_ERR_SUCCESS;
6289 : }
6290 :
6291 8 : _PUBLIC_ void ndr_print_lsa_QuerySecurity(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QuerySecurity *r)
6292 : {
6293 8 : ndr_print_struct(ndr, name, "lsa_QuerySecurity");
6294 8 : if (r == NULL) { ndr_print_null(ndr); return; }
6295 8 : ndr->depth++;
6296 8 : if (flags & NDR_SET_VALUES) {
6297 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6298 : }
6299 8 : if (flags & NDR_IN) {
6300 0 : ndr_print_struct(ndr, "in", "lsa_QuerySecurity");
6301 0 : ndr->depth++;
6302 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6303 0 : ndr->depth++;
6304 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6305 0 : ndr->depth--;
6306 0 : ndr_print_security_secinfo(ndr, "sec_info", r->in.sec_info);
6307 0 : ndr->depth--;
6308 : }
6309 8 : if (flags & NDR_OUT) {
6310 8 : ndr_print_struct(ndr, "out", "lsa_QuerySecurity");
6311 8 : ndr->depth++;
6312 8 : ndr_print_ptr(ndr, "sdbuf", r->out.sdbuf);
6313 8 : ndr->depth++;
6314 8 : ndr_print_ptr(ndr, "sdbuf", *r->out.sdbuf);
6315 8 : ndr->depth++;
6316 8 : if (*r->out.sdbuf) {
6317 8 : ndr_print_sec_desc_buf(ndr, "sdbuf", *r->out.sdbuf);
6318 : }
6319 8 : ndr->depth--;
6320 8 : ndr->depth--;
6321 8 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6322 8 : ndr->depth--;
6323 : }
6324 8 : ndr->depth--;
6325 : }
6326 :
6327 0 : static enum ndr_err_code ndr_push_lsa_SetSecObj(struct ndr_push *ndr, int flags, const struct lsa_SetSecObj *r)
6328 : {
6329 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6330 0 : if (flags & NDR_IN) {
6331 0 : if (r->in.handle == NULL) {
6332 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6333 : }
6334 0 : if (r->in.sdbuf == NULL) {
6335 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6336 : }
6337 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6338 0 : NDR_CHECK(ndr_push_security_secinfo(ndr, NDR_SCALARS, r->in.sec_info));
6339 0 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sdbuf));
6340 : }
6341 0 : if (flags & NDR_OUT) {
6342 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6343 : }
6344 0 : return NDR_ERR_SUCCESS;
6345 : }
6346 :
6347 0 : static enum ndr_err_code ndr_pull_lsa_SetSecObj(struct ndr_pull *ndr, int flags, struct lsa_SetSecObj *r)
6348 : {
6349 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6350 0 : TALLOC_CTX *_mem_save_sdbuf_0 = NULL;
6351 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6352 0 : if (flags & NDR_IN) {
6353 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6354 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
6355 : }
6356 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6357 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6358 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6359 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6360 0 : NDR_CHECK(ndr_pull_security_secinfo(ndr, NDR_SCALARS, &r->in.sec_info));
6361 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6362 0 : NDR_PULL_ALLOC(ndr, r->in.sdbuf);
6363 : }
6364 0 : _mem_save_sdbuf_0 = NDR_PULL_GET_MEM_CTX(ndr);
6365 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sdbuf, LIBNDR_FLAG_REF_ALLOC);
6366 0 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sdbuf));
6367 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sdbuf_0, LIBNDR_FLAG_REF_ALLOC);
6368 : }
6369 0 : if (flags & NDR_OUT) {
6370 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6371 : if (r->in.handle == NULL) {
6372 : NDR_PULL_ALLOC(ndr, r->in.handle);
6373 : NDR_ZERO_STRUCTP(r->in.handle);
6374 : }
6375 : if (r->in.sdbuf == NULL) {
6376 : NDR_PULL_ALLOC(ndr, r->in.sdbuf);
6377 : NDR_ZERO_STRUCTP(r->in.sdbuf);
6378 : }
6379 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6380 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6381 : }
6382 0 : return NDR_ERR_SUCCESS;
6383 : }
6384 :
6385 0 : _PUBLIC_ void ndr_print_lsa_SetSecObj(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetSecObj *r)
6386 : {
6387 0 : ndr_print_struct(ndr, name, "lsa_SetSecObj");
6388 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6389 0 : ndr->depth++;
6390 0 : if (flags & NDR_SET_VALUES) {
6391 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6392 : }
6393 0 : if (flags & NDR_IN) {
6394 0 : ndr_print_struct(ndr, "in", "lsa_SetSecObj");
6395 0 : ndr->depth++;
6396 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6397 0 : ndr->depth++;
6398 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6399 0 : ndr->depth--;
6400 0 : ndr_print_security_secinfo(ndr, "sec_info", r->in.sec_info);
6401 0 : ndr_print_ptr(ndr, "sdbuf", r->in.sdbuf);
6402 0 : ndr->depth++;
6403 0 : ndr_print_sec_desc_buf(ndr, "sdbuf", r->in.sdbuf);
6404 0 : ndr->depth--;
6405 0 : ndr->depth--;
6406 : }
6407 0 : if (flags & NDR_OUT) {
6408 0 : ndr_print_struct(ndr, "out", "lsa_SetSecObj");
6409 0 : ndr->depth++;
6410 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6411 0 : ndr->depth--;
6412 : }
6413 0 : ndr->depth--;
6414 : }
6415 :
6416 0 : static enum ndr_err_code ndr_push_lsa_ChangePassword(struct ndr_push *ndr, int flags, const struct lsa_ChangePassword *r)
6417 : {
6418 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6419 0 : if (flags & NDR_IN) {
6420 : }
6421 0 : if (flags & NDR_OUT) {
6422 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6423 : }
6424 0 : return NDR_ERR_SUCCESS;
6425 : }
6426 :
6427 0 : static enum ndr_err_code ndr_pull_lsa_ChangePassword(struct ndr_pull *ndr, int flags, struct lsa_ChangePassword *r)
6428 : {
6429 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6430 0 : if (flags & NDR_IN) {
6431 : }
6432 0 : if (flags & NDR_OUT) {
6433 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6434 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6435 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6436 : }
6437 0 : return NDR_ERR_SUCCESS;
6438 : }
6439 :
6440 0 : _PUBLIC_ void ndr_print_lsa_ChangePassword(struct ndr_print *ndr, const char *name, int flags, const struct lsa_ChangePassword *r)
6441 : {
6442 0 : ndr_print_struct(ndr, name, "lsa_ChangePassword");
6443 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6444 0 : ndr->depth++;
6445 0 : if (flags & NDR_SET_VALUES) {
6446 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6447 : }
6448 0 : if (flags & NDR_IN) {
6449 0 : ndr_print_struct(ndr, "in", "lsa_ChangePassword");
6450 0 : ndr->depth++;
6451 0 : ndr->depth--;
6452 : }
6453 0 : if (flags & NDR_OUT) {
6454 0 : ndr_print_struct(ndr, "out", "lsa_ChangePassword");
6455 0 : ndr->depth++;
6456 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6457 0 : ndr->depth--;
6458 : }
6459 0 : ndr->depth--;
6460 : }
6461 :
6462 994 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_OpenPolicy(struct ndr_push *ndr, int flags, const struct lsa_OpenPolicy *r)
6463 : {
6464 994 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6465 994 : if (flags & NDR_IN) {
6466 356 : if (r->in.attr == NULL) {
6467 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6468 : }
6469 356 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
6470 356 : if (r->in.system_name) {
6471 356 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, *r->in.system_name));
6472 : }
6473 356 : NDR_CHECK(ndr_push_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
6474 356 : NDR_CHECK(ndr_push_lsa_PolicyAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
6475 : }
6476 994 : if (flags & NDR_OUT) {
6477 638 : if (r->out.handle == NULL) {
6478 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6479 : }
6480 638 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
6481 638 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6482 : }
6483 994 : return NDR_ERR_SUCCESS;
6484 : }
6485 :
6486 986 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_OpenPolicy(struct ndr_pull *ndr, int flags, struct lsa_OpenPolicy *r)
6487 : {
6488 : uint32_t _ptr_system_name;
6489 986 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
6490 986 : TALLOC_CTX *_mem_save_attr_0 = NULL;
6491 986 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6492 986 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6493 986 : if (flags & NDR_IN) {
6494 634 : NDR_ZERO_STRUCT(r->out);
6495 :
6496 634 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
6497 634 : if (_ptr_system_name) {
6498 634 : NDR_PULL_ALLOC(ndr, r->in.system_name);
6499 : } else {
6500 0 : r->in.system_name = NULL;
6501 : }
6502 634 : if (r->in.system_name) {
6503 634 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
6504 634 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
6505 634 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, r->in.system_name));
6506 634 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
6507 : }
6508 634 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6509 634 : NDR_PULL_ALLOC(ndr, r->in.attr);
6510 : }
6511 634 : _mem_save_attr_0 = NDR_PULL_GET_MEM_CTX(ndr);
6512 634 : NDR_PULL_SET_MEM_CTX(ndr, r->in.attr, LIBNDR_FLAG_REF_ALLOC);
6513 634 : NDR_CHECK(ndr_pull_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
6514 634 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_attr_0, LIBNDR_FLAG_REF_ALLOC);
6515 634 : NDR_CHECK(ndr_pull_lsa_PolicyAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
6516 634 : NDR_PULL_ALLOC(ndr, r->out.handle);
6517 634 : NDR_ZERO_STRUCTP(r->out.handle);
6518 : }
6519 986 : if (flags & NDR_OUT) {
6520 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6521 : if (r->in.attr == NULL) {
6522 : NDR_PULL_ALLOC(ndr, r->in.attr);
6523 : NDR_ZERO_STRUCTP(r->in.attr);
6524 : }
6525 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6526 352 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6527 326 : NDR_PULL_ALLOC(ndr, r->out.handle);
6528 : }
6529 352 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6530 352 : NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
6531 352 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
6532 352 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6533 352 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6534 : }
6535 986 : return NDR_ERR_SUCCESS;
6536 : }
6537 :
6538 16 : _PUBLIC_ void ndr_print_lsa_OpenPolicy(struct ndr_print *ndr, const char *name, int flags, const struct lsa_OpenPolicy *r)
6539 : {
6540 16 : ndr_print_struct(ndr, name, "lsa_OpenPolicy");
6541 16 : if (r == NULL) { ndr_print_null(ndr); return; }
6542 16 : ndr->depth++;
6543 16 : if (flags & NDR_SET_VALUES) {
6544 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6545 : }
6546 16 : if (flags & NDR_IN) {
6547 0 : ndr_print_struct(ndr, "in", "lsa_OpenPolicy");
6548 0 : ndr->depth++;
6549 0 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
6550 0 : ndr->depth++;
6551 0 : if (r->in.system_name) {
6552 0 : ndr_print_uint16(ndr, "system_name", *r->in.system_name);
6553 : }
6554 0 : ndr->depth--;
6555 0 : ndr_print_ptr(ndr, "attr", r->in.attr);
6556 0 : ndr->depth++;
6557 0 : ndr_print_lsa_ObjectAttribute(ndr, "attr", r->in.attr);
6558 0 : ndr->depth--;
6559 0 : ndr_print_lsa_PolicyAccessMask(ndr, "access_mask", r->in.access_mask);
6560 0 : ndr->depth--;
6561 : }
6562 16 : if (flags & NDR_OUT) {
6563 16 : ndr_print_struct(ndr, "out", "lsa_OpenPolicy");
6564 16 : ndr->depth++;
6565 16 : ndr_print_ptr(ndr, "handle", r->out.handle);
6566 16 : ndr->depth++;
6567 16 : ndr_print_policy_handle(ndr, "handle", r->out.handle);
6568 16 : ndr->depth--;
6569 16 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6570 16 : ndr->depth--;
6571 : }
6572 16 : ndr->depth--;
6573 : }
6574 :
6575 1317 : static enum ndr_err_code ndr_push_lsa_QueryInfoPolicy(struct ndr_push *ndr, int flags, const struct lsa_QueryInfoPolicy *r)
6576 : {
6577 1317 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6578 1317 : if (flags & NDR_IN) {
6579 603 : if (r->in.handle == NULL) {
6580 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6581 : }
6582 603 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6583 603 : NDR_CHECK(ndr_push_lsa_PolicyInfo(ndr, NDR_SCALARS, r->in.level));
6584 : }
6585 1317 : if (flags & NDR_OUT) {
6586 714 : if (r->out.info == NULL) {
6587 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6588 : }
6589 714 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
6590 714 : if (*r->out.info) {
6591 684 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
6592 684 : NDR_CHECK(ndr_push_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
6593 : }
6594 714 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6595 : }
6596 1317 : return NDR_ERR_SUCCESS;
6597 : }
6598 :
6599 1221 : static enum ndr_err_code ndr_pull_lsa_QueryInfoPolicy(struct ndr_pull *ndr, int flags, struct lsa_QueryInfoPolicy *r)
6600 : {
6601 : uint32_t _ptr_info;
6602 1221 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6603 1221 : TALLOC_CTX *_mem_save_info_0 = NULL;
6604 1221 : TALLOC_CTX *_mem_save_info_1 = NULL;
6605 1221 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6606 1221 : if (flags & NDR_IN) {
6607 618 : NDR_ZERO_STRUCT(r->out);
6608 :
6609 618 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6610 618 : NDR_PULL_ALLOC(ndr, r->in.handle);
6611 : }
6612 618 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6613 618 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6614 618 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6615 618 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6616 618 : NDR_CHECK(ndr_pull_lsa_PolicyInfo(ndr, NDR_SCALARS, &r->in.level));
6617 618 : NDR_PULL_ALLOC(ndr, r->out.info);
6618 618 : NDR_ZERO_STRUCTP(r->out.info);
6619 : }
6620 1221 : if (flags & NDR_OUT) {
6621 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6622 : if (r->in.handle == NULL) {
6623 : NDR_PULL_ALLOC(ndr, r->in.handle);
6624 : NDR_ZERO_STRUCTP(r->in.handle);
6625 : }
6626 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6627 603 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6628 238 : NDR_PULL_ALLOC(ndr, r->out.info);
6629 : }
6630 603 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
6631 603 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
6632 603 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
6633 603 : if (_ptr_info) {
6634 579 : NDR_PULL_ALLOC(ndr, *r->out.info);
6635 : } else {
6636 24 : *r->out.info = NULL;
6637 : }
6638 603 : if (*r->out.info) {
6639 579 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
6640 579 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
6641 579 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
6642 579 : NDR_CHECK(ndr_pull_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
6643 579 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
6644 : }
6645 603 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
6646 603 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6647 : }
6648 1221 : return NDR_ERR_SUCCESS;
6649 : }
6650 :
6651 192 : _PUBLIC_ void ndr_print_lsa_QueryInfoPolicy(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QueryInfoPolicy *r)
6652 : {
6653 192 : ndr_print_struct(ndr, name, "lsa_QueryInfoPolicy");
6654 192 : if (r == NULL) { ndr_print_null(ndr); return; }
6655 192 : ndr->depth++;
6656 192 : if (flags & NDR_SET_VALUES) {
6657 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6658 : }
6659 192 : if (flags & NDR_IN) {
6660 0 : ndr_print_struct(ndr, "in", "lsa_QueryInfoPolicy");
6661 0 : ndr->depth++;
6662 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6663 0 : ndr->depth++;
6664 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6665 0 : ndr->depth--;
6666 0 : ndr_print_lsa_PolicyInfo(ndr, "level", r->in.level);
6667 0 : ndr->depth--;
6668 : }
6669 192 : if (flags & NDR_OUT) {
6670 192 : ndr_print_struct(ndr, "out", "lsa_QueryInfoPolicy");
6671 192 : ndr->depth++;
6672 192 : ndr_print_ptr(ndr, "info", r->out.info);
6673 192 : ndr->depth++;
6674 192 : ndr_print_ptr(ndr, "info", *r->out.info);
6675 192 : ndr->depth++;
6676 192 : if (*r->out.info) {
6677 180 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
6678 180 : ndr_print_lsa_PolicyInformation(ndr, "info", *r->out.info);
6679 : }
6680 192 : ndr->depth--;
6681 192 : ndr->depth--;
6682 192 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6683 192 : ndr->depth--;
6684 : }
6685 192 : ndr->depth--;
6686 : }
6687 :
6688 0 : static enum ndr_err_code ndr_push_lsa_SetInfoPolicy(struct ndr_push *ndr, int flags, const struct lsa_SetInfoPolicy *r)
6689 : {
6690 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6691 0 : if (flags & NDR_IN) {
6692 0 : if (r->in.handle == NULL) {
6693 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6694 : }
6695 0 : if (r->in.info == NULL) {
6696 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6697 : }
6698 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6699 0 : NDR_CHECK(ndr_push_lsa_PolicyInfo(ndr, NDR_SCALARS, r->in.level));
6700 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
6701 0 : NDR_CHECK(ndr_push_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
6702 : }
6703 0 : if (flags & NDR_OUT) {
6704 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6705 : }
6706 0 : return NDR_ERR_SUCCESS;
6707 : }
6708 :
6709 0 : static enum ndr_err_code ndr_pull_lsa_SetInfoPolicy(struct ndr_pull *ndr, int flags, struct lsa_SetInfoPolicy *r)
6710 : {
6711 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6712 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
6713 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6714 0 : if (flags & NDR_IN) {
6715 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6716 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
6717 : }
6718 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6719 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6720 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6721 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6722 0 : NDR_CHECK(ndr_pull_lsa_PolicyInfo(ndr, NDR_SCALARS, &r->in.level));
6723 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6724 0 : NDR_PULL_ALLOC(ndr, r->in.info);
6725 : }
6726 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
6727 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
6728 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
6729 0 : NDR_CHECK(ndr_pull_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
6730 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
6731 : }
6732 0 : if (flags & NDR_OUT) {
6733 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6734 : if (r->in.handle == NULL) {
6735 : NDR_PULL_ALLOC(ndr, r->in.handle);
6736 : NDR_ZERO_STRUCTP(r->in.handle);
6737 : }
6738 : if (r->in.info == NULL) {
6739 : NDR_PULL_ALLOC(ndr, r->in.info);
6740 : NDR_ZERO_STRUCTP(r->in.info);
6741 : }
6742 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6743 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6744 : }
6745 0 : return NDR_ERR_SUCCESS;
6746 : }
6747 :
6748 0 : _PUBLIC_ void ndr_print_lsa_SetInfoPolicy(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetInfoPolicy *r)
6749 : {
6750 0 : ndr_print_struct(ndr, name, "lsa_SetInfoPolicy");
6751 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6752 0 : ndr->depth++;
6753 0 : if (flags & NDR_SET_VALUES) {
6754 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6755 : }
6756 0 : if (flags & NDR_IN) {
6757 0 : ndr_print_struct(ndr, "in", "lsa_SetInfoPolicy");
6758 0 : ndr->depth++;
6759 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6760 0 : ndr->depth++;
6761 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6762 0 : ndr->depth--;
6763 0 : ndr_print_lsa_PolicyInfo(ndr, "level", r->in.level);
6764 0 : ndr_print_ptr(ndr, "info", r->in.info);
6765 0 : ndr->depth++;
6766 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
6767 0 : ndr_print_lsa_PolicyInformation(ndr, "info", r->in.info);
6768 0 : ndr->depth--;
6769 0 : ndr->depth--;
6770 : }
6771 0 : if (flags & NDR_OUT) {
6772 0 : ndr_print_struct(ndr, "out", "lsa_SetInfoPolicy");
6773 0 : ndr->depth++;
6774 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6775 0 : ndr->depth--;
6776 : }
6777 0 : ndr->depth--;
6778 : }
6779 :
6780 0 : static enum ndr_err_code ndr_push_lsa_ClearAuditLog(struct ndr_push *ndr, int flags, const struct lsa_ClearAuditLog *r)
6781 : {
6782 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6783 0 : if (flags & NDR_IN) {
6784 : }
6785 0 : if (flags & NDR_OUT) {
6786 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6787 : }
6788 0 : return NDR_ERR_SUCCESS;
6789 : }
6790 :
6791 0 : static enum ndr_err_code ndr_pull_lsa_ClearAuditLog(struct ndr_pull *ndr, int flags, struct lsa_ClearAuditLog *r)
6792 : {
6793 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6794 0 : if (flags & NDR_IN) {
6795 : }
6796 0 : if (flags & NDR_OUT) {
6797 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6798 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6799 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6800 : }
6801 0 : return NDR_ERR_SUCCESS;
6802 : }
6803 :
6804 0 : _PUBLIC_ void ndr_print_lsa_ClearAuditLog(struct ndr_print *ndr, const char *name, int flags, const struct lsa_ClearAuditLog *r)
6805 : {
6806 0 : ndr_print_struct(ndr, name, "lsa_ClearAuditLog");
6807 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6808 0 : ndr->depth++;
6809 0 : if (flags & NDR_SET_VALUES) {
6810 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6811 : }
6812 0 : if (flags & NDR_IN) {
6813 0 : ndr_print_struct(ndr, "in", "lsa_ClearAuditLog");
6814 0 : ndr->depth++;
6815 0 : ndr->depth--;
6816 : }
6817 0 : if (flags & NDR_OUT) {
6818 0 : ndr_print_struct(ndr, "out", "lsa_ClearAuditLog");
6819 0 : ndr->depth++;
6820 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6821 0 : ndr->depth--;
6822 : }
6823 0 : ndr->depth--;
6824 : }
6825 :
6826 9 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_CreateAccount(struct ndr_push *ndr, int flags, const struct lsa_CreateAccount *r)
6827 : {
6828 9 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6829 9 : if (flags & NDR_IN) {
6830 4 : if (r->in.handle == NULL) {
6831 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6832 : }
6833 4 : if (r->in.sid == NULL) {
6834 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6835 : }
6836 4 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6837 4 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
6838 4 : NDR_CHECK(ndr_push_lsa_AccountAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
6839 : }
6840 9 : if (flags & NDR_OUT) {
6841 5 : if (r->out.acct_handle == NULL) {
6842 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6843 : }
6844 5 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.acct_handle));
6845 5 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6846 : }
6847 9 : return NDR_ERR_SUCCESS;
6848 : }
6849 :
6850 8 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_CreateAccount(struct ndr_pull *ndr, int flags, struct lsa_CreateAccount *r)
6851 : {
6852 8 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6853 8 : TALLOC_CTX *_mem_save_sid_0 = NULL;
6854 8 : TALLOC_CTX *_mem_save_acct_handle_0 = NULL;
6855 8 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6856 8 : if (flags & NDR_IN) {
6857 4 : NDR_ZERO_STRUCT(r->out);
6858 :
6859 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6860 4 : NDR_PULL_ALLOC(ndr, r->in.handle);
6861 : }
6862 4 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6863 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6864 4 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6865 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6866 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6867 4 : NDR_PULL_ALLOC(ndr, r->in.sid);
6868 : }
6869 4 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
6870 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
6871 4 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
6872 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
6873 4 : NDR_CHECK(ndr_pull_lsa_AccountAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
6874 4 : NDR_PULL_ALLOC(ndr, r->out.acct_handle);
6875 4 : NDR_ZERO_STRUCTP(r->out.acct_handle);
6876 : }
6877 8 : if (flags & NDR_OUT) {
6878 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6879 : if (r->in.handle == NULL) {
6880 : NDR_PULL_ALLOC(ndr, r->in.handle);
6881 : NDR_ZERO_STRUCTP(r->in.handle);
6882 : }
6883 : if (r->in.sid == NULL) {
6884 : NDR_PULL_ALLOC(ndr, r->in.sid);
6885 : NDR_ZERO_STRUCTP(r->in.sid);
6886 : }
6887 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6888 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6889 1 : NDR_PULL_ALLOC(ndr, r->out.acct_handle);
6890 : }
6891 4 : _mem_save_acct_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6892 4 : NDR_PULL_SET_MEM_CTX(ndr, r->out.acct_handle, LIBNDR_FLAG_REF_ALLOC);
6893 4 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.acct_handle));
6894 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_acct_handle_0, LIBNDR_FLAG_REF_ALLOC);
6895 4 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6896 : }
6897 8 : return NDR_ERR_SUCCESS;
6898 : }
6899 :
6900 2 : _PUBLIC_ void ndr_print_lsa_CreateAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CreateAccount *r)
6901 : {
6902 2 : ndr_print_struct(ndr, name, "lsa_CreateAccount");
6903 2 : if (r == NULL) { ndr_print_null(ndr); return; }
6904 2 : ndr->depth++;
6905 2 : if (flags & NDR_SET_VALUES) {
6906 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6907 : }
6908 2 : if (flags & NDR_IN) {
6909 0 : ndr_print_struct(ndr, "in", "lsa_CreateAccount");
6910 0 : ndr->depth++;
6911 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6912 0 : ndr->depth++;
6913 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6914 0 : ndr->depth--;
6915 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
6916 0 : ndr->depth++;
6917 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
6918 0 : ndr->depth--;
6919 0 : ndr_print_lsa_AccountAccessMask(ndr, "access_mask", r->in.access_mask);
6920 0 : ndr->depth--;
6921 : }
6922 2 : if (flags & NDR_OUT) {
6923 2 : ndr_print_struct(ndr, "out", "lsa_CreateAccount");
6924 2 : ndr->depth++;
6925 2 : ndr_print_ptr(ndr, "acct_handle", r->out.acct_handle);
6926 2 : ndr->depth++;
6927 2 : ndr_print_policy_handle(ndr, "acct_handle", r->out.acct_handle);
6928 2 : ndr->depth--;
6929 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6930 2 : ndr->depth--;
6931 : }
6932 2 : ndr->depth--;
6933 : }
6934 :
6935 42 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_EnumAccounts(struct ndr_push *ndr, int flags, const struct lsa_EnumAccounts *r)
6936 : {
6937 42 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6938 42 : if (flags & NDR_IN) {
6939 20 : if (r->in.handle == NULL) {
6940 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6941 : }
6942 20 : if (r->in.resume_handle == NULL) {
6943 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6944 : }
6945 20 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6946 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
6947 20 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_entries));
6948 : }
6949 42 : if (flags & NDR_OUT) {
6950 22 : if (r->out.resume_handle == NULL) {
6951 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6952 : }
6953 22 : if (r->out.sids == NULL) {
6954 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6955 : }
6956 22 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
6957 22 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
6958 22 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6959 : }
6960 42 : return NDR_ERR_SUCCESS;
6961 : }
6962 :
6963 40 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_EnumAccounts(struct ndr_pull *ndr, int flags, struct lsa_EnumAccounts *r)
6964 : {
6965 40 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6966 40 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
6967 40 : TALLOC_CTX *_mem_save_sids_0 = NULL;
6968 40 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6969 40 : if (flags & NDR_IN) {
6970 20 : NDR_ZERO_STRUCT(r->out);
6971 :
6972 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6973 20 : NDR_PULL_ALLOC(ndr, r->in.handle);
6974 : }
6975 20 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6976 20 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6977 20 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6978 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6979 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6980 20 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
6981 : }
6982 20 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6983 20 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
6984 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
6985 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
6986 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_entries));
6987 20 : if (r->in.num_entries > 8192) {
6988 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
6989 : }
6990 20 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
6991 20 : *r->out.resume_handle = *r->in.resume_handle;
6992 20 : NDR_PULL_ALLOC(ndr, r->out.sids);
6993 20 : NDR_ZERO_STRUCTP(r->out.sids);
6994 : }
6995 40 : if (flags & NDR_OUT) {
6996 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6997 : if (r->in.handle == NULL) {
6998 : NDR_PULL_ALLOC(ndr, r->in.handle);
6999 : NDR_ZERO_STRUCTP(r->in.handle);
7000 : }
7001 : if (r->in.resume_handle == NULL) {
7002 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7003 : NDR_ZERO_STRUCTP(r->in.resume_handle);
7004 : }
7005 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7006 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7007 2 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7008 : }
7009 20 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7010 20 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7011 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
7012 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7013 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7014 2 : NDR_PULL_ALLOC(ndr, r->out.sids);
7015 : }
7016 20 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
7017 20 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
7018 20 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
7019 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
7020 20 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7021 : }
7022 40 : return NDR_ERR_SUCCESS;
7023 : }
7024 :
7025 4 : _PUBLIC_ void ndr_print_lsa_EnumAccounts(struct ndr_print *ndr, const char *name, int flags, const struct lsa_EnumAccounts *r)
7026 : {
7027 4 : ndr_print_struct(ndr, name, "lsa_EnumAccounts");
7028 4 : if (r == NULL) { ndr_print_null(ndr); return; }
7029 4 : ndr->depth++;
7030 4 : if (flags & NDR_SET_VALUES) {
7031 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7032 : }
7033 4 : if (flags & NDR_IN) {
7034 0 : ndr_print_struct(ndr, "in", "lsa_EnumAccounts");
7035 0 : ndr->depth++;
7036 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
7037 0 : ndr->depth++;
7038 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
7039 0 : ndr->depth--;
7040 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
7041 0 : ndr->depth++;
7042 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
7043 0 : ndr->depth--;
7044 0 : ndr_print_uint32(ndr, "num_entries", r->in.num_entries);
7045 0 : ndr->depth--;
7046 : }
7047 4 : if (flags & NDR_OUT) {
7048 4 : ndr_print_struct(ndr, "out", "lsa_EnumAccounts");
7049 4 : ndr->depth++;
7050 4 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
7051 4 : ndr->depth++;
7052 4 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
7053 4 : ndr->depth--;
7054 4 : ndr_print_ptr(ndr, "sids", r->out.sids);
7055 4 : ndr->depth++;
7056 4 : ndr_print_lsa_SidArray(ndr, "sids", r->out.sids);
7057 4 : ndr->depth--;
7058 4 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7059 4 : ndr->depth--;
7060 : }
7061 4 : ndr->depth--;
7062 : }
7063 :
7064 108 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_CreateTrustedDomain(struct ndr_push *ndr, int flags, const struct lsa_CreateTrustedDomain *r)
7065 : {
7066 108 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7067 108 : if (flags & NDR_IN) {
7068 48 : if (r->in.policy_handle == NULL) {
7069 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7070 : }
7071 48 : if (r->in.info == NULL) {
7072 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7073 : }
7074 48 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.policy_handle));
7075 48 : NDR_CHECK(ndr_push_lsa_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
7076 48 : NDR_CHECK(ndr_push_lsa_TrustedAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
7077 : }
7078 108 : if (flags & NDR_OUT) {
7079 60 : if (r->out.trustdom_handle == NULL) {
7080 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7081 : }
7082 60 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
7083 60 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7084 : }
7085 108 : return NDR_ERR_SUCCESS;
7086 : }
7087 :
7088 96 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_CreateTrustedDomain(struct ndr_pull *ndr, int flags, struct lsa_CreateTrustedDomain *r)
7089 : {
7090 96 : TALLOC_CTX *_mem_save_policy_handle_0 = NULL;
7091 96 : TALLOC_CTX *_mem_save_info_0 = NULL;
7092 96 : TALLOC_CTX *_mem_save_trustdom_handle_0 = NULL;
7093 96 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7094 96 : if (flags & NDR_IN) {
7095 48 : NDR_ZERO_STRUCT(r->out);
7096 :
7097 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7098 48 : NDR_PULL_ALLOC(ndr, r->in.policy_handle);
7099 : }
7100 48 : _mem_save_policy_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7101 48 : NDR_PULL_SET_MEM_CTX(ndr, r->in.policy_handle, LIBNDR_FLAG_REF_ALLOC);
7102 48 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.policy_handle));
7103 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_policy_handle_0, LIBNDR_FLAG_REF_ALLOC);
7104 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7105 48 : NDR_PULL_ALLOC(ndr, r->in.info);
7106 : }
7107 48 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
7108 48 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
7109 48 : NDR_CHECK(ndr_pull_lsa_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
7110 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
7111 48 : NDR_CHECK(ndr_pull_lsa_TrustedAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
7112 48 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
7113 48 : NDR_ZERO_STRUCTP(r->out.trustdom_handle);
7114 : }
7115 96 : if (flags & NDR_OUT) {
7116 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7117 : if (r->in.policy_handle == NULL) {
7118 : NDR_PULL_ALLOC(ndr, r->in.policy_handle);
7119 : NDR_ZERO_STRUCTP(r->in.policy_handle);
7120 : }
7121 : if (r->in.info == NULL) {
7122 : NDR_PULL_ALLOC(ndr, r->in.info);
7123 : NDR_ZERO_STRUCTP(r->in.info);
7124 : }
7125 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7126 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7127 12 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
7128 : }
7129 48 : _mem_save_trustdom_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7130 48 : NDR_PULL_SET_MEM_CTX(ndr, r->out.trustdom_handle, LIBNDR_FLAG_REF_ALLOC);
7131 48 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
7132 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trustdom_handle_0, LIBNDR_FLAG_REF_ALLOC);
7133 48 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7134 : }
7135 96 : return NDR_ERR_SUCCESS;
7136 : }
7137 :
7138 24 : _PUBLIC_ void ndr_print_lsa_CreateTrustedDomain(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CreateTrustedDomain *r)
7139 : {
7140 24 : ndr_print_struct(ndr, name, "lsa_CreateTrustedDomain");
7141 24 : if (r == NULL) { ndr_print_null(ndr); return; }
7142 24 : ndr->depth++;
7143 24 : if (flags & NDR_SET_VALUES) {
7144 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7145 : }
7146 24 : if (flags & NDR_IN) {
7147 0 : ndr_print_struct(ndr, "in", "lsa_CreateTrustedDomain");
7148 0 : ndr->depth++;
7149 0 : ndr_print_ptr(ndr, "policy_handle", r->in.policy_handle);
7150 0 : ndr->depth++;
7151 0 : ndr_print_policy_handle(ndr, "policy_handle", r->in.policy_handle);
7152 0 : ndr->depth--;
7153 0 : ndr_print_ptr(ndr, "info", r->in.info);
7154 0 : ndr->depth++;
7155 0 : ndr_print_lsa_DomainInfo(ndr, "info", r->in.info);
7156 0 : ndr->depth--;
7157 0 : ndr_print_lsa_TrustedAccessMask(ndr, "access_mask", r->in.access_mask);
7158 0 : ndr->depth--;
7159 : }
7160 24 : if (flags & NDR_OUT) {
7161 24 : ndr_print_struct(ndr, "out", "lsa_CreateTrustedDomain");
7162 24 : ndr->depth++;
7163 24 : ndr_print_ptr(ndr, "trustdom_handle", r->out.trustdom_handle);
7164 24 : ndr->depth++;
7165 24 : ndr_print_policy_handle(ndr, "trustdom_handle", r->out.trustdom_handle);
7166 24 : ndr->depth--;
7167 24 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7168 24 : ndr->depth--;
7169 : }
7170 24 : ndr->depth--;
7171 : }
7172 :
7173 153 : static enum ndr_err_code ndr_push_lsa_EnumTrustDom(struct ndr_push *ndr, int flags, const struct lsa_EnumTrustDom *r)
7174 : {
7175 153 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7176 153 : if (flags & NDR_IN) {
7177 68 : if (r->in.handle == NULL) {
7178 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7179 : }
7180 68 : if (r->in.resume_handle == NULL) {
7181 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7182 : }
7183 68 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7184 68 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
7185 68 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_size));
7186 : }
7187 153 : if (flags & NDR_OUT) {
7188 85 : if (r->out.resume_handle == NULL) {
7189 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7190 : }
7191 85 : if (r->out.domains == NULL) {
7192 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7193 : }
7194 85 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
7195 85 : NDR_CHECK(ndr_push_lsa_DomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
7196 85 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7197 : }
7198 153 : return NDR_ERR_SUCCESS;
7199 : }
7200 :
7201 136 : static enum ndr_err_code ndr_pull_lsa_EnumTrustDom(struct ndr_pull *ndr, int flags, struct lsa_EnumTrustDom *r)
7202 : {
7203 136 : TALLOC_CTX *_mem_save_handle_0 = NULL;
7204 136 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
7205 136 : TALLOC_CTX *_mem_save_domains_0 = NULL;
7206 136 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7207 136 : if (flags & NDR_IN) {
7208 68 : NDR_ZERO_STRUCT(r->out);
7209 :
7210 68 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7211 68 : NDR_PULL_ALLOC(ndr, r->in.handle);
7212 : }
7213 68 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7214 68 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
7215 68 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7216 68 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
7217 68 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7218 68 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7219 : }
7220 68 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7221 68 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7222 68 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
7223 68 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7224 68 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_size));
7225 68 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7226 68 : *r->out.resume_handle = *r->in.resume_handle;
7227 68 : NDR_PULL_ALLOC(ndr, r->out.domains);
7228 68 : NDR_ZERO_STRUCTP(r->out.domains);
7229 : }
7230 136 : if (flags & NDR_OUT) {
7231 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7232 : if (r->in.handle == NULL) {
7233 : NDR_PULL_ALLOC(ndr, r->in.handle);
7234 : NDR_ZERO_STRUCTP(r->in.handle);
7235 : }
7236 : if (r->in.resume_handle == NULL) {
7237 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7238 : NDR_ZERO_STRUCTP(r->in.resume_handle);
7239 : }
7240 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7241 68 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7242 17 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7243 : }
7244 68 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7245 68 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7246 68 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
7247 68 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7248 68 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7249 17 : NDR_PULL_ALLOC(ndr, r->out.domains);
7250 : }
7251 68 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
7252 68 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
7253 68 : NDR_CHECK(ndr_pull_lsa_DomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
7254 68 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
7255 68 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7256 : }
7257 136 : return NDR_ERR_SUCCESS;
7258 : }
7259 :
7260 34 : _PUBLIC_ void ndr_print_lsa_EnumTrustDom(struct ndr_print *ndr, const char *name, int flags, const struct lsa_EnumTrustDom *r)
7261 : {
7262 34 : ndr_print_struct(ndr, name, "lsa_EnumTrustDom");
7263 34 : if (r == NULL) { ndr_print_null(ndr); return; }
7264 34 : ndr->depth++;
7265 34 : if (flags & NDR_SET_VALUES) {
7266 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7267 : }
7268 34 : if (flags & NDR_IN) {
7269 0 : ndr_print_struct(ndr, "in", "lsa_EnumTrustDom");
7270 0 : ndr->depth++;
7271 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
7272 0 : ndr->depth++;
7273 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
7274 0 : ndr->depth--;
7275 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
7276 0 : ndr->depth++;
7277 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
7278 0 : ndr->depth--;
7279 0 : ndr_print_uint32(ndr, "max_size", r->in.max_size);
7280 0 : ndr->depth--;
7281 : }
7282 34 : if (flags & NDR_OUT) {
7283 34 : ndr_print_struct(ndr, "out", "lsa_EnumTrustDom");
7284 34 : ndr->depth++;
7285 34 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
7286 34 : ndr->depth++;
7287 34 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
7288 34 : ndr->depth--;
7289 34 : ndr_print_ptr(ndr, "domains", r->out.domains);
7290 34 : ndr->depth++;
7291 34 : ndr_print_lsa_DomainList(ndr, "domains", r->out.domains);
7292 34 : ndr->depth--;
7293 34 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7294 34 : ndr->depth--;
7295 : }
7296 34 : ndr->depth--;
7297 : }
7298 :
7299 647 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupNames(struct ndr_push *ndr, int flags, const struct lsa_LookupNames *r)
7300 : {
7301 : uint32_t cntr_names_0;
7302 647 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7303 647 : if (flags & NDR_IN) {
7304 308 : if (r->in.handle == NULL) {
7305 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7306 : }
7307 308 : if (r->in.sids == NULL) {
7308 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7309 : }
7310 308 : if (r->in.count == NULL) {
7311 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7312 : }
7313 308 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7314 308 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_names));
7315 308 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.num_names));
7316 1845 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
7317 1537 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
7318 : }
7319 1845 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
7320 1537 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
7321 : }
7322 308 : NDR_CHECK(ndr_push_lsa_TransSidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
7323 308 : NDR_CHECK(ndr_push_lsa_LookupNamesLevel(ndr, NDR_SCALARS, r->in.level));
7324 308 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
7325 : }
7326 647 : if (flags & NDR_OUT) {
7327 339 : if (r->out.domains == NULL) {
7328 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7329 : }
7330 339 : if (r->out.sids == NULL) {
7331 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7332 : }
7333 339 : if (r->out.count == NULL) {
7334 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7335 : }
7336 339 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
7337 339 : if (*r->out.domains) {
7338 339 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
7339 : }
7340 339 : NDR_CHECK(ndr_push_lsa_TransSidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
7341 339 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
7342 339 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7343 : }
7344 647 : return NDR_ERR_SUCCESS;
7345 : }
7346 :
7347 606 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames(struct ndr_pull *ndr, int flags, struct lsa_LookupNames *r)
7348 : {
7349 606 : uint32_t size_names_0 = 0;
7350 : uint32_t cntr_names_0;
7351 : uint32_t _ptr_domains;
7352 606 : TALLOC_CTX *_mem_save_handle_0 = NULL;
7353 606 : TALLOC_CTX *_mem_save_names_0 = NULL;
7354 606 : TALLOC_CTX *_mem_save_domains_0 = NULL;
7355 606 : TALLOC_CTX *_mem_save_domains_1 = NULL;
7356 606 : TALLOC_CTX *_mem_save_sids_0 = NULL;
7357 606 : TALLOC_CTX *_mem_save_count_0 = NULL;
7358 606 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7359 606 : if (flags & NDR_IN) {
7360 298 : NDR_ZERO_STRUCT(r->out);
7361 :
7362 298 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7363 298 : NDR_PULL_ALLOC(ndr, r->in.handle);
7364 : }
7365 298 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7366 298 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
7367 298 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7368 298 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
7369 298 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_names));
7370 298 : if (r->in.num_names > 1000) {
7371 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
7372 : }
7373 298 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.names));
7374 298 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.names, &size_names_0));
7375 298 : NDR_PULL_ALLOC_N(ndr, r->in.names, size_names_0);
7376 298 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
7377 298 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, 0);
7378 1825 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
7379 1527 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
7380 : }
7381 1825 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
7382 1527 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
7383 : }
7384 298 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
7385 298 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7386 298 : NDR_PULL_ALLOC(ndr, r->in.sids);
7387 : }
7388 298 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
7389 298 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
7390 298 : NDR_CHECK(ndr_pull_lsa_TransSidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
7391 298 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
7392 298 : NDR_CHECK(ndr_pull_lsa_LookupNamesLevel(ndr, NDR_SCALARS, &r->in.level));
7393 298 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7394 298 : NDR_PULL_ALLOC(ndr, r->in.count);
7395 : }
7396 298 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
7397 298 : NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
7398 298 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
7399 298 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
7400 298 : NDR_PULL_ALLOC(ndr, r->out.domains);
7401 298 : NDR_ZERO_STRUCTP(r->out.domains);
7402 298 : NDR_PULL_ALLOC(ndr, r->out.sids);
7403 298 : *r->out.sids = *r->in.sids;
7404 298 : NDR_PULL_ALLOC(ndr, r->out.count);
7405 298 : *r->out.count = *r->in.count;
7406 298 : if (r->in.names) {
7407 298 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.names, r->in.num_names));
7408 : }
7409 364 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
7410 : }
7411 : }
7412 606 : if (flags & NDR_OUT) {
7413 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7414 : if (r->in.handle == NULL) {
7415 : NDR_PULL_ALLOC(ndr, r->in.handle);
7416 : NDR_ZERO_STRUCTP(r->in.handle);
7417 : }
7418 : if (r->in.sids == NULL) {
7419 : NDR_PULL_ALLOC(ndr, r->in.sids);
7420 : NDR_ZERO_STRUCTP(r->in.sids);
7421 : }
7422 : if (r->in.count == NULL) {
7423 : NDR_PULL_ALLOC(ndr, r->in.count);
7424 : NDR_ZERO_STRUCTP(r->in.count);
7425 : }
7426 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7427 308 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7428 192 : NDR_PULL_ALLOC(ndr, r->out.domains);
7429 : }
7430 308 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
7431 308 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
7432 308 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
7433 308 : if (_ptr_domains) {
7434 308 : NDR_PULL_ALLOC(ndr, *r->out.domains);
7435 : } else {
7436 0 : *r->out.domains = NULL;
7437 : }
7438 308 : if (*r->out.domains) {
7439 308 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
7440 308 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
7441 308 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
7442 308 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
7443 : }
7444 308 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
7445 308 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7446 192 : NDR_PULL_ALLOC(ndr, r->out.sids);
7447 : }
7448 308 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
7449 308 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
7450 308 : NDR_CHECK(ndr_pull_lsa_TransSidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
7451 308 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
7452 308 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7453 192 : NDR_PULL_ALLOC(ndr, r->out.count);
7454 : }
7455 308 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
7456 308 : NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
7457 308 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
7458 308 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
7459 308 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7460 : }
7461 606 : return NDR_ERR_SUCCESS;
7462 : }
7463 :
7464 82 : _PUBLIC_ void ndr_print_lsa_LookupNames(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupNames *r)
7465 : {
7466 : uint32_t cntr_names_0;
7467 82 : ndr_print_struct(ndr, name, "lsa_LookupNames");
7468 82 : if (r == NULL) { ndr_print_null(ndr); return; }
7469 82 : ndr->depth++;
7470 82 : if (flags & NDR_SET_VALUES) {
7471 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7472 : }
7473 82 : if (flags & NDR_IN) {
7474 0 : ndr_print_struct(ndr, "in", "lsa_LookupNames");
7475 0 : ndr->depth++;
7476 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
7477 0 : ndr->depth++;
7478 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
7479 0 : ndr->depth--;
7480 0 : ndr_print_uint32(ndr, "num_names", r->in.num_names);
7481 0 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->in.num_names);
7482 0 : ndr->depth++;
7483 0 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
7484 0 : ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
7485 : }
7486 0 : ndr->depth--;
7487 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
7488 0 : ndr->depth++;
7489 0 : ndr_print_lsa_TransSidArray(ndr, "sids", r->in.sids);
7490 0 : ndr->depth--;
7491 0 : ndr_print_lsa_LookupNamesLevel(ndr, "level", r->in.level);
7492 0 : ndr_print_ptr(ndr, "count", r->in.count);
7493 0 : ndr->depth++;
7494 0 : ndr_print_uint32(ndr, "count", *r->in.count);
7495 0 : ndr->depth--;
7496 0 : ndr->depth--;
7497 : }
7498 82 : if (flags & NDR_OUT) {
7499 82 : ndr_print_struct(ndr, "out", "lsa_LookupNames");
7500 82 : ndr->depth++;
7501 82 : ndr_print_ptr(ndr, "domains", r->out.domains);
7502 82 : ndr->depth++;
7503 82 : ndr_print_ptr(ndr, "domains", *r->out.domains);
7504 82 : ndr->depth++;
7505 82 : if (*r->out.domains) {
7506 82 : ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
7507 : }
7508 82 : ndr->depth--;
7509 82 : ndr->depth--;
7510 82 : ndr_print_ptr(ndr, "sids", r->out.sids);
7511 82 : ndr->depth++;
7512 82 : ndr_print_lsa_TransSidArray(ndr, "sids", r->out.sids);
7513 82 : ndr->depth--;
7514 82 : ndr_print_ptr(ndr, "count", r->out.count);
7515 82 : ndr->depth++;
7516 82 : ndr_print_uint32(ndr, "count", *r->out.count);
7517 82 : ndr->depth--;
7518 82 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7519 82 : ndr->depth--;
7520 : }
7521 82 : ndr->depth--;
7522 : }
7523 :
7524 978 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupSids(struct ndr_push *ndr, int flags, const struct lsa_LookupSids *r)
7525 : {
7526 978 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7527 978 : if (flags & NDR_IN) {
7528 437 : if (r->in.handle == NULL) {
7529 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7530 : }
7531 437 : if (r->in.sids == NULL) {
7532 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7533 : }
7534 437 : if (r->in.names == NULL) {
7535 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7536 : }
7537 437 : if (r->in.count == NULL) {
7538 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7539 : }
7540 437 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7541 437 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
7542 437 : NDR_CHECK(ndr_push_lsa_TransNameArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.names));
7543 437 : NDR_CHECK(ndr_push_lsa_LookupNamesLevel(ndr, NDR_SCALARS, r->in.level));
7544 437 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
7545 : }
7546 978 : if (flags & NDR_OUT) {
7547 541 : if (r->out.domains == NULL) {
7548 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7549 : }
7550 541 : if (r->out.names == NULL) {
7551 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7552 : }
7553 541 : if (r->out.count == NULL) {
7554 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7555 : }
7556 541 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
7557 541 : if (*r->out.domains) {
7558 541 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
7559 : }
7560 541 : NDR_CHECK(ndr_push_lsa_TransNameArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
7561 541 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
7562 541 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7563 : }
7564 978 : return NDR_ERR_SUCCESS;
7565 : }
7566 :
7567 874 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids(struct ndr_pull *ndr, int flags, struct lsa_LookupSids *r)
7568 : {
7569 : uint32_t _ptr_domains;
7570 874 : TALLOC_CTX *_mem_save_handle_0 = NULL;
7571 874 : TALLOC_CTX *_mem_save_sids_0 = NULL;
7572 874 : TALLOC_CTX *_mem_save_domains_0 = NULL;
7573 874 : TALLOC_CTX *_mem_save_domains_1 = NULL;
7574 874 : TALLOC_CTX *_mem_save_names_0 = NULL;
7575 874 : TALLOC_CTX *_mem_save_count_0 = NULL;
7576 874 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7577 874 : if (flags & NDR_IN) {
7578 437 : NDR_ZERO_STRUCT(r->out);
7579 :
7580 437 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7581 437 : NDR_PULL_ALLOC(ndr, r->in.handle);
7582 : }
7583 437 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7584 437 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
7585 437 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7586 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
7587 437 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7588 437 : NDR_PULL_ALLOC(ndr, r->in.sids);
7589 : }
7590 437 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
7591 437 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
7592 437 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
7593 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
7594 437 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7595 437 : NDR_PULL_ALLOC(ndr, r->in.names);
7596 : }
7597 437 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
7598 437 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, LIBNDR_FLAG_REF_ALLOC);
7599 437 : NDR_CHECK(ndr_pull_lsa_TransNameArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.names));
7600 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
7601 437 : NDR_CHECK(ndr_pull_lsa_LookupNamesLevel(ndr, NDR_SCALARS, &r->in.level));
7602 437 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7603 437 : NDR_PULL_ALLOC(ndr, r->in.count);
7604 : }
7605 437 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
7606 437 : NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
7607 437 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
7608 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
7609 437 : NDR_PULL_ALLOC(ndr, r->out.domains);
7610 437 : NDR_ZERO_STRUCTP(r->out.domains);
7611 437 : NDR_PULL_ALLOC(ndr, r->out.names);
7612 437 : *r->out.names = *r->in.names;
7613 437 : NDR_PULL_ALLOC(ndr, r->out.count);
7614 437 : *r->out.count = *r->in.count;
7615 : }
7616 874 : if (flags & NDR_OUT) {
7617 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7618 : if (r->in.handle == NULL) {
7619 : NDR_PULL_ALLOC(ndr, r->in.handle);
7620 : NDR_ZERO_STRUCTP(r->in.handle);
7621 : }
7622 : if (r->in.sids == NULL) {
7623 : NDR_PULL_ALLOC(ndr, r->in.sids);
7624 : NDR_ZERO_STRUCTP(r->in.sids);
7625 : }
7626 : if (r->in.names == NULL) {
7627 : NDR_PULL_ALLOC(ndr, r->in.names);
7628 : NDR_ZERO_STRUCTP(r->in.names);
7629 : }
7630 : if (r->in.count == NULL) {
7631 : NDR_PULL_ALLOC(ndr, r->in.count);
7632 : NDR_ZERO_STRUCTP(r->in.count);
7633 : }
7634 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7635 437 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7636 105 : NDR_PULL_ALLOC(ndr, r->out.domains);
7637 : }
7638 437 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
7639 437 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
7640 437 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
7641 437 : if (_ptr_domains) {
7642 437 : NDR_PULL_ALLOC(ndr, *r->out.domains);
7643 : } else {
7644 0 : *r->out.domains = NULL;
7645 : }
7646 437 : if (*r->out.domains) {
7647 437 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
7648 437 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
7649 437 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
7650 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
7651 : }
7652 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
7653 437 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7654 105 : NDR_PULL_ALLOC(ndr, r->out.names);
7655 : }
7656 437 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
7657 437 : NDR_PULL_SET_MEM_CTX(ndr, r->out.names, LIBNDR_FLAG_REF_ALLOC);
7658 437 : NDR_CHECK(ndr_pull_lsa_TransNameArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
7659 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
7660 437 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7661 105 : NDR_PULL_ALLOC(ndr, r->out.count);
7662 : }
7663 437 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
7664 437 : NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
7665 437 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
7666 437 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
7667 437 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7668 : }
7669 874 : return NDR_ERR_SUCCESS;
7670 : }
7671 :
7672 208 : _PUBLIC_ void ndr_print_lsa_LookupSids(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupSids *r)
7673 : {
7674 208 : ndr_print_struct(ndr, name, "lsa_LookupSids");
7675 208 : if (r == NULL) { ndr_print_null(ndr); return; }
7676 208 : ndr->depth++;
7677 208 : if (flags & NDR_SET_VALUES) {
7678 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7679 : }
7680 208 : if (flags & NDR_IN) {
7681 0 : ndr_print_struct(ndr, "in", "lsa_LookupSids");
7682 0 : ndr->depth++;
7683 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
7684 0 : ndr->depth++;
7685 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
7686 0 : ndr->depth--;
7687 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
7688 0 : ndr->depth++;
7689 0 : ndr_print_lsa_SidArray(ndr, "sids", r->in.sids);
7690 0 : ndr->depth--;
7691 0 : ndr_print_ptr(ndr, "names", r->in.names);
7692 0 : ndr->depth++;
7693 0 : ndr_print_lsa_TransNameArray(ndr, "names", r->in.names);
7694 0 : ndr->depth--;
7695 0 : ndr_print_lsa_LookupNamesLevel(ndr, "level", r->in.level);
7696 0 : ndr_print_ptr(ndr, "count", r->in.count);
7697 0 : ndr->depth++;
7698 0 : ndr_print_uint32(ndr, "count", *r->in.count);
7699 0 : ndr->depth--;
7700 0 : ndr->depth--;
7701 : }
7702 208 : if (flags & NDR_OUT) {
7703 208 : ndr_print_struct(ndr, "out", "lsa_LookupSids");
7704 208 : ndr->depth++;
7705 208 : ndr_print_ptr(ndr, "domains", r->out.domains);
7706 208 : ndr->depth++;
7707 208 : ndr_print_ptr(ndr, "domains", *r->out.domains);
7708 208 : ndr->depth++;
7709 208 : if (*r->out.domains) {
7710 208 : ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
7711 : }
7712 208 : ndr->depth--;
7713 208 : ndr->depth--;
7714 208 : ndr_print_ptr(ndr, "names", r->out.names);
7715 208 : ndr->depth++;
7716 208 : ndr_print_lsa_TransNameArray(ndr, "names", r->out.names);
7717 208 : ndr->depth--;
7718 208 : ndr_print_ptr(ndr, "count", r->out.count);
7719 208 : ndr->depth++;
7720 208 : ndr_print_uint32(ndr, "count", *r->out.count);
7721 208 : ndr->depth--;
7722 208 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7723 208 : ndr->depth--;
7724 : }
7725 208 : ndr->depth--;
7726 : }
7727 :
7728 3334 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_CreateSecret(struct ndr_push *ndr, int flags, const struct lsa_CreateSecret *r)
7729 : {
7730 3334 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7731 3334 : if (flags & NDR_IN) {
7732 1663 : if (r->in.handle == NULL) {
7733 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7734 : }
7735 1663 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7736 1663 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.name));
7737 1663 : NDR_CHECK(ndr_push_lsa_SecretAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
7738 : }
7739 3334 : if (flags & NDR_OUT) {
7740 1671 : if (r->out.sec_handle == NULL) {
7741 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7742 : }
7743 1671 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.sec_handle));
7744 1671 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7745 : }
7746 3334 : return NDR_ERR_SUCCESS;
7747 : }
7748 :
7749 3326 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_CreateSecret(struct ndr_pull *ndr, int flags, struct lsa_CreateSecret *r)
7750 : {
7751 3326 : TALLOC_CTX *_mem_save_handle_0 = NULL;
7752 3326 : TALLOC_CTX *_mem_save_sec_handle_0 = NULL;
7753 3326 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7754 3326 : if (flags & NDR_IN) {
7755 1663 : NDR_ZERO_STRUCT(r->out);
7756 :
7757 1663 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7758 1663 : NDR_PULL_ALLOC(ndr, r->in.handle);
7759 : }
7760 1663 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7761 1663 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
7762 1663 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7763 1663 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
7764 1663 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.name));
7765 1663 : NDR_CHECK(ndr_pull_lsa_SecretAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
7766 1663 : NDR_PULL_ALLOC(ndr, r->out.sec_handle);
7767 1663 : NDR_ZERO_STRUCTP(r->out.sec_handle);
7768 : }
7769 3326 : if (flags & NDR_OUT) {
7770 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7771 : if (r->in.handle == NULL) {
7772 : NDR_PULL_ALLOC(ndr, r->in.handle);
7773 : NDR_ZERO_STRUCTP(r->in.handle);
7774 : }
7775 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7776 1663 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7777 9 : NDR_PULL_ALLOC(ndr, r->out.sec_handle);
7778 : }
7779 1663 : _mem_save_sec_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7780 1663 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sec_handle, LIBNDR_FLAG_REF_ALLOC);
7781 1663 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.sec_handle));
7782 1663 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sec_handle_0, LIBNDR_FLAG_REF_ALLOC);
7783 1663 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7784 : }
7785 3326 : return NDR_ERR_SUCCESS;
7786 : }
7787 :
7788 16 : _PUBLIC_ void ndr_print_lsa_CreateSecret(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CreateSecret *r)
7789 : {
7790 16 : ndr_print_struct(ndr, name, "lsa_CreateSecret");
7791 16 : if (r == NULL) { ndr_print_null(ndr); return; }
7792 16 : ndr->depth++;
7793 16 : if (flags & NDR_SET_VALUES) {
7794 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7795 : }
7796 16 : if (flags & NDR_IN) {
7797 0 : ndr_print_struct(ndr, "in", "lsa_CreateSecret");
7798 0 : ndr->depth++;
7799 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
7800 0 : ndr->depth++;
7801 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
7802 0 : ndr->depth--;
7803 0 : ndr_print_lsa_String(ndr, "name", &r->in.name);
7804 0 : ndr_print_lsa_SecretAccessMask(ndr, "access_mask", r->in.access_mask);
7805 0 : ndr->depth--;
7806 : }
7807 16 : if (flags & NDR_OUT) {
7808 16 : ndr_print_struct(ndr, "out", "lsa_CreateSecret");
7809 16 : ndr->depth++;
7810 16 : ndr_print_ptr(ndr, "sec_handle", r->out.sec_handle);
7811 16 : ndr->depth++;
7812 16 : ndr_print_policy_handle(ndr, "sec_handle", r->out.sec_handle);
7813 16 : ndr->depth--;
7814 16 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7815 16 : ndr->depth--;
7816 : }
7817 16 : ndr->depth--;
7818 : }
7819 :
7820 70 : static enum ndr_err_code ndr_push_lsa_OpenAccount(struct ndr_push *ndr, int flags, const struct lsa_OpenAccount *r)
7821 : {
7822 70 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7823 70 : if (flags & NDR_IN) {
7824 32 : if (r->in.handle == NULL) {
7825 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7826 : }
7827 32 : if (r->in.sid == NULL) {
7828 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7829 : }
7830 32 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7831 32 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
7832 32 : NDR_CHECK(ndr_push_lsa_AccountAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
7833 : }
7834 70 : if (flags & NDR_OUT) {
7835 38 : if (r->out.acct_handle == NULL) {
7836 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7837 : }
7838 38 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.acct_handle));
7839 38 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7840 : }
7841 70 : return NDR_ERR_SUCCESS;
7842 : }
7843 :
7844 64 : static enum ndr_err_code ndr_pull_lsa_OpenAccount(struct ndr_pull *ndr, int flags, struct lsa_OpenAccount *r)
7845 : {
7846 64 : TALLOC_CTX *_mem_save_handle_0 = NULL;
7847 64 : TALLOC_CTX *_mem_save_sid_0 = NULL;
7848 64 : TALLOC_CTX *_mem_save_acct_handle_0 = NULL;
7849 64 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7850 64 : if (flags & NDR_IN) {
7851 32 : NDR_ZERO_STRUCT(r->out);
7852 :
7853 32 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7854 32 : NDR_PULL_ALLOC(ndr, r->in.handle);
7855 : }
7856 32 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7857 32 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
7858 32 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7859 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
7860 32 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7861 32 : NDR_PULL_ALLOC(ndr, r->in.sid);
7862 : }
7863 32 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
7864 32 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
7865 32 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
7866 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
7867 32 : NDR_CHECK(ndr_pull_lsa_AccountAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
7868 32 : NDR_PULL_ALLOC(ndr, r->out.acct_handle);
7869 32 : NDR_ZERO_STRUCTP(r->out.acct_handle);
7870 : }
7871 64 : if (flags & NDR_OUT) {
7872 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7873 : if (r->in.handle == NULL) {
7874 : NDR_PULL_ALLOC(ndr, r->in.handle);
7875 : NDR_ZERO_STRUCTP(r->in.handle);
7876 : }
7877 : if (r->in.sid == NULL) {
7878 : NDR_PULL_ALLOC(ndr, r->in.sid);
7879 : NDR_ZERO_STRUCTP(r->in.sid);
7880 : }
7881 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7882 32 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7883 6 : NDR_PULL_ALLOC(ndr, r->out.acct_handle);
7884 : }
7885 32 : _mem_save_acct_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7886 32 : NDR_PULL_SET_MEM_CTX(ndr, r->out.acct_handle, LIBNDR_FLAG_REF_ALLOC);
7887 32 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.acct_handle));
7888 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_acct_handle_0, LIBNDR_FLAG_REF_ALLOC);
7889 32 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7890 : }
7891 64 : return NDR_ERR_SUCCESS;
7892 : }
7893 :
7894 12 : _PUBLIC_ void ndr_print_lsa_OpenAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_OpenAccount *r)
7895 : {
7896 12 : ndr_print_struct(ndr, name, "lsa_OpenAccount");
7897 12 : if (r == NULL) { ndr_print_null(ndr); return; }
7898 12 : ndr->depth++;
7899 12 : if (flags & NDR_SET_VALUES) {
7900 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7901 : }
7902 12 : if (flags & NDR_IN) {
7903 0 : ndr_print_struct(ndr, "in", "lsa_OpenAccount");
7904 0 : ndr->depth++;
7905 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
7906 0 : ndr->depth++;
7907 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
7908 0 : ndr->depth--;
7909 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
7910 0 : ndr->depth++;
7911 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
7912 0 : ndr->depth--;
7913 0 : ndr_print_lsa_AccountAccessMask(ndr, "access_mask", r->in.access_mask);
7914 0 : ndr->depth--;
7915 : }
7916 12 : if (flags & NDR_OUT) {
7917 12 : ndr_print_struct(ndr, "out", "lsa_OpenAccount");
7918 12 : ndr->depth++;
7919 12 : ndr_print_ptr(ndr, "acct_handle", r->out.acct_handle);
7920 12 : ndr->depth++;
7921 12 : ndr_print_policy_handle(ndr, "acct_handle", r->out.acct_handle);
7922 12 : ndr->depth--;
7923 12 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7924 12 : ndr->depth--;
7925 : }
7926 12 : ndr->depth--;
7927 : }
7928 :
7929 54 : static enum ndr_err_code ndr_push_lsa_EnumPrivsAccount(struct ndr_push *ndr, int flags, const struct lsa_EnumPrivsAccount *r)
7930 : {
7931 54 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7932 54 : if (flags & NDR_IN) {
7933 24 : if (r->in.handle == NULL) {
7934 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7935 : }
7936 24 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7937 : }
7938 54 : if (flags & NDR_OUT) {
7939 30 : if (r->out.privs == NULL) {
7940 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7941 : }
7942 30 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.privs));
7943 30 : if (*r->out.privs) {
7944 30 : NDR_CHECK(ndr_push_lsa_PrivilegeSet(ndr, NDR_SCALARS, *r->out.privs));
7945 : }
7946 30 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7947 : }
7948 54 : return NDR_ERR_SUCCESS;
7949 : }
7950 :
7951 48 : static enum ndr_err_code ndr_pull_lsa_EnumPrivsAccount(struct ndr_pull *ndr, int flags, struct lsa_EnumPrivsAccount *r)
7952 : {
7953 : uint32_t _ptr_privs;
7954 48 : TALLOC_CTX *_mem_save_handle_0 = NULL;
7955 48 : TALLOC_CTX *_mem_save_privs_0 = NULL;
7956 48 : TALLOC_CTX *_mem_save_privs_1 = NULL;
7957 48 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7958 48 : if (flags & NDR_IN) {
7959 24 : NDR_ZERO_STRUCT(r->out);
7960 :
7961 24 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7962 24 : NDR_PULL_ALLOC(ndr, r->in.handle);
7963 : }
7964 24 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7965 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
7966 24 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
7967 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
7968 24 : NDR_PULL_ALLOC(ndr, r->out.privs);
7969 24 : NDR_ZERO_STRUCTP(r->out.privs);
7970 : }
7971 48 : if (flags & NDR_OUT) {
7972 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7973 : if (r->in.handle == NULL) {
7974 : NDR_PULL_ALLOC(ndr, r->in.handle);
7975 : NDR_ZERO_STRUCTP(r->in.handle);
7976 : }
7977 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7978 24 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7979 6 : NDR_PULL_ALLOC(ndr, r->out.privs);
7980 : }
7981 24 : _mem_save_privs_0 = NDR_PULL_GET_MEM_CTX(ndr);
7982 24 : NDR_PULL_SET_MEM_CTX(ndr, r->out.privs, LIBNDR_FLAG_REF_ALLOC);
7983 24 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_privs));
7984 24 : if (_ptr_privs) {
7985 24 : NDR_PULL_ALLOC(ndr, *r->out.privs);
7986 : } else {
7987 0 : *r->out.privs = NULL;
7988 : }
7989 24 : if (*r->out.privs) {
7990 24 : _mem_save_privs_1 = NDR_PULL_GET_MEM_CTX(ndr);
7991 24 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.privs, 0);
7992 24 : NDR_CHECK(ndr_pull_lsa_PrivilegeSet(ndr, NDR_SCALARS, *r->out.privs));
7993 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_1, 0);
7994 : }
7995 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_0, LIBNDR_FLAG_REF_ALLOC);
7996 24 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7997 : }
7998 48 : return NDR_ERR_SUCCESS;
7999 : }
8000 :
8001 12 : _PUBLIC_ void ndr_print_lsa_EnumPrivsAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_EnumPrivsAccount *r)
8002 : {
8003 12 : ndr_print_struct(ndr, name, "lsa_EnumPrivsAccount");
8004 12 : if (r == NULL) { ndr_print_null(ndr); return; }
8005 12 : ndr->depth++;
8006 12 : if (flags & NDR_SET_VALUES) {
8007 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8008 : }
8009 12 : if (flags & NDR_IN) {
8010 0 : ndr_print_struct(ndr, "in", "lsa_EnumPrivsAccount");
8011 0 : ndr->depth++;
8012 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
8013 0 : ndr->depth++;
8014 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
8015 0 : ndr->depth--;
8016 0 : ndr->depth--;
8017 : }
8018 12 : if (flags & NDR_OUT) {
8019 12 : ndr_print_struct(ndr, "out", "lsa_EnumPrivsAccount");
8020 12 : ndr->depth++;
8021 12 : ndr_print_ptr(ndr, "privs", r->out.privs);
8022 12 : ndr->depth++;
8023 12 : ndr_print_ptr(ndr, "privs", *r->out.privs);
8024 12 : ndr->depth++;
8025 12 : if (*r->out.privs) {
8026 12 : ndr_print_lsa_PrivilegeSet(ndr, "privs", *r->out.privs);
8027 : }
8028 12 : ndr->depth--;
8029 12 : ndr->depth--;
8030 12 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8031 12 : ndr->depth--;
8032 : }
8033 12 : ndr->depth--;
8034 : }
8035 :
8036 45 : static enum ndr_err_code ndr_push_lsa_AddPrivilegesToAccount(struct ndr_push *ndr, int flags, const struct lsa_AddPrivilegesToAccount *r)
8037 : {
8038 45 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8039 45 : if (flags & NDR_IN) {
8040 20 : if (r->in.handle == NULL) {
8041 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8042 : }
8043 20 : if (r->in.privs == NULL) {
8044 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8045 : }
8046 20 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8047 20 : NDR_CHECK(ndr_push_lsa_PrivilegeSet(ndr, NDR_SCALARS, r->in.privs));
8048 : }
8049 45 : if (flags & NDR_OUT) {
8050 25 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8051 : }
8052 45 : return NDR_ERR_SUCCESS;
8053 : }
8054 :
8055 40 : static enum ndr_err_code ndr_pull_lsa_AddPrivilegesToAccount(struct ndr_pull *ndr, int flags, struct lsa_AddPrivilegesToAccount *r)
8056 : {
8057 40 : TALLOC_CTX *_mem_save_handle_0 = NULL;
8058 40 : TALLOC_CTX *_mem_save_privs_0 = NULL;
8059 40 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8060 40 : if (flags & NDR_IN) {
8061 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8062 20 : NDR_PULL_ALLOC(ndr, r->in.handle);
8063 : }
8064 20 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8065 20 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
8066 20 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8067 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
8068 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8069 20 : NDR_PULL_ALLOC(ndr, r->in.privs);
8070 : }
8071 20 : _mem_save_privs_0 = NDR_PULL_GET_MEM_CTX(ndr);
8072 20 : NDR_PULL_SET_MEM_CTX(ndr, r->in.privs, LIBNDR_FLAG_REF_ALLOC);
8073 20 : NDR_CHECK(ndr_pull_lsa_PrivilegeSet(ndr, NDR_SCALARS, r->in.privs));
8074 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_0, LIBNDR_FLAG_REF_ALLOC);
8075 : }
8076 40 : if (flags & NDR_OUT) {
8077 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8078 : if (r->in.handle == NULL) {
8079 : NDR_PULL_ALLOC(ndr, r->in.handle);
8080 : NDR_ZERO_STRUCTP(r->in.handle);
8081 : }
8082 : if (r->in.privs == NULL) {
8083 : NDR_PULL_ALLOC(ndr, r->in.privs);
8084 : NDR_ZERO_STRUCTP(r->in.privs);
8085 : }
8086 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8087 20 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8088 : }
8089 40 : return NDR_ERR_SUCCESS;
8090 : }
8091 :
8092 10 : _PUBLIC_ void ndr_print_lsa_AddPrivilegesToAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_AddPrivilegesToAccount *r)
8093 : {
8094 10 : ndr_print_struct(ndr, name, "lsa_AddPrivilegesToAccount");
8095 10 : if (r == NULL) { ndr_print_null(ndr); return; }
8096 10 : ndr->depth++;
8097 10 : if (flags & NDR_SET_VALUES) {
8098 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8099 : }
8100 10 : if (flags & NDR_IN) {
8101 0 : ndr_print_struct(ndr, "in", "lsa_AddPrivilegesToAccount");
8102 0 : ndr->depth++;
8103 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
8104 0 : ndr->depth++;
8105 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
8106 0 : ndr->depth--;
8107 0 : ndr_print_ptr(ndr, "privs", r->in.privs);
8108 0 : ndr->depth++;
8109 0 : ndr_print_lsa_PrivilegeSet(ndr, "privs", r->in.privs);
8110 0 : ndr->depth--;
8111 0 : ndr->depth--;
8112 : }
8113 10 : if (flags & NDR_OUT) {
8114 10 : ndr_print_struct(ndr, "out", "lsa_AddPrivilegesToAccount");
8115 10 : ndr->depth++;
8116 10 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8117 10 : ndr->depth--;
8118 : }
8119 10 : ndr->depth--;
8120 : }
8121 :
8122 45 : static enum ndr_err_code ndr_push_lsa_RemovePrivilegesFromAccount(struct ndr_push *ndr, int flags, const struct lsa_RemovePrivilegesFromAccount *r)
8123 : {
8124 45 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8125 45 : if (flags & NDR_IN) {
8126 20 : if (r->in.handle == NULL) {
8127 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8128 : }
8129 20 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8130 20 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.remove_all));
8131 20 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.privs));
8132 20 : if (r->in.privs) {
8133 20 : NDR_CHECK(ndr_push_lsa_PrivilegeSet(ndr, NDR_SCALARS, r->in.privs));
8134 : }
8135 : }
8136 45 : if (flags & NDR_OUT) {
8137 25 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8138 : }
8139 45 : return NDR_ERR_SUCCESS;
8140 : }
8141 :
8142 40 : static enum ndr_err_code ndr_pull_lsa_RemovePrivilegesFromAccount(struct ndr_pull *ndr, int flags, struct lsa_RemovePrivilegesFromAccount *r)
8143 : {
8144 : uint32_t _ptr_privs;
8145 40 : TALLOC_CTX *_mem_save_handle_0 = NULL;
8146 40 : TALLOC_CTX *_mem_save_privs_0 = NULL;
8147 40 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8148 40 : if (flags & NDR_IN) {
8149 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8150 20 : NDR_PULL_ALLOC(ndr, r->in.handle);
8151 : }
8152 20 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8153 20 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
8154 20 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8155 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
8156 20 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.remove_all));
8157 20 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_privs));
8158 20 : if (_ptr_privs) {
8159 20 : NDR_PULL_ALLOC(ndr, r->in.privs);
8160 : } else {
8161 0 : r->in.privs = NULL;
8162 : }
8163 20 : if (r->in.privs) {
8164 20 : _mem_save_privs_0 = NDR_PULL_GET_MEM_CTX(ndr);
8165 20 : NDR_PULL_SET_MEM_CTX(ndr, r->in.privs, 0);
8166 20 : NDR_CHECK(ndr_pull_lsa_PrivilegeSet(ndr, NDR_SCALARS, r->in.privs));
8167 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_privs_0, 0);
8168 : }
8169 : }
8170 40 : if (flags & NDR_OUT) {
8171 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8172 : if (r->in.handle == NULL) {
8173 : NDR_PULL_ALLOC(ndr, r->in.handle);
8174 : NDR_ZERO_STRUCTP(r->in.handle);
8175 : }
8176 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8177 20 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8178 : }
8179 40 : return NDR_ERR_SUCCESS;
8180 : }
8181 :
8182 10 : _PUBLIC_ void ndr_print_lsa_RemovePrivilegesFromAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_RemovePrivilegesFromAccount *r)
8183 : {
8184 10 : ndr_print_struct(ndr, name, "lsa_RemovePrivilegesFromAccount");
8185 10 : if (r == NULL) { ndr_print_null(ndr); return; }
8186 10 : ndr->depth++;
8187 10 : if (flags & NDR_SET_VALUES) {
8188 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8189 : }
8190 10 : if (flags & NDR_IN) {
8191 0 : ndr_print_struct(ndr, "in", "lsa_RemovePrivilegesFromAccount");
8192 0 : ndr->depth++;
8193 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
8194 0 : ndr->depth++;
8195 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
8196 0 : ndr->depth--;
8197 0 : ndr_print_uint8(ndr, "remove_all", r->in.remove_all);
8198 0 : ndr_print_ptr(ndr, "privs", r->in.privs);
8199 0 : ndr->depth++;
8200 0 : if (r->in.privs) {
8201 0 : ndr_print_lsa_PrivilegeSet(ndr, "privs", r->in.privs);
8202 : }
8203 0 : ndr->depth--;
8204 0 : ndr->depth--;
8205 : }
8206 10 : if (flags & NDR_OUT) {
8207 10 : ndr_print_struct(ndr, "out", "lsa_RemovePrivilegesFromAccount");
8208 10 : ndr->depth++;
8209 10 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8210 10 : ndr->depth--;
8211 : }
8212 10 : ndr->depth--;
8213 : }
8214 :
8215 0 : static enum ndr_err_code ndr_push_lsa_GetQuotasForAccount(struct ndr_push *ndr, int flags, const struct lsa_GetQuotasForAccount *r)
8216 : {
8217 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8218 0 : if (flags & NDR_IN) {
8219 : }
8220 0 : if (flags & NDR_OUT) {
8221 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8222 : }
8223 0 : return NDR_ERR_SUCCESS;
8224 : }
8225 :
8226 0 : static enum ndr_err_code ndr_pull_lsa_GetQuotasForAccount(struct ndr_pull *ndr, int flags, struct lsa_GetQuotasForAccount *r)
8227 : {
8228 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8229 0 : if (flags & NDR_IN) {
8230 : }
8231 0 : if (flags & NDR_OUT) {
8232 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8233 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8234 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8235 : }
8236 0 : return NDR_ERR_SUCCESS;
8237 : }
8238 :
8239 0 : _PUBLIC_ void ndr_print_lsa_GetQuotasForAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_GetQuotasForAccount *r)
8240 : {
8241 0 : ndr_print_struct(ndr, name, "lsa_GetQuotasForAccount");
8242 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8243 0 : ndr->depth++;
8244 0 : if (flags & NDR_SET_VALUES) {
8245 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8246 : }
8247 0 : if (flags & NDR_IN) {
8248 0 : ndr_print_struct(ndr, "in", "lsa_GetQuotasForAccount");
8249 0 : ndr->depth++;
8250 0 : ndr->depth--;
8251 : }
8252 0 : if (flags & NDR_OUT) {
8253 0 : ndr_print_struct(ndr, "out", "lsa_GetQuotasForAccount");
8254 0 : ndr->depth++;
8255 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8256 0 : ndr->depth--;
8257 : }
8258 0 : ndr->depth--;
8259 : }
8260 :
8261 0 : static enum ndr_err_code ndr_push_lsa_SetQuotasForAccount(struct ndr_push *ndr, int flags, const struct lsa_SetQuotasForAccount *r)
8262 : {
8263 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8264 0 : if (flags & NDR_IN) {
8265 : }
8266 0 : if (flags & NDR_OUT) {
8267 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8268 : }
8269 0 : return NDR_ERR_SUCCESS;
8270 : }
8271 :
8272 0 : static enum ndr_err_code ndr_pull_lsa_SetQuotasForAccount(struct ndr_pull *ndr, int flags, struct lsa_SetQuotasForAccount *r)
8273 : {
8274 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8275 0 : if (flags & NDR_IN) {
8276 : }
8277 0 : if (flags & NDR_OUT) {
8278 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8279 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8280 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8281 : }
8282 0 : return NDR_ERR_SUCCESS;
8283 : }
8284 :
8285 0 : _PUBLIC_ void ndr_print_lsa_SetQuotasForAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetQuotasForAccount *r)
8286 : {
8287 0 : ndr_print_struct(ndr, name, "lsa_SetQuotasForAccount");
8288 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8289 0 : ndr->depth++;
8290 0 : if (flags & NDR_SET_VALUES) {
8291 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8292 : }
8293 0 : if (flags & NDR_IN) {
8294 0 : ndr_print_struct(ndr, "in", "lsa_SetQuotasForAccount");
8295 0 : ndr->depth++;
8296 0 : ndr->depth--;
8297 : }
8298 0 : if (flags & NDR_OUT) {
8299 0 : ndr_print_struct(ndr, "out", "lsa_SetQuotasForAccount");
8300 0 : ndr->depth++;
8301 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8302 0 : ndr->depth--;
8303 : }
8304 0 : ndr->depth--;
8305 : }
8306 :
8307 70 : static enum ndr_err_code ndr_push_lsa_GetSystemAccessAccount(struct ndr_push *ndr, int flags, const struct lsa_GetSystemAccessAccount *r)
8308 : {
8309 70 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8310 70 : if (flags & NDR_IN) {
8311 32 : if (r->in.handle == NULL) {
8312 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8313 : }
8314 32 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8315 : }
8316 70 : if (flags & NDR_OUT) {
8317 38 : if (r->out.access_mask == NULL) {
8318 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8319 : }
8320 38 : NDR_CHECK(ndr_push_lsa_AccountAccessMask(ndr, NDR_SCALARS, *r->out.access_mask));
8321 38 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8322 : }
8323 70 : return NDR_ERR_SUCCESS;
8324 : }
8325 :
8326 64 : static enum ndr_err_code ndr_pull_lsa_GetSystemAccessAccount(struct ndr_pull *ndr, int flags, struct lsa_GetSystemAccessAccount *r)
8327 : {
8328 64 : TALLOC_CTX *_mem_save_handle_0 = NULL;
8329 64 : TALLOC_CTX *_mem_save_access_mask_0 = NULL;
8330 64 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8331 64 : if (flags & NDR_IN) {
8332 32 : NDR_ZERO_STRUCT(r->out);
8333 :
8334 32 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8335 32 : NDR_PULL_ALLOC(ndr, r->in.handle);
8336 : }
8337 32 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8338 32 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
8339 32 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8340 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
8341 32 : NDR_PULL_ALLOC(ndr, r->out.access_mask);
8342 32 : NDR_ZERO_STRUCTP(r->out.access_mask);
8343 : }
8344 64 : if (flags & NDR_OUT) {
8345 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8346 : if (r->in.handle == NULL) {
8347 : NDR_PULL_ALLOC(ndr, r->in.handle);
8348 : NDR_ZERO_STRUCTP(r->in.handle);
8349 : }
8350 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8351 32 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8352 6 : NDR_PULL_ALLOC(ndr, r->out.access_mask);
8353 : }
8354 32 : _mem_save_access_mask_0 = NDR_PULL_GET_MEM_CTX(ndr);
8355 32 : NDR_PULL_SET_MEM_CTX(ndr, r->out.access_mask, LIBNDR_FLAG_REF_ALLOC);
8356 32 : NDR_CHECK(ndr_pull_lsa_AccountAccessMask(ndr, NDR_SCALARS, r->out.access_mask));
8357 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_access_mask_0, LIBNDR_FLAG_REF_ALLOC);
8358 32 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8359 : }
8360 64 : return NDR_ERR_SUCCESS;
8361 : }
8362 :
8363 12 : _PUBLIC_ void ndr_print_lsa_GetSystemAccessAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_GetSystemAccessAccount *r)
8364 : {
8365 12 : ndr_print_struct(ndr, name, "lsa_GetSystemAccessAccount");
8366 12 : if (r == NULL) { ndr_print_null(ndr); return; }
8367 12 : ndr->depth++;
8368 12 : if (flags & NDR_SET_VALUES) {
8369 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8370 : }
8371 12 : if (flags & NDR_IN) {
8372 0 : ndr_print_struct(ndr, "in", "lsa_GetSystemAccessAccount");
8373 0 : ndr->depth++;
8374 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
8375 0 : ndr->depth++;
8376 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
8377 0 : ndr->depth--;
8378 0 : ndr->depth--;
8379 : }
8380 12 : if (flags & NDR_OUT) {
8381 12 : ndr_print_struct(ndr, "out", "lsa_GetSystemAccessAccount");
8382 12 : ndr->depth++;
8383 12 : ndr_print_ptr(ndr, "access_mask", r->out.access_mask);
8384 12 : ndr->depth++;
8385 12 : ndr_print_lsa_AccountAccessMask(ndr, "access_mask", *r->out.access_mask);
8386 12 : ndr->depth--;
8387 12 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8388 12 : ndr->depth--;
8389 : }
8390 12 : ndr->depth--;
8391 : }
8392 :
8393 0 : static enum ndr_err_code ndr_push_lsa_SetSystemAccessAccount(struct ndr_push *ndr, int flags, const struct lsa_SetSystemAccessAccount *r)
8394 : {
8395 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8396 0 : if (flags & NDR_IN) {
8397 0 : if (r->in.handle == NULL) {
8398 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8399 : }
8400 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8401 0 : NDR_CHECK(ndr_push_lsa_AccountAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
8402 : }
8403 0 : if (flags & NDR_OUT) {
8404 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8405 : }
8406 0 : return NDR_ERR_SUCCESS;
8407 : }
8408 :
8409 0 : static enum ndr_err_code ndr_pull_lsa_SetSystemAccessAccount(struct ndr_pull *ndr, int flags, struct lsa_SetSystemAccessAccount *r)
8410 : {
8411 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
8412 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8413 0 : if (flags & NDR_IN) {
8414 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8415 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
8416 : }
8417 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8418 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
8419 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8420 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
8421 0 : NDR_CHECK(ndr_pull_lsa_AccountAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
8422 : }
8423 0 : if (flags & NDR_OUT) {
8424 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8425 : if (r->in.handle == NULL) {
8426 : NDR_PULL_ALLOC(ndr, r->in.handle);
8427 : NDR_ZERO_STRUCTP(r->in.handle);
8428 : }
8429 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8430 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8431 : }
8432 0 : return NDR_ERR_SUCCESS;
8433 : }
8434 :
8435 0 : _PUBLIC_ void ndr_print_lsa_SetSystemAccessAccount(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetSystemAccessAccount *r)
8436 : {
8437 0 : ndr_print_struct(ndr, name, "lsa_SetSystemAccessAccount");
8438 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8439 0 : ndr->depth++;
8440 0 : if (flags & NDR_SET_VALUES) {
8441 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8442 : }
8443 0 : if (flags & NDR_IN) {
8444 0 : ndr_print_struct(ndr, "in", "lsa_SetSystemAccessAccount");
8445 0 : ndr->depth++;
8446 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
8447 0 : ndr->depth++;
8448 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
8449 0 : ndr->depth--;
8450 0 : ndr_print_lsa_AccountAccessMask(ndr, "access_mask", r->in.access_mask);
8451 0 : ndr->depth--;
8452 : }
8453 0 : if (flags & NDR_OUT) {
8454 0 : ndr_print_struct(ndr, "out", "lsa_SetSystemAccessAccount");
8455 0 : ndr->depth++;
8456 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8457 0 : ndr->depth--;
8458 : }
8459 0 : ndr->depth--;
8460 : }
8461 :
8462 324 : static enum ndr_err_code ndr_push_lsa_OpenTrustedDomain(struct ndr_push *ndr, int flags, const struct lsa_OpenTrustedDomain *r)
8463 : {
8464 324 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8465 324 : if (flags & NDR_IN) {
8466 144 : if (r->in.handle == NULL) {
8467 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8468 : }
8469 144 : if (r->in.sid == NULL) {
8470 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8471 : }
8472 144 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8473 144 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
8474 144 : NDR_CHECK(ndr_push_lsa_TrustedAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
8475 : }
8476 324 : if (flags & NDR_OUT) {
8477 180 : if (r->out.trustdom_handle == NULL) {
8478 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8479 : }
8480 180 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
8481 180 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8482 : }
8483 324 : return NDR_ERR_SUCCESS;
8484 : }
8485 :
8486 288 : static enum ndr_err_code ndr_pull_lsa_OpenTrustedDomain(struct ndr_pull *ndr, int flags, struct lsa_OpenTrustedDomain *r)
8487 : {
8488 288 : TALLOC_CTX *_mem_save_handle_0 = NULL;
8489 288 : TALLOC_CTX *_mem_save_sid_0 = NULL;
8490 288 : TALLOC_CTX *_mem_save_trustdom_handle_0 = NULL;
8491 288 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8492 288 : if (flags & NDR_IN) {
8493 144 : NDR_ZERO_STRUCT(r->out);
8494 :
8495 144 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8496 144 : NDR_PULL_ALLOC(ndr, r->in.handle);
8497 : }
8498 144 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8499 144 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
8500 144 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8501 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
8502 144 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8503 144 : NDR_PULL_ALLOC(ndr, r->in.sid);
8504 : }
8505 144 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
8506 144 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
8507 144 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
8508 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
8509 144 : NDR_CHECK(ndr_pull_lsa_TrustedAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
8510 144 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
8511 144 : NDR_ZERO_STRUCTP(r->out.trustdom_handle);
8512 : }
8513 288 : if (flags & NDR_OUT) {
8514 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8515 : if (r->in.handle == NULL) {
8516 : NDR_PULL_ALLOC(ndr, r->in.handle);
8517 : NDR_ZERO_STRUCTP(r->in.handle);
8518 : }
8519 : if (r->in.sid == NULL) {
8520 : NDR_PULL_ALLOC(ndr, r->in.sid);
8521 : NDR_ZERO_STRUCTP(r->in.sid);
8522 : }
8523 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8524 144 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8525 36 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
8526 : }
8527 144 : _mem_save_trustdom_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8528 144 : NDR_PULL_SET_MEM_CTX(ndr, r->out.trustdom_handle, LIBNDR_FLAG_REF_ALLOC);
8529 144 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
8530 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trustdom_handle_0, LIBNDR_FLAG_REF_ALLOC);
8531 144 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8532 : }
8533 288 : return NDR_ERR_SUCCESS;
8534 : }
8535 :
8536 72 : _PUBLIC_ void ndr_print_lsa_OpenTrustedDomain(struct ndr_print *ndr, const char *name, int flags, const struct lsa_OpenTrustedDomain *r)
8537 : {
8538 72 : ndr_print_struct(ndr, name, "lsa_OpenTrustedDomain");
8539 72 : if (r == NULL) { ndr_print_null(ndr); return; }
8540 72 : ndr->depth++;
8541 72 : if (flags & NDR_SET_VALUES) {
8542 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8543 : }
8544 72 : if (flags & NDR_IN) {
8545 0 : ndr_print_struct(ndr, "in", "lsa_OpenTrustedDomain");
8546 0 : ndr->depth++;
8547 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
8548 0 : ndr->depth++;
8549 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
8550 0 : ndr->depth--;
8551 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
8552 0 : ndr->depth++;
8553 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
8554 0 : ndr->depth--;
8555 0 : ndr_print_lsa_TrustedAccessMask(ndr, "access_mask", r->in.access_mask);
8556 0 : ndr->depth--;
8557 : }
8558 72 : if (flags & NDR_OUT) {
8559 72 : ndr_print_struct(ndr, "out", "lsa_OpenTrustedDomain");
8560 72 : ndr->depth++;
8561 72 : ndr_print_ptr(ndr, "trustdom_handle", r->out.trustdom_handle);
8562 72 : ndr->depth++;
8563 72 : ndr_print_policy_handle(ndr, "trustdom_handle", r->out.trustdom_handle);
8564 72 : ndr->depth--;
8565 72 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8566 72 : ndr->depth--;
8567 : }
8568 72 : ndr->depth--;
8569 : }
8570 :
8571 8757 : static enum ndr_err_code ndr_push_lsa_QueryTrustedDomainInfo(struct ndr_push *ndr, int flags, const struct lsa_QueryTrustedDomainInfo *r)
8572 : {
8573 8757 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8574 8757 : if (flags & NDR_IN) {
8575 3892 : if (r->in.trustdom_handle == NULL) {
8576 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8577 : }
8578 3892 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.trustdom_handle));
8579 3892 : NDR_CHECK(ndr_push_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, r->in.level));
8580 : }
8581 8757 : if (flags & NDR_OUT) {
8582 4865 : if (r->out.info == NULL) {
8583 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8584 : }
8585 4865 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
8586 4865 : if (*r->out.info) {
8587 2345 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
8588 2345 : NDR_CHECK(ndr_push_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
8589 : }
8590 4865 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8591 : }
8592 8757 : return NDR_ERR_SUCCESS;
8593 : }
8594 :
8595 7784 : static enum ndr_err_code ndr_pull_lsa_QueryTrustedDomainInfo(struct ndr_pull *ndr, int flags, struct lsa_QueryTrustedDomainInfo *r)
8596 : {
8597 : uint32_t _ptr_info;
8598 7784 : TALLOC_CTX *_mem_save_trustdom_handle_0 = NULL;
8599 7784 : TALLOC_CTX *_mem_save_info_0 = NULL;
8600 7784 : TALLOC_CTX *_mem_save_info_1 = NULL;
8601 7784 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8602 7784 : if (flags & NDR_IN) {
8603 3892 : NDR_ZERO_STRUCT(r->out);
8604 :
8605 3892 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8606 3892 : NDR_PULL_ALLOC(ndr, r->in.trustdom_handle);
8607 : }
8608 3892 : _mem_save_trustdom_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8609 3892 : NDR_PULL_SET_MEM_CTX(ndr, r->in.trustdom_handle, LIBNDR_FLAG_REF_ALLOC);
8610 3892 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.trustdom_handle));
8611 3892 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trustdom_handle_0, LIBNDR_FLAG_REF_ALLOC);
8612 3892 : NDR_CHECK(ndr_pull_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, &r->in.level));
8613 3892 : NDR_PULL_ALLOC(ndr, r->out.info);
8614 3892 : NDR_ZERO_STRUCTP(r->out.info);
8615 : }
8616 7784 : if (flags & NDR_OUT) {
8617 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8618 : if (r->in.trustdom_handle == NULL) {
8619 : NDR_PULL_ALLOC(ndr, r->in.trustdom_handle);
8620 : NDR_ZERO_STRUCTP(r->in.trustdom_handle);
8621 : }
8622 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8623 3892 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8624 973 : NDR_PULL_ALLOC(ndr, r->out.info);
8625 : }
8626 3892 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
8627 3892 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
8628 3892 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
8629 3892 : if (_ptr_info) {
8630 1876 : NDR_PULL_ALLOC(ndr, *r->out.info);
8631 : } else {
8632 2016 : *r->out.info = NULL;
8633 : }
8634 3892 : if (*r->out.info) {
8635 1876 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
8636 1876 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
8637 1876 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
8638 1876 : NDR_CHECK(ndr_pull_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
8639 1876 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
8640 : }
8641 3892 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
8642 3892 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8643 : }
8644 7784 : return NDR_ERR_SUCCESS;
8645 : }
8646 :
8647 1946 : _PUBLIC_ void ndr_print_lsa_QueryTrustedDomainInfo(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QueryTrustedDomainInfo *r)
8648 : {
8649 1946 : ndr_print_struct(ndr, name, "lsa_QueryTrustedDomainInfo");
8650 1946 : if (r == NULL) { ndr_print_null(ndr); return; }
8651 1946 : ndr->depth++;
8652 1946 : if (flags & NDR_SET_VALUES) {
8653 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8654 : }
8655 1946 : if (flags & NDR_IN) {
8656 0 : ndr_print_struct(ndr, "in", "lsa_QueryTrustedDomainInfo");
8657 0 : ndr->depth++;
8658 0 : ndr_print_ptr(ndr, "trustdom_handle", r->in.trustdom_handle);
8659 0 : ndr->depth++;
8660 0 : ndr_print_policy_handle(ndr, "trustdom_handle", r->in.trustdom_handle);
8661 0 : ndr->depth--;
8662 0 : ndr_print_lsa_TrustDomInfoEnum(ndr, "level", r->in.level);
8663 0 : ndr->depth--;
8664 : }
8665 1946 : if (flags & NDR_OUT) {
8666 1946 : ndr_print_struct(ndr, "out", "lsa_QueryTrustedDomainInfo");
8667 1946 : ndr->depth++;
8668 1946 : ndr_print_ptr(ndr, "info", r->out.info);
8669 1946 : ndr->depth++;
8670 1946 : ndr_print_ptr(ndr, "info", *r->out.info);
8671 1946 : ndr->depth++;
8672 1946 : if (*r->out.info) {
8673 938 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
8674 938 : ndr_print_lsa_TrustedDomainInfo(ndr, "info", *r->out.info);
8675 : }
8676 1946 : ndr->depth--;
8677 1946 : ndr->depth--;
8678 1946 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8679 1946 : ndr->depth--;
8680 : }
8681 1946 : ndr->depth--;
8682 : }
8683 :
8684 44 : static enum ndr_err_code ndr_push_lsa_SetInformationTrustedDomain(struct ndr_push *ndr, int flags, const struct lsa_SetInformationTrustedDomain *r)
8685 : {
8686 44 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8687 44 : if (flags & NDR_IN) {
8688 22 : if (r->in.trustdom_handle == NULL) {
8689 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8690 : }
8691 22 : if (r->in.info == NULL) {
8692 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8693 : }
8694 22 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.trustdom_handle));
8695 22 : NDR_CHECK(ndr_push_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, r->in.level));
8696 22 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
8697 22 : NDR_CHECK(ndr_push_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
8698 : }
8699 44 : if (flags & NDR_OUT) {
8700 22 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8701 : }
8702 44 : return NDR_ERR_SUCCESS;
8703 : }
8704 :
8705 44 : static enum ndr_err_code ndr_pull_lsa_SetInformationTrustedDomain(struct ndr_pull *ndr, int flags, struct lsa_SetInformationTrustedDomain *r)
8706 : {
8707 44 : TALLOC_CTX *_mem_save_trustdom_handle_0 = NULL;
8708 44 : TALLOC_CTX *_mem_save_info_0 = NULL;
8709 44 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8710 44 : if (flags & NDR_IN) {
8711 22 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8712 22 : NDR_PULL_ALLOC(ndr, r->in.trustdom_handle);
8713 : }
8714 22 : _mem_save_trustdom_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8715 22 : NDR_PULL_SET_MEM_CTX(ndr, r->in.trustdom_handle, LIBNDR_FLAG_REF_ALLOC);
8716 22 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.trustdom_handle));
8717 22 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trustdom_handle_0, LIBNDR_FLAG_REF_ALLOC);
8718 22 : NDR_CHECK(ndr_pull_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, &r->in.level));
8719 22 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8720 22 : NDR_PULL_ALLOC(ndr, r->in.info);
8721 : }
8722 22 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
8723 22 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
8724 22 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
8725 22 : NDR_CHECK(ndr_pull_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
8726 22 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
8727 : }
8728 44 : if (flags & NDR_OUT) {
8729 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8730 : if (r->in.trustdom_handle == NULL) {
8731 : NDR_PULL_ALLOC(ndr, r->in.trustdom_handle);
8732 : NDR_ZERO_STRUCTP(r->in.trustdom_handle);
8733 : }
8734 : if (r->in.info == NULL) {
8735 : NDR_PULL_ALLOC(ndr, r->in.info);
8736 : NDR_ZERO_STRUCTP(r->in.info);
8737 : }
8738 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8739 22 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8740 : }
8741 44 : return NDR_ERR_SUCCESS;
8742 : }
8743 :
8744 0 : _PUBLIC_ void ndr_print_lsa_SetInformationTrustedDomain(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetInformationTrustedDomain *r)
8745 : {
8746 0 : ndr_print_struct(ndr, name, "lsa_SetInformationTrustedDomain");
8747 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8748 0 : ndr->depth++;
8749 0 : if (flags & NDR_SET_VALUES) {
8750 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8751 : }
8752 0 : if (flags & NDR_IN) {
8753 0 : ndr_print_struct(ndr, "in", "lsa_SetInformationTrustedDomain");
8754 0 : ndr->depth++;
8755 0 : ndr_print_ptr(ndr, "trustdom_handle", r->in.trustdom_handle);
8756 0 : ndr->depth++;
8757 0 : ndr_print_policy_handle(ndr, "trustdom_handle", r->in.trustdom_handle);
8758 0 : ndr->depth--;
8759 0 : ndr_print_lsa_TrustDomInfoEnum(ndr, "level", r->in.level);
8760 0 : ndr_print_ptr(ndr, "info", r->in.info);
8761 0 : ndr->depth++;
8762 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
8763 0 : ndr_print_lsa_TrustedDomainInfo(ndr, "info", r->in.info);
8764 0 : ndr->depth--;
8765 0 : ndr->depth--;
8766 : }
8767 0 : if (flags & NDR_OUT) {
8768 0 : ndr_print_struct(ndr, "out", "lsa_SetInformationTrustedDomain");
8769 0 : ndr->depth++;
8770 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8771 0 : ndr->depth--;
8772 : }
8773 0 : ndr->depth--;
8774 : }
8775 :
8776 78 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_OpenSecret(struct ndr_push *ndr, int flags, const struct lsa_OpenSecret *r)
8777 : {
8778 78 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8779 78 : if (flags & NDR_IN) {
8780 35 : if (r->in.handle == NULL) {
8781 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8782 : }
8783 35 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8784 35 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.name));
8785 35 : NDR_CHECK(ndr_push_lsa_SecretAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
8786 : }
8787 78 : if (flags & NDR_OUT) {
8788 43 : if (r->out.sec_handle == NULL) {
8789 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8790 : }
8791 43 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.sec_handle));
8792 43 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8793 : }
8794 78 : return NDR_ERR_SUCCESS;
8795 : }
8796 :
8797 70 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_OpenSecret(struct ndr_pull *ndr, int flags, struct lsa_OpenSecret *r)
8798 : {
8799 70 : TALLOC_CTX *_mem_save_handle_0 = NULL;
8800 70 : TALLOC_CTX *_mem_save_sec_handle_0 = NULL;
8801 70 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8802 70 : if (flags & NDR_IN) {
8803 35 : NDR_ZERO_STRUCT(r->out);
8804 :
8805 35 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8806 35 : NDR_PULL_ALLOC(ndr, r->in.handle);
8807 : }
8808 35 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8809 35 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
8810 35 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
8811 35 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
8812 35 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.name));
8813 35 : NDR_CHECK(ndr_pull_lsa_SecretAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
8814 35 : NDR_PULL_ALLOC(ndr, r->out.sec_handle);
8815 35 : NDR_ZERO_STRUCTP(r->out.sec_handle);
8816 : }
8817 70 : if (flags & NDR_OUT) {
8818 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8819 : if (r->in.handle == NULL) {
8820 : NDR_PULL_ALLOC(ndr, r->in.handle);
8821 : NDR_ZERO_STRUCTP(r->in.handle);
8822 : }
8823 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8824 35 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8825 8 : NDR_PULL_ALLOC(ndr, r->out.sec_handle);
8826 : }
8827 35 : _mem_save_sec_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8828 35 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sec_handle, LIBNDR_FLAG_REF_ALLOC);
8829 35 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.sec_handle));
8830 35 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sec_handle_0, LIBNDR_FLAG_REF_ALLOC);
8831 35 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8832 : }
8833 70 : return NDR_ERR_SUCCESS;
8834 : }
8835 :
8836 16 : _PUBLIC_ void ndr_print_lsa_OpenSecret(struct ndr_print *ndr, const char *name, int flags, const struct lsa_OpenSecret *r)
8837 : {
8838 16 : ndr_print_struct(ndr, name, "lsa_OpenSecret");
8839 16 : if (r == NULL) { ndr_print_null(ndr); return; }
8840 16 : ndr->depth++;
8841 16 : if (flags & NDR_SET_VALUES) {
8842 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8843 : }
8844 16 : if (flags & NDR_IN) {
8845 0 : ndr_print_struct(ndr, "in", "lsa_OpenSecret");
8846 0 : ndr->depth++;
8847 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
8848 0 : ndr->depth++;
8849 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
8850 0 : ndr->depth--;
8851 0 : ndr_print_lsa_String(ndr, "name", &r->in.name);
8852 0 : ndr_print_lsa_SecretAccessMask(ndr, "access_mask", r->in.access_mask);
8853 0 : ndr->depth--;
8854 : }
8855 16 : if (flags & NDR_OUT) {
8856 16 : ndr_print_struct(ndr, "out", "lsa_OpenSecret");
8857 16 : ndr->depth++;
8858 16 : ndr_print_ptr(ndr, "sec_handle", r->out.sec_handle);
8859 16 : ndr->depth++;
8860 16 : ndr_print_policy_handle(ndr, "sec_handle", r->out.sec_handle);
8861 16 : ndr->depth--;
8862 16 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8863 16 : ndr->depth--;
8864 : }
8865 16 : ndr->depth--;
8866 : }
8867 :
8868 4736 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_SetSecret(struct ndr_push *ndr, int flags, const struct lsa_SetSecret *r)
8869 : {
8870 4736 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8871 4736 : if (flags & NDR_IN) {
8872 2360 : if (r->in.sec_handle == NULL) {
8873 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8874 : }
8875 2360 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.sec_handle));
8876 2360 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.new_val));
8877 2360 : if (r->in.new_val) {
8878 2346 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.new_val));
8879 : }
8880 2360 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.old_val));
8881 2360 : if (r->in.old_val) {
8882 14 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.old_val));
8883 : }
8884 : }
8885 4736 : if (flags & NDR_OUT) {
8886 2376 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8887 : }
8888 4736 : return NDR_ERR_SUCCESS;
8889 : }
8890 :
8891 4720 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_SetSecret(struct ndr_pull *ndr, int flags, struct lsa_SetSecret *r)
8892 : {
8893 : uint32_t _ptr_new_val;
8894 : uint32_t _ptr_old_val;
8895 4720 : TALLOC_CTX *_mem_save_sec_handle_0 = NULL;
8896 4720 : TALLOC_CTX *_mem_save_new_val_0 = NULL;
8897 4720 : TALLOC_CTX *_mem_save_old_val_0 = NULL;
8898 4720 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8899 4720 : if (flags & NDR_IN) {
8900 2360 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8901 2360 : NDR_PULL_ALLOC(ndr, r->in.sec_handle);
8902 : }
8903 2360 : _mem_save_sec_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8904 2360 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sec_handle, LIBNDR_FLAG_REF_ALLOC);
8905 2360 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.sec_handle));
8906 2360 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sec_handle_0, LIBNDR_FLAG_REF_ALLOC);
8907 2360 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_new_val));
8908 2360 : if (_ptr_new_val) {
8909 2346 : NDR_PULL_ALLOC(ndr, r->in.new_val);
8910 : } else {
8911 14 : r->in.new_val = NULL;
8912 : }
8913 2360 : if (r->in.new_val) {
8914 2346 : _mem_save_new_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
8915 2346 : NDR_PULL_SET_MEM_CTX(ndr, r->in.new_val, 0);
8916 2346 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.new_val));
8917 2346 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_val_0, 0);
8918 : }
8919 2360 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_val));
8920 2360 : if (_ptr_old_val) {
8921 14 : NDR_PULL_ALLOC(ndr, r->in.old_val);
8922 : } else {
8923 2346 : r->in.old_val = NULL;
8924 : }
8925 2360 : if (r->in.old_val) {
8926 14 : _mem_save_old_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
8927 14 : NDR_PULL_SET_MEM_CTX(ndr, r->in.old_val, 0);
8928 14 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.old_val));
8929 14 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_val_0, 0);
8930 : }
8931 : }
8932 4720 : if (flags & NDR_OUT) {
8933 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8934 : if (r->in.sec_handle == NULL) {
8935 : NDR_PULL_ALLOC(ndr, r->in.sec_handle);
8936 : NDR_ZERO_STRUCTP(r->in.sec_handle);
8937 : }
8938 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8939 2360 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8940 : }
8941 4720 : return NDR_ERR_SUCCESS;
8942 : }
8943 :
8944 32 : _PUBLIC_ void ndr_print_lsa_SetSecret(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetSecret *r)
8945 : {
8946 32 : ndr_print_struct(ndr, name, "lsa_SetSecret");
8947 32 : if (r == NULL) { ndr_print_null(ndr); return; }
8948 32 : ndr->depth++;
8949 32 : if (flags & NDR_SET_VALUES) {
8950 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8951 : }
8952 32 : if (flags & NDR_IN) {
8953 0 : ndr_print_struct(ndr, "in", "lsa_SetSecret");
8954 0 : ndr->depth++;
8955 0 : ndr_print_ptr(ndr, "sec_handle", r->in.sec_handle);
8956 0 : ndr->depth++;
8957 0 : ndr_print_policy_handle(ndr, "sec_handle", r->in.sec_handle);
8958 0 : ndr->depth--;
8959 0 : ndr_print_ptr(ndr, "new_val", r->in.new_val);
8960 0 : ndr->depth++;
8961 0 : if (r->in.new_val) {
8962 0 : ndr_print_lsa_DATA_BUF(ndr, "new_val", r->in.new_val);
8963 : }
8964 0 : ndr->depth--;
8965 0 : ndr_print_ptr(ndr, "old_val", r->in.old_val);
8966 0 : ndr->depth++;
8967 0 : if (r->in.old_val) {
8968 0 : ndr_print_lsa_DATA_BUF(ndr, "old_val", r->in.old_val);
8969 : }
8970 0 : ndr->depth--;
8971 0 : ndr->depth--;
8972 : }
8973 32 : if (flags & NDR_OUT) {
8974 32 : ndr_print_struct(ndr, "out", "lsa_SetSecret");
8975 32 : ndr->depth++;
8976 32 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8977 32 : ndr->depth--;
8978 : }
8979 32 : ndr->depth--;
8980 : }
8981 :
8982 2412 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_QuerySecret(struct ndr_push *ndr, int flags, const struct lsa_QuerySecret *r)
8983 : {
8984 2412 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8985 2412 : if (flags & NDR_IN) {
8986 1200 : if (r->in.sec_handle == NULL) {
8987 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8988 : }
8989 1200 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.sec_handle));
8990 1200 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.new_val));
8991 1200 : if (r->in.new_val) {
8992 1200 : NDR_CHECK(ndr_push_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.new_val));
8993 : }
8994 1200 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.new_mtime));
8995 1200 : if (r->in.new_mtime) {
8996 1194 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, *r->in.new_mtime));
8997 : }
8998 1200 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.old_val));
8999 1200 : if (r->in.old_val) {
9000 28 : NDR_CHECK(ndr_push_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.old_val));
9001 : }
9002 1200 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.old_mtime));
9003 1200 : if (r->in.old_mtime) {
9004 28 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, *r->in.old_mtime));
9005 : }
9006 : }
9007 2412 : if (flags & NDR_OUT) {
9008 1212 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.new_val));
9009 1212 : if (r->out.new_val) {
9010 1212 : NDR_CHECK(ndr_push_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.new_val));
9011 : }
9012 1212 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.new_mtime));
9013 1212 : if (r->out.new_mtime) {
9014 1206 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, *r->out.new_mtime));
9015 : }
9016 1212 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.old_val));
9017 1212 : if (r->out.old_val) {
9018 36 : NDR_CHECK(ndr_push_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.old_val));
9019 : }
9020 1212 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.old_mtime));
9021 1212 : if (r->out.old_mtime) {
9022 36 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, *r->out.old_mtime));
9023 : }
9024 1212 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9025 : }
9026 2412 : return NDR_ERR_SUCCESS;
9027 : }
9028 :
9029 2400 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_QuerySecret(struct ndr_pull *ndr, int flags, struct lsa_QuerySecret *r)
9030 : {
9031 : uint32_t _ptr_new_val;
9032 : uint32_t _ptr_new_mtime;
9033 : uint32_t _ptr_old_val;
9034 : uint32_t _ptr_old_mtime;
9035 2400 : TALLOC_CTX *_mem_save_sec_handle_0 = NULL;
9036 2400 : TALLOC_CTX *_mem_save_new_val_0 = NULL;
9037 2400 : TALLOC_CTX *_mem_save_new_mtime_0 = NULL;
9038 2400 : TALLOC_CTX *_mem_save_old_val_0 = NULL;
9039 2400 : TALLOC_CTX *_mem_save_old_mtime_0 = NULL;
9040 2400 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9041 2400 : if (flags & NDR_IN) {
9042 1200 : NDR_ZERO_STRUCT(r->out);
9043 :
9044 1200 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9045 1200 : NDR_PULL_ALLOC(ndr, r->in.sec_handle);
9046 : }
9047 1200 : _mem_save_sec_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9048 1200 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sec_handle, LIBNDR_FLAG_REF_ALLOC);
9049 1200 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.sec_handle));
9050 1200 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sec_handle_0, LIBNDR_FLAG_REF_ALLOC);
9051 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_new_val));
9052 1200 : if (_ptr_new_val) {
9053 1200 : NDR_PULL_ALLOC(ndr, r->in.new_val);
9054 : } else {
9055 0 : r->in.new_val = NULL;
9056 : }
9057 1200 : if (r->in.new_val) {
9058 1200 : _mem_save_new_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
9059 1200 : NDR_PULL_SET_MEM_CTX(ndr, r->in.new_val, 0);
9060 1200 : NDR_CHECK(ndr_pull_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.new_val));
9061 1200 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_val_0, 0);
9062 : }
9063 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_new_mtime));
9064 1200 : if (_ptr_new_mtime) {
9065 1194 : NDR_PULL_ALLOC(ndr, r->in.new_mtime);
9066 : } else {
9067 6 : r->in.new_mtime = NULL;
9068 : }
9069 1200 : if (r->in.new_mtime) {
9070 1194 : _mem_save_new_mtime_0 = NDR_PULL_GET_MEM_CTX(ndr);
9071 1194 : NDR_PULL_SET_MEM_CTX(ndr, r->in.new_mtime, 0);
9072 1194 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, r->in.new_mtime));
9073 1194 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_mtime_0, 0);
9074 : }
9075 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_val));
9076 1200 : if (_ptr_old_val) {
9077 28 : NDR_PULL_ALLOC(ndr, r->in.old_val);
9078 : } else {
9079 1172 : r->in.old_val = NULL;
9080 : }
9081 1200 : if (r->in.old_val) {
9082 28 : _mem_save_old_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
9083 28 : NDR_PULL_SET_MEM_CTX(ndr, r->in.old_val, 0);
9084 28 : NDR_CHECK(ndr_pull_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.old_val));
9085 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_val_0, 0);
9086 : }
9087 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_mtime));
9088 1200 : if (_ptr_old_mtime) {
9089 28 : NDR_PULL_ALLOC(ndr, r->in.old_mtime);
9090 : } else {
9091 1172 : r->in.old_mtime = NULL;
9092 : }
9093 1200 : if (r->in.old_mtime) {
9094 28 : _mem_save_old_mtime_0 = NDR_PULL_GET_MEM_CTX(ndr);
9095 28 : NDR_PULL_SET_MEM_CTX(ndr, r->in.old_mtime, 0);
9096 28 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, r->in.old_mtime));
9097 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_mtime_0, 0);
9098 : }
9099 : }
9100 2400 : if (flags & NDR_OUT) {
9101 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9102 : if (r->in.sec_handle == NULL) {
9103 : NDR_PULL_ALLOC(ndr, r->in.sec_handle);
9104 : NDR_ZERO_STRUCTP(r->in.sec_handle);
9105 : }
9106 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9107 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_new_val));
9108 1200 : if (_ptr_new_val) {
9109 1200 : NDR_PULL_ALLOC(ndr, r->out.new_val);
9110 : } else {
9111 0 : r->out.new_val = NULL;
9112 : }
9113 1200 : if (r->out.new_val) {
9114 1200 : _mem_save_new_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
9115 1200 : NDR_PULL_SET_MEM_CTX(ndr, r->out.new_val, 0);
9116 1200 : NDR_CHECK(ndr_pull_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.new_val));
9117 1200 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_val_0, 0);
9118 : }
9119 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_new_mtime));
9120 1200 : if (_ptr_new_mtime) {
9121 1194 : NDR_PULL_ALLOC(ndr, r->out.new_mtime);
9122 : } else {
9123 6 : r->out.new_mtime = NULL;
9124 : }
9125 1200 : if (r->out.new_mtime) {
9126 1194 : _mem_save_new_mtime_0 = NDR_PULL_GET_MEM_CTX(ndr);
9127 1194 : NDR_PULL_SET_MEM_CTX(ndr, r->out.new_mtime, 0);
9128 1194 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, r->out.new_mtime));
9129 1194 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_mtime_0, 0);
9130 : }
9131 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_val));
9132 1200 : if (_ptr_old_val) {
9133 28 : NDR_PULL_ALLOC(ndr, r->out.old_val);
9134 : } else {
9135 1172 : r->out.old_val = NULL;
9136 : }
9137 1200 : if (r->out.old_val) {
9138 28 : _mem_save_old_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
9139 28 : NDR_PULL_SET_MEM_CTX(ndr, r->out.old_val, 0);
9140 28 : NDR_CHECK(ndr_pull_lsa_DATA_BUF_PTR(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.old_val));
9141 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_val_0, 0);
9142 : }
9143 1200 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_mtime));
9144 1200 : if (_ptr_old_mtime) {
9145 28 : NDR_PULL_ALLOC(ndr, r->out.old_mtime);
9146 : } else {
9147 1172 : r->out.old_mtime = NULL;
9148 : }
9149 1200 : if (r->out.old_mtime) {
9150 28 : _mem_save_old_mtime_0 = NDR_PULL_GET_MEM_CTX(ndr);
9151 28 : NDR_PULL_SET_MEM_CTX(ndr, r->out.old_mtime, 0);
9152 28 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, r->out.old_mtime));
9153 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_mtime_0, 0);
9154 : }
9155 1200 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9156 : }
9157 2400 : return NDR_ERR_SUCCESS;
9158 : }
9159 :
9160 24 : _PUBLIC_ void ndr_print_lsa_QuerySecret(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QuerySecret *r)
9161 : {
9162 24 : ndr_print_struct(ndr, name, "lsa_QuerySecret");
9163 24 : if (r == NULL) { ndr_print_null(ndr); return; }
9164 24 : ndr->depth++;
9165 24 : if (flags & NDR_SET_VALUES) {
9166 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9167 : }
9168 24 : if (flags & NDR_IN) {
9169 0 : ndr_print_struct(ndr, "in", "lsa_QuerySecret");
9170 0 : ndr->depth++;
9171 0 : ndr_print_ptr(ndr, "sec_handle", r->in.sec_handle);
9172 0 : ndr->depth++;
9173 0 : ndr_print_policy_handle(ndr, "sec_handle", r->in.sec_handle);
9174 0 : ndr->depth--;
9175 0 : ndr_print_ptr(ndr, "new_val", r->in.new_val);
9176 0 : ndr->depth++;
9177 0 : if (r->in.new_val) {
9178 0 : ndr_print_lsa_DATA_BUF_PTR(ndr, "new_val", r->in.new_val);
9179 : }
9180 0 : ndr->depth--;
9181 0 : ndr_print_ptr(ndr, "new_mtime", r->in.new_mtime);
9182 0 : ndr->depth++;
9183 0 : if (r->in.new_mtime) {
9184 0 : ndr_print_NTTIME_hyper(ndr, "new_mtime", *r->in.new_mtime);
9185 : }
9186 0 : ndr->depth--;
9187 0 : ndr_print_ptr(ndr, "old_val", r->in.old_val);
9188 0 : ndr->depth++;
9189 0 : if (r->in.old_val) {
9190 0 : ndr_print_lsa_DATA_BUF_PTR(ndr, "old_val", r->in.old_val);
9191 : }
9192 0 : ndr->depth--;
9193 0 : ndr_print_ptr(ndr, "old_mtime", r->in.old_mtime);
9194 0 : ndr->depth++;
9195 0 : if (r->in.old_mtime) {
9196 0 : ndr_print_NTTIME_hyper(ndr, "old_mtime", *r->in.old_mtime);
9197 : }
9198 0 : ndr->depth--;
9199 0 : ndr->depth--;
9200 : }
9201 24 : if (flags & NDR_OUT) {
9202 24 : ndr_print_struct(ndr, "out", "lsa_QuerySecret");
9203 24 : ndr->depth++;
9204 24 : ndr_print_ptr(ndr, "new_val", r->out.new_val);
9205 24 : ndr->depth++;
9206 24 : if (r->out.new_val) {
9207 24 : ndr_print_lsa_DATA_BUF_PTR(ndr, "new_val", r->out.new_val);
9208 : }
9209 24 : ndr->depth--;
9210 24 : ndr_print_ptr(ndr, "new_mtime", r->out.new_mtime);
9211 24 : ndr->depth++;
9212 24 : if (r->out.new_mtime) {
9213 24 : ndr_print_NTTIME_hyper(ndr, "new_mtime", *r->out.new_mtime);
9214 : }
9215 24 : ndr->depth--;
9216 24 : ndr_print_ptr(ndr, "old_val", r->out.old_val);
9217 24 : ndr->depth++;
9218 24 : if (r->out.old_val) {
9219 16 : ndr_print_lsa_DATA_BUF_PTR(ndr, "old_val", r->out.old_val);
9220 : }
9221 24 : ndr->depth--;
9222 24 : ndr_print_ptr(ndr, "old_mtime", r->out.old_mtime);
9223 24 : ndr->depth++;
9224 24 : if (r->out.old_mtime) {
9225 16 : ndr_print_NTTIME_hyper(ndr, "old_mtime", *r->out.old_mtime);
9226 : }
9227 24 : ndr->depth--;
9228 24 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9229 24 : ndr->depth--;
9230 : }
9231 24 : ndr->depth--;
9232 : }
9233 :
9234 225 : static enum ndr_err_code ndr_push_lsa_LookupPrivValue(struct ndr_push *ndr, int flags, const struct lsa_LookupPrivValue *r)
9235 : {
9236 225 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9237 225 : if (flags & NDR_IN) {
9238 100 : if (r->in.handle == NULL) {
9239 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9240 : }
9241 100 : if (r->in.name == NULL) {
9242 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9243 : }
9244 100 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9245 100 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
9246 : }
9247 225 : if (flags & NDR_OUT) {
9248 125 : if (r->out.luid == NULL) {
9249 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9250 : }
9251 125 : NDR_CHECK(ndr_push_lsa_LUID(ndr, NDR_SCALARS, r->out.luid));
9252 125 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9253 : }
9254 225 : return NDR_ERR_SUCCESS;
9255 : }
9256 :
9257 200 : static enum ndr_err_code ndr_pull_lsa_LookupPrivValue(struct ndr_pull *ndr, int flags, struct lsa_LookupPrivValue *r)
9258 : {
9259 200 : TALLOC_CTX *_mem_save_handle_0 = NULL;
9260 200 : TALLOC_CTX *_mem_save_name_0 = NULL;
9261 200 : TALLOC_CTX *_mem_save_luid_0 = NULL;
9262 200 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9263 200 : if (flags & NDR_IN) {
9264 100 : NDR_ZERO_STRUCT(r->out);
9265 :
9266 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9267 100 : NDR_PULL_ALLOC(ndr, r->in.handle);
9268 : }
9269 100 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9270 100 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
9271 100 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9272 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9273 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9274 100 : NDR_PULL_ALLOC(ndr, r->in.name);
9275 : }
9276 100 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
9277 100 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, LIBNDR_FLAG_REF_ALLOC);
9278 100 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
9279 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
9280 100 : NDR_PULL_ALLOC(ndr, r->out.luid);
9281 100 : NDR_ZERO_STRUCTP(r->out.luid);
9282 : }
9283 200 : if (flags & NDR_OUT) {
9284 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9285 : if (r->in.handle == NULL) {
9286 : NDR_PULL_ALLOC(ndr, r->in.handle);
9287 : NDR_ZERO_STRUCTP(r->in.handle);
9288 : }
9289 : if (r->in.name == NULL) {
9290 : NDR_PULL_ALLOC(ndr, r->in.name);
9291 : NDR_ZERO_STRUCTP(r->in.name);
9292 : }
9293 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9294 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9295 25 : NDR_PULL_ALLOC(ndr, r->out.luid);
9296 : }
9297 100 : _mem_save_luid_0 = NDR_PULL_GET_MEM_CTX(ndr);
9298 100 : NDR_PULL_SET_MEM_CTX(ndr, r->out.luid, LIBNDR_FLAG_REF_ALLOC);
9299 100 : NDR_CHECK(ndr_pull_lsa_LUID(ndr, NDR_SCALARS, r->out.luid));
9300 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_luid_0, LIBNDR_FLAG_REF_ALLOC);
9301 100 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9302 : }
9303 200 : return NDR_ERR_SUCCESS;
9304 : }
9305 :
9306 50 : _PUBLIC_ void ndr_print_lsa_LookupPrivValue(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupPrivValue *r)
9307 : {
9308 50 : ndr_print_struct(ndr, name, "lsa_LookupPrivValue");
9309 50 : if (r == NULL) { ndr_print_null(ndr); return; }
9310 50 : ndr->depth++;
9311 50 : if (flags & NDR_SET_VALUES) {
9312 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9313 : }
9314 50 : if (flags & NDR_IN) {
9315 0 : ndr_print_struct(ndr, "in", "lsa_LookupPrivValue");
9316 0 : ndr->depth++;
9317 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
9318 0 : ndr->depth++;
9319 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
9320 0 : ndr->depth--;
9321 0 : ndr_print_ptr(ndr, "name", r->in.name);
9322 0 : ndr->depth++;
9323 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
9324 0 : ndr->depth--;
9325 0 : ndr->depth--;
9326 : }
9327 50 : if (flags & NDR_OUT) {
9328 50 : ndr_print_struct(ndr, "out", "lsa_LookupPrivValue");
9329 50 : ndr->depth++;
9330 50 : ndr_print_ptr(ndr, "luid", r->out.luid);
9331 50 : ndr->depth++;
9332 50 : ndr_print_lsa_LUID(ndr, "luid", r->out.luid);
9333 50 : ndr->depth--;
9334 50 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9335 50 : ndr->depth--;
9336 : }
9337 50 : ndr->depth--;
9338 : }
9339 :
9340 288 : static enum ndr_err_code ndr_push_lsa_LookupPrivName(struct ndr_push *ndr, int flags, const struct lsa_LookupPrivName *r)
9341 : {
9342 288 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9343 288 : if (flags & NDR_IN) {
9344 128 : if (r->in.handle == NULL) {
9345 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9346 : }
9347 128 : if (r->in.luid == NULL) {
9348 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9349 : }
9350 128 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9351 128 : NDR_CHECK(ndr_push_lsa_LUID(ndr, NDR_SCALARS, r->in.luid));
9352 : }
9353 288 : if (flags & NDR_OUT) {
9354 160 : if (r->out.name == NULL) {
9355 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9356 : }
9357 160 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.name));
9358 160 : if (*r->out.name) {
9359 160 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.name));
9360 : }
9361 160 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9362 : }
9363 288 : return NDR_ERR_SUCCESS;
9364 : }
9365 :
9366 256 : static enum ndr_err_code ndr_pull_lsa_LookupPrivName(struct ndr_pull *ndr, int flags, struct lsa_LookupPrivName *r)
9367 : {
9368 : uint32_t _ptr_name;
9369 256 : TALLOC_CTX *_mem_save_handle_0 = NULL;
9370 256 : TALLOC_CTX *_mem_save_luid_0 = NULL;
9371 256 : TALLOC_CTX *_mem_save_name_0 = NULL;
9372 256 : TALLOC_CTX *_mem_save_name_1 = NULL;
9373 256 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9374 256 : if (flags & NDR_IN) {
9375 128 : NDR_ZERO_STRUCT(r->out);
9376 :
9377 128 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9378 128 : NDR_PULL_ALLOC(ndr, r->in.handle);
9379 : }
9380 128 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9381 128 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
9382 128 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9383 128 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9384 128 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9385 128 : NDR_PULL_ALLOC(ndr, r->in.luid);
9386 : }
9387 128 : _mem_save_luid_0 = NDR_PULL_GET_MEM_CTX(ndr);
9388 128 : NDR_PULL_SET_MEM_CTX(ndr, r->in.luid, LIBNDR_FLAG_REF_ALLOC);
9389 128 : NDR_CHECK(ndr_pull_lsa_LUID(ndr, NDR_SCALARS, r->in.luid));
9390 128 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_luid_0, LIBNDR_FLAG_REF_ALLOC);
9391 128 : NDR_PULL_ALLOC(ndr, r->out.name);
9392 128 : NDR_ZERO_STRUCTP(r->out.name);
9393 : }
9394 256 : if (flags & NDR_OUT) {
9395 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9396 : if (r->in.handle == NULL) {
9397 : NDR_PULL_ALLOC(ndr, r->in.handle);
9398 : NDR_ZERO_STRUCTP(r->in.handle);
9399 : }
9400 : if (r->in.luid == NULL) {
9401 : NDR_PULL_ALLOC(ndr, r->in.luid);
9402 : NDR_ZERO_STRUCTP(r->in.luid);
9403 : }
9404 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9405 128 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9406 32 : NDR_PULL_ALLOC(ndr, r->out.name);
9407 : }
9408 128 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
9409 128 : NDR_PULL_SET_MEM_CTX(ndr, r->out.name, LIBNDR_FLAG_REF_ALLOC);
9410 128 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
9411 128 : if (_ptr_name) {
9412 128 : NDR_PULL_ALLOC(ndr, *r->out.name);
9413 : } else {
9414 0 : *r->out.name = NULL;
9415 : }
9416 128 : if (*r->out.name) {
9417 128 : _mem_save_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
9418 128 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.name, 0);
9419 128 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.name));
9420 128 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_1, 0);
9421 : }
9422 128 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
9423 128 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9424 : }
9425 256 : return NDR_ERR_SUCCESS;
9426 : }
9427 :
9428 64 : _PUBLIC_ void ndr_print_lsa_LookupPrivName(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupPrivName *r)
9429 : {
9430 64 : ndr_print_struct(ndr, name, "lsa_LookupPrivName");
9431 64 : if (r == NULL) { ndr_print_null(ndr); return; }
9432 64 : ndr->depth++;
9433 64 : if (flags & NDR_SET_VALUES) {
9434 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9435 : }
9436 64 : if (flags & NDR_IN) {
9437 0 : ndr_print_struct(ndr, "in", "lsa_LookupPrivName");
9438 0 : ndr->depth++;
9439 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
9440 0 : ndr->depth++;
9441 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
9442 0 : ndr->depth--;
9443 0 : ndr_print_ptr(ndr, "luid", r->in.luid);
9444 0 : ndr->depth++;
9445 0 : ndr_print_lsa_LUID(ndr, "luid", r->in.luid);
9446 0 : ndr->depth--;
9447 0 : ndr->depth--;
9448 : }
9449 64 : if (flags & NDR_OUT) {
9450 64 : ndr_print_struct(ndr, "out", "lsa_LookupPrivName");
9451 64 : ndr->depth++;
9452 64 : ndr_print_ptr(ndr, "name", r->out.name);
9453 64 : ndr->depth++;
9454 64 : ndr_print_ptr(ndr, "name", *r->out.name);
9455 64 : ndr->depth++;
9456 64 : if (*r->out.name) {
9457 64 : ndr_print_lsa_StringLarge(ndr, "name", *r->out.name);
9458 : }
9459 64 : ndr->depth--;
9460 64 : ndr->depth--;
9461 64 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9462 64 : ndr->depth--;
9463 : }
9464 64 : ndr->depth--;
9465 : }
9466 :
9467 225 : static enum ndr_err_code ndr_push_lsa_LookupPrivDisplayName(struct ndr_push *ndr, int flags, const struct lsa_LookupPrivDisplayName *r)
9468 : {
9469 225 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9470 225 : if (flags & NDR_IN) {
9471 100 : if (r->in.handle == NULL) {
9472 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9473 : }
9474 100 : if (r->in.name == NULL) {
9475 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9476 : }
9477 100 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9478 100 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
9479 100 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.language_id));
9480 100 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.language_id_sys));
9481 : }
9482 225 : if (flags & NDR_OUT) {
9483 125 : if (r->out.disp_name == NULL) {
9484 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9485 : }
9486 125 : if (r->out.returned_language_id == NULL) {
9487 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9488 : }
9489 125 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.disp_name));
9490 125 : if (*r->out.disp_name) {
9491 125 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.disp_name));
9492 : }
9493 125 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, *r->out.returned_language_id));
9494 125 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9495 : }
9496 225 : return NDR_ERR_SUCCESS;
9497 : }
9498 :
9499 200 : static enum ndr_err_code ndr_pull_lsa_LookupPrivDisplayName(struct ndr_pull *ndr, int flags, struct lsa_LookupPrivDisplayName *r)
9500 : {
9501 : uint32_t _ptr_disp_name;
9502 200 : TALLOC_CTX *_mem_save_handle_0 = NULL;
9503 200 : TALLOC_CTX *_mem_save_name_0 = NULL;
9504 200 : TALLOC_CTX *_mem_save_disp_name_0 = NULL;
9505 200 : TALLOC_CTX *_mem_save_disp_name_1 = NULL;
9506 200 : TALLOC_CTX *_mem_save_returned_language_id_0 = NULL;
9507 200 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9508 200 : if (flags & NDR_IN) {
9509 100 : NDR_ZERO_STRUCT(r->out);
9510 :
9511 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9512 100 : NDR_PULL_ALLOC(ndr, r->in.handle);
9513 : }
9514 100 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9515 100 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
9516 100 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9517 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9518 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9519 100 : NDR_PULL_ALLOC(ndr, r->in.name);
9520 : }
9521 100 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
9522 100 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, LIBNDR_FLAG_REF_ALLOC);
9523 100 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
9524 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
9525 100 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.language_id));
9526 100 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.language_id_sys));
9527 100 : NDR_PULL_ALLOC(ndr, r->out.disp_name);
9528 100 : NDR_ZERO_STRUCTP(r->out.disp_name);
9529 100 : NDR_PULL_ALLOC(ndr, r->out.returned_language_id);
9530 100 : NDR_ZERO_STRUCTP(r->out.returned_language_id);
9531 : }
9532 200 : if (flags & NDR_OUT) {
9533 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9534 : if (r->in.handle == NULL) {
9535 : NDR_PULL_ALLOC(ndr, r->in.handle);
9536 : NDR_ZERO_STRUCTP(r->in.handle);
9537 : }
9538 : if (r->in.name == NULL) {
9539 : NDR_PULL_ALLOC(ndr, r->in.name);
9540 : NDR_ZERO_STRUCTP(r->in.name);
9541 : }
9542 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9543 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9544 25 : NDR_PULL_ALLOC(ndr, r->out.disp_name);
9545 : }
9546 100 : _mem_save_disp_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
9547 100 : NDR_PULL_SET_MEM_CTX(ndr, r->out.disp_name, LIBNDR_FLAG_REF_ALLOC);
9548 100 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_disp_name));
9549 100 : if (_ptr_disp_name) {
9550 100 : NDR_PULL_ALLOC(ndr, *r->out.disp_name);
9551 : } else {
9552 0 : *r->out.disp_name = NULL;
9553 : }
9554 100 : if (*r->out.disp_name) {
9555 100 : _mem_save_disp_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
9556 100 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.disp_name, 0);
9557 100 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.disp_name));
9558 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_disp_name_1, 0);
9559 : }
9560 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_disp_name_0, LIBNDR_FLAG_REF_ALLOC);
9561 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9562 25 : NDR_PULL_ALLOC(ndr, r->out.returned_language_id);
9563 : }
9564 100 : _mem_save_returned_language_id_0 = NDR_PULL_GET_MEM_CTX(ndr);
9565 100 : NDR_PULL_SET_MEM_CTX(ndr, r->out.returned_language_id, LIBNDR_FLAG_REF_ALLOC);
9566 100 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, r->out.returned_language_id));
9567 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_returned_language_id_0, LIBNDR_FLAG_REF_ALLOC);
9568 100 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9569 : }
9570 200 : return NDR_ERR_SUCCESS;
9571 : }
9572 :
9573 50 : _PUBLIC_ void ndr_print_lsa_LookupPrivDisplayName(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupPrivDisplayName *r)
9574 : {
9575 50 : ndr_print_struct(ndr, name, "lsa_LookupPrivDisplayName");
9576 50 : if (r == NULL) { ndr_print_null(ndr); return; }
9577 50 : ndr->depth++;
9578 50 : if (flags & NDR_SET_VALUES) {
9579 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9580 : }
9581 50 : if (flags & NDR_IN) {
9582 0 : ndr_print_struct(ndr, "in", "lsa_LookupPrivDisplayName");
9583 0 : ndr->depth++;
9584 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
9585 0 : ndr->depth++;
9586 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
9587 0 : ndr->depth--;
9588 0 : ndr_print_ptr(ndr, "name", r->in.name);
9589 0 : ndr->depth++;
9590 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
9591 0 : ndr->depth--;
9592 0 : ndr_print_uint16(ndr, "language_id", r->in.language_id);
9593 0 : ndr_print_uint16(ndr, "language_id_sys", r->in.language_id_sys);
9594 0 : ndr->depth--;
9595 : }
9596 50 : if (flags & NDR_OUT) {
9597 50 : ndr_print_struct(ndr, "out", "lsa_LookupPrivDisplayName");
9598 50 : ndr->depth++;
9599 50 : ndr_print_ptr(ndr, "disp_name", r->out.disp_name);
9600 50 : ndr->depth++;
9601 50 : ndr_print_ptr(ndr, "disp_name", *r->out.disp_name);
9602 50 : ndr->depth++;
9603 50 : if (*r->out.disp_name) {
9604 50 : ndr_print_lsa_StringLarge(ndr, "disp_name", *r->out.disp_name);
9605 : }
9606 50 : ndr->depth--;
9607 50 : ndr->depth--;
9608 50 : ndr_print_ptr(ndr, "returned_language_id", r->out.returned_language_id);
9609 50 : ndr->depth++;
9610 50 : ndr_print_uint16(ndr, "returned_language_id", *r->out.returned_language_id);
9611 50 : ndr->depth--;
9612 50 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9613 50 : ndr->depth--;
9614 : }
9615 50 : ndr->depth--;
9616 : }
9617 :
9618 3345 : static enum ndr_err_code ndr_push_lsa_DeleteObject(struct ndr_push *ndr, int flags, const struct lsa_DeleteObject *r)
9619 : {
9620 3345 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9621 3345 : if (flags & NDR_IN) {
9622 1668 : if (r->in.handle == NULL) {
9623 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9624 : }
9625 1668 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9626 : }
9627 3345 : if (flags & NDR_OUT) {
9628 1677 : if (r->out.handle == NULL) {
9629 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9630 : }
9631 1677 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
9632 1677 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9633 : }
9634 3345 : return NDR_ERR_SUCCESS;
9635 : }
9636 :
9637 3336 : static enum ndr_err_code ndr_pull_lsa_DeleteObject(struct ndr_pull *ndr, int flags, struct lsa_DeleteObject *r)
9638 : {
9639 3336 : TALLOC_CTX *_mem_save_handle_0 = NULL;
9640 3336 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9641 3336 : if (flags & NDR_IN) {
9642 1668 : NDR_ZERO_STRUCT(r->out);
9643 :
9644 1668 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9645 1668 : NDR_PULL_ALLOC(ndr, r->in.handle);
9646 : }
9647 1668 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9648 1668 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
9649 1668 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9650 1668 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9651 1668 : NDR_PULL_ALLOC(ndr, r->out.handle);
9652 1668 : *r->out.handle = *r->in.handle;
9653 : }
9654 3336 : if (flags & NDR_OUT) {
9655 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9656 : if (r->in.handle == NULL) {
9657 : NDR_PULL_ALLOC(ndr, r->in.handle);
9658 : NDR_ZERO_STRUCTP(r->in.handle);
9659 : }
9660 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9661 1668 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9662 9 : NDR_PULL_ALLOC(ndr, r->out.handle);
9663 : }
9664 1668 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9665 1668 : NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
9666 1668 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
9667 1668 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9668 1668 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9669 : }
9670 3336 : return NDR_ERR_SUCCESS;
9671 : }
9672 :
9673 18 : _PUBLIC_ void ndr_print_lsa_DeleteObject(struct ndr_print *ndr, const char *name, int flags, const struct lsa_DeleteObject *r)
9674 : {
9675 18 : ndr_print_struct(ndr, name, "lsa_DeleteObject");
9676 18 : if (r == NULL) { ndr_print_null(ndr); return; }
9677 18 : ndr->depth++;
9678 18 : if (flags & NDR_SET_VALUES) {
9679 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9680 : }
9681 18 : if (flags & NDR_IN) {
9682 0 : ndr_print_struct(ndr, "in", "lsa_DeleteObject");
9683 0 : ndr->depth++;
9684 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
9685 0 : ndr->depth++;
9686 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
9687 0 : ndr->depth--;
9688 0 : ndr->depth--;
9689 : }
9690 18 : if (flags & NDR_OUT) {
9691 18 : ndr_print_struct(ndr, "out", "lsa_DeleteObject");
9692 18 : ndr->depth++;
9693 18 : ndr_print_ptr(ndr, "handle", r->out.handle);
9694 18 : ndr->depth++;
9695 18 : ndr_print_policy_handle(ndr, "handle", r->out.handle);
9696 18 : ndr->depth--;
9697 18 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9698 18 : ndr->depth--;
9699 : }
9700 18 : ndr->depth--;
9701 : }
9702 :
9703 225 : static enum ndr_err_code ndr_push_lsa_EnumAccountsWithUserRight(struct ndr_push *ndr, int flags, const struct lsa_EnumAccountsWithUserRight *r)
9704 : {
9705 225 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9706 225 : if (flags & NDR_IN) {
9707 100 : if (r->in.handle == NULL) {
9708 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9709 : }
9710 100 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9711 100 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.name));
9712 100 : if (r->in.name) {
9713 100 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
9714 : }
9715 : }
9716 225 : if (flags & NDR_OUT) {
9717 125 : if (r->out.sids == NULL) {
9718 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9719 : }
9720 125 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
9721 125 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9722 : }
9723 225 : return NDR_ERR_SUCCESS;
9724 : }
9725 :
9726 200 : static enum ndr_err_code ndr_pull_lsa_EnumAccountsWithUserRight(struct ndr_pull *ndr, int flags, struct lsa_EnumAccountsWithUserRight *r)
9727 : {
9728 : uint32_t _ptr_name;
9729 200 : TALLOC_CTX *_mem_save_handle_0 = NULL;
9730 200 : TALLOC_CTX *_mem_save_name_0 = NULL;
9731 200 : TALLOC_CTX *_mem_save_sids_0 = NULL;
9732 200 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9733 200 : if (flags & NDR_IN) {
9734 100 : NDR_ZERO_STRUCT(r->out);
9735 :
9736 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9737 100 : NDR_PULL_ALLOC(ndr, r->in.handle);
9738 : }
9739 100 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9740 100 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
9741 100 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9742 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9743 100 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
9744 100 : if (_ptr_name) {
9745 100 : NDR_PULL_ALLOC(ndr, r->in.name);
9746 : } else {
9747 0 : r->in.name = NULL;
9748 : }
9749 100 : if (r->in.name) {
9750 100 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
9751 100 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, 0);
9752 100 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
9753 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
9754 : }
9755 100 : NDR_PULL_ALLOC(ndr, r->out.sids);
9756 100 : NDR_ZERO_STRUCTP(r->out.sids);
9757 : }
9758 200 : if (flags & NDR_OUT) {
9759 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9760 : if (r->in.handle == NULL) {
9761 : NDR_PULL_ALLOC(ndr, r->in.handle);
9762 : NDR_ZERO_STRUCTP(r->in.handle);
9763 : }
9764 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9765 100 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9766 25 : NDR_PULL_ALLOC(ndr, r->out.sids);
9767 : }
9768 100 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
9769 100 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
9770 100 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
9771 100 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
9772 100 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9773 : }
9774 200 : return NDR_ERR_SUCCESS;
9775 : }
9776 :
9777 50 : _PUBLIC_ void ndr_print_lsa_EnumAccountsWithUserRight(struct ndr_print *ndr, const char *name, int flags, const struct lsa_EnumAccountsWithUserRight *r)
9778 : {
9779 50 : ndr_print_struct(ndr, name, "lsa_EnumAccountsWithUserRight");
9780 50 : if (r == NULL) { ndr_print_null(ndr); return; }
9781 50 : ndr->depth++;
9782 50 : if (flags & NDR_SET_VALUES) {
9783 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9784 : }
9785 50 : if (flags & NDR_IN) {
9786 0 : ndr_print_struct(ndr, "in", "lsa_EnumAccountsWithUserRight");
9787 0 : ndr->depth++;
9788 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
9789 0 : ndr->depth++;
9790 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
9791 0 : ndr->depth--;
9792 0 : ndr_print_ptr(ndr, "name", r->in.name);
9793 0 : ndr->depth++;
9794 0 : if (r->in.name) {
9795 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
9796 : }
9797 0 : ndr->depth--;
9798 0 : ndr->depth--;
9799 : }
9800 50 : if (flags & NDR_OUT) {
9801 50 : ndr_print_struct(ndr, "out", "lsa_EnumAccountsWithUserRight");
9802 50 : ndr->depth++;
9803 50 : ndr_print_ptr(ndr, "sids", r->out.sids);
9804 50 : ndr->depth++;
9805 50 : ndr_print_lsa_SidArray(ndr, "sids", r->out.sids);
9806 50 : ndr->depth--;
9807 50 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9808 50 : ndr->depth--;
9809 : }
9810 50 : ndr->depth--;
9811 : }
9812 :
9813 86 : static enum ndr_err_code ndr_push_lsa_EnumAccountRights(struct ndr_push *ndr, int flags, const struct lsa_EnumAccountRights *r)
9814 : {
9815 86 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9816 86 : if (flags & NDR_IN) {
9817 40 : if (r->in.handle == NULL) {
9818 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9819 : }
9820 40 : if (r->in.sid == NULL) {
9821 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9822 : }
9823 40 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9824 40 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9825 : }
9826 86 : if (flags & NDR_OUT) {
9827 46 : if (r->out.rights == NULL) {
9828 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9829 : }
9830 46 : NDR_CHECK(ndr_push_lsa_RightSet(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.rights));
9831 46 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9832 : }
9833 86 : return NDR_ERR_SUCCESS;
9834 : }
9835 :
9836 80 : static enum ndr_err_code ndr_pull_lsa_EnumAccountRights(struct ndr_pull *ndr, int flags, struct lsa_EnumAccountRights *r)
9837 : {
9838 80 : TALLOC_CTX *_mem_save_handle_0 = NULL;
9839 80 : TALLOC_CTX *_mem_save_sid_0 = NULL;
9840 80 : TALLOC_CTX *_mem_save_rights_0 = NULL;
9841 80 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9842 80 : if (flags & NDR_IN) {
9843 40 : NDR_ZERO_STRUCT(r->out);
9844 :
9845 40 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9846 40 : NDR_PULL_ALLOC(ndr, r->in.handle);
9847 : }
9848 40 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9849 40 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
9850 40 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9851 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9852 40 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9853 40 : NDR_PULL_ALLOC(ndr, r->in.sid);
9854 : }
9855 40 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
9856 40 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
9857 40 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9858 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
9859 40 : NDR_PULL_ALLOC(ndr, r->out.rights);
9860 40 : NDR_ZERO_STRUCTP(r->out.rights);
9861 : }
9862 80 : if (flags & NDR_OUT) {
9863 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9864 : if (r->in.handle == NULL) {
9865 : NDR_PULL_ALLOC(ndr, r->in.handle);
9866 : NDR_ZERO_STRUCTP(r->in.handle);
9867 : }
9868 : if (r->in.sid == NULL) {
9869 : NDR_PULL_ALLOC(ndr, r->in.sid);
9870 : NDR_ZERO_STRUCTP(r->in.sid);
9871 : }
9872 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9873 40 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9874 6 : NDR_PULL_ALLOC(ndr, r->out.rights);
9875 : }
9876 40 : _mem_save_rights_0 = NDR_PULL_GET_MEM_CTX(ndr);
9877 40 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rights, LIBNDR_FLAG_REF_ALLOC);
9878 40 : NDR_CHECK(ndr_pull_lsa_RightSet(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.rights));
9879 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rights_0, LIBNDR_FLAG_REF_ALLOC);
9880 40 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9881 : }
9882 80 : return NDR_ERR_SUCCESS;
9883 : }
9884 :
9885 12 : _PUBLIC_ void ndr_print_lsa_EnumAccountRights(struct ndr_print *ndr, const char *name, int flags, const struct lsa_EnumAccountRights *r)
9886 : {
9887 12 : ndr_print_struct(ndr, name, "lsa_EnumAccountRights");
9888 12 : if (r == NULL) { ndr_print_null(ndr); return; }
9889 12 : ndr->depth++;
9890 12 : if (flags & NDR_SET_VALUES) {
9891 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9892 : }
9893 12 : if (flags & NDR_IN) {
9894 0 : ndr_print_struct(ndr, "in", "lsa_EnumAccountRights");
9895 0 : ndr->depth++;
9896 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
9897 0 : ndr->depth++;
9898 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
9899 0 : ndr->depth--;
9900 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
9901 0 : ndr->depth++;
9902 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
9903 0 : ndr->depth--;
9904 0 : ndr->depth--;
9905 : }
9906 12 : if (flags & NDR_OUT) {
9907 12 : ndr_print_struct(ndr, "out", "lsa_EnumAccountRights");
9908 12 : ndr->depth++;
9909 12 : ndr_print_ptr(ndr, "rights", r->out.rights);
9910 12 : ndr->depth++;
9911 12 : ndr_print_lsa_RightSet(ndr, "rights", r->out.rights);
9912 12 : ndr->depth--;
9913 12 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9914 12 : ndr->depth--;
9915 : }
9916 12 : ndr->depth--;
9917 : }
9918 :
9919 16 : static enum ndr_err_code ndr_push_lsa_AddAccountRights(struct ndr_push *ndr, int flags, const struct lsa_AddAccountRights *r)
9920 : {
9921 16 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9922 16 : if (flags & NDR_IN) {
9923 8 : if (r->in.handle == NULL) {
9924 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9925 : }
9926 8 : if (r->in.sid == NULL) {
9927 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9928 : }
9929 8 : if (r->in.rights == NULL) {
9930 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9931 : }
9932 8 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9933 8 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9934 8 : NDR_CHECK(ndr_push_lsa_RightSet(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.rights));
9935 : }
9936 16 : if (flags & NDR_OUT) {
9937 8 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9938 : }
9939 16 : return NDR_ERR_SUCCESS;
9940 : }
9941 :
9942 16 : static enum ndr_err_code ndr_pull_lsa_AddAccountRights(struct ndr_pull *ndr, int flags, struct lsa_AddAccountRights *r)
9943 : {
9944 16 : TALLOC_CTX *_mem_save_handle_0 = NULL;
9945 16 : TALLOC_CTX *_mem_save_sid_0 = NULL;
9946 16 : TALLOC_CTX *_mem_save_rights_0 = NULL;
9947 16 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9948 16 : if (flags & NDR_IN) {
9949 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9950 8 : NDR_PULL_ALLOC(ndr, r->in.handle);
9951 : }
9952 8 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9953 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
9954 8 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
9955 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
9956 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9957 8 : NDR_PULL_ALLOC(ndr, r->in.sid);
9958 : }
9959 8 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
9960 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
9961 8 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9962 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
9963 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9964 8 : NDR_PULL_ALLOC(ndr, r->in.rights);
9965 : }
9966 8 : _mem_save_rights_0 = NDR_PULL_GET_MEM_CTX(ndr);
9967 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.rights, LIBNDR_FLAG_REF_ALLOC);
9968 8 : NDR_CHECK(ndr_pull_lsa_RightSet(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.rights));
9969 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rights_0, LIBNDR_FLAG_REF_ALLOC);
9970 : }
9971 16 : if (flags & NDR_OUT) {
9972 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9973 : if (r->in.handle == NULL) {
9974 : NDR_PULL_ALLOC(ndr, r->in.handle);
9975 : NDR_ZERO_STRUCTP(r->in.handle);
9976 : }
9977 : if (r->in.sid == NULL) {
9978 : NDR_PULL_ALLOC(ndr, r->in.sid);
9979 : NDR_ZERO_STRUCTP(r->in.sid);
9980 : }
9981 : if (r->in.rights == NULL) {
9982 : NDR_PULL_ALLOC(ndr, r->in.rights);
9983 : NDR_ZERO_STRUCTP(r->in.rights);
9984 : }
9985 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9986 8 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9987 : }
9988 16 : return NDR_ERR_SUCCESS;
9989 : }
9990 :
9991 0 : _PUBLIC_ void ndr_print_lsa_AddAccountRights(struct ndr_print *ndr, const char *name, int flags, const struct lsa_AddAccountRights *r)
9992 : {
9993 0 : ndr_print_struct(ndr, name, "lsa_AddAccountRights");
9994 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9995 0 : ndr->depth++;
9996 0 : if (flags & NDR_SET_VALUES) {
9997 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9998 : }
9999 0 : if (flags & NDR_IN) {
10000 0 : ndr_print_struct(ndr, "in", "lsa_AddAccountRights");
10001 0 : ndr->depth++;
10002 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
10003 0 : ndr->depth++;
10004 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
10005 0 : ndr->depth--;
10006 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
10007 0 : ndr->depth++;
10008 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
10009 0 : ndr->depth--;
10010 0 : ndr_print_ptr(ndr, "rights", r->in.rights);
10011 0 : ndr->depth++;
10012 0 : ndr_print_lsa_RightSet(ndr, "rights", r->in.rights);
10013 0 : ndr->depth--;
10014 0 : ndr->depth--;
10015 : }
10016 0 : if (flags & NDR_OUT) {
10017 0 : ndr_print_struct(ndr, "out", "lsa_AddAccountRights");
10018 0 : ndr->depth++;
10019 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10020 0 : ndr->depth--;
10021 : }
10022 0 : ndr->depth--;
10023 : }
10024 :
10025 0 : static enum ndr_err_code ndr_push_lsa_RemoveAccountRights(struct ndr_push *ndr, int flags, const struct lsa_RemoveAccountRights *r)
10026 : {
10027 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10028 0 : if (flags & NDR_IN) {
10029 0 : if (r->in.handle == NULL) {
10030 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10031 : }
10032 0 : if (r->in.sid == NULL) {
10033 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10034 : }
10035 0 : if (r->in.rights == NULL) {
10036 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10037 : }
10038 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10039 0 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
10040 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.remove_all));
10041 0 : NDR_CHECK(ndr_push_lsa_RightSet(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.rights));
10042 : }
10043 0 : if (flags & NDR_OUT) {
10044 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10045 : }
10046 0 : return NDR_ERR_SUCCESS;
10047 : }
10048 :
10049 0 : static enum ndr_err_code ndr_pull_lsa_RemoveAccountRights(struct ndr_pull *ndr, int flags, struct lsa_RemoveAccountRights *r)
10050 : {
10051 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
10052 0 : TALLOC_CTX *_mem_save_sid_0 = NULL;
10053 0 : TALLOC_CTX *_mem_save_rights_0 = NULL;
10054 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10055 0 : if (flags & NDR_IN) {
10056 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10057 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
10058 : }
10059 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10060 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
10061 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10062 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
10063 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10064 0 : NDR_PULL_ALLOC(ndr, r->in.sid);
10065 : }
10066 0 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
10067 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
10068 0 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
10069 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
10070 0 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.remove_all));
10071 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10072 0 : NDR_PULL_ALLOC(ndr, r->in.rights);
10073 : }
10074 0 : _mem_save_rights_0 = NDR_PULL_GET_MEM_CTX(ndr);
10075 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.rights, LIBNDR_FLAG_REF_ALLOC);
10076 0 : NDR_CHECK(ndr_pull_lsa_RightSet(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.rights));
10077 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rights_0, LIBNDR_FLAG_REF_ALLOC);
10078 : }
10079 0 : if (flags & NDR_OUT) {
10080 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10081 : if (r->in.handle == NULL) {
10082 : NDR_PULL_ALLOC(ndr, r->in.handle);
10083 : NDR_ZERO_STRUCTP(r->in.handle);
10084 : }
10085 : if (r->in.sid == NULL) {
10086 : NDR_PULL_ALLOC(ndr, r->in.sid);
10087 : NDR_ZERO_STRUCTP(r->in.sid);
10088 : }
10089 : if (r->in.rights == NULL) {
10090 : NDR_PULL_ALLOC(ndr, r->in.rights);
10091 : NDR_ZERO_STRUCTP(r->in.rights);
10092 : }
10093 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10094 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10095 : }
10096 0 : return NDR_ERR_SUCCESS;
10097 : }
10098 :
10099 0 : _PUBLIC_ void ndr_print_lsa_RemoveAccountRights(struct ndr_print *ndr, const char *name, int flags, const struct lsa_RemoveAccountRights *r)
10100 : {
10101 0 : ndr_print_struct(ndr, name, "lsa_RemoveAccountRights");
10102 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10103 0 : ndr->depth++;
10104 0 : if (flags & NDR_SET_VALUES) {
10105 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10106 : }
10107 0 : if (flags & NDR_IN) {
10108 0 : ndr_print_struct(ndr, "in", "lsa_RemoveAccountRights");
10109 0 : ndr->depth++;
10110 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
10111 0 : ndr->depth++;
10112 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
10113 0 : ndr->depth--;
10114 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
10115 0 : ndr->depth++;
10116 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
10117 0 : ndr->depth--;
10118 0 : ndr_print_uint8(ndr, "remove_all", r->in.remove_all);
10119 0 : ndr_print_ptr(ndr, "rights", r->in.rights);
10120 0 : ndr->depth++;
10121 0 : ndr_print_lsa_RightSet(ndr, "rights", r->in.rights);
10122 0 : ndr->depth--;
10123 0 : ndr->depth--;
10124 : }
10125 0 : if (flags & NDR_OUT) {
10126 0 : ndr_print_struct(ndr, "out", "lsa_RemoveAccountRights");
10127 0 : ndr->depth++;
10128 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10129 0 : ndr->depth--;
10130 : }
10131 0 : ndr->depth--;
10132 : }
10133 :
10134 4214 : static enum ndr_err_code ndr_push_lsa_QueryTrustedDomainInfoBySid(struct ndr_push *ndr, int flags, const struct lsa_QueryTrustedDomainInfoBySid *r)
10135 : {
10136 4214 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10137 4214 : if (flags & NDR_IN) {
10138 1873 : if (r->in.handle == NULL) {
10139 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10140 : }
10141 1873 : if (r->in.dom_sid == NULL) {
10142 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10143 : }
10144 1873 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10145 1873 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dom_sid));
10146 1873 : NDR_CHECK(ndr_push_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, r->in.level));
10147 : }
10148 4214 : if (flags & NDR_OUT) {
10149 2341 : if (r->out.info == NULL) {
10150 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10151 : }
10152 2341 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
10153 2341 : if (*r->out.info) {
10154 1080 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
10155 1080 : NDR_CHECK(ndr_push_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
10156 : }
10157 2341 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10158 : }
10159 4214 : return NDR_ERR_SUCCESS;
10160 : }
10161 :
10162 3746 : static enum ndr_err_code ndr_pull_lsa_QueryTrustedDomainInfoBySid(struct ndr_pull *ndr, int flags, struct lsa_QueryTrustedDomainInfoBySid *r)
10163 : {
10164 : uint32_t _ptr_info;
10165 3746 : TALLOC_CTX *_mem_save_handle_0 = NULL;
10166 3746 : TALLOC_CTX *_mem_save_dom_sid_0 = NULL;
10167 3746 : TALLOC_CTX *_mem_save_info_0 = NULL;
10168 3746 : TALLOC_CTX *_mem_save_info_1 = NULL;
10169 3746 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10170 3746 : if (flags & NDR_IN) {
10171 1873 : NDR_ZERO_STRUCT(r->out);
10172 :
10173 1873 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10174 1873 : NDR_PULL_ALLOC(ndr, r->in.handle);
10175 : }
10176 1873 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10177 1873 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
10178 1873 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10179 1873 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
10180 1873 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10181 1873 : NDR_PULL_ALLOC(ndr, r->in.dom_sid);
10182 : }
10183 1873 : _mem_save_dom_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
10184 1873 : NDR_PULL_SET_MEM_CTX(ndr, r->in.dom_sid, LIBNDR_FLAG_REF_ALLOC);
10185 1873 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dom_sid));
10186 1873 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dom_sid_0, LIBNDR_FLAG_REF_ALLOC);
10187 1873 : NDR_CHECK(ndr_pull_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, &r->in.level));
10188 1873 : NDR_PULL_ALLOC(ndr, r->out.info);
10189 1873 : NDR_ZERO_STRUCTP(r->out.info);
10190 : }
10191 3746 : if (flags & NDR_OUT) {
10192 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10193 : if (r->in.handle == NULL) {
10194 : NDR_PULL_ALLOC(ndr, r->in.handle);
10195 : NDR_ZERO_STRUCTP(r->in.handle);
10196 : }
10197 : if (r->in.dom_sid == NULL) {
10198 : NDR_PULL_ALLOC(ndr, r->in.dom_sid);
10199 : NDR_ZERO_STRUCTP(r->in.dom_sid);
10200 : }
10201 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10202 1873 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10203 469 : NDR_PULL_ALLOC(ndr, r->out.info);
10204 : }
10205 1873 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
10206 1873 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
10207 1873 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
10208 1873 : if (_ptr_info) {
10209 864 : NDR_PULL_ALLOC(ndr, *r->out.info);
10210 : } else {
10211 1009 : *r->out.info = NULL;
10212 : }
10213 1873 : if (*r->out.info) {
10214 864 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
10215 864 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
10216 864 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
10217 864 : NDR_CHECK(ndr_pull_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
10218 864 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
10219 : }
10220 1873 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
10221 1873 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10222 : }
10223 3746 : return NDR_ERR_SUCCESS;
10224 : }
10225 :
10226 936 : _PUBLIC_ void ndr_print_lsa_QueryTrustedDomainInfoBySid(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QueryTrustedDomainInfoBySid *r)
10227 : {
10228 936 : ndr_print_struct(ndr, name, "lsa_QueryTrustedDomainInfoBySid");
10229 936 : if (r == NULL) { ndr_print_null(ndr); return; }
10230 936 : ndr->depth++;
10231 936 : if (flags & NDR_SET_VALUES) {
10232 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10233 : }
10234 936 : if (flags & NDR_IN) {
10235 0 : ndr_print_struct(ndr, "in", "lsa_QueryTrustedDomainInfoBySid");
10236 0 : ndr->depth++;
10237 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
10238 0 : ndr->depth++;
10239 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
10240 0 : ndr->depth--;
10241 0 : ndr_print_ptr(ndr, "dom_sid", r->in.dom_sid);
10242 0 : ndr->depth++;
10243 0 : ndr_print_dom_sid2(ndr, "dom_sid", r->in.dom_sid);
10244 0 : ndr->depth--;
10245 0 : ndr_print_lsa_TrustDomInfoEnum(ndr, "level", r->in.level);
10246 0 : ndr->depth--;
10247 : }
10248 936 : if (flags & NDR_OUT) {
10249 936 : ndr_print_struct(ndr, "out", "lsa_QueryTrustedDomainInfoBySid");
10250 936 : ndr->depth++;
10251 936 : ndr_print_ptr(ndr, "info", r->out.info);
10252 936 : ndr->depth++;
10253 936 : ndr_print_ptr(ndr, "info", *r->out.info);
10254 936 : ndr->depth++;
10255 936 : if (*r->out.info) {
10256 432 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
10257 432 : ndr_print_lsa_TrustedDomainInfo(ndr, "info", *r->out.info);
10258 : }
10259 936 : ndr->depth--;
10260 936 : ndr->depth--;
10261 936 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10262 936 : ndr->depth--;
10263 : }
10264 936 : ndr->depth--;
10265 : }
10266 :
10267 0 : static enum ndr_err_code ndr_push_lsa_SetTrustedDomainInfo(struct ndr_push *ndr, int flags, const struct lsa_SetTrustedDomainInfo *r)
10268 : {
10269 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10270 0 : if (flags & NDR_IN) {
10271 0 : if (r->in.handle == NULL) {
10272 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10273 : }
10274 0 : if (r->in.dom_sid == NULL) {
10275 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10276 : }
10277 0 : if (r->in.info == NULL) {
10278 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10279 : }
10280 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10281 0 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dom_sid));
10282 0 : NDR_CHECK(ndr_push_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, r->in.level));
10283 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
10284 0 : NDR_CHECK(ndr_push_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
10285 : }
10286 0 : if (flags & NDR_OUT) {
10287 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10288 : }
10289 0 : return NDR_ERR_SUCCESS;
10290 : }
10291 :
10292 0 : static enum ndr_err_code ndr_pull_lsa_SetTrustedDomainInfo(struct ndr_pull *ndr, int flags, struct lsa_SetTrustedDomainInfo *r)
10293 : {
10294 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
10295 0 : TALLOC_CTX *_mem_save_dom_sid_0 = NULL;
10296 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
10297 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10298 0 : if (flags & NDR_IN) {
10299 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10300 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
10301 : }
10302 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10303 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
10304 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10305 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
10306 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10307 0 : NDR_PULL_ALLOC(ndr, r->in.dom_sid);
10308 : }
10309 0 : _mem_save_dom_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
10310 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.dom_sid, LIBNDR_FLAG_REF_ALLOC);
10311 0 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dom_sid));
10312 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dom_sid_0, LIBNDR_FLAG_REF_ALLOC);
10313 0 : NDR_CHECK(ndr_pull_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, &r->in.level));
10314 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10315 0 : NDR_PULL_ALLOC(ndr, r->in.info);
10316 : }
10317 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
10318 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
10319 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
10320 0 : NDR_CHECK(ndr_pull_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
10321 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
10322 : }
10323 0 : if (flags & NDR_OUT) {
10324 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10325 : if (r->in.handle == NULL) {
10326 : NDR_PULL_ALLOC(ndr, r->in.handle);
10327 : NDR_ZERO_STRUCTP(r->in.handle);
10328 : }
10329 : if (r->in.dom_sid == NULL) {
10330 : NDR_PULL_ALLOC(ndr, r->in.dom_sid);
10331 : NDR_ZERO_STRUCTP(r->in.dom_sid);
10332 : }
10333 : if (r->in.info == NULL) {
10334 : NDR_PULL_ALLOC(ndr, r->in.info);
10335 : NDR_ZERO_STRUCTP(r->in.info);
10336 : }
10337 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10338 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10339 : }
10340 0 : return NDR_ERR_SUCCESS;
10341 : }
10342 :
10343 0 : _PUBLIC_ void ndr_print_lsa_SetTrustedDomainInfo(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetTrustedDomainInfo *r)
10344 : {
10345 0 : ndr_print_struct(ndr, name, "lsa_SetTrustedDomainInfo");
10346 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10347 0 : ndr->depth++;
10348 0 : if (flags & NDR_SET_VALUES) {
10349 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10350 : }
10351 0 : if (flags & NDR_IN) {
10352 0 : ndr_print_struct(ndr, "in", "lsa_SetTrustedDomainInfo");
10353 0 : ndr->depth++;
10354 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
10355 0 : ndr->depth++;
10356 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
10357 0 : ndr->depth--;
10358 0 : ndr_print_ptr(ndr, "dom_sid", r->in.dom_sid);
10359 0 : ndr->depth++;
10360 0 : ndr_print_dom_sid2(ndr, "dom_sid", r->in.dom_sid);
10361 0 : ndr->depth--;
10362 0 : ndr_print_lsa_TrustDomInfoEnum(ndr, "level", r->in.level);
10363 0 : ndr_print_ptr(ndr, "info", r->in.info);
10364 0 : ndr->depth++;
10365 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
10366 0 : ndr_print_lsa_TrustedDomainInfo(ndr, "info", r->in.info);
10367 0 : ndr->depth--;
10368 0 : ndr->depth--;
10369 : }
10370 0 : if (flags & NDR_OUT) {
10371 0 : ndr_print_struct(ndr, "out", "lsa_SetTrustedDomainInfo");
10372 0 : ndr->depth++;
10373 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10374 0 : ndr->depth--;
10375 : }
10376 0 : ndr->depth--;
10377 : }
10378 :
10379 333 : static enum ndr_err_code ndr_push_lsa_DeleteTrustedDomain(struct ndr_push *ndr, int flags, const struct lsa_DeleteTrustedDomain *r)
10380 : {
10381 333 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10382 333 : if (flags & NDR_IN) {
10383 148 : if (r->in.handle == NULL) {
10384 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10385 : }
10386 148 : if (r->in.dom_sid == NULL) {
10387 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10388 : }
10389 148 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10390 148 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dom_sid));
10391 : }
10392 333 : if (flags & NDR_OUT) {
10393 185 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10394 : }
10395 333 : return NDR_ERR_SUCCESS;
10396 : }
10397 :
10398 296 : static enum ndr_err_code ndr_pull_lsa_DeleteTrustedDomain(struct ndr_pull *ndr, int flags, struct lsa_DeleteTrustedDomain *r)
10399 : {
10400 296 : TALLOC_CTX *_mem_save_handle_0 = NULL;
10401 296 : TALLOC_CTX *_mem_save_dom_sid_0 = NULL;
10402 296 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10403 296 : if (flags & NDR_IN) {
10404 148 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10405 148 : NDR_PULL_ALLOC(ndr, r->in.handle);
10406 : }
10407 148 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10408 148 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
10409 148 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10410 148 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
10411 148 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10412 148 : NDR_PULL_ALLOC(ndr, r->in.dom_sid);
10413 : }
10414 148 : _mem_save_dom_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
10415 148 : NDR_PULL_SET_MEM_CTX(ndr, r->in.dom_sid, LIBNDR_FLAG_REF_ALLOC);
10416 148 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dom_sid));
10417 148 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dom_sid_0, LIBNDR_FLAG_REF_ALLOC);
10418 : }
10419 296 : if (flags & NDR_OUT) {
10420 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10421 : if (r->in.handle == NULL) {
10422 : NDR_PULL_ALLOC(ndr, r->in.handle);
10423 : NDR_ZERO_STRUCTP(r->in.handle);
10424 : }
10425 : if (r->in.dom_sid == NULL) {
10426 : NDR_PULL_ALLOC(ndr, r->in.dom_sid);
10427 : NDR_ZERO_STRUCTP(r->in.dom_sid);
10428 : }
10429 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10430 148 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10431 : }
10432 296 : return NDR_ERR_SUCCESS;
10433 : }
10434 :
10435 74 : _PUBLIC_ void ndr_print_lsa_DeleteTrustedDomain(struct ndr_print *ndr, const char *name, int flags, const struct lsa_DeleteTrustedDomain *r)
10436 : {
10437 74 : ndr_print_struct(ndr, name, "lsa_DeleteTrustedDomain");
10438 74 : if (r == NULL) { ndr_print_null(ndr); return; }
10439 74 : ndr->depth++;
10440 74 : if (flags & NDR_SET_VALUES) {
10441 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10442 : }
10443 74 : if (flags & NDR_IN) {
10444 0 : ndr_print_struct(ndr, "in", "lsa_DeleteTrustedDomain");
10445 0 : ndr->depth++;
10446 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
10447 0 : ndr->depth++;
10448 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
10449 0 : ndr->depth--;
10450 0 : ndr_print_ptr(ndr, "dom_sid", r->in.dom_sid);
10451 0 : ndr->depth++;
10452 0 : ndr_print_dom_sid2(ndr, "dom_sid", r->in.dom_sid);
10453 0 : ndr->depth--;
10454 0 : ndr->depth--;
10455 : }
10456 74 : if (flags & NDR_OUT) {
10457 74 : ndr_print_struct(ndr, "out", "lsa_DeleteTrustedDomain");
10458 74 : ndr->depth++;
10459 74 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10460 74 : ndr->depth--;
10461 : }
10462 74 : ndr->depth--;
10463 : }
10464 :
10465 0 : static enum ndr_err_code ndr_push_lsa_StorePrivateData(struct ndr_push *ndr, int flags, const struct lsa_StorePrivateData *r)
10466 : {
10467 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10468 0 : if (flags & NDR_IN) {
10469 0 : if (r->in.handle == NULL) {
10470 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10471 : }
10472 0 : if (r->in.name == NULL) {
10473 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10474 : }
10475 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10476 0 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
10477 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.val));
10478 0 : if (r->in.val) {
10479 0 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.val));
10480 : }
10481 : }
10482 0 : if (flags & NDR_OUT) {
10483 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10484 : }
10485 0 : return NDR_ERR_SUCCESS;
10486 : }
10487 :
10488 0 : static enum ndr_err_code ndr_pull_lsa_StorePrivateData(struct ndr_pull *ndr, int flags, struct lsa_StorePrivateData *r)
10489 : {
10490 : uint32_t _ptr_val;
10491 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
10492 0 : TALLOC_CTX *_mem_save_name_0 = NULL;
10493 0 : TALLOC_CTX *_mem_save_val_0 = NULL;
10494 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10495 0 : if (flags & NDR_IN) {
10496 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10497 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
10498 : }
10499 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10500 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
10501 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10502 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
10503 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10504 0 : NDR_PULL_ALLOC(ndr, r->in.name);
10505 : }
10506 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
10507 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, LIBNDR_FLAG_REF_ALLOC);
10508 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
10509 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
10510 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_val));
10511 0 : if (_ptr_val) {
10512 0 : NDR_PULL_ALLOC(ndr, r->in.val);
10513 : } else {
10514 0 : r->in.val = NULL;
10515 : }
10516 0 : if (r->in.val) {
10517 0 : _mem_save_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
10518 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.val, 0);
10519 0 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.val));
10520 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_val_0, 0);
10521 : }
10522 : }
10523 0 : if (flags & NDR_OUT) {
10524 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10525 : if (r->in.handle == NULL) {
10526 : NDR_PULL_ALLOC(ndr, r->in.handle);
10527 : NDR_ZERO_STRUCTP(r->in.handle);
10528 : }
10529 : if (r->in.name == NULL) {
10530 : NDR_PULL_ALLOC(ndr, r->in.name);
10531 : NDR_ZERO_STRUCTP(r->in.name);
10532 : }
10533 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10534 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10535 : }
10536 0 : return NDR_ERR_SUCCESS;
10537 : }
10538 :
10539 0 : _PUBLIC_ void ndr_print_lsa_StorePrivateData(struct ndr_print *ndr, const char *name, int flags, const struct lsa_StorePrivateData *r)
10540 : {
10541 0 : ndr_print_struct(ndr, name, "lsa_StorePrivateData");
10542 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10543 0 : ndr->depth++;
10544 0 : if (flags & NDR_SET_VALUES) {
10545 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10546 : }
10547 0 : if (flags & NDR_IN) {
10548 0 : ndr_print_struct(ndr, "in", "lsa_StorePrivateData");
10549 0 : ndr->depth++;
10550 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
10551 0 : ndr->depth++;
10552 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
10553 0 : ndr->depth--;
10554 0 : ndr_print_ptr(ndr, "name", r->in.name);
10555 0 : ndr->depth++;
10556 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
10557 0 : ndr->depth--;
10558 0 : ndr_print_ptr(ndr, "val", r->in.val);
10559 0 : ndr->depth++;
10560 0 : if (r->in.val) {
10561 0 : ndr_print_lsa_DATA_BUF(ndr, "val", r->in.val);
10562 : }
10563 0 : ndr->depth--;
10564 0 : ndr->depth--;
10565 : }
10566 0 : if (flags & NDR_OUT) {
10567 0 : ndr_print_struct(ndr, "out", "lsa_StorePrivateData");
10568 0 : ndr->depth++;
10569 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10570 0 : ndr->depth--;
10571 : }
10572 0 : ndr->depth--;
10573 : }
10574 :
10575 0 : static enum ndr_err_code ndr_push_lsa_RetrievePrivateData(struct ndr_push *ndr, int flags, const struct lsa_RetrievePrivateData *r)
10576 : {
10577 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10578 0 : if (flags & NDR_IN) {
10579 0 : if (r->in.handle == NULL) {
10580 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10581 : }
10582 0 : if (r->in.name == NULL) {
10583 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10584 : }
10585 0 : if (r->in.val == NULL) {
10586 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10587 : }
10588 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10589 0 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
10590 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->in.val));
10591 0 : if (*r->in.val) {
10592 0 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, *r->in.val));
10593 : }
10594 : }
10595 0 : if (flags & NDR_OUT) {
10596 0 : if (r->out.val == NULL) {
10597 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10598 : }
10599 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.val));
10600 0 : if (*r->out.val) {
10601 0 : NDR_CHECK(ndr_push_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.val));
10602 : }
10603 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10604 : }
10605 0 : return NDR_ERR_SUCCESS;
10606 : }
10607 :
10608 0 : static enum ndr_err_code ndr_pull_lsa_RetrievePrivateData(struct ndr_pull *ndr, int flags, struct lsa_RetrievePrivateData *r)
10609 : {
10610 : uint32_t _ptr_val;
10611 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
10612 0 : TALLOC_CTX *_mem_save_name_0 = NULL;
10613 0 : TALLOC_CTX *_mem_save_val_0 = NULL;
10614 0 : TALLOC_CTX *_mem_save_val_1 = NULL;
10615 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10616 0 : if (flags & NDR_IN) {
10617 0 : NDR_ZERO_STRUCT(r->out);
10618 :
10619 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10620 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
10621 : }
10622 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10623 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
10624 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
10625 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
10626 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10627 0 : NDR_PULL_ALLOC(ndr, r->in.name);
10628 : }
10629 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
10630 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, LIBNDR_FLAG_REF_ALLOC);
10631 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
10632 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
10633 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10634 0 : NDR_PULL_ALLOC(ndr, r->in.val);
10635 : }
10636 0 : _mem_save_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
10637 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.val, LIBNDR_FLAG_REF_ALLOC);
10638 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_val));
10639 0 : if (_ptr_val) {
10640 0 : NDR_PULL_ALLOC(ndr, *r->in.val);
10641 : } else {
10642 0 : *r->in.val = NULL;
10643 : }
10644 0 : if (*r->in.val) {
10645 0 : _mem_save_val_1 = NDR_PULL_GET_MEM_CTX(ndr);
10646 0 : NDR_PULL_SET_MEM_CTX(ndr, *r->in.val, 0);
10647 0 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, *r->in.val));
10648 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_val_1, 0);
10649 : }
10650 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_val_0, LIBNDR_FLAG_REF_ALLOC);
10651 0 : NDR_PULL_ALLOC(ndr, r->out.val);
10652 0 : *r->out.val = *r->in.val;
10653 : }
10654 0 : if (flags & NDR_OUT) {
10655 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10656 : if (r->in.handle == NULL) {
10657 : NDR_PULL_ALLOC(ndr, r->in.handle);
10658 : NDR_ZERO_STRUCTP(r->in.handle);
10659 : }
10660 : if (r->in.name == NULL) {
10661 : NDR_PULL_ALLOC(ndr, r->in.name);
10662 : NDR_ZERO_STRUCTP(r->in.name);
10663 : }
10664 : if (r->in.val == NULL) {
10665 : NDR_PULL_ALLOC(ndr, r->in.val);
10666 : NDR_ZERO_STRUCTP(r->in.val);
10667 : }
10668 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10669 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10670 0 : NDR_PULL_ALLOC(ndr, r->out.val);
10671 : }
10672 0 : _mem_save_val_0 = NDR_PULL_GET_MEM_CTX(ndr);
10673 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.val, LIBNDR_FLAG_REF_ALLOC);
10674 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_val));
10675 0 : if (_ptr_val) {
10676 0 : NDR_PULL_ALLOC(ndr, *r->out.val);
10677 : } else {
10678 0 : *r->out.val = NULL;
10679 : }
10680 0 : if (*r->out.val) {
10681 0 : _mem_save_val_1 = NDR_PULL_GET_MEM_CTX(ndr);
10682 0 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.val, 0);
10683 0 : NDR_CHECK(ndr_pull_lsa_DATA_BUF(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.val));
10684 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_val_1, 0);
10685 : }
10686 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_val_0, LIBNDR_FLAG_REF_ALLOC);
10687 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10688 : }
10689 0 : return NDR_ERR_SUCCESS;
10690 : }
10691 :
10692 0 : _PUBLIC_ void ndr_print_lsa_RetrievePrivateData(struct ndr_print *ndr, const char *name, int flags, const struct lsa_RetrievePrivateData *r)
10693 : {
10694 0 : ndr_print_struct(ndr, name, "lsa_RetrievePrivateData");
10695 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10696 0 : ndr->depth++;
10697 0 : if (flags & NDR_SET_VALUES) {
10698 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10699 : }
10700 0 : if (flags & NDR_IN) {
10701 0 : ndr_print_struct(ndr, "in", "lsa_RetrievePrivateData");
10702 0 : ndr->depth++;
10703 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
10704 0 : ndr->depth++;
10705 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
10706 0 : ndr->depth--;
10707 0 : ndr_print_ptr(ndr, "name", r->in.name);
10708 0 : ndr->depth++;
10709 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
10710 0 : ndr->depth--;
10711 0 : ndr_print_ptr(ndr, "val", r->in.val);
10712 0 : ndr->depth++;
10713 0 : ndr_print_ptr(ndr, "val", *r->in.val);
10714 0 : ndr->depth++;
10715 0 : if (*r->in.val) {
10716 0 : ndr_print_lsa_DATA_BUF(ndr, "val", *r->in.val);
10717 : }
10718 0 : ndr->depth--;
10719 0 : ndr->depth--;
10720 0 : ndr->depth--;
10721 : }
10722 0 : if (flags & NDR_OUT) {
10723 0 : ndr_print_struct(ndr, "out", "lsa_RetrievePrivateData");
10724 0 : ndr->depth++;
10725 0 : ndr_print_ptr(ndr, "val", r->out.val);
10726 0 : ndr->depth++;
10727 0 : ndr_print_ptr(ndr, "val", *r->out.val);
10728 0 : ndr->depth++;
10729 0 : if (*r->out.val) {
10730 0 : ndr_print_lsa_DATA_BUF(ndr, "val", *r->out.val);
10731 : }
10732 0 : ndr->depth--;
10733 0 : ndr->depth--;
10734 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10735 0 : ndr->depth--;
10736 : }
10737 0 : ndr->depth--;
10738 : }
10739 :
10740 4876 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_OpenPolicy2(struct ndr_push *ndr, int flags, const struct lsa_OpenPolicy2 *r)
10741 : {
10742 4876 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10743 4876 : if (flags & NDR_IN) {
10744 2376 : if (r->in.attr == NULL) {
10745 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10746 : }
10747 2376 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
10748 2376 : if (r->in.system_name) {
10749 2376 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
10750 2376 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
10751 2376 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
10752 2376 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.system_name, ndr_charset_length(r->in.system_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
10753 : }
10754 2376 : NDR_CHECK(ndr_push_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
10755 2376 : NDR_CHECK(ndr_push_lsa_PolicyAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
10756 : }
10757 4876 : if (flags & NDR_OUT) {
10758 2500 : if (r->out.handle == NULL) {
10759 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10760 : }
10761 2500 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
10762 2500 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10763 : }
10764 4876 : return NDR_ERR_SUCCESS;
10765 : }
10766 :
10767 4763 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_OpenPolicy2(struct ndr_pull *ndr, int flags, struct lsa_OpenPolicy2 *r)
10768 : {
10769 : uint32_t _ptr_system_name;
10770 4763 : uint32_t size_system_name_1 = 0;
10771 4763 : uint32_t length_system_name_1 = 0;
10772 4763 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
10773 4763 : TALLOC_CTX *_mem_save_attr_0 = NULL;
10774 4763 : TALLOC_CTX *_mem_save_handle_0 = NULL;
10775 4763 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10776 4763 : if (flags & NDR_IN) {
10777 2408 : NDR_ZERO_STRUCT(r->out);
10778 :
10779 2408 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
10780 2408 : if (_ptr_system_name) {
10781 2408 : NDR_PULL_ALLOC(ndr, r->in.system_name);
10782 : } else {
10783 0 : r->in.system_name = NULL;
10784 : }
10785 2408 : if (r->in.system_name) {
10786 2408 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
10787 2408 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
10788 2408 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.system_name));
10789 2408 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.system_name));
10790 2408 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.system_name, &size_system_name_1));
10791 2408 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.system_name, &length_system_name_1));
10792 2408 : if (length_system_name_1 > size_system_name_1) {
10793 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_system_name_1, length_system_name_1);
10794 : }
10795 2408 : NDR_CHECK(ndr_check_string_terminator(ndr, length_system_name_1, sizeof(uint16_t)));
10796 2408 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.system_name, length_system_name_1, sizeof(uint16_t), CH_UTF16));
10797 2408 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
10798 : }
10799 2408 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10800 2408 : NDR_PULL_ALLOC(ndr, r->in.attr);
10801 : }
10802 2408 : _mem_save_attr_0 = NDR_PULL_GET_MEM_CTX(ndr);
10803 2408 : NDR_PULL_SET_MEM_CTX(ndr, r->in.attr, LIBNDR_FLAG_REF_ALLOC);
10804 2408 : NDR_CHECK(ndr_pull_lsa_ObjectAttribute(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.attr));
10805 2408 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_attr_0, LIBNDR_FLAG_REF_ALLOC);
10806 2408 : NDR_CHECK(ndr_pull_lsa_PolicyAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
10807 2408 : NDR_PULL_ALLOC(ndr, r->out.handle);
10808 2408 : NDR_ZERO_STRUCTP(r->out.handle);
10809 : }
10810 4763 : if (flags & NDR_OUT) {
10811 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10812 : if (r->in.attr == NULL) {
10813 : NDR_PULL_ALLOC(ndr, r->in.attr);
10814 : NDR_ZERO_STRUCTP(r->in.attr);
10815 : }
10816 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10817 2355 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10818 315 : NDR_PULL_ALLOC(ndr, r->out.handle);
10819 : }
10820 2355 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10821 2355 : NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
10822 2355 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
10823 2355 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
10824 2355 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10825 : }
10826 4763 : return NDR_ERR_SUCCESS;
10827 : }
10828 :
10829 196 : _PUBLIC_ void ndr_print_lsa_OpenPolicy2(struct ndr_print *ndr, const char *name, int flags, const struct lsa_OpenPolicy2 *r)
10830 : {
10831 196 : ndr_print_struct(ndr, name, "lsa_OpenPolicy2");
10832 196 : if (r == NULL) { ndr_print_null(ndr); return; }
10833 196 : ndr->depth++;
10834 196 : if (flags & NDR_SET_VALUES) {
10835 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10836 : }
10837 196 : if (flags & NDR_IN) {
10838 0 : ndr_print_struct(ndr, "in", "lsa_OpenPolicy2");
10839 0 : ndr->depth++;
10840 0 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
10841 0 : ndr->depth++;
10842 0 : if (r->in.system_name) {
10843 0 : ndr_print_string(ndr, "system_name", r->in.system_name);
10844 : }
10845 0 : ndr->depth--;
10846 0 : ndr_print_ptr(ndr, "attr", r->in.attr);
10847 0 : ndr->depth++;
10848 0 : ndr_print_lsa_ObjectAttribute(ndr, "attr", r->in.attr);
10849 0 : ndr->depth--;
10850 0 : ndr_print_lsa_PolicyAccessMask(ndr, "access_mask", r->in.access_mask);
10851 0 : ndr->depth--;
10852 : }
10853 196 : if (flags & NDR_OUT) {
10854 196 : ndr_print_struct(ndr, "out", "lsa_OpenPolicy2");
10855 196 : ndr->depth++;
10856 196 : ndr_print_ptr(ndr, "handle", r->out.handle);
10857 196 : ndr->depth++;
10858 196 : ndr_print_policy_handle(ndr, "handle", r->out.handle);
10859 196 : ndr->depth--;
10860 196 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10861 196 : ndr->depth--;
10862 : }
10863 196 : ndr->depth--;
10864 : }
10865 :
10866 934 : static enum ndr_err_code ndr_push_lsa_GetUserName(struct ndr_push *ndr, int flags, const struct lsa_GetUserName *r)
10867 : {
10868 934 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10869 934 : if (flags & NDR_IN) {
10870 552 : if (r->in.account_name == NULL) {
10871 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10872 : }
10873 552 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
10874 552 : if (r->in.system_name) {
10875 540 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
10876 540 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
10877 540 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
10878 540 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.system_name, ndr_charset_length(r->in.system_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
10879 : }
10880 552 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->in.account_name));
10881 552 : if (*r->in.account_name) {
10882 0 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->in.account_name));
10883 : }
10884 552 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.authority_name));
10885 552 : if (r->in.authority_name) {
10886 520 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->in.authority_name));
10887 520 : if (*r->in.authority_name) {
10888 0 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->in.authority_name));
10889 : }
10890 : }
10891 : }
10892 934 : if (flags & NDR_OUT) {
10893 382 : if (r->out.account_name == NULL) {
10894 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10895 : }
10896 382 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.account_name));
10897 382 : if (*r->out.account_name) {
10898 382 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.account_name));
10899 : }
10900 382 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->out.authority_name));
10901 382 : if (r->out.authority_name) {
10902 356 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.authority_name));
10903 356 : if (*r->out.authority_name) {
10904 356 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.authority_name));
10905 : }
10906 : }
10907 382 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10908 : }
10909 934 : return NDR_ERR_SUCCESS;
10910 : }
10911 :
10912 885 : static enum ndr_err_code ndr_pull_lsa_GetUserName(struct ndr_pull *ndr, int flags, struct lsa_GetUserName *r)
10913 : {
10914 : uint32_t _ptr_system_name;
10915 885 : uint32_t size_system_name_1 = 0;
10916 885 : uint32_t length_system_name_1 = 0;
10917 : uint32_t _ptr_account_name;
10918 : uint32_t _ptr_authority_name;
10919 885 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
10920 885 : TALLOC_CTX *_mem_save_account_name_0 = NULL;
10921 885 : TALLOC_CTX *_mem_save_account_name_1 = NULL;
10922 885 : TALLOC_CTX *_mem_save_authority_name_0 = NULL;
10923 885 : TALLOC_CTX *_mem_save_authority_name_1 = NULL;
10924 885 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10925 885 : if (flags & NDR_IN) {
10926 341 : NDR_ZERO_STRUCT(r->out);
10927 :
10928 341 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
10929 341 : if (_ptr_system_name) {
10930 335 : NDR_PULL_ALLOC(ndr, r->in.system_name);
10931 : } else {
10932 6 : r->in.system_name = NULL;
10933 : }
10934 341 : if (r->in.system_name) {
10935 335 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
10936 335 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
10937 335 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.system_name));
10938 335 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.system_name));
10939 335 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.system_name, &size_system_name_1));
10940 335 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.system_name, &length_system_name_1));
10941 335 : if (length_system_name_1 > size_system_name_1) {
10942 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_system_name_1, length_system_name_1);
10943 : }
10944 335 : NDR_CHECK(ndr_check_string_terminator(ndr, length_system_name_1, sizeof(uint16_t)));
10945 335 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.system_name, length_system_name_1, sizeof(uint16_t), CH_UTF16));
10946 335 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
10947 : }
10948 341 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10949 341 : NDR_PULL_ALLOC(ndr, r->in.account_name);
10950 : }
10951 341 : _mem_save_account_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
10952 341 : NDR_PULL_SET_MEM_CTX(ndr, r->in.account_name, LIBNDR_FLAG_REF_ALLOC);
10953 341 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_account_name));
10954 341 : if (_ptr_account_name) {
10955 0 : NDR_PULL_ALLOC(ndr, *r->in.account_name);
10956 : } else {
10957 341 : *r->in.account_name = NULL;
10958 : }
10959 341 : if (*r->in.account_name) {
10960 0 : _mem_save_account_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
10961 0 : NDR_PULL_SET_MEM_CTX(ndr, *r->in.account_name, 0);
10962 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->in.account_name));
10963 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_name_1, 0);
10964 : }
10965 341 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_name_0, LIBNDR_FLAG_REF_ALLOC);
10966 341 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_authority_name));
10967 341 : if (_ptr_authority_name) {
10968 315 : NDR_PULL_ALLOC(ndr, r->in.authority_name);
10969 : } else {
10970 26 : r->in.authority_name = NULL;
10971 : }
10972 341 : if (r->in.authority_name) {
10973 315 : _mem_save_authority_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
10974 315 : NDR_PULL_SET_MEM_CTX(ndr, r->in.authority_name, 0);
10975 315 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_authority_name));
10976 315 : if (_ptr_authority_name) {
10977 0 : NDR_PULL_ALLOC(ndr, *r->in.authority_name);
10978 : } else {
10979 315 : *r->in.authority_name = NULL;
10980 : }
10981 315 : if (*r->in.authority_name) {
10982 0 : _mem_save_authority_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
10983 0 : NDR_PULL_SET_MEM_CTX(ndr, *r->in.authority_name, 0);
10984 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->in.authority_name));
10985 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_authority_name_1, 0);
10986 : }
10987 315 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_authority_name_0, 0);
10988 : }
10989 341 : NDR_PULL_ALLOC(ndr, r->out.account_name);
10990 341 : *r->out.account_name = *r->in.account_name;
10991 : }
10992 885 : if (flags & NDR_OUT) {
10993 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10994 : if (r->in.account_name == NULL) {
10995 : NDR_PULL_ALLOC(ndr, r->in.account_name);
10996 : NDR_ZERO_STRUCTP(r->in.account_name);
10997 : }
10998 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10999 544 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11000 409 : NDR_PULL_ALLOC(ndr, r->out.account_name);
11001 : }
11002 544 : _mem_save_account_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
11003 544 : NDR_PULL_SET_MEM_CTX(ndr, r->out.account_name, LIBNDR_FLAG_REF_ALLOC);
11004 544 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_account_name));
11005 544 : if (_ptr_account_name) {
11006 544 : NDR_PULL_ALLOC(ndr, *r->out.account_name);
11007 : } else {
11008 0 : *r->out.account_name = NULL;
11009 : }
11010 544 : if (*r->out.account_name) {
11011 544 : _mem_save_account_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
11012 544 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.account_name, 0);
11013 544 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.account_name));
11014 544 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_name_1, 0);
11015 : }
11016 544 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_name_0, LIBNDR_FLAG_REF_ALLOC);
11017 544 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_authority_name));
11018 544 : if (_ptr_authority_name) {
11019 516 : NDR_PULL_ALLOC(ndr, r->out.authority_name);
11020 : } else {
11021 28 : r->out.authority_name = NULL;
11022 : }
11023 544 : if (r->out.authority_name) {
11024 516 : _mem_save_authority_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
11025 516 : NDR_PULL_SET_MEM_CTX(ndr, r->out.authority_name, 0);
11026 516 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_authority_name));
11027 516 : if (_ptr_authority_name) {
11028 516 : NDR_PULL_ALLOC(ndr, *r->out.authority_name);
11029 : } else {
11030 0 : *r->out.authority_name = NULL;
11031 : }
11032 516 : if (*r->out.authority_name) {
11033 516 : _mem_save_authority_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
11034 516 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.authority_name, 0);
11035 516 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.authority_name));
11036 516 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_authority_name_1, 0);
11037 : }
11038 516 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_authority_name_0, 0);
11039 : }
11040 544 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11041 : }
11042 885 : return NDR_ERR_SUCCESS;
11043 : }
11044 :
11045 90 : _PUBLIC_ void ndr_print_lsa_GetUserName(struct ndr_print *ndr, const char *name, int flags, const struct lsa_GetUserName *r)
11046 : {
11047 90 : ndr_print_struct(ndr, name, "lsa_GetUserName");
11048 90 : if (r == NULL) { ndr_print_null(ndr); return; }
11049 90 : ndr->depth++;
11050 90 : if (flags & NDR_SET_VALUES) {
11051 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11052 : }
11053 90 : if (flags & NDR_IN) {
11054 0 : ndr_print_struct(ndr, "in", "lsa_GetUserName");
11055 0 : ndr->depth++;
11056 0 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
11057 0 : ndr->depth++;
11058 0 : if (r->in.system_name) {
11059 0 : ndr_print_string(ndr, "system_name", r->in.system_name);
11060 : }
11061 0 : ndr->depth--;
11062 0 : ndr_print_ptr(ndr, "account_name", r->in.account_name);
11063 0 : ndr->depth++;
11064 0 : ndr_print_ptr(ndr, "account_name", *r->in.account_name);
11065 0 : ndr->depth++;
11066 0 : if (*r->in.account_name) {
11067 0 : ndr_print_lsa_String(ndr, "account_name", *r->in.account_name);
11068 : }
11069 0 : ndr->depth--;
11070 0 : ndr->depth--;
11071 0 : ndr_print_ptr(ndr, "authority_name", r->in.authority_name);
11072 0 : ndr->depth++;
11073 0 : if (r->in.authority_name) {
11074 0 : ndr_print_ptr(ndr, "authority_name", *r->in.authority_name);
11075 0 : ndr->depth++;
11076 0 : if (*r->in.authority_name) {
11077 0 : ndr_print_lsa_String(ndr, "authority_name", *r->in.authority_name);
11078 : }
11079 0 : ndr->depth--;
11080 : }
11081 0 : ndr->depth--;
11082 0 : ndr->depth--;
11083 : }
11084 90 : if (flags & NDR_OUT) {
11085 90 : ndr_print_struct(ndr, "out", "lsa_GetUserName");
11086 90 : ndr->depth++;
11087 90 : ndr_print_ptr(ndr, "account_name", r->out.account_name);
11088 90 : ndr->depth++;
11089 90 : ndr_print_ptr(ndr, "account_name", *r->out.account_name);
11090 90 : ndr->depth++;
11091 90 : if (*r->out.account_name) {
11092 90 : ndr_print_lsa_String(ndr, "account_name", *r->out.account_name);
11093 : }
11094 90 : ndr->depth--;
11095 90 : ndr->depth--;
11096 90 : ndr_print_ptr(ndr, "authority_name", r->out.authority_name);
11097 90 : ndr->depth++;
11098 90 : if (r->out.authority_name) {
11099 82 : ndr_print_ptr(ndr, "authority_name", *r->out.authority_name);
11100 82 : ndr->depth++;
11101 82 : if (*r->out.authority_name) {
11102 82 : ndr_print_lsa_String(ndr, "authority_name", *r->out.authority_name);
11103 : }
11104 82 : ndr->depth--;
11105 : }
11106 90 : ndr->depth--;
11107 90 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11108 90 : ndr->depth--;
11109 : }
11110 90 : ndr->depth--;
11111 : }
11112 :
11113 1521 : static enum ndr_err_code ndr_push_lsa_QueryInfoPolicy2(struct ndr_push *ndr, int flags, const struct lsa_QueryInfoPolicy2 *r)
11114 : {
11115 1521 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11116 1521 : if (flags & NDR_IN) {
11117 697 : if (r->in.handle == NULL) {
11118 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11119 : }
11120 697 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11121 697 : NDR_CHECK(ndr_push_lsa_PolicyInfo(ndr, NDR_SCALARS, r->in.level));
11122 : }
11123 1521 : if (flags & NDR_OUT) {
11124 824 : if (r->out.info == NULL) {
11125 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11126 : }
11127 824 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
11128 824 : if (*r->out.info) {
11129 794 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
11130 794 : NDR_CHECK(ndr_push_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11131 : }
11132 824 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11133 : }
11134 1521 : return NDR_ERR_SUCCESS;
11135 : }
11136 :
11137 1439 : static enum ndr_err_code ndr_pull_lsa_QueryInfoPolicy2(struct ndr_pull *ndr, int flags, struct lsa_QueryInfoPolicy2 *r)
11138 : {
11139 : uint32_t _ptr_info;
11140 1439 : TALLOC_CTX *_mem_save_handle_0 = NULL;
11141 1439 : TALLOC_CTX *_mem_save_info_0 = NULL;
11142 1439 : TALLOC_CTX *_mem_save_info_1 = NULL;
11143 1439 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11144 1439 : if (flags & NDR_IN) {
11145 744 : NDR_ZERO_STRUCT(r->out);
11146 :
11147 744 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11148 744 : NDR_PULL_ALLOC(ndr, r->in.handle);
11149 : }
11150 744 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11151 744 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
11152 744 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11153 744 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11154 744 : NDR_CHECK(ndr_pull_lsa_PolicyInfo(ndr, NDR_SCALARS, &r->in.level));
11155 744 : NDR_PULL_ALLOC(ndr, r->out.info);
11156 744 : NDR_ZERO_STRUCTP(r->out.info);
11157 : }
11158 1439 : if (flags & NDR_OUT) {
11159 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11160 : if (r->in.handle == NULL) {
11161 : NDR_PULL_ALLOC(ndr, r->in.handle);
11162 : NDR_ZERO_STRUCTP(r->in.handle);
11163 : }
11164 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11165 695 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11166 336 : NDR_PULL_ALLOC(ndr, r->out.info);
11167 : }
11168 695 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11169 695 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
11170 695 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
11171 695 : if (_ptr_info) {
11172 671 : NDR_PULL_ALLOC(ndr, *r->out.info);
11173 : } else {
11174 24 : *r->out.info = NULL;
11175 : }
11176 695 : if (*r->out.info) {
11177 671 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
11178 671 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
11179 671 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
11180 671 : NDR_CHECK(ndr_pull_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11181 671 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
11182 : }
11183 695 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11184 695 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11185 : }
11186 1439 : return NDR_ERR_SUCCESS;
11187 : }
11188 :
11189 194 : _PUBLIC_ void ndr_print_lsa_QueryInfoPolicy2(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QueryInfoPolicy2 *r)
11190 : {
11191 194 : ndr_print_struct(ndr, name, "lsa_QueryInfoPolicy2");
11192 194 : if (r == NULL) { ndr_print_null(ndr); return; }
11193 194 : ndr->depth++;
11194 194 : if (flags & NDR_SET_VALUES) {
11195 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11196 : }
11197 194 : if (flags & NDR_IN) {
11198 0 : ndr_print_struct(ndr, "in", "lsa_QueryInfoPolicy2");
11199 0 : ndr->depth++;
11200 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
11201 0 : ndr->depth++;
11202 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
11203 0 : ndr->depth--;
11204 0 : ndr_print_lsa_PolicyInfo(ndr, "level", r->in.level);
11205 0 : ndr->depth--;
11206 : }
11207 194 : if (flags & NDR_OUT) {
11208 194 : ndr_print_struct(ndr, "out", "lsa_QueryInfoPolicy2");
11209 194 : ndr->depth++;
11210 194 : ndr_print_ptr(ndr, "info", r->out.info);
11211 194 : ndr->depth++;
11212 194 : ndr_print_ptr(ndr, "info", *r->out.info);
11213 194 : ndr->depth++;
11214 194 : if (*r->out.info) {
11215 182 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
11216 182 : ndr_print_lsa_PolicyInformation(ndr, "info", *r->out.info);
11217 : }
11218 194 : ndr->depth--;
11219 194 : ndr->depth--;
11220 194 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11221 194 : ndr->depth--;
11222 : }
11223 194 : ndr->depth--;
11224 : }
11225 :
11226 0 : static enum ndr_err_code ndr_push_lsa_SetInfoPolicy2(struct ndr_push *ndr, int flags, const struct lsa_SetInfoPolicy2 *r)
11227 : {
11228 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11229 0 : if (flags & NDR_IN) {
11230 0 : if (r->in.handle == NULL) {
11231 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11232 : }
11233 0 : if (r->in.info == NULL) {
11234 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11235 : }
11236 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11237 0 : NDR_CHECK(ndr_push_lsa_PolicyInfo(ndr, NDR_SCALARS, r->in.level));
11238 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
11239 0 : NDR_CHECK(ndr_push_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
11240 : }
11241 0 : if (flags & NDR_OUT) {
11242 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11243 : }
11244 0 : return NDR_ERR_SUCCESS;
11245 : }
11246 :
11247 0 : static enum ndr_err_code ndr_pull_lsa_SetInfoPolicy2(struct ndr_pull *ndr, int flags, struct lsa_SetInfoPolicy2 *r)
11248 : {
11249 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
11250 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
11251 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11252 0 : if (flags & NDR_IN) {
11253 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11254 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
11255 : }
11256 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11257 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
11258 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11259 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11260 0 : NDR_CHECK(ndr_pull_lsa_PolicyInfo(ndr, NDR_SCALARS, &r->in.level));
11261 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11262 0 : NDR_PULL_ALLOC(ndr, r->in.info);
11263 : }
11264 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11265 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
11266 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
11267 0 : NDR_CHECK(ndr_pull_lsa_PolicyInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
11268 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11269 : }
11270 0 : if (flags & NDR_OUT) {
11271 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11272 : if (r->in.handle == NULL) {
11273 : NDR_PULL_ALLOC(ndr, r->in.handle);
11274 : NDR_ZERO_STRUCTP(r->in.handle);
11275 : }
11276 : if (r->in.info == NULL) {
11277 : NDR_PULL_ALLOC(ndr, r->in.info);
11278 : NDR_ZERO_STRUCTP(r->in.info);
11279 : }
11280 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11281 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11282 : }
11283 0 : return NDR_ERR_SUCCESS;
11284 : }
11285 :
11286 0 : _PUBLIC_ void ndr_print_lsa_SetInfoPolicy2(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetInfoPolicy2 *r)
11287 : {
11288 0 : ndr_print_struct(ndr, name, "lsa_SetInfoPolicy2");
11289 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11290 0 : ndr->depth++;
11291 0 : if (flags & NDR_SET_VALUES) {
11292 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11293 : }
11294 0 : if (flags & NDR_IN) {
11295 0 : ndr_print_struct(ndr, "in", "lsa_SetInfoPolicy2");
11296 0 : ndr->depth++;
11297 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
11298 0 : ndr->depth++;
11299 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
11300 0 : ndr->depth--;
11301 0 : ndr_print_lsa_PolicyInfo(ndr, "level", r->in.level);
11302 0 : ndr_print_ptr(ndr, "info", r->in.info);
11303 0 : ndr->depth++;
11304 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
11305 0 : ndr_print_lsa_PolicyInformation(ndr, "info", r->in.info);
11306 0 : ndr->depth--;
11307 0 : ndr->depth--;
11308 : }
11309 0 : if (flags & NDR_OUT) {
11310 0 : ndr_print_struct(ndr, "out", "lsa_SetInfoPolicy2");
11311 0 : ndr->depth++;
11312 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11313 0 : ndr->depth--;
11314 : }
11315 0 : ndr->depth--;
11316 : }
11317 :
11318 4733 : static enum ndr_err_code ndr_push_lsa_QueryTrustedDomainInfoByName(struct ndr_push *ndr, int flags, const struct lsa_QueryTrustedDomainInfoByName *r)
11319 : {
11320 4733 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11321 4733 : if (flags & NDR_IN) {
11322 2092 : if (r->in.handle == NULL) {
11323 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11324 : }
11325 2092 : if (r->in.trusted_domain == NULL) {
11326 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11327 : }
11328 2092 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11329 2092 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain));
11330 2092 : NDR_CHECK(ndr_push_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, r->in.level));
11331 : }
11332 4733 : if (flags & NDR_OUT) {
11333 2641 : if (r->out.info == NULL) {
11334 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11335 : }
11336 2641 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
11337 2641 : if (*r->out.info) {
11338 1327 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
11339 1327 : NDR_CHECK(ndr_push_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11340 : }
11341 2641 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11342 : }
11343 4733 : return NDR_ERR_SUCCESS;
11344 : }
11345 :
11346 4257 : static enum ndr_err_code ndr_pull_lsa_QueryTrustedDomainInfoByName(struct ndr_pull *ndr, int flags, struct lsa_QueryTrustedDomainInfoByName *r)
11347 : {
11348 : uint32_t _ptr_info;
11349 4257 : TALLOC_CTX *_mem_save_handle_0 = NULL;
11350 4257 : TALLOC_CTX *_mem_save_trusted_domain_0 = NULL;
11351 4257 : TALLOC_CTX *_mem_save_info_0 = NULL;
11352 4257 : TALLOC_CTX *_mem_save_info_1 = NULL;
11353 4257 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11354 4257 : if (flags & NDR_IN) {
11355 2165 : NDR_ZERO_STRUCT(r->out);
11356 :
11357 2165 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11358 2165 : NDR_PULL_ALLOC(ndr, r->in.handle);
11359 : }
11360 2165 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11361 2165 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
11362 2165 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11363 2165 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11364 2165 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11365 2165 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain);
11366 : }
11367 2165 : _mem_save_trusted_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
11368 2165 : NDR_PULL_SET_MEM_CTX(ndr, r->in.trusted_domain, LIBNDR_FLAG_REF_ALLOC);
11369 2165 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain));
11370 2165 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trusted_domain_0, LIBNDR_FLAG_REF_ALLOC);
11371 2165 : NDR_CHECK(ndr_pull_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, &r->in.level));
11372 2165 : NDR_PULL_ALLOC(ndr, r->out.info);
11373 2165 : NDR_ZERO_STRUCTP(r->out.info);
11374 : }
11375 4257 : if (flags & NDR_OUT) {
11376 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11377 : if (r->in.handle == NULL) {
11378 : NDR_PULL_ALLOC(ndr, r->in.handle);
11379 : NDR_ZERO_STRUCTP(r->in.handle);
11380 : }
11381 : if (r->in.trusted_domain == NULL) {
11382 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain);
11383 : NDR_ZERO_STRUCTP(r->in.trusted_domain);
11384 : }
11385 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11386 2092 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11387 664 : NDR_PULL_ALLOC(ndr, r->out.info);
11388 : }
11389 2092 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11390 2092 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
11391 2092 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
11392 2092 : if (_ptr_info) {
11393 1032 : NDR_PULL_ALLOC(ndr, *r->out.info);
11394 : } else {
11395 1060 : *r->out.info = NULL;
11396 : }
11397 2092 : if (*r->out.info) {
11398 1032 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
11399 1032 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
11400 1032 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
11401 1032 : NDR_CHECK(ndr_pull_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11402 1032 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
11403 : }
11404 2092 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11405 2092 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11406 : }
11407 4257 : return NDR_ERR_SUCCESS;
11408 : }
11409 :
11410 952 : _PUBLIC_ void ndr_print_lsa_QueryTrustedDomainInfoByName(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QueryTrustedDomainInfoByName *r)
11411 : {
11412 952 : ndr_print_struct(ndr, name, "lsa_QueryTrustedDomainInfoByName");
11413 952 : if (r == NULL) { ndr_print_null(ndr); return; }
11414 952 : ndr->depth++;
11415 952 : if (flags & NDR_SET_VALUES) {
11416 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11417 : }
11418 952 : if (flags & NDR_IN) {
11419 0 : ndr_print_struct(ndr, "in", "lsa_QueryTrustedDomainInfoByName");
11420 0 : ndr->depth++;
11421 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
11422 0 : ndr->depth++;
11423 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
11424 0 : ndr->depth--;
11425 0 : ndr_print_ptr(ndr, "trusted_domain", r->in.trusted_domain);
11426 0 : ndr->depth++;
11427 0 : ndr_print_lsa_String(ndr, "trusted_domain", r->in.trusted_domain);
11428 0 : ndr->depth--;
11429 0 : ndr_print_lsa_TrustDomInfoEnum(ndr, "level", r->in.level);
11430 0 : ndr->depth--;
11431 : }
11432 952 : if (flags & NDR_OUT) {
11433 952 : ndr_print_struct(ndr, "out", "lsa_QueryTrustedDomainInfoByName");
11434 952 : ndr->depth++;
11435 952 : ndr_print_ptr(ndr, "info", r->out.info);
11436 952 : ndr->depth++;
11437 952 : ndr_print_ptr(ndr, "info", *r->out.info);
11438 952 : ndr->depth++;
11439 952 : if (*r->out.info) {
11440 444 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
11441 444 : ndr_print_lsa_TrustedDomainInfo(ndr, "info", *r->out.info);
11442 : }
11443 952 : ndr->depth--;
11444 952 : ndr->depth--;
11445 952 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11446 952 : ndr->depth--;
11447 : }
11448 952 : ndr->depth--;
11449 : }
11450 :
11451 54 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_SetTrustedDomainInfoByName(struct ndr_push *ndr, int flags, const struct lsa_SetTrustedDomainInfoByName *r)
11452 : {
11453 54 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11454 54 : if (flags & NDR_IN) {
11455 24 : if (r->in.handle == NULL) {
11456 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11457 : }
11458 24 : if (r->in.trusted_domain == NULL) {
11459 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11460 : }
11461 24 : if (r->in.info == NULL) {
11462 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11463 : }
11464 24 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11465 24 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain));
11466 24 : NDR_CHECK(ndr_push_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, r->in.level));
11467 24 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
11468 24 : NDR_CHECK(ndr_push_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
11469 : }
11470 54 : if (flags & NDR_OUT) {
11471 30 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11472 : }
11473 54 : return NDR_ERR_SUCCESS;
11474 : }
11475 :
11476 48 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_SetTrustedDomainInfoByName(struct ndr_pull *ndr, int flags, struct lsa_SetTrustedDomainInfoByName *r)
11477 : {
11478 48 : TALLOC_CTX *_mem_save_handle_0 = NULL;
11479 48 : TALLOC_CTX *_mem_save_trusted_domain_0 = NULL;
11480 48 : TALLOC_CTX *_mem_save_info_0 = NULL;
11481 48 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11482 48 : if (flags & NDR_IN) {
11483 24 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11484 24 : NDR_PULL_ALLOC(ndr, r->in.handle);
11485 : }
11486 24 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11487 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
11488 24 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11489 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11490 24 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11491 24 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain);
11492 : }
11493 24 : _mem_save_trusted_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
11494 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.trusted_domain, LIBNDR_FLAG_REF_ALLOC);
11495 24 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain));
11496 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trusted_domain_0, LIBNDR_FLAG_REF_ALLOC);
11497 24 : NDR_CHECK(ndr_pull_lsa_TrustDomInfoEnum(ndr, NDR_SCALARS, &r->in.level));
11498 24 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11499 24 : NDR_PULL_ALLOC(ndr, r->in.info);
11500 : }
11501 24 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11502 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
11503 24 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
11504 24 : NDR_CHECK(ndr_pull_lsa_TrustedDomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
11505 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11506 : }
11507 48 : if (flags & NDR_OUT) {
11508 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11509 : if (r->in.handle == NULL) {
11510 : NDR_PULL_ALLOC(ndr, r->in.handle);
11511 : NDR_ZERO_STRUCTP(r->in.handle);
11512 : }
11513 : if (r->in.trusted_domain == NULL) {
11514 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain);
11515 : NDR_ZERO_STRUCTP(r->in.trusted_domain);
11516 : }
11517 : if (r->in.info == NULL) {
11518 : NDR_PULL_ALLOC(ndr, r->in.info);
11519 : NDR_ZERO_STRUCTP(r->in.info);
11520 : }
11521 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11522 24 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11523 : }
11524 48 : return NDR_ERR_SUCCESS;
11525 : }
11526 :
11527 12 : _PUBLIC_ void ndr_print_lsa_SetTrustedDomainInfoByName(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetTrustedDomainInfoByName *r)
11528 : {
11529 12 : ndr_print_struct(ndr, name, "lsa_SetTrustedDomainInfoByName");
11530 12 : if (r == NULL) { ndr_print_null(ndr); return; }
11531 12 : ndr->depth++;
11532 12 : if (flags & NDR_SET_VALUES) {
11533 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11534 : }
11535 12 : if (flags & NDR_IN) {
11536 0 : ndr_print_struct(ndr, "in", "lsa_SetTrustedDomainInfoByName");
11537 0 : ndr->depth++;
11538 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
11539 0 : ndr->depth++;
11540 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
11541 0 : ndr->depth--;
11542 0 : ndr_print_ptr(ndr, "trusted_domain", r->in.trusted_domain);
11543 0 : ndr->depth++;
11544 0 : ndr_print_lsa_String(ndr, "trusted_domain", r->in.trusted_domain);
11545 0 : ndr->depth--;
11546 0 : ndr_print_lsa_TrustDomInfoEnum(ndr, "level", r->in.level);
11547 0 : ndr_print_ptr(ndr, "info", r->in.info);
11548 0 : ndr->depth++;
11549 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
11550 0 : ndr_print_lsa_TrustedDomainInfo(ndr, "info", r->in.info);
11551 0 : ndr->depth--;
11552 0 : ndr->depth--;
11553 : }
11554 12 : if (flags & NDR_OUT) {
11555 12 : ndr_print_struct(ndr, "out", "lsa_SetTrustedDomainInfoByName");
11556 12 : ndr->depth++;
11557 12 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11558 12 : ndr->depth--;
11559 : }
11560 12 : ndr->depth--;
11561 : }
11562 :
11563 126 : static enum ndr_err_code ndr_push_lsa_EnumTrustedDomainsEx(struct ndr_push *ndr, int flags, const struct lsa_EnumTrustedDomainsEx *r)
11564 : {
11565 126 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11566 126 : if (flags & NDR_IN) {
11567 56 : if (r->in.handle == NULL) {
11568 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11569 : }
11570 56 : if (r->in.resume_handle == NULL) {
11571 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11572 : }
11573 56 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11574 56 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
11575 56 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_size));
11576 : }
11577 126 : if (flags & NDR_OUT) {
11578 70 : if (r->out.resume_handle == NULL) {
11579 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11580 : }
11581 70 : if (r->out.domains == NULL) {
11582 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11583 : }
11584 70 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
11585 70 : NDR_CHECK(ndr_push_lsa_DomainListEx(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
11586 70 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11587 : }
11588 126 : return NDR_ERR_SUCCESS;
11589 : }
11590 :
11591 112 : static enum ndr_err_code ndr_pull_lsa_EnumTrustedDomainsEx(struct ndr_pull *ndr, int flags, struct lsa_EnumTrustedDomainsEx *r)
11592 : {
11593 112 : TALLOC_CTX *_mem_save_handle_0 = NULL;
11594 112 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
11595 112 : TALLOC_CTX *_mem_save_domains_0 = NULL;
11596 112 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11597 112 : if (flags & NDR_IN) {
11598 56 : NDR_ZERO_STRUCT(r->out);
11599 :
11600 56 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11601 56 : NDR_PULL_ALLOC(ndr, r->in.handle);
11602 : }
11603 56 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11604 56 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
11605 56 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11606 56 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11607 56 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11608 56 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
11609 : }
11610 56 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11611 56 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
11612 56 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
11613 56 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
11614 56 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_size));
11615 56 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
11616 56 : *r->out.resume_handle = *r->in.resume_handle;
11617 56 : NDR_PULL_ALLOC(ndr, r->out.domains);
11618 56 : NDR_ZERO_STRUCTP(r->out.domains);
11619 : }
11620 112 : if (flags & NDR_OUT) {
11621 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11622 : if (r->in.handle == NULL) {
11623 : NDR_PULL_ALLOC(ndr, r->in.handle);
11624 : NDR_ZERO_STRUCTP(r->in.handle);
11625 : }
11626 : if (r->in.resume_handle == NULL) {
11627 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
11628 : NDR_ZERO_STRUCTP(r->in.resume_handle);
11629 : }
11630 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11631 56 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11632 14 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
11633 : }
11634 56 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11635 56 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
11636 56 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
11637 56 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
11638 56 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11639 14 : NDR_PULL_ALLOC(ndr, r->out.domains);
11640 : }
11641 56 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
11642 56 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
11643 56 : NDR_CHECK(ndr_pull_lsa_DomainListEx(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
11644 56 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
11645 56 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11646 : }
11647 112 : return NDR_ERR_SUCCESS;
11648 : }
11649 :
11650 28 : _PUBLIC_ void ndr_print_lsa_EnumTrustedDomainsEx(struct ndr_print *ndr, const char *name, int flags, const struct lsa_EnumTrustedDomainsEx *r)
11651 : {
11652 28 : ndr_print_struct(ndr, name, "lsa_EnumTrustedDomainsEx");
11653 28 : if (r == NULL) { ndr_print_null(ndr); return; }
11654 28 : ndr->depth++;
11655 28 : if (flags & NDR_SET_VALUES) {
11656 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11657 : }
11658 28 : if (flags & NDR_IN) {
11659 0 : ndr_print_struct(ndr, "in", "lsa_EnumTrustedDomainsEx");
11660 0 : ndr->depth++;
11661 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
11662 0 : ndr->depth++;
11663 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
11664 0 : ndr->depth--;
11665 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
11666 0 : ndr->depth++;
11667 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
11668 0 : ndr->depth--;
11669 0 : ndr_print_uint32(ndr, "max_size", r->in.max_size);
11670 0 : ndr->depth--;
11671 : }
11672 28 : if (flags & NDR_OUT) {
11673 28 : ndr_print_struct(ndr, "out", "lsa_EnumTrustedDomainsEx");
11674 28 : ndr->depth++;
11675 28 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
11676 28 : ndr->depth++;
11677 28 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
11678 28 : ndr->depth--;
11679 28 : ndr_print_ptr(ndr, "domains", r->out.domains);
11680 28 : ndr->depth++;
11681 28 : ndr_print_lsa_DomainListEx(ndr, "domains", r->out.domains);
11682 28 : ndr->depth--;
11683 28 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11684 28 : ndr->depth--;
11685 : }
11686 28 : ndr->depth--;
11687 : }
11688 :
11689 108 : static enum ndr_err_code ndr_push_lsa_CreateTrustedDomainEx(struct ndr_push *ndr, int flags, const struct lsa_CreateTrustedDomainEx *r)
11690 : {
11691 108 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11692 108 : if (flags & NDR_IN) {
11693 48 : if (r->in.policy_handle == NULL) {
11694 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11695 : }
11696 48 : if (r->in.info == NULL) {
11697 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11698 : }
11699 48 : if (r->in.auth_info == NULL) {
11700 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11701 : }
11702 48 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.policy_handle));
11703 48 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
11704 48 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.auth_info));
11705 48 : NDR_CHECK(ndr_push_lsa_TrustedAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
11706 : }
11707 108 : if (flags & NDR_OUT) {
11708 60 : if (r->out.trustdom_handle == NULL) {
11709 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11710 : }
11711 60 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
11712 60 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11713 : }
11714 108 : return NDR_ERR_SUCCESS;
11715 : }
11716 :
11717 96 : static enum ndr_err_code ndr_pull_lsa_CreateTrustedDomainEx(struct ndr_pull *ndr, int flags, struct lsa_CreateTrustedDomainEx *r)
11718 : {
11719 96 : TALLOC_CTX *_mem_save_policy_handle_0 = NULL;
11720 96 : TALLOC_CTX *_mem_save_info_0 = NULL;
11721 96 : TALLOC_CTX *_mem_save_auth_info_0 = NULL;
11722 96 : TALLOC_CTX *_mem_save_trustdom_handle_0 = NULL;
11723 96 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11724 96 : if (flags & NDR_IN) {
11725 48 : NDR_ZERO_STRUCT(r->out);
11726 :
11727 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11728 48 : NDR_PULL_ALLOC(ndr, r->in.policy_handle);
11729 : }
11730 48 : _mem_save_policy_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11731 48 : NDR_PULL_SET_MEM_CTX(ndr, r->in.policy_handle, LIBNDR_FLAG_REF_ALLOC);
11732 48 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.policy_handle));
11733 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_policy_handle_0, LIBNDR_FLAG_REF_ALLOC);
11734 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11735 48 : NDR_PULL_ALLOC(ndr, r->in.info);
11736 : }
11737 48 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11738 48 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
11739 48 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
11740 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11741 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11742 48 : NDR_PULL_ALLOC(ndr, r->in.auth_info);
11743 : }
11744 48 : _mem_save_auth_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11745 48 : NDR_PULL_SET_MEM_CTX(ndr, r->in.auth_info, LIBNDR_FLAG_REF_ALLOC);
11746 48 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.auth_info));
11747 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_auth_info_0, LIBNDR_FLAG_REF_ALLOC);
11748 48 : NDR_CHECK(ndr_pull_lsa_TrustedAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
11749 48 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
11750 48 : NDR_ZERO_STRUCTP(r->out.trustdom_handle);
11751 : }
11752 96 : if (flags & NDR_OUT) {
11753 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11754 : if (r->in.policy_handle == NULL) {
11755 : NDR_PULL_ALLOC(ndr, r->in.policy_handle);
11756 : NDR_ZERO_STRUCTP(r->in.policy_handle);
11757 : }
11758 : if (r->in.info == NULL) {
11759 : NDR_PULL_ALLOC(ndr, r->in.info);
11760 : NDR_ZERO_STRUCTP(r->in.info);
11761 : }
11762 : if (r->in.auth_info == NULL) {
11763 : NDR_PULL_ALLOC(ndr, r->in.auth_info);
11764 : NDR_ZERO_STRUCTP(r->in.auth_info);
11765 : }
11766 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11767 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11768 12 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
11769 : }
11770 48 : _mem_save_trustdom_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11771 48 : NDR_PULL_SET_MEM_CTX(ndr, r->out.trustdom_handle, LIBNDR_FLAG_REF_ALLOC);
11772 48 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
11773 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trustdom_handle_0, LIBNDR_FLAG_REF_ALLOC);
11774 48 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11775 : }
11776 96 : return NDR_ERR_SUCCESS;
11777 : }
11778 :
11779 24 : _PUBLIC_ void ndr_print_lsa_CreateTrustedDomainEx(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CreateTrustedDomainEx *r)
11780 : {
11781 24 : ndr_print_struct(ndr, name, "lsa_CreateTrustedDomainEx");
11782 24 : if (r == NULL) { ndr_print_null(ndr); return; }
11783 24 : ndr->depth++;
11784 24 : if (flags & NDR_SET_VALUES) {
11785 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11786 : }
11787 24 : if (flags & NDR_IN) {
11788 0 : ndr_print_struct(ndr, "in", "lsa_CreateTrustedDomainEx");
11789 0 : ndr->depth++;
11790 0 : ndr_print_ptr(ndr, "policy_handle", r->in.policy_handle);
11791 0 : ndr->depth++;
11792 0 : ndr_print_policy_handle(ndr, "policy_handle", r->in.policy_handle);
11793 0 : ndr->depth--;
11794 0 : ndr_print_ptr(ndr, "info", r->in.info);
11795 0 : ndr->depth++;
11796 0 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "info", r->in.info);
11797 0 : ndr->depth--;
11798 0 : ndr_print_ptr(ndr, "auth_info", r->in.auth_info);
11799 0 : ndr->depth++;
11800 0 : ndr_print_lsa_TrustDomainInfoAuthInfo(ndr, "auth_info", r->in.auth_info);
11801 0 : ndr->depth--;
11802 0 : ndr_print_lsa_TrustedAccessMask(ndr, "access_mask", r->in.access_mask);
11803 0 : ndr->depth--;
11804 : }
11805 24 : if (flags & NDR_OUT) {
11806 24 : ndr_print_struct(ndr, "out", "lsa_CreateTrustedDomainEx");
11807 24 : ndr->depth++;
11808 24 : ndr_print_ptr(ndr, "trustdom_handle", r->out.trustdom_handle);
11809 24 : ndr->depth++;
11810 24 : ndr_print_policy_handle(ndr, "trustdom_handle", r->out.trustdom_handle);
11811 24 : ndr->depth--;
11812 24 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11813 24 : ndr->depth--;
11814 : }
11815 24 : ndr->depth--;
11816 : }
11817 :
11818 324 : static enum ndr_err_code ndr_push_lsa_CloseTrustedDomainEx(struct ndr_push *ndr, int flags, const struct lsa_CloseTrustedDomainEx *r)
11819 : {
11820 324 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11821 324 : if (flags & NDR_IN) {
11822 144 : if (r->in.handle == NULL) {
11823 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11824 : }
11825 144 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11826 : }
11827 324 : if (flags & NDR_OUT) {
11828 180 : if (r->out.handle == NULL) {
11829 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11830 : }
11831 180 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
11832 180 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11833 : }
11834 324 : return NDR_ERR_SUCCESS;
11835 : }
11836 :
11837 288 : static enum ndr_err_code ndr_pull_lsa_CloseTrustedDomainEx(struct ndr_pull *ndr, int flags, struct lsa_CloseTrustedDomainEx *r)
11838 : {
11839 288 : TALLOC_CTX *_mem_save_handle_0 = NULL;
11840 288 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11841 288 : if (flags & NDR_IN) {
11842 144 : NDR_ZERO_STRUCT(r->out);
11843 :
11844 144 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11845 144 : NDR_PULL_ALLOC(ndr, r->in.handle);
11846 : }
11847 144 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11848 144 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
11849 144 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11850 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11851 144 : NDR_PULL_ALLOC(ndr, r->out.handle);
11852 144 : *r->out.handle = *r->in.handle;
11853 : }
11854 288 : if (flags & NDR_OUT) {
11855 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11856 : if (r->in.handle == NULL) {
11857 : NDR_PULL_ALLOC(ndr, r->in.handle);
11858 : NDR_ZERO_STRUCTP(r->in.handle);
11859 : }
11860 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11861 144 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11862 36 : NDR_PULL_ALLOC(ndr, r->out.handle);
11863 : }
11864 144 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11865 144 : NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
11866 144 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
11867 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11868 144 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11869 : }
11870 288 : return NDR_ERR_SUCCESS;
11871 : }
11872 :
11873 72 : _PUBLIC_ void ndr_print_lsa_CloseTrustedDomainEx(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CloseTrustedDomainEx *r)
11874 : {
11875 72 : ndr_print_struct(ndr, name, "lsa_CloseTrustedDomainEx");
11876 72 : if (r == NULL) { ndr_print_null(ndr); return; }
11877 72 : ndr->depth++;
11878 72 : if (flags & NDR_SET_VALUES) {
11879 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11880 : }
11881 72 : if (flags & NDR_IN) {
11882 0 : ndr_print_struct(ndr, "in", "lsa_CloseTrustedDomainEx");
11883 0 : ndr->depth++;
11884 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
11885 0 : ndr->depth++;
11886 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
11887 0 : ndr->depth--;
11888 0 : ndr->depth--;
11889 : }
11890 72 : if (flags & NDR_OUT) {
11891 72 : ndr_print_struct(ndr, "out", "lsa_CloseTrustedDomainEx");
11892 72 : ndr->depth++;
11893 72 : ndr_print_ptr(ndr, "handle", r->out.handle);
11894 72 : ndr->depth++;
11895 72 : ndr_print_policy_handle(ndr, "handle", r->out.handle);
11896 72 : ndr->depth--;
11897 72 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11898 72 : ndr->depth--;
11899 : }
11900 72 : ndr->depth--;
11901 : }
11902 :
11903 36 : static enum ndr_err_code ndr_push_lsa_QueryDomainInformationPolicy(struct ndr_push *ndr, int flags, const struct lsa_QueryDomainInformationPolicy *r)
11904 : {
11905 36 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11906 36 : if (flags & NDR_IN) {
11907 16 : if (r->in.handle == NULL) {
11908 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11909 : }
11910 16 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11911 16 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
11912 : }
11913 36 : if (flags & NDR_OUT) {
11914 20 : if (r->out.info == NULL) {
11915 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11916 : }
11917 20 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
11918 20 : if (*r->out.info) {
11919 10 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
11920 10 : NDR_CHECK(ndr_push_lsa_DomainInformationPolicy(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11921 : }
11922 20 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11923 : }
11924 36 : return NDR_ERR_SUCCESS;
11925 : }
11926 :
11927 32 : static enum ndr_err_code ndr_pull_lsa_QueryDomainInformationPolicy(struct ndr_pull *ndr, int flags, struct lsa_QueryDomainInformationPolicy *r)
11928 : {
11929 : uint32_t _ptr_info;
11930 32 : TALLOC_CTX *_mem_save_handle_0 = NULL;
11931 32 : TALLOC_CTX *_mem_save_info_0 = NULL;
11932 32 : TALLOC_CTX *_mem_save_info_1 = NULL;
11933 32 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11934 32 : if (flags & NDR_IN) {
11935 16 : NDR_ZERO_STRUCT(r->out);
11936 :
11937 16 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11938 16 : NDR_PULL_ALLOC(ndr, r->in.handle);
11939 : }
11940 16 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11941 16 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
11942 16 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
11943 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
11944 16 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
11945 16 : NDR_PULL_ALLOC(ndr, r->out.info);
11946 16 : NDR_ZERO_STRUCTP(r->out.info);
11947 : }
11948 32 : if (flags & NDR_OUT) {
11949 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11950 : if (r->in.handle == NULL) {
11951 : NDR_PULL_ALLOC(ndr, r->in.handle);
11952 : NDR_ZERO_STRUCTP(r->in.handle);
11953 : }
11954 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11955 16 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11956 4 : NDR_PULL_ALLOC(ndr, r->out.info);
11957 : }
11958 16 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11959 16 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
11960 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
11961 16 : if (_ptr_info) {
11962 8 : NDR_PULL_ALLOC(ndr, *r->out.info);
11963 : } else {
11964 8 : *r->out.info = NULL;
11965 : }
11966 16 : if (*r->out.info) {
11967 8 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
11968 8 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
11969 8 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
11970 8 : NDR_CHECK(ndr_pull_lsa_DomainInformationPolicy(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11971 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
11972 : }
11973 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11974 16 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11975 : }
11976 32 : return NDR_ERR_SUCCESS;
11977 : }
11978 :
11979 8 : _PUBLIC_ void ndr_print_lsa_QueryDomainInformationPolicy(struct ndr_print *ndr, const char *name, int flags, const struct lsa_QueryDomainInformationPolicy *r)
11980 : {
11981 8 : ndr_print_struct(ndr, name, "lsa_QueryDomainInformationPolicy");
11982 8 : if (r == NULL) { ndr_print_null(ndr); return; }
11983 8 : ndr->depth++;
11984 8 : if (flags & NDR_SET_VALUES) {
11985 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11986 : }
11987 8 : if (flags & NDR_IN) {
11988 0 : ndr_print_struct(ndr, "in", "lsa_QueryDomainInformationPolicy");
11989 0 : ndr->depth++;
11990 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
11991 0 : ndr->depth++;
11992 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
11993 0 : ndr->depth--;
11994 0 : ndr_print_uint16(ndr, "level", r->in.level);
11995 0 : ndr->depth--;
11996 : }
11997 8 : if (flags & NDR_OUT) {
11998 8 : ndr_print_struct(ndr, "out", "lsa_QueryDomainInformationPolicy");
11999 8 : ndr->depth++;
12000 8 : ndr_print_ptr(ndr, "info", r->out.info);
12001 8 : ndr->depth++;
12002 8 : ndr_print_ptr(ndr, "info", *r->out.info);
12003 8 : ndr->depth++;
12004 8 : if (*r->out.info) {
12005 4 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
12006 4 : ndr_print_lsa_DomainInformationPolicy(ndr, "info", *r->out.info);
12007 : }
12008 8 : ndr->depth--;
12009 8 : ndr->depth--;
12010 8 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12011 8 : ndr->depth--;
12012 : }
12013 8 : ndr->depth--;
12014 : }
12015 :
12016 0 : static enum ndr_err_code ndr_push_lsa_SetDomainInformationPolicy(struct ndr_push *ndr, int flags, const struct lsa_SetDomainInformationPolicy *r)
12017 : {
12018 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12019 0 : if (flags & NDR_IN) {
12020 0 : if (r->in.handle == NULL) {
12021 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12022 : }
12023 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12024 0 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
12025 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.info));
12026 0 : if (r->in.info) {
12027 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
12028 0 : NDR_CHECK(ndr_push_lsa_DomainInformationPolicy(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
12029 : }
12030 : }
12031 0 : if (flags & NDR_OUT) {
12032 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12033 : }
12034 0 : return NDR_ERR_SUCCESS;
12035 : }
12036 :
12037 0 : static enum ndr_err_code ndr_pull_lsa_SetDomainInformationPolicy(struct ndr_pull *ndr, int flags, struct lsa_SetDomainInformationPolicy *r)
12038 : {
12039 : uint32_t _ptr_info;
12040 0 : TALLOC_CTX *_mem_save_handle_0 = NULL;
12041 0 : TALLOC_CTX *_mem_save_info_0 = NULL;
12042 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12043 0 : if (flags & NDR_IN) {
12044 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12045 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
12046 : }
12047 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12048 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
12049 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12050 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
12051 0 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
12052 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
12053 0 : if (_ptr_info) {
12054 0 : NDR_PULL_ALLOC(ndr, r->in.info);
12055 : } else {
12056 0 : r->in.info = NULL;
12057 : }
12058 0 : if (r->in.info) {
12059 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
12060 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, 0);
12061 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
12062 0 : NDR_CHECK(ndr_pull_lsa_DomainInformationPolicy(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
12063 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, 0);
12064 : }
12065 : }
12066 0 : if (flags & NDR_OUT) {
12067 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12068 : if (r->in.handle == NULL) {
12069 : NDR_PULL_ALLOC(ndr, r->in.handle);
12070 : NDR_ZERO_STRUCTP(r->in.handle);
12071 : }
12072 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12073 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12074 : }
12075 0 : return NDR_ERR_SUCCESS;
12076 : }
12077 :
12078 0 : _PUBLIC_ void ndr_print_lsa_SetDomainInformationPolicy(struct ndr_print *ndr, const char *name, int flags, const struct lsa_SetDomainInformationPolicy *r)
12079 : {
12080 0 : ndr_print_struct(ndr, name, "lsa_SetDomainInformationPolicy");
12081 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12082 0 : ndr->depth++;
12083 0 : if (flags & NDR_SET_VALUES) {
12084 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12085 : }
12086 0 : if (flags & NDR_IN) {
12087 0 : ndr_print_struct(ndr, "in", "lsa_SetDomainInformationPolicy");
12088 0 : ndr->depth++;
12089 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
12090 0 : ndr->depth++;
12091 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
12092 0 : ndr->depth--;
12093 0 : ndr_print_uint16(ndr, "level", r->in.level);
12094 0 : ndr_print_ptr(ndr, "info", r->in.info);
12095 0 : ndr->depth++;
12096 0 : if (r->in.info) {
12097 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
12098 0 : ndr_print_lsa_DomainInformationPolicy(ndr, "info", r->in.info);
12099 : }
12100 0 : ndr->depth--;
12101 0 : ndr->depth--;
12102 : }
12103 0 : if (flags & NDR_OUT) {
12104 0 : ndr_print_struct(ndr, "out", "lsa_SetDomainInformationPolicy");
12105 0 : ndr->depth++;
12106 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12107 0 : ndr->depth--;
12108 : }
12109 0 : ndr->depth--;
12110 : }
12111 :
12112 324 : static enum ndr_err_code ndr_push_lsa_OpenTrustedDomainByName(struct ndr_push *ndr, int flags, const struct lsa_OpenTrustedDomainByName *r)
12113 : {
12114 324 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12115 324 : if (flags & NDR_IN) {
12116 144 : if (r->in.handle == NULL) {
12117 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12118 : }
12119 144 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12120 144 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.name));
12121 144 : NDR_CHECK(ndr_push_lsa_TrustedAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
12122 : }
12123 324 : if (flags & NDR_OUT) {
12124 180 : if (r->out.trustdom_handle == NULL) {
12125 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12126 : }
12127 180 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
12128 180 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12129 : }
12130 324 : return NDR_ERR_SUCCESS;
12131 : }
12132 :
12133 288 : static enum ndr_err_code ndr_pull_lsa_OpenTrustedDomainByName(struct ndr_pull *ndr, int flags, struct lsa_OpenTrustedDomainByName *r)
12134 : {
12135 288 : TALLOC_CTX *_mem_save_handle_0 = NULL;
12136 288 : TALLOC_CTX *_mem_save_trustdom_handle_0 = NULL;
12137 288 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12138 288 : if (flags & NDR_IN) {
12139 144 : NDR_ZERO_STRUCT(r->out);
12140 :
12141 144 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12142 144 : NDR_PULL_ALLOC(ndr, r->in.handle);
12143 : }
12144 144 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12145 144 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
12146 144 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12147 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
12148 144 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.name));
12149 144 : NDR_CHECK(ndr_pull_lsa_TrustedAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
12150 144 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
12151 144 : NDR_ZERO_STRUCTP(r->out.trustdom_handle);
12152 : }
12153 288 : if (flags & NDR_OUT) {
12154 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12155 : if (r->in.handle == NULL) {
12156 : NDR_PULL_ALLOC(ndr, r->in.handle);
12157 : NDR_ZERO_STRUCTP(r->in.handle);
12158 : }
12159 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12160 144 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12161 36 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
12162 : }
12163 144 : _mem_save_trustdom_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12164 144 : NDR_PULL_SET_MEM_CTX(ndr, r->out.trustdom_handle, LIBNDR_FLAG_REF_ALLOC);
12165 144 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
12166 144 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trustdom_handle_0, LIBNDR_FLAG_REF_ALLOC);
12167 144 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12168 : }
12169 288 : return NDR_ERR_SUCCESS;
12170 : }
12171 :
12172 72 : _PUBLIC_ void ndr_print_lsa_OpenTrustedDomainByName(struct ndr_print *ndr, const char *name, int flags, const struct lsa_OpenTrustedDomainByName *r)
12173 : {
12174 72 : ndr_print_struct(ndr, name, "lsa_OpenTrustedDomainByName");
12175 72 : if (r == NULL) { ndr_print_null(ndr); return; }
12176 72 : ndr->depth++;
12177 72 : if (flags & NDR_SET_VALUES) {
12178 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12179 : }
12180 72 : if (flags & NDR_IN) {
12181 0 : ndr_print_struct(ndr, "in", "lsa_OpenTrustedDomainByName");
12182 0 : ndr->depth++;
12183 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
12184 0 : ndr->depth++;
12185 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
12186 0 : ndr->depth--;
12187 0 : ndr_print_lsa_String(ndr, "name", &r->in.name);
12188 0 : ndr_print_lsa_TrustedAccessMask(ndr, "access_mask", r->in.access_mask);
12189 0 : ndr->depth--;
12190 : }
12191 72 : if (flags & NDR_OUT) {
12192 72 : ndr_print_struct(ndr, "out", "lsa_OpenTrustedDomainByName");
12193 72 : ndr->depth++;
12194 72 : ndr_print_ptr(ndr, "trustdom_handle", r->out.trustdom_handle);
12195 72 : ndr->depth++;
12196 72 : ndr_print_policy_handle(ndr, "trustdom_handle", r->out.trustdom_handle);
12197 72 : ndr->depth--;
12198 72 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12199 72 : ndr->depth--;
12200 : }
12201 72 : ndr->depth--;
12202 : }
12203 :
12204 0 : static enum ndr_err_code ndr_push_lsa_TestCall(struct ndr_push *ndr, int flags, const struct lsa_TestCall *r)
12205 : {
12206 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12207 0 : if (flags & NDR_IN) {
12208 : }
12209 0 : if (flags & NDR_OUT) {
12210 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12211 : }
12212 0 : return NDR_ERR_SUCCESS;
12213 : }
12214 :
12215 0 : static enum ndr_err_code ndr_pull_lsa_TestCall(struct ndr_pull *ndr, int flags, struct lsa_TestCall *r)
12216 : {
12217 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12218 0 : if (flags & NDR_IN) {
12219 : }
12220 0 : if (flags & NDR_OUT) {
12221 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12222 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12223 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12224 : }
12225 0 : return NDR_ERR_SUCCESS;
12226 : }
12227 :
12228 0 : _PUBLIC_ void ndr_print_lsa_TestCall(struct ndr_print *ndr, const char *name, int flags, const struct lsa_TestCall *r)
12229 : {
12230 0 : ndr_print_struct(ndr, name, "lsa_TestCall");
12231 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12232 0 : ndr->depth++;
12233 0 : if (flags & NDR_SET_VALUES) {
12234 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12235 : }
12236 0 : if (flags & NDR_IN) {
12237 0 : ndr_print_struct(ndr, "in", "lsa_TestCall");
12238 0 : ndr->depth++;
12239 0 : ndr->depth--;
12240 : }
12241 0 : if (flags & NDR_OUT) {
12242 0 : ndr_print_struct(ndr, "out", "lsa_TestCall");
12243 0 : ndr->depth++;
12244 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12245 0 : ndr->depth--;
12246 : }
12247 0 : ndr->depth--;
12248 : }
12249 :
12250 9 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupSids2(struct ndr_push *ndr, int flags, const struct lsa_LookupSids2 *r)
12251 : {
12252 9 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12253 9 : if (flags & NDR_IN) {
12254 4 : if (r->in.handle == NULL) {
12255 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12256 : }
12257 4 : if (r->in.sids == NULL) {
12258 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12259 : }
12260 4 : if (r->in.names == NULL) {
12261 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12262 : }
12263 4 : if (r->in.count == NULL) {
12264 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12265 : }
12266 4 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12267 4 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
12268 4 : NDR_CHECK(ndr_push_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.names));
12269 4 : NDR_CHECK(ndr_push_lsa_LookupNamesLevel(ndr, NDR_SCALARS, r->in.level));
12270 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
12271 4 : NDR_CHECK(ndr_push_lsa_LookupOptions(ndr, NDR_SCALARS, r->in.lookup_options));
12272 4 : NDR_CHECK(ndr_push_lsa_ClientRevision(ndr, NDR_SCALARS, r->in.client_revision));
12273 : }
12274 9 : if (flags & NDR_OUT) {
12275 5 : if (r->out.domains == NULL) {
12276 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12277 : }
12278 5 : if (r->out.names == NULL) {
12279 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12280 : }
12281 5 : if (r->out.count == NULL) {
12282 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12283 : }
12284 5 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
12285 5 : if (*r->out.domains) {
12286 5 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
12287 : }
12288 5 : NDR_CHECK(ndr_push_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
12289 5 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
12290 5 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12291 : }
12292 9 : return NDR_ERR_SUCCESS;
12293 : }
12294 :
12295 8 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids2(struct ndr_pull *ndr, int flags, struct lsa_LookupSids2 *r)
12296 : {
12297 : uint32_t _ptr_domains;
12298 8 : TALLOC_CTX *_mem_save_handle_0 = NULL;
12299 8 : TALLOC_CTX *_mem_save_sids_0 = NULL;
12300 8 : TALLOC_CTX *_mem_save_domains_0 = NULL;
12301 8 : TALLOC_CTX *_mem_save_domains_1 = NULL;
12302 8 : TALLOC_CTX *_mem_save_names_0 = NULL;
12303 8 : TALLOC_CTX *_mem_save_count_0 = NULL;
12304 8 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12305 8 : if (flags & NDR_IN) {
12306 4 : NDR_ZERO_STRUCT(r->out);
12307 :
12308 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12309 4 : NDR_PULL_ALLOC(ndr, r->in.handle);
12310 : }
12311 4 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12312 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
12313 4 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12314 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
12315 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12316 4 : NDR_PULL_ALLOC(ndr, r->in.sids);
12317 : }
12318 4 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
12319 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
12320 4 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
12321 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
12322 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12323 4 : NDR_PULL_ALLOC(ndr, r->in.names);
12324 : }
12325 4 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
12326 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, LIBNDR_FLAG_REF_ALLOC);
12327 4 : NDR_CHECK(ndr_pull_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.names));
12328 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
12329 4 : NDR_CHECK(ndr_pull_lsa_LookupNamesLevel(ndr, NDR_SCALARS, &r->in.level));
12330 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12331 4 : NDR_PULL_ALLOC(ndr, r->in.count);
12332 : }
12333 4 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
12334 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
12335 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
12336 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
12337 4 : NDR_CHECK(ndr_pull_lsa_LookupOptions(ndr, NDR_SCALARS, &r->in.lookup_options));
12338 4 : NDR_CHECK(ndr_pull_lsa_ClientRevision(ndr, NDR_SCALARS, &r->in.client_revision));
12339 4 : NDR_PULL_ALLOC(ndr, r->out.domains);
12340 4 : NDR_ZERO_STRUCTP(r->out.domains);
12341 4 : NDR_PULL_ALLOC(ndr, r->out.names);
12342 4 : *r->out.names = *r->in.names;
12343 4 : NDR_PULL_ALLOC(ndr, r->out.count);
12344 4 : *r->out.count = *r->in.count;
12345 : }
12346 8 : if (flags & NDR_OUT) {
12347 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12348 : if (r->in.handle == NULL) {
12349 : NDR_PULL_ALLOC(ndr, r->in.handle);
12350 : NDR_ZERO_STRUCTP(r->in.handle);
12351 : }
12352 : if (r->in.sids == NULL) {
12353 : NDR_PULL_ALLOC(ndr, r->in.sids);
12354 : NDR_ZERO_STRUCTP(r->in.sids);
12355 : }
12356 : if (r->in.names == NULL) {
12357 : NDR_PULL_ALLOC(ndr, r->in.names);
12358 : NDR_ZERO_STRUCTP(r->in.names);
12359 : }
12360 : if (r->in.count == NULL) {
12361 : NDR_PULL_ALLOC(ndr, r->in.count);
12362 : NDR_ZERO_STRUCTP(r->in.count);
12363 : }
12364 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12365 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12366 1 : NDR_PULL_ALLOC(ndr, r->out.domains);
12367 : }
12368 4 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
12369 4 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
12370 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
12371 4 : if (_ptr_domains) {
12372 4 : NDR_PULL_ALLOC(ndr, *r->out.domains);
12373 : } else {
12374 0 : *r->out.domains = NULL;
12375 : }
12376 4 : if (*r->out.domains) {
12377 4 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
12378 4 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
12379 4 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
12380 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
12381 : }
12382 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
12383 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12384 1 : NDR_PULL_ALLOC(ndr, r->out.names);
12385 : }
12386 4 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
12387 4 : NDR_PULL_SET_MEM_CTX(ndr, r->out.names, LIBNDR_FLAG_REF_ALLOC);
12388 4 : NDR_CHECK(ndr_pull_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
12389 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
12390 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12391 1 : NDR_PULL_ALLOC(ndr, r->out.count);
12392 : }
12393 4 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
12394 4 : NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
12395 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
12396 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
12397 4 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12398 : }
12399 8 : return NDR_ERR_SUCCESS;
12400 : }
12401 :
12402 2 : _PUBLIC_ void ndr_print_lsa_LookupSids2(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupSids2 *r)
12403 : {
12404 2 : ndr_print_struct(ndr, name, "lsa_LookupSids2");
12405 2 : if (r == NULL) { ndr_print_null(ndr); return; }
12406 2 : ndr->depth++;
12407 2 : if (flags & NDR_SET_VALUES) {
12408 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12409 : }
12410 2 : if (flags & NDR_IN) {
12411 0 : ndr_print_struct(ndr, "in", "lsa_LookupSids2");
12412 0 : ndr->depth++;
12413 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
12414 0 : ndr->depth++;
12415 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
12416 0 : ndr->depth--;
12417 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
12418 0 : ndr->depth++;
12419 0 : ndr_print_lsa_SidArray(ndr, "sids", r->in.sids);
12420 0 : ndr->depth--;
12421 0 : ndr_print_ptr(ndr, "names", r->in.names);
12422 0 : ndr->depth++;
12423 0 : ndr_print_lsa_TransNameArray2(ndr, "names", r->in.names);
12424 0 : ndr->depth--;
12425 0 : ndr_print_lsa_LookupNamesLevel(ndr, "level", r->in.level);
12426 0 : ndr_print_ptr(ndr, "count", r->in.count);
12427 0 : ndr->depth++;
12428 0 : ndr_print_uint32(ndr, "count", *r->in.count);
12429 0 : ndr->depth--;
12430 0 : ndr_print_lsa_LookupOptions(ndr, "lookup_options", r->in.lookup_options);
12431 0 : ndr_print_lsa_ClientRevision(ndr, "client_revision", r->in.client_revision);
12432 0 : ndr->depth--;
12433 : }
12434 2 : if (flags & NDR_OUT) {
12435 2 : ndr_print_struct(ndr, "out", "lsa_LookupSids2");
12436 2 : ndr->depth++;
12437 2 : ndr_print_ptr(ndr, "domains", r->out.domains);
12438 2 : ndr->depth++;
12439 2 : ndr_print_ptr(ndr, "domains", *r->out.domains);
12440 2 : ndr->depth++;
12441 2 : if (*r->out.domains) {
12442 2 : ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
12443 : }
12444 2 : ndr->depth--;
12445 2 : ndr->depth--;
12446 2 : ndr_print_ptr(ndr, "names", r->out.names);
12447 2 : ndr->depth++;
12448 2 : ndr_print_lsa_TransNameArray2(ndr, "names", r->out.names);
12449 2 : ndr->depth--;
12450 2 : ndr_print_ptr(ndr, "count", r->out.count);
12451 2 : ndr->depth++;
12452 2 : ndr_print_uint32(ndr, "count", *r->out.count);
12453 2 : ndr->depth--;
12454 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12455 2 : ndr->depth--;
12456 : }
12457 2 : ndr->depth--;
12458 : }
12459 :
12460 18 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupNames2(struct ndr_push *ndr, int flags, const struct lsa_LookupNames2 *r)
12461 : {
12462 : uint32_t cntr_names_0;
12463 18 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12464 18 : if (flags & NDR_IN) {
12465 8 : if (r->in.handle == NULL) {
12466 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12467 : }
12468 8 : if (r->in.sids == NULL) {
12469 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12470 : }
12471 8 : if (r->in.count == NULL) {
12472 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12473 : }
12474 8 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12475 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_names));
12476 8 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.num_names));
12477 36 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
12478 28 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
12479 : }
12480 36 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
12481 28 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
12482 : }
12483 8 : NDR_CHECK(ndr_push_lsa_TransSidArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
12484 8 : NDR_CHECK(ndr_push_lsa_LookupNamesLevel(ndr, NDR_SCALARS, r->in.level));
12485 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
12486 8 : NDR_CHECK(ndr_push_lsa_LookupOptions(ndr, NDR_SCALARS, r->in.lookup_options));
12487 8 : NDR_CHECK(ndr_push_lsa_ClientRevision(ndr, NDR_SCALARS, r->in.client_revision));
12488 : }
12489 18 : if (flags & NDR_OUT) {
12490 10 : if (r->out.domains == NULL) {
12491 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12492 : }
12493 10 : if (r->out.sids == NULL) {
12494 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12495 : }
12496 10 : if (r->out.count == NULL) {
12497 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12498 : }
12499 10 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
12500 10 : if (*r->out.domains) {
12501 10 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
12502 : }
12503 10 : NDR_CHECK(ndr_push_lsa_TransSidArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
12504 10 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
12505 10 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12506 : }
12507 18 : return NDR_ERR_SUCCESS;
12508 : }
12509 :
12510 16 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames2(struct ndr_pull *ndr, int flags, struct lsa_LookupNames2 *r)
12511 : {
12512 16 : uint32_t size_names_0 = 0;
12513 : uint32_t cntr_names_0;
12514 : uint32_t _ptr_domains;
12515 16 : TALLOC_CTX *_mem_save_handle_0 = NULL;
12516 16 : TALLOC_CTX *_mem_save_names_0 = NULL;
12517 16 : TALLOC_CTX *_mem_save_domains_0 = NULL;
12518 16 : TALLOC_CTX *_mem_save_domains_1 = NULL;
12519 16 : TALLOC_CTX *_mem_save_sids_0 = NULL;
12520 16 : TALLOC_CTX *_mem_save_count_0 = NULL;
12521 16 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12522 16 : if (flags & NDR_IN) {
12523 8 : NDR_ZERO_STRUCT(r->out);
12524 :
12525 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12526 8 : NDR_PULL_ALLOC(ndr, r->in.handle);
12527 : }
12528 8 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12529 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
12530 8 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
12531 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
12532 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_names));
12533 8 : if (r->in.num_names > 1000) {
12534 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
12535 : }
12536 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.names));
12537 8 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.names, &size_names_0));
12538 8 : NDR_PULL_ALLOC_N(ndr, r->in.names, size_names_0);
12539 8 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
12540 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, 0);
12541 36 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
12542 28 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
12543 : }
12544 36 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
12545 28 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
12546 : }
12547 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
12548 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12549 8 : NDR_PULL_ALLOC(ndr, r->in.sids);
12550 : }
12551 8 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
12552 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
12553 8 : NDR_CHECK(ndr_pull_lsa_TransSidArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
12554 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
12555 8 : NDR_CHECK(ndr_pull_lsa_LookupNamesLevel(ndr, NDR_SCALARS, &r->in.level));
12556 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12557 8 : NDR_PULL_ALLOC(ndr, r->in.count);
12558 : }
12559 8 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
12560 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
12561 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
12562 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
12563 8 : NDR_CHECK(ndr_pull_lsa_LookupOptions(ndr, NDR_SCALARS, &r->in.lookup_options));
12564 8 : NDR_CHECK(ndr_pull_lsa_ClientRevision(ndr, NDR_SCALARS, &r->in.client_revision));
12565 8 : NDR_PULL_ALLOC(ndr, r->out.domains);
12566 8 : NDR_ZERO_STRUCTP(r->out.domains);
12567 8 : NDR_PULL_ALLOC(ndr, r->out.sids);
12568 8 : *r->out.sids = *r->in.sids;
12569 8 : NDR_PULL_ALLOC(ndr, r->out.count);
12570 8 : *r->out.count = *r->in.count;
12571 8 : if (r->in.names) {
12572 8 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.names, r->in.num_names));
12573 : }
12574 8 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
12575 : }
12576 : }
12577 16 : if (flags & NDR_OUT) {
12578 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12579 : if (r->in.handle == NULL) {
12580 : NDR_PULL_ALLOC(ndr, r->in.handle);
12581 : NDR_ZERO_STRUCTP(r->in.handle);
12582 : }
12583 : if (r->in.sids == NULL) {
12584 : NDR_PULL_ALLOC(ndr, r->in.sids);
12585 : NDR_ZERO_STRUCTP(r->in.sids);
12586 : }
12587 : if (r->in.count == NULL) {
12588 : NDR_PULL_ALLOC(ndr, r->in.count);
12589 : NDR_ZERO_STRUCTP(r->in.count);
12590 : }
12591 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12592 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12593 2 : NDR_PULL_ALLOC(ndr, r->out.domains);
12594 : }
12595 8 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
12596 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
12597 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
12598 8 : if (_ptr_domains) {
12599 8 : NDR_PULL_ALLOC(ndr, *r->out.domains);
12600 : } else {
12601 0 : *r->out.domains = NULL;
12602 : }
12603 8 : if (*r->out.domains) {
12604 8 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
12605 8 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
12606 8 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
12607 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
12608 : }
12609 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
12610 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12611 2 : NDR_PULL_ALLOC(ndr, r->out.sids);
12612 : }
12613 8 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
12614 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
12615 8 : NDR_CHECK(ndr_pull_lsa_TransSidArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
12616 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
12617 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12618 2 : NDR_PULL_ALLOC(ndr, r->out.count);
12619 : }
12620 8 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
12621 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
12622 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
12623 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
12624 8 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12625 : }
12626 16 : return NDR_ERR_SUCCESS;
12627 : }
12628 :
12629 4 : _PUBLIC_ void ndr_print_lsa_LookupNames2(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupNames2 *r)
12630 : {
12631 : uint32_t cntr_names_0;
12632 4 : ndr_print_struct(ndr, name, "lsa_LookupNames2");
12633 4 : if (r == NULL) { ndr_print_null(ndr); return; }
12634 4 : ndr->depth++;
12635 4 : if (flags & NDR_SET_VALUES) {
12636 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12637 : }
12638 4 : if (flags & NDR_IN) {
12639 0 : ndr_print_struct(ndr, "in", "lsa_LookupNames2");
12640 0 : ndr->depth++;
12641 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
12642 0 : ndr->depth++;
12643 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
12644 0 : ndr->depth--;
12645 0 : ndr_print_uint32(ndr, "num_names", r->in.num_names);
12646 0 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->in.num_names);
12647 0 : ndr->depth++;
12648 0 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
12649 0 : ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
12650 : }
12651 0 : ndr->depth--;
12652 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
12653 0 : ndr->depth++;
12654 0 : ndr_print_lsa_TransSidArray2(ndr, "sids", r->in.sids);
12655 0 : ndr->depth--;
12656 0 : ndr_print_lsa_LookupNamesLevel(ndr, "level", r->in.level);
12657 0 : ndr_print_ptr(ndr, "count", r->in.count);
12658 0 : ndr->depth++;
12659 0 : ndr_print_uint32(ndr, "count", *r->in.count);
12660 0 : ndr->depth--;
12661 0 : ndr_print_lsa_LookupOptions(ndr, "lookup_options", r->in.lookup_options);
12662 0 : ndr_print_lsa_ClientRevision(ndr, "client_revision", r->in.client_revision);
12663 0 : ndr->depth--;
12664 : }
12665 4 : if (flags & NDR_OUT) {
12666 4 : ndr_print_struct(ndr, "out", "lsa_LookupNames2");
12667 4 : ndr->depth++;
12668 4 : ndr_print_ptr(ndr, "domains", r->out.domains);
12669 4 : ndr->depth++;
12670 4 : ndr_print_ptr(ndr, "domains", *r->out.domains);
12671 4 : ndr->depth++;
12672 4 : if (*r->out.domains) {
12673 4 : ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
12674 : }
12675 4 : ndr->depth--;
12676 4 : ndr->depth--;
12677 4 : ndr_print_ptr(ndr, "sids", r->out.sids);
12678 4 : ndr->depth++;
12679 4 : ndr_print_lsa_TransSidArray2(ndr, "sids", r->out.sids);
12680 4 : ndr->depth--;
12681 4 : ndr_print_ptr(ndr, "count", r->out.count);
12682 4 : ndr->depth++;
12683 4 : ndr_print_uint32(ndr, "count", *r->out.count);
12684 4 : ndr->depth--;
12685 4 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12686 4 : ndr->depth--;
12687 : }
12688 4 : ndr->depth--;
12689 : }
12690 :
12691 161 : static enum ndr_err_code ndr_push_lsa_CreateTrustedDomainEx2(struct ndr_push *ndr, int flags, const struct lsa_CreateTrustedDomainEx2 *r)
12692 : {
12693 161 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12694 161 : if (flags & NDR_IN) {
12695 74 : if (r->in.policy_handle == NULL) {
12696 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12697 : }
12698 74 : if (r->in.info == NULL) {
12699 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12700 : }
12701 74 : if (r->in.auth_info_internal == NULL) {
12702 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12703 : }
12704 74 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.policy_handle));
12705 74 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
12706 74 : NDR_CHECK(ndr_push_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.auth_info_internal));
12707 74 : NDR_CHECK(ndr_push_lsa_TrustedAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
12708 : }
12709 161 : if (flags & NDR_OUT) {
12710 87 : if (r->out.trustdom_handle == NULL) {
12711 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12712 : }
12713 87 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
12714 87 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12715 : }
12716 161 : return NDR_ERR_SUCCESS;
12717 : }
12718 :
12719 148 : static enum ndr_err_code ndr_pull_lsa_CreateTrustedDomainEx2(struct ndr_pull *ndr, int flags, struct lsa_CreateTrustedDomainEx2 *r)
12720 : {
12721 148 : TALLOC_CTX *_mem_save_policy_handle_0 = NULL;
12722 148 : TALLOC_CTX *_mem_save_info_0 = NULL;
12723 148 : TALLOC_CTX *_mem_save_auth_info_internal_0 = NULL;
12724 148 : TALLOC_CTX *_mem_save_trustdom_handle_0 = NULL;
12725 148 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12726 148 : if (flags & NDR_IN) {
12727 74 : NDR_ZERO_STRUCT(r->out);
12728 :
12729 74 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12730 74 : NDR_PULL_ALLOC(ndr, r->in.policy_handle);
12731 : }
12732 74 : _mem_save_policy_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12733 74 : NDR_PULL_SET_MEM_CTX(ndr, r->in.policy_handle, LIBNDR_FLAG_REF_ALLOC);
12734 74 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.policy_handle));
12735 74 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_policy_handle_0, LIBNDR_FLAG_REF_ALLOC);
12736 74 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12737 74 : NDR_PULL_ALLOC(ndr, r->in.info);
12738 : }
12739 74 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
12740 74 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
12741 74 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoInfoEx(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
12742 74 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
12743 74 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12744 74 : NDR_PULL_ALLOC(ndr, r->in.auth_info_internal);
12745 : }
12746 74 : _mem_save_auth_info_internal_0 = NDR_PULL_GET_MEM_CTX(ndr);
12747 74 : NDR_PULL_SET_MEM_CTX(ndr, r->in.auth_info_internal, LIBNDR_FLAG_REF_ALLOC);
12748 74 : NDR_CHECK(ndr_pull_lsa_TrustDomainInfoAuthInfoInternal(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.auth_info_internal));
12749 74 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_auth_info_internal_0, LIBNDR_FLAG_REF_ALLOC);
12750 74 : NDR_CHECK(ndr_pull_lsa_TrustedAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
12751 74 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
12752 74 : NDR_ZERO_STRUCTP(r->out.trustdom_handle);
12753 : }
12754 148 : if (flags & NDR_OUT) {
12755 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12756 : if (r->in.policy_handle == NULL) {
12757 : NDR_PULL_ALLOC(ndr, r->in.policy_handle);
12758 : NDR_ZERO_STRUCTP(r->in.policy_handle);
12759 : }
12760 : if (r->in.info == NULL) {
12761 : NDR_PULL_ALLOC(ndr, r->in.info);
12762 : NDR_ZERO_STRUCTP(r->in.info);
12763 : }
12764 : if (r->in.auth_info_internal == NULL) {
12765 : NDR_PULL_ALLOC(ndr, r->in.auth_info_internal);
12766 : NDR_ZERO_STRUCTP(r->in.auth_info_internal);
12767 : }
12768 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12769 74 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12770 35 : NDR_PULL_ALLOC(ndr, r->out.trustdom_handle);
12771 : }
12772 74 : _mem_save_trustdom_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12773 74 : NDR_PULL_SET_MEM_CTX(ndr, r->out.trustdom_handle, LIBNDR_FLAG_REF_ALLOC);
12774 74 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.trustdom_handle));
12775 74 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trustdom_handle_0, LIBNDR_FLAG_REF_ALLOC);
12776 74 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12777 : }
12778 148 : return NDR_ERR_SUCCESS;
12779 : }
12780 :
12781 26 : _PUBLIC_ void ndr_print_lsa_CreateTrustedDomainEx2(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CreateTrustedDomainEx2 *r)
12782 : {
12783 26 : ndr_print_struct(ndr, name, "lsa_CreateTrustedDomainEx2");
12784 26 : if (r == NULL) { ndr_print_null(ndr); return; }
12785 26 : ndr->depth++;
12786 26 : if (flags & NDR_SET_VALUES) {
12787 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12788 : }
12789 26 : if (flags & NDR_IN) {
12790 0 : ndr_print_struct(ndr, "in", "lsa_CreateTrustedDomainEx2");
12791 0 : ndr->depth++;
12792 0 : ndr_print_ptr(ndr, "policy_handle", r->in.policy_handle);
12793 0 : ndr->depth++;
12794 0 : ndr_print_policy_handle(ndr, "policy_handle", r->in.policy_handle);
12795 0 : ndr->depth--;
12796 0 : ndr_print_ptr(ndr, "info", r->in.info);
12797 0 : ndr->depth++;
12798 0 : ndr_print_lsa_TrustDomainInfoInfoEx(ndr, "info", r->in.info);
12799 0 : ndr->depth--;
12800 0 : ndr_print_ptr(ndr, "auth_info_internal", r->in.auth_info_internal);
12801 0 : ndr->depth++;
12802 0 : ndr_print_lsa_TrustDomainInfoAuthInfoInternal(ndr, "auth_info_internal", r->in.auth_info_internal);
12803 0 : ndr->depth--;
12804 0 : ndr_print_lsa_TrustedAccessMask(ndr, "access_mask", r->in.access_mask);
12805 0 : ndr->depth--;
12806 : }
12807 26 : if (flags & NDR_OUT) {
12808 26 : ndr_print_struct(ndr, "out", "lsa_CreateTrustedDomainEx2");
12809 26 : ndr->depth++;
12810 26 : ndr_print_ptr(ndr, "trustdom_handle", r->out.trustdom_handle);
12811 26 : ndr->depth++;
12812 26 : ndr_print_policy_handle(ndr, "trustdom_handle", r->out.trustdom_handle);
12813 26 : ndr->depth--;
12814 26 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12815 26 : ndr->depth--;
12816 : }
12817 26 : ndr->depth--;
12818 : }
12819 :
12820 0 : static enum ndr_err_code ndr_push_lsa_CREDRWRITE(struct ndr_push *ndr, int flags, const struct lsa_CREDRWRITE *r)
12821 : {
12822 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12823 0 : if (flags & NDR_IN) {
12824 : }
12825 0 : if (flags & NDR_OUT) {
12826 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12827 : }
12828 0 : return NDR_ERR_SUCCESS;
12829 : }
12830 :
12831 0 : static enum ndr_err_code ndr_pull_lsa_CREDRWRITE(struct ndr_pull *ndr, int flags, struct lsa_CREDRWRITE *r)
12832 : {
12833 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12834 0 : if (flags & NDR_IN) {
12835 : }
12836 0 : if (flags & NDR_OUT) {
12837 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12838 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12839 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12840 : }
12841 0 : return NDR_ERR_SUCCESS;
12842 : }
12843 :
12844 0 : _PUBLIC_ void ndr_print_lsa_CREDRWRITE(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRWRITE *r)
12845 : {
12846 0 : ndr_print_struct(ndr, name, "lsa_CREDRWRITE");
12847 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12848 0 : ndr->depth++;
12849 0 : if (flags & NDR_SET_VALUES) {
12850 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12851 : }
12852 0 : if (flags & NDR_IN) {
12853 0 : ndr_print_struct(ndr, "in", "lsa_CREDRWRITE");
12854 0 : ndr->depth++;
12855 0 : ndr->depth--;
12856 : }
12857 0 : if (flags & NDR_OUT) {
12858 0 : ndr_print_struct(ndr, "out", "lsa_CREDRWRITE");
12859 0 : ndr->depth++;
12860 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12861 0 : ndr->depth--;
12862 : }
12863 0 : ndr->depth--;
12864 : }
12865 :
12866 0 : static enum ndr_err_code ndr_push_lsa_CREDRREAD(struct ndr_push *ndr, int flags, const struct lsa_CREDRREAD *r)
12867 : {
12868 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12869 0 : if (flags & NDR_IN) {
12870 : }
12871 0 : if (flags & NDR_OUT) {
12872 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12873 : }
12874 0 : return NDR_ERR_SUCCESS;
12875 : }
12876 :
12877 0 : static enum ndr_err_code ndr_pull_lsa_CREDRREAD(struct ndr_pull *ndr, int flags, struct lsa_CREDRREAD *r)
12878 : {
12879 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12880 0 : if (flags & NDR_IN) {
12881 : }
12882 0 : if (flags & NDR_OUT) {
12883 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12884 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12885 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12886 : }
12887 0 : return NDR_ERR_SUCCESS;
12888 : }
12889 :
12890 0 : _PUBLIC_ void ndr_print_lsa_CREDRREAD(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRREAD *r)
12891 : {
12892 0 : ndr_print_struct(ndr, name, "lsa_CREDRREAD");
12893 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12894 0 : ndr->depth++;
12895 0 : if (flags & NDR_SET_VALUES) {
12896 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12897 : }
12898 0 : if (flags & NDR_IN) {
12899 0 : ndr_print_struct(ndr, "in", "lsa_CREDRREAD");
12900 0 : ndr->depth++;
12901 0 : ndr->depth--;
12902 : }
12903 0 : if (flags & NDR_OUT) {
12904 0 : ndr_print_struct(ndr, "out", "lsa_CREDRREAD");
12905 0 : ndr->depth++;
12906 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12907 0 : ndr->depth--;
12908 : }
12909 0 : ndr->depth--;
12910 : }
12911 :
12912 0 : static enum ndr_err_code ndr_push_lsa_CREDRENUMERATE(struct ndr_push *ndr, int flags, const struct lsa_CREDRENUMERATE *r)
12913 : {
12914 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12915 0 : if (flags & NDR_IN) {
12916 : }
12917 0 : if (flags & NDR_OUT) {
12918 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12919 : }
12920 0 : return NDR_ERR_SUCCESS;
12921 : }
12922 :
12923 0 : static enum ndr_err_code ndr_pull_lsa_CREDRENUMERATE(struct ndr_pull *ndr, int flags, struct lsa_CREDRENUMERATE *r)
12924 : {
12925 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12926 0 : if (flags & NDR_IN) {
12927 : }
12928 0 : if (flags & NDR_OUT) {
12929 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12930 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12931 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12932 : }
12933 0 : return NDR_ERR_SUCCESS;
12934 : }
12935 :
12936 0 : _PUBLIC_ void ndr_print_lsa_CREDRENUMERATE(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRENUMERATE *r)
12937 : {
12938 0 : ndr_print_struct(ndr, name, "lsa_CREDRENUMERATE");
12939 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12940 0 : ndr->depth++;
12941 0 : if (flags & NDR_SET_VALUES) {
12942 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12943 : }
12944 0 : if (flags & NDR_IN) {
12945 0 : ndr_print_struct(ndr, "in", "lsa_CREDRENUMERATE");
12946 0 : ndr->depth++;
12947 0 : ndr->depth--;
12948 : }
12949 0 : if (flags & NDR_OUT) {
12950 0 : ndr_print_struct(ndr, "out", "lsa_CREDRENUMERATE");
12951 0 : ndr->depth++;
12952 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12953 0 : ndr->depth--;
12954 : }
12955 0 : ndr->depth--;
12956 : }
12957 :
12958 0 : static enum ndr_err_code ndr_push_lsa_CREDRWRITEDOMAINCREDENTIALS(struct ndr_push *ndr, int flags, const struct lsa_CREDRWRITEDOMAINCREDENTIALS *r)
12959 : {
12960 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12961 0 : if (flags & NDR_IN) {
12962 : }
12963 0 : if (flags & NDR_OUT) {
12964 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12965 : }
12966 0 : return NDR_ERR_SUCCESS;
12967 : }
12968 :
12969 0 : static enum ndr_err_code ndr_pull_lsa_CREDRWRITEDOMAINCREDENTIALS(struct ndr_pull *ndr, int flags, struct lsa_CREDRWRITEDOMAINCREDENTIALS *r)
12970 : {
12971 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12972 0 : if (flags & NDR_IN) {
12973 : }
12974 0 : if (flags & NDR_OUT) {
12975 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12976 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12977 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12978 : }
12979 0 : return NDR_ERR_SUCCESS;
12980 : }
12981 :
12982 0 : _PUBLIC_ void ndr_print_lsa_CREDRWRITEDOMAINCREDENTIALS(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRWRITEDOMAINCREDENTIALS *r)
12983 : {
12984 0 : ndr_print_struct(ndr, name, "lsa_CREDRWRITEDOMAINCREDENTIALS");
12985 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12986 0 : ndr->depth++;
12987 0 : if (flags & NDR_SET_VALUES) {
12988 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12989 : }
12990 0 : if (flags & NDR_IN) {
12991 0 : ndr_print_struct(ndr, "in", "lsa_CREDRWRITEDOMAINCREDENTIALS");
12992 0 : ndr->depth++;
12993 0 : ndr->depth--;
12994 : }
12995 0 : if (flags & NDR_OUT) {
12996 0 : ndr_print_struct(ndr, "out", "lsa_CREDRWRITEDOMAINCREDENTIALS");
12997 0 : ndr->depth++;
12998 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12999 0 : ndr->depth--;
13000 : }
13001 0 : ndr->depth--;
13002 : }
13003 :
13004 0 : static enum ndr_err_code ndr_push_lsa_CREDRREADDOMAINCREDENTIALS(struct ndr_push *ndr, int flags, const struct lsa_CREDRREADDOMAINCREDENTIALS *r)
13005 : {
13006 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13007 0 : if (flags & NDR_IN) {
13008 : }
13009 0 : if (flags & NDR_OUT) {
13010 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13011 : }
13012 0 : return NDR_ERR_SUCCESS;
13013 : }
13014 :
13015 0 : static enum ndr_err_code ndr_pull_lsa_CREDRREADDOMAINCREDENTIALS(struct ndr_pull *ndr, int flags, struct lsa_CREDRREADDOMAINCREDENTIALS *r)
13016 : {
13017 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13018 0 : if (flags & NDR_IN) {
13019 : }
13020 0 : if (flags & NDR_OUT) {
13021 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13022 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13023 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13024 : }
13025 0 : return NDR_ERR_SUCCESS;
13026 : }
13027 :
13028 0 : _PUBLIC_ void ndr_print_lsa_CREDRREADDOMAINCREDENTIALS(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRREADDOMAINCREDENTIALS *r)
13029 : {
13030 0 : ndr_print_struct(ndr, name, "lsa_CREDRREADDOMAINCREDENTIALS");
13031 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13032 0 : ndr->depth++;
13033 0 : if (flags & NDR_SET_VALUES) {
13034 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13035 : }
13036 0 : if (flags & NDR_IN) {
13037 0 : ndr_print_struct(ndr, "in", "lsa_CREDRREADDOMAINCREDENTIALS");
13038 0 : ndr->depth++;
13039 0 : ndr->depth--;
13040 : }
13041 0 : if (flags & NDR_OUT) {
13042 0 : ndr_print_struct(ndr, "out", "lsa_CREDRREADDOMAINCREDENTIALS");
13043 0 : ndr->depth++;
13044 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13045 0 : ndr->depth--;
13046 : }
13047 0 : ndr->depth--;
13048 : }
13049 :
13050 0 : static enum ndr_err_code ndr_push_lsa_CREDRDELETE(struct ndr_push *ndr, int flags, const struct lsa_CREDRDELETE *r)
13051 : {
13052 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13053 0 : if (flags & NDR_IN) {
13054 : }
13055 0 : if (flags & NDR_OUT) {
13056 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13057 : }
13058 0 : return NDR_ERR_SUCCESS;
13059 : }
13060 :
13061 0 : static enum ndr_err_code ndr_pull_lsa_CREDRDELETE(struct ndr_pull *ndr, int flags, struct lsa_CREDRDELETE *r)
13062 : {
13063 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13064 0 : if (flags & NDR_IN) {
13065 : }
13066 0 : if (flags & NDR_OUT) {
13067 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13068 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13069 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13070 : }
13071 0 : return NDR_ERR_SUCCESS;
13072 : }
13073 :
13074 0 : _PUBLIC_ void ndr_print_lsa_CREDRDELETE(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRDELETE *r)
13075 : {
13076 0 : ndr_print_struct(ndr, name, "lsa_CREDRDELETE");
13077 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13078 0 : ndr->depth++;
13079 0 : if (flags & NDR_SET_VALUES) {
13080 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13081 : }
13082 0 : if (flags & NDR_IN) {
13083 0 : ndr_print_struct(ndr, "in", "lsa_CREDRDELETE");
13084 0 : ndr->depth++;
13085 0 : ndr->depth--;
13086 : }
13087 0 : if (flags & NDR_OUT) {
13088 0 : ndr_print_struct(ndr, "out", "lsa_CREDRDELETE");
13089 0 : ndr->depth++;
13090 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13091 0 : ndr->depth--;
13092 : }
13093 0 : ndr->depth--;
13094 : }
13095 :
13096 0 : static enum ndr_err_code ndr_push_lsa_CREDRGETTARGETINFO(struct ndr_push *ndr, int flags, const struct lsa_CREDRGETTARGETINFO *r)
13097 : {
13098 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13099 0 : if (flags & NDR_IN) {
13100 : }
13101 0 : if (flags & NDR_OUT) {
13102 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13103 : }
13104 0 : return NDR_ERR_SUCCESS;
13105 : }
13106 :
13107 0 : static enum ndr_err_code ndr_pull_lsa_CREDRGETTARGETINFO(struct ndr_pull *ndr, int flags, struct lsa_CREDRGETTARGETINFO *r)
13108 : {
13109 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13110 0 : if (flags & NDR_IN) {
13111 : }
13112 0 : if (flags & NDR_OUT) {
13113 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13114 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13115 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13116 : }
13117 0 : return NDR_ERR_SUCCESS;
13118 : }
13119 :
13120 0 : _PUBLIC_ void ndr_print_lsa_CREDRGETTARGETINFO(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRGETTARGETINFO *r)
13121 : {
13122 0 : ndr_print_struct(ndr, name, "lsa_CREDRGETTARGETINFO");
13123 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13124 0 : ndr->depth++;
13125 0 : if (flags & NDR_SET_VALUES) {
13126 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13127 : }
13128 0 : if (flags & NDR_IN) {
13129 0 : ndr_print_struct(ndr, "in", "lsa_CREDRGETTARGETINFO");
13130 0 : ndr->depth++;
13131 0 : ndr->depth--;
13132 : }
13133 0 : if (flags & NDR_OUT) {
13134 0 : ndr_print_struct(ndr, "out", "lsa_CREDRGETTARGETINFO");
13135 0 : ndr->depth++;
13136 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13137 0 : ndr->depth--;
13138 : }
13139 0 : ndr->depth--;
13140 : }
13141 :
13142 0 : static enum ndr_err_code ndr_push_lsa_CREDRPROFILELOADED(struct ndr_push *ndr, int flags, const struct lsa_CREDRPROFILELOADED *r)
13143 : {
13144 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13145 0 : if (flags & NDR_IN) {
13146 : }
13147 0 : if (flags & NDR_OUT) {
13148 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13149 : }
13150 0 : return NDR_ERR_SUCCESS;
13151 : }
13152 :
13153 0 : static enum ndr_err_code ndr_pull_lsa_CREDRPROFILELOADED(struct ndr_pull *ndr, int flags, struct lsa_CREDRPROFILELOADED *r)
13154 : {
13155 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13156 0 : if (flags & NDR_IN) {
13157 : }
13158 0 : if (flags & NDR_OUT) {
13159 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13160 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13161 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13162 : }
13163 0 : return NDR_ERR_SUCCESS;
13164 : }
13165 :
13166 0 : _PUBLIC_ void ndr_print_lsa_CREDRPROFILELOADED(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRPROFILELOADED *r)
13167 : {
13168 0 : ndr_print_struct(ndr, name, "lsa_CREDRPROFILELOADED");
13169 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13170 0 : ndr->depth++;
13171 0 : if (flags & NDR_SET_VALUES) {
13172 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13173 : }
13174 0 : if (flags & NDR_IN) {
13175 0 : ndr_print_struct(ndr, "in", "lsa_CREDRPROFILELOADED");
13176 0 : ndr->depth++;
13177 0 : ndr->depth--;
13178 : }
13179 0 : if (flags & NDR_OUT) {
13180 0 : ndr_print_struct(ndr, "out", "lsa_CREDRPROFILELOADED");
13181 0 : ndr->depth++;
13182 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13183 0 : ndr->depth--;
13184 : }
13185 0 : ndr->depth--;
13186 : }
13187 :
13188 18 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupNames3(struct ndr_push *ndr, int flags, const struct lsa_LookupNames3 *r)
13189 : {
13190 : uint32_t cntr_names_0;
13191 18 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13192 18 : if (flags & NDR_IN) {
13193 8 : if (r->in.handle == NULL) {
13194 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13195 : }
13196 8 : if (r->in.sids == NULL) {
13197 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13198 : }
13199 8 : if (r->in.count == NULL) {
13200 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13201 : }
13202 8 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
13203 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_names));
13204 8 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.num_names));
13205 36 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
13206 28 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
13207 : }
13208 36 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
13209 28 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
13210 : }
13211 8 : NDR_CHECK(ndr_push_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
13212 8 : NDR_CHECK(ndr_push_lsa_LookupNamesLevel(ndr, NDR_SCALARS, r->in.level));
13213 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
13214 8 : NDR_CHECK(ndr_push_lsa_LookupOptions(ndr, NDR_SCALARS, r->in.lookup_options));
13215 8 : NDR_CHECK(ndr_push_lsa_ClientRevision(ndr, NDR_SCALARS, r->in.client_revision));
13216 : }
13217 18 : if (flags & NDR_OUT) {
13218 10 : if (r->out.domains == NULL) {
13219 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13220 : }
13221 10 : if (r->out.sids == NULL) {
13222 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13223 : }
13224 10 : if (r->out.count == NULL) {
13225 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13226 : }
13227 10 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
13228 10 : if (*r->out.domains) {
13229 10 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
13230 : }
13231 10 : NDR_CHECK(ndr_push_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
13232 10 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
13233 10 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13234 : }
13235 18 : return NDR_ERR_SUCCESS;
13236 : }
13237 :
13238 16 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupNames3(struct ndr_pull *ndr, int flags, struct lsa_LookupNames3 *r)
13239 : {
13240 16 : uint32_t size_names_0 = 0;
13241 : uint32_t cntr_names_0;
13242 : uint32_t _ptr_domains;
13243 16 : TALLOC_CTX *_mem_save_handle_0 = NULL;
13244 16 : TALLOC_CTX *_mem_save_names_0 = NULL;
13245 16 : TALLOC_CTX *_mem_save_domains_0 = NULL;
13246 16 : TALLOC_CTX *_mem_save_domains_1 = NULL;
13247 16 : TALLOC_CTX *_mem_save_sids_0 = NULL;
13248 16 : TALLOC_CTX *_mem_save_count_0 = NULL;
13249 16 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13250 16 : if (flags & NDR_IN) {
13251 8 : NDR_ZERO_STRUCT(r->out);
13252 :
13253 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13254 8 : NDR_PULL_ALLOC(ndr, r->in.handle);
13255 : }
13256 8 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
13257 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
13258 8 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
13259 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
13260 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_names));
13261 8 : if (r->in.num_names > 1000) {
13262 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
13263 : }
13264 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.names));
13265 8 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.names, &size_names_0));
13266 8 : NDR_PULL_ALLOC_N(ndr, r->in.names, size_names_0);
13267 8 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
13268 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, 0);
13269 36 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
13270 28 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
13271 : }
13272 36 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
13273 28 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
13274 : }
13275 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
13276 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13277 8 : NDR_PULL_ALLOC(ndr, r->in.sids);
13278 : }
13279 8 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
13280 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
13281 8 : NDR_CHECK(ndr_pull_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
13282 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
13283 8 : NDR_CHECK(ndr_pull_lsa_LookupNamesLevel(ndr, NDR_SCALARS, &r->in.level));
13284 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13285 8 : NDR_PULL_ALLOC(ndr, r->in.count);
13286 : }
13287 8 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
13288 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
13289 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
13290 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
13291 8 : NDR_CHECK(ndr_pull_lsa_LookupOptions(ndr, NDR_SCALARS, &r->in.lookup_options));
13292 8 : NDR_CHECK(ndr_pull_lsa_ClientRevision(ndr, NDR_SCALARS, &r->in.client_revision));
13293 8 : NDR_PULL_ALLOC(ndr, r->out.domains);
13294 8 : NDR_ZERO_STRUCTP(r->out.domains);
13295 8 : NDR_PULL_ALLOC(ndr, r->out.sids);
13296 8 : *r->out.sids = *r->in.sids;
13297 8 : NDR_PULL_ALLOC(ndr, r->out.count);
13298 8 : *r->out.count = *r->in.count;
13299 8 : if (r->in.names) {
13300 8 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.names, r->in.num_names));
13301 : }
13302 8 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
13303 : }
13304 : }
13305 16 : if (flags & NDR_OUT) {
13306 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13307 : if (r->in.handle == NULL) {
13308 : NDR_PULL_ALLOC(ndr, r->in.handle);
13309 : NDR_ZERO_STRUCTP(r->in.handle);
13310 : }
13311 : if (r->in.sids == NULL) {
13312 : NDR_PULL_ALLOC(ndr, r->in.sids);
13313 : NDR_ZERO_STRUCTP(r->in.sids);
13314 : }
13315 : if (r->in.count == NULL) {
13316 : NDR_PULL_ALLOC(ndr, r->in.count);
13317 : NDR_ZERO_STRUCTP(r->in.count);
13318 : }
13319 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13320 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13321 2 : NDR_PULL_ALLOC(ndr, r->out.domains);
13322 : }
13323 8 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
13324 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
13325 8 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
13326 8 : if (_ptr_domains) {
13327 8 : NDR_PULL_ALLOC(ndr, *r->out.domains);
13328 : } else {
13329 0 : *r->out.domains = NULL;
13330 : }
13331 8 : if (*r->out.domains) {
13332 8 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
13333 8 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
13334 8 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
13335 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
13336 : }
13337 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
13338 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13339 2 : NDR_PULL_ALLOC(ndr, r->out.sids);
13340 : }
13341 8 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
13342 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
13343 8 : NDR_CHECK(ndr_pull_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
13344 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
13345 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13346 2 : NDR_PULL_ALLOC(ndr, r->out.count);
13347 : }
13348 8 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
13349 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
13350 8 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
13351 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
13352 8 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13353 : }
13354 16 : return NDR_ERR_SUCCESS;
13355 : }
13356 :
13357 4 : _PUBLIC_ void ndr_print_lsa_LookupNames3(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupNames3 *r)
13358 : {
13359 : uint32_t cntr_names_0;
13360 4 : ndr_print_struct(ndr, name, "lsa_LookupNames3");
13361 4 : if (r == NULL) { ndr_print_null(ndr); return; }
13362 4 : ndr->depth++;
13363 4 : if (flags & NDR_SET_VALUES) {
13364 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13365 : }
13366 4 : if (flags & NDR_IN) {
13367 0 : ndr_print_struct(ndr, "in", "lsa_LookupNames3");
13368 0 : ndr->depth++;
13369 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
13370 0 : ndr->depth++;
13371 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
13372 0 : ndr->depth--;
13373 0 : ndr_print_uint32(ndr, "num_names", r->in.num_names);
13374 0 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->in.num_names);
13375 0 : ndr->depth++;
13376 0 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
13377 0 : ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
13378 : }
13379 0 : ndr->depth--;
13380 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
13381 0 : ndr->depth++;
13382 0 : ndr_print_lsa_TransSidArray3(ndr, "sids", r->in.sids);
13383 0 : ndr->depth--;
13384 0 : ndr_print_lsa_LookupNamesLevel(ndr, "level", r->in.level);
13385 0 : ndr_print_ptr(ndr, "count", r->in.count);
13386 0 : ndr->depth++;
13387 0 : ndr_print_uint32(ndr, "count", *r->in.count);
13388 0 : ndr->depth--;
13389 0 : ndr_print_lsa_LookupOptions(ndr, "lookup_options", r->in.lookup_options);
13390 0 : ndr_print_lsa_ClientRevision(ndr, "client_revision", r->in.client_revision);
13391 0 : ndr->depth--;
13392 : }
13393 4 : if (flags & NDR_OUT) {
13394 4 : ndr_print_struct(ndr, "out", "lsa_LookupNames3");
13395 4 : ndr->depth++;
13396 4 : ndr_print_ptr(ndr, "domains", r->out.domains);
13397 4 : ndr->depth++;
13398 4 : ndr_print_ptr(ndr, "domains", *r->out.domains);
13399 4 : ndr->depth++;
13400 4 : if (*r->out.domains) {
13401 4 : ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
13402 : }
13403 4 : ndr->depth--;
13404 4 : ndr->depth--;
13405 4 : ndr_print_ptr(ndr, "sids", r->out.sids);
13406 4 : ndr->depth++;
13407 4 : ndr_print_lsa_TransSidArray3(ndr, "sids", r->out.sids);
13408 4 : ndr->depth--;
13409 4 : ndr_print_ptr(ndr, "count", r->out.count);
13410 4 : ndr->depth++;
13411 4 : ndr_print_uint32(ndr, "count", *r->out.count);
13412 4 : ndr->depth--;
13413 4 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13414 4 : ndr->depth--;
13415 : }
13416 4 : ndr->depth--;
13417 : }
13418 :
13419 0 : static enum ndr_err_code ndr_push_lsa_CREDRGETSESSIONTYPES(struct ndr_push *ndr, int flags, const struct lsa_CREDRGETSESSIONTYPES *r)
13420 : {
13421 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13422 0 : if (flags & NDR_IN) {
13423 : }
13424 0 : if (flags & NDR_OUT) {
13425 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13426 : }
13427 0 : return NDR_ERR_SUCCESS;
13428 : }
13429 :
13430 0 : static enum ndr_err_code ndr_pull_lsa_CREDRGETSESSIONTYPES(struct ndr_pull *ndr, int flags, struct lsa_CREDRGETSESSIONTYPES *r)
13431 : {
13432 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13433 0 : if (flags & NDR_IN) {
13434 : }
13435 0 : if (flags & NDR_OUT) {
13436 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13437 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13438 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13439 : }
13440 0 : return NDR_ERR_SUCCESS;
13441 : }
13442 :
13443 0 : _PUBLIC_ void ndr_print_lsa_CREDRGETSESSIONTYPES(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRGETSESSIONTYPES *r)
13444 : {
13445 0 : ndr_print_struct(ndr, name, "lsa_CREDRGETSESSIONTYPES");
13446 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13447 0 : ndr->depth++;
13448 0 : if (flags & NDR_SET_VALUES) {
13449 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13450 : }
13451 0 : if (flags & NDR_IN) {
13452 0 : ndr_print_struct(ndr, "in", "lsa_CREDRGETSESSIONTYPES");
13453 0 : ndr->depth++;
13454 0 : ndr->depth--;
13455 : }
13456 0 : if (flags & NDR_OUT) {
13457 0 : ndr_print_struct(ndr, "out", "lsa_CREDRGETSESSIONTYPES");
13458 0 : ndr->depth++;
13459 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13460 0 : ndr->depth--;
13461 : }
13462 0 : ndr->depth--;
13463 : }
13464 :
13465 0 : static enum ndr_err_code ndr_push_lsa_LSARREGISTERAUDITEVENT(struct ndr_push *ndr, int flags, const struct lsa_LSARREGISTERAUDITEVENT *r)
13466 : {
13467 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13468 0 : if (flags & NDR_IN) {
13469 : }
13470 0 : if (flags & NDR_OUT) {
13471 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13472 : }
13473 0 : return NDR_ERR_SUCCESS;
13474 : }
13475 :
13476 0 : static enum ndr_err_code ndr_pull_lsa_LSARREGISTERAUDITEVENT(struct ndr_pull *ndr, int flags, struct lsa_LSARREGISTERAUDITEVENT *r)
13477 : {
13478 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13479 0 : if (flags & NDR_IN) {
13480 : }
13481 0 : if (flags & NDR_OUT) {
13482 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13483 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13484 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13485 : }
13486 0 : return NDR_ERR_SUCCESS;
13487 : }
13488 :
13489 0 : _PUBLIC_ void ndr_print_lsa_LSARREGISTERAUDITEVENT(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARREGISTERAUDITEVENT *r)
13490 : {
13491 0 : ndr_print_struct(ndr, name, "lsa_LSARREGISTERAUDITEVENT");
13492 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13493 0 : ndr->depth++;
13494 0 : if (flags & NDR_SET_VALUES) {
13495 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13496 : }
13497 0 : if (flags & NDR_IN) {
13498 0 : ndr_print_struct(ndr, "in", "lsa_LSARREGISTERAUDITEVENT");
13499 0 : ndr->depth++;
13500 0 : ndr->depth--;
13501 : }
13502 0 : if (flags & NDR_OUT) {
13503 0 : ndr_print_struct(ndr, "out", "lsa_LSARREGISTERAUDITEVENT");
13504 0 : ndr->depth++;
13505 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13506 0 : ndr->depth--;
13507 : }
13508 0 : ndr->depth--;
13509 : }
13510 :
13511 0 : static enum ndr_err_code ndr_push_lsa_LSARGENAUDITEVENT(struct ndr_push *ndr, int flags, const struct lsa_LSARGENAUDITEVENT *r)
13512 : {
13513 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13514 0 : if (flags & NDR_IN) {
13515 : }
13516 0 : if (flags & NDR_OUT) {
13517 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13518 : }
13519 0 : return NDR_ERR_SUCCESS;
13520 : }
13521 :
13522 0 : static enum ndr_err_code ndr_pull_lsa_LSARGENAUDITEVENT(struct ndr_pull *ndr, int flags, struct lsa_LSARGENAUDITEVENT *r)
13523 : {
13524 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13525 0 : if (flags & NDR_IN) {
13526 : }
13527 0 : if (flags & NDR_OUT) {
13528 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13529 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13530 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13531 : }
13532 0 : return NDR_ERR_SUCCESS;
13533 : }
13534 :
13535 0 : _PUBLIC_ void ndr_print_lsa_LSARGENAUDITEVENT(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARGENAUDITEVENT *r)
13536 : {
13537 0 : ndr_print_struct(ndr, name, "lsa_LSARGENAUDITEVENT");
13538 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13539 0 : ndr->depth++;
13540 0 : if (flags & NDR_SET_VALUES) {
13541 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13542 : }
13543 0 : if (flags & NDR_IN) {
13544 0 : ndr_print_struct(ndr, "in", "lsa_LSARGENAUDITEVENT");
13545 0 : ndr->depth++;
13546 0 : ndr->depth--;
13547 : }
13548 0 : if (flags & NDR_OUT) {
13549 0 : ndr_print_struct(ndr, "out", "lsa_LSARGENAUDITEVENT");
13550 0 : ndr->depth++;
13551 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13552 0 : ndr->depth--;
13553 : }
13554 0 : ndr->depth--;
13555 : }
13556 :
13557 0 : static enum ndr_err_code ndr_push_lsa_LSARUNREGISTERAUDITEVENT(struct ndr_push *ndr, int flags, const struct lsa_LSARUNREGISTERAUDITEVENT *r)
13558 : {
13559 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13560 0 : if (flags & NDR_IN) {
13561 : }
13562 0 : if (flags & NDR_OUT) {
13563 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13564 : }
13565 0 : return NDR_ERR_SUCCESS;
13566 : }
13567 :
13568 0 : static enum ndr_err_code ndr_pull_lsa_LSARUNREGISTERAUDITEVENT(struct ndr_pull *ndr, int flags, struct lsa_LSARUNREGISTERAUDITEVENT *r)
13569 : {
13570 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13571 0 : if (flags & NDR_IN) {
13572 : }
13573 0 : if (flags & NDR_OUT) {
13574 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13575 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13576 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13577 : }
13578 0 : return NDR_ERR_SUCCESS;
13579 : }
13580 :
13581 0 : _PUBLIC_ void ndr_print_lsa_LSARUNREGISTERAUDITEVENT(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARUNREGISTERAUDITEVENT *r)
13582 : {
13583 0 : ndr_print_struct(ndr, name, "lsa_LSARUNREGISTERAUDITEVENT");
13584 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13585 0 : ndr->depth++;
13586 0 : if (flags & NDR_SET_VALUES) {
13587 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13588 : }
13589 0 : if (flags & NDR_IN) {
13590 0 : ndr_print_struct(ndr, "in", "lsa_LSARUNREGISTERAUDITEVENT");
13591 0 : ndr->depth++;
13592 0 : ndr->depth--;
13593 : }
13594 0 : if (flags & NDR_OUT) {
13595 0 : ndr_print_struct(ndr, "out", "lsa_LSARUNREGISTERAUDITEVENT");
13596 0 : ndr->depth++;
13597 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13598 0 : ndr->depth--;
13599 : }
13600 0 : ndr->depth--;
13601 : }
13602 :
13603 288 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_lsaRQueryForestTrustInformation(struct ndr_push *ndr, int flags, const struct lsa_lsaRQueryForestTrustInformation *r)
13604 : {
13605 288 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13606 288 : if (flags & NDR_IN) {
13607 124 : if (r->in.handle == NULL) {
13608 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13609 : }
13610 124 : if (r->in.trusted_domain_name == NULL) {
13611 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13612 : }
13613 124 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
13614 124 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain_name));
13615 124 : NDR_CHECK(ndr_push_lsa_ForestTrustRecordType(ndr, NDR_SCALARS, r->in.highest_record_type));
13616 : }
13617 288 : if (flags & NDR_OUT) {
13618 164 : if (r->out.forest_trust_info == NULL) {
13619 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13620 : }
13621 164 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.forest_trust_info));
13622 164 : if (*r->out.forest_trust_info) {
13623 156 : NDR_CHECK(ndr_push_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.forest_trust_info));
13624 : }
13625 164 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13626 : }
13627 288 : return NDR_ERR_SUCCESS;
13628 : }
13629 :
13630 288 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_lsaRQueryForestTrustInformation(struct ndr_pull *ndr, int flags, struct lsa_lsaRQueryForestTrustInformation *r)
13631 : {
13632 : uint32_t _ptr_forest_trust_info;
13633 288 : TALLOC_CTX *_mem_save_handle_0 = NULL;
13634 288 : TALLOC_CTX *_mem_save_trusted_domain_name_0 = NULL;
13635 288 : TALLOC_CTX *_mem_save_forest_trust_info_0 = NULL;
13636 288 : TALLOC_CTX *_mem_save_forest_trust_info_1 = NULL;
13637 288 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13638 288 : if (flags & NDR_IN) {
13639 164 : NDR_ZERO_STRUCT(r->out);
13640 :
13641 164 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13642 164 : NDR_PULL_ALLOC(ndr, r->in.handle);
13643 : }
13644 164 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
13645 164 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
13646 164 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
13647 164 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
13648 164 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13649 164 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain_name);
13650 : }
13651 164 : _mem_save_trusted_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
13652 164 : NDR_PULL_SET_MEM_CTX(ndr, r->in.trusted_domain_name, LIBNDR_FLAG_REF_ALLOC);
13653 164 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain_name));
13654 164 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trusted_domain_name_0, LIBNDR_FLAG_REF_ALLOC);
13655 164 : NDR_CHECK(ndr_pull_lsa_ForestTrustRecordType(ndr, NDR_SCALARS, &r->in.highest_record_type));
13656 164 : NDR_PULL_ALLOC(ndr, r->out.forest_trust_info);
13657 164 : NDR_ZERO_STRUCTP(r->out.forest_trust_info);
13658 : }
13659 288 : if (flags & NDR_OUT) {
13660 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13661 : if (r->in.handle == NULL) {
13662 : NDR_PULL_ALLOC(ndr, r->in.handle);
13663 : NDR_ZERO_STRUCTP(r->in.handle);
13664 : }
13665 : if (r->in.trusted_domain_name == NULL) {
13666 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain_name);
13667 : NDR_ZERO_STRUCTP(r->in.trusted_domain_name);
13668 : }
13669 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13670 124 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13671 124 : NDR_PULL_ALLOC(ndr, r->out.forest_trust_info);
13672 : }
13673 124 : _mem_save_forest_trust_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
13674 124 : NDR_PULL_SET_MEM_CTX(ndr, r->out.forest_trust_info, LIBNDR_FLAG_REF_ALLOC);
13675 124 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_forest_trust_info));
13676 124 : if (_ptr_forest_trust_info) {
13677 124 : NDR_PULL_ALLOC(ndr, *r->out.forest_trust_info);
13678 : } else {
13679 0 : *r->out.forest_trust_info = NULL;
13680 : }
13681 124 : if (*r->out.forest_trust_info) {
13682 124 : _mem_save_forest_trust_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
13683 124 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.forest_trust_info, 0);
13684 124 : NDR_CHECK(ndr_pull_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.forest_trust_info));
13685 124 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_trust_info_1, 0);
13686 : }
13687 124 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_trust_info_0, LIBNDR_FLAG_REF_ALLOC);
13688 124 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13689 : }
13690 288 : return NDR_ERR_SUCCESS;
13691 : }
13692 :
13693 0 : _PUBLIC_ void ndr_print_lsa_lsaRQueryForestTrustInformation(struct ndr_print *ndr, const char *name, int flags, const struct lsa_lsaRQueryForestTrustInformation *r)
13694 : {
13695 0 : ndr_print_struct(ndr, name, "lsa_lsaRQueryForestTrustInformation");
13696 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13697 0 : ndr->depth++;
13698 0 : if (flags & NDR_SET_VALUES) {
13699 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13700 : }
13701 0 : if (flags & NDR_IN) {
13702 0 : ndr_print_struct(ndr, "in", "lsa_lsaRQueryForestTrustInformation");
13703 0 : ndr->depth++;
13704 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
13705 0 : ndr->depth++;
13706 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
13707 0 : ndr->depth--;
13708 0 : ndr_print_ptr(ndr, "trusted_domain_name", r->in.trusted_domain_name);
13709 0 : ndr->depth++;
13710 0 : ndr_print_lsa_String(ndr, "trusted_domain_name", r->in.trusted_domain_name);
13711 0 : ndr->depth--;
13712 0 : ndr_print_lsa_ForestTrustRecordType(ndr, "highest_record_type", r->in.highest_record_type);
13713 0 : ndr->depth--;
13714 : }
13715 0 : if (flags & NDR_OUT) {
13716 0 : ndr_print_struct(ndr, "out", "lsa_lsaRQueryForestTrustInformation");
13717 0 : ndr->depth++;
13718 0 : ndr_print_ptr(ndr, "forest_trust_info", r->out.forest_trust_info);
13719 0 : ndr->depth++;
13720 0 : ndr_print_ptr(ndr, "forest_trust_info", *r->out.forest_trust_info);
13721 0 : ndr->depth++;
13722 0 : if (*r->out.forest_trust_info) {
13723 0 : ndr_print_lsa_ForestTrustInformation(ndr, "forest_trust_info", *r->out.forest_trust_info);
13724 : }
13725 0 : ndr->depth--;
13726 0 : ndr->depth--;
13727 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13728 0 : ndr->depth--;
13729 : }
13730 0 : ndr->depth--;
13731 : }
13732 :
13733 161 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_lsaRSetForestTrustInformation(struct ndr_push *ndr, int flags, const struct lsa_lsaRSetForestTrustInformation *r)
13734 : {
13735 161 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13736 161 : if (flags & NDR_IN) {
13737 72 : if (r->in.handle == NULL) {
13738 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13739 : }
13740 72 : if (r->in.trusted_domain_name == NULL) {
13741 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13742 : }
13743 72 : if (r->in.forest_trust_info == NULL) {
13744 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13745 : }
13746 72 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
13747 72 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain_name));
13748 72 : NDR_CHECK(ndr_push_lsa_ForestTrustRecordType(ndr, NDR_SCALARS, r->in.highest_record_type));
13749 72 : NDR_CHECK(ndr_push_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.forest_trust_info));
13750 72 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.check_only));
13751 : }
13752 161 : if (flags & NDR_OUT) {
13753 89 : if (r->out.collision_info == NULL) {
13754 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13755 : }
13756 89 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.collision_info));
13757 89 : if (*r->out.collision_info) {
13758 20 : NDR_CHECK(ndr_push_lsa_ForestTrustCollisionInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.collision_info));
13759 : }
13760 89 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13761 : }
13762 161 : return NDR_ERR_SUCCESS;
13763 : }
13764 :
13765 160 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_lsaRSetForestTrustInformation(struct ndr_pull *ndr, int flags, struct lsa_lsaRSetForestTrustInformation *r)
13766 : {
13767 : uint32_t _ptr_collision_info;
13768 160 : TALLOC_CTX *_mem_save_handle_0 = NULL;
13769 160 : TALLOC_CTX *_mem_save_trusted_domain_name_0 = NULL;
13770 160 : TALLOC_CTX *_mem_save_forest_trust_info_0 = NULL;
13771 160 : TALLOC_CTX *_mem_save_collision_info_0 = NULL;
13772 160 : TALLOC_CTX *_mem_save_collision_info_1 = NULL;
13773 160 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13774 160 : if (flags & NDR_IN) {
13775 88 : NDR_ZERO_STRUCT(r->out);
13776 :
13777 88 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13778 88 : NDR_PULL_ALLOC(ndr, r->in.handle);
13779 : }
13780 88 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
13781 88 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
13782 88 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
13783 88 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
13784 88 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13785 88 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain_name);
13786 : }
13787 88 : _mem_save_trusted_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
13788 88 : NDR_PULL_SET_MEM_CTX(ndr, r->in.trusted_domain_name, LIBNDR_FLAG_REF_ALLOC);
13789 88 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.trusted_domain_name));
13790 88 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trusted_domain_name_0, LIBNDR_FLAG_REF_ALLOC);
13791 88 : NDR_CHECK(ndr_pull_lsa_ForestTrustRecordType(ndr, NDR_SCALARS, &r->in.highest_record_type));
13792 88 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13793 88 : NDR_PULL_ALLOC(ndr, r->in.forest_trust_info);
13794 : }
13795 88 : _mem_save_forest_trust_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
13796 88 : NDR_PULL_SET_MEM_CTX(ndr, r->in.forest_trust_info, LIBNDR_FLAG_REF_ALLOC);
13797 88 : NDR_CHECK(ndr_pull_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.forest_trust_info));
13798 88 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_trust_info_0, LIBNDR_FLAG_REF_ALLOC);
13799 88 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.check_only));
13800 88 : NDR_PULL_ALLOC(ndr, r->out.collision_info);
13801 88 : NDR_ZERO_STRUCTP(r->out.collision_info);
13802 : }
13803 160 : if (flags & NDR_OUT) {
13804 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13805 : if (r->in.handle == NULL) {
13806 : NDR_PULL_ALLOC(ndr, r->in.handle);
13807 : NDR_ZERO_STRUCTP(r->in.handle);
13808 : }
13809 : if (r->in.trusted_domain_name == NULL) {
13810 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain_name);
13811 : NDR_ZERO_STRUCTP(r->in.trusted_domain_name);
13812 : }
13813 : if (r->in.forest_trust_info == NULL) {
13814 : NDR_PULL_ALLOC(ndr, r->in.forest_trust_info);
13815 : NDR_ZERO_STRUCTP(r->in.forest_trust_info);
13816 : }
13817 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13818 72 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13819 69 : NDR_PULL_ALLOC(ndr, r->out.collision_info);
13820 : }
13821 72 : _mem_save_collision_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
13822 72 : NDR_PULL_SET_MEM_CTX(ndr, r->out.collision_info, LIBNDR_FLAG_REF_ALLOC);
13823 72 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_collision_info));
13824 72 : if (_ptr_collision_info) {
13825 16 : NDR_PULL_ALLOC(ndr, *r->out.collision_info);
13826 : } else {
13827 56 : *r->out.collision_info = NULL;
13828 : }
13829 72 : if (*r->out.collision_info) {
13830 16 : _mem_save_collision_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
13831 16 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.collision_info, 0);
13832 16 : NDR_CHECK(ndr_pull_lsa_ForestTrustCollisionInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.collision_info));
13833 16 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_collision_info_1, 0);
13834 : }
13835 72 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_collision_info_0, LIBNDR_FLAG_REF_ALLOC);
13836 72 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13837 : }
13838 160 : return NDR_ERR_SUCCESS;
13839 : }
13840 :
13841 2 : _PUBLIC_ void ndr_print_lsa_lsaRSetForestTrustInformation(struct ndr_print *ndr, const char *name, int flags, const struct lsa_lsaRSetForestTrustInformation *r)
13842 : {
13843 2 : ndr_print_struct(ndr, name, "lsa_lsaRSetForestTrustInformation");
13844 2 : if (r == NULL) { ndr_print_null(ndr); return; }
13845 2 : ndr->depth++;
13846 2 : if (flags & NDR_SET_VALUES) {
13847 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13848 : }
13849 2 : if (flags & NDR_IN) {
13850 0 : ndr_print_struct(ndr, "in", "lsa_lsaRSetForestTrustInformation");
13851 0 : ndr->depth++;
13852 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
13853 0 : ndr->depth++;
13854 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
13855 0 : ndr->depth--;
13856 0 : ndr_print_ptr(ndr, "trusted_domain_name", r->in.trusted_domain_name);
13857 0 : ndr->depth++;
13858 0 : ndr_print_lsa_StringLarge(ndr, "trusted_domain_name", r->in.trusted_domain_name);
13859 0 : ndr->depth--;
13860 0 : ndr_print_lsa_ForestTrustRecordType(ndr, "highest_record_type", r->in.highest_record_type);
13861 0 : ndr_print_ptr(ndr, "forest_trust_info", r->in.forest_trust_info);
13862 0 : ndr->depth++;
13863 0 : ndr_print_lsa_ForestTrustInformation(ndr, "forest_trust_info", r->in.forest_trust_info);
13864 0 : ndr->depth--;
13865 0 : ndr_print_uint8(ndr, "check_only", r->in.check_only);
13866 0 : ndr->depth--;
13867 : }
13868 2 : if (flags & NDR_OUT) {
13869 2 : ndr_print_struct(ndr, "out", "lsa_lsaRSetForestTrustInformation");
13870 2 : ndr->depth++;
13871 2 : ndr_print_ptr(ndr, "collision_info", r->out.collision_info);
13872 2 : ndr->depth++;
13873 2 : ndr_print_ptr(ndr, "collision_info", *r->out.collision_info);
13874 2 : ndr->depth++;
13875 2 : if (*r->out.collision_info) {
13876 0 : ndr_print_lsa_ForestTrustCollisionInfo(ndr, "collision_info", *r->out.collision_info);
13877 : }
13878 2 : ndr->depth--;
13879 2 : ndr->depth--;
13880 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13881 2 : ndr->depth--;
13882 : }
13883 2 : ndr->depth--;
13884 : }
13885 :
13886 0 : static enum ndr_err_code ndr_push_lsa_CREDRRENAME(struct ndr_push *ndr, int flags, const struct lsa_CREDRRENAME *r)
13887 : {
13888 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13889 0 : if (flags & NDR_IN) {
13890 : }
13891 0 : if (flags & NDR_OUT) {
13892 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13893 : }
13894 0 : return NDR_ERR_SUCCESS;
13895 : }
13896 :
13897 0 : static enum ndr_err_code ndr_pull_lsa_CREDRRENAME(struct ndr_pull *ndr, int flags, struct lsa_CREDRRENAME *r)
13898 : {
13899 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13900 0 : if (flags & NDR_IN) {
13901 : }
13902 0 : if (flags & NDR_OUT) {
13903 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13904 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13905 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13906 : }
13907 0 : return NDR_ERR_SUCCESS;
13908 : }
13909 :
13910 0 : _PUBLIC_ void ndr_print_lsa_CREDRRENAME(struct ndr_print *ndr, const char *name, int flags, const struct lsa_CREDRRENAME *r)
13911 : {
13912 0 : ndr_print_struct(ndr, name, "lsa_CREDRRENAME");
13913 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13914 0 : ndr->depth++;
13915 0 : if (flags & NDR_SET_VALUES) {
13916 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13917 : }
13918 0 : if (flags & NDR_IN) {
13919 0 : ndr_print_struct(ndr, "in", "lsa_CREDRRENAME");
13920 0 : ndr->depth++;
13921 0 : ndr->depth--;
13922 : }
13923 0 : if (flags & NDR_OUT) {
13924 0 : ndr_print_struct(ndr, "out", "lsa_CREDRRENAME");
13925 0 : ndr->depth++;
13926 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13927 0 : ndr->depth--;
13928 : }
13929 0 : ndr->depth--;
13930 : }
13931 :
13932 1259 : _PUBLIC_ enum ndr_err_code ndr_push_lsa_LookupSids3(struct ndr_push *ndr, int flags, const struct lsa_LookupSids3 *r)
13933 : {
13934 1259 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13935 1259 : if (flags & NDR_IN) {
13936 181 : if (r->in.sids == NULL) {
13937 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13938 : }
13939 181 : if (r->in.names == NULL) {
13940 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13941 : }
13942 181 : if (r->in.count == NULL) {
13943 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13944 : }
13945 181 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
13946 181 : NDR_CHECK(ndr_push_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.names));
13947 181 : NDR_CHECK(ndr_push_lsa_LookupNamesLevel(ndr, NDR_SCALARS, r->in.level));
13948 181 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
13949 181 : NDR_CHECK(ndr_push_lsa_LookupOptions(ndr, NDR_SCALARS, r->in.lookup_options));
13950 181 : NDR_CHECK(ndr_push_lsa_ClientRevision(ndr, NDR_SCALARS, r->in.client_revision));
13951 : }
13952 1259 : if (flags & NDR_OUT) {
13953 1078 : if (r->out.domains == NULL) {
13954 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13955 : }
13956 1078 : if (r->out.names == NULL) {
13957 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13958 : }
13959 1078 : if (r->out.count == NULL) {
13960 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13961 : }
13962 1078 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
13963 1078 : if (*r->out.domains) {
13964 1078 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
13965 : }
13966 1078 : NDR_CHECK(ndr_push_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
13967 1078 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
13968 1078 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13969 : }
13970 1259 : return NDR_ERR_SUCCESS;
13971 : }
13972 :
13973 1223 : _PUBLIC_ enum ndr_err_code ndr_pull_lsa_LookupSids3(struct ndr_pull *ndr, int flags, struct lsa_LookupSids3 *r)
13974 : {
13975 : uint32_t _ptr_domains;
13976 1223 : TALLOC_CTX *_mem_save_sids_0 = NULL;
13977 1223 : TALLOC_CTX *_mem_save_domains_0 = NULL;
13978 1223 : TALLOC_CTX *_mem_save_domains_1 = NULL;
13979 1223 : TALLOC_CTX *_mem_save_names_0 = NULL;
13980 1223 : TALLOC_CTX *_mem_save_count_0 = NULL;
13981 1223 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13982 1223 : if (flags & NDR_IN) {
13983 1051 : NDR_ZERO_STRUCT(r->out);
13984 :
13985 1051 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13986 1051 : NDR_PULL_ALLOC(ndr, r->in.sids);
13987 : }
13988 1051 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
13989 1051 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
13990 1051 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
13991 1051 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
13992 1051 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13993 1051 : NDR_PULL_ALLOC(ndr, r->in.names);
13994 : }
13995 1051 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
13996 1051 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, LIBNDR_FLAG_REF_ALLOC);
13997 1051 : NDR_CHECK(ndr_pull_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.names));
13998 1051 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
13999 1051 : NDR_CHECK(ndr_pull_lsa_LookupNamesLevel(ndr, NDR_SCALARS, &r->in.level));
14000 1051 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14001 1051 : NDR_PULL_ALLOC(ndr, r->in.count);
14002 : }
14003 1051 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
14004 1051 : NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
14005 1051 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
14006 1051 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
14007 1051 : NDR_CHECK(ndr_pull_lsa_LookupOptions(ndr, NDR_SCALARS, &r->in.lookup_options));
14008 1051 : NDR_CHECK(ndr_pull_lsa_ClientRevision(ndr, NDR_SCALARS, &r->in.client_revision));
14009 1051 : NDR_PULL_ALLOC(ndr, r->out.domains);
14010 1051 : NDR_ZERO_STRUCTP(r->out.domains);
14011 1051 : NDR_PULL_ALLOC(ndr, r->out.names);
14012 1051 : *r->out.names = *r->in.names;
14013 1051 : NDR_PULL_ALLOC(ndr, r->out.count);
14014 1051 : *r->out.count = *r->in.count;
14015 : }
14016 1223 : if (flags & NDR_OUT) {
14017 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14018 : if (r->in.sids == NULL) {
14019 : NDR_PULL_ALLOC(ndr, r->in.sids);
14020 : NDR_ZERO_STRUCTP(r->in.sids);
14021 : }
14022 : if (r->in.names == NULL) {
14023 : NDR_PULL_ALLOC(ndr, r->in.names);
14024 : NDR_ZERO_STRUCTP(r->in.names);
14025 : }
14026 : if (r->in.count == NULL) {
14027 : NDR_PULL_ALLOC(ndr, r->in.count);
14028 : NDR_ZERO_STRUCTP(r->in.count);
14029 : }
14030 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14031 172 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14032 64 : NDR_PULL_ALLOC(ndr, r->out.domains);
14033 : }
14034 172 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
14035 172 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
14036 172 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
14037 172 : if (_ptr_domains) {
14038 172 : NDR_PULL_ALLOC(ndr, *r->out.domains);
14039 : } else {
14040 0 : *r->out.domains = NULL;
14041 : }
14042 172 : if (*r->out.domains) {
14043 172 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
14044 172 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
14045 172 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
14046 172 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
14047 : }
14048 172 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
14049 172 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14050 64 : NDR_PULL_ALLOC(ndr, r->out.names);
14051 : }
14052 172 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
14053 172 : NDR_PULL_SET_MEM_CTX(ndr, r->out.names, LIBNDR_FLAG_REF_ALLOC);
14054 172 : NDR_CHECK(ndr_pull_lsa_TransNameArray2(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
14055 172 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
14056 172 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14057 64 : NDR_PULL_ALLOC(ndr, r->out.count);
14058 : }
14059 172 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
14060 172 : NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
14061 172 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
14062 172 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
14063 172 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
14064 : }
14065 1223 : return NDR_ERR_SUCCESS;
14066 : }
14067 :
14068 72 : _PUBLIC_ void ndr_print_lsa_LookupSids3(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupSids3 *r)
14069 : {
14070 72 : ndr_print_struct(ndr, name, "lsa_LookupSids3");
14071 72 : if (r == NULL) { ndr_print_null(ndr); return; }
14072 72 : ndr->depth++;
14073 72 : if (flags & NDR_SET_VALUES) {
14074 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14075 : }
14076 72 : if (flags & NDR_IN) {
14077 0 : ndr_print_struct(ndr, "in", "lsa_LookupSids3");
14078 0 : ndr->depth++;
14079 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
14080 0 : ndr->depth++;
14081 0 : ndr_print_lsa_SidArray(ndr, "sids", r->in.sids);
14082 0 : ndr->depth--;
14083 0 : ndr_print_ptr(ndr, "names", r->in.names);
14084 0 : ndr->depth++;
14085 0 : ndr_print_lsa_TransNameArray2(ndr, "names", r->in.names);
14086 0 : ndr->depth--;
14087 0 : ndr_print_lsa_LookupNamesLevel(ndr, "level", r->in.level);
14088 0 : ndr_print_ptr(ndr, "count", r->in.count);
14089 0 : ndr->depth++;
14090 0 : ndr_print_uint32(ndr, "count", *r->in.count);
14091 0 : ndr->depth--;
14092 0 : ndr_print_lsa_LookupOptions(ndr, "lookup_options", r->in.lookup_options);
14093 0 : ndr_print_lsa_ClientRevision(ndr, "client_revision", r->in.client_revision);
14094 0 : ndr->depth--;
14095 : }
14096 72 : if (flags & NDR_OUT) {
14097 72 : ndr_print_struct(ndr, "out", "lsa_LookupSids3");
14098 72 : ndr->depth++;
14099 72 : ndr_print_ptr(ndr, "domains", r->out.domains);
14100 72 : ndr->depth++;
14101 72 : ndr_print_ptr(ndr, "domains", *r->out.domains);
14102 72 : ndr->depth++;
14103 72 : if (*r->out.domains) {
14104 72 : ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
14105 : }
14106 72 : ndr->depth--;
14107 72 : ndr->depth--;
14108 72 : ndr_print_ptr(ndr, "names", r->out.names);
14109 72 : ndr->depth++;
14110 72 : ndr_print_lsa_TransNameArray2(ndr, "names", r->out.names);
14111 72 : ndr->depth--;
14112 72 : ndr_print_ptr(ndr, "count", r->out.count);
14113 72 : ndr->depth++;
14114 72 : ndr_print_uint32(ndr, "count", *r->out.count);
14115 72 : ndr->depth--;
14116 72 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
14117 72 : ndr->depth--;
14118 : }
14119 72 : ndr->depth--;
14120 : }
14121 :
14122 1023 : static enum ndr_err_code ndr_push_lsa_LookupNames4(struct ndr_push *ndr, int flags, const struct lsa_LookupNames4 *r)
14123 : {
14124 : uint32_t cntr_names_0;
14125 1023 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14126 1023 : if (flags & NDR_IN) {
14127 351 : if (r->in.sids == NULL) {
14128 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14129 : }
14130 351 : if (r->in.count == NULL) {
14131 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14132 : }
14133 351 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_names));
14134 351 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.num_names));
14135 14807 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
14136 14456 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
14137 : }
14138 14807 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
14139 14456 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
14140 : }
14141 351 : NDR_CHECK(ndr_push_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
14142 351 : NDR_CHECK(ndr_push_lsa_LookupNamesLevel(ndr, NDR_SCALARS, r->in.level));
14143 351 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.count));
14144 351 : NDR_CHECK(ndr_push_lsa_LookupOptions(ndr, NDR_SCALARS, r->in.lookup_options));
14145 351 : NDR_CHECK(ndr_push_lsa_ClientRevision(ndr, NDR_SCALARS, r->in.client_revision));
14146 : }
14147 1023 : if (flags & NDR_OUT) {
14148 672 : if (r->out.domains == NULL) {
14149 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14150 : }
14151 672 : if (r->out.sids == NULL) {
14152 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14153 : }
14154 672 : if (r->out.count == NULL) {
14155 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
14156 : }
14157 672 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domains));
14158 672 : if (*r->out.domains) {
14159 664 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
14160 : }
14161 672 : NDR_CHECK(ndr_push_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
14162 672 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.count));
14163 672 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
14164 : }
14165 1023 : return NDR_ERR_SUCCESS;
14166 : }
14167 :
14168 951 : static enum ndr_err_code ndr_pull_lsa_LookupNames4(struct ndr_pull *ndr, int flags, struct lsa_LookupNames4 *r)
14169 : {
14170 951 : uint32_t size_names_0 = 0;
14171 : uint32_t cntr_names_0;
14172 : uint32_t _ptr_domains;
14173 951 : TALLOC_CTX *_mem_save_names_0 = NULL;
14174 951 : TALLOC_CTX *_mem_save_domains_0 = NULL;
14175 951 : TALLOC_CTX *_mem_save_domains_1 = NULL;
14176 951 : TALLOC_CTX *_mem_save_sids_0 = NULL;
14177 951 : TALLOC_CTX *_mem_save_count_0 = NULL;
14178 951 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14179 951 : if (flags & NDR_IN) {
14180 625 : NDR_ZERO_STRUCT(r->out);
14181 :
14182 625 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_names));
14183 625 : if (r->in.num_names > 1000) {
14184 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value out of range");
14185 : }
14186 625 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.names));
14187 625 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.names, &size_names_0));
14188 625 : NDR_PULL_ALLOC_N(ndr, r->in.names, size_names_0);
14189 625 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
14190 625 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, 0);
14191 15355 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
14192 14730 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
14193 : }
14194 15355 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
14195 14730 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
14196 : }
14197 625 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
14198 625 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14199 625 : NDR_PULL_ALLOC(ndr, r->in.sids);
14200 : }
14201 625 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
14202 625 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
14203 625 : NDR_CHECK(ndr_pull_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
14204 625 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
14205 625 : NDR_CHECK(ndr_pull_lsa_LookupNamesLevel(ndr, NDR_SCALARS, &r->in.level));
14206 625 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14207 625 : NDR_PULL_ALLOC(ndr, r->in.count);
14208 : }
14209 625 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
14210 625 : NDR_PULL_SET_MEM_CTX(ndr, r->in.count, LIBNDR_FLAG_REF_ALLOC);
14211 625 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.count));
14212 625 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
14213 625 : NDR_CHECK(ndr_pull_lsa_LookupOptions(ndr, NDR_SCALARS, &r->in.lookup_options));
14214 625 : NDR_CHECK(ndr_pull_lsa_ClientRevision(ndr, NDR_SCALARS, &r->in.client_revision));
14215 625 : NDR_PULL_ALLOC(ndr, r->out.domains);
14216 625 : NDR_ZERO_STRUCTP(r->out.domains);
14217 625 : NDR_PULL_ALLOC(ndr, r->out.sids);
14218 625 : *r->out.sids = *r->in.sids;
14219 625 : NDR_PULL_ALLOC(ndr, r->out.count);
14220 625 : *r->out.count = *r->in.count;
14221 625 : if (r->in.names) {
14222 625 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.names, r->in.num_names));
14223 : }
14224 774 : for (cntr_names_0 = 0; cntr_names_0 < (size_names_0); cntr_names_0++) {
14225 : }
14226 : }
14227 951 : if (flags & NDR_OUT) {
14228 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14229 : if (r->in.sids == NULL) {
14230 : NDR_PULL_ALLOC(ndr, r->in.sids);
14231 : NDR_ZERO_STRUCTP(r->in.sids);
14232 : }
14233 : if (r->in.count == NULL) {
14234 : NDR_PULL_ALLOC(ndr, r->in.count);
14235 : NDR_ZERO_STRUCTP(r->in.count);
14236 : }
14237 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14238 326 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14239 110 : NDR_PULL_ALLOC(ndr, r->out.domains);
14240 : }
14241 326 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
14242 326 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
14243 326 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domains));
14244 326 : if (_ptr_domains) {
14245 326 : NDR_PULL_ALLOC(ndr, *r->out.domains);
14246 : } else {
14247 0 : *r->out.domains = NULL;
14248 : }
14249 326 : if (*r->out.domains) {
14250 326 : _mem_save_domains_1 = NDR_PULL_GET_MEM_CTX(ndr);
14251 326 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domains, 0);
14252 326 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.domains));
14253 326 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_1, 0);
14254 : }
14255 326 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
14256 326 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14257 110 : NDR_PULL_ALLOC(ndr, r->out.sids);
14258 : }
14259 326 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
14260 326 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
14261 326 : NDR_CHECK(ndr_pull_lsa_TransSidArray3(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
14262 326 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
14263 326 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14264 110 : NDR_PULL_ALLOC(ndr, r->out.count);
14265 : }
14266 326 : _mem_save_count_0 = NDR_PULL_GET_MEM_CTX(ndr);
14267 326 : NDR_PULL_SET_MEM_CTX(ndr, r->out.count, LIBNDR_FLAG_REF_ALLOC);
14268 326 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.count));
14269 326 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_count_0, LIBNDR_FLAG_REF_ALLOC);
14270 326 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
14271 : }
14272 951 : return NDR_ERR_SUCCESS;
14273 : }
14274 :
14275 144 : _PUBLIC_ void ndr_print_lsa_LookupNames4(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LookupNames4 *r)
14276 : {
14277 : uint32_t cntr_names_0;
14278 144 : ndr_print_struct(ndr, name, "lsa_LookupNames4");
14279 144 : if (r == NULL) { ndr_print_null(ndr); return; }
14280 144 : ndr->depth++;
14281 144 : if (flags & NDR_SET_VALUES) {
14282 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14283 : }
14284 144 : if (flags & NDR_IN) {
14285 0 : ndr_print_struct(ndr, "in", "lsa_LookupNames4");
14286 0 : ndr->depth++;
14287 0 : ndr_print_uint32(ndr, "num_names", r->in.num_names);
14288 0 : ndr->print(ndr, "%s: ARRAY(%d)", "names", (int)r->in.num_names);
14289 0 : ndr->depth++;
14290 0 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
14291 0 : ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
14292 : }
14293 0 : ndr->depth--;
14294 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
14295 0 : ndr->depth++;
14296 0 : ndr_print_lsa_TransSidArray3(ndr, "sids", r->in.sids);
14297 0 : ndr->depth--;
14298 0 : ndr_print_lsa_LookupNamesLevel(ndr, "level", r->in.level);
14299 0 : ndr_print_ptr(ndr, "count", r->in.count);
14300 0 : ndr->depth++;
14301 0 : ndr_print_uint32(ndr, "count", *r->in.count);
14302 0 : ndr->depth--;
14303 0 : ndr_print_lsa_LookupOptions(ndr, "lookup_options", r->in.lookup_options);
14304 0 : ndr_print_lsa_ClientRevision(ndr, "client_revision", r->in.client_revision);
14305 0 : ndr->depth--;
14306 : }
14307 144 : if (flags & NDR_OUT) {
14308 144 : ndr_print_struct(ndr, "out", "lsa_LookupNames4");
14309 144 : ndr->depth++;
14310 144 : ndr_print_ptr(ndr, "domains", r->out.domains);
14311 144 : ndr->depth++;
14312 144 : ndr_print_ptr(ndr, "domains", *r->out.domains);
14313 144 : ndr->depth++;
14314 144 : if (*r->out.domains) {
14315 144 : ndr_print_lsa_RefDomainList(ndr, "domains", *r->out.domains);
14316 : }
14317 144 : ndr->depth--;
14318 144 : ndr->depth--;
14319 144 : ndr_print_ptr(ndr, "sids", r->out.sids);
14320 144 : ndr->depth++;
14321 144 : ndr_print_lsa_TransSidArray3(ndr, "sids", r->out.sids);
14322 144 : ndr->depth--;
14323 144 : ndr_print_ptr(ndr, "count", r->out.count);
14324 144 : ndr->depth++;
14325 144 : ndr_print_uint32(ndr, "count", *r->out.count);
14326 144 : ndr->depth--;
14327 144 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
14328 144 : ndr->depth--;
14329 : }
14330 144 : ndr->depth--;
14331 : }
14332 :
14333 0 : static enum ndr_err_code ndr_push_lsa_LSAROPENPOLICYSCE(struct ndr_push *ndr, int flags, const struct lsa_LSAROPENPOLICYSCE *r)
14334 : {
14335 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14336 0 : if (flags & NDR_IN) {
14337 : }
14338 0 : if (flags & NDR_OUT) {
14339 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
14340 : }
14341 0 : return NDR_ERR_SUCCESS;
14342 : }
14343 :
14344 0 : static enum ndr_err_code ndr_pull_lsa_LSAROPENPOLICYSCE(struct ndr_pull *ndr, int flags, struct lsa_LSAROPENPOLICYSCE *r)
14345 : {
14346 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14347 0 : if (flags & NDR_IN) {
14348 : }
14349 0 : if (flags & NDR_OUT) {
14350 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14351 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14352 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
14353 : }
14354 0 : return NDR_ERR_SUCCESS;
14355 : }
14356 :
14357 0 : _PUBLIC_ void ndr_print_lsa_LSAROPENPOLICYSCE(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSAROPENPOLICYSCE *r)
14358 : {
14359 0 : ndr_print_struct(ndr, name, "lsa_LSAROPENPOLICYSCE");
14360 0 : if (r == NULL) { ndr_print_null(ndr); return; }
14361 0 : ndr->depth++;
14362 0 : if (flags & NDR_SET_VALUES) {
14363 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14364 : }
14365 0 : if (flags & NDR_IN) {
14366 0 : ndr_print_struct(ndr, "in", "lsa_LSAROPENPOLICYSCE");
14367 0 : ndr->depth++;
14368 0 : ndr->depth--;
14369 : }
14370 0 : if (flags & NDR_OUT) {
14371 0 : ndr_print_struct(ndr, "out", "lsa_LSAROPENPOLICYSCE");
14372 0 : ndr->depth++;
14373 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
14374 0 : ndr->depth--;
14375 : }
14376 0 : ndr->depth--;
14377 : }
14378 :
14379 0 : static enum ndr_err_code ndr_push_lsa_LSARADTREGISTERSECURITYEVENTSOURCE(struct ndr_push *ndr, int flags, const struct lsa_LSARADTREGISTERSECURITYEVENTSOURCE *r)
14380 : {
14381 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14382 0 : if (flags & NDR_IN) {
14383 : }
14384 0 : if (flags & NDR_OUT) {
14385 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
14386 : }
14387 0 : return NDR_ERR_SUCCESS;
14388 : }
14389 :
14390 0 : static enum ndr_err_code ndr_pull_lsa_LSARADTREGISTERSECURITYEVENTSOURCE(struct ndr_pull *ndr, int flags, struct lsa_LSARADTREGISTERSECURITYEVENTSOURCE *r)
14391 : {
14392 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14393 0 : if (flags & NDR_IN) {
14394 : }
14395 0 : if (flags & NDR_OUT) {
14396 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14397 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14398 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
14399 : }
14400 0 : return NDR_ERR_SUCCESS;
14401 : }
14402 :
14403 0 : _PUBLIC_ void ndr_print_lsa_LSARADTREGISTERSECURITYEVENTSOURCE(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARADTREGISTERSECURITYEVENTSOURCE *r)
14404 : {
14405 0 : ndr_print_struct(ndr, name, "lsa_LSARADTREGISTERSECURITYEVENTSOURCE");
14406 0 : if (r == NULL) { ndr_print_null(ndr); return; }
14407 0 : ndr->depth++;
14408 0 : if (flags & NDR_SET_VALUES) {
14409 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14410 : }
14411 0 : if (flags & NDR_IN) {
14412 0 : ndr_print_struct(ndr, "in", "lsa_LSARADTREGISTERSECURITYEVENTSOURCE");
14413 0 : ndr->depth++;
14414 0 : ndr->depth--;
14415 : }
14416 0 : if (flags & NDR_OUT) {
14417 0 : ndr_print_struct(ndr, "out", "lsa_LSARADTREGISTERSECURITYEVENTSOURCE");
14418 0 : ndr->depth++;
14419 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
14420 0 : ndr->depth--;
14421 : }
14422 0 : ndr->depth--;
14423 : }
14424 :
14425 0 : static enum ndr_err_code ndr_push_lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE(struct ndr_push *ndr, int flags, const struct lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE *r)
14426 : {
14427 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14428 0 : if (flags & NDR_IN) {
14429 : }
14430 0 : if (flags & NDR_OUT) {
14431 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
14432 : }
14433 0 : return NDR_ERR_SUCCESS;
14434 : }
14435 :
14436 0 : static enum ndr_err_code ndr_pull_lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE(struct ndr_pull *ndr, int flags, struct lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE *r)
14437 : {
14438 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14439 0 : if (flags & NDR_IN) {
14440 : }
14441 0 : if (flags & NDR_OUT) {
14442 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14443 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14444 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
14445 : }
14446 0 : return NDR_ERR_SUCCESS;
14447 : }
14448 :
14449 0 : _PUBLIC_ void ndr_print_lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE *r)
14450 : {
14451 0 : ndr_print_struct(ndr, name, "lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE");
14452 0 : if (r == NULL) { ndr_print_null(ndr); return; }
14453 0 : ndr->depth++;
14454 0 : if (flags & NDR_SET_VALUES) {
14455 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14456 : }
14457 0 : if (flags & NDR_IN) {
14458 0 : ndr_print_struct(ndr, "in", "lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE");
14459 0 : ndr->depth++;
14460 0 : ndr->depth--;
14461 : }
14462 0 : if (flags & NDR_OUT) {
14463 0 : ndr_print_struct(ndr, "out", "lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE");
14464 0 : ndr->depth++;
14465 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
14466 0 : ndr->depth--;
14467 : }
14468 0 : ndr->depth--;
14469 : }
14470 :
14471 0 : static enum ndr_err_code ndr_push_lsa_LSARADTREPORTSECURITYEVENT(struct ndr_push *ndr, int flags, const struct lsa_LSARADTREPORTSECURITYEVENT *r)
14472 : {
14473 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
14474 0 : if (flags & NDR_IN) {
14475 : }
14476 0 : if (flags & NDR_OUT) {
14477 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
14478 : }
14479 0 : return NDR_ERR_SUCCESS;
14480 : }
14481 :
14482 0 : static enum ndr_err_code ndr_pull_lsa_LSARADTREPORTSECURITYEVENT(struct ndr_pull *ndr, int flags, struct lsa_LSARADTREPORTSECURITYEVENT *r)
14483 : {
14484 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
14485 0 : if (flags & NDR_IN) {
14486 : }
14487 0 : if (flags & NDR_OUT) {
14488 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14489 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14490 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
14491 : }
14492 0 : return NDR_ERR_SUCCESS;
14493 : }
14494 :
14495 0 : _PUBLIC_ void ndr_print_lsa_LSARADTREPORTSECURITYEVENT(struct ndr_print *ndr, const char *name, int flags, const struct lsa_LSARADTREPORTSECURITYEVENT *r)
14496 : {
14497 0 : ndr_print_struct(ndr, name, "lsa_LSARADTREPORTSECURITYEVENT");
14498 0 : if (r == NULL) { ndr_print_null(ndr); return; }
14499 0 : ndr->depth++;
14500 0 : if (flags & NDR_SET_VALUES) {
14501 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14502 : }
14503 0 : if (flags & NDR_IN) {
14504 0 : ndr_print_struct(ndr, "in", "lsa_LSARADTREPORTSECURITYEVENT");
14505 0 : ndr->depth++;
14506 0 : ndr->depth--;
14507 : }
14508 0 : if (flags & NDR_OUT) {
14509 0 : ndr_print_struct(ndr, "out", "lsa_LSARADTREPORTSECURITYEVENT");
14510 0 : ndr->depth++;
14511 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
14512 0 : ndr->depth--;
14513 : }
14514 0 : ndr->depth--;
14515 : }
14516 :
14517 : #ifndef SKIP_NDR_TABLE_lsarpc
14518 : static const struct ndr_interface_public_struct lsarpc_public_structs[] = {
14519 : {
14520 : .name = "lsa_String",
14521 : .struct_size = sizeof(struct lsa_String ),
14522 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_String,
14523 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_String,
14524 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_String,
14525 : },
14526 : {
14527 : .name = "lsa_StringLarge",
14528 : .struct_size = sizeof(struct lsa_StringLarge ),
14529 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_StringLarge,
14530 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_StringLarge,
14531 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_StringLarge,
14532 : },
14533 : {
14534 : .name = "lsa_Strings",
14535 : .struct_size = sizeof(struct lsa_Strings ),
14536 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_Strings,
14537 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_Strings,
14538 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_Strings,
14539 : },
14540 : {
14541 : .name = "lsa_AsciiString",
14542 : .struct_size = sizeof(struct lsa_AsciiString ),
14543 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_AsciiString,
14544 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_AsciiString,
14545 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_AsciiString,
14546 : },
14547 : {
14548 : .name = "lsa_AsciiStringLarge",
14549 : .struct_size = sizeof(struct lsa_AsciiStringLarge ),
14550 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_AsciiStringLarge,
14551 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_AsciiStringLarge,
14552 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_AsciiStringLarge,
14553 : },
14554 : {
14555 : .name = "lsa_BinaryString",
14556 : .struct_size = sizeof(struct lsa_BinaryString ),
14557 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_BinaryString,
14558 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_BinaryString,
14559 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_BinaryString,
14560 : },
14561 : {
14562 : .name = "lsa_DnsDomainInfo",
14563 : .struct_size = sizeof(struct lsa_DnsDomainInfo ),
14564 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_DnsDomainInfo,
14565 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_DnsDomainInfo,
14566 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_DnsDomainInfo,
14567 : },
14568 : {
14569 : .name = "lsa_SidArray",
14570 : .struct_size = sizeof(struct lsa_SidArray ),
14571 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_SidArray,
14572 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_SidArray,
14573 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_SidArray,
14574 : },
14575 : {
14576 : .name = "lsa_RefDomainList",
14577 : .struct_size = sizeof(struct lsa_RefDomainList ),
14578 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_RefDomainList,
14579 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_RefDomainList,
14580 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_RefDomainList,
14581 : },
14582 : {
14583 : .name = "lsa_TransNameArray",
14584 : .struct_size = sizeof(struct lsa_TransNameArray ),
14585 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_TransNameArray,
14586 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_TransNameArray,
14587 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_TransNameArray,
14588 : },
14589 : {
14590 : .name = "lsa_TrustDomainInfoInfoEx",
14591 : .struct_size = sizeof(struct lsa_TrustDomainInfoInfoEx ),
14592 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_TrustDomainInfoInfoEx,
14593 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_TrustDomainInfoInfoEx,
14594 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_TrustDomainInfoInfoEx,
14595 : },
14596 : {
14597 : .name = "lsa_TrustDomainInfoAuthInfo",
14598 : .struct_size = sizeof(struct lsa_TrustDomainInfoAuthInfo ),
14599 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_TrustDomainInfoAuthInfo,
14600 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_TrustDomainInfoAuthInfo,
14601 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_TrustDomainInfoAuthInfo,
14602 : },
14603 : {
14604 : .name = "lsa_ForestTrustInformation",
14605 : .struct_size = sizeof(struct lsa_ForestTrustInformation ),
14606 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_ForestTrustInformation,
14607 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_ForestTrustInformation,
14608 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_ForestTrustInformation,
14609 : },
14610 : {
14611 : .name = "lsa_ForestTrustCollisionRecord",
14612 : .struct_size = sizeof(struct lsa_ForestTrustCollisionRecord ),
14613 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_ForestTrustCollisionRecord,
14614 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_ForestTrustCollisionRecord,
14615 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_ForestTrustCollisionRecord,
14616 : },
14617 : {
14618 : .name = "lsa_ForestTrustCollisionInfo",
14619 : .struct_size = sizeof(struct lsa_ForestTrustCollisionInfo ),
14620 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_lsa_ForestTrustCollisionInfo,
14621 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_lsa_ForestTrustCollisionInfo,
14622 : .ndr_print = (ndr_print_function_t) ndr_print_flags_lsa_ForestTrustCollisionInfo,
14623 : },
14624 : { .name = NULL }
14625 : };
14626 :
14627 : static const struct ndr_interface_call lsarpc_calls[] = {
14628 : {
14629 : "lsa_Close",
14630 : sizeof(struct lsa_Close),
14631 : (ndr_push_flags_fn_t) ndr_push_lsa_Close,
14632 : (ndr_pull_flags_fn_t) ndr_pull_lsa_Close,
14633 : (ndr_print_function_t) ndr_print_lsa_Close,
14634 : { 0, NULL },
14635 : { 0, NULL },
14636 : },
14637 : {
14638 : "lsa_Delete",
14639 : sizeof(struct lsa_Delete),
14640 : (ndr_push_flags_fn_t) ndr_push_lsa_Delete,
14641 : (ndr_pull_flags_fn_t) ndr_pull_lsa_Delete,
14642 : (ndr_print_function_t) ndr_print_lsa_Delete,
14643 : { 0, NULL },
14644 : { 0, NULL },
14645 : },
14646 : {
14647 : "lsa_EnumPrivs",
14648 : sizeof(struct lsa_EnumPrivs),
14649 : (ndr_push_flags_fn_t) ndr_push_lsa_EnumPrivs,
14650 : (ndr_pull_flags_fn_t) ndr_pull_lsa_EnumPrivs,
14651 : (ndr_print_function_t) ndr_print_lsa_EnumPrivs,
14652 : { 0, NULL },
14653 : { 0, NULL },
14654 : },
14655 : {
14656 : "lsa_QuerySecurity",
14657 : sizeof(struct lsa_QuerySecurity),
14658 : (ndr_push_flags_fn_t) ndr_push_lsa_QuerySecurity,
14659 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QuerySecurity,
14660 : (ndr_print_function_t) ndr_print_lsa_QuerySecurity,
14661 : { 0, NULL },
14662 : { 0, NULL },
14663 : },
14664 : {
14665 : "lsa_SetSecObj",
14666 : sizeof(struct lsa_SetSecObj),
14667 : (ndr_push_flags_fn_t) ndr_push_lsa_SetSecObj,
14668 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetSecObj,
14669 : (ndr_print_function_t) ndr_print_lsa_SetSecObj,
14670 : { 0, NULL },
14671 : { 0, NULL },
14672 : },
14673 : {
14674 : "lsa_ChangePassword",
14675 : sizeof(struct lsa_ChangePassword),
14676 : (ndr_push_flags_fn_t) ndr_push_lsa_ChangePassword,
14677 : (ndr_pull_flags_fn_t) ndr_pull_lsa_ChangePassword,
14678 : (ndr_print_function_t) ndr_print_lsa_ChangePassword,
14679 : { 0, NULL },
14680 : { 0, NULL },
14681 : },
14682 : {
14683 : "lsa_OpenPolicy",
14684 : sizeof(struct lsa_OpenPolicy),
14685 : (ndr_push_flags_fn_t) ndr_push_lsa_OpenPolicy,
14686 : (ndr_pull_flags_fn_t) ndr_pull_lsa_OpenPolicy,
14687 : (ndr_print_function_t) ndr_print_lsa_OpenPolicy,
14688 : { 0, NULL },
14689 : { 0, NULL },
14690 : },
14691 : {
14692 : "lsa_QueryInfoPolicy",
14693 : sizeof(struct lsa_QueryInfoPolicy),
14694 : (ndr_push_flags_fn_t) ndr_push_lsa_QueryInfoPolicy,
14695 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QueryInfoPolicy,
14696 : (ndr_print_function_t) ndr_print_lsa_QueryInfoPolicy,
14697 : { 0, NULL },
14698 : { 0, NULL },
14699 : },
14700 : {
14701 : "lsa_SetInfoPolicy",
14702 : sizeof(struct lsa_SetInfoPolicy),
14703 : (ndr_push_flags_fn_t) ndr_push_lsa_SetInfoPolicy,
14704 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetInfoPolicy,
14705 : (ndr_print_function_t) ndr_print_lsa_SetInfoPolicy,
14706 : { 0, NULL },
14707 : { 0, NULL },
14708 : },
14709 : {
14710 : "lsa_ClearAuditLog",
14711 : sizeof(struct lsa_ClearAuditLog),
14712 : (ndr_push_flags_fn_t) ndr_push_lsa_ClearAuditLog,
14713 : (ndr_pull_flags_fn_t) ndr_pull_lsa_ClearAuditLog,
14714 : (ndr_print_function_t) ndr_print_lsa_ClearAuditLog,
14715 : { 0, NULL },
14716 : { 0, NULL },
14717 : },
14718 : {
14719 : "lsa_CreateAccount",
14720 : sizeof(struct lsa_CreateAccount),
14721 : (ndr_push_flags_fn_t) ndr_push_lsa_CreateAccount,
14722 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CreateAccount,
14723 : (ndr_print_function_t) ndr_print_lsa_CreateAccount,
14724 : { 0, NULL },
14725 : { 0, NULL },
14726 : },
14727 : {
14728 : "lsa_EnumAccounts",
14729 : sizeof(struct lsa_EnumAccounts),
14730 : (ndr_push_flags_fn_t) ndr_push_lsa_EnumAccounts,
14731 : (ndr_pull_flags_fn_t) ndr_pull_lsa_EnumAccounts,
14732 : (ndr_print_function_t) ndr_print_lsa_EnumAccounts,
14733 : { 0, NULL },
14734 : { 0, NULL },
14735 : },
14736 : {
14737 : "lsa_CreateTrustedDomain",
14738 : sizeof(struct lsa_CreateTrustedDomain),
14739 : (ndr_push_flags_fn_t) ndr_push_lsa_CreateTrustedDomain,
14740 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CreateTrustedDomain,
14741 : (ndr_print_function_t) ndr_print_lsa_CreateTrustedDomain,
14742 : { 0, NULL },
14743 : { 0, NULL },
14744 : },
14745 : {
14746 : "lsa_EnumTrustDom",
14747 : sizeof(struct lsa_EnumTrustDom),
14748 : (ndr_push_flags_fn_t) ndr_push_lsa_EnumTrustDom,
14749 : (ndr_pull_flags_fn_t) ndr_pull_lsa_EnumTrustDom,
14750 : (ndr_print_function_t) ndr_print_lsa_EnumTrustDom,
14751 : { 0, NULL },
14752 : { 0, NULL },
14753 : },
14754 : {
14755 : "lsa_LookupNames",
14756 : sizeof(struct lsa_LookupNames),
14757 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupNames,
14758 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupNames,
14759 : (ndr_print_function_t) ndr_print_lsa_LookupNames,
14760 : { 0, NULL },
14761 : { 0, NULL },
14762 : },
14763 : {
14764 : "lsa_LookupSids",
14765 : sizeof(struct lsa_LookupSids),
14766 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupSids,
14767 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupSids,
14768 : (ndr_print_function_t) ndr_print_lsa_LookupSids,
14769 : { 0, NULL },
14770 : { 0, NULL },
14771 : },
14772 : {
14773 : "lsa_CreateSecret",
14774 : sizeof(struct lsa_CreateSecret),
14775 : (ndr_push_flags_fn_t) ndr_push_lsa_CreateSecret,
14776 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CreateSecret,
14777 : (ndr_print_function_t) ndr_print_lsa_CreateSecret,
14778 : { 0, NULL },
14779 : { 0, NULL },
14780 : },
14781 : {
14782 : "lsa_OpenAccount",
14783 : sizeof(struct lsa_OpenAccount),
14784 : (ndr_push_flags_fn_t) ndr_push_lsa_OpenAccount,
14785 : (ndr_pull_flags_fn_t) ndr_pull_lsa_OpenAccount,
14786 : (ndr_print_function_t) ndr_print_lsa_OpenAccount,
14787 : { 0, NULL },
14788 : { 0, NULL },
14789 : },
14790 : {
14791 : "lsa_EnumPrivsAccount",
14792 : sizeof(struct lsa_EnumPrivsAccount),
14793 : (ndr_push_flags_fn_t) ndr_push_lsa_EnumPrivsAccount,
14794 : (ndr_pull_flags_fn_t) ndr_pull_lsa_EnumPrivsAccount,
14795 : (ndr_print_function_t) ndr_print_lsa_EnumPrivsAccount,
14796 : { 0, NULL },
14797 : { 0, NULL },
14798 : },
14799 : {
14800 : "lsa_AddPrivilegesToAccount",
14801 : sizeof(struct lsa_AddPrivilegesToAccount),
14802 : (ndr_push_flags_fn_t) ndr_push_lsa_AddPrivilegesToAccount,
14803 : (ndr_pull_flags_fn_t) ndr_pull_lsa_AddPrivilegesToAccount,
14804 : (ndr_print_function_t) ndr_print_lsa_AddPrivilegesToAccount,
14805 : { 0, NULL },
14806 : { 0, NULL },
14807 : },
14808 : {
14809 : "lsa_RemovePrivilegesFromAccount",
14810 : sizeof(struct lsa_RemovePrivilegesFromAccount),
14811 : (ndr_push_flags_fn_t) ndr_push_lsa_RemovePrivilegesFromAccount,
14812 : (ndr_pull_flags_fn_t) ndr_pull_lsa_RemovePrivilegesFromAccount,
14813 : (ndr_print_function_t) ndr_print_lsa_RemovePrivilegesFromAccount,
14814 : { 0, NULL },
14815 : { 0, NULL },
14816 : },
14817 : {
14818 : "lsa_GetQuotasForAccount",
14819 : sizeof(struct lsa_GetQuotasForAccount),
14820 : (ndr_push_flags_fn_t) ndr_push_lsa_GetQuotasForAccount,
14821 : (ndr_pull_flags_fn_t) ndr_pull_lsa_GetQuotasForAccount,
14822 : (ndr_print_function_t) ndr_print_lsa_GetQuotasForAccount,
14823 : { 0, NULL },
14824 : { 0, NULL },
14825 : },
14826 : {
14827 : "lsa_SetQuotasForAccount",
14828 : sizeof(struct lsa_SetQuotasForAccount),
14829 : (ndr_push_flags_fn_t) ndr_push_lsa_SetQuotasForAccount,
14830 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetQuotasForAccount,
14831 : (ndr_print_function_t) ndr_print_lsa_SetQuotasForAccount,
14832 : { 0, NULL },
14833 : { 0, NULL },
14834 : },
14835 : {
14836 : "lsa_GetSystemAccessAccount",
14837 : sizeof(struct lsa_GetSystemAccessAccount),
14838 : (ndr_push_flags_fn_t) ndr_push_lsa_GetSystemAccessAccount,
14839 : (ndr_pull_flags_fn_t) ndr_pull_lsa_GetSystemAccessAccount,
14840 : (ndr_print_function_t) ndr_print_lsa_GetSystemAccessAccount,
14841 : { 0, NULL },
14842 : { 0, NULL },
14843 : },
14844 : {
14845 : "lsa_SetSystemAccessAccount",
14846 : sizeof(struct lsa_SetSystemAccessAccount),
14847 : (ndr_push_flags_fn_t) ndr_push_lsa_SetSystemAccessAccount,
14848 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetSystemAccessAccount,
14849 : (ndr_print_function_t) ndr_print_lsa_SetSystemAccessAccount,
14850 : { 0, NULL },
14851 : { 0, NULL },
14852 : },
14853 : {
14854 : "lsa_OpenTrustedDomain",
14855 : sizeof(struct lsa_OpenTrustedDomain),
14856 : (ndr_push_flags_fn_t) ndr_push_lsa_OpenTrustedDomain,
14857 : (ndr_pull_flags_fn_t) ndr_pull_lsa_OpenTrustedDomain,
14858 : (ndr_print_function_t) ndr_print_lsa_OpenTrustedDomain,
14859 : { 0, NULL },
14860 : { 0, NULL },
14861 : },
14862 : {
14863 : "lsa_QueryTrustedDomainInfo",
14864 : sizeof(struct lsa_QueryTrustedDomainInfo),
14865 : (ndr_push_flags_fn_t) ndr_push_lsa_QueryTrustedDomainInfo,
14866 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QueryTrustedDomainInfo,
14867 : (ndr_print_function_t) ndr_print_lsa_QueryTrustedDomainInfo,
14868 : { 0, NULL },
14869 : { 0, NULL },
14870 : },
14871 : {
14872 : "lsa_SetInformationTrustedDomain",
14873 : sizeof(struct lsa_SetInformationTrustedDomain),
14874 : (ndr_push_flags_fn_t) ndr_push_lsa_SetInformationTrustedDomain,
14875 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetInformationTrustedDomain,
14876 : (ndr_print_function_t) ndr_print_lsa_SetInformationTrustedDomain,
14877 : { 0, NULL },
14878 : { 0, NULL },
14879 : },
14880 : {
14881 : "lsa_OpenSecret",
14882 : sizeof(struct lsa_OpenSecret),
14883 : (ndr_push_flags_fn_t) ndr_push_lsa_OpenSecret,
14884 : (ndr_pull_flags_fn_t) ndr_pull_lsa_OpenSecret,
14885 : (ndr_print_function_t) ndr_print_lsa_OpenSecret,
14886 : { 0, NULL },
14887 : { 0, NULL },
14888 : },
14889 : {
14890 : "lsa_SetSecret",
14891 : sizeof(struct lsa_SetSecret),
14892 : (ndr_push_flags_fn_t) ndr_push_lsa_SetSecret,
14893 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetSecret,
14894 : (ndr_print_function_t) ndr_print_lsa_SetSecret,
14895 : { 0, NULL },
14896 : { 0, NULL },
14897 : },
14898 : {
14899 : "lsa_QuerySecret",
14900 : sizeof(struct lsa_QuerySecret),
14901 : (ndr_push_flags_fn_t) ndr_push_lsa_QuerySecret,
14902 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QuerySecret,
14903 : (ndr_print_function_t) ndr_print_lsa_QuerySecret,
14904 : { 0, NULL },
14905 : { 0, NULL },
14906 : },
14907 : {
14908 : "lsa_LookupPrivValue",
14909 : sizeof(struct lsa_LookupPrivValue),
14910 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupPrivValue,
14911 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupPrivValue,
14912 : (ndr_print_function_t) ndr_print_lsa_LookupPrivValue,
14913 : { 0, NULL },
14914 : { 0, NULL },
14915 : },
14916 : {
14917 : "lsa_LookupPrivName",
14918 : sizeof(struct lsa_LookupPrivName),
14919 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupPrivName,
14920 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupPrivName,
14921 : (ndr_print_function_t) ndr_print_lsa_LookupPrivName,
14922 : { 0, NULL },
14923 : { 0, NULL },
14924 : },
14925 : {
14926 : "lsa_LookupPrivDisplayName",
14927 : sizeof(struct lsa_LookupPrivDisplayName),
14928 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupPrivDisplayName,
14929 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupPrivDisplayName,
14930 : (ndr_print_function_t) ndr_print_lsa_LookupPrivDisplayName,
14931 : { 0, NULL },
14932 : { 0, NULL },
14933 : },
14934 : {
14935 : "lsa_DeleteObject",
14936 : sizeof(struct lsa_DeleteObject),
14937 : (ndr_push_flags_fn_t) ndr_push_lsa_DeleteObject,
14938 : (ndr_pull_flags_fn_t) ndr_pull_lsa_DeleteObject,
14939 : (ndr_print_function_t) ndr_print_lsa_DeleteObject,
14940 : { 0, NULL },
14941 : { 0, NULL },
14942 : },
14943 : {
14944 : "lsa_EnumAccountsWithUserRight",
14945 : sizeof(struct lsa_EnumAccountsWithUserRight),
14946 : (ndr_push_flags_fn_t) ndr_push_lsa_EnumAccountsWithUserRight,
14947 : (ndr_pull_flags_fn_t) ndr_pull_lsa_EnumAccountsWithUserRight,
14948 : (ndr_print_function_t) ndr_print_lsa_EnumAccountsWithUserRight,
14949 : { 0, NULL },
14950 : { 0, NULL },
14951 : },
14952 : {
14953 : "lsa_EnumAccountRights",
14954 : sizeof(struct lsa_EnumAccountRights),
14955 : (ndr_push_flags_fn_t) ndr_push_lsa_EnumAccountRights,
14956 : (ndr_pull_flags_fn_t) ndr_pull_lsa_EnumAccountRights,
14957 : (ndr_print_function_t) ndr_print_lsa_EnumAccountRights,
14958 : { 0, NULL },
14959 : { 0, NULL },
14960 : },
14961 : {
14962 : "lsa_AddAccountRights",
14963 : sizeof(struct lsa_AddAccountRights),
14964 : (ndr_push_flags_fn_t) ndr_push_lsa_AddAccountRights,
14965 : (ndr_pull_flags_fn_t) ndr_pull_lsa_AddAccountRights,
14966 : (ndr_print_function_t) ndr_print_lsa_AddAccountRights,
14967 : { 0, NULL },
14968 : { 0, NULL },
14969 : },
14970 : {
14971 : "lsa_RemoveAccountRights",
14972 : sizeof(struct lsa_RemoveAccountRights),
14973 : (ndr_push_flags_fn_t) ndr_push_lsa_RemoveAccountRights,
14974 : (ndr_pull_flags_fn_t) ndr_pull_lsa_RemoveAccountRights,
14975 : (ndr_print_function_t) ndr_print_lsa_RemoveAccountRights,
14976 : { 0, NULL },
14977 : { 0, NULL },
14978 : },
14979 : {
14980 : "lsa_QueryTrustedDomainInfoBySid",
14981 : sizeof(struct lsa_QueryTrustedDomainInfoBySid),
14982 : (ndr_push_flags_fn_t) ndr_push_lsa_QueryTrustedDomainInfoBySid,
14983 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QueryTrustedDomainInfoBySid,
14984 : (ndr_print_function_t) ndr_print_lsa_QueryTrustedDomainInfoBySid,
14985 : { 0, NULL },
14986 : { 0, NULL },
14987 : },
14988 : {
14989 : "lsa_SetTrustedDomainInfo",
14990 : sizeof(struct lsa_SetTrustedDomainInfo),
14991 : (ndr_push_flags_fn_t) ndr_push_lsa_SetTrustedDomainInfo,
14992 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetTrustedDomainInfo,
14993 : (ndr_print_function_t) ndr_print_lsa_SetTrustedDomainInfo,
14994 : { 0, NULL },
14995 : { 0, NULL },
14996 : },
14997 : {
14998 : "lsa_DeleteTrustedDomain",
14999 : sizeof(struct lsa_DeleteTrustedDomain),
15000 : (ndr_push_flags_fn_t) ndr_push_lsa_DeleteTrustedDomain,
15001 : (ndr_pull_flags_fn_t) ndr_pull_lsa_DeleteTrustedDomain,
15002 : (ndr_print_function_t) ndr_print_lsa_DeleteTrustedDomain,
15003 : { 0, NULL },
15004 : { 0, NULL },
15005 : },
15006 : {
15007 : "lsa_StorePrivateData",
15008 : sizeof(struct lsa_StorePrivateData),
15009 : (ndr_push_flags_fn_t) ndr_push_lsa_StorePrivateData,
15010 : (ndr_pull_flags_fn_t) ndr_pull_lsa_StorePrivateData,
15011 : (ndr_print_function_t) ndr_print_lsa_StorePrivateData,
15012 : { 0, NULL },
15013 : { 0, NULL },
15014 : },
15015 : {
15016 : "lsa_RetrievePrivateData",
15017 : sizeof(struct lsa_RetrievePrivateData),
15018 : (ndr_push_flags_fn_t) ndr_push_lsa_RetrievePrivateData,
15019 : (ndr_pull_flags_fn_t) ndr_pull_lsa_RetrievePrivateData,
15020 : (ndr_print_function_t) ndr_print_lsa_RetrievePrivateData,
15021 : { 0, NULL },
15022 : { 0, NULL },
15023 : },
15024 : {
15025 : "lsa_OpenPolicy2",
15026 : sizeof(struct lsa_OpenPolicy2),
15027 : (ndr_push_flags_fn_t) ndr_push_lsa_OpenPolicy2,
15028 : (ndr_pull_flags_fn_t) ndr_pull_lsa_OpenPolicy2,
15029 : (ndr_print_function_t) ndr_print_lsa_OpenPolicy2,
15030 : { 0, NULL },
15031 : { 0, NULL },
15032 : },
15033 : {
15034 : "lsa_GetUserName",
15035 : sizeof(struct lsa_GetUserName),
15036 : (ndr_push_flags_fn_t) ndr_push_lsa_GetUserName,
15037 : (ndr_pull_flags_fn_t) ndr_pull_lsa_GetUserName,
15038 : (ndr_print_function_t) ndr_print_lsa_GetUserName,
15039 : { 0, NULL },
15040 : { 0, NULL },
15041 : },
15042 : {
15043 : "lsa_QueryInfoPolicy2",
15044 : sizeof(struct lsa_QueryInfoPolicy2),
15045 : (ndr_push_flags_fn_t) ndr_push_lsa_QueryInfoPolicy2,
15046 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QueryInfoPolicy2,
15047 : (ndr_print_function_t) ndr_print_lsa_QueryInfoPolicy2,
15048 : { 0, NULL },
15049 : { 0, NULL },
15050 : },
15051 : {
15052 : "lsa_SetInfoPolicy2",
15053 : sizeof(struct lsa_SetInfoPolicy2),
15054 : (ndr_push_flags_fn_t) ndr_push_lsa_SetInfoPolicy2,
15055 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetInfoPolicy2,
15056 : (ndr_print_function_t) ndr_print_lsa_SetInfoPolicy2,
15057 : { 0, NULL },
15058 : { 0, NULL },
15059 : },
15060 : {
15061 : "lsa_QueryTrustedDomainInfoByName",
15062 : sizeof(struct lsa_QueryTrustedDomainInfoByName),
15063 : (ndr_push_flags_fn_t) ndr_push_lsa_QueryTrustedDomainInfoByName,
15064 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QueryTrustedDomainInfoByName,
15065 : (ndr_print_function_t) ndr_print_lsa_QueryTrustedDomainInfoByName,
15066 : { 0, NULL },
15067 : { 0, NULL },
15068 : },
15069 : {
15070 : "lsa_SetTrustedDomainInfoByName",
15071 : sizeof(struct lsa_SetTrustedDomainInfoByName),
15072 : (ndr_push_flags_fn_t) ndr_push_lsa_SetTrustedDomainInfoByName,
15073 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetTrustedDomainInfoByName,
15074 : (ndr_print_function_t) ndr_print_lsa_SetTrustedDomainInfoByName,
15075 : { 0, NULL },
15076 : { 0, NULL },
15077 : },
15078 : {
15079 : "lsa_EnumTrustedDomainsEx",
15080 : sizeof(struct lsa_EnumTrustedDomainsEx),
15081 : (ndr_push_flags_fn_t) ndr_push_lsa_EnumTrustedDomainsEx,
15082 : (ndr_pull_flags_fn_t) ndr_pull_lsa_EnumTrustedDomainsEx,
15083 : (ndr_print_function_t) ndr_print_lsa_EnumTrustedDomainsEx,
15084 : { 0, NULL },
15085 : { 0, NULL },
15086 : },
15087 : {
15088 : "lsa_CreateTrustedDomainEx",
15089 : sizeof(struct lsa_CreateTrustedDomainEx),
15090 : (ndr_push_flags_fn_t) ndr_push_lsa_CreateTrustedDomainEx,
15091 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CreateTrustedDomainEx,
15092 : (ndr_print_function_t) ndr_print_lsa_CreateTrustedDomainEx,
15093 : { 0, NULL },
15094 : { 0, NULL },
15095 : },
15096 : {
15097 : "lsa_CloseTrustedDomainEx",
15098 : sizeof(struct lsa_CloseTrustedDomainEx),
15099 : (ndr_push_flags_fn_t) ndr_push_lsa_CloseTrustedDomainEx,
15100 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CloseTrustedDomainEx,
15101 : (ndr_print_function_t) ndr_print_lsa_CloseTrustedDomainEx,
15102 : { 0, NULL },
15103 : { 0, NULL },
15104 : },
15105 : {
15106 : "lsa_QueryDomainInformationPolicy",
15107 : sizeof(struct lsa_QueryDomainInformationPolicy),
15108 : (ndr_push_flags_fn_t) ndr_push_lsa_QueryDomainInformationPolicy,
15109 : (ndr_pull_flags_fn_t) ndr_pull_lsa_QueryDomainInformationPolicy,
15110 : (ndr_print_function_t) ndr_print_lsa_QueryDomainInformationPolicy,
15111 : { 0, NULL },
15112 : { 0, NULL },
15113 : },
15114 : {
15115 : "lsa_SetDomainInformationPolicy",
15116 : sizeof(struct lsa_SetDomainInformationPolicy),
15117 : (ndr_push_flags_fn_t) ndr_push_lsa_SetDomainInformationPolicy,
15118 : (ndr_pull_flags_fn_t) ndr_pull_lsa_SetDomainInformationPolicy,
15119 : (ndr_print_function_t) ndr_print_lsa_SetDomainInformationPolicy,
15120 : { 0, NULL },
15121 : { 0, NULL },
15122 : },
15123 : {
15124 : "lsa_OpenTrustedDomainByName",
15125 : sizeof(struct lsa_OpenTrustedDomainByName),
15126 : (ndr_push_flags_fn_t) ndr_push_lsa_OpenTrustedDomainByName,
15127 : (ndr_pull_flags_fn_t) ndr_pull_lsa_OpenTrustedDomainByName,
15128 : (ndr_print_function_t) ndr_print_lsa_OpenTrustedDomainByName,
15129 : { 0, NULL },
15130 : { 0, NULL },
15131 : },
15132 : {
15133 : "lsa_TestCall",
15134 : sizeof(struct lsa_TestCall),
15135 : (ndr_push_flags_fn_t) ndr_push_lsa_TestCall,
15136 : (ndr_pull_flags_fn_t) ndr_pull_lsa_TestCall,
15137 : (ndr_print_function_t) ndr_print_lsa_TestCall,
15138 : { 0, NULL },
15139 : { 0, NULL },
15140 : },
15141 : {
15142 : "lsa_LookupSids2",
15143 : sizeof(struct lsa_LookupSids2),
15144 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupSids2,
15145 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupSids2,
15146 : (ndr_print_function_t) ndr_print_lsa_LookupSids2,
15147 : { 0, NULL },
15148 : { 0, NULL },
15149 : },
15150 : {
15151 : "lsa_LookupNames2",
15152 : sizeof(struct lsa_LookupNames2),
15153 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupNames2,
15154 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupNames2,
15155 : (ndr_print_function_t) ndr_print_lsa_LookupNames2,
15156 : { 0, NULL },
15157 : { 0, NULL },
15158 : },
15159 : {
15160 : "lsa_CreateTrustedDomainEx2",
15161 : sizeof(struct lsa_CreateTrustedDomainEx2),
15162 : (ndr_push_flags_fn_t) ndr_push_lsa_CreateTrustedDomainEx2,
15163 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CreateTrustedDomainEx2,
15164 : (ndr_print_function_t) ndr_print_lsa_CreateTrustedDomainEx2,
15165 : { 0, NULL },
15166 : { 0, NULL },
15167 : },
15168 : {
15169 : "lsa_CREDRWRITE",
15170 : sizeof(struct lsa_CREDRWRITE),
15171 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRWRITE,
15172 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRWRITE,
15173 : (ndr_print_function_t) ndr_print_lsa_CREDRWRITE,
15174 : { 0, NULL },
15175 : { 0, NULL },
15176 : },
15177 : {
15178 : "lsa_CREDRREAD",
15179 : sizeof(struct lsa_CREDRREAD),
15180 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRREAD,
15181 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRREAD,
15182 : (ndr_print_function_t) ndr_print_lsa_CREDRREAD,
15183 : { 0, NULL },
15184 : { 0, NULL },
15185 : },
15186 : {
15187 : "lsa_CREDRENUMERATE",
15188 : sizeof(struct lsa_CREDRENUMERATE),
15189 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRENUMERATE,
15190 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRENUMERATE,
15191 : (ndr_print_function_t) ndr_print_lsa_CREDRENUMERATE,
15192 : { 0, NULL },
15193 : { 0, NULL },
15194 : },
15195 : {
15196 : "lsa_CREDRWRITEDOMAINCREDENTIALS",
15197 : sizeof(struct lsa_CREDRWRITEDOMAINCREDENTIALS),
15198 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRWRITEDOMAINCREDENTIALS,
15199 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRWRITEDOMAINCREDENTIALS,
15200 : (ndr_print_function_t) ndr_print_lsa_CREDRWRITEDOMAINCREDENTIALS,
15201 : { 0, NULL },
15202 : { 0, NULL },
15203 : },
15204 : {
15205 : "lsa_CREDRREADDOMAINCREDENTIALS",
15206 : sizeof(struct lsa_CREDRREADDOMAINCREDENTIALS),
15207 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRREADDOMAINCREDENTIALS,
15208 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRREADDOMAINCREDENTIALS,
15209 : (ndr_print_function_t) ndr_print_lsa_CREDRREADDOMAINCREDENTIALS,
15210 : { 0, NULL },
15211 : { 0, NULL },
15212 : },
15213 : {
15214 : "lsa_CREDRDELETE",
15215 : sizeof(struct lsa_CREDRDELETE),
15216 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRDELETE,
15217 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRDELETE,
15218 : (ndr_print_function_t) ndr_print_lsa_CREDRDELETE,
15219 : { 0, NULL },
15220 : { 0, NULL },
15221 : },
15222 : {
15223 : "lsa_CREDRGETTARGETINFO",
15224 : sizeof(struct lsa_CREDRGETTARGETINFO),
15225 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRGETTARGETINFO,
15226 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRGETTARGETINFO,
15227 : (ndr_print_function_t) ndr_print_lsa_CREDRGETTARGETINFO,
15228 : { 0, NULL },
15229 : { 0, NULL },
15230 : },
15231 : {
15232 : "lsa_CREDRPROFILELOADED",
15233 : sizeof(struct lsa_CREDRPROFILELOADED),
15234 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRPROFILELOADED,
15235 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRPROFILELOADED,
15236 : (ndr_print_function_t) ndr_print_lsa_CREDRPROFILELOADED,
15237 : { 0, NULL },
15238 : { 0, NULL },
15239 : },
15240 : {
15241 : "lsa_LookupNames3",
15242 : sizeof(struct lsa_LookupNames3),
15243 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupNames3,
15244 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupNames3,
15245 : (ndr_print_function_t) ndr_print_lsa_LookupNames3,
15246 : { 0, NULL },
15247 : { 0, NULL },
15248 : },
15249 : {
15250 : "lsa_CREDRGETSESSIONTYPES",
15251 : sizeof(struct lsa_CREDRGETSESSIONTYPES),
15252 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRGETSESSIONTYPES,
15253 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRGETSESSIONTYPES,
15254 : (ndr_print_function_t) ndr_print_lsa_CREDRGETSESSIONTYPES,
15255 : { 0, NULL },
15256 : { 0, NULL },
15257 : },
15258 : {
15259 : "lsa_LSARREGISTERAUDITEVENT",
15260 : sizeof(struct lsa_LSARREGISTERAUDITEVENT),
15261 : (ndr_push_flags_fn_t) ndr_push_lsa_LSARREGISTERAUDITEVENT,
15262 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LSARREGISTERAUDITEVENT,
15263 : (ndr_print_function_t) ndr_print_lsa_LSARREGISTERAUDITEVENT,
15264 : { 0, NULL },
15265 : { 0, NULL },
15266 : },
15267 : {
15268 : "lsa_LSARGENAUDITEVENT",
15269 : sizeof(struct lsa_LSARGENAUDITEVENT),
15270 : (ndr_push_flags_fn_t) ndr_push_lsa_LSARGENAUDITEVENT,
15271 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LSARGENAUDITEVENT,
15272 : (ndr_print_function_t) ndr_print_lsa_LSARGENAUDITEVENT,
15273 : { 0, NULL },
15274 : { 0, NULL },
15275 : },
15276 : {
15277 : "lsa_LSARUNREGISTERAUDITEVENT",
15278 : sizeof(struct lsa_LSARUNREGISTERAUDITEVENT),
15279 : (ndr_push_flags_fn_t) ndr_push_lsa_LSARUNREGISTERAUDITEVENT,
15280 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LSARUNREGISTERAUDITEVENT,
15281 : (ndr_print_function_t) ndr_print_lsa_LSARUNREGISTERAUDITEVENT,
15282 : { 0, NULL },
15283 : { 0, NULL },
15284 : },
15285 : {
15286 : "lsa_lsaRQueryForestTrustInformation",
15287 : sizeof(struct lsa_lsaRQueryForestTrustInformation),
15288 : (ndr_push_flags_fn_t) ndr_push_lsa_lsaRQueryForestTrustInformation,
15289 : (ndr_pull_flags_fn_t) ndr_pull_lsa_lsaRQueryForestTrustInformation,
15290 : (ndr_print_function_t) ndr_print_lsa_lsaRQueryForestTrustInformation,
15291 : { 0, NULL },
15292 : { 0, NULL },
15293 : },
15294 : {
15295 : "lsa_lsaRSetForestTrustInformation",
15296 : sizeof(struct lsa_lsaRSetForestTrustInformation),
15297 : (ndr_push_flags_fn_t) ndr_push_lsa_lsaRSetForestTrustInformation,
15298 : (ndr_pull_flags_fn_t) ndr_pull_lsa_lsaRSetForestTrustInformation,
15299 : (ndr_print_function_t) ndr_print_lsa_lsaRSetForestTrustInformation,
15300 : { 0, NULL },
15301 : { 0, NULL },
15302 : },
15303 : {
15304 : "lsa_CREDRRENAME",
15305 : sizeof(struct lsa_CREDRRENAME),
15306 : (ndr_push_flags_fn_t) ndr_push_lsa_CREDRRENAME,
15307 : (ndr_pull_flags_fn_t) ndr_pull_lsa_CREDRRENAME,
15308 : (ndr_print_function_t) ndr_print_lsa_CREDRRENAME,
15309 : { 0, NULL },
15310 : { 0, NULL },
15311 : },
15312 : {
15313 : "lsa_LookupSids3",
15314 : sizeof(struct lsa_LookupSids3),
15315 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupSids3,
15316 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupSids3,
15317 : (ndr_print_function_t) ndr_print_lsa_LookupSids3,
15318 : { 0, NULL },
15319 : { 0, NULL },
15320 : },
15321 : {
15322 : "lsa_LookupNames4",
15323 : sizeof(struct lsa_LookupNames4),
15324 : (ndr_push_flags_fn_t) ndr_push_lsa_LookupNames4,
15325 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LookupNames4,
15326 : (ndr_print_function_t) ndr_print_lsa_LookupNames4,
15327 : { 0, NULL },
15328 : { 0, NULL },
15329 : },
15330 : {
15331 : "lsa_LSAROPENPOLICYSCE",
15332 : sizeof(struct lsa_LSAROPENPOLICYSCE),
15333 : (ndr_push_flags_fn_t) ndr_push_lsa_LSAROPENPOLICYSCE,
15334 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LSAROPENPOLICYSCE,
15335 : (ndr_print_function_t) ndr_print_lsa_LSAROPENPOLICYSCE,
15336 : { 0, NULL },
15337 : { 0, NULL },
15338 : },
15339 : {
15340 : "lsa_LSARADTREGISTERSECURITYEVENTSOURCE",
15341 : sizeof(struct lsa_LSARADTREGISTERSECURITYEVENTSOURCE),
15342 : (ndr_push_flags_fn_t) ndr_push_lsa_LSARADTREGISTERSECURITYEVENTSOURCE,
15343 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LSARADTREGISTERSECURITYEVENTSOURCE,
15344 : (ndr_print_function_t) ndr_print_lsa_LSARADTREGISTERSECURITYEVENTSOURCE,
15345 : { 0, NULL },
15346 : { 0, NULL },
15347 : },
15348 : {
15349 : "lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE",
15350 : sizeof(struct lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE),
15351 : (ndr_push_flags_fn_t) ndr_push_lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE,
15352 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE,
15353 : (ndr_print_function_t) ndr_print_lsa_LSARADTUNREGISTERSECURITYEVENTSOURCE,
15354 : { 0, NULL },
15355 : { 0, NULL },
15356 : },
15357 : {
15358 : "lsa_LSARADTREPORTSECURITYEVENT",
15359 : sizeof(struct lsa_LSARADTREPORTSECURITYEVENT),
15360 : (ndr_push_flags_fn_t) ndr_push_lsa_LSARADTREPORTSECURITYEVENT,
15361 : (ndr_pull_flags_fn_t) ndr_pull_lsa_LSARADTREPORTSECURITYEVENT,
15362 : (ndr_print_function_t) ndr_print_lsa_LSARADTREPORTSECURITYEVENT,
15363 : { 0, NULL },
15364 : { 0, NULL },
15365 : },
15366 : { .name = NULL }
15367 : };
15368 :
15369 : static const char * const lsarpc_endpoint_strings[] = {
15370 : "ncacn_np:[\\pipe\\lsarpc]",
15371 : "ncacn_np:[\\pipe\\lsass]",
15372 : "ncacn_ip_tcp:",
15373 : "ncalrpc:",
15374 : };
15375 :
15376 : static const struct ndr_interface_string_array lsarpc_endpoints = {
15377 : .count = 4,
15378 : .names = lsarpc_endpoint_strings
15379 : };
15380 :
15381 : static const char * const lsarpc_authservice_strings[] = {
15382 : "host",
15383 : };
15384 :
15385 : static const struct ndr_interface_string_array lsarpc_authservices = {
15386 : .count = 1,
15387 : .names = lsarpc_authservice_strings
15388 : };
15389 :
15390 :
15391 : const struct ndr_interface_table ndr_table_lsarpc = {
15392 : .name = "lsarpc",
15393 : .syntax_id = {
15394 : {0x12345778,0x1234,0xabcd,{0xef,0x00},{0x01,0x23,0x45,0x67,0x89,0xab}},
15395 : NDR_LSARPC_VERSION
15396 : },
15397 : .helpstring = NDR_LSARPC_HELPSTRING,
15398 : .num_calls = 82,
15399 : .calls = lsarpc_calls,
15400 : .num_public_structs = 15,
15401 : .public_structs = lsarpc_public_structs,
15402 : .endpoints = &lsarpc_endpoints,
15403 : .authservices = &lsarpc_authservices
15404 : };
15405 :
15406 : #endif /* SKIP_NDR_TABLE_lsarpc */
|