Line data Source code
1 : /* parser auto-generated by pidl */
2 :
3 : #include "includes.h"
4 : #include "bin/default/librpc/gen_ndr/ndr_winbind.h"
5 :
6 : #include "librpc/gen_ndr/ndr_lsa.h"
7 : #include "librpc/gen_ndr/ndr_netlogon.h"
8 : #include "librpc/gen_ndr/ndr_samr.h"
9 : #include "librpc/gen_ndr/ndr_misc.h"
10 : #include "librpc/gen_ndr/ndr_security.h"
11 : #include "librpc/gen_ndr/ndr_idmap.h"
12 1753 : static enum ndr_err_code ndr_push_wbint_TransID(struct ndr_push *ndr, int ndr_flags, const struct wbint_TransID *r)
13 : {
14 1753 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
15 1753 : if (ndr_flags & NDR_SCALARS) {
16 1753 : NDR_CHECK(ndr_push_align(ndr, 4));
17 1753 : NDR_CHECK(ndr_push_id_type(ndr, NDR_SCALARS, r->type_hint));
18 1753 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->domain_index));
19 1753 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
20 1753 : NDR_CHECK(ndr_push_unixid(ndr, NDR_SCALARS, &r->xid));
21 1753 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
22 : }
23 1753 : if (ndr_flags & NDR_BUFFERS) {
24 : }
25 1753 : return NDR_ERR_SUCCESS;
26 : }
27 :
28 1706 : static enum ndr_err_code ndr_pull_wbint_TransID(struct ndr_pull *ndr, int ndr_flags, struct wbint_TransID *r)
29 : {
30 1706 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
31 1706 : if (ndr_flags & NDR_SCALARS) {
32 1706 : NDR_CHECK(ndr_pull_align(ndr, 4));
33 1706 : NDR_CHECK(ndr_pull_id_type(ndr, NDR_SCALARS, &r->type_hint));
34 1706 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->domain_index));
35 1706 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
36 1706 : NDR_CHECK(ndr_pull_unixid(ndr, NDR_SCALARS, &r->xid));
37 1706 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
38 : }
39 1706 : if (ndr_flags & NDR_BUFFERS) {
40 : }
41 1706 : return NDR_ERR_SUCCESS;
42 : }
43 :
44 0 : _PUBLIC_ void ndr_print_wbint_TransID(struct ndr_print *ndr, const char *name, const struct wbint_TransID *r)
45 : {
46 0 : ndr_print_struct(ndr, name, "wbint_TransID");
47 0 : if (r == NULL) { ndr_print_null(ndr); return; }
48 0 : ndr->depth++;
49 0 : ndr_print_id_type(ndr, "type_hint", r->type_hint);
50 0 : ndr_print_uint32(ndr, "domain_index", r->domain_index);
51 0 : ndr_print_uint32(ndr, "rid", r->rid);
52 0 : ndr_print_unixid(ndr, "xid", &r->xid);
53 0 : ndr->depth--;
54 : }
55 :
56 1400 : static enum ndr_err_code ndr_push_wbint_TransIDArray(struct ndr_push *ndr, int ndr_flags, const struct wbint_TransIDArray *r)
57 : {
58 : uint32_t cntr_ids_0;
59 1400 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
60 1400 : if (ndr_flags & NDR_SCALARS) {
61 1400 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_ids));
62 1400 : NDR_CHECK(ndr_push_align(ndr, 4));
63 1400 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_ids));
64 3153 : for (cntr_ids_0 = 0; cntr_ids_0 < (r->num_ids); cntr_ids_0++) {
65 1753 : NDR_CHECK(ndr_push_wbint_TransID(ndr, NDR_SCALARS, &r->ids[cntr_ids_0]));
66 : }
67 1400 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
68 : }
69 1400 : if (ndr_flags & NDR_BUFFERS) {
70 : }
71 1400 : return NDR_ERR_SUCCESS;
72 : }
73 :
74 1389 : static enum ndr_err_code ndr_pull_wbint_TransIDArray(struct ndr_pull *ndr, int ndr_flags, struct wbint_TransIDArray *r)
75 : {
76 1389 : uint32_t size_ids_0 = 0;
77 : uint32_t cntr_ids_0;
78 1389 : TALLOC_CTX *_mem_save_ids_0 = NULL;
79 1389 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
80 1389 : if (ndr_flags & NDR_SCALARS) {
81 1389 : NDR_CHECK(ndr_pull_array_size(ndr, &r->ids));
82 1389 : NDR_CHECK(ndr_pull_align(ndr, 4));
83 1389 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_ids));
84 1389 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->ids, &size_ids_0));
85 1389 : NDR_PULL_ALLOC_N(ndr, r->ids, size_ids_0);
86 1389 : _mem_save_ids_0 = NDR_PULL_GET_MEM_CTX(ndr);
87 1389 : NDR_PULL_SET_MEM_CTX(ndr, r->ids, 0);
88 3095 : for (cntr_ids_0 = 0; cntr_ids_0 < (size_ids_0); cntr_ids_0++) {
89 1706 : NDR_CHECK(ndr_pull_wbint_TransID(ndr, NDR_SCALARS, &r->ids[cntr_ids_0]));
90 : }
91 1389 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ids_0, 0);
92 1389 : if (r->ids) {
93 1389 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->ids, r->num_ids));
94 : }
95 1389 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
96 : }
97 1389 : if (ndr_flags & NDR_BUFFERS) {
98 : }
99 1389 : return NDR_ERR_SUCCESS;
100 : }
101 :
102 0 : _PUBLIC_ void ndr_print_wbint_TransIDArray(struct ndr_print *ndr, const char *name, const struct wbint_TransIDArray *r)
103 : {
104 : uint32_t cntr_ids_0;
105 0 : ndr_print_struct(ndr, name, "wbint_TransIDArray");
106 0 : if (r == NULL) { ndr_print_null(ndr); return; }
107 0 : ndr->depth++;
108 0 : ndr_print_uint32(ndr, "num_ids", r->num_ids);
109 0 : ndr->print(ndr, "%s: ARRAY(%d)", "ids", (int)r->num_ids);
110 0 : ndr->depth++;
111 0 : for (cntr_ids_0 = 0; cntr_ids_0 < (r->num_ids); cntr_ids_0++) {
112 0 : ndr_print_wbint_TransID(ndr, "ids", &r->ids[cntr_ids_0]);
113 : }
114 0 : ndr->depth--;
115 0 : ndr->depth--;
116 : }
117 :
118 4736 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_userinfo(struct ndr_push *ndr, int ndr_flags, const struct wbint_userinfo *r)
119 : {
120 4736 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
121 4736 : if (ndr_flags & NDR_SCALARS) {
122 4736 : NDR_CHECK(ndr_push_align(ndr, 8));
123 4736 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->domain_name));
124 4736 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->acct_name));
125 4736 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->full_name));
126 4736 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->homedir));
127 4736 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->shell));
128 4736 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->uid));
129 4736 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->primary_gid));
130 4736 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->primary_group_name));
131 4736 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->user_sid));
132 4736 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->group_sid));
133 4736 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
134 : }
135 4736 : if (ndr_flags & NDR_BUFFERS) {
136 4736 : if (r->domain_name) {
137 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain_name, CH_UTF8)));
138 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
139 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->domain_name, CH_UTF8)));
140 4736 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->domain_name, ndr_charset_length(r->domain_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
141 : }
142 4736 : if (r->acct_name) {
143 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->acct_name, CH_UTF8)));
144 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
145 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->acct_name, CH_UTF8)));
146 4736 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->acct_name, ndr_charset_length(r->acct_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
147 : }
148 4736 : if (r->full_name) {
149 1983 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->full_name, CH_UTF8)));
150 1983 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
151 1983 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->full_name, CH_UTF8)));
152 1983 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->full_name, ndr_charset_length(r->full_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
153 : }
154 4736 : if (r->homedir) {
155 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->homedir, CH_UTF8)));
156 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
157 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->homedir, CH_UTF8)));
158 4736 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->homedir, ndr_charset_length(r->homedir, CH_UTF8), sizeof(uint8_t), CH_UTF8));
159 : }
160 4736 : if (r->shell) {
161 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->shell, CH_UTF8)));
162 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
163 4736 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->shell, CH_UTF8)));
164 4736 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->shell, ndr_charset_length(r->shell, CH_UTF8), sizeof(uint8_t), CH_UTF8));
165 : }
166 4736 : if (r->primary_group_name) {
167 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->primary_group_name, CH_UTF8)));
168 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
169 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->primary_group_name, CH_UTF8)));
170 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->primary_group_name, ndr_charset_length(r->primary_group_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
171 : }
172 : }
173 4736 : return NDR_ERR_SUCCESS;
174 : }
175 :
176 4736 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_userinfo(struct ndr_pull *ndr, int ndr_flags, struct wbint_userinfo *r)
177 : {
178 : uint32_t _ptr_domain_name;
179 4736 : uint32_t size_domain_name_1 = 0;
180 4736 : uint32_t length_domain_name_1 = 0;
181 4736 : TALLOC_CTX *_mem_save_domain_name_0 = NULL;
182 : uint32_t _ptr_acct_name;
183 4736 : uint32_t size_acct_name_1 = 0;
184 4736 : uint32_t length_acct_name_1 = 0;
185 4736 : TALLOC_CTX *_mem_save_acct_name_0 = NULL;
186 : uint32_t _ptr_full_name;
187 4736 : uint32_t size_full_name_1 = 0;
188 4736 : uint32_t length_full_name_1 = 0;
189 4736 : TALLOC_CTX *_mem_save_full_name_0 = NULL;
190 : uint32_t _ptr_homedir;
191 4736 : uint32_t size_homedir_1 = 0;
192 4736 : uint32_t length_homedir_1 = 0;
193 4736 : TALLOC_CTX *_mem_save_homedir_0 = NULL;
194 : uint32_t _ptr_shell;
195 4736 : uint32_t size_shell_1 = 0;
196 4736 : uint32_t length_shell_1 = 0;
197 4736 : TALLOC_CTX *_mem_save_shell_0 = NULL;
198 : uint32_t _ptr_primary_group_name;
199 4736 : uint32_t size_primary_group_name_1 = 0;
200 4736 : uint32_t length_primary_group_name_1 = 0;
201 4736 : TALLOC_CTX *_mem_save_primary_group_name_0 = NULL;
202 4736 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
203 4736 : if (ndr_flags & NDR_SCALARS) {
204 4736 : NDR_CHECK(ndr_pull_align(ndr, 8));
205 4736 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain_name));
206 4736 : if (_ptr_domain_name) {
207 4736 : NDR_PULL_ALLOC(ndr, r->domain_name);
208 : } else {
209 0 : r->domain_name = NULL;
210 : }
211 4736 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_acct_name));
212 4736 : if (_ptr_acct_name) {
213 4736 : NDR_PULL_ALLOC(ndr, r->acct_name);
214 : } else {
215 0 : r->acct_name = NULL;
216 : }
217 4736 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_full_name));
218 4736 : if (_ptr_full_name) {
219 1985 : NDR_PULL_ALLOC(ndr, r->full_name);
220 : } else {
221 2751 : r->full_name = NULL;
222 : }
223 4736 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_homedir));
224 4736 : if (_ptr_homedir) {
225 4736 : NDR_PULL_ALLOC(ndr, r->homedir);
226 : } else {
227 0 : r->homedir = NULL;
228 : }
229 4736 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_shell));
230 4736 : if (_ptr_shell) {
231 4736 : NDR_PULL_ALLOC(ndr, r->shell);
232 : } else {
233 0 : r->shell = NULL;
234 : }
235 4736 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->uid));
236 4736 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->primary_gid));
237 4736 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_primary_group_name));
238 4736 : if (_ptr_primary_group_name) {
239 0 : NDR_PULL_ALLOC(ndr, r->primary_group_name);
240 : } else {
241 4736 : r->primary_group_name = NULL;
242 : }
243 4736 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->user_sid));
244 4736 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->group_sid));
245 4736 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
246 : }
247 4736 : if (ndr_flags & NDR_BUFFERS) {
248 4736 : if (r->domain_name) {
249 4736 : _mem_save_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
250 4736 : NDR_PULL_SET_MEM_CTX(ndr, r->domain_name, 0);
251 4736 : NDR_CHECK(ndr_pull_array_size(ndr, &r->domain_name));
252 4736 : NDR_CHECK(ndr_pull_array_length(ndr, &r->domain_name));
253 4736 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->domain_name, &size_domain_name_1));
254 4736 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->domain_name, &length_domain_name_1));
255 4736 : if (length_domain_name_1 > size_domain_name_1) {
256 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_name_1, length_domain_name_1);
257 : }
258 4736 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_name_1, sizeof(uint8_t)));
259 4736 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->domain_name, length_domain_name_1, sizeof(uint8_t), CH_UTF8));
260 4736 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_name_0, 0);
261 : }
262 4736 : if (r->acct_name) {
263 4736 : _mem_save_acct_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
264 4736 : NDR_PULL_SET_MEM_CTX(ndr, r->acct_name, 0);
265 4736 : NDR_CHECK(ndr_pull_array_size(ndr, &r->acct_name));
266 4736 : NDR_CHECK(ndr_pull_array_length(ndr, &r->acct_name));
267 4736 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->acct_name, &size_acct_name_1));
268 4736 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->acct_name, &length_acct_name_1));
269 4736 : if (length_acct_name_1 > size_acct_name_1) {
270 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_acct_name_1, length_acct_name_1);
271 : }
272 4736 : NDR_CHECK(ndr_check_string_terminator(ndr, length_acct_name_1, sizeof(uint8_t)));
273 4736 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->acct_name, length_acct_name_1, sizeof(uint8_t), CH_UTF8));
274 4736 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_acct_name_0, 0);
275 : }
276 4736 : if (r->full_name) {
277 1985 : _mem_save_full_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
278 1985 : NDR_PULL_SET_MEM_CTX(ndr, r->full_name, 0);
279 1985 : NDR_CHECK(ndr_pull_array_size(ndr, &r->full_name));
280 1985 : NDR_CHECK(ndr_pull_array_length(ndr, &r->full_name));
281 1985 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->full_name, &size_full_name_1));
282 1985 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->full_name, &length_full_name_1));
283 1985 : if (length_full_name_1 > size_full_name_1) {
284 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_full_name_1, length_full_name_1);
285 : }
286 1985 : NDR_CHECK(ndr_check_string_terminator(ndr, length_full_name_1, sizeof(uint8_t)));
287 1985 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->full_name, length_full_name_1, sizeof(uint8_t), CH_UTF8));
288 1985 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_full_name_0, 0);
289 : }
290 4736 : if (r->homedir) {
291 4736 : _mem_save_homedir_0 = NDR_PULL_GET_MEM_CTX(ndr);
292 4736 : NDR_PULL_SET_MEM_CTX(ndr, r->homedir, 0);
293 4736 : NDR_CHECK(ndr_pull_array_size(ndr, &r->homedir));
294 4736 : NDR_CHECK(ndr_pull_array_length(ndr, &r->homedir));
295 4736 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->homedir, &size_homedir_1));
296 4736 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->homedir, &length_homedir_1));
297 4736 : if (length_homedir_1 > size_homedir_1) {
298 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_homedir_1, length_homedir_1);
299 : }
300 4736 : NDR_CHECK(ndr_check_string_terminator(ndr, length_homedir_1, sizeof(uint8_t)));
301 4736 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->homedir, length_homedir_1, sizeof(uint8_t), CH_UTF8));
302 4736 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_homedir_0, 0);
303 : }
304 4736 : if (r->shell) {
305 4736 : _mem_save_shell_0 = NDR_PULL_GET_MEM_CTX(ndr);
306 4736 : NDR_PULL_SET_MEM_CTX(ndr, r->shell, 0);
307 4736 : NDR_CHECK(ndr_pull_array_size(ndr, &r->shell));
308 4736 : NDR_CHECK(ndr_pull_array_length(ndr, &r->shell));
309 4736 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->shell, &size_shell_1));
310 4736 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->shell, &length_shell_1));
311 4736 : if (length_shell_1 > size_shell_1) {
312 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_shell_1, length_shell_1);
313 : }
314 4736 : NDR_CHECK(ndr_check_string_terminator(ndr, length_shell_1, sizeof(uint8_t)));
315 4736 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->shell, length_shell_1, sizeof(uint8_t), CH_UTF8));
316 4736 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_shell_0, 0);
317 : }
318 4736 : if (r->primary_group_name) {
319 0 : _mem_save_primary_group_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
320 0 : NDR_PULL_SET_MEM_CTX(ndr, r->primary_group_name, 0);
321 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->primary_group_name));
322 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->primary_group_name));
323 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->primary_group_name, &size_primary_group_name_1));
324 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->primary_group_name, &length_primary_group_name_1));
325 0 : if (length_primary_group_name_1 > size_primary_group_name_1) {
326 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_primary_group_name_1, length_primary_group_name_1);
327 : }
328 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_primary_group_name_1, sizeof(uint8_t)));
329 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->primary_group_name, length_primary_group_name_1, sizeof(uint8_t), CH_UTF8));
330 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_primary_group_name_0, 0);
331 : }
332 : }
333 4736 : return NDR_ERR_SUCCESS;
334 : }
335 :
336 0 : static void ndr_print_flags_wbint_userinfo(struct ndr_print *ndr, const char *name, int unused, const struct wbint_userinfo *r)
337 : {
338 0 : ndr_print_wbint_userinfo(ndr, name, r);
339 0 : }
340 :
341 0 : _PUBLIC_ void ndr_print_wbint_userinfo(struct ndr_print *ndr, const char *name, const struct wbint_userinfo *r)
342 : {
343 0 : ndr_print_struct(ndr, name, "wbint_userinfo");
344 0 : if (r == NULL) { ndr_print_null(ndr); return; }
345 0 : ndr->depth++;
346 0 : ndr_print_ptr(ndr, "domain_name", r->domain_name);
347 0 : ndr->depth++;
348 0 : if (r->domain_name) {
349 0 : ndr_print_string(ndr, "domain_name", r->domain_name);
350 : }
351 0 : ndr->depth--;
352 0 : ndr_print_ptr(ndr, "acct_name", r->acct_name);
353 0 : ndr->depth++;
354 0 : if (r->acct_name) {
355 0 : ndr_print_string(ndr, "acct_name", r->acct_name);
356 : }
357 0 : ndr->depth--;
358 0 : ndr_print_ptr(ndr, "full_name", r->full_name);
359 0 : ndr->depth++;
360 0 : if (r->full_name) {
361 0 : ndr_print_string(ndr, "full_name", r->full_name);
362 : }
363 0 : ndr->depth--;
364 0 : ndr_print_ptr(ndr, "homedir", r->homedir);
365 0 : ndr->depth++;
366 0 : if (r->homedir) {
367 0 : ndr_print_string(ndr, "homedir", r->homedir);
368 : }
369 0 : ndr->depth--;
370 0 : ndr_print_ptr(ndr, "shell", r->shell);
371 0 : ndr->depth++;
372 0 : if (r->shell) {
373 0 : ndr_print_string(ndr, "shell", r->shell);
374 : }
375 0 : ndr->depth--;
376 0 : ndr_print_hyper(ndr, "uid", r->uid);
377 0 : ndr_print_hyper(ndr, "primary_gid", r->primary_gid);
378 0 : ndr_print_ptr(ndr, "primary_group_name", r->primary_group_name);
379 0 : ndr->depth++;
380 0 : if (r->primary_group_name) {
381 0 : ndr_print_string(ndr, "primary_group_name", r->primary_group_name);
382 : }
383 0 : ndr->depth--;
384 0 : ndr_print_dom_sid(ndr, "user_sid", &r->user_sid);
385 0 : ndr_print_dom_sid(ndr, "group_sid", &r->group_sid);
386 0 : ndr->depth--;
387 : }
388 :
389 1017 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_SidArray(struct ndr_push *ndr, int ndr_flags, const struct wbint_SidArray *r)
390 : {
391 : uint32_t cntr_sids_0;
392 1017 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
393 1017 : if (ndr_flags & NDR_SCALARS) {
394 1017 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_sids));
395 1017 : NDR_CHECK(ndr_push_align(ndr, 4));
396 1017 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_sids));
397 1708 : for (cntr_sids_0 = 0; cntr_sids_0 < (r->num_sids); cntr_sids_0++) {
398 691 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->sids[cntr_sids_0]));
399 : }
400 1017 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
401 : }
402 1017 : if (ndr_flags & NDR_BUFFERS) {
403 : }
404 1017 : return NDR_ERR_SUCCESS;
405 : }
406 :
407 40 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_SidArray(struct ndr_pull *ndr, int ndr_flags, struct wbint_SidArray *r)
408 : {
409 40 : uint32_t size_sids_0 = 0;
410 : uint32_t cntr_sids_0;
411 40 : TALLOC_CTX *_mem_save_sids_0 = NULL;
412 40 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
413 40 : if (ndr_flags & NDR_SCALARS) {
414 40 : NDR_CHECK(ndr_pull_array_size(ndr, &r->sids));
415 40 : NDR_CHECK(ndr_pull_align(ndr, 4));
416 40 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_sids));
417 40 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->sids, &size_sids_0));
418 40 : NDR_PULL_ALLOC_N(ndr, r->sids, size_sids_0);
419 40 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
420 40 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
421 103 : for (cntr_sids_0 = 0; cntr_sids_0 < (size_sids_0); cntr_sids_0++) {
422 63 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->sids[cntr_sids_0]));
423 : }
424 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, 0);
425 40 : if (r->sids) {
426 40 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->sids, r->num_sids));
427 : }
428 40 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
429 : }
430 40 : if (ndr_flags & NDR_BUFFERS) {
431 : }
432 40 : return NDR_ERR_SUCCESS;
433 : }
434 :
435 0 : static void ndr_print_flags_wbint_SidArray(struct ndr_print *ndr, const char *name, int unused, const struct wbint_SidArray *r)
436 : {
437 0 : ndr_print_wbint_SidArray(ndr, name, r);
438 0 : }
439 :
440 0 : _PUBLIC_ void ndr_print_wbint_SidArray(struct ndr_print *ndr, const char *name, const struct wbint_SidArray *r)
441 : {
442 : uint32_t cntr_sids_0;
443 0 : ndr_print_struct(ndr, name, "wbint_SidArray");
444 0 : if (r == NULL) { ndr_print_null(ndr); return; }
445 0 : ndr->depth++;
446 0 : ndr_print_uint32(ndr, "num_sids", r->num_sids);
447 0 : ndr->print(ndr, "%s: ARRAY(%d)", "sids", (int)r->num_sids);
448 0 : ndr->depth++;
449 0 : for (cntr_sids_0 = 0; cntr_sids_0 < (r->num_sids); cntr_sids_0++) {
450 0 : ndr_print_dom_sid(ndr, "sids", &r->sids[cntr_sids_0]);
451 : }
452 0 : ndr->depth--;
453 0 : ndr->depth--;
454 : }
455 :
456 50 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_RidArray(struct ndr_push *ndr, int ndr_flags, const struct wbint_RidArray *r)
457 : {
458 : uint32_t cntr_rids_0;
459 50 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
460 50 : if (ndr_flags & NDR_SCALARS) {
461 50 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_rids));
462 50 : NDR_CHECK(ndr_push_align(ndr, 4));
463 50 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_rids));
464 288 : for (cntr_rids_0 = 0; cntr_rids_0 < (r->num_rids); cntr_rids_0++) {
465 238 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rids[cntr_rids_0]));
466 : }
467 50 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
468 : }
469 50 : if (ndr_flags & NDR_BUFFERS) {
470 : }
471 50 : return NDR_ERR_SUCCESS;
472 : }
473 :
474 248 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_RidArray(struct ndr_pull *ndr, int ndr_flags, struct wbint_RidArray *r)
475 : {
476 248 : uint32_t size_rids_0 = 0;
477 : uint32_t cntr_rids_0;
478 248 : TALLOC_CTX *_mem_save_rids_0 = NULL;
479 248 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
480 248 : if (ndr_flags & NDR_SCALARS) {
481 248 : NDR_CHECK(ndr_pull_array_size(ndr, &r->rids));
482 248 : NDR_CHECK(ndr_pull_align(ndr, 4));
483 248 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_rids));
484 248 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->rids, &size_rids_0));
485 248 : NDR_PULL_ALLOC_N(ndr, r->rids, size_rids_0);
486 248 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
487 248 : NDR_PULL_SET_MEM_CTX(ndr, r->rids, 0);
488 705 : for (cntr_rids_0 = 0; cntr_rids_0 < (size_rids_0); cntr_rids_0++) {
489 457 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rids[cntr_rids_0]));
490 : }
491 248 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, 0);
492 248 : if (r->rids) {
493 248 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->rids, r->num_rids));
494 : }
495 248 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
496 : }
497 248 : if (ndr_flags & NDR_BUFFERS) {
498 : }
499 248 : return NDR_ERR_SUCCESS;
500 : }
501 :
502 0 : static void ndr_print_flags_wbint_RidArray(struct ndr_print *ndr, const char *name, int unused, const struct wbint_RidArray *r)
503 : {
504 0 : ndr_print_wbint_RidArray(ndr, name, r);
505 0 : }
506 :
507 0 : _PUBLIC_ void ndr_print_wbint_RidArray(struct ndr_print *ndr, const char *name, const struct wbint_RidArray *r)
508 : {
509 : uint32_t cntr_rids_0;
510 0 : ndr_print_struct(ndr, name, "wbint_RidArray");
511 0 : if (r == NULL) { ndr_print_null(ndr); return; }
512 0 : ndr->depth++;
513 0 : ndr_print_uint32(ndr, "num_rids", r->num_rids);
514 0 : ndr->print(ndr, "%s: ARRAY(%d)", "rids", (int)r->num_rids);
515 0 : ndr->depth++;
516 0 : for (cntr_rids_0 = 0; cntr_rids_0 < (r->num_rids); cntr_rids_0++) {
517 0 : ndr_print_uint32(ndr, "rids", r->rids[cntr_rids_0]);
518 : }
519 0 : ndr->depth--;
520 0 : ndr->depth--;
521 : }
522 :
523 0 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_Principal(struct ndr_push *ndr, int ndr_flags, const struct wbint_Principal *r)
524 : {
525 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
526 0 : if (ndr_flags & NDR_SCALARS) {
527 0 : NDR_CHECK(ndr_push_align(ndr, 5));
528 0 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->sid));
529 0 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, r->type));
530 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
531 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
532 : }
533 0 : if (ndr_flags & NDR_BUFFERS) {
534 0 : if (r->name) {
535 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF8)));
536 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
537 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->name, CH_UTF8)));
538 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, ndr_charset_length(r->name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
539 : }
540 : }
541 0 : return NDR_ERR_SUCCESS;
542 : }
543 :
544 5818 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_Principal(struct ndr_pull *ndr, int ndr_flags, struct wbint_Principal *r)
545 : {
546 : uint32_t _ptr_name;
547 5818 : uint32_t size_name_1 = 0;
548 5818 : uint32_t length_name_1 = 0;
549 5818 : TALLOC_CTX *_mem_save_name_0 = NULL;
550 5818 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
551 5818 : if (ndr_flags & NDR_SCALARS) {
552 2909 : NDR_CHECK(ndr_pull_align(ndr, 5));
553 2909 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->sid));
554 2909 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, &r->type));
555 2909 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
556 2909 : if (_ptr_name) {
557 2909 : NDR_PULL_ALLOC(ndr, r->name);
558 : } else {
559 0 : r->name = NULL;
560 : }
561 2909 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
562 : }
563 5818 : if (ndr_flags & NDR_BUFFERS) {
564 2909 : if (r->name) {
565 2909 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
566 2909 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
567 2909 : NDR_CHECK(ndr_pull_array_size(ndr, &r->name));
568 2909 : NDR_CHECK(ndr_pull_array_length(ndr, &r->name));
569 2909 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->name, &size_name_1));
570 2909 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->name, &length_name_1));
571 2909 : if (length_name_1 > size_name_1) {
572 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_name_1, length_name_1);
573 : }
574 2909 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint8_t)));
575 2909 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->name, length_name_1, sizeof(uint8_t), CH_UTF8));
576 2909 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
577 : }
578 : }
579 5818 : return NDR_ERR_SUCCESS;
580 : }
581 :
582 0 : static void ndr_print_flags_wbint_Principal(struct ndr_print *ndr, const char *name, int unused, const struct wbint_Principal *r)
583 : {
584 0 : ndr_print_wbint_Principal(ndr, name, r);
585 0 : }
586 :
587 0 : _PUBLIC_ void ndr_print_wbint_Principal(struct ndr_print *ndr, const char *name, const struct wbint_Principal *r)
588 : {
589 0 : ndr_print_struct(ndr, name, "wbint_Principal");
590 0 : if (r == NULL) { ndr_print_null(ndr); return; }
591 0 : ndr->depth++;
592 0 : ndr_print_dom_sid(ndr, "sid", &r->sid);
593 0 : ndr_print_lsa_SidType(ndr, "type", r->type);
594 0 : ndr_print_ptr(ndr, "name", r->name);
595 0 : ndr->depth++;
596 0 : if (r->name) {
597 0 : ndr_print_string(ndr, "name", r->name);
598 : }
599 0 : ndr->depth--;
600 0 : ndr->depth--;
601 : }
602 :
603 0 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_Principals(struct ndr_push *ndr, int ndr_flags, const struct wbint_Principals *r)
604 : {
605 : uint32_t cntr_principals_0;
606 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
607 0 : if (ndr_flags & NDR_SCALARS) {
608 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_principals));
609 0 : NDR_CHECK(ndr_push_align(ndr, 5));
610 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_principals));
611 0 : for (cntr_principals_0 = 0; cntr_principals_0 < (r->num_principals); cntr_principals_0++) {
612 0 : NDR_CHECK(ndr_push_wbint_Principal(ndr, NDR_SCALARS, &r->principals[cntr_principals_0]));
613 : }
614 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
615 : }
616 0 : if (ndr_flags & NDR_BUFFERS) {
617 0 : for (cntr_principals_0 = 0; cntr_principals_0 < (r->num_principals); cntr_principals_0++) {
618 0 : NDR_CHECK(ndr_push_wbint_Principal(ndr, NDR_BUFFERS, &r->principals[cntr_principals_0]));
619 : }
620 : }
621 0 : return NDR_ERR_SUCCESS;
622 : }
623 :
624 623 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_Principals(struct ndr_pull *ndr, int ndr_flags, struct wbint_Principals *r)
625 : {
626 623 : uint32_t size_principals_0 = 0;
627 : uint32_t cntr_principals_0;
628 623 : TALLOC_CTX *_mem_save_principals_0 = NULL;
629 623 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
630 623 : if (ndr_flags & NDR_SCALARS) {
631 623 : NDR_CHECK(ndr_pull_array_size(ndr, &r->principals));
632 623 : NDR_CHECK(ndr_pull_align(ndr, 5));
633 623 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_principals));
634 623 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->principals, &size_principals_0));
635 623 : NDR_PULL_ALLOC_N(ndr, r->principals, size_principals_0);
636 623 : _mem_save_principals_0 = NDR_PULL_GET_MEM_CTX(ndr);
637 623 : NDR_PULL_SET_MEM_CTX(ndr, r->principals, 0);
638 3532 : for (cntr_principals_0 = 0; cntr_principals_0 < (size_principals_0); cntr_principals_0++) {
639 2909 : NDR_CHECK(ndr_pull_wbint_Principal(ndr, NDR_SCALARS, &r->principals[cntr_principals_0]));
640 : }
641 623 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_principals_0, 0);
642 623 : if (r->principals) {
643 623 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->principals, r->num_principals));
644 : }
645 623 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
646 : }
647 623 : if (ndr_flags & NDR_BUFFERS) {
648 623 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->principals, &size_principals_0));
649 623 : _mem_save_principals_0 = NDR_PULL_GET_MEM_CTX(ndr);
650 623 : NDR_PULL_SET_MEM_CTX(ndr, r->principals, 0);
651 3532 : for (cntr_principals_0 = 0; cntr_principals_0 < (size_principals_0); cntr_principals_0++) {
652 2909 : NDR_CHECK(ndr_pull_wbint_Principal(ndr, NDR_BUFFERS, &r->principals[cntr_principals_0]));
653 : }
654 623 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_principals_0, 0);
655 1999 : for (cntr_principals_0 = 0; cntr_principals_0 < (size_principals_0); cntr_principals_0++) {
656 : }
657 : }
658 623 : return NDR_ERR_SUCCESS;
659 : }
660 :
661 0 : static void ndr_print_flags_wbint_Principals(struct ndr_print *ndr, const char *name, int unused, const struct wbint_Principals *r)
662 : {
663 0 : ndr_print_wbint_Principals(ndr, name, r);
664 0 : }
665 :
666 0 : _PUBLIC_ void ndr_print_wbint_Principals(struct ndr_print *ndr, const char *name, const struct wbint_Principals *r)
667 : {
668 : uint32_t cntr_principals_0;
669 0 : ndr_print_struct(ndr, name, "wbint_Principals");
670 0 : if (r == NULL) { ndr_print_null(ndr); return; }
671 0 : ndr->depth++;
672 0 : ndr_print_uint32(ndr, "num_principals", r->num_principals);
673 0 : ndr->print(ndr, "%s: ARRAY(%d)", "principals", (int)r->num_principals);
674 0 : ndr->depth++;
675 0 : for (cntr_principals_0 = 0; cntr_principals_0 < (r->num_principals); cntr_principals_0++) {
676 0 : ndr_print_wbint_Principal(ndr, "principals", &r->principals[cntr_principals_0]);
677 : }
678 0 : ndr->depth--;
679 0 : ndr->depth--;
680 : }
681 :
682 0 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_userinfos(struct ndr_push *ndr, int ndr_flags, const struct wbint_userinfos *r)
683 : {
684 : uint32_t cntr_userinfos_0;
685 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
686 0 : if (ndr_flags & NDR_SCALARS) {
687 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_userinfos));
688 0 : NDR_CHECK(ndr_push_align(ndr, 8));
689 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_userinfos));
690 0 : for (cntr_userinfos_0 = 0; cntr_userinfos_0 < (r->num_userinfos); cntr_userinfos_0++) {
691 0 : NDR_CHECK(ndr_push_wbint_userinfo(ndr, NDR_SCALARS, &r->userinfos[cntr_userinfos_0]));
692 : }
693 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
694 : }
695 0 : if (ndr_flags & NDR_BUFFERS) {
696 0 : for (cntr_userinfos_0 = 0; cntr_userinfos_0 < (r->num_userinfos); cntr_userinfos_0++) {
697 0 : NDR_CHECK(ndr_push_wbint_userinfo(ndr, NDR_BUFFERS, &r->userinfos[cntr_userinfos_0]));
698 : }
699 : }
700 0 : return NDR_ERR_SUCCESS;
701 : }
702 :
703 0 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_userinfos(struct ndr_pull *ndr, int ndr_flags, struct wbint_userinfos *r)
704 : {
705 0 : uint32_t size_userinfos_0 = 0;
706 : uint32_t cntr_userinfos_0;
707 0 : TALLOC_CTX *_mem_save_userinfos_0 = NULL;
708 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
709 0 : if (ndr_flags & NDR_SCALARS) {
710 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->userinfos));
711 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
712 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_userinfos));
713 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->userinfos, &size_userinfos_0));
714 0 : NDR_PULL_ALLOC_N(ndr, r->userinfos, size_userinfos_0);
715 0 : _mem_save_userinfos_0 = NDR_PULL_GET_MEM_CTX(ndr);
716 0 : NDR_PULL_SET_MEM_CTX(ndr, r->userinfos, 0);
717 0 : for (cntr_userinfos_0 = 0; cntr_userinfos_0 < (size_userinfos_0); cntr_userinfos_0++) {
718 0 : NDR_CHECK(ndr_pull_wbint_userinfo(ndr, NDR_SCALARS, &r->userinfos[cntr_userinfos_0]));
719 : }
720 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_userinfos_0, 0);
721 0 : if (r->userinfos) {
722 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->userinfos, r->num_userinfos));
723 : }
724 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
725 : }
726 0 : if (ndr_flags & NDR_BUFFERS) {
727 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->userinfos, &size_userinfos_0));
728 0 : _mem_save_userinfos_0 = NDR_PULL_GET_MEM_CTX(ndr);
729 0 : NDR_PULL_SET_MEM_CTX(ndr, r->userinfos, 0);
730 0 : for (cntr_userinfos_0 = 0; cntr_userinfos_0 < (size_userinfos_0); cntr_userinfos_0++) {
731 0 : NDR_CHECK(ndr_pull_wbint_userinfo(ndr, NDR_BUFFERS, &r->userinfos[cntr_userinfos_0]));
732 : }
733 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_userinfos_0, 0);
734 0 : for (cntr_userinfos_0 = 0; cntr_userinfos_0 < (size_userinfos_0); cntr_userinfos_0++) {
735 : }
736 : }
737 0 : return NDR_ERR_SUCCESS;
738 : }
739 :
740 0 : static void ndr_print_flags_wbint_userinfos(struct ndr_print *ndr, const char *name, int unused, const struct wbint_userinfos *r)
741 : {
742 0 : ndr_print_wbint_userinfos(ndr, name, r);
743 0 : }
744 :
745 0 : _PUBLIC_ void ndr_print_wbint_userinfos(struct ndr_print *ndr, const char *name, const struct wbint_userinfos *r)
746 : {
747 : uint32_t cntr_userinfos_0;
748 0 : ndr_print_struct(ndr, name, "wbint_userinfos");
749 0 : if (r == NULL) { ndr_print_null(ndr); return; }
750 0 : ndr->depth++;
751 0 : ndr_print_uint32(ndr, "num_userinfos", r->num_userinfos);
752 0 : ndr->print(ndr, "%s: ARRAY(%d)", "userinfos", (int)r->num_userinfos);
753 0 : ndr->depth++;
754 0 : for (cntr_userinfos_0 = 0; cntr_userinfos_0 < (r->num_userinfos); cntr_userinfos_0++) {
755 0 : ndr_print_wbint_userinfo(ndr, "userinfos", &r->userinfos[cntr_userinfos_0]);
756 : }
757 0 : ndr->depth--;
758 0 : ndr->depth--;
759 : }
760 :
761 0 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_Validation(struct ndr_push *ndr, int ndr_flags, const struct wbint_Validation *r)
762 : {
763 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
764 0 : if (ndr_flags & NDR_SCALARS) {
765 0 : NDR_CHECK(ndr_push_align(ndr, 5));
766 0 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->level));
767 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->validation));
768 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->krb5ccname));
769 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
770 : }
771 0 : if (ndr_flags & NDR_BUFFERS) {
772 0 : if (r->validation) {
773 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->validation, r->level));
774 0 : NDR_CHECK(ndr_push_netr_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, r->validation));
775 : }
776 0 : if (r->krb5ccname) {
777 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->krb5ccname, CH_UTF8)));
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->krb5ccname, CH_UTF8)));
780 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->krb5ccname, ndr_charset_length(r->krb5ccname, CH_UTF8), sizeof(uint8_t), CH_UTF8));
781 : }
782 : }
783 0 : return NDR_ERR_SUCCESS;
784 : }
785 :
786 392 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_Validation(struct ndr_pull *ndr, int ndr_flags, struct wbint_Validation *r)
787 : {
788 : uint32_t _ptr_validation;
789 392 : TALLOC_CTX *_mem_save_validation_0 = NULL;
790 : uint32_t _ptr_krb5ccname;
791 392 : uint32_t size_krb5ccname_1 = 0;
792 392 : uint32_t length_krb5ccname_1 = 0;
793 392 : TALLOC_CTX *_mem_save_krb5ccname_0 = NULL;
794 392 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
795 392 : if (ndr_flags & NDR_SCALARS) {
796 392 : NDR_CHECK(ndr_pull_align(ndr, 5));
797 392 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->level));
798 392 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_validation));
799 392 : if (_ptr_validation) {
800 278 : NDR_PULL_ALLOC(ndr, r->validation);
801 : } else {
802 114 : r->validation = NULL;
803 : }
804 392 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_krb5ccname));
805 392 : if (_ptr_krb5ccname) {
806 34 : NDR_PULL_ALLOC(ndr, r->krb5ccname);
807 : } else {
808 358 : r->krb5ccname = NULL;
809 : }
810 392 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
811 : }
812 392 : if (ndr_flags & NDR_BUFFERS) {
813 392 : if (r->validation) {
814 278 : _mem_save_validation_0 = NDR_PULL_GET_MEM_CTX(ndr);
815 278 : NDR_PULL_SET_MEM_CTX(ndr, r->validation, 0);
816 278 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->validation, r->level));
817 278 : NDR_CHECK(ndr_pull_netr_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, r->validation));
818 278 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_validation_0, 0);
819 : }
820 392 : if (r->krb5ccname) {
821 34 : _mem_save_krb5ccname_0 = NDR_PULL_GET_MEM_CTX(ndr);
822 34 : NDR_PULL_SET_MEM_CTX(ndr, r->krb5ccname, 0);
823 34 : NDR_CHECK(ndr_pull_array_size(ndr, &r->krb5ccname));
824 34 : NDR_CHECK(ndr_pull_array_length(ndr, &r->krb5ccname));
825 34 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->krb5ccname, &size_krb5ccname_1));
826 34 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->krb5ccname, &length_krb5ccname_1));
827 34 : if (length_krb5ccname_1 > size_krb5ccname_1) {
828 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_krb5ccname_1, length_krb5ccname_1);
829 : }
830 34 : NDR_CHECK(ndr_check_string_terminator(ndr, length_krb5ccname_1, sizeof(uint8_t)));
831 34 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->krb5ccname, length_krb5ccname_1, sizeof(uint8_t), CH_UTF8));
832 34 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_krb5ccname_0, 0);
833 : }
834 : }
835 392 : return NDR_ERR_SUCCESS;
836 : }
837 :
838 0 : static void ndr_print_flags_wbint_Validation(struct ndr_print *ndr, const char *name, int unused, const struct wbint_Validation *r)
839 : {
840 0 : ndr_print_wbint_Validation(ndr, name, r);
841 0 : }
842 :
843 0 : _PUBLIC_ void ndr_print_wbint_Validation(struct ndr_print *ndr, const char *name, const struct wbint_Validation *r)
844 : {
845 0 : ndr_print_struct(ndr, name, "wbint_Validation");
846 0 : if (r == NULL) { ndr_print_null(ndr); return; }
847 0 : ndr->depth++;
848 0 : ndr_print_uint16(ndr, "level", r->level);
849 0 : ndr_print_ptr(ndr, "validation", r->validation);
850 0 : ndr->depth++;
851 0 : if (r->validation) {
852 0 : ndr_print_set_switch_value(ndr, r->validation, r->level);
853 0 : ndr_print_netr_Validation(ndr, "validation", r->validation);
854 : }
855 0 : ndr->depth--;
856 0 : ndr_print_ptr(ndr, "krb5ccname", r->krb5ccname);
857 0 : ndr->depth++;
858 0 : if (r->krb5ccname) {
859 0 : ndr_print_string(ndr, "krb5ccname", r->krb5ccname);
860 : }
861 0 : ndr->depth--;
862 0 : ndr->depth--;
863 : }
864 :
865 392 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_AuthUserInfo(struct ndr_push *ndr, int ndr_flags, const struct wbint_AuthUserInfo *r)
866 : {
867 392 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
868 392 : if (ndr_flags & NDR_SCALARS) {
869 392 : NDR_CHECK(ndr_push_align(ndr, 8));
870 392 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->username));
871 : {
872 392 : uint32_t _flags_save_uint8 = ndr->flags;
873 392 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
874 392 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->password));
875 392 : ndr->flags = _flags_save_uint8;
876 : }
877 392 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->krb5_cc_type));
878 392 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->uid));
879 392 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
880 : }
881 392 : if (ndr_flags & NDR_BUFFERS) {
882 392 : if (r->username) {
883 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->username, CH_UTF8)));
884 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
885 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->username, CH_UTF8)));
886 392 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->username, ndr_charset_length(r->username, CH_UTF8), sizeof(uint8_t), CH_UTF8));
887 : }
888 : {
889 392 : uint32_t _flags_save_uint8 = ndr->flags;
890 392 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
891 392 : if (r->password) {
892 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->password, CH_UTF8)));
893 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
894 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->password, CH_UTF8)));
895 392 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->password, ndr_charset_length(r->password, CH_UTF8), sizeof(uint8_t), CH_UTF8));
896 : }
897 392 : ndr->flags = _flags_save_uint8;
898 : }
899 392 : if (r->krb5_cc_type) {
900 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->krb5_cc_type, CH_UTF8)));
901 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
902 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->krb5_cc_type, CH_UTF8)));
903 392 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->krb5_cc_type, ndr_charset_length(r->krb5_cc_type, CH_UTF8), sizeof(uint8_t), CH_UTF8));
904 : }
905 : }
906 392 : return NDR_ERR_SUCCESS;
907 : }
908 :
909 0 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_AuthUserInfo(struct ndr_pull *ndr, int ndr_flags, struct wbint_AuthUserInfo *r)
910 : {
911 : uint32_t _ptr_username;
912 0 : uint32_t size_username_1 = 0;
913 0 : uint32_t length_username_1 = 0;
914 0 : TALLOC_CTX *_mem_save_username_0 = NULL;
915 : uint32_t _ptr_password;
916 0 : uint32_t size_password_1 = 0;
917 0 : uint32_t length_password_1 = 0;
918 0 : TALLOC_CTX *_mem_save_password_0 = NULL;
919 : uint32_t _ptr_krb5_cc_type;
920 0 : uint32_t size_krb5_cc_type_1 = 0;
921 0 : uint32_t length_krb5_cc_type_1 = 0;
922 0 : TALLOC_CTX *_mem_save_krb5_cc_type_0 = NULL;
923 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
924 0 : if (ndr_flags & NDR_SCALARS) {
925 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
926 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_username));
927 0 : if (_ptr_username) {
928 0 : NDR_PULL_ALLOC(ndr, r->username);
929 : } else {
930 0 : r->username = NULL;
931 : }
932 : {
933 0 : uint32_t _flags_save_uint8 = ndr->flags;
934 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
935 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_password));
936 0 : if (_ptr_password) {
937 0 : NDR_PULL_ALLOC(ndr, r->password);
938 : } else {
939 0 : r->password = NULL;
940 : }
941 0 : ndr->flags = _flags_save_uint8;
942 : }
943 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_krb5_cc_type));
944 0 : if (_ptr_krb5_cc_type) {
945 0 : NDR_PULL_ALLOC(ndr, r->krb5_cc_type);
946 : } else {
947 0 : r->krb5_cc_type = NULL;
948 : }
949 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->uid));
950 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
951 : }
952 0 : if (ndr_flags & NDR_BUFFERS) {
953 0 : if (r->username) {
954 0 : _mem_save_username_0 = NDR_PULL_GET_MEM_CTX(ndr);
955 0 : NDR_PULL_SET_MEM_CTX(ndr, r->username, 0);
956 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->username));
957 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->username));
958 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->username, &size_username_1));
959 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->username, &length_username_1));
960 0 : if (length_username_1 > size_username_1) {
961 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_username_1, length_username_1);
962 : }
963 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_username_1, sizeof(uint8_t)));
964 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->username, length_username_1, sizeof(uint8_t), CH_UTF8));
965 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_username_0, 0);
966 : }
967 : {
968 0 : uint32_t _flags_save_uint8 = ndr->flags;
969 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
970 0 : if (r->password) {
971 0 : _mem_save_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
972 0 : NDR_PULL_SET_MEM_CTX(ndr, r->password, 0);
973 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->password));
974 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->password));
975 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->password, &size_password_1));
976 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->password, &length_password_1));
977 0 : if (length_password_1 > size_password_1) {
978 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_password_1, length_password_1);
979 : }
980 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_password_1, sizeof(uint8_t)));
981 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->password, length_password_1, sizeof(uint8_t), CH_UTF8));
982 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_password_0, 0);
983 : }
984 0 : ndr->flags = _flags_save_uint8;
985 : }
986 0 : if (r->krb5_cc_type) {
987 0 : _mem_save_krb5_cc_type_0 = NDR_PULL_GET_MEM_CTX(ndr);
988 0 : NDR_PULL_SET_MEM_CTX(ndr, r->krb5_cc_type, 0);
989 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->krb5_cc_type));
990 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->krb5_cc_type));
991 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->krb5_cc_type, &size_krb5_cc_type_1));
992 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->krb5_cc_type, &length_krb5_cc_type_1));
993 0 : if (length_krb5_cc_type_1 > size_krb5_cc_type_1) {
994 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_krb5_cc_type_1, length_krb5_cc_type_1);
995 : }
996 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_krb5_cc_type_1, sizeof(uint8_t)));
997 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->krb5_cc_type, length_krb5_cc_type_1, sizeof(uint8_t), CH_UTF8));
998 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_krb5_cc_type_0, 0);
999 : }
1000 : }
1001 0 : return NDR_ERR_SUCCESS;
1002 : }
1003 :
1004 0 : static void ndr_print_flags_wbint_AuthUserInfo(struct ndr_print *ndr, const char *name, int unused, const struct wbint_AuthUserInfo *r)
1005 : {
1006 0 : ndr_print_wbint_AuthUserInfo(ndr, name, r);
1007 0 : }
1008 :
1009 0 : _PUBLIC_ void ndr_print_wbint_AuthUserInfo(struct ndr_print *ndr, const char *name, const struct wbint_AuthUserInfo *r)
1010 : {
1011 0 : ndr_print_struct(ndr, name, "wbint_AuthUserInfo");
1012 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1013 0 : ndr->depth++;
1014 0 : ndr_print_ptr(ndr, "username", r->username);
1015 0 : ndr->depth++;
1016 0 : if (r->username) {
1017 0 : ndr_print_string(ndr, "username", r->username);
1018 : }
1019 0 : ndr->depth--;
1020 : {
1021 0 : uint32_t _flags_save_uint8 = ndr->flags;
1022 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
1023 0 : ndr_print_ptr(ndr, "password", r->password);
1024 0 : ndr->depth++;
1025 0 : if (r->password) {
1026 0 : ndr_print_string(ndr, "password", r->password);
1027 : }
1028 0 : ndr->depth--;
1029 0 : ndr->flags = _flags_save_uint8;
1030 : }
1031 0 : ndr_print_ptr(ndr, "krb5_cc_type", r->krb5_cc_type);
1032 0 : ndr->depth++;
1033 0 : if (r->krb5_cc_type) {
1034 0 : ndr_print_string(ndr, "krb5_cc_type", r->krb5_cc_type);
1035 : }
1036 0 : ndr->depth--;
1037 0 : ndr_print_hyper(ndr, "uid", r->uid);
1038 0 : ndr->depth--;
1039 : }
1040 :
1041 0 : _PUBLIC_ enum ndr_err_code ndr_push_wbint_PamAuthCrapValidation(struct ndr_push *ndr, int ndr_flags, const struct wbint_PamAuthCrapValidation *r)
1042 : {
1043 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1044 0 : if (ndr_flags & NDR_SCALARS) {
1045 0 : NDR_CHECK(ndr_push_align(ndr, 5));
1046 0 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->level));
1047 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->validation));
1048 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1049 : }
1050 0 : if (ndr_flags & NDR_BUFFERS) {
1051 0 : if (r->validation) {
1052 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->validation, r->level));
1053 0 : NDR_CHECK(ndr_push_netr_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, r->validation));
1054 : }
1055 : }
1056 0 : return NDR_ERR_SUCCESS;
1057 : }
1058 :
1059 458 : _PUBLIC_ enum ndr_err_code ndr_pull_wbint_PamAuthCrapValidation(struct ndr_pull *ndr, int ndr_flags, struct wbint_PamAuthCrapValidation *r)
1060 : {
1061 : uint32_t _ptr_validation;
1062 458 : TALLOC_CTX *_mem_save_validation_0 = NULL;
1063 458 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1064 458 : if (ndr_flags & NDR_SCALARS) {
1065 458 : NDR_CHECK(ndr_pull_align(ndr, 5));
1066 458 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->level));
1067 458 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_validation));
1068 458 : if (_ptr_validation) {
1069 345 : NDR_PULL_ALLOC(ndr, r->validation);
1070 : } else {
1071 113 : r->validation = NULL;
1072 : }
1073 458 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1074 : }
1075 458 : if (ndr_flags & NDR_BUFFERS) {
1076 458 : if (r->validation) {
1077 345 : _mem_save_validation_0 = NDR_PULL_GET_MEM_CTX(ndr);
1078 345 : NDR_PULL_SET_MEM_CTX(ndr, r->validation, 0);
1079 345 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->validation, r->level));
1080 345 : NDR_CHECK(ndr_pull_netr_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, r->validation));
1081 345 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_validation_0, 0);
1082 : }
1083 : }
1084 458 : return NDR_ERR_SUCCESS;
1085 : }
1086 :
1087 0 : static void ndr_print_flags_wbint_PamAuthCrapValidation(struct ndr_print *ndr, const char *name, int unused, const struct wbint_PamAuthCrapValidation *r)
1088 : {
1089 0 : ndr_print_wbint_PamAuthCrapValidation(ndr, name, r);
1090 0 : }
1091 :
1092 0 : _PUBLIC_ void ndr_print_wbint_PamAuthCrapValidation(struct ndr_print *ndr, const char *name, const struct wbint_PamAuthCrapValidation *r)
1093 : {
1094 0 : ndr_print_struct(ndr, name, "wbint_PamAuthCrapValidation");
1095 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1096 0 : ndr->depth++;
1097 0 : ndr_print_uint16(ndr, "level", r->level);
1098 0 : ndr_print_ptr(ndr, "validation", r->validation);
1099 0 : ndr->depth++;
1100 0 : if (r->validation) {
1101 0 : ndr_print_set_switch_value(ndr, r->validation, r->level);
1102 0 : ndr_print_netr_Validation(ndr, "validation", r->validation);
1103 : }
1104 0 : ndr->depth--;
1105 0 : ndr->depth--;
1106 : }
1107 :
1108 0 : static enum ndr_err_code ndr_push_DomainInfoFlags(struct ndr_push *ndr, int ndr_flags, enum DomainInfoFlags r)
1109 : {
1110 0 : NDR_CHECK(ndr_push_enum_uint16(ndr, NDR_SCALARS, r));
1111 0 : return NDR_ERR_SUCCESS;
1112 : }
1113 :
1114 146 : static enum ndr_err_code ndr_pull_DomainInfoFlags(struct ndr_pull *ndr, int ndr_flags, enum DomainInfoFlags *r)
1115 : {
1116 : uint16_t v;
1117 146 : NDR_CHECK(ndr_pull_enum_uint16(ndr, NDR_SCALARS, &v));
1118 146 : *r = v;
1119 146 : return NDR_ERR_SUCCESS;
1120 : }
1121 :
1122 0 : _PUBLIC_ void ndr_print_DomainInfoFlags(struct ndr_print *ndr, const char *name, enum DomainInfoFlags r)
1123 : {
1124 0 : const char *val = NULL;
1125 :
1126 0 : switch (r) {
1127 0 : case WB_DOMINFO_DOMAIN_UNKNOWN: val = "WB_DOMINFO_DOMAIN_UNKNOWN"; break;
1128 0 : case WB_DOMINFO_DOMAIN_NATIVE: val = "WB_DOMINFO_DOMAIN_NATIVE"; break;
1129 0 : case WB_DOMINFO_DOMAIN_AD: val = "WB_DOMINFO_DOMAIN_AD"; break;
1130 0 : case WB_DOMINFO_DOMAIN_PRIMARY: val = "WB_DOMINFO_DOMAIN_PRIMARY"; break;
1131 0 : case WB_DOMINFO_DOMAIN_OFFLINE: val = "WB_DOMINFO_DOMAIN_OFFLINE"; break;
1132 : }
1133 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
1134 0 : }
1135 :
1136 6 : static enum ndr_err_code ndr_push_wbint_Ping(struct ndr_push *ndr, int flags, const struct wbint_Ping *r)
1137 : {
1138 6 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1139 6 : if (flags & NDR_IN) {
1140 6 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.in_data));
1141 : }
1142 6 : if (flags & NDR_OUT) {
1143 0 : if (r->out.out_data == NULL) {
1144 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1145 : }
1146 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.out_data));
1147 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1148 : }
1149 6 : return NDR_ERR_SUCCESS;
1150 : }
1151 :
1152 6 : static enum ndr_err_code ndr_pull_wbint_Ping(struct ndr_pull *ndr, int flags, struct wbint_Ping *r)
1153 : {
1154 6 : TALLOC_CTX *_mem_save_out_data_0 = NULL;
1155 6 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1156 6 : if (flags & NDR_IN) {
1157 0 : NDR_ZERO_STRUCT(r->out);
1158 :
1159 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.in_data));
1160 0 : NDR_PULL_ALLOC(ndr, r->out.out_data);
1161 0 : NDR_ZERO_STRUCTP(r->out.out_data);
1162 : }
1163 6 : if (flags & NDR_OUT) {
1164 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1165 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1166 6 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1167 6 : NDR_PULL_ALLOC(ndr, r->out.out_data);
1168 : }
1169 6 : _mem_save_out_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
1170 6 : NDR_PULL_SET_MEM_CTX(ndr, r->out.out_data, LIBNDR_FLAG_REF_ALLOC);
1171 6 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.out_data));
1172 6 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_out_data_0, LIBNDR_FLAG_REF_ALLOC);
1173 6 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1174 : }
1175 6 : return NDR_ERR_SUCCESS;
1176 : }
1177 :
1178 0 : _PUBLIC_ void ndr_print_wbint_Ping(struct ndr_print *ndr, const char *name, int flags, const struct wbint_Ping *r)
1179 : {
1180 0 : ndr_print_struct(ndr, name, "wbint_Ping");
1181 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1182 0 : ndr->depth++;
1183 0 : if (flags & NDR_SET_VALUES) {
1184 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1185 : }
1186 0 : if (flags & NDR_IN) {
1187 0 : ndr_print_struct(ndr, "in", "wbint_Ping");
1188 0 : ndr->depth++;
1189 0 : ndr_print_uint32(ndr, "in_data", r->in.in_data);
1190 0 : ndr->depth--;
1191 : }
1192 0 : if (flags & NDR_OUT) {
1193 0 : ndr_print_struct(ndr, "out", "wbint_Ping");
1194 0 : ndr->depth++;
1195 0 : ndr_print_ptr(ndr, "out_data", r->out.out_data);
1196 0 : ndr->depth++;
1197 0 : ndr_print_uint32(ndr, "out_data", *r->out.out_data);
1198 0 : ndr->depth--;
1199 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1200 0 : ndr->depth--;
1201 : }
1202 0 : ndr->depth--;
1203 : }
1204 :
1205 8060 : static enum ndr_err_code ndr_push_wbint_LookupSid(struct ndr_push *ndr, int flags, const struct wbint_LookupSid *r)
1206 : {
1207 8060 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1208 8060 : if (flags & NDR_IN) {
1209 8060 : if (r->in.sid == NULL) {
1210 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1211 : }
1212 8060 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->in.sid));
1213 : }
1214 8060 : if (flags & NDR_OUT) {
1215 0 : if (r->out.type == NULL) {
1216 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1217 : }
1218 0 : if (r->out.domain == NULL) {
1219 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1220 : }
1221 0 : if (r->out.name == NULL) {
1222 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1223 : }
1224 0 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, *r->out.type));
1225 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domain));
1226 0 : if (*r->out.domain) {
1227 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.domain, CH_UTF8)));
1228 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1229 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.domain, CH_UTF8)));
1230 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.domain, ndr_charset_length(*r->out.domain, CH_UTF8), sizeof(uint8_t), CH_UTF8));
1231 : }
1232 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.name));
1233 0 : if (*r->out.name) {
1234 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.name, CH_UTF8)));
1235 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1236 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.name, CH_UTF8)));
1237 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.name, ndr_charset_length(*r->out.name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
1238 : }
1239 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1240 : }
1241 8060 : return NDR_ERR_SUCCESS;
1242 : }
1243 :
1244 8060 : static enum ndr_err_code ndr_pull_wbint_LookupSid(struct ndr_pull *ndr, int flags, struct wbint_LookupSid *r)
1245 : {
1246 : uint32_t _ptr_domain;
1247 8060 : uint32_t size_domain_2 = 0;
1248 8060 : uint32_t length_domain_2 = 0;
1249 : uint32_t _ptr_name;
1250 8060 : uint32_t size_name_2 = 0;
1251 8060 : uint32_t length_name_2 = 0;
1252 8060 : TALLOC_CTX *_mem_save_sid_0 = NULL;
1253 8060 : TALLOC_CTX *_mem_save_type_0 = NULL;
1254 8060 : TALLOC_CTX *_mem_save_domain_0 = NULL;
1255 8060 : TALLOC_CTX *_mem_save_domain_1 = NULL;
1256 8060 : TALLOC_CTX *_mem_save_name_0 = NULL;
1257 8060 : TALLOC_CTX *_mem_save_name_1 = NULL;
1258 8060 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1259 8060 : if (flags & NDR_IN) {
1260 0 : NDR_ZERO_STRUCT(r->out);
1261 :
1262 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1263 0 : NDR_PULL_ALLOC(ndr, r->in.sid);
1264 : }
1265 0 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1266 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
1267 0 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->in.sid));
1268 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
1269 0 : NDR_PULL_ALLOC(ndr, r->out.type);
1270 0 : NDR_ZERO_STRUCTP(r->out.type);
1271 0 : NDR_PULL_ALLOC(ndr, r->out.domain);
1272 0 : NDR_ZERO_STRUCTP(r->out.domain);
1273 0 : NDR_PULL_ALLOC(ndr, r->out.name);
1274 0 : NDR_ZERO_STRUCTP(r->out.name);
1275 : }
1276 8060 : if (flags & NDR_OUT) {
1277 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1278 : if (r->in.sid == NULL) {
1279 : NDR_PULL_ALLOC(ndr, r->in.sid);
1280 : NDR_ZERO_STRUCTP(r->in.sid);
1281 : }
1282 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1283 8060 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1284 8060 : NDR_PULL_ALLOC(ndr, r->out.type);
1285 : }
1286 8060 : _mem_save_type_0 = NDR_PULL_GET_MEM_CTX(ndr);
1287 8060 : NDR_PULL_SET_MEM_CTX(ndr, r->out.type, LIBNDR_FLAG_REF_ALLOC);
1288 8060 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, r->out.type));
1289 8060 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_type_0, LIBNDR_FLAG_REF_ALLOC);
1290 8060 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1291 8060 : NDR_PULL_ALLOC(ndr, r->out.domain);
1292 : }
1293 8060 : _mem_save_domain_0 = NDR_PULL_GET_MEM_CTX(ndr);
1294 8060 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domain, LIBNDR_FLAG_REF_ALLOC);
1295 8060 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain));
1296 8060 : if (_ptr_domain) {
1297 7534 : NDR_PULL_ALLOC(ndr, *r->out.domain);
1298 : } else {
1299 526 : *r->out.domain = NULL;
1300 : }
1301 8060 : if (*r->out.domain) {
1302 7534 : _mem_save_domain_1 = NDR_PULL_GET_MEM_CTX(ndr);
1303 7534 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domain, 0);
1304 7534 : NDR_CHECK(ndr_pull_array_size(ndr, r->out.domain));
1305 7534 : NDR_CHECK(ndr_pull_array_length(ndr, r->out.domain));
1306 7534 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)r->out.domain, &size_domain_2));
1307 7534 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)r->out.domain, &length_domain_2));
1308 7534 : if (length_domain_2 > size_domain_2) {
1309 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_2, length_domain_2);
1310 : }
1311 7534 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_2, sizeof(uint8_t)));
1312 7534 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.domain, length_domain_2, sizeof(uint8_t), CH_UTF8));
1313 7534 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_1, 0);
1314 : }
1315 8060 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_0, LIBNDR_FLAG_REF_ALLOC);
1316 8060 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1317 8060 : NDR_PULL_ALLOC(ndr, r->out.name);
1318 : }
1319 8060 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
1320 8060 : NDR_PULL_SET_MEM_CTX(ndr, r->out.name, LIBNDR_FLAG_REF_ALLOC);
1321 8060 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
1322 8060 : if (_ptr_name) {
1323 7534 : NDR_PULL_ALLOC(ndr, *r->out.name);
1324 : } else {
1325 526 : *r->out.name = NULL;
1326 : }
1327 8060 : if (*r->out.name) {
1328 7534 : _mem_save_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
1329 7534 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.name, 0);
1330 7534 : NDR_CHECK(ndr_pull_array_size(ndr, r->out.name));
1331 7534 : NDR_CHECK(ndr_pull_array_length(ndr, r->out.name));
1332 7534 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)r->out.name, &size_name_2));
1333 7534 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)r->out.name, &length_name_2));
1334 7534 : if (length_name_2 > size_name_2) {
1335 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_name_2, length_name_2);
1336 : }
1337 7534 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_2, sizeof(uint8_t)));
1338 7534 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.name, length_name_2, sizeof(uint8_t), CH_UTF8));
1339 7534 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_1, 0);
1340 : }
1341 8060 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
1342 8060 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1343 : }
1344 8060 : return NDR_ERR_SUCCESS;
1345 : }
1346 :
1347 0 : _PUBLIC_ void ndr_print_wbint_LookupSid(struct ndr_print *ndr, const char *name, int flags, const struct wbint_LookupSid *r)
1348 : {
1349 0 : ndr_print_struct(ndr, name, "wbint_LookupSid");
1350 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1351 0 : ndr->depth++;
1352 0 : if (flags & NDR_SET_VALUES) {
1353 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1354 : }
1355 0 : if (flags & NDR_IN) {
1356 0 : ndr_print_struct(ndr, "in", "wbint_LookupSid");
1357 0 : ndr->depth++;
1358 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
1359 0 : ndr->depth++;
1360 0 : ndr_print_dom_sid(ndr, "sid", r->in.sid);
1361 0 : ndr->depth--;
1362 0 : ndr->depth--;
1363 : }
1364 0 : if (flags & NDR_OUT) {
1365 0 : ndr_print_struct(ndr, "out", "wbint_LookupSid");
1366 0 : ndr->depth++;
1367 0 : ndr_print_ptr(ndr, "type", r->out.type);
1368 0 : ndr->depth++;
1369 0 : ndr_print_lsa_SidType(ndr, "type", *r->out.type);
1370 0 : ndr->depth--;
1371 0 : ndr_print_ptr(ndr, "domain", r->out.domain);
1372 0 : ndr->depth++;
1373 0 : ndr_print_ptr(ndr, "domain", *r->out.domain);
1374 0 : ndr->depth++;
1375 0 : if (*r->out.domain) {
1376 0 : ndr_print_string(ndr, "domain", *r->out.domain);
1377 : }
1378 0 : ndr->depth--;
1379 0 : ndr->depth--;
1380 0 : ndr_print_ptr(ndr, "name", r->out.name);
1381 0 : ndr->depth++;
1382 0 : ndr_print_ptr(ndr, "name", *r->out.name);
1383 0 : ndr->depth++;
1384 0 : if (*r->out.name) {
1385 0 : ndr_print_string(ndr, "name", *r->out.name);
1386 : }
1387 0 : ndr->depth--;
1388 0 : ndr->depth--;
1389 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1390 0 : ndr->depth--;
1391 : }
1392 0 : ndr->depth--;
1393 : }
1394 :
1395 105 : static enum ndr_err_code ndr_push_wbint_LookupSids(struct ndr_push *ndr, int flags, const struct wbint_LookupSids *r)
1396 : {
1397 105 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1398 105 : if (flags & NDR_IN) {
1399 105 : if (r->in.sids == NULL) {
1400 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1401 : }
1402 105 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
1403 : }
1404 105 : if (flags & NDR_OUT) {
1405 0 : if (r->out.domains == NULL) {
1406 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1407 : }
1408 0 : if (r->out.names == NULL) {
1409 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1410 : }
1411 0 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
1412 0 : NDR_CHECK(ndr_push_lsa_TransNameArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
1413 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1414 : }
1415 105 : return NDR_ERR_SUCCESS;
1416 : }
1417 :
1418 105 : static enum ndr_err_code ndr_pull_wbint_LookupSids(struct ndr_pull *ndr, int flags, struct wbint_LookupSids *r)
1419 : {
1420 105 : TALLOC_CTX *_mem_save_sids_0 = NULL;
1421 105 : TALLOC_CTX *_mem_save_domains_0 = NULL;
1422 105 : TALLOC_CTX *_mem_save_names_0 = NULL;
1423 105 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1424 105 : if (flags & NDR_IN) {
1425 0 : NDR_ZERO_STRUCT(r->out);
1426 :
1427 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1428 0 : NDR_PULL_ALLOC(ndr, r->in.sids);
1429 : }
1430 0 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1431 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
1432 0 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
1433 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
1434 0 : NDR_PULL_ALLOC(ndr, r->out.domains);
1435 0 : NDR_ZERO_STRUCTP(r->out.domains);
1436 0 : NDR_PULL_ALLOC(ndr, r->out.names);
1437 0 : NDR_ZERO_STRUCTP(r->out.names);
1438 : }
1439 105 : if (flags & NDR_OUT) {
1440 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1441 : if (r->in.sids == NULL) {
1442 : NDR_PULL_ALLOC(ndr, r->in.sids);
1443 : NDR_ZERO_STRUCTP(r->in.sids);
1444 : }
1445 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1446 105 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1447 105 : NDR_PULL_ALLOC(ndr, r->out.domains);
1448 : }
1449 105 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
1450 105 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
1451 105 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
1452 105 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
1453 105 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1454 105 : NDR_PULL_ALLOC(ndr, r->out.names);
1455 : }
1456 105 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
1457 105 : NDR_PULL_SET_MEM_CTX(ndr, r->out.names, LIBNDR_FLAG_REF_ALLOC);
1458 105 : NDR_CHECK(ndr_pull_lsa_TransNameArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
1459 105 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
1460 105 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1461 : }
1462 105 : return NDR_ERR_SUCCESS;
1463 : }
1464 :
1465 0 : _PUBLIC_ void ndr_print_wbint_LookupSids(struct ndr_print *ndr, const char *name, int flags, const struct wbint_LookupSids *r)
1466 : {
1467 0 : ndr_print_struct(ndr, name, "wbint_LookupSids");
1468 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1469 0 : ndr->depth++;
1470 0 : if (flags & NDR_SET_VALUES) {
1471 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1472 : }
1473 0 : if (flags & NDR_IN) {
1474 0 : ndr_print_struct(ndr, "in", "wbint_LookupSids");
1475 0 : ndr->depth++;
1476 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
1477 0 : ndr->depth++;
1478 0 : ndr_print_lsa_SidArray(ndr, "sids", r->in.sids);
1479 0 : ndr->depth--;
1480 0 : ndr->depth--;
1481 : }
1482 0 : if (flags & NDR_OUT) {
1483 0 : ndr_print_struct(ndr, "out", "wbint_LookupSids");
1484 0 : ndr->depth++;
1485 0 : ndr_print_ptr(ndr, "domains", r->out.domains);
1486 0 : ndr->depth++;
1487 0 : ndr_print_lsa_RefDomainList(ndr, "domains", r->out.domains);
1488 0 : ndr->depth--;
1489 0 : ndr_print_ptr(ndr, "names", r->out.names);
1490 0 : ndr->depth++;
1491 0 : ndr_print_lsa_TransNameArray(ndr, "names", r->out.names);
1492 0 : ndr->depth--;
1493 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1494 0 : ndr->depth--;
1495 : }
1496 0 : ndr->depth--;
1497 : }
1498 :
1499 5232 : static enum ndr_err_code ndr_push_wbint_LookupName(struct ndr_push *ndr, int flags, const struct wbint_LookupName *r)
1500 : {
1501 5232 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1502 5232 : if (flags & NDR_IN) {
1503 5232 : if (r->in.domain == NULL) {
1504 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1505 : }
1506 5232 : if (r->in.name == NULL) {
1507 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1508 : }
1509 5232 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain, CH_UTF8)));
1510 5232 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1511 5232 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain, CH_UTF8)));
1512 5232 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.domain, ndr_charset_length(r->in.domain, CH_UTF8), sizeof(uint8_t), CH_UTF8));
1513 5232 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name, CH_UTF8)));
1514 5232 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1515 5232 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.name, CH_UTF8)));
1516 5232 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.name, ndr_charset_length(r->in.name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
1517 5232 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
1518 : }
1519 5232 : if (flags & NDR_OUT) {
1520 0 : if (r->out.type == NULL) {
1521 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1522 : }
1523 0 : if (r->out.sid == NULL) {
1524 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1525 : }
1526 0 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, *r->out.type));
1527 0 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->out.sid));
1528 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1529 : }
1530 5232 : return NDR_ERR_SUCCESS;
1531 : }
1532 :
1533 5226 : static enum ndr_err_code ndr_pull_wbint_LookupName(struct ndr_pull *ndr, int flags, struct wbint_LookupName *r)
1534 : {
1535 5226 : uint32_t size_domain_1 = 0;
1536 5226 : uint32_t length_domain_1 = 0;
1537 5226 : uint32_t size_name_1 = 0;
1538 5226 : uint32_t length_name_1 = 0;
1539 5226 : TALLOC_CTX *_mem_save_type_0 = NULL;
1540 5226 : TALLOC_CTX *_mem_save_sid_0 = NULL;
1541 5226 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1542 5226 : if (flags & NDR_IN) {
1543 0 : NDR_ZERO_STRUCT(r->out);
1544 :
1545 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.domain));
1546 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.domain));
1547 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.domain, &size_domain_1));
1548 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.domain, &length_domain_1));
1549 0 : if (length_domain_1 > size_domain_1) {
1550 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_1, length_domain_1);
1551 : }
1552 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint8_t)));
1553 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.domain, length_domain_1, sizeof(uint8_t), CH_UTF8));
1554 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.name));
1555 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.name));
1556 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.name, &size_name_1));
1557 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.name, &length_name_1));
1558 0 : if (length_name_1 > size_name_1) {
1559 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_name_1, length_name_1);
1560 : }
1561 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_1, sizeof(uint8_t)));
1562 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.name, length_name_1, sizeof(uint8_t), CH_UTF8));
1563 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
1564 0 : NDR_PULL_ALLOC(ndr, r->out.type);
1565 0 : NDR_ZERO_STRUCTP(r->out.type);
1566 0 : NDR_PULL_ALLOC(ndr, r->out.sid);
1567 0 : NDR_ZERO_STRUCTP(r->out.sid);
1568 : }
1569 5226 : if (flags & NDR_OUT) {
1570 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1571 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1572 5226 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1573 5226 : NDR_PULL_ALLOC(ndr, r->out.type);
1574 : }
1575 5226 : _mem_save_type_0 = NDR_PULL_GET_MEM_CTX(ndr);
1576 5226 : NDR_PULL_SET_MEM_CTX(ndr, r->out.type, LIBNDR_FLAG_REF_ALLOC);
1577 5226 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, r->out.type));
1578 5226 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_type_0, LIBNDR_FLAG_REF_ALLOC);
1579 5226 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1580 5226 : NDR_PULL_ALLOC(ndr, r->out.sid);
1581 : }
1582 5226 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1583 5226 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sid, LIBNDR_FLAG_REF_ALLOC);
1584 5226 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->out.sid));
1585 5226 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
1586 5226 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1587 : }
1588 5226 : return NDR_ERR_SUCCESS;
1589 : }
1590 :
1591 0 : _PUBLIC_ void ndr_print_wbint_LookupName(struct ndr_print *ndr, const char *name, int flags, const struct wbint_LookupName *r)
1592 : {
1593 0 : ndr_print_struct(ndr, name, "wbint_LookupName");
1594 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1595 0 : ndr->depth++;
1596 0 : if (flags & NDR_SET_VALUES) {
1597 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1598 : }
1599 0 : if (flags & NDR_IN) {
1600 0 : ndr_print_struct(ndr, "in", "wbint_LookupName");
1601 0 : ndr->depth++;
1602 0 : ndr_print_ptr(ndr, "domain", r->in.domain);
1603 0 : ndr->depth++;
1604 0 : ndr_print_string(ndr, "domain", r->in.domain);
1605 0 : ndr->depth--;
1606 0 : ndr_print_ptr(ndr, "name", r->in.name);
1607 0 : ndr->depth++;
1608 0 : ndr_print_string(ndr, "name", r->in.name);
1609 0 : ndr->depth--;
1610 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
1611 0 : ndr->depth--;
1612 : }
1613 0 : if (flags & NDR_OUT) {
1614 0 : ndr_print_struct(ndr, "out", "wbint_LookupName");
1615 0 : ndr->depth++;
1616 0 : ndr_print_ptr(ndr, "type", r->out.type);
1617 0 : ndr->depth++;
1618 0 : ndr_print_lsa_SidType(ndr, "type", *r->out.type);
1619 0 : ndr->depth--;
1620 0 : ndr_print_ptr(ndr, "sid", r->out.sid);
1621 0 : ndr->depth++;
1622 0 : ndr_print_dom_sid(ndr, "sid", r->out.sid);
1623 0 : ndr->depth--;
1624 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1625 0 : ndr->depth--;
1626 : }
1627 0 : ndr->depth--;
1628 : }
1629 :
1630 1400 : static enum ndr_err_code ndr_push_wbint_Sids2UnixIDs(struct ndr_push *ndr, int flags, const struct wbint_Sids2UnixIDs *r)
1631 : {
1632 1400 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1633 1400 : if (flags & NDR_IN) {
1634 1400 : if (r->in.domains == NULL) {
1635 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1636 : }
1637 1400 : if (r->in.ids == NULL) {
1638 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1639 : }
1640 1400 : NDR_CHECK(ndr_push_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.domains));
1641 1400 : NDR_CHECK(ndr_push_wbint_TransIDArray(ndr, NDR_SCALARS, r->in.ids));
1642 : }
1643 1400 : if (flags & NDR_OUT) {
1644 0 : if (r->out.ids == NULL) {
1645 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1646 : }
1647 0 : NDR_CHECK(ndr_push_wbint_TransIDArray(ndr, NDR_SCALARS, r->out.ids));
1648 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1649 : }
1650 1400 : return NDR_ERR_SUCCESS;
1651 : }
1652 :
1653 1389 : static enum ndr_err_code ndr_pull_wbint_Sids2UnixIDs(struct ndr_pull *ndr, int flags, struct wbint_Sids2UnixIDs *r)
1654 : {
1655 1389 : TALLOC_CTX *_mem_save_domains_0 = NULL;
1656 1389 : TALLOC_CTX *_mem_save_ids_0 = NULL;
1657 1389 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1658 1389 : if (flags & NDR_IN) {
1659 0 : NDR_ZERO_STRUCT(r->out);
1660 :
1661 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1662 0 : NDR_PULL_ALLOC(ndr, r->in.domains);
1663 : }
1664 0 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
1665 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domains, LIBNDR_FLAG_REF_ALLOC);
1666 0 : NDR_CHECK(ndr_pull_lsa_RefDomainList(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.domains));
1667 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
1668 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1669 0 : NDR_PULL_ALLOC(ndr, r->in.ids);
1670 : }
1671 0 : _mem_save_ids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1672 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.ids, LIBNDR_FLAG_REF_ALLOC);
1673 0 : NDR_CHECK(ndr_pull_wbint_TransIDArray(ndr, NDR_SCALARS, r->in.ids));
1674 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ids_0, LIBNDR_FLAG_REF_ALLOC);
1675 0 : NDR_PULL_ALLOC(ndr, r->out.ids);
1676 0 : *r->out.ids = *r->in.ids;
1677 : }
1678 1389 : if (flags & NDR_OUT) {
1679 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1680 : if (r->in.domains == NULL) {
1681 : NDR_PULL_ALLOC(ndr, r->in.domains);
1682 : NDR_ZERO_STRUCTP(r->in.domains);
1683 : }
1684 : if (r->in.ids == NULL) {
1685 : NDR_PULL_ALLOC(ndr, r->in.ids);
1686 : NDR_ZERO_STRUCTP(r->in.ids);
1687 : }
1688 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1689 1389 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1690 1389 : NDR_PULL_ALLOC(ndr, r->out.ids);
1691 : }
1692 1389 : _mem_save_ids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1693 1389 : NDR_PULL_SET_MEM_CTX(ndr, r->out.ids, LIBNDR_FLAG_REF_ALLOC);
1694 1389 : NDR_CHECK(ndr_pull_wbint_TransIDArray(ndr, NDR_SCALARS, r->out.ids));
1695 1389 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ids_0, LIBNDR_FLAG_REF_ALLOC);
1696 1389 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1697 : }
1698 1389 : return NDR_ERR_SUCCESS;
1699 : }
1700 :
1701 0 : _PUBLIC_ void ndr_print_wbint_Sids2UnixIDs(struct ndr_print *ndr, const char *name, int flags, const struct wbint_Sids2UnixIDs *r)
1702 : {
1703 0 : ndr_print_struct(ndr, name, "wbint_Sids2UnixIDs");
1704 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1705 0 : ndr->depth++;
1706 0 : if (flags & NDR_SET_VALUES) {
1707 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1708 : }
1709 0 : if (flags & NDR_IN) {
1710 0 : ndr_print_struct(ndr, "in", "wbint_Sids2UnixIDs");
1711 0 : ndr->depth++;
1712 0 : ndr_print_ptr(ndr, "domains", r->in.domains);
1713 0 : ndr->depth++;
1714 0 : ndr_print_lsa_RefDomainList(ndr, "domains", r->in.domains);
1715 0 : ndr->depth--;
1716 0 : ndr_print_ptr(ndr, "ids", r->in.ids);
1717 0 : ndr->depth++;
1718 0 : ndr_print_wbint_TransIDArray(ndr, "ids", r->in.ids);
1719 0 : ndr->depth--;
1720 0 : ndr->depth--;
1721 : }
1722 0 : if (flags & NDR_OUT) {
1723 0 : ndr_print_struct(ndr, "out", "wbint_Sids2UnixIDs");
1724 0 : ndr->depth++;
1725 0 : ndr_print_ptr(ndr, "ids", r->out.ids);
1726 0 : ndr->depth++;
1727 0 : ndr_print_wbint_TransIDArray(ndr, "ids", r->out.ids);
1728 0 : ndr->depth--;
1729 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1730 0 : ndr->depth--;
1731 : }
1732 0 : ndr->depth--;
1733 : }
1734 :
1735 187 : static enum ndr_err_code ndr_push_wbint_UnixIDs2Sids(struct ndr_push *ndr, int flags, const struct wbint_UnixIDs2Sids *r)
1736 : {
1737 : uint32_t cntr_xids_0;
1738 : uint32_t cntr_sids_0;
1739 187 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1740 187 : if (flags & NDR_IN) {
1741 187 : if (r->in.domain_name == NULL) {
1742 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1743 : }
1744 187 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain_name, CH_UTF8)));
1745 187 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
1746 187 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain_name, CH_UTF8)));
1747 187 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.domain_name, ndr_charset_length(r->in.domain_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
1748 187 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->in.domain_sid));
1749 187 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_ids));
1750 510 : for (cntr_xids_0 = 0; cntr_xids_0 < (r->in.num_ids); cntr_xids_0++) {
1751 323 : NDR_CHECK(ndr_push_unixid(ndr, NDR_SCALARS, &r->in.xids[cntr_xids_0]));
1752 : }
1753 : }
1754 187 : if (flags & NDR_OUT) {
1755 0 : for (cntr_xids_0 = 0; cntr_xids_0 < (r->in.num_ids); cntr_xids_0++) {
1756 0 : NDR_CHECK(ndr_push_unixid(ndr, NDR_SCALARS, &r->out.xids[cntr_xids_0]));
1757 : }
1758 0 : for (cntr_sids_0 = 0; cntr_sids_0 < (r->in.num_ids); cntr_sids_0++) {
1759 0 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->out.sids[cntr_sids_0]));
1760 : }
1761 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1762 : }
1763 187 : return NDR_ERR_SUCCESS;
1764 : }
1765 :
1766 187 : static enum ndr_err_code ndr_pull_wbint_UnixIDs2Sids(struct ndr_pull *ndr, int flags, struct wbint_UnixIDs2Sids *r)
1767 : {
1768 187 : uint32_t size_domain_name_1 = 0;
1769 187 : uint32_t length_domain_name_1 = 0;
1770 187 : uint32_t size_xids_0 = 0;
1771 : uint32_t cntr_xids_0;
1772 187 : uint32_t size_sids_0 = 0;
1773 : uint32_t cntr_sids_0;
1774 187 : TALLOC_CTX *_mem_save_xids_0 = NULL;
1775 187 : TALLOC_CTX *_mem_save_sids_0 = NULL;
1776 187 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1777 187 : if (flags & NDR_IN) {
1778 0 : NDR_ZERO_STRUCT(r->out);
1779 :
1780 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.domain_name));
1781 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.domain_name));
1782 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.domain_name, &size_domain_name_1));
1783 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.domain_name, &length_domain_name_1));
1784 0 : if (length_domain_name_1 > size_domain_name_1) {
1785 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_name_1, length_domain_name_1);
1786 : }
1787 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_name_1, sizeof(uint8_t)));
1788 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.domain_name, length_domain_name_1, sizeof(uint8_t), CH_UTF8));
1789 0 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->in.domain_sid));
1790 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_ids));
1791 0 : size_xids_0 = r->in.num_ids;
1792 0 : NDR_PULL_ALLOC_N(ndr, r->in.xids, size_xids_0);
1793 0 : _mem_save_xids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1794 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.xids, 0);
1795 0 : for (cntr_xids_0 = 0; cntr_xids_0 < (size_xids_0); cntr_xids_0++) {
1796 0 : NDR_CHECK(ndr_pull_unixid(ndr, NDR_SCALARS, &r->in.xids[cntr_xids_0]));
1797 : }
1798 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_xids_0, 0);
1799 : }
1800 187 : if (flags & NDR_OUT) {
1801 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1802 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1803 187 : size_xids_0 = r->in.num_ids;
1804 187 : NDR_PULL_ALLOC_N(ndr, r->out.xids, size_xids_0);
1805 187 : _mem_save_xids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1806 187 : NDR_PULL_SET_MEM_CTX(ndr, r->out.xids, 0);
1807 510 : for (cntr_xids_0 = 0; cntr_xids_0 < (size_xids_0); cntr_xids_0++) {
1808 323 : NDR_CHECK(ndr_pull_unixid(ndr, NDR_SCALARS, &r->out.xids[cntr_xids_0]));
1809 : }
1810 187 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_xids_0, 0);
1811 187 : size_sids_0 = r->in.num_ids;
1812 187 : NDR_PULL_ALLOC_N(ndr, r->out.sids, size_sids_0);
1813 187 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1814 187 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, 0);
1815 510 : for (cntr_sids_0 = 0; cntr_sids_0 < (size_sids_0); cntr_sids_0++) {
1816 323 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->out.sids[cntr_sids_0]));
1817 : }
1818 187 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, 0);
1819 187 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1820 : }
1821 187 : return NDR_ERR_SUCCESS;
1822 : }
1823 :
1824 0 : _PUBLIC_ void ndr_print_wbint_UnixIDs2Sids(struct ndr_print *ndr, const char *name, int flags, const struct wbint_UnixIDs2Sids *r)
1825 : {
1826 : uint32_t cntr_xids_0;
1827 : uint32_t cntr_sids_0;
1828 0 : ndr_print_struct(ndr, name, "wbint_UnixIDs2Sids");
1829 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1830 0 : ndr->depth++;
1831 0 : if (flags & NDR_SET_VALUES) {
1832 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1833 : }
1834 0 : if (flags & NDR_IN) {
1835 0 : ndr_print_struct(ndr, "in", "wbint_UnixIDs2Sids");
1836 0 : ndr->depth++;
1837 0 : ndr_print_ptr(ndr, "domain_name", r->in.domain_name);
1838 0 : ndr->depth++;
1839 0 : ndr_print_string(ndr, "domain_name", r->in.domain_name);
1840 0 : ndr->depth--;
1841 0 : ndr_print_dom_sid(ndr, "domain_sid", &r->in.domain_sid);
1842 0 : ndr_print_uint32(ndr, "num_ids", r->in.num_ids);
1843 0 : ndr->print(ndr, "%s: ARRAY(%d)", "xids", (int)r->in.num_ids);
1844 0 : ndr->depth++;
1845 0 : for (cntr_xids_0 = 0; cntr_xids_0 < (r->in.num_ids); cntr_xids_0++) {
1846 0 : ndr_print_unixid(ndr, "xids", &r->in.xids[cntr_xids_0]);
1847 : }
1848 0 : ndr->depth--;
1849 0 : ndr->depth--;
1850 : }
1851 0 : if (flags & NDR_OUT) {
1852 0 : ndr_print_struct(ndr, "out", "wbint_UnixIDs2Sids");
1853 0 : ndr->depth++;
1854 0 : ndr->print(ndr, "%s: ARRAY(%d)", "xids", (int)r->in.num_ids);
1855 0 : ndr->depth++;
1856 0 : for (cntr_xids_0 = 0; cntr_xids_0 < (r->in.num_ids); cntr_xids_0++) {
1857 0 : ndr_print_unixid(ndr, "xids", &r->out.xids[cntr_xids_0]);
1858 : }
1859 0 : ndr->depth--;
1860 0 : ndr->print(ndr, "%s: ARRAY(%d)", "sids", (int)r->in.num_ids);
1861 0 : ndr->depth++;
1862 0 : for (cntr_sids_0 = 0; cntr_sids_0 < (r->in.num_ids); cntr_sids_0++) {
1863 0 : ndr_print_dom_sid(ndr, "sids", &r->out.sids[cntr_sids_0]);
1864 : }
1865 0 : ndr->depth--;
1866 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1867 0 : ndr->depth--;
1868 : }
1869 0 : ndr->depth--;
1870 : }
1871 :
1872 4 : static enum ndr_err_code ndr_push_wbint_AllocateUid(struct ndr_push *ndr, int flags, const struct wbint_AllocateUid *r)
1873 : {
1874 4 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1875 4 : if (flags & NDR_IN) {
1876 : }
1877 4 : if (flags & NDR_OUT) {
1878 0 : if (r->out.uid == NULL) {
1879 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1880 : }
1881 0 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, *r->out.uid));
1882 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1883 : }
1884 4 : return NDR_ERR_SUCCESS;
1885 : }
1886 :
1887 4 : static enum ndr_err_code ndr_pull_wbint_AllocateUid(struct ndr_pull *ndr, int flags, struct wbint_AllocateUid *r)
1888 : {
1889 4 : TALLOC_CTX *_mem_save_uid_0 = NULL;
1890 4 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1891 4 : if (flags & NDR_IN) {
1892 0 : NDR_ZERO_STRUCT(r->out);
1893 :
1894 0 : NDR_PULL_ALLOC(ndr, r->out.uid);
1895 0 : NDR_ZERO_STRUCTP(r->out.uid);
1896 : }
1897 4 : if (flags & NDR_OUT) {
1898 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1899 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1900 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1901 4 : NDR_PULL_ALLOC(ndr, r->out.uid);
1902 : }
1903 4 : _mem_save_uid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1904 4 : NDR_PULL_SET_MEM_CTX(ndr, r->out.uid, LIBNDR_FLAG_REF_ALLOC);
1905 4 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, r->out.uid));
1906 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_uid_0, LIBNDR_FLAG_REF_ALLOC);
1907 4 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1908 : }
1909 4 : return NDR_ERR_SUCCESS;
1910 : }
1911 :
1912 0 : _PUBLIC_ void ndr_print_wbint_AllocateUid(struct ndr_print *ndr, const char *name, int flags, const struct wbint_AllocateUid *r)
1913 : {
1914 0 : ndr_print_struct(ndr, name, "wbint_AllocateUid");
1915 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1916 0 : ndr->depth++;
1917 0 : if (flags & NDR_SET_VALUES) {
1918 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1919 : }
1920 0 : if (flags & NDR_IN) {
1921 0 : ndr_print_struct(ndr, "in", "wbint_AllocateUid");
1922 0 : ndr->depth++;
1923 0 : ndr->depth--;
1924 : }
1925 0 : if (flags & NDR_OUT) {
1926 0 : ndr_print_struct(ndr, "out", "wbint_AllocateUid");
1927 0 : ndr->depth++;
1928 0 : ndr_print_ptr(ndr, "uid", r->out.uid);
1929 0 : ndr->depth++;
1930 0 : ndr_print_hyper(ndr, "uid", *r->out.uid);
1931 0 : ndr->depth--;
1932 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1933 0 : ndr->depth--;
1934 : }
1935 0 : ndr->depth--;
1936 : }
1937 :
1938 80 : static enum ndr_err_code ndr_push_wbint_AllocateGid(struct ndr_push *ndr, int flags, const struct wbint_AllocateGid *r)
1939 : {
1940 80 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
1941 80 : if (flags & NDR_IN) {
1942 : }
1943 80 : if (flags & NDR_OUT) {
1944 0 : if (r->out.gid == NULL) {
1945 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
1946 : }
1947 0 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, *r->out.gid));
1948 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
1949 : }
1950 80 : return NDR_ERR_SUCCESS;
1951 : }
1952 :
1953 80 : static enum ndr_err_code ndr_pull_wbint_AllocateGid(struct ndr_pull *ndr, int flags, struct wbint_AllocateGid *r)
1954 : {
1955 80 : TALLOC_CTX *_mem_save_gid_0 = NULL;
1956 80 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
1957 80 : if (flags & NDR_IN) {
1958 0 : NDR_ZERO_STRUCT(r->out);
1959 :
1960 0 : NDR_PULL_ALLOC(ndr, r->out.gid);
1961 0 : NDR_ZERO_STRUCTP(r->out.gid);
1962 : }
1963 80 : if (flags & NDR_OUT) {
1964 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
1965 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
1966 80 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
1967 80 : NDR_PULL_ALLOC(ndr, r->out.gid);
1968 : }
1969 80 : _mem_save_gid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1970 80 : NDR_PULL_SET_MEM_CTX(ndr, r->out.gid, LIBNDR_FLAG_REF_ALLOC);
1971 80 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, r->out.gid));
1972 80 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_gid_0, LIBNDR_FLAG_REF_ALLOC);
1973 80 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
1974 : }
1975 80 : return NDR_ERR_SUCCESS;
1976 : }
1977 :
1978 0 : _PUBLIC_ void ndr_print_wbint_AllocateGid(struct ndr_print *ndr, const char *name, int flags, const struct wbint_AllocateGid *r)
1979 : {
1980 0 : ndr_print_struct(ndr, name, "wbint_AllocateGid");
1981 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1982 0 : ndr->depth++;
1983 0 : if (flags & NDR_SET_VALUES) {
1984 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
1985 : }
1986 0 : if (flags & NDR_IN) {
1987 0 : ndr_print_struct(ndr, "in", "wbint_AllocateGid");
1988 0 : ndr->depth++;
1989 0 : ndr->depth--;
1990 : }
1991 0 : if (flags & NDR_OUT) {
1992 0 : ndr_print_struct(ndr, "out", "wbint_AllocateGid");
1993 0 : ndr->depth++;
1994 0 : ndr_print_ptr(ndr, "gid", r->out.gid);
1995 0 : ndr->depth++;
1996 0 : ndr_print_hyper(ndr, "gid", *r->out.gid);
1997 0 : ndr->depth--;
1998 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
1999 0 : ndr->depth--;
2000 : }
2001 0 : ndr->depth--;
2002 : }
2003 :
2004 4736 : static enum ndr_err_code ndr_push_wbint_GetNssInfo(struct ndr_push *ndr, int flags, const struct wbint_GetNssInfo *r)
2005 : {
2006 4736 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2007 4736 : if (flags & NDR_IN) {
2008 4736 : if (r->in.info == NULL) {
2009 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2010 : }
2011 4736 : NDR_CHECK(ndr_push_wbint_userinfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
2012 : }
2013 4736 : if (flags & NDR_OUT) {
2014 0 : if (r->out.info == NULL) {
2015 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2016 : }
2017 0 : NDR_CHECK(ndr_push_wbint_userinfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
2018 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2019 : }
2020 4736 : return NDR_ERR_SUCCESS;
2021 : }
2022 :
2023 4736 : static enum ndr_err_code ndr_pull_wbint_GetNssInfo(struct ndr_pull *ndr, int flags, struct wbint_GetNssInfo *r)
2024 : {
2025 4736 : TALLOC_CTX *_mem_save_info_0 = NULL;
2026 4736 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2027 4736 : if (flags & NDR_IN) {
2028 0 : NDR_ZERO_STRUCT(r->out);
2029 :
2030 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2031 0 : NDR_PULL_ALLOC(ndr, r->in.info);
2032 : }
2033 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
2034 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
2035 0 : NDR_CHECK(ndr_pull_wbint_userinfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
2036 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
2037 0 : NDR_PULL_ALLOC(ndr, r->out.info);
2038 0 : *r->out.info = *r->in.info;
2039 : }
2040 4736 : if (flags & NDR_OUT) {
2041 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2042 : if (r->in.info == NULL) {
2043 : NDR_PULL_ALLOC(ndr, r->in.info);
2044 : NDR_ZERO_STRUCTP(r->in.info);
2045 : }
2046 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2047 4736 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2048 4736 : NDR_PULL_ALLOC(ndr, r->out.info);
2049 : }
2050 4736 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
2051 4736 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
2052 4736 : NDR_CHECK(ndr_pull_wbint_userinfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
2053 4736 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
2054 4736 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2055 : }
2056 4736 : return NDR_ERR_SUCCESS;
2057 : }
2058 :
2059 0 : _PUBLIC_ void ndr_print_wbint_GetNssInfo(struct ndr_print *ndr, const char *name, int flags, const struct wbint_GetNssInfo *r)
2060 : {
2061 0 : ndr_print_struct(ndr, name, "wbint_GetNssInfo");
2062 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2063 0 : ndr->depth++;
2064 0 : if (flags & NDR_SET_VALUES) {
2065 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2066 : }
2067 0 : if (flags & NDR_IN) {
2068 0 : ndr_print_struct(ndr, "in", "wbint_GetNssInfo");
2069 0 : ndr->depth++;
2070 0 : ndr_print_ptr(ndr, "info", r->in.info);
2071 0 : ndr->depth++;
2072 0 : ndr_print_wbint_userinfo(ndr, "info", r->in.info);
2073 0 : ndr->depth--;
2074 0 : ndr->depth--;
2075 : }
2076 0 : if (flags & NDR_OUT) {
2077 0 : ndr_print_struct(ndr, "out", "wbint_GetNssInfo");
2078 0 : ndr->depth++;
2079 0 : ndr_print_ptr(ndr, "info", r->out.info);
2080 0 : ndr->depth++;
2081 0 : ndr_print_wbint_userinfo(ndr, "info", r->out.info);
2082 0 : ndr->depth--;
2083 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2084 0 : ndr->depth--;
2085 : }
2086 0 : ndr->depth--;
2087 : }
2088 :
2089 167 : static enum ndr_err_code ndr_push_wbint_LookupUserAliases(struct ndr_push *ndr, int flags, const struct wbint_LookupUserAliases *r)
2090 : {
2091 167 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2092 167 : if (flags & NDR_IN) {
2093 167 : if (r->in.sids == NULL) {
2094 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2095 : }
2096 167 : NDR_CHECK(ndr_push_wbint_SidArray(ndr, NDR_SCALARS, r->in.sids));
2097 : }
2098 167 : if (flags & NDR_OUT) {
2099 0 : if (r->out.rids == NULL) {
2100 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2101 : }
2102 0 : NDR_CHECK(ndr_push_wbint_RidArray(ndr, NDR_SCALARS, r->out.rids));
2103 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2104 : }
2105 167 : return NDR_ERR_SUCCESS;
2106 : }
2107 :
2108 167 : static enum ndr_err_code ndr_pull_wbint_LookupUserAliases(struct ndr_pull *ndr, int flags, struct wbint_LookupUserAliases *r)
2109 : {
2110 167 : TALLOC_CTX *_mem_save_sids_0 = NULL;
2111 167 : TALLOC_CTX *_mem_save_rids_0 = NULL;
2112 167 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2113 167 : if (flags & NDR_IN) {
2114 0 : NDR_ZERO_STRUCT(r->out);
2115 :
2116 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2117 0 : NDR_PULL_ALLOC(ndr, r->in.sids);
2118 : }
2119 0 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
2120 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
2121 0 : NDR_CHECK(ndr_pull_wbint_SidArray(ndr, NDR_SCALARS, r->in.sids));
2122 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
2123 0 : NDR_PULL_ALLOC(ndr, r->out.rids);
2124 0 : NDR_ZERO_STRUCTP(r->out.rids);
2125 : }
2126 167 : if (flags & NDR_OUT) {
2127 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2128 : if (r->in.sids == NULL) {
2129 : NDR_PULL_ALLOC(ndr, r->in.sids);
2130 : NDR_ZERO_STRUCTP(r->in.sids);
2131 : }
2132 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2133 167 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2134 167 : NDR_PULL_ALLOC(ndr, r->out.rids);
2135 : }
2136 167 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
2137 167 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rids, LIBNDR_FLAG_REF_ALLOC);
2138 167 : NDR_CHECK(ndr_pull_wbint_RidArray(ndr, NDR_SCALARS, r->out.rids));
2139 167 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, LIBNDR_FLAG_REF_ALLOC);
2140 167 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2141 : }
2142 167 : return NDR_ERR_SUCCESS;
2143 : }
2144 :
2145 0 : _PUBLIC_ void ndr_print_wbint_LookupUserAliases(struct ndr_print *ndr, const char *name, int flags, const struct wbint_LookupUserAliases *r)
2146 : {
2147 0 : ndr_print_struct(ndr, name, "wbint_LookupUserAliases");
2148 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2149 0 : ndr->depth++;
2150 0 : if (flags & NDR_SET_VALUES) {
2151 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2152 : }
2153 0 : if (flags & NDR_IN) {
2154 0 : ndr_print_struct(ndr, "in", "wbint_LookupUserAliases");
2155 0 : ndr->depth++;
2156 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
2157 0 : ndr->depth++;
2158 0 : ndr_print_wbint_SidArray(ndr, "sids", r->in.sids);
2159 0 : ndr->depth--;
2160 0 : ndr->depth--;
2161 : }
2162 0 : if (flags & NDR_OUT) {
2163 0 : ndr_print_struct(ndr, "out", "wbint_LookupUserAliases");
2164 0 : ndr->depth++;
2165 0 : ndr_print_ptr(ndr, "rids", r->out.rids);
2166 0 : ndr->depth++;
2167 0 : ndr_print_wbint_RidArray(ndr, "rids", r->out.rids);
2168 0 : ndr->depth--;
2169 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2170 0 : ndr->depth--;
2171 : }
2172 0 : ndr->depth--;
2173 : }
2174 :
2175 40 : static enum ndr_err_code ndr_push_wbint_LookupUserGroups(struct ndr_push *ndr, int flags, const struct wbint_LookupUserGroups *r)
2176 : {
2177 40 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2178 40 : if (flags & NDR_IN) {
2179 40 : if (r->in.sid == NULL) {
2180 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2181 : }
2182 40 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->in.sid));
2183 : }
2184 40 : if (flags & NDR_OUT) {
2185 0 : if (r->out.sids == NULL) {
2186 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2187 : }
2188 0 : NDR_CHECK(ndr_push_wbint_SidArray(ndr, NDR_SCALARS, r->out.sids));
2189 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2190 : }
2191 40 : return NDR_ERR_SUCCESS;
2192 : }
2193 :
2194 40 : static enum ndr_err_code ndr_pull_wbint_LookupUserGroups(struct ndr_pull *ndr, int flags, struct wbint_LookupUserGroups *r)
2195 : {
2196 40 : TALLOC_CTX *_mem_save_sid_0 = NULL;
2197 40 : TALLOC_CTX *_mem_save_sids_0 = NULL;
2198 40 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2199 40 : if (flags & NDR_IN) {
2200 0 : NDR_ZERO_STRUCT(r->out);
2201 :
2202 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2203 0 : NDR_PULL_ALLOC(ndr, r->in.sid);
2204 : }
2205 0 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
2206 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
2207 0 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->in.sid));
2208 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
2209 0 : NDR_PULL_ALLOC(ndr, r->out.sids);
2210 0 : NDR_ZERO_STRUCTP(r->out.sids);
2211 : }
2212 40 : if (flags & NDR_OUT) {
2213 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2214 : if (r->in.sid == NULL) {
2215 : NDR_PULL_ALLOC(ndr, r->in.sid);
2216 : NDR_ZERO_STRUCTP(r->in.sid);
2217 : }
2218 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2219 40 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2220 40 : NDR_PULL_ALLOC(ndr, r->out.sids);
2221 : }
2222 40 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
2223 40 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
2224 40 : NDR_CHECK(ndr_pull_wbint_SidArray(ndr, NDR_SCALARS, r->out.sids));
2225 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
2226 40 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2227 : }
2228 40 : return NDR_ERR_SUCCESS;
2229 : }
2230 :
2231 0 : _PUBLIC_ void ndr_print_wbint_LookupUserGroups(struct ndr_print *ndr, const char *name, int flags, const struct wbint_LookupUserGroups *r)
2232 : {
2233 0 : ndr_print_struct(ndr, name, "wbint_LookupUserGroups");
2234 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2235 0 : ndr->depth++;
2236 0 : if (flags & NDR_SET_VALUES) {
2237 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2238 : }
2239 0 : if (flags & NDR_IN) {
2240 0 : ndr_print_struct(ndr, "in", "wbint_LookupUserGroups");
2241 0 : ndr->depth++;
2242 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
2243 0 : ndr->depth++;
2244 0 : ndr_print_dom_sid(ndr, "sid", r->in.sid);
2245 0 : ndr->depth--;
2246 0 : ndr->depth--;
2247 : }
2248 0 : if (flags & NDR_OUT) {
2249 0 : ndr_print_struct(ndr, "out", "wbint_LookupUserGroups");
2250 0 : ndr->depth++;
2251 0 : ndr_print_ptr(ndr, "sids", r->out.sids);
2252 0 : ndr->depth++;
2253 0 : ndr_print_wbint_SidArray(ndr, "sids", r->out.sids);
2254 0 : ndr->depth--;
2255 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2256 0 : ndr->depth--;
2257 : }
2258 0 : ndr->depth--;
2259 : }
2260 :
2261 20 : static enum ndr_err_code ndr_push_wbint_QuerySequenceNumber(struct ndr_push *ndr, int flags, const struct wbint_QuerySequenceNumber *r)
2262 : {
2263 20 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2264 20 : if (flags & NDR_IN) {
2265 : }
2266 20 : if (flags & NDR_OUT) {
2267 0 : if (r->out.sequence == NULL) {
2268 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2269 : }
2270 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.sequence));
2271 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2272 : }
2273 20 : return NDR_ERR_SUCCESS;
2274 : }
2275 :
2276 20 : static enum ndr_err_code ndr_pull_wbint_QuerySequenceNumber(struct ndr_pull *ndr, int flags, struct wbint_QuerySequenceNumber *r)
2277 : {
2278 20 : TALLOC_CTX *_mem_save_sequence_0 = NULL;
2279 20 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2280 20 : if (flags & NDR_IN) {
2281 0 : NDR_ZERO_STRUCT(r->out);
2282 :
2283 0 : NDR_PULL_ALLOC(ndr, r->out.sequence);
2284 0 : NDR_ZERO_STRUCTP(r->out.sequence);
2285 : }
2286 20 : if (flags & NDR_OUT) {
2287 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2288 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2289 20 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2290 20 : NDR_PULL_ALLOC(ndr, r->out.sequence);
2291 : }
2292 20 : _mem_save_sequence_0 = NDR_PULL_GET_MEM_CTX(ndr);
2293 20 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sequence, LIBNDR_FLAG_REF_ALLOC);
2294 20 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.sequence));
2295 20 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sequence_0, LIBNDR_FLAG_REF_ALLOC);
2296 20 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2297 : }
2298 20 : return NDR_ERR_SUCCESS;
2299 : }
2300 :
2301 0 : _PUBLIC_ void ndr_print_wbint_QuerySequenceNumber(struct ndr_print *ndr, const char *name, int flags, const struct wbint_QuerySequenceNumber *r)
2302 : {
2303 0 : ndr_print_struct(ndr, name, "wbint_QuerySequenceNumber");
2304 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2305 0 : ndr->depth++;
2306 0 : if (flags & NDR_SET_VALUES) {
2307 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2308 : }
2309 0 : if (flags & NDR_IN) {
2310 0 : ndr_print_struct(ndr, "in", "wbint_QuerySequenceNumber");
2311 0 : ndr->depth++;
2312 0 : ndr->depth--;
2313 : }
2314 0 : if (flags & NDR_OUT) {
2315 0 : ndr_print_struct(ndr, "out", "wbint_QuerySequenceNumber");
2316 0 : ndr->depth++;
2317 0 : ndr_print_ptr(ndr, "sequence", r->out.sequence);
2318 0 : ndr->depth++;
2319 0 : ndr_print_uint32(ndr, "sequence", *r->out.sequence);
2320 0 : ndr->depth--;
2321 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2322 0 : ndr->depth--;
2323 : }
2324 0 : ndr->depth--;
2325 : }
2326 :
2327 0 : static enum ndr_err_code ndr_push_wbint_LookupGroupMembers(struct ndr_push *ndr, int flags, const struct wbint_LookupGroupMembers *r)
2328 : {
2329 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2330 0 : if (flags & NDR_IN) {
2331 0 : if (r->in.sid == NULL) {
2332 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2333 : }
2334 0 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->in.sid));
2335 0 : NDR_CHECK(ndr_push_lsa_SidType(ndr, NDR_SCALARS, r->in.type));
2336 : }
2337 0 : if (flags & NDR_OUT) {
2338 0 : if (r->out.members == NULL) {
2339 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2340 : }
2341 0 : NDR_CHECK(ndr_push_wbint_Principals(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.members));
2342 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2343 : }
2344 0 : return NDR_ERR_SUCCESS;
2345 : }
2346 :
2347 0 : static enum ndr_err_code ndr_pull_wbint_LookupGroupMembers(struct ndr_pull *ndr, int flags, struct wbint_LookupGroupMembers *r)
2348 : {
2349 0 : TALLOC_CTX *_mem_save_sid_0 = NULL;
2350 0 : TALLOC_CTX *_mem_save_members_0 = NULL;
2351 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2352 0 : if (flags & NDR_IN) {
2353 0 : NDR_ZERO_STRUCT(r->out);
2354 :
2355 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2356 0 : NDR_PULL_ALLOC(ndr, r->in.sid);
2357 : }
2358 0 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
2359 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
2360 0 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->in.sid));
2361 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
2362 0 : NDR_CHECK(ndr_pull_lsa_SidType(ndr, NDR_SCALARS, &r->in.type));
2363 0 : NDR_PULL_ALLOC(ndr, r->out.members);
2364 0 : NDR_ZERO_STRUCTP(r->out.members);
2365 : }
2366 0 : if (flags & NDR_OUT) {
2367 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2368 : if (r->in.sid == NULL) {
2369 : NDR_PULL_ALLOC(ndr, r->in.sid);
2370 : NDR_ZERO_STRUCTP(r->in.sid);
2371 : }
2372 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2373 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2374 0 : NDR_PULL_ALLOC(ndr, r->out.members);
2375 : }
2376 0 : _mem_save_members_0 = NDR_PULL_GET_MEM_CTX(ndr);
2377 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.members, LIBNDR_FLAG_REF_ALLOC);
2378 0 : NDR_CHECK(ndr_pull_wbint_Principals(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.members));
2379 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_members_0, LIBNDR_FLAG_REF_ALLOC);
2380 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2381 : }
2382 0 : return NDR_ERR_SUCCESS;
2383 : }
2384 :
2385 0 : _PUBLIC_ void ndr_print_wbint_LookupGroupMembers(struct ndr_print *ndr, const char *name, int flags, const struct wbint_LookupGroupMembers *r)
2386 : {
2387 0 : ndr_print_struct(ndr, name, "wbint_LookupGroupMembers");
2388 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2389 0 : ndr->depth++;
2390 0 : if (flags & NDR_SET_VALUES) {
2391 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2392 : }
2393 0 : if (flags & NDR_IN) {
2394 0 : ndr_print_struct(ndr, "in", "wbint_LookupGroupMembers");
2395 0 : ndr->depth++;
2396 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
2397 0 : ndr->depth++;
2398 0 : ndr_print_dom_sid(ndr, "sid", r->in.sid);
2399 0 : ndr->depth--;
2400 0 : ndr_print_lsa_SidType(ndr, "type", r->in.type);
2401 0 : ndr->depth--;
2402 : }
2403 0 : if (flags & NDR_OUT) {
2404 0 : ndr_print_struct(ndr, "out", "wbint_LookupGroupMembers");
2405 0 : ndr->depth++;
2406 0 : ndr_print_ptr(ndr, "members", r->out.members);
2407 0 : ndr->depth++;
2408 0 : ndr_print_wbint_Principals(ndr, "members", r->out.members);
2409 0 : ndr->depth--;
2410 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2411 0 : ndr->depth--;
2412 : }
2413 0 : ndr->depth--;
2414 : }
2415 :
2416 575 : static enum ndr_err_code ndr_push_wbint_QueryGroupList(struct ndr_push *ndr, int flags, const struct wbint_QueryGroupList *r)
2417 : {
2418 575 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2419 575 : if (flags & NDR_IN) {
2420 : }
2421 575 : if (flags & NDR_OUT) {
2422 0 : if (r->out.groups == NULL) {
2423 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2424 : }
2425 0 : NDR_CHECK(ndr_push_wbint_Principals(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.groups));
2426 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2427 : }
2428 575 : return NDR_ERR_SUCCESS;
2429 : }
2430 :
2431 573 : static enum ndr_err_code ndr_pull_wbint_QueryGroupList(struct ndr_pull *ndr, int flags, struct wbint_QueryGroupList *r)
2432 : {
2433 573 : TALLOC_CTX *_mem_save_groups_0 = NULL;
2434 573 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2435 573 : if (flags & NDR_IN) {
2436 0 : NDR_ZERO_STRUCT(r->out);
2437 :
2438 0 : NDR_PULL_ALLOC(ndr, r->out.groups);
2439 0 : NDR_ZERO_STRUCTP(r->out.groups);
2440 : }
2441 573 : if (flags & NDR_OUT) {
2442 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2443 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2444 573 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2445 573 : NDR_PULL_ALLOC(ndr, r->out.groups);
2446 : }
2447 573 : _mem_save_groups_0 = NDR_PULL_GET_MEM_CTX(ndr);
2448 573 : NDR_PULL_SET_MEM_CTX(ndr, r->out.groups, LIBNDR_FLAG_REF_ALLOC);
2449 573 : NDR_CHECK(ndr_pull_wbint_Principals(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.groups));
2450 573 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_groups_0, LIBNDR_FLAG_REF_ALLOC);
2451 573 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2452 : }
2453 573 : return NDR_ERR_SUCCESS;
2454 : }
2455 :
2456 0 : _PUBLIC_ void ndr_print_wbint_QueryGroupList(struct ndr_print *ndr, const char *name, int flags, const struct wbint_QueryGroupList *r)
2457 : {
2458 0 : ndr_print_struct(ndr, name, "wbint_QueryGroupList");
2459 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2460 0 : ndr->depth++;
2461 0 : if (flags & NDR_SET_VALUES) {
2462 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2463 : }
2464 0 : if (flags & NDR_IN) {
2465 0 : ndr_print_struct(ndr, "in", "wbint_QueryGroupList");
2466 0 : ndr->depth++;
2467 0 : ndr->depth--;
2468 : }
2469 0 : if (flags & NDR_OUT) {
2470 0 : ndr_print_struct(ndr, "out", "wbint_QueryGroupList");
2471 0 : ndr->depth++;
2472 0 : ndr_print_ptr(ndr, "groups", r->out.groups);
2473 0 : ndr->depth++;
2474 0 : ndr_print_wbint_Principals(ndr, "groups", r->out.groups);
2475 0 : ndr->depth--;
2476 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2477 0 : ndr->depth--;
2478 : }
2479 0 : ndr->depth--;
2480 : }
2481 :
2482 81 : static enum ndr_err_code ndr_push_wbint_QueryUserRidList(struct ndr_push *ndr, int flags, const struct wbint_QueryUserRidList *r)
2483 : {
2484 81 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2485 81 : if (flags & NDR_IN) {
2486 : }
2487 81 : if (flags & NDR_OUT) {
2488 0 : if (r->out.rids == NULL) {
2489 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2490 : }
2491 0 : NDR_CHECK(ndr_push_wbint_RidArray(ndr, NDR_SCALARS, r->out.rids));
2492 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2493 : }
2494 81 : return NDR_ERR_SUCCESS;
2495 : }
2496 :
2497 81 : static enum ndr_err_code ndr_pull_wbint_QueryUserRidList(struct ndr_pull *ndr, int flags, struct wbint_QueryUserRidList *r)
2498 : {
2499 81 : TALLOC_CTX *_mem_save_rids_0 = NULL;
2500 81 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2501 81 : if (flags & NDR_IN) {
2502 0 : NDR_ZERO_STRUCT(r->out);
2503 :
2504 0 : NDR_PULL_ALLOC(ndr, r->out.rids);
2505 0 : NDR_ZERO_STRUCTP(r->out.rids);
2506 : }
2507 81 : if (flags & NDR_OUT) {
2508 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2509 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2510 81 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2511 81 : NDR_PULL_ALLOC(ndr, r->out.rids);
2512 : }
2513 81 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
2514 81 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rids, LIBNDR_FLAG_REF_ALLOC);
2515 81 : NDR_CHECK(ndr_pull_wbint_RidArray(ndr, NDR_SCALARS, r->out.rids));
2516 81 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, LIBNDR_FLAG_REF_ALLOC);
2517 81 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2518 : }
2519 81 : return NDR_ERR_SUCCESS;
2520 : }
2521 :
2522 0 : _PUBLIC_ void ndr_print_wbint_QueryUserRidList(struct ndr_print *ndr, const char *name, int flags, const struct wbint_QueryUserRidList *r)
2523 : {
2524 0 : ndr_print_struct(ndr, name, "wbint_QueryUserRidList");
2525 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2526 0 : ndr->depth++;
2527 0 : if (flags & NDR_SET_VALUES) {
2528 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2529 : }
2530 0 : if (flags & NDR_IN) {
2531 0 : ndr_print_struct(ndr, "in", "wbint_QueryUserRidList");
2532 0 : ndr->depth++;
2533 0 : ndr->depth--;
2534 : }
2535 0 : if (flags & NDR_OUT) {
2536 0 : ndr_print_struct(ndr, "out", "wbint_QueryUserRidList");
2537 0 : ndr->depth++;
2538 0 : ndr_print_ptr(ndr, "rids", r->out.rids);
2539 0 : ndr->depth++;
2540 0 : ndr_print_wbint_RidArray(ndr, "rids", r->out.rids);
2541 0 : ndr->depth--;
2542 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2543 0 : ndr->depth--;
2544 : }
2545 0 : ndr->depth--;
2546 : }
2547 :
2548 90 : static enum ndr_err_code ndr_push_wbint_DsGetDcName(struct ndr_push *ndr, int flags, const struct wbint_DsGetDcName *r)
2549 : {
2550 90 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2551 90 : if (flags & NDR_IN) {
2552 76 : if (r->in.domain_name == NULL) {
2553 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2554 : }
2555 76 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain_name, CH_UTF8)));
2556 76 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2557 76 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain_name, CH_UTF8)));
2558 76 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.domain_name, ndr_charset_length(r->in.domain_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
2559 76 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.domain_guid));
2560 76 : if (r->in.domain_guid) {
2561 0 : NDR_CHECK(ndr_push_GUID(ndr, NDR_SCALARS, r->in.domain_guid));
2562 : }
2563 76 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.site_name));
2564 76 : if (r->in.site_name) {
2565 32 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.site_name, CH_UTF8)));
2566 32 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2567 32 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.site_name, CH_UTF8)));
2568 32 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.site_name, ndr_charset_length(r->in.site_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
2569 : }
2570 76 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
2571 : }
2572 90 : if (flags & NDR_OUT) {
2573 14 : if (r->out.dc_info == NULL) {
2574 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2575 : }
2576 14 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.dc_info));
2577 14 : if (*r->out.dc_info) {
2578 14 : NDR_CHECK(ndr_push_netr_DsRGetDCNameInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.dc_info));
2579 : }
2580 14 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2581 : }
2582 90 : return NDR_ERR_SUCCESS;
2583 : }
2584 :
2585 90 : static enum ndr_err_code ndr_pull_wbint_DsGetDcName(struct ndr_pull *ndr, int flags, struct wbint_DsGetDcName *r)
2586 : {
2587 90 : uint32_t size_domain_name_1 = 0;
2588 90 : uint32_t length_domain_name_1 = 0;
2589 : uint32_t _ptr_domain_guid;
2590 : uint32_t _ptr_site_name;
2591 90 : uint32_t size_site_name_1 = 0;
2592 90 : uint32_t length_site_name_1 = 0;
2593 : uint32_t _ptr_dc_info;
2594 90 : TALLOC_CTX *_mem_save_domain_guid_0 = NULL;
2595 90 : TALLOC_CTX *_mem_save_site_name_0 = NULL;
2596 90 : TALLOC_CTX *_mem_save_dc_info_0 = NULL;
2597 90 : TALLOC_CTX *_mem_save_dc_info_1 = NULL;
2598 90 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2599 90 : if (flags & NDR_IN) {
2600 16 : NDR_ZERO_STRUCT(r->out);
2601 :
2602 16 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.domain_name));
2603 16 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.domain_name));
2604 16 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.domain_name, &size_domain_name_1));
2605 16 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.domain_name, &length_domain_name_1));
2606 16 : if (length_domain_name_1 > size_domain_name_1) {
2607 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_name_1, length_domain_name_1);
2608 : }
2609 16 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_name_1, sizeof(uint8_t)));
2610 16 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.domain_name, length_domain_name_1, sizeof(uint8_t), CH_UTF8));
2611 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain_guid));
2612 16 : if (_ptr_domain_guid) {
2613 0 : NDR_PULL_ALLOC(ndr, r->in.domain_guid);
2614 : } else {
2615 16 : r->in.domain_guid = NULL;
2616 : }
2617 16 : if (r->in.domain_guid) {
2618 0 : _mem_save_domain_guid_0 = NDR_PULL_GET_MEM_CTX(ndr);
2619 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_guid, 0);
2620 0 : NDR_CHECK(ndr_pull_GUID(ndr, NDR_SCALARS, r->in.domain_guid));
2621 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_guid_0, 0);
2622 : }
2623 16 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_site_name));
2624 16 : if (_ptr_site_name) {
2625 8 : NDR_PULL_ALLOC(ndr, r->in.site_name);
2626 : } else {
2627 8 : r->in.site_name = NULL;
2628 : }
2629 16 : if (r->in.site_name) {
2630 8 : _mem_save_site_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
2631 8 : NDR_PULL_SET_MEM_CTX(ndr, r->in.site_name, 0);
2632 8 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.site_name));
2633 8 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.site_name));
2634 8 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.site_name, &size_site_name_1));
2635 8 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.site_name, &length_site_name_1));
2636 8 : if (length_site_name_1 > size_site_name_1) {
2637 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_site_name_1, length_site_name_1);
2638 : }
2639 8 : NDR_CHECK(ndr_check_string_terminator(ndr, length_site_name_1, sizeof(uint8_t)));
2640 8 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.site_name, length_site_name_1, sizeof(uint8_t), CH_UTF8));
2641 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_site_name_0, 0);
2642 : }
2643 16 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
2644 16 : NDR_PULL_ALLOC(ndr, r->out.dc_info);
2645 16 : NDR_ZERO_STRUCTP(r->out.dc_info);
2646 : }
2647 90 : if (flags & NDR_OUT) {
2648 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2649 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2650 74 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2651 74 : NDR_PULL_ALLOC(ndr, r->out.dc_info);
2652 : }
2653 74 : _mem_save_dc_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
2654 74 : NDR_PULL_SET_MEM_CTX(ndr, r->out.dc_info, LIBNDR_FLAG_REF_ALLOC);
2655 74 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_dc_info));
2656 74 : if (_ptr_dc_info) {
2657 68 : NDR_PULL_ALLOC(ndr, *r->out.dc_info);
2658 : } else {
2659 6 : *r->out.dc_info = NULL;
2660 : }
2661 74 : if (*r->out.dc_info) {
2662 68 : _mem_save_dc_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
2663 68 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.dc_info, 0);
2664 68 : NDR_CHECK(ndr_pull_netr_DsRGetDCNameInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.dc_info));
2665 68 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dc_info_1, 0);
2666 : }
2667 74 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dc_info_0, LIBNDR_FLAG_REF_ALLOC);
2668 74 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2669 : }
2670 90 : return NDR_ERR_SUCCESS;
2671 : }
2672 :
2673 0 : _PUBLIC_ void ndr_print_wbint_DsGetDcName(struct ndr_print *ndr, const char *name, int flags, const struct wbint_DsGetDcName *r)
2674 : {
2675 0 : ndr_print_struct(ndr, name, "wbint_DsGetDcName");
2676 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2677 0 : ndr->depth++;
2678 0 : if (flags & NDR_SET_VALUES) {
2679 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2680 : }
2681 0 : if (flags & NDR_IN) {
2682 0 : ndr_print_struct(ndr, "in", "wbint_DsGetDcName");
2683 0 : ndr->depth++;
2684 0 : ndr_print_ptr(ndr, "domain_name", r->in.domain_name);
2685 0 : ndr->depth++;
2686 0 : ndr_print_string(ndr, "domain_name", r->in.domain_name);
2687 0 : ndr->depth--;
2688 0 : ndr_print_ptr(ndr, "domain_guid", r->in.domain_guid);
2689 0 : ndr->depth++;
2690 0 : if (r->in.domain_guid) {
2691 0 : ndr_print_GUID(ndr, "domain_guid", r->in.domain_guid);
2692 : }
2693 0 : ndr->depth--;
2694 0 : ndr_print_ptr(ndr, "site_name", r->in.site_name);
2695 0 : ndr->depth++;
2696 0 : if (r->in.site_name) {
2697 0 : ndr_print_string(ndr, "site_name", r->in.site_name);
2698 : }
2699 0 : ndr->depth--;
2700 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
2701 0 : ndr->depth--;
2702 : }
2703 0 : if (flags & NDR_OUT) {
2704 0 : ndr_print_struct(ndr, "out", "wbint_DsGetDcName");
2705 0 : ndr->depth++;
2706 0 : ndr_print_ptr(ndr, "dc_info", r->out.dc_info);
2707 0 : ndr->depth++;
2708 0 : ndr_print_ptr(ndr, "dc_info", *r->out.dc_info);
2709 0 : ndr->depth++;
2710 0 : if (*r->out.dc_info) {
2711 0 : ndr_print_netr_DsRGetDCNameInfo(ndr, "dc_info", *r->out.dc_info);
2712 : }
2713 0 : ndr->depth--;
2714 0 : ndr->depth--;
2715 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2716 0 : ndr->depth--;
2717 : }
2718 0 : ndr->depth--;
2719 : }
2720 :
2721 50 : static enum ndr_err_code ndr_push_wbint_LookupRids(struct ndr_push *ndr, int flags, const struct wbint_LookupRids *r)
2722 : {
2723 50 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2724 50 : if (flags & NDR_IN) {
2725 50 : if (r->in.domain_sid == NULL) {
2726 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2727 : }
2728 50 : if (r->in.rids == NULL) {
2729 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2730 : }
2731 50 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->in.domain_sid));
2732 50 : NDR_CHECK(ndr_push_wbint_RidArray(ndr, NDR_SCALARS, r->in.rids));
2733 : }
2734 50 : if (flags & NDR_OUT) {
2735 0 : if (r->out.domain_name == NULL) {
2736 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2737 : }
2738 0 : if (r->out.names == NULL) {
2739 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2740 : }
2741 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.domain_name));
2742 0 : if (*r->out.domain_name) {
2743 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.domain_name, CH_UTF8)));
2744 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2745 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.domain_name, CH_UTF8)));
2746 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.domain_name, ndr_charset_length(*r->out.domain_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
2747 : }
2748 0 : NDR_CHECK(ndr_push_wbint_Principals(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
2749 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2750 : }
2751 50 : return NDR_ERR_SUCCESS;
2752 : }
2753 :
2754 50 : static enum ndr_err_code ndr_pull_wbint_LookupRids(struct ndr_pull *ndr, int flags, struct wbint_LookupRids *r)
2755 : {
2756 : uint32_t _ptr_domain_name;
2757 50 : uint32_t size_domain_name_2 = 0;
2758 50 : uint32_t length_domain_name_2 = 0;
2759 50 : TALLOC_CTX *_mem_save_domain_sid_0 = NULL;
2760 50 : TALLOC_CTX *_mem_save_rids_0 = NULL;
2761 50 : TALLOC_CTX *_mem_save_domain_name_0 = NULL;
2762 50 : TALLOC_CTX *_mem_save_domain_name_1 = NULL;
2763 50 : TALLOC_CTX *_mem_save_names_0 = NULL;
2764 50 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2765 50 : if (flags & NDR_IN) {
2766 0 : NDR_ZERO_STRUCT(r->out);
2767 :
2768 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2769 0 : NDR_PULL_ALLOC(ndr, r->in.domain_sid);
2770 : }
2771 0 : _mem_save_domain_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
2772 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_sid, LIBNDR_FLAG_REF_ALLOC);
2773 0 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->in.domain_sid));
2774 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_sid_0, LIBNDR_FLAG_REF_ALLOC);
2775 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2776 0 : NDR_PULL_ALLOC(ndr, r->in.rids);
2777 : }
2778 0 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
2779 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.rids, LIBNDR_FLAG_REF_ALLOC);
2780 0 : NDR_CHECK(ndr_pull_wbint_RidArray(ndr, NDR_SCALARS, r->in.rids));
2781 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, LIBNDR_FLAG_REF_ALLOC);
2782 0 : NDR_PULL_ALLOC(ndr, r->out.domain_name);
2783 0 : NDR_ZERO_STRUCTP(r->out.domain_name);
2784 0 : NDR_PULL_ALLOC(ndr, r->out.names);
2785 0 : NDR_ZERO_STRUCTP(r->out.names);
2786 : }
2787 50 : if (flags & NDR_OUT) {
2788 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2789 : if (r->in.domain_sid == NULL) {
2790 : NDR_PULL_ALLOC(ndr, r->in.domain_sid);
2791 : NDR_ZERO_STRUCTP(r->in.domain_sid);
2792 : }
2793 : if (r->in.rids == NULL) {
2794 : NDR_PULL_ALLOC(ndr, r->in.rids);
2795 : NDR_ZERO_STRUCTP(r->in.rids);
2796 : }
2797 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2798 50 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2799 50 : NDR_PULL_ALLOC(ndr, r->out.domain_name);
2800 : }
2801 50 : _mem_save_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
2802 50 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domain_name, LIBNDR_FLAG_REF_ALLOC);
2803 50 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain_name));
2804 50 : if (_ptr_domain_name) {
2805 18 : NDR_PULL_ALLOC(ndr, *r->out.domain_name);
2806 : } else {
2807 32 : *r->out.domain_name = NULL;
2808 : }
2809 50 : if (*r->out.domain_name) {
2810 18 : _mem_save_domain_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
2811 18 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.domain_name, 0);
2812 18 : NDR_CHECK(ndr_pull_array_size(ndr, r->out.domain_name));
2813 18 : NDR_CHECK(ndr_pull_array_length(ndr, r->out.domain_name));
2814 18 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)r->out.domain_name, &size_domain_name_2));
2815 18 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)r->out.domain_name, &length_domain_name_2));
2816 18 : if (length_domain_name_2 > size_domain_name_2) {
2817 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_name_2, length_domain_name_2);
2818 : }
2819 18 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_name_2, sizeof(uint8_t)));
2820 18 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.domain_name, length_domain_name_2, sizeof(uint8_t), CH_UTF8));
2821 18 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_name_1, 0);
2822 : }
2823 50 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_name_0, LIBNDR_FLAG_REF_ALLOC);
2824 50 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
2825 50 : NDR_PULL_ALLOC(ndr, r->out.names);
2826 : }
2827 50 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
2828 50 : NDR_PULL_SET_MEM_CTX(ndr, r->out.names, LIBNDR_FLAG_REF_ALLOC);
2829 50 : NDR_CHECK(ndr_pull_wbint_Principals(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
2830 50 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
2831 50 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2832 : }
2833 50 : return NDR_ERR_SUCCESS;
2834 : }
2835 :
2836 0 : _PUBLIC_ void ndr_print_wbint_LookupRids(struct ndr_print *ndr, const char *name, int flags, const struct wbint_LookupRids *r)
2837 : {
2838 0 : ndr_print_struct(ndr, name, "wbint_LookupRids");
2839 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2840 0 : ndr->depth++;
2841 0 : if (flags & NDR_SET_VALUES) {
2842 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2843 : }
2844 0 : if (flags & NDR_IN) {
2845 0 : ndr_print_struct(ndr, "in", "wbint_LookupRids");
2846 0 : ndr->depth++;
2847 0 : ndr_print_ptr(ndr, "domain_sid", r->in.domain_sid);
2848 0 : ndr->depth++;
2849 0 : ndr_print_dom_sid(ndr, "domain_sid", r->in.domain_sid);
2850 0 : ndr->depth--;
2851 0 : ndr_print_ptr(ndr, "rids", r->in.rids);
2852 0 : ndr->depth++;
2853 0 : ndr_print_wbint_RidArray(ndr, "rids", r->in.rids);
2854 0 : ndr->depth--;
2855 0 : ndr->depth--;
2856 : }
2857 0 : if (flags & NDR_OUT) {
2858 0 : ndr_print_struct(ndr, "out", "wbint_LookupRids");
2859 0 : ndr->depth++;
2860 0 : ndr_print_ptr(ndr, "domain_name", r->out.domain_name);
2861 0 : ndr->depth++;
2862 0 : ndr_print_ptr(ndr, "domain_name", *r->out.domain_name);
2863 0 : ndr->depth++;
2864 0 : if (*r->out.domain_name) {
2865 0 : ndr_print_string(ndr, "domain_name", *r->out.domain_name);
2866 : }
2867 0 : ndr->depth--;
2868 0 : ndr->depth--;
2869 0 : ndr_print_ptr(ndr, "names", r->out.names);
2870 0 : ndr->depth++;
2871 0 : ndr_print_wbint_Principals(ndr, "names", r->out.names);
2872 0 : ndr->depth--;
2873 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2874 0 : ndr->depth--;
2875 : }
2876 0 : ndr->depth--;
2877 : }
2878 :
2879 12 : static enum ndr_err_code ndr_push_wbint_CheckMachineAccount(struct ndr_push *ndr, int flags, const struct wbint_CheckMachineAccount *r)
2880 : {
2881 12 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2882 12 : if (flags & NDR_IN) {
2883 : }
2884 12 : if (flags & NDR_OUT) {
2885 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2886 : }
2887 12 : return NDR_ERR_SUCCESS;
2888 : }
2889 :
2890 12 : static enum ndr_err_code ndr_pull_wbint_CheckMachineAccount(struct ndr_pull *ndr, int flags, struct wbint_CheckMachineAccount *r)
2891 : {
2892 12 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2893 12 : if (flags & NDR_IN) {
2894 : }
2895 12 : if (flags & NDR_OUT) {
2896 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2897 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2898 12 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2899 : }
2900 12 : return NDR_ERR_SUCCESS;
2901 : }
2902 :
2903 0 : _PUBLIC_ void ndr_print_wbint_CheckMachineAccount(struct ndr_print *ndr, const char *name, int flags, const struct wbint_CheckMachineAccount *r)
2904 : {
2905 0 : ndr_print_struct(ndr, name, "wbint_CheckMachineAccount");
2906 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2907 0 : ndr->depth++;
2908 0 : if (flags & NDR_SET_VALUES) {
2909 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2910 : }
2911 0 : if (flags & NDR_IN) {
2912 0 : ndr_print_struct(ndr, "in", "wbint_CheckMachineAccount");
2913 0 : ndr->depth++;
2914 0 : ndr->depth--;
2915 : }
2916 0 : if (flags & NDR_OUT) {
2917 0 : ndr_print_struct(ndr, "out", "wbint_CheckMachineAccount");
2918 0 : ndr->depth++;
2919 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2920 0 : ndr->depth--;
2921 : }
2922 0 : ndr->depth--;
2923 : }
2924 :
2925 11 : static enum ndr_err_code ndr_push_wbint_ChangeMachineAccount(struct ndr_push *ndr, int flags, const struct wbint_ChangeMachineAccount *r)
2926 : {
2927 11 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2928 11 : if (flags & NDR_IN) {
2929 : }
2930 11 : if (flags & NDR_OUT) {
2931 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2932 : }
2933 11 : return NDR_ERR_SUCCESS;
2934 : }
2935 :
2936 11 : static enum ndr_err_code ndr_pull_wbint_ChangeMachineAccount(struct ndr_pull *ndr, int flags, struct wbint_ChangeMachineAccount *r)
2937 : {
2938 11 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
2939 11 : if (flags & NDR_IN) {
2940 : }
2941 11 : if (flags & NDR_OUT) {
2942 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
2943 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
2944 11 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
2945 : }
2946 11 : return NDR_ERR_SUCCESS;
2947 : }
2948 :
2949 0 : _PUBLIC_ void ndr_print_wbint_ChangeMachineAccount(struct ndr_print *ndr, const char *name, int flags, const struct wbint_ChangeMachineAccount *r)
2950 : {
2951 0 : ndr_print_struct(ndr, name, "wbint_ChangeMachineAccount");
2952 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2953 0 : ndr->depth++;
2954 0 : if (flags & NDR_SET_VALUES) {
2955 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
2956 : }
2957 0 : if (flags & NDR_IN) {
2958 0 : ndr_print_struct(ndr, "in", "wbint_ChangeMachineAccount");
2959 0 : ndr->depth++;
2960 0 : ndr->depth--;
2961 : }
2962 0 : if (flags & NDR_OUT) {
2963 0 : ndr_print_struct(ndr, "out", "wbint_ChangeMachineAccount");
2964 0 : ndr->depth++;
2965 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
2966 0 : ndr->depth--;
2967 : }
2968 0 : ndr->depth--;
2969 : }
2970 :
2971 1393 : static enum ndr_err_code ndr_push_wbint_PingDc(struct ndr_push *ndr, int flags, const struct wbint_PingDc *r)
2972 : {
2973 1393 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
2974 1393 : if (flags & NDR_IN) {
2975 : }
2976 1393 : if (flags & NDR_OUT) {
2977 0 : if (r->out.dcname == NULL) {
2978 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
2979 : }
2980 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.dcname));
2981 0 : if (*r->out.dcname) {
2982 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.dcname, CH_UTF8)));
2983 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2984 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.dcname, CH_UTF8)));
2985 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.dcname, ndr_charset_length(*r->out.dcname, CH_UTF8), sizeof(uint8_t), CH_UTF8));
2986 : }
2987 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
2988 : }
2989 1393 : return NDR_ERR_SUCCESS;
2990 : }
2991 :
2992 1392 : static enum ndr_err_code ndr_pull_wbint_PingDc(struct ndr_pull *ndr, int flags, struct wbint_PingDc *r)
2993 : {
2994 : uint32_t _ptr_dcname;
2995 1392 : uint32_t size_dcname_2 = 0;
2996 1392 : uint32_t length_dcname_2 = 0;
2997 1392 : TALLOC_CTX *_mem_save_dcname_0 = NULL;
2998 1392 : TALLOC_CTX *_mem_save_dcname_1 = NULL;
2999 1392 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
3000 1392 : if (flags & NDR_IN) {
3001 0 : NDR_ZERO_STRUCT(r->out);
3002 :
3003 0 : NDR_PULL_ALLOC(ndr, r->out.dcname);
3004 0 : NDR_ZERO_STRUCTP(r->out.dcname);
3005 : }
3006 1392 : if (flags & NDR_OUT) {
3007 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
3008 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
3009 1392 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3010 1392 : NDR_PULL_ALLOC(ndr, r->out.dcname);
3011 : }
3012 1392 : _mem_save_dcname_0 = NDR_PULL_GET_MEM_CTX(ndr);
3013 1392 : NDR_PULL_SET_MEM_CTX(ndr, r->out.dcname, LIBNDR_FLAG_REF_ALLOC);
3014 1392 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_dcname));
3015 1392 : if (_ptr_dcname) {
3016 49 : NDR_PULL_ALLOC(ndr, *r->out.dcname);
3017 : } else {
3018 1343 : *r->out.dcname = NULL;
3019 : }
3020 1392 : if (*r->out.dcname) {
3021 49 : _mem_save_dcname_1 = NDR_PULL_GET_MEM_CTX(ndr);
3022 49 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.dcname, 0);
3023 49 : NDR_CHECK(ndr_pull_array_size(ndr, r->out.dcname));
3024 49 : NDR_CHECK(ndr_pull_array_length(ndr, r->out.dcname));
3025 49 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)r->out.dcname, &size_dcname_2));
3026 49 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)r->out.dcname, &length_dcname_2));
3027 49 : if (length_dcname_2 > size_dcname_2) {
3028 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_dcname_2, length_dcname_2);
3029 : }
3030 49 : NDR_CHECK(ndr_check_string_terminator(ndr, length_dcname_2, sizeof(uint8_t)));
3031 49 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.dcname, length_dcname_2, sizeof(uint8_t), CH_UTF8));
3032 49 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dcname_1, 0);
3033 : }
3034 1392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dcname_0, LIBNDR_FLAG_REF_ALLOC);
3035 1392 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
3036 : }
3037 1392 : return NDR_ERR_SUCCESS;
3038 : }
3039 :
3040 0 : _PUBLIC_ void ndr_print_wbint_PingDc(struct ndr_print *ndr, const char *name, int flags, const struct wbint_PingDc *r)
3041 : {
3042 0 : ndr_print_struct(ndr, name, "wbint_PingDc");
3043 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3044 0 : ndr->depth++;
3045 0 : if (flags & NDR_SET_VALUES) {
3046 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3047 : }
3048 0 : if (flags & NDR_IN) {
3049 0 : ndr_print_struct(ndr, "in", "wbint_PingDc");
3050 0 : ndr->depth++;
3051 0 : ndr->depth--;
3052 : }
3053 0 : if (flags & NDR_OUT) {
3054 0 : ndr_print_struct(ndr, "out", "wbint_PingDc");
3055 0 : ndr->depth++;
3056 0 : ndr_print_ptr(ndr, "dcname", r->out.dcname);
3057 0 : ndr->depth++;
3058 0 : ndr_print_ptr(ndr, "dcname", *r->out.dcname);
3059 0 : ndr->depth++;
3060 0 : if (*r->out.dcname) {
3061 0 : ndr_print_string(ndr, "dcname", *r->out.dcname);
3062 : }
3063 0 : ndr->depth--;
3064 0 : ndr->depth--;
3065 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
3066 0 : ndr->depth--;
3067 : }
3068 0 : ndr->depth--;
3069 : }
3070 :
3071 0 : static enum ndr_err_code ndr_push_wbint_ListTrustedDomains(struct ndr_push *ndr, int flags, const struct wbint_ListTrustedDomains *r)
3072 : {
3073 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
3074 0 : if (flags & NDR_IN) {
3075 0 : if (r->in.client_name == NULL) {
3076 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3077 : }
3078 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3079 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3080 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3081 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client_name, ndr_charset_length(r->in.client_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3082 0 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.client_pid));
3083 : }
3084 0 : if (flags & NDR_OUT) {
3085 0 : if (r->out.domains == NULL) {
3086 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3087 : }
3088 0 : NDR_CHECK(ndr_push_netr_DomainTrustList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
3089 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
3090 : }
3091 0 : return NDR_ERR_SUCCESS;
3092 : }
3093 :
3094 0 : static enum ndr_err_code ndr_pull_wbint_ListTrustedDomains(struct ndr_pull *ndr, int flags, struct wbint_ListTrustedDomains *r)
3095 : {
3096 0 : uint32_t size_client_name_1 = 0;
3097 0 : uint32_t length_client_name_1 = 0;
3098 0 : TALLOC_CTX *_mem_save_domains_0 = NULL;
3099 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
3100 0 : if (flags & NDR_IN) {
3101 0 : NDR_ZERO_STRUCT(r->out);
3102 :
3103 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client_name));
3104 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client_name));
3105 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client_name, &size_client_name_1));
3106 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client_name, &length_client_name_1));
3107 0 : if (length_client_name_1 > size_client_name_1) {
3108 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_client_name_1, length_client_name_1);
3109 : }
3110 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_name_1, sizeof(uint8_t)));
3111 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client_name, length_client_name_1, sizeof(uint8_t), CH_UTF8));
3112 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.client_pid));
3113 0 : NDR_PULL_ALLOC(ndr, r->out.domains);
3114 0 : NDR_ZERO_STRUCTP(r->out.domains);
3115 : }
3116 0 : if (flags & NDR_OUT) {
3117 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
3118 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
3119 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3120 0 : NDR_PULL_ALLOC(ndr, r->out.domains);
3121 : }
3122 0 : _mem_save_domains_0 = NDR_PULL_GET_MEM_CTX(ndr);
3123 0 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domains, LIBNDR_FLAG_REF_ALLOC);
3124 0 : NDR_CHECK(ndr_pull_netr_DomainTrustList(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.domains));
3125 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domains_0, LIBNDR_FLAG_REF_ALLOC);
3126 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
3127 : }
3128 0 : return NDR_ERR_SUCCESS;
3129 : }
3130 :
3131 0 : _PUBLIC_ void ndr_print_wbint_ListTrustedDomains(struct ndr_print *ndr, const char *name, int flags, const struct wbint_ListTrustedDomains *r)
3132 : {
3133 0 : ndr_print_struct(ndr, name, "wbint_ListTrustedDomains");
3134 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3135 0 : ndr->depth++;
3136 0 : if (flags & NDR_SET_VALUES) {
3137 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3138 : }
3139 0 : if (flags & NDR_IN) {
3140 0 : ndr_print_struct(ndr, "in", "wbint_ListTrustedDomains");
3141 0 : ndr->depth++;
3142 0 : ndr_print_ptr(ndr, "client_name", r->in.client_name);
3143 0 : ndr->depth++;
3144 0 : ndr_print_string(ndr, "client_name", r->in.client_name);
3145 0 : ndr->depth--;
3146 0 : ndr_print_hyper(ndr, "client_pid", r->in.client_pid);
3147 0 : ndr->depth--;
3148 : }
3149 0 : if (flags & NDR_OUT) {
3150 0 : ndr_print_struct(ndr, "out", "wbint_ListTrustedDomains");
3151 0 : ndr->depth++;
3152 0 : ndr_print_ptr(ndr, "domains", r->out.domains);
3153 0 : ndr->depth++;
3154 0 : ndr_print_netr_DomainTrustList(ndr, "domains", r->out.domains);
3155 0 : ndr->depth--;
3156 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
3157 0 : ndr->depth--;
3158 : }
3159 0 : ndr->depth--;
3160 : }
3161 :
3162 392 : static enum ndr_err_code ndr_push_wbint_PamAuth(struct ndr_push *ndr, int flags, const struct wbint_PamAuth *r)
3163 : {
3164 392 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
3165 392 : if (flags & NDR_IN) {
3166 392 : if (r->in.client_name == NULL) {
3167 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3168 : }
3169 392 : if (r->in.info == NULL) {
3170 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3171 : }
3172 392 : if (r->in.require_membership_of_sid == NULL) {
3173 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3174 : }
3175 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3176 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3177 392 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3178 392 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client_name, ndr_charset_length(r->in.client_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3179 392 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.client_pid));
3180 392 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3181 392 : NDR_CHECK(ndr_push_wbint_AuthUserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
3182 392 : NDR_CHECK(ndr_push_wbint_SidArray(ndr, NDR_SCALARS, r->in.require_membership_of_sid));
3183 : }
3184 392 : if (flags & NDR_OUT) {
3185 0 : if (r->out.validation == NULL) {
3186 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3187 : }
3188 0 : NDR_CHECK(ndr_push_wbint_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.validation));
3189 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
3190 : }
3191 392 : return NDR_ERR_SUCCESS;
3192 : }
3193 :
3194 392 : static enum ndr_err_code ndr_pull_wbint_PamAuth(struct ndr_pull *ndr, int flags, struct wbint_PamAuth *r)
3195 : {
3196 392 : uint32_t size_client_name_1 = 0;
3197 392 : uint32_t length_client_name_1 = 0;
3198 392 : TALLOC_CTX *_mem_save_info_0 = NULL;
3199 392 : TALLOC_CTX *_mem_save_require_membership_of_sid_0 = NULL;
3200 392 : TALLOC_CTX *_mem_save_validation_0 = NULL;
3201 392 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
3202 392 : if (flags & NDR_IN) {
3203 0 : NDR_ZERO_STRUCT(r->out);
3204 :
3205 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client_name));
3206 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client_name));
3207 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client_name, &size_client_name_1));
3208 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client_name, &length_client_name_1));
3209 0 : if (length_client_name_1 > size_client_name_1) {
3210 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_client_name_1, length_client_name_1);
3211 : }
3212 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_name_1, sizeof(uint8_t)));
3213 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client_name, length_client_name_1, sizeof(uint8_t), CH_UTF8));
3214 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.client_pid));
3215 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3216 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3217 0 : NDR_PULL_ALLOC(ndr, r->in.info);
3218 : }
3219 0 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
3220 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
3221 0 : NDR_CHECK(ndr_pull_wbint_AuthUserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
3222 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
3223 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3224 0 : NDR_PULL_ALLOC(ndr, r->in.require_membership_of_sid);
3225 : }
3226 0 : _mem_save_require_membership_of_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
3227 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.require_membership_of_sid, LIBNDR_FLAG_REF_ALLOC);
3228 0 : NDR_CHECK(ndr_pull_wbint_SidArray(ndr, NDR_SCALARS, r->in.require_membership_of_sid));
3229 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_require_membership_of_sid_0, LIBNDR_FLAG_REF_ALLOC);
3230 0 : NDR_PULL_ALLOC(ndr, r->out.validation);
3231 0 : NDR_ZERO_STRUCTP(r->out.validation);
3232 : }
3233 392 : if (flags & NDR_OUT) {
3234 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
3235 : if (r->in.info == NULL) {
3236 : NDR_PULL_ALLOC(ndr, r->in.info);
3237 : NDR_ZERO_STRUCTP(r->in.info);
3238 : }
3239 : if (r->in.require_membership_of_sid == NULL) {
3240 : NDR_PULL_ALLOC(ndr, r->in.require_membership_of_sid);
3241 : NDR_ZERO_STRUCTP(r->in.require_membership_of_sid);
3242 : }
3243 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
3244 392 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3245 392 : NDR_PULL_ALLOC(ndr, r->out.validation);
3246 : }
3247 392 : _mem_save_validation_0 = NDR_PULL_GET_MEM_CTX(ndr);
3248 392 : NDR_PULL_SET_MEM_CTX(ndr, r->out.validation, LIBNDR_FLAG_REF_ALLOC);
3249 392 : NDR_CHECK(ndr_pull_wbint_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.validation));
3250 392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_validation_0, LIBNDR_FLAG_REF_ALLOC);
3251 392 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
3252 : }
3253 392 : return NDR_ERR_SUCCESS;
3254 : }
3255 :
3256 0 : _PUBLIC_ void ndr_print_wbint_PamAuth(struct ndr_print *ndr, const char *name, int flags, const struct wbint_PamAuth *r)
3257 : {
3258 0 : ndr_print_struct(ndr, name, "wbint_PamAuth");
3259 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3260 0 : ndr->depth++;
3261 0 : if (flags & NDR_SET_VALUES) {
3262 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3263 : }
3264 0 : if (flags & NDR_IN) {
3265 0 : ndr_print_struct(ndr, "in", "wbint_PamAuth");
3266 0 : ndr->depth++;
3267 0 : ndr_print_ptr(ndr, "client_name", r->in.client_name);
3268 0 : ndr->depth++;
3269 0 : ndr_print_string(ndr, "client_name", r->in.client_name);
3270 0 : ndr->depth--;
3271 0 : ndr_print_hyper(ndr, "client_pid", r->in.client_pid);
3272 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
3273 0 : ndr_print_ptr(ndr, "info", r->in.info);
3274 0 : ndr->depth++;
3275 0 : ndr_print_wbint_AuthUserInfo(ndr, "info", r->in.info);
3276 0 : ndr->depth--;
3277 0 : ndr_print_ptr(ndr, "require_membership_of_sid", r->in.require_membership_of_sid);
3278 0 : ndr->depth++;
3279 0 : ndr_print_wbint_SidArray(ndr, "require_membership_of_sid", r->in.require_membership_of_sid);
3280 0 : ndr->depth--;
3281 0 : ndr->depth--;
3282 : }
3283 0 : if (flags & NDR_OUT) {
3284 0 : ndr_print_struct(ndr, "out", "wbint_PamAuth");
3285 0 : ndr->depth++;
3286 0 : ndr_print_ptr(ndr, "validation", r->out.validation);
3287 0 : ndr->depth++;
3288 0 : ndr_print_wbint_Validation(ndr, "validation", r->out.validation);
3289 0 : ndr->depth--;
3290 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
3291 0 : ndr->depth--;
3292 : }
3293 0 : ndr->depth--;
3294 : }
3295 :
3296 458 : static enum ndr_err_code ndr_push_wbint_PamAuthCrap(struct ndr_push *ndr, int flags, const struct wbint_PamAuthCrap *r)
3297 : {
3298 458 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
3299 458 : if (flags & NDR_IN) {
3300 458 : if (r->in.client_name == NULL) {
3301 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3302 : }
3303 458 : if (r->in.user == NULL) {
3304 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3305 : }
3306 458 : if (r->in.domain == NULL) {
3307 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3308 : }
3309 458 : if (r->in.workstation == NULL) {
3310 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3311 : }
3312 458 : if (r->in.require_membership_of_sid == NULL) {
3313 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3314 : }
3315 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3316 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3317 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3318 458 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client_name, ndr_charset_length(r->in.client_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3319 458 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.client_pid));
3320 458 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3321 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3322 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3323 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3324 458 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3325 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain, CH_UTF8)));
3326 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3327 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain, CH_UTF8)));
3328 458 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.domain, ndr_charset_length(r->in.domain, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3329 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.workstation, CH_UTF8)));
3330 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3331 458 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.workstation, CH_UTF8)));
3332 458 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.workstation, ndr_charset_length(r->in.workstation, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3333 : {
3334 458 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3335 458 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3336 458 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->in.lm_resp));
3337 458 : ndr->flags = _flags_save_DATA_BLOB;
3338 : }
3339 : {
3340 458 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3341 458 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3342 458 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->in.nt_resp));
3343 458 : ndr->flags = _flags_save_DATA_BLOB;
3344 : }
3345 : {
3346 458 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3347 458 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3348 458 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->in.chal));
3349 458 : ndr->flags = _flags_save_DATA_BLOB;
3350 : }
3351 458 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.logon_parameters));
3352 458 : NDR_CHECK(ndr_push_wbint_SidArray(ndr, NDR_SCALARS, r->in.require_membership_of_sid));
3353 : }
3354 458 : if (flags & NDR_OUT) {
3355 0 : if (r->out.authoritative == NULL) {
3356 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3357 : }
3358 0 : if (r->out.validation == NULL) {
3359 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3360 : }
3361 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, *r->out.authoritative));
3362 0 : NDR_CHECK(ndr_push_wbint_PamAuthCrapValidation(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.validation));
3363 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
3364 : }
3365 458 : return NDR_ERR_SUCCESS;
3366 : }
3367 :
3368 458 : static enum ndr_err_code ndr_pull_wbint_PamAuthCrap(struct ndr_pull *ndr, int flags, struct wbint_PamAuthCrap *r)
3369 : {
3370 458 : uint32_t size_client_name_1 = 0;
3371 458 : uint32_t length_client_name_1 = 0;
3372 458 : uint32_t size_user_1 = 0;
3373 458 : uint32_t length_user_1 = 0;
3374 458 : uint32_t size_domain_1 = 0;
3375 458 : uint32_t length_domain_1 = 0;
3376 458 : uint32_t size_workstation_1 = 0;
3377 458 : uint32_t length_workstation_1 = 0;
3378 458 : TALLOC_CTX *_mem_save_require_membership_of_sid_0 = NULL;
3379 458 : TALLOC_CTX *_mem_save_authoritative_0 = NULL;
3380 458 : TALLOC_CTX *_mem_save_validation_0 = NULL;
3381 458 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
3382 458 : if (flags & NDR_IN) {
3383 0 : NDR_ZERO_STRUCT(r->out);
3384 :
3385 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client_name));
3386 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client_name));
3387 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client_name, &size_client_name_1));
3388 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client_name, &length_client_name_1));
3389 0 : if (length_client_name_1 > size_client_name_1) {
3390 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_client_name_1, length_client_name_1);
3391 : }
3392 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_name_1, sizeof(uint8_t)));
3393 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client_name, length_client_name_1, sizeof(uint8_t), CH_UTF8));
3394 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.client_pid));
3395 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3396 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
3397 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
3398 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
3399 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
3400 0 : if (length_user_1 > size_user_1) {
3401 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_user_1, length_user_1);
3402 : }
3403 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint8_t)));
3404 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint8_t), CH_UTF8));
3405 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.domain));
3406 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.domain));
3407 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.domain, &size_domain_1));
3408 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.domain, &length_domain_1));
3409 0 : if (length_domain_1 > size_domain_1) {
3410 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_1, length_domain_1);
3411 : }
3412 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint8_t)));
3413 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.domain, length_domain_1, sizeof(uint8_t), CH_UTF8));
3414 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.workstation));
3415 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.workstation));
3416 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.workstation, &size_workstation_1));
3417 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.workstation, &length_workstation_1));
3418 0 : if (length_workstation_1 > size_workstation_1) {
3419 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_workstation_1, length_workstation_1);
3420 : }
3421 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_workstation_1, sizeof(uint8_t)));
3422 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.workstation, length_workstation_1, sizeof(uint8_t), CH_UTF8));
3423 : {
3424 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3425 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3426 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->in.lm_resp));
3427 0 : ndr->flags = _flags_save_DATA_BLOB;
3428 : }
3429 : {
3430 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3431 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3432 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->in.nt_resp));
3433 0 : ndr->flags = _flags_save_DATA_BLOB;
3434 : }
3435 : {
3436 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3437 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3438 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->in.chal));
3439 0 : ndr->flags = _flags_save_DATA_BLOB;
3440 : }
3441 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.logon_parameters));
3442 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3443 0 : NDR_PULL_ALLOC(ndr, r->in.require_membership_of_sid);
3444 : }
3445 0 : _mem_save_require_membership_of_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
3446 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.require_membership_of_sid, LIBNDR_FLAG_REF_ALLOC);
3447 0 : NDR_CHECK(ndr_pull_wbint_SidArray(ndr, NDR_SCALARS, r->in.require_membership_of_sid));
3448 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_require_membership_of_sid_0, LIBNDR_FLAG_REF_ALLOC);
3449 0 : NDR_PULL_ALLOC(ndr, r->out.authoritative);
3450 0 : NDR_ZERO_STRUCTP(r->out.authoritative);
3451 0 : NDR_PULL_ALLOC(ndr, r->out.validation);
3452 0 : NDR_ZERO_STRUCTP(r->out.validation);
3453 : }
3454 458 : if (flags & NDR_OUT) {
3455 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
3456 : if (r->in.require_membership_of_sid == NULL) {
3457 : NDR_PULL_ALLOC(ndr, r->in.require_membership_of_sid);
3458 : NDR_ZERO_STRUCTP(r->in.require_membership_of_sid);
3459 : }
3460 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
3461 458 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3462 458 : NDR_PULL_ALLOC(ndr, r->out.authoritative);
3463 : }
3464 458 : _mem_save_authoritative_0 = NDR_PULL_GET_MEM_CTX(ndr);
3465 458 : NDR_PULL_SET_MEM_CTX(ndr, r->out.authoritative, LIBNDR_FLAG_REF_ALLOC);
3466 458 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, r->out.authoritative));
3467 458 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_authoritative_0, LIBNDR_FLAG_REF_ALLOC);
3468 458 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3469 458 : NDR_PULL_ALLOC(ndr, r->out.validation);
3470 : }
3471 458 : _mem_save_validation_0 = NDR_PULL_GET_MEM_CTX(ndr);
3472 458 : NDR_PULL_SET_MEM_CTX(ndr, r->out.validation, LIBNDR_FLAG_REF_ALLOC);
3473 458 : NDR_CHECK(ndr_pull_wbint_PamAuthCrapValidation(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.validation));
3474 458 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_validation_0, LIBNDR_FLAG_REF_ALLOC);
3475 458 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
3476 : }
3477 458 : return NDR_ERR_SUCCESS;
3478 : }
3479 :
3480 0 : _PUBLIC_ void ndr_print_wbint_PamAuthCrap(struct ndr_print *ndr, const char *name, int flags, const struct wbint_PamAuthCrap *r)
3481 : {
3482 0 : ndr_print_struct(ndr, name, "wbint_PamAuthCrap");
3483 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3484 0 : ndr->depth++;
3485 0 : if (flags & NDR_SET_VALUES) {
3486 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3487 : }
3488 0 : if (flags & NDR_IN) {
3489 0 : ndr_print_struct(ndr, "in", "wbint_PamAuthCrap");
3490 0 : ndr->depth++;
3491 0 : ndr_print_ptr(ndr, "client_name", r->in.client_name);
3492 0 : ndr->depth++;
3493 0 : ndr_print_string(ndr, "client_name", r->in.client_name);
3494 0 : ndr->depth--;
3495 0 : ndr_print_hyper(ndr, "client_pid", r->in.client_pid);
3496 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
3497 0 : ndr_print_ptr(ndr, "user", r->in.user);
3498 0 : ndr->depth++;
3499 0 : ndr_print_string(ndr, "user", r->in.user);
3500 0 : ndr->depth--;
3501 0 : ndr_print_ptr(ndr, "domain", r->in.domain);
3502 0 : ndr->depth++;
3503 0 : ndr_print_string(ndr, "domain", r->in.domain);
3504 0 : ndr->depth--;
3505 0 : ndr_print_ptr(ndr, "workstation", r->in.workstation);
3506 0 : ndr->depth++;
3507 0 : ndr_print_string(ndr, "workstation", r->in.workstation);
3508 0 : ndr->depth--;
3509 : {
3510 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3511 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3512 0 : ndr_print_DATA_BLOB(ndr, "lm_resp", r->in.lm_resp);
3513 0 : ndr->flags = _flags_save_DATA_BLOB;
3514 : }
3515 : {
3516 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3517 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3518 0 : ndr_print_DATA_BLOB(ndr, "nt_resp", r->in.nt_resp);
3519 0 : ndr->flags = _flags_save_DATA_BLOB;
3520 : }
3521 : {
3522 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3523 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3524 0 : ndr_print_DATA_BLOB(ndr, "chal", r->in.chal);
3525 0 : ndr->flags = _flags_save_DATA_BLOB;
3526 : }
3527 0 : ndr_print_uint32(ndr, "logon_parameters", r->in.logon_parameters);
3528 0 : ndr_print_ptr(ndr, "require_membership_of_sid", r->in.require_membership_of_sid);
3529 0 : ndr->depth++;
3530 0 : ndr_print_wbint_SidArray(ndr, "require_membership_of_sid", r->in.require_membership_of_sid);
3531 0 : ndr->depth--;
3532 0 : ndr->depth--;
3533 : }
3534 0 : if (flags & NDR_OUT) {
3535 0 : ndr_print_struct(ndr, "out", "wbint_PamAuthCrap");
3536 0 : ndr->depth++;
3537 0 : ndr_print_ptr(ndr, "authoritative", r->out.authoritative);
3538 0 : ndr->depth++;
3539 0 : ndr_print_uint8(ndr, "authoritative", *r->out.authoritative);
3540 0 : ndr->depth--;
3541 0 : ndr_print_ptr(ndr, "validation", r->out.validation);
3542 0 : ndr->depth++;
3543 0 : ndr_print_wbint_PamAuthCrapValidation(ndr, "validation", r->out.validation);
3544 0 : ndr->depth--;
3545 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
3546 0 : ndr->depth--;
3547 : }
3548 0 : ndr->depth--;
3549 : }
3550 :
3551 4 : static enum ndr_err_code ndr_push_wbint_PamLogOff(struct ndr_push *ndr, int flags, const struct wbint_PamLogOff *r)
3552 : {
3553 4 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
3554 4 : if (flags & NDR_IN) {
3555 4 : if (r->in.client_name == NULL) {
3556 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3557 : }
3558 4 : if (r->in.user == NULL) {
3559 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3560 : }
3561 4 : if (r->in.krb5ccname == NULL) {
3562 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3563 : }
3564 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3565 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3566 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3567 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client_name, ndr_charset_length(r->in.client_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3568 4 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.client_pid));
3569 4 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3570 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3571 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3572 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3573 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3574 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.krb5ccname, CH_UTF8)));
3575 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3576 4 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.krb5ccname, CH_UTF8)));
3577 4 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.krb5ccname, ndr_charset_length(r->in.krb5ccname, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3578 4 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.uid));
3579 : }
3580 4 : if (flags & NDR_OUT) {
3581 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
3582 : }
3583 4 : return NDR_ERR_SUCCESS;
3584 : }
3585 :
3586 4 : static enum ndr_err_code ndr_pull_wbint_PamLogOff(struct ndr_pull *ndr, int flags, struct wbint_PamLogOff *r)
3587 : {
3588 4 : uint32_t size_client_name_1 = 0;
3589 4 : uint32_t length_client_name_1 = 0;
3590 4 : uint32_t size_user_1 = 0;
3591 4 : uint32_t length_user_1 = 0;
3592 4 : uint32_t size_krb5ccname_1 = 0;
3593 4 : uint32_t length_krb5ccname_1 = 0;
3594 4 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
3595 4 : if (flags & NDR_IN) {
3596 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client_name));
3597 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client_name));
3598 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client_name, &size_client_name_1));
3599 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client_name, &length_client_name_1));
3600 0 : if (length_client_name_1 > size_client_name_1) {
3601 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_client_name_1, length_client_name_1);
3602 : }
3603 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_name_1, sizeof(uint8_t)));
3604 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client_name, length_client_name_1, sizeof(uint8_t), CH_UTF8));
3605 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.client_pid));
3606 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3607 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
3608 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
3609 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
3610 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
3611 0 : if (length_user_1 > size_user_1) {
3612 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_user_1, length_user_1);
3613 : }
3614 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint8_t)));
3615 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint8_t), CH_UTF8));
3616 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.krb5ccname));
3617 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.krb5ccname));
3618 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.krb5ccname, &size_krb5ccname_1));
3619 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.krb5ccname, &length_krb5ccname_1));
3620 0 : if (length_krb5ccname_1 > size_krb5ccname_1) {
3621 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_krb5ccname_1, length_krb5ccname_1);
3622 : }
3623 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_krb5ccname_1, sizeof(uint8_t)));
3624 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.krb5ccname, length_krb5ccname_1, sizeof(uint8_t), CH_UTF8));
3625 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.uid));
3626 : }
3627 4 : if (flags & NDR_OUT) {
3628 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
3629 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
3630 4 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
3631 : }
3632 4 : return NDR_ERR_SUCCESS;
3633 : }
3634 :
3635 0 : _PUBLIC_ void ndr_print_wbint_PamLogOff(struct ndr_print *ndr, const char *name, int flags, const struct wbint_PamLogOff *r)
3636 : {
3637 0 : ndr_print_struct(ndr, name, "wbint_PamLogOff");
3638 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3639 0 : ndr->depth++;
3640 0 : if (flags & NDR_SET_VALUES) {
3641 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3642 : }
3643 0 : if (flags & NDR_IN) {
3644 0 : ndr_print_struct(ndr, "in", "wbint_PamLogOff");
3645 0 : ndr->depth++;
3646 0 : ndr_print_ptr(ndr, "client_name", r->in.client_name);
3647 0 : ndr->depth++;
3648 0 : ndr_print_string(ndr, "client_name", r->in.client_name);
3649 0 : ndr->depth--;
3650 0 : ndr_print_hyper(ndr, "client_pid", r->in.client_pid);
3651 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
3652 0 : ndr_print_ptr(ndr, "user", r->in.user);
3653 0 : ndr->depth++;
3654 0 : ndr_print_string(ndr, "user", r->in.user);
3655 0 : ndr->depth--;
3656 0 : ndr_print_ptr(ndr, "krb5ccname", r->in.krb5ccname);
3657 0 : ndr->depth++;
3658 0 : ndr_print_string(ndr, "krb5ccname", r->in.krb5ccname);
3659 0 : ndr->depth--;
3660 0 : ndr_print_hyper(ndr, "uid", r->in.uid);
3661 0 : ndr->depth--;
3662 : }
3663 0 : if (flags & NDR_OUT) {
3664 0 : ndr_print_struct(ndr, "out", "wbint_PamLogOff");
3665 0 : ndr->depth++;
3666 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
3667 0 : ndr->depth--;
3668 : }
3669 0 : ndr->depth--;
3670 : }
3671 :
3672 1 : static enum ndr_err_code ndr_push_wbint_PamAuthCrapChangePassword(struct ndr_push *ndr, int flags, const struct wbint_PamAuthCrapChangePassword *r)
3673 : {
3674 1 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
3675 1 : if (flags & NDR_IN) {
3676 1 : if (r->in.client_name == NULL) {
3677 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3678 : }
3679 1 : if (r->in.user == NULL) {
3680 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3681 : }
3682 1 : if (r->in.domain == NULL) {
3683 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3684 : }
3685 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3686 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3687 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3688 1 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client_name, ndr_charset_length(r->in.client_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3689 1 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.client_pid));
3690 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3691 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3692 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3693 1 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3694 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain, CH_UTF8)));
3695 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3696 1 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.domain, CH_UTF8)));
3697 1 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.domain, ndr_charset_length(r->in.domain, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3698 : {
3699 1 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3700 1 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3701 1 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->in.new_nt_pswd));
3702 1 : ndr->flags = _flags_save_DATA_BLOB;
3703 : }
3704 : {
3705 1 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3706 1 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3707 1 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->in.old_nt_hash_enc));
3708 1 : ndr->flags = _flags_save_DATA_BLOB;
3709 : }
3710 : {
3711 1 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3712 1 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3713 1 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->in.new_lm_pswd));
3714 1 : ndr->flags = _flags_save_DATA_BLOB;
3715 : }
3716 : {
3717 1 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3718 1 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3719 1 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->in.old_lm_hash_enc));
3720 1 : ndr->flags = _flags_save_DATA_BLOB;
3721 : }
3722 : }
3723 1 : if (flags & NDR_OUT) {
3724 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
3725 : }
3726 1 : return NDR_ERR_SUCCESS;
3727 : }
3728 :
3729 1 : static enum ndr_err_code ndr_pull_wbint_PamAuthCrapChangePassword(struct ndr_pull *ndr, int flags, struct wbint_PamAuthCrapChangePassword *r)
3730 : {
3731 1 : uint32_t size_client_name_1 = 0;
3732 1 : uint32_t length_client_name_1 = 0;
3733 1 : uint32_t size_user_1 = 0;
3734 1 : uint32_t length_user_1 = 0;
3735 1 : uint32_t size_domain_1 = 0;
3736 1 : uint32_t length_domain_1 = 0;
3737 1 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
3738 1 : if (flags & NDR_IN) {
3739 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client_name));
3740 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client_name));
3741 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client_name, &size_client_name_1));
3742 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client_name, &length_client_name_1));
3743 0 : if (length_client_name_1 > size_client_name_1) {
3744 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_client_name_1, length_client_name_1);
3745 : }
3746 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_name_1, sizeof(uint8_t)));
3747 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client_name, length_client_name_1, sizeof(uint8_t), CH_UTF8));
3748 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.client_pid));
3749 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
3750 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
3751 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
3752 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
3753 0 : if (length_user_1 > size_user_1) {
3754 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_user_1, length_user_1);
3755 : }
3756 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint8_t)));
3757 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint8_t), CH_UTF8));
3758 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.domain));
3759 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.domain));
3760 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.domain, &size_domain_1));
3761 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.domain, &length_domain_1));
3762 0 : if (length_domain_1 > size_domain_1) {
3763 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_domain_1, length_domain_1);
3764 : }
3765 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_domain_1, sizeof(uint8_t)));
3766 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.domain, length_domain_1, sizeof(uint8_t), CH_UTF8));
3767 : {
3768 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3769 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3770 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->in.new_nt_pswd));
3771 0 : ndr->flags = _flags_save_DATA_BLOB;
3772 : }
3773 : {
3774 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3775 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3776 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->in.old_nt_hash_enc));
3777 0 : ndr->flags = _flags_save_DATA_BLOB;
3778 : }
3779 : {
3780 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3781 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3782 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->in.new_lm_pswd));
3783 0 : ndr->flags = _flags_save_DATA_BLOB;
3784 : }
3785 : {
3786 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3787 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3788 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->in.old_lm_hash_enc));
3789 0 : ndr->flags = _flags_save_DATA_BLOB;
3790 : }
3791 : }
3792 1 : if (flags & NDR_OUT) {
3793 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
3794 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
3795 1 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
3796 : }
3797 1 : return NDR_ERR_SUCCESS;
3798 : }
3799 :
3800 0 : _PUBLIC_ void ndr_print_wbint_PamAuthCrapChangePassword(struct ndr_print *ndr, const char *name, int flags, const struct wbint_PamAuthCrapChangePassword *r)
3801 : {
3802 0 : ndr_print_struct(ndr, name, "wbint_PamAuthCrapChangePassword");
3803 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3804 0 : ndr->depth++;
3805 0 : if (flags & NDR_SET_VALUES) {
3806 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
3807 : }
3808 0 : if (flags & NDR_IN) {
3809 0 : ndr_print_struct(ndr, "in", "wbint_PamAuthCrapChangePassword");
3810 0 : ndr->depth++;
3811 0 : ndr_print_ptr(ndr, "client_name", r->in.client_name);
3812 0 : ndr->depth++;
3813 0 : ndr_print_string(ndr, "client_name", r->in.client_name);
3814 0 : ndr->depth--;
3815 0 : ndr_print_hyper(ndr, "client_pid", r->in.client_pid);
3816 0 : ndr_print_ptr(ndr, "user", r->in.user);
3817 0 : ndr->depth++;
3818 0 : ndr_print_string(ndr, "user", r->in.user);
3819 0 : ndr->depth--;
3820 0 : ndr_print_ptr(ndr, "domain", r->in.domain);
3821 0 : ndr->depth++;
3822 0 : ndr_print_string(ndr, "domain", r->in.domain);
3823 0 : ndr->depth--;
3824 : {
3825 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3826 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3827 0 : ndr_print_DATA_BLOB(ndr, "new_nt_pswd", r->in.new_nt_pswd);
3828 0 : ndr->flags = _flags_save_DATA_BLOB;
3829 : }
3830 : {
3831 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3832 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3833 0 : ndr_print_DATA_BLOB(ndr, "old_nt_hash_enc", r->in.old_nt_hash_enc);
3834 0 : ndr->flags = _flags_save_DATA_BLOB;
3835 : }
3836 : {
3837 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3838 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3839 0 : ndr_print_DATA_BLOB(ndr, "new_lm_pswd", r->in.new_lm_pswd);
3840 0 : ndr->flags = _flags_save_DATA_BLOB;
3841 : }
3842 : {
3843 0 : uint32_t _flags_save_DATA_BLOB = ndr->flags;
3844 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3845 0 : ndr_print_DATA_BLOB(ndr, "old_lm_hash_enc", r->in.old_lm_hash_enc);
3846 0 : ndr->flags = _flags_save_DATA_BLOB;
3847 : }
3848 0 : ndr->depth--;
3849 : }
3850 0 : if (flags & NDR_OUT) {
3851 0 : ndr_print_struct(ndr, "out", "wbint_PamAuthCrapChangePassword");
3852 0 : ndr->depth++;
3853 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
3854 0 : ndr->depth--;
3855 : }
3856 0 : ndr->depth--;
3857 : }
3858 :
3859 13 : static enum ndr_err_code ndr_push_wbint_PamAuthChangePassword(struct ndr_push *ndr, int flags, const struct wbint_PamAuthChangePassword *r)
3860 : {
3861 13 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
3862 13 : if (flags & NDR_IN) {
3863 13 : if (r->in.client_name == NULL) {
3864 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3865 : }
3866 13 : if (r->in.user == NULL) {
3867 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3868 : }
3869 13 : if (r->in.old_password == NULL) {
3870 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3871 : }
3872 13 : if (r->in.new_password == NULL) {
3873 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3874 : }
3875 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3876 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3877 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.client_name, CH_UTF8)));
3878 13 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.client_name, ndr_charset_length(r->in.client_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3879 13 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->in.client_pid));
3880 13 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
3881 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3882 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3883 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.user, CH_UTF8)));
3884 13 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.user, ndr_charset_length(r->in.user, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3885 : {
3886 13 : uint32_t _flags_save_uint8 = ndr->flags;
3887 13 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3888 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.old_password, CH_UTF8)));
3889 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3890 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.old_password, CH_UTF8)));
3891 13 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.old_password, ndr_charset_length(r->in.old_password, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3892 13 : ndr->flags = _flags_save_uint8;
3893 : }
3894 : {
3895 13 : uint32_t _flags_save_uint8 = ndr->flags;
3896 13 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3897 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.new_password, CH_UTF8)));
3898 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
3899 13 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.new_password, CH_UTF8)));
3900 13 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.new_password, ndr_charset_length(r->in.new_password, CH_UTF8), sizeof(uint8_t), CH_UTF8));
3901 13 : ndr->flags = _flags_save_uint8;
3902 : }
3903 : }
3904 13 : if (flags & NDR_OUT) {
3905 0 : if (r->out.dominfo == NULL) {
3906 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3907 : }
3908 0 : if (r->out.reject_reason == NULL) {
3909 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
3910 : }
3911 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.dominfo));
3912 0 : if (*r->out.dominfo) {
3913 0 : NDR_CHECK(ndr_push_samr_DomInfo1(ndr, NDR_SCALARS, *r->out.dominfo));
3914 : }
3915 0 : NDR_CHECK(ndr_push_samPwdChangeReason(ndr, NDR_SCALARS, *r->out.reject_reason));
3916 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
3917 : }
3918 13 : return NDR_ERR_SUCCESS;
3919 : }
3920 :
3921 13 : static enum ndr_err_code ndr_pull_wbint_PamAuthChangePassword(struct ndr_pull *ndr, int flags, struct wbint_PamAuthChangePassword *r)
3922 : {
3923 13 : uint32_t size_client_name_1 = 0;
3924 13 : uint32_t length_client_name_1 = 0;
3925 13 : uint32_t size_user_1 = 0;
3926 13 : uint32_t length_user_1 = 0;
3927 13 : uint32_t size_old_password_1 = 0;
3928 13 : uint32_t length_old_password_1 = 0;
3929 13 : uint32_t size_new_password_1 = 0;
3930 13 : uint32_t length_new_password_1 = 0;
3931 : uint32_t _ptr_dominfo;
3932 13 : TALLOC_CTX *_mem_save_dominfo_0 = NULL;
3933 13 : TALLOC_CTX *_mem_save_dominfo_1 = NULL;
3934 13 : TALLOC_CTX *_mem_save_reject_reason_0 = NULL;
3935 13 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
3936 13 : if (flags & NDR_IN) {
3937 0 : NDR_ZERO_STRUCT(r->out);
3938 :
3939 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.client_name));
3940 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.client_name));
3941 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.client_name, &size_client_name_1));
3942 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.client_name, &length_client_name_1));
3943 0 : if (length_client_name_1 > size_client_name_1) {
3944 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_client_name_1, length_client_name_1);
3945 : }
3946 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_client_name_1, sizeof(uint8_t)));
3947 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.client_name, length_client_name_1, sizeof(uint8_t), CH_UTF8));
3948 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->in.client_pid));
3949 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
3950 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.user));
3951 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.user));
3952 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.user, &size_user_1));
3953 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.user, &length_user_1));
3954 0 : if (length_user_1 > size_user_1) {
3955 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_user_1, length_user_1);
3956 : }
3957 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_user_1, sizeof(uint8_t)));
3958 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.user, length_user_1, sizeof(uint8_t), CH_UTF8));
3959 : {
3960 0 : uint32_t _flags_save_uint8 = ndr->flags;
3961 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3962 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.old_password));
3963 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.old_password));
3964 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.old_password, &size_old_password_1));
3965 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.old_password, &length_old_password_1));
3966 0 : if (length_old_password_1 > size_old_password_1) {
3967 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_old_password_1, length_old_password_1);
3968 : }
3969 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_old_password_1, sizeof(uint8_t)));
3970 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.old_password, length_old_password_1, sizeof(uint8_t), CH_UTF8));
3971 0 : ndr->flags = _flags_save_uint8;
3972 : }
3973 : {
3974 0 : uint32_t _flags_save_uint8 = ndr->flags;
3975 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
3976 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.new_password));
3977 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.new_password));
3978 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.new_password, &size_new_password_1));
3979 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.new_password, &length_new_password_1));
3980 0 : if (length_new_password_1 > size_new_password_1) {
3981 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_new_password_1, length_new_password_1);
3982 : }
3983 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_new_password_1, sizeof(uint8_t)));
3984 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.new_password, length_new_password_1, sizeof(uint8_t), CH_UTF8));
3985 0 : ndr->flags = _flags_save_uint8;
3986 : }
3987 0 : NDR_PULL_ALLOC(ndr, r->out.dominfo);
3988 0 : NDR_ZERO_STRUCTP(r->out.dominfo);
3989 0 : NDR_PULL_ALLOC(ndr, r->out.reject_reason);
3990 0 : NDR_ZERO_STRUCTP(r->out.reject_reason);
3991 : }
3992 13 : if (flags & NDR_OUT) {
3993 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
3994 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
3995 13 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
3996 13 : NDR_PULL_ALLOC(ndr, r->out.dominfo);
3997 : }
3998 13 : _mem_save_dominfo_0 = NDR_PULL_GET_MEM_CTX(ndr);
3999 13 : NDR_PULL_SET_MEM_CTX(ndr, r->out.dominfo, LIBNDR_FLAG_REF_ALLOC);
4000 13 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_dominfo));
4001 13 : if (_ptr_dominfo) {
4002 0 : NDR_PULL_ALLOC(ndr, *r->out.dominfo);
4003 : } else {
4004 13 : *r->out.dominfo = NULL;
4005 : }
4006 13 : if (*r->out.dominfo) {
4007 0 : _mem_save_dominfo_1 = NDR_PULL_GET_MEM_CTX(ndr);
4008 0 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.dominfo, 0);
4009 0 : NDR_CHECK(ndr_pull_samr_DomInfo1(ndr, NDR_SCALARS, *r->out.dominfo));
4010 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dominfo_1, 0);
4011 : }
4012 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dominfo_0, LIBNDR_FLAG_REF_ALLOC);
4013 13 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4014 13 : NDR_PULL_ALLOC(ndr, r->out.reject_reason);
4015 : }
4016 13 : _mem_save_reject_reason_0 = NDR_PULL_GET_MEM_CTX(ndr);
4017 13 : NDR_PULL_SET_MEM_CTX(ndr, r->out.reject_reason, LIBNDR_FLAG_REF_ALLOC);
4018 13 : NDR_CHECK(ndr_pull_samPwdChangeReason(ndr, NDR_SCALARS, r->out.reject_reason));
4019 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_reject_reason_0, LIBNDR_FLAG_REF_ALLOC);
4020 13 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
4021 : }
4022 13 : return NDR_ERR_SUCCESS;
4023 : }
4024 :
4025 0 : _PUBLIC_ void ndr_print_wbint_PamAuthChangePassword(struct ndr_print *ndr, const char *name, int flags, const struct wbint_PamAuthChangePassword *r)
4026 : {
4027 0 : ndr_print_struct(ndr, name, "wbint_PamAuthChangePassword");
4028 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4029 0 : ndr->depth++;
4030 0 : if (flags & NDR_SET_VALUES) {
4031 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4032 : }
4033 0 : if (flags & NDR_IN) {
4034 0 : ndr_print_struct(ndr, "in", "wbint_PamAuthChangePassword");
4035 0 : ndr->depth++;
4036 0 : ndr_print_ptr(ndr, "client_name", r->in.client_name);
4037 0 : ndr->depth++;
4038 0 : ndr_print_string(ndr, "client_name", r->in.client_name);
4039 0 : ndr->depth--;
4040 0 : ndr_print_hyper(ndr, "client_pid", r->in.client_pid);
4041 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
4042 0 : ndr_print_ptr(ndr, "user", r->in.user);
4043 0 : ndr->depth++;
4044 0 : ndr_print_string(ndr, "user", r->in.user);
4045 0 : ndr->depth--;
4046 : {
4047 0 : uint32_t _flags_save_uint8 = ndr->flags;
4048 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
4049 0 : ndr_print_ptr(ndr, "old_password", r->in.old_password);
4050 0 : ndr->depth++;
4051 0 : ndr_print_string(ndr, "old_password", r->in.old_password);
4052 0 : ndr->depth--;
4053 0 : ndr->flags = _flags_save_uint8;
4054 : }
4055 : {
4056 0 : uint32_t _flags_save_uint8 = ndr->flags;
4057 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_IS_SECRET);
4058 0 : ndr_print_ptr(ndr, "new_password", r->in.new_password);
4059 0 : ndr->depth++;
4060 0 : ndr_print_string(ndr, "new_password", r->in.new_password);
4061 0 : ndr->depth--;
4062 0 : ndr->flags = _flags_save_uint8;
4063 : }
4064 0 : ndr->depth--;
4065 : }
4066 0 : if (flags & NDR_OUT) {
4067 0 : ndr_print_struct(ndr, "out", "wbint_PamAuthChangePassword");
4068 0 : ndr->depth++;
4069 0 : ndr_print_ptr(ndr, "dominfo", r->out.dominfo);
4070 0 : ndr->depth++;
4071 0 : ndr_print_ptr(ndr, "dominfo", *r->out.dominfo);
4072 0 : ndr->depth++;
4073 0 : if (*r->out.dominfo) {
4074 0 : ndr_print_samr_DomInfo1(ndr, "dominfo", *r->out.dominfo);
4075 : }
4076 0 : ndr->depth--;
4077 0 : ndr->depth--;
4078 0 : ndr_print_ptr(ndr, "reject_reason", r->out.reject_reason);
4079 0 : ndr->depth++;
4080 0 : ndr_print_samPwdChangeReason(ndr, "reject_reason", *r->out.reject_reason);
4081 0 : ndr->depth--;
4082 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
4083 0 : ndr->depth--;
4084 : }
4085 0 : ndr->depth--;
4086 : }
4087 :
4088 156 : static enum ndr_err_code ndr_push_wbint_InitConnection(struct ndr_push *ndr, int flags, const struct wbint_InitConnection *r)
4089 : {
4090 156 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
4091 156 : if (flags & NDR_IN) {
4092 156 : if (r->in.dcname == NULL) {
4093 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4094 : }
4095 156 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.dcname, CH_UTF8)));
4096 156 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4097 156 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.dcname, CH_UTF8)));
4098 156 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.dcname, ndr_charset_length(r->in.dcname, CH_UTF8), sizeof(uint8_t), CH_UTF8));
4099 : }
4100 156 : if (flags & NDR_OUT) {
4101 0 : if (r->out.name == NULL) {
4102 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4103 : }
4104 0 : if (r->out.alt_name == NULL) {
4105 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4106 : }
4107 0 : if (r->out.sid == NULL) {
4108 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4109 : }
4110 0 : if (r->out.flags == NULL) {
4111 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4112 : }
4113 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.name));
4114 0 : if (*r->out.name) {
4115 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.name, CH_UTF8)));
4116 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4117 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.name, CH_UTF8)));
4118 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.name, ndr_charset_length(*r->out.name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
4119 : }
4120 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.alt_name));
4121 0 : if (*r->out.alt_name) {
4122 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.alt_name, CH_UTF8)));
4123 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4124 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(*r->out.alt_name, CH_UTF8)));
4125 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, *r->out.alt_name, ndr_charset_length(*r->out.alt_name, CH_UTF8), sizeof(uint8_t), CH_UTF8));
4126 : }
4127 0 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->out.sid));
4128 0 : NDR_CHECK(ndr_push_DomainInfoFlags(ndr, NDR_SCALARS, *r->out.flags));
4129 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
4130 : }
4131 156 : return NDR_ERR_SUCCESS;
4132 : }
4133 :
4134 146 : static enum ndr_err_code ndr_pull_wbint_InitConnection(struct ndr_pull *ndr, int flags, struct wbint_InitConnection *r)
4135 : {
4136 146 : uint32_t size_dcname_1 = 0;
4137 146 : uint32_t length_dcname_1 = 0;
4138 : uint32_t _ptr_name;
4139 146 : uint32_t size_name_2 = 0;
4140 146 : uint32_t length_name_2 = 0;
4141 : uint32_t _ptr_alt_name;
4142 146 : uint32_t size_alt_name_2 = 0;
4143 146 : uint32_t length_alt_name_2 = 0;
4144 146 : TALLOC_CTX *_mem_save_name_0 = NULL;
4145 146 : TALLOC_CTX *_mem_save_name_1 = NULL;
4146 146 : TALLOC_CTX *_mem_save_alt_name_0 = NULL;
4147 146 : TALLOC_CTX *_mem_save_alt_name_1 = NULL;
4148 146 : TALLOC_CTX *_mem_save_sid_0 = NULL;
4149 146 : TALLOC_CTX *_mem_save_flags_0 = NULL;
4150 146 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
4151 146 : if (flags & NDR_IN) {
4152 0 : NDR_ZERO_STRUCT(r->out);
4153 :
4154 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.dcname));
4155 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.dcname));
4156 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.dcname, &size_dcname_1));
4157 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.dcname, &length_dcname_1));
4158 0 : if (length_dcname_1 > size_dcname_1) {
4159 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_dcname_1, length_dcname_1);
4160 : }
4161 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_dcname_1, sizeof(uint8_t)));
4162 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.dcname, length_dcname_1, sizeof(uint8_t), CH_UTF8));
4163 0 : NDR_PULL_ALLOC(ndr, r->out.name);
4164 0 : NDR_ZERO_STRUCTP(r->out.name);
4165 0 : NDR_PULL_ALLOC(ndr, r->out.alt_name);
4166 0 : NDR_ZERO_STRUCTP(r->out.alt_name);
4167 0 : NDR_PULL_ALLOC(ndr, r->out.sid);
4168 0 : NDR_ZERO_STRUCTP(r->out.sid);
4169 0 : NDR_PULL_ALLOC(ndr, r->out.flags);
4170 0 : NDR_ZERO_STRUCTP(r->out.flags);
4171 : }
4172 146 : if (flags & NDR_OUT) {
4173 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
4174 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
4175 146 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4176 146 : NDR_PULL_ALLOC(ndr, r->out.name);
4177 : }
4178 146 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4179 146 : NDR_PULL_SET_MEM_CTX(ndr, r->out.name, LIBNDR_FLAG_REF_ALLOC);
4180 146 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
4181 146 : if (_ptr_name) {
4182 146 : NDR_PULL_ALLOC(ndr, *r->out.name);
4183 : } else {
4184 0 : *r->out.name = NULL;
4185 : }
4186 146 : if (*r->out.name) {
4187 146 : _mem_save_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
4188 146 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.name, 0);
4189 146 : NDR_CHECK(ndr_pull_array_size(ndr, r->out.name));
4190 146 : NDR_CHECK(ndr_pull_array_length(ndr, r->out.name));
4191 146 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)r->out.name, &size_name_2));
4192 146 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)r->out.name, &length_name_2));
4193 146 : if (length_name_2 > size_name_2) {
4194 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_name_2, length_name_2);
4195 : }
4196 146 : NDR_CHECK(ndr_check_string_terminator(ndr, length_name_2, sizeof(uint8_t)));
4197 146 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.name, length_name_2, sizeof(uint8_t), CH_UTF8));
4198 146 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_1, 0);
4199 : }
4200 146 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
4201 146 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4202 146 : NDR_PULL_ALLOC(ndr, r->out.alt_name);
4203 : }
4204 146 : _mem_save_alt_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4205 146 : NDR_PULL_SET_MEM_CTX(ndr, r->out.alt_name, LIBNDR_FLAG_REF_ALLOC);
4206 146 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_alt_name));
4207 146 : if (_ptr_alt_name) {
4208 105 : NDR_PULL_ALLOC(ndr, *r->out.alt_name);
4209 : } else {
4210 41 : *r->out.alt_name = NULL;
4211 : }
4212 146 : if (*r->out.alt_name) {
4213 105 : _mem_save_alt_name_1 = NDR_PULL_GET_MEM_CTX(ndr);
4214 105 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.alt_name, 0);
4215 105 : NDR_CHECK(ndr_pull_array_size(ndr, r->out.alt_name));
4216 105 : NDR_CHECK(ndr_pull_array_length(ndr, r->out.alt_name));
4217 105 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)r->out.alt_name, &size_alt_name_2));
4218 105 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)r->out.alt_name, &length_alt_name_2));
4219 105 : if (length_alt_name_2 > size_alt_name_2) {
4220 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_alt_name_2, length_alt_name_2);
4221 : }
4222 105 : NDR_CHECK(ndr_check_string_terminator(ndr, length_alt_name_2, sizeof(uint8_t)));
4223 105 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, r->out.alt_name, length_alt_name_2, sizeof(uint8_t), CH_UTF8));
4224 105 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alt_name_1, 0);
4225 : }
4226 146 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alt_name_0, LIBNDR_FLAG_REF_ALLOC);
4227 146 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4228 146 : NDR_PULL_ALLOC(ndr, r->out.sid);
4229 : }
4230 146 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
4231 146 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sid, LIBNDR_FLAG_REF_ALLOC);
4232 146 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->out.sid));
4233 146 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
4234 146 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4235 146 : NDR_PULL_ALLOC(ndr, r->out.flags);
4236 : }
4237 146 : _mem_save_flags_0 = NDR_PULL_GET_MEM_CTX(ndr);
4238 146 : NDR_PULL_SET_MEM_CTX(ndr, r->out.flags, LIBNDR_FLAG_REF_ALLOC);
4239 146 : NDR_CHECK(ndr_pull_DomainInfoFlags(ndr, NDR_SCALARS, r->out.flags));
4240 146 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_flags_0, LIBNDR_FLAG_REF_ALLOC);
4241 146 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
4242 : }
4243 146 : return NDR_ERR_SUCCESS;
4244 : }
4245 :
4246 0 : _PUBLIC_ void ndr_print_wbint_InitConnection(struct ndr_print *ndr, const char *name, int flags, const struct wbint_InitConnection *r)
4247 : {
4248 0 : ndr_print_struct(ndr, name, "wbint_InitConnection");
4249 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4250 0 : ndr->depth++;
4251 0 : if (flags & NDR_SET_VALUES) {
4252 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4253 : }
4254 0 : if (flags & NDR_IN) {
4255 0 : ndr_print_struct(ndr, "in", "wbint_InitConnection");
4256 0 : ndr->depth++;
4257 0 : ndr_print_ptr(ndr, "dcname", r->in.dcname);
4258 0 : ndr->depth++;
4259 0 : ndr_print_string(ndr, "dcname", r->in.dcname);
4260 0 : ndr->depth--;
4261 0 : ndr->depth--;
4262 : }
4263 0 : if (flags & NDR_OUT) {
4264 0 : ndr_print_struct(ndr, "out", "wbint_InitConnection");
4265 0 : ndr->depth++;
4266 0 : ndr_print_ptr(ndr, "name", r->out.name);
4267 0 : ndr->depth++;
4268 0 : ndr_print_ptr(ndr, "name", *r->out.name);
4269 0 : ndr->depth++;
4270 0 : if (*r->out.name) {
4271 0 : ndr_print_string(ndr, "name", *r->out.name);
4272 : }
4273 0 : ndr->depth--;
4274 0 : ndr->depth--;
4275 0 : ndr_print_ptr(ndr, "alt_name", r->out.alt_name);
4276 0 : ndr->depth++;
4277 0 : ndr_print_ptr(ndr, "alt_name", *r->out.alt_name);
4278 0 : ndr->depth++;
4279 0 : if (*r->out.alt_name) {
4280 0 : ndr_print_string(ndr, "alt_name", *r->out.alt_name);
4281 : }
4282 0 : ndr->depth--;
4283 0 : ndr->depth--;
4284 0 : ndr_print_ptr(ndr, "sid", r->out.sid);
4285 0 : ndr->depth++;
4286 0 : ndr_print_dom_sid(ndr, "sid", r->out.sid);
4287 0 : ndr->depth--;
4288 0 : ndr_print_ptr(ndr, "flags", r->out.flags);
4289 0 : ndr->depth++;
4290 0 : ndr_print_DomainInfoFlags(ndr, "flags", *r->out.flags);
4291 0 : ndr->depth--;
4292 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
4293 0 : ndr->depth--;
4294 : }
4295 0 : ndr->depth--;
4296 : }
4297 :
4298 1163 : static enum ndr_err_code ndr_push_winbind_SamLogon(struct ndr_push *ndr, int flags, const struct winbind_SamLogon *r)
4299 : {
4300 1163 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
4301 1163 : if (flags & NDR_IN) {
4302 780 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.logon_level));
4303 780 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->in.logon, r->in.logon_level));
4304 780 : NDR_CHECK(ndr_push_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon));
4305 780 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.validation_level));
4306 : }
4307 1163 : if (flags & NDR_OUT) {
4308 383 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->out.validation, r->in.validation_level));
4309 383 : NDR_CHECK(ndr_push_netr_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, &r->out.validation));
4310 383 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->out.authoritative));
4311 383 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
4312 : }
4313 1163 : return NDR_ERR_SUCCESS;
4314 : }
4315 :
4316 1161 : static enum ndr_err_code ndr_pull_winbind_SamLogon(struct ndr_pull *ndr, int flags, struct winbind_SamLogon *r)
4317 : {
4318 1161 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
4319 1161 : if (flags & NDR_IN) {
4320 383 : NDR_ZERO_STRUCT(r->out);
4321 :
4322 383 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.logon_level));
4323 383 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->in.logon, r->in.logon_level));
4324 383 : NDR_CHECK(ndr_pull_netr_LogonLevel(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon));
4325 383 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.validation_level));
4326 : }
4327 1161 : if (flags & NDR_OUT) {
4328 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
4329 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
4330 778 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->out.validation, r->in.validation_level));
4331 778 : NDR_CHECK(ndr_pull_netr_Validation(ndr, NDR_SCALARS|NDR_BUFFERS, &r->out.validation));
4332 778 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->out.authoritative));
4333 778 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
4334 : }
4335 1161 : return NDR_ERR_SUCCESS;
4336 : }
4337 :
4338 0 : _PUBLIC_ void ndr_print_winbind_SamLogon(struct ndr_print *ndr, const char *name, int flags, const struct winbind_SamLogon *r)
4339 : {
4340 0 : ndr_print_struct(ndr, name, "winbind_SamLogon");
4341 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4342 0 : ndr->depth++;
4343 0 : if (flags & NDR_SET_VALUES) {
4344 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4345 : }
4346 0 : if (flags & NDR_IN) {
4347 0 : ndr_print_struct(ndr, "in", "winbind_SamLogon");
4348 0 : ndr->depth++;
4349 0 : ndr_print_uint16(ndr, "logon_level", r->in.logon_level);
4350 0 : ndr_print_set_switch_value(ndr, &r->in.logon, r->in.logon_level);
4351 0 : ndr_print_netr_LogonLevel(ndr, "logon", &r->in.logon);
4352 0 : ndr_print_uint16(ndr, "validation_level", r->in.validation_level);
4353 0 : ndr->depth--;
4354 : }
4355 0 : if (flags & NDR_OUT) {
4356 0 : ndr_print_struct(ndr, "out", "winbind_SamLogon");
4357 0 : ndr->depth++;
4358 0 : ndr_print_set_switch_value(ndr, &r->out.validation, r->in.validation_level);
4359 0 : ndr_print_netr_Validation(ndr, "validation", &r->out.validation);
4360 0 : ndr_print_uint8(ndr, "authoritative", r->out.authoritative);
4361 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
4362 0 : ndr->depth--;
4363 : }
4364 0 : ndr->depth--;
4365 : }
4366 :
4367 12 : static enum ndr_err_code ndr_push_winbind_DsrUpdateReadOnlyServerDnsRecords(struct ndr_push *ndr, int flags, const struct winbind_DsrUpdateReadOnlyServerDnsRecords *r)
4368 : {
4369 12 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
4370 12 : if (flags & NDR_IN) {
4371 8 : if (r->in.dns_names == NULL) {
4372 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4373 : }
4374 8 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.site_name));
4375 8 : if (r->in.site_name) {
4376 8 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.site_name, CH_UTF16)));
4377 8 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4378 8 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.site_name, CH_UTF16)));
4379 8 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.site_name, ndr_charset_length(r->in.site_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4380 : }
4381 8 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.dns_ttl));
4382 8 : NDR_CHECK(ndr_push_NL_DNS_NAME_INFO_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dns_names));
4383 : }
4384 12 : if (flags & NDR_OUT) {
4385 4 : if (r->out.dns_names == NULL) {
4386 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4387 : }
4388 4 : NDR_CHECK(ndr_push_NL_DNS_NAME_INFO_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.dns_names));
4389 4 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
4390 : }
4391 12 : return NDR_ERR_SUCCESS;
4392 : }
4393 :
4394 12 : static enum ndr_err_code ndr_pull_winbind_DsrUpdateReadOnlyServerDnsRecords(struct ndr_pull *ndr, int flags, struct winbind_DsrUpdateReadOnlyServerDnsRecords *r)
4395 : {
4396 : uint32_t _ptr_site_name;
4397 12 : uint32_t size_site_name_1 = 0;
4398 12 : uint32_t length_site_name_1 = 0;
4399 12 : TALLOC_CTX *_mem_save_site_name_0 = NULL;
4400 12 : TALLOC_CTX *_mem_save_dns_names_0 = NULL;
4401 12 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
4402 12 : if (flags & NDR_IN) {
4403 4 : NDR_ZERO_STRUCT(r->out);
4404 :
4405 4 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_site_name));
4406 4 : if (_ptr_site_name) {
4407 4 : NDR_PULL_ALLOC(ndr, r->in.site_name);
4408 : } else {
4409 0 : r->in.site_name = NULL;
4410 : }
4411 4 : if (r->in.site_name) {
4412 4 : _mem_save_site_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4413 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.site_name, 0);
4414 4 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.site_name));
4415 4 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.site_name));
4416 4 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.site_name, &size_site_name_1));
4417 4 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.site_name, &length_site_name_1));
4418 4 : if (length_site_name_1 > size_site_name_1) {
4419 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_site_name_1, length_site_name_1);
4420 : }
4421 4 : NDR_CHECK(ndr_check_string_terminator(ndr, length_site_name_1, sizeof(uint16_t)));
4422 4 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.site_name, length_site_name_1, sizeof(uint16_t), CH_UTF16));
4423 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_site_name_0, 0);
4424 : }
4425 4 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.dns_ttl));
4426 4 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4427 4 : NDR_PULL_ALLOC(ndr, r->in.dns_names);
4428 : }
4429 4 : _mem_save_dns_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
4430 4 : NDR_PULL_SET_MEM_CTX(ndr, r->in.dns_names, LIBNDR_FLAG_REF_ALLOC);
4431 4 : NDR_CHECK(ndr_pull_NL_DNS_NAME_INFO_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.dns_names));
4432 4 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dns_names_0, LIBNDR_FLAG_REF_ALLOC);
4433 4 : NDR_PULL_ALLOC(ndr, r->out.dns_names);
4434 4 : *r->out.dns_names = *r->in.dns_names;
4435 : }
4436 12 : if (flags & NDR_OUT) {
4437 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
4438 : if (r->in.dns_names == NULL) {
4439 : NDR_PULL_ALLOC(ndr, r->in.dns_names);
4440 : NDR_ZERO_STRUCTP(r->in.dns_names);
4441 : }
4442 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
4443 8 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4444 8 : NDR_PULL_ALLOC(ndr, r->out.dns_names);
4445 : }
4446 8 : _mem_save_dns_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
4447 8 : NDR_PULL_SET_MEM_CTX(ndr, r->out.dns_names, LIBNDR_FLAG_REF_ALLOC);
4448 8 : NDR_CHECK(ndr_pull_NL_DNS_NAME_INFO_ARRAY(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.dns_names));
4449 8 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dns_names_0, LIBNDR_FLAG_REF_ALLOC);
4450 8 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
4451 : }
4452 12 : return NDR_ERR_SUCCESS;
4453 : }
4454 :
4455 0 : _PUBLIC_ void ndr_print_winbind_DsrUpdateReadOnlyServerDnsRecords(struct ndr_print *ndr, const char *name, int flags, const struct winbind_DsrUpdateReadOnlyServerDnsRecords *r)
4456 : {
4457 0 : ndr_print_struct(ndr, name, "winbind_DsrUpdateReadOnlyServerDnsRecords");
4458 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4459 0 : ndr->depth++;
4460 0 : if (flags & NDR_SET_VALUES) {
4461 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4462 : }
4463 0 : if (flags & NDR_IN) {
4464 0 : ndr_print_struct(ndr, "in", "winbind_DsrUpdateReadOnlyServerDnsRecords");
4465 0 : ndr->depth++;
4466 0 : ndr_print_ptr(ndr, "site_name", r->in.site_name);
4467 0 : ndr->depth++;
4468 0 : if (r->in.site_name) {
4469 0 : ndr_print_string(ndr, "site_name", r->in.site_name);
4470 : }
4471 0 : ndr->depth--;
4472 0 : ndr_print_uint32(ndr, "dns_ttl", r->in.dns_ttl);
4473 0 : ndr_print_ptr(ndr, "dns_names", r->in.dns_names);
4474 0 : ndr->depth++;
4475 0 : ndr_print_NL_DNS_NAME_INFO_ARRAY(ndr, "dns_names", r->in.dns_names);
4476 0 : ndr->depth--;
4477 0 : ndr->depth--;
4478 : }
4479 0 : if (flags & NDR_OUT) {
4480 0 : ndr_print_struct(ndr, "out", "winbind_DsrUpdateReadOnlyServerDnsRecords");
4481 0 : ndr->depth++;
4482 0 : ndr_print_ptr(ndr, "dns_names", r->out.dns_names);
4483 0 : ndr->depth++;
4484 0 : ndr_print_NL_DNS_NAME_INFO_ARRAY(ndr, "dns_names", r->out.dns_names);
4485 0 : ndr->depth--;
4486 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
4487 0 : ndr->depth--;
4488 : }
4489 0 : ndr->depth--;
4490 : }
4491 :
4492 270 : static enum ndr_err_code ndr_push_winbind_LogonControl(struct ndr_push *ndr, int flags, const struct winbind_LogonControl *r)
4493 : {
4494 270 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
4495 270 : if (flags & NDR_IN) {
4496 194 : if (r->in.data == NULL) {
4497 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4498 : }
4499 194 : NDR_CHECK(ndr_push_netr_LogonControlCode(ndr, NDR_SCALARS, r->in.function_code));
4500 194 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level));
4501 194 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.data, r->in.function_code));
4502 194 : NDR_CHECK(ndr_push_netr_CONTROL_DATA_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.data));
4503 : }
4504 270 : if (flags & NDR_OUT) {
4505 76 : if (r->out.query == NULL) {
4506 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4507 : }
4508 76 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.query, r->in.level));
4509 76 : NDR_CHECK(ndr_push_netr_CONTROL_QUERY_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.query));
4510 76 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4511 : }
4512 270 : return NDR_ERR_SUCCESS;
4513 : }
4514 :
4515 270 : static enum ndr_err_code ndr_pull_winbind_LogonControl(struct ndr_pull *ndr, int flags, struct winbind_LogonControl *r)
4516 : {
4517 270 : TALLOC_CTX *_mem_save_data_0 = NULL;
4518 270 : TALLOC_CTX *_mem_save_query_0 = NULL;
4519 270 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
4520 270 : if (flags & NDR_IN) {
4521 77 : NDR_ZERO_STRUCT(r->out);
4522 :
4523 77 : NDR_CHECK(ndr_pull_netr_LogonControlCode(ndr, NDR_SCALARS, &r->in.function_code));
4524 77 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level));
4525 77 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4526 77 : NDR_PULL_ALLOC(ndr, r->in.data);
4527 : }
4528 77 : _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
4529 77 : NDR_PULL_SET_MEM_CTX(ndr, r->in.data, LIBNDR_FLAG_REF_ALLOC);
4530 77 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.data, r->in.function_code));
4531 77 : NDR_CHECK(ndr_pull_netr_CONTROL_DATA_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.data));
4532 77 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, LIBNDR_FLAG_REF_ALLOC);
4533 77 : NDR_PULL_ALLOC(ndr, r->out.query);
4534 77 : NDR_ZERO_STRUCTP(r->out.query);
4535 : }
4536 270 : if (flags & NDR_OUT) {
4537 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
4538 : if (r->in.data == NULL) {
4539 : NDR_PULL_ALLOC(ndr, r->in.data);
4540 : NDR_ZERO_STRUCTP(r->in.data);
4541 : }
4542 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
4543 193 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4544 193 : NDR_PULL_ALLOC(ndr, r->out.query);
4545 : }
4546 193 : _mem_save_query_0 = NDR_PULL_GET_MEM_CTX(ndr);
4547 193 : NDR_PULL_SET_MEM_CTX(ndr, r->out.query, LIBNDR_FLAG_REF_ALLOC);
4548 193 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.query, r->in.level));
4549 193 : NDR_CHECK(ndr_pull_netr_CONTROL_QUERY_INFORMATION(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.query));
4550 193 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_query_0, LIBNDR_FLAG_REF_ALLOC);
4551 193 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4552 : }
4553 270 : return NDR_ERR_SUCCESS;
4554 : }
4555 :
4556 0 : _PUBLIC_ void ndr_print_winbind_LogonControl(struct ndr_print *ndr, const char *name, int flags, const struct winbind_LogonControl *r)
4557 : {
4558 0 : ndr_print_struct(ndr, name, "winbind_LogonControl");
4559 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4560 0 : ndr->depth++;
4561 0 : if (flags & NDR_SET_VALUES) {
4562 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4563 : }
4564 0 : if (flags & NDR_IN) {
4565 0 : ndr_print_struct(ndr, "in", "winbind_LogonControl");
4566 0 : ndr->depth++;
4567 0 : ndr_print_netr_LogonControlCode(ndr, "function_code", r->in.function_code);
4568 0 : ndr_print_uint32(ndr, "level", r->in.level);
4569 0 : ndr_print_ptr(ndr, "data", r->in.data);
4570 0 : ndr->depth++;
4571 0 : ndr_print_set_switch_value(ndr, r->in.data, r->in.function_code);
4572 0 : ndr_print_netr_CONTROL_DATA_INFORMATION(ndr, "data", r->in.data);
4573 0 : ndr->depth--;
4574 0 : ndr->depth--;
4575 : }
4576 0 : if (flags & NDR_OUT) {
4577 0 : ndr_print_struct(ndr, "out", "winbind_LogonControl");
4578 0 : ndr->depth++;
4579 0 : ndr_print_ptr(ndr, "query", r->out.query);
4580 0 : ndr->depth++;
4581 0 : ndr_print_set_switch_value(ndr, r->out.query, r->in.level);
4582 0 : ndr_print_netr_CONTROL_QUERY_INFORMATION(ndr, "query", r->out.query);
4583 0 : ndr->depth--;
4584 0 : ndr_print_WERROR(ndr, "result", r->out.result);
4585 0 : ndr->depth--;
4586 : }
4587 0 : ndr->depth--;
4588 : }
4589 :
4590 40 : static enum ndr_err_code ndr_push_winbind_GetForestTrustInformation(struct ndr_push *ndr, int flags, const struct winbind_GetForestTrustInformation *r)
4591 : {
4592 40 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
4593 40 : if (flags & NDR_IN) {
4594 30 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.trusted_domain_name));
4595 30 : if (r->in.trusted_domain_name) {
4596 30 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.trusted_domain_name, CH_UTF16)));
4597 30 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
4598 30 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.trusted_domain_name, CH_UTF16)));
4599 30 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.trusted_domain_name, ndr_charset_length(r->in.trusted_domain_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
4600 : }
4601 30 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
4602 : }
4603 40 : if (flags & NDR_OUT) {
4604 10 : if (r->out.forest_trust_info == NULL) {
4605 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
4606 : }
4607 10 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.forest_trust_info));
4608 10 : if (*r->out.forest_trust_info) {
4609 10 : NDR_CHECK(ndr_push_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.forest_trust_info));
4610 : }
4611 10 : NDR_CHECK(ndr_push_WERROR(ndr, NDR_SCALARS, r->out.result));
4612 : }
4613 40 : return NDR_ERR_SUCCESS;
4614 : }
4615 :
4616 40 : static enum ndr_err_code ndr_pull_winbind_GetForestTrustInformation(struct ndr_pull *ndr, int flags, struct winbind_GetForestTrustInformation *r)
4617 : {
4618 : uint32_t _ptr_trusted_domain_name;
4619 40 : uint32_t size_trusted_domain_name_1 = 0;
4620 40 : uint32_t length_trusted_domain_name_1 = 0;
4621 : uint32_t _ptr_forest_trust_info;
4622 40 : TALLOC_CTX *_mem_save_trusted_domain_name_0 = NULL;
4623 40 : TALLOC_CTX *_mem_save_forest_trust_info_0 = NULL;
4624 40 : TALLOC_CTX *_mem_save_forest_trust_info_1 = NULL;
4625 40 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
4626 40 : if (flags & NDR_IN) {
4627 10 : NDR_ZERO_STRUCT(r->out);
4628 :
4629 10 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_trusted_domain_name));
4630 10 : if (_ptr_trusted_domain_name) {
4631 10 : NDR_PULL_ALLOC(ndr, r->in.trusted_domain_name);
4632 : } else {
4633 0 : r->in.trusted_domain_name = NULL;
4634 : }
4635 10 : if (r->in.trusted_domain_name) {
4636 10 : _mem_save_trusted_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
4637 10 : NDR_PULL_SET_MEM_CTX(ndr, r->in.trusted_domain_name, 0);
4638 10 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.trusted_domain_name));
4639 10 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.trusted_domain_name));
4640 10 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.trusted_domain_name, &size_trusted_domain_name_1));
4641 10 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.trusted_domain_name, &length_trusted_domain_name_1));
4642 10 : if (length_trusted_domain_name_1 > size_trusted_domain_name_1) {
4643 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %u should exceed array length %u", size_trusted_domain_name_1, length_trusted_domain_name_1);
4644 : }
4645 10 : NDR_CHECK(ndr_check_string_terminator(ndr, length_trusted_domain_name_1, sizeof(uint16_t)));
4646 10 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.trusted_domain_name, length_trusted_domain_name_1, sizeof(uint16_t), CH_UTF16));
4647 10 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_trusted_domain_name_0, 0);
4648 : }
4649 10 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
4650 10 : NDR_PULL_ALLOC(ndr, r->out.forest_trust_info);
4651 10 : NDR_ZERO_STRUCTP(r->out.forest_trust_info);
4652 : }
4653 40 : if (flags & NDR_OUT) {
4654 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
4655 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
4656 30 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
4657 30 : NDR_PULL_ALLOC(ndr, r->out.forest_trust_info);
4658 : }
4659 30 : _mem_save_forest_trust_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
4660 30 : NDR_PULL_SET_MEM_CTX(ndr, r->out.forest_trust_info, LIBNDR_FLAG_REF_ALLOC);
4661 30 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_forest_trust_info));
4662 30 : if (_ptr_forest_trust_info) {
4663 30 : NDR_PULL_ALLOC(ndr, *r->out.forest_trust_info);
4664 : } else {
4665 0 : *r->out.forest_trust_info = NULL;
4666 : }
4667 30 : if (*r->out.forest_trust_info) {
4668 30 : _mem_save_forest_trust_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
4669 30 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.forest_trust_info, 0);
4670 30 : NDR_CHECK(ndr_pull_lsa_ForestTrustInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.forest_trust_info));
4671 30 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_trust_info_1, 0);
4672 : }
4673 30 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_forest_trust_info_0, LIBNDR_FLAG_REF_ALLOC);
4674 30 : NDR_CHECK(ndr_pull_WERROR(ndr, NDR_SCALARS, &r->out.result));
4675 : }
4676 40 : return NDR_ERR_SUCCESS;
4677 : }
4678 :
4679 0 : _PUBLIC_ void ndr_print_winbind_GetForestTrustInformation(struct ndr_print *ndr, const char *name, int flags, const struct winbind_GetForestTrustInformation *r)
4680 : {
4681 0 : ndr_print_struct(ndr, name, "winbind_GetForestTrustInformation");
4682 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4683 0 : ndr->depth++;
4684 0 : if (flags & NDR_SET_VALUES) {
4685 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4686 : }
4687 0 : if (flags & NDR_IN) {
4688 0 : ndr_print_struct(ndr, "in", "winbind_GetForestTrustInformation");
4689 0 : ndr->depth++;
4690 0 : ndr_print_ptr(ndr, "trusted_domain_name", r->in.trusted_domain_name);
4691 0 : ndr->depth++;
4692 0 : if (r->in.trusted_domain_name) {
4693 0 : ndr_print_string(ndr, "trusted_domain_name", r->in.trusted_domain_name);
4694 : }
4695 0 : ndr->depth--;
4696 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
4697 0 : ndr->depth--;
4698 : }
4699 0 : if (flags & NDR_OUT) {
4700 0 : ndr_print_struct(ndr, "out", "winbind_GetForestTrustInformation");
4701 0 : ndr->depth++;
4702 0 : ndr_print_ptr(ndr, "forest_trust_info", r->out.forest_trust_info);
4703 0 : ndr->depth++;
4704 0 : ndr_print_ptr(ndr, "forest_trust_info", *r->out.forest_trust_info);
4705 0 : ndr->depth++;
4706 0 : if (*r->out.forest_trust_info) {
4707 0 : ndr_print_lsa_ForestTrustInformation(ndr, "forest_trust_info", *r->out.forest_trust_info);
4708 : }
4709 0 : ndr->depth--;
4710 0 : ndr->depth--;
4711 0 : ndr_print_WERROR(ndr, "result", r->out.result);
4712 0 : ndr->depth--;
4713 : }
4714 0 : ndr->depth--;
4715 : }
4716 :
4717 51 : static enum ndr_err_code ndr_push_winbind_SendToSam(struct ndr_push *ndr, int flags, const struct winbind_SendToSam *r)
4718 : {
4719 51 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
4720 51 : if (flags & NDR_IN) {
4721 34 : NDR_CHECK(ndr_push_netr_SendToSamBase(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.message));
4722 : }
4723 51 : if (flags & NDR_OUT) {
4724 17 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
4725 : }
4726 51 : return NDR_ERR_SUCCESS;
4727 : }
4728 :
4729 34 : static enum ndr_err_code ndr_pull_winbind_SendToSam(struct ndr_pull *ndr, int flags, struct winbind_SendToSam *r)
4730 : {
4731 34 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
4732 34 : if (flags & NDR_IN) {
4733 17 : NDR_CHECK(ndr_pull_netr_SendToSamBase(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.message));
4734 : }
4735 34 : if (flags & NDR_OUT) {
4736 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
4737 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
4738 17 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
4739 : }
4740 34 : return NDR_ERR_SUCCESS;
4741 : }
4742 :
4743 0 : _PUBLIC_ void ndr_print_winbind_SendToSam(struct ndr_print *ndr, const char *name, int flags, const struct winbind_SendToSam *r)
4744 : {
4745 0 : ndr_print_struct(ndr, name, "winbind_SendToSam");
4746 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4747 0 : ndr->depth++;
4748 0 : if (flags & NDR_SET_VALUES) {
4749 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
4750 : }
4751 0 : if (flags & NDR_IN) {
4752 0 : ndr_print_struct(ndr, "in", "winbind_SendToSam");
4753 0 : ndr->depth++;
4754 0 : ndr_print_netr_SendToSamBase(ndr, "message", &r->in.message);
4755 0 : ndr->depth--;
4756 : }
4757 0 : if (flags & NDR_OUT) {
4758 0 : ndr_print_struct(ndr, "out", "winbind_SendToSam");
4759 0 : ndr->depth++;
4760 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
4761 0 : ndr->depth--;
4762 : }
4763 0 : ndr->depth--;
4764 : }
4765 :
4766 : #ifndef SKIP_NDR_TABLE_winbind
4767 : static const struct ndr_interface_public_struct winbind_public_structs[] = {
4768 : {
4769 : .name = "wbint_userinfo",
4770 : .struct_size = sizeof(struct wbint_userinfo ),
4771 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_userinfo,
4772 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_userinfo,
4773 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_userinfo,
4774 : },
4775 : {
4776 : .name = "wbint_SidArray",
4777 : .struct_size = sizeof(struct wbint_SidArray ),
4778 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_SidArray,
4779 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_SidArray,
4780 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_SidArray,
4781 : },
4782 : {
4783 : .name = "wbint_RidArray",
4784 : .struct_size = sizeof(struct wbint_RidArray ),
4785 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_RidArray,
4786 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_RidArray,
4787 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_RidArray,
4788 : },
4789 : {
4790 : .name = "wbint_Principal",
4791 : .struct_size = sizeof(struct wbint_Principal ),
4792 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_Principal,
4793 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_Principal,
4794 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_Principal,
4795 : },
4796 : {
4797 : .name = "wbint_Principals",
4798 : .struct_size = sizeof(struct wbint_Principals ),
4799 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_Principals,
4800 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_Principals,
4801 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_Principals,
4802 : },
4803 : {
4804 : .name = "wbint_userinfos",
4805 : .struct_size = sizeof(struct wbint_userinfos ),
4806 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_userinfos,
4807 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_userinfos,
4808 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_userinfos,
4809 : },
4810 : {
4811 : .name = "wbint_Validation",
4812 : .struct_size = sizeof(struct wbint_Validation ),
4813 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_Validation,
4814 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_Validation,
4815 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_Validation,
4816 : },
4817 : {
4818 : .name = "wbint_AuthUserInfo",
4819 : .struct_size = sizeof(struct wbint_AuthUserInfo ),
4820 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_AuthUserInfo,
4821 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_AuthUserInfo,
4822 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_AuthUserInfo,
4823 : },
4824 : {
4825 : .name = "wbint_PamAuthCrapValidation",
4826 : .struct_size = sizeof(struct wbint_PamAuthCrapValidation ),
4827 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_wbint_PamAuthCrapValidation,
4828 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_wbint_PamAuthCrapValidation,
4829 : .ndr_print = (ndr_print_function_t) ndr_print_flags_wbint_PamAuthCrapValidation,
4830 : },
4831 : { .name = NULL }
4832 : };
4833 :
4834 : static const struct ndr_interface_call winbind_calls[] = {
4835 : {
4836 : "wbint_Ping",
4837 : sizeof(struct wbint_Ping),
4838 : (ndr_push_flags_fn_t) ndr_push_wbint_Ping,
4839 : (ndr_pull_flags_fn_t) ndr_pull_wbint_Ping,
4840 : (ndr_print_function_t) ndr_print_wbint_Ping,
4841 : { 0, NULL },
4842 : { 0, NULL },
4843 : },
4844 : {
4845 : "wbint_LookupSid",
4846 : sizeof(struct wbint_LookupSid),
4847 : (ndr_push_flags_fn_t) ndr_push_wbint_LookupSid,
4848 : (ndr_pull_flags_fn_t) ndr_pull_wbint_LookupSid,
4849 : (ndr_print_function_t) ndr_print_wbint_LookupSid,
4850 : { 0, NULL },
4851 : { 0, NULL },
4852 : },
4853 : {
4854 : "wbint_LookupSids",
4855 : sizeof(struct wbint_LookupSids),
4856 : (ndr_push_flags_fn_t) ndr_push_wbint_LookupSids,
4857 : (ndr_pull_flags_fn_t) ndr_pull_wbint_LookupSids,
4858 : (ndr_print_function_t) ndr_print_wbint_LookupSids,
4859 : { 0, NULL },
4860 : { 0, NULL },
4861 : },
4862 : {
4863 : "wbint_LookupName",
4864 : sizeof(struct wbint_LookupName),
4865 : (ndr_push_flags_fn_t) ndr_push_wbint_LookupName,
4866 : (ndr_pull_flags_fn_t) ndr_pull_wbint_LookupName,
4867 : (ndr_print_function_t) ndr_print_wbint_LookupName,
4868 : { 0, NULL },
4869 : { 0, NULL },
4870 : },
4871 : {
4872 : "wbint_Sids2UnixIDs",
4873 : sizeof(struct wbint_Sids2UnixIDs),
4874 : (ndr_push_flags_fn_t) ndr_push_wbint_Sids2UnixIDs,
4875 : (ndr_pull_flags_fn_t) ndr_pull_wbint_Sids2UnixIDs,
4876 : (ndr_print_function_t) ndr_print_wbint_Sids2UnixIDs,
4877 : { 0, NULL },
4878 : { 0, NULL },
4879 : },
4880 : {
4881 : "wbint_UnixIDs2Sids",
4882 : sizeof(struct wbint_UnixIDs2Sids),
4883 : (ndr_push_flags_fn_t) ndr_push_wbint_UnixIDs2Sids,
4884 : (ndr_pull_flags_fn_t) ndr_pull_wbint_UnixIDs2Sids,
4885 : (ndr_print_function_t) ndr_print_wbint_UnixIDs2Sids,
4886 : { 0, NULL },
4887 : { 0, NULL },
4888 : },
4889 : {
4890 : "wbint_AllocateUid",
4891 : sizeof(struct wbint_AllocateUid),
4892 : (ndr_push_flags_fn_t) ndr_push_wbint_AllocateUid,
4893 : (ndr_pull_flags_fn_t) ndr_pull_wbint_AllocateUid,
4894 : (ndr_print_function_t) ndr_print_wbint_AllocateUid,
4895 : { 0, NULL },
4896 : { 0, NULL },
4897 : },
4898 : {
4899 : "wbint_AllocateGid",
4900 : sizeof(struct wbint_AllocateGid),
4901 : (ndr_push_flags_fn_t) ndr_push_wbint_AllocateGid,
4902 : (ndr_pull_flags_fn_t) ndr_pull_wbint_AllocateGid,
4903 : (ndr_print_function_t) ndr_print_wbint_AllocateGid,
4904 : { 0, NULL },
4905 : { 0, NULL },
4906 : },
4907 : {
4908 : "wbint_GetNssInfo",
4909 : sizeof(struct wbint_GetNssInfo),
4910 : (ndr_push_flags_fn_t) ndr_push_wbint_GetNssInfo,
4911 : (ndr_pull_flags_fn_t) ndr_pull_wbint_GetNssInfo,
4912 : (ndr_print_function_t) ndr_print_wbint_GetNssInfo,
4913 : { 0, NULL },
4914 : { 0, NULL },
4915 : },
4916 : {
4917 : "wbint_LookupUserAliases",
4918 : sizeof(struct wbint_LookupUserAliases),
4919 : (ndr_push_flags_fn_t) ndr_push_wbint_LookupUserAliases,
4920 : (ndr_pull_flags_fn_t) ndr_pull_wbint_LookupUserAliases,
4921 : (ndr_print_function_t) ndr_print_wbint_LookupUserAliases,
4922 : { 0, NULL },
4923 : { 0, NULL },
4924 : },
4925 : {
4926 : "wbint_LookupUserGroups",
4927 : sizeof(struct wbint_LookupUserGroups),
4928 : (ndr_push_flags_fn_t) ndr_push_wbint_LookupUserGroups,
4929 : (ndr_pull_flags_fn_t) ndr_pull_wbint_LookupUserGroups,
4930 : (ndr_print_function_t) ndr_print_wbint_LookupUserGroups,
4931 : { 0, NULL },
4932 : { 0, NULL },
4933 : },
4934 : {
4935 : "wbint_QuerySequenceNumber",
4936 : sizeof(struct wbint_QuerySequenceNumber),
4937 : (ndr_push_flags_fn_t) ndr_push_wbint_QuerySequenceNumber,
4938 : (ndr_pull_flags_fn_t) ndr_pull_wbint_QuerySequenceNumber,
4939 : (ndr_print_function_t) ndr_print_wbint_QuerySequenceNumber,
4940 : { 0, NULL },
4941 : { 0, NULL },
4942 : },
4943 : {
4944 : "wbint_LookupGroupMembers",
4945 : sizeof(struct wbint_LookupGroupMembers),
4946 : (ndr_push_flags_fn_t) ndr_push_wbint_LookupGroupMembers,
4947 : (ndr_pull_flags_fn_t) ndr_pull_wbint_LookupGroupMembers,
4948 : (ndr_print_function_t) ndr_print_wbint_LookupGroupMembers,
4949 : { 0, NULL },
4950 : { 0, NULL },
4951 : },
4952 : {
4953 : "wbint_QueryGroupList",
4954 : sizeof(struct wbint_QueryGroupList),
4955 : (ndr_push_flags_fn_t) ndr_push_wbint_QueryGroupList,
4956 : (ndr_pull_flags_fn_t) ndr_pull_wbint_QueryGroupList,
4957 : (ndr_print_function_t) ndr_print_wbint_QueryGroupList,
4958 : { 0, NULL },
4959 : { 0, NULL },
4960 : },
4961 : {
4962 : "wbint_QueryUserRidList",
4963 : sizeof(struct wbint_QueryUserRidList),
4964 : (ndr_push_flags_fn_t) ndr_push_wbint_QueryUserRidList,
4965 : (ndr_pull_flags_fn_t) ndr_pull_wbint_QueryUserRidList,
4966 : (ndr_print_function_t) ndr_print_wbint_QueryUserRidList,
4967 : { 0, NULL },
4968 : { 0, NULL },
4969 : },
4970 : {
4971 : "wbint_DsGetDcName",
4972 : sizeof(struct wbint_DsGetDcName),
4973 : (ndr_push_flags_fn_t) ndr_push_wbint_DsGetDcName,
4974 : (ndr_pull_flags_fn_t) ndr_pull_wbint_DsGetDcName,
4975 : (ndr_print_function_t) ndr_print_wbint_DsGetDcName,
4976 : { 0, NULL },
4977 : { 0, NULL },
4978 : },
4979 : {
4980 : "wbint_LookupRids",
4981 : sizeof(struct wbint_LookupRids),
4982 : (ndr_push_flags_fn_t) ndr_push_wbint_LookupRids,
4983 : (ndr_pull_flags_fn_t) ndr_pull_wbint_LookupRids,
4984 : (ndr_print_function_t) ndr_print_wbint_LookupRids,
4985 : { 0, NULL },
4986 : { 0, NULL },
4987 : },
4988 : {
4989 : "wbint_CheckMachineAccount",
4990 : sizeof(struct wbint_CheckMachineAccount),
4991 : (ndr_push_flags_fn_t) ndr_push_wbint_CheckMachineAccount,
4992 : (ndr_pull_flags_fn_t) ndr_pull_wbint_CheckMachineAccount,
4993 : (ndr_print_function_t) ndr_print_wbint_CheckMachineAccount,
4994 : { 0, NULL },
4995 : { 0, NULL },
4996 : },
4997 : {
4998 : "wbint_ChangeMachineAccount",
4999 : sizeof(struct wbint_ChangeMachineAccount),
5000 : (ndr_push_flags_fn_t) ndr_push_wbint_ChangeMachineAccount,
5001 : (ndr_pull_flags_fn_t) ndr_pull_wbint_ChangeMachineAccount,
5002 : (ndr_print_function_t) ndr_print_wbint_ChangeMachineAccount,
5003 : { 0, NULL },
5004 : { 0, NULL },
5005 : },
5006 : {
5007 : "wbint_PingDc",
5008 : sizeof(struct wbint_PingDc),
5009 : (ndr_push_flags_fn_t) ndr_push_wbint_PingDc,
5010 : (ndr_pull_flags_fn_t) ndr_pull_wbint_PingDc,
5011 : (ndr_print_function_t) ndr_print_wbint_PingDc,
5012 : { 0, NULL },
5013 : { 0, NULL },
5014 : },
5015 : {
5016 : "wbint_ListTrustedDomains",
5017 : sizeof(struct wbint_ListTrustedDomains),
5018 : (ndr_push_flags_fn_t) ndr_push_wbint_ListTrustedDomains,
5019 : (ndr_pull_flags_fn_t) ndr_pull_wbint_ListTrustedDomains,
5020 : (ndr_print_function_t) ndr_print_wbint_ListTrustedDomains,
5021 : { 0, NULL },
5022 : { 0, NULL },
5023 : },
5024 : {
5025 : "wbint_PamAuth",
5026 : sizeof(struct wbint_PamAuth),
5027 : (ndr_push_flags_fn_t) ndr_push_wbint_PamAuth,
5028 : (ndr_pull_flags_fn_t) ndr_pull_wbint_PamAuth,
5029 : (ndr_print_function_t) ndr_print_wbint_PamAuth,
5030 : { 0, NULL },
5031 : { 0, NULL },
5032 : },
5033 : {
5034 : "wbint_PamAuthCrap",
5035 : sizeof(struct wbint_PamAuthCrap),
5036 : (ndr_push_flags_fn_t) ndr_push_wbint_PamAuthCrap,
5037 : (ndr_pull_flags_fn_t) ndr_pull_wbint_PamAuthCrap,
5038 : (ndr_print_function_t) ndr_print_wbint_PamAuthCrap,
5039 : { 0, NULL },
5040 : { 0, NULL },
5041 : },
5042 : {
5043 : "wbint_PamLogOff",
5044 : sizeof(struct wbint_PamLogOff),
5045 : (ndr_push_flags_fn_t) ndr_push_wbint_PamLogOff,
5046 : (ndr_pull_flags_fn_t) ndr_pull_wbint_PamLogOff,
5047 : (ndr_print_function_t) ndr_print_wbint_PamLogOff,
5048 : { 0, NULL },
5049 : { 0, NULL },
5050 : },
5051 : {
5052 : "wbint_PamAuthCrapChangePassword",
5053 : sizeof(struct wbint_PamAuthCrapChangePassword),
5054 : (ndr_push_flags_fn_t) ndr_push_wbint_PamAuthCrapChangePassword,
5055 : (ndr_pull_flags_fn_t) ndr_pull_wbint_PamAuthCrapChangePassword,
5056 : (ndr_print_function_t) ndr_print_wbint_PamAuthCrapChangePassword,
5057 : { 0, NULL },
5058 : { 0, NULL },
5059 : },
5060 : {
5061 : "wbint_PamAuthChangePassword",
5062 : sizeof(struct wbint_PamAuthChangePassword),
5063 : (ndr_push_flags_fn_t) ndr_push_wbint_PamAuthChangePassword,
5064 : (ndr_pull_flags_fn_t) ndr_pull_wbint_PamAuthChangePassword,
5065 : (ndr_print_function_t) ndr_print_wbint_PamAuthChangePassword,
5066 : { 0, NULL },
5067 : { 0, NULL },
5068 : },
5069 : {
5070 : "wbint_InitConnection",
5071 : sizeof(struct wbint_InitConnection),
5072 : (ndr_push_flags_fn_t) ndr_push_wbint_InitConnection,
5073 : (ndr_pull_flags_fn_t) ndr_pull_wbint_InitConnection,
5074 : (ndr_print_function_t) ndr_print_wbint_InitConnection,
5075 : { 0, NULL },
5076 : { 0, NULL },
5077 : },
5078 : {
5079 : "winbind_SamLogon",
5080 : sizeof(struct winbind_SamLogon),
5081 : (ndr_push_flags_fn_t) ndr_push_winbind_SamLogon,
5082 : (ndr_pull_flags_fn_t) ndr_pull_winbind_SamLogon,
5083 : (ndr_print_function_t) ndr_print_winbind_SamLogon,
5084 : { 0, NULL },
5085 : { 0, NULL },
5086 : },
5087 : {
5088 : "winbind_DsrUpdateReadOnlyServerDnsRecords",
5089 : sizeof(struct winbind_DsrUpdateReadOnlyServerDnsRecords),
5090 : (ndr_push_flags_fn_t) ndr_push_winbind_DsrUpdateReadOnlyServerDnsRecords,
5091 : (ndr_pull_flags_fn_t) ndr_pull_winbind_DsrUpdateReadOnlyServerDnsRecords,
5092 : (ndr_print_function_t) ndr_print_winbind_DsrUpdateReadOnlyServerDnsRecords,
5093 : { 0, NULL },
5094 : { 0, NULL },
5095 : },
5096 : {
5097 : "winbind_LogonControl",
5098 : sizeof(struct winbind_LogonControl),
5099 : (ndr_push_flags_fn_t) ndr_push_winbind_LogonControl,
5100 : (ndr_pull_flags_fn_t) ndr_pull_winbind_LogonControl,
5101 : (ndr_print_function_t) ndr_print_winbind_LogonControl,
5102 : { 0, NULL },
5103 : { 0, NULL },
5104 : },
5105 : {
5106 : "winbind_GetForestTrustInformation",
5107 : sizeof(struct winbind_GetForestTrustInformation),
5108 : (ndr_push_flags_fn_t) ndr_push_winbind_GetForestTrustInformation,
5109 : (ndr_pull_flags_fn_t) ndr_pull_winbind_GetForestTrustInformation,
5110 : (ndr_print_function_t) ndr_print_winbind_GetForestTrustInformation,
5111 : { 0, NULL },
5112 : { 0, NULL },
5113 : },
5114 : {
5115 : "winbind_SendToSam",
5116 : sizeof(struct winbind_SendToSam),
5117 : (ndr_push_flags_fn_t) ndr_push_winbind_SendToSam,
5118 : (ndr_pull_flags_fn_t) ndr_pull_winbind_SendToSam,
5119 : (ndr_print_function_t) ndr_print_winbind_SendToSam,
5120 : { 0, NULL },
5121 : { 0, NULL },
5122 : },
5123 : { .name = NULL }
5124 : };
5125 :
5126 : static const char * const winbind_endpoint_strings[] = {
5127 : "ncalrpc:",
5128 : };
5129 :
5130 : static const struct ndr_interface_string_array winbind_endpoints = {
5131 : .count = 1,
5132 : .names = winbind_endpoint_strings
5133 : };
5134 :
5135 : static const char * const winbind_authservice_strings[] = {
5136 : "host",
5137 : };
5138 :
5139 : static const struct ndr_interface_string_array winbind_authservices = {
5140 : .count = 1,
5141 : .names = winbind_authservice_strings
5142 : };
5143 :
5144 :
5145 : const struct ndr_interface_table ndr_table_winbind = {
5146 : .name = "winbind",
5147 : .syntax_id = {
5148 : {0xbf09192c,0xed60,0x4928,{0x9d,0xff},{0xd0,0xd7,0xbc,0xb0,0x3e,0xd8}},
5149 : NDR_WINBIND_VERSION
5150 : },
5151 : .helpstring = NDR_WINBIND_HELPSTRING,
5152 : .num_calls = 32,
5153 : .calls = winbind_calls,
5154 : .num_public_structs = 9,
5155 : .public_structs = winbind_public_structs,
5156 : .endpoints = &winbind_endpoints,
5157 : .authservices = &winbind_authservices
5158 : };
5159 :
5160 : #endif /* SKIP_NDR_TABLE_winbind */
|