Line data Source code
1 : /* parser auto-generated by pidl */
2 :
3 : #include "includes.h"
4 : #include "bin/default/librpc/gen_ndr/ndr_samr.h"
5 :
6 : #include "librpc/gen_ndr/ndr_misc.h"
7 : #include "librpc/gen_ndr/ndr_lsa.h"
8 : #include "librpc/gen_ndr/ndr_security.h"
9 121011 : _PUBLIC_ enum ndr_err_code ndr_push_samr_AcctFlags(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
10 : {
11 121011 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
12 115831 : return NDR_ERR_SUCCESS;
13 : }
14 :
15 232706 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_AcctFlags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
16 : {
17 4548 : uint32_t v;
18 232706 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
19 232706 : *r = v;
20 232706 : return NDR_ERR_SUCCESS;
21 : }
22 :
23 4269 : _PUBLIC_ void ndr_print_samr_AcctFlags(struct ndr_print *ndr, const char *name, uint32_t r)
24 : {
25 4269 : ndr_print_uint32(ndr, name, r);
26 4269 : ndr->depth++;
27 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_DISABLED", ACB_DISABLED, r);
28 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_HOMDIRREQ", ACB_HOMDIRREQ, r);
29 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_PWNOTREQ", ACB_PWNOTREQ, r);
30 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_TEMPDUP", ACB_TEMPDUP, r);
31 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_NORMAL", ACB_NORMAL, r);
32 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_MNS", ACB_MNS, r);
33 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_DOMTRUST", ACB_DOMTRUST, r);
34 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_WSTRUST", ACB_WSTRUST, r);
35 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_SVRTRUST", ACB_SVRTRUST, r);
36 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_PWNOEXP", ACB_PWNOEXP, r);
37 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_AUTOLOCK", ACB_AUTOLOCK, r);
38 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_ENC_TXT_PWD_ALLOWED", ACB_ENC_TXT_PWD_ALLOWED, r);
39 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_SMARTCARD_REQUIRED", ACB_SMARTCARD_REQUIRED, r);
40 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_TRUSTED_FOR_DELEGATION", ACB_TRUSTED_FOR_DELEGATION, r);
41 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_NOT_DELEGATED", ACB_NOT_DELEGATED, r);
42 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_USE_DES_KEY_ONLY", ACB_USE_DES_KEY_ONLY, r);
43 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_DONT_REQUIRE_PREAUTH", ACB_DONT_REQUIRE_PREAUTH, r);
44 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_PW_EXPIRED", ACB_PW_EXPIRED, r);
45 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_TRUSTED_TO_AUTHENTICATE_FOR_DELEGATION", ACB_TRUSTED_TO_AUTHENTICATE_FOR_DELEGATION, r);
46 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_NO_AUTH_DATA_REQD", ACB_NO_AUTH_DATA_REQD, r);
47 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_PARTIAL_SECRETS_ACCOUNT", ACB_PARTIAL_SECRETS_ACCOUNT, r);
48 4269 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "ACB_USE_AES_KEYS", ACB_USE_AES_KEYS, r);
49 4269 : ndr->depth--;
50 4269 : }
51 :
52 3328 : static enum ndr_err_code ndr_push_samr_ConnectAccessMask(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
53 : {
54 3328 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
55 3110 : return NDR_ERR_SUCCESS;
56 : }
57 :
58 3506 : static enum ndr_err_code ndr_pull_samr_ConnectAccessMask(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
59 : {
60 224 : uint32_t v;
61 3506 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
62 3506 : *r = v;
63 3506 : return NDR_ERR_SUCCESS;
64 : }
65 :
66 2 : _PUBLIC_ void ndr_print_samr_ConnectAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
67 : {
68 2 : ndr_print_uint32(ndr, name, r);
69 2 : ndr->depth++;
70 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ACCESS_CONNECT_TO_SERVER", SAMR_ACCESS_CONNECT_TO_SERVER, r);
71 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ACCESS_SHUTDOWN_SERVER", SAMR_ACCESS_SHUTDOWN_SERVER, r);
72 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ACCESS_INITIALIZE_SERVER", SAMR_ACCESS_INITIALIZE_SERVER, r);
73 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ACCESS_CREATE_DOMAIN", SAMR_ACCESS_CREATE_DOMAIN, r);
74 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ACCESS_ENUM_DOMAINS", SAMR_ACCESS_ENUM_DOMAINS, r);
75 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ACCESS_LOOKUP_DOMAIN", SAMR_ACCESS_LOOKUP_DOMAIN, r);
76 2 : ndr->depth--;
77 2 : }
78 :
79 5106 : static enum ndr_err_code ndr_push_samr_UserAccessMask(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
80 : {
81 5106 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
82 5015 : return NDR_ERR_SUCCESS;
83 : }
84 :
85 6197 : static enum ndr_err_code ndr_pull_samr_UserAccessMask(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
86 : {
87 96 : uint32_t v;
88 6197 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
89 6197 : *r = v;
90 6197 : return NDR_ERR_SUCCESS;
91 : }
92 :
93 5 : _PUBLIC_ void ndr_print_samr_UserAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
94 : {
95 5 : ndr_print_uint32(ndr, name, r);
96 5 : ndr->depth++;
97 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_GET_NAME_ETC", SAMR_USER_ACCESS_GET_NAME_ETC, r);
98 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_GET_LOCALE", SAMR_USER_ACCESS_GET_LOCALE, r);
99 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_SET_LOC_COM", SAMR_USER_ACCESS_SET_LOC_COM, r);
100 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_GET_LOGONINFO", SAMR_USER_ACCESS_GET_LOGONINFO, r);
101 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_GET_ATTRIBUTES", SAMR_USER_ACCESS_GET_ATTRIBUTES, r);
102 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_SET_ATTRIBUTES", SAMR_USER_ACCESS_SET_ATTRIBUTES, r);
103 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_CHANGE_PASSWORD", SAMR_USER_ACCESS_CHANGE_PASSWORD, r);
104 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_SET_PASSWORD", SAMR_USER_ACCESS_SET_PASSWORD, r);
105 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_GET_GROUPS", SAMR_USER_ACCESS_GET_GROUPS, r);
106 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_GET_GROUP_MEMBERSHIP", SAMR_USER_ACCESS_GET_GROUP_MEMBERSHIP, r);
107 5 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_USER_ACCESS_CHANGE_GROUP_MEMBERSHIP", SAMR_USER_ACCESS_CHANGE_GROUP_MEMBERSHIP, r);
108 5 : ndr->depth--;
109 5 : }
110 :
111 2776 : static enum ndr_err_code ndr_push_samr_DomainAccessMask(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
112 : {
113 2776 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
114 2566 : return NDR_ERR_SUCCESS;
115 : }
116 :
117 3148 : static enum ndr_err_code ndr_pull_samr_DomainAccessMask(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
118 : {
119 216 : uint32_t v;
120 3148 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
121 3148 : *r = v;
122 3148 : return NDR_ERR_SUCCESS;
123 : }
124 :
125 2 : _PUBLIC_ void ndr_print_samr_DomainAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
126 : {
127 2 : ndr_print_uint32(ndr, name, r);
128 2 : ndr->depth++;
129 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_LOOKUP_INFO_1", SAMR_DOMAIN_ACCESS_LOOKUP_INFO_1, r);
130 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_SET_INFO_1", SAMR_DOMAIN_ACCESS_SET_INFO_1, r);
131 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_LOOKUP_INFO_2", SAMR_DOMAIN_ACCESS_LOOKUP_INFO_2, r);
132 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_SET_INFO_2", SAMR_DOMAIN_ACCESS_SET_INFO_2, r);
133 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_CREATE_USER", SAMR_DOMAIN_ACCESS_CREATE_USER, r);
134 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_CREATE_GROUP", SAMR_DOMAIN_ACCESS_CREATE_GROUP, r);
135 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_CREATE_ALIAS", SAMR_DOMAIN_ACCESS_CREATE_ALIAS, r);
136 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_LOOKUP_ALIAS", SAMR_DOMAIN_ACCESS_LOOKUP_ALIAS, r);
137 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_ENUM_ACCOUNTS", SAMR_DOMAIN_ACCESS_ENUM_ACCOUNTS, r);
138 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_OPEN_ACCOUNT", SAMR_DOMAIN_ACCESS_OPEN_ACCOUNT, r);
139 2 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_DOMAIN_ACCESS_SET_INFO_3", SAMR_DOMAIN_ACCESS_SET_INFO_3, r);
140 2 : ndr->depth--;
141 2 : }
142 :
143 2177 : static enum ndr_err_code ndr_push_samr_GroupAccessMask(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
144 : {
145 2177 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
146 2177 : return NDR_ERR_SUCCESS;
147 : }
148 :
149 2165 : static enum ndr_err_code ndr_pull_samr_GroupAccessMask(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
150 : {
151 0 : uint32_t v;
152 2165 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
153 2165 : *r = v;
154 2165 : return NDR_ERR_SUCCESS;
155 : }
156 :
157 0 : _PUBLIC_ void ndr_print_samr_GroupAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
158 : {
159 0 : ndr_print_uint32(ndr, name, r);
160 0 : ndr->depth++;
161 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_GROUP_ACCESS_LOOKUP_INFO", SAMR_GROUP_ACCESS_LOOKUP_INFO, r);
162 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_GROUP_ACCESS_SET_INFO", SAMR_GROUP_ACCESS_SET_INFO, r);
163 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_GROUP_ACCESS_ADD_MEMBER", SAMR_GROUP_ACCESS_ADD_MEMBER, r);
164 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_GROUP_ACCESS_REMOVE_MEMBER", SAMR_GROUP_ACCESS_REMOVE_MEMBER, r);
165 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_GROUP_ACCESS_GET_MEMBERS", SAMR_GROUP_ACCESS_GET_MEMBERS, r);
166 0 : ndr->depth--;
167 0 : }
168 :
169 2821 : static enum ndr_err_code ndr_push_samr_AliasAccessMask(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
170 : {
171 2821 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
172 2821 : return NDR_ERR_SUCCESS;
173 : }
174 :
175 1587 : static enum ndr_err_code ndr_pull_samr_AliasAccessMask(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
176 : {
177 0 : uint32_t v;
178 1587 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
179 1587 : *r = v;
180 1587 : return NDR_ERR_SUCCESS;
181 : }
182 :
183 0 : _PUBLIC_ void ndr_print_samr_AliasAccessMask(struct ndr_print *ndr, const char *name, uint32_t r)
184 : {
185 0 : ndr_print_uint32(ndr, name, r);
186 0 : ndr->depth++;
187 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ALIAS_ACCESS_ADD_MEMBER", SAMR_ALIAS_ACCESS_ADD_MEMBER, r);
188 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ALIAS_ACCESS_REMOVE_MEMBER", SAMR_ALIAS_ACCESS_REMOVE_MEMBER, r);
189 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ALIAS_ACCESS_GET_MEMBERS", SAMR_ALIAS_ACCESS_GET_MEMBERS, r);
190 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ALIAS_ACCESS_LOOKUP_INFO", SAMR_ALIAS_ACCESS_LOOKUP_INFO, r);
191 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_ALIAS_ACCESS_SET_INFO", SAMR_ALIAS_ACCESS_SET_INFO, r);
192 0 : ndr->depth--;
193 0 : }
194 :
195 17574 : static enum ndr_err_code ndr_push_samr_SamEntry(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_SamEntry *r)
196 : {
197 17574 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
198 17574 : if (ndr_flags & NDR_SCALARS) {
199 8787 : NDR_CHECK(ndr_push_align(ndr, 5));
200 8787 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idx));
201 8787 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
202 8787 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
203 : }
204 17574 : if (ndr_flags & NDR_BUFFERS) {
205 8787 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
206 : }
207 17574 : return NDR_ERR_SUCCESS;
208 : }
209 :
210 10898 : static enum ndr_err_code ndr_pull_samr_SamEntry(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_SamEntry *r)
211 : {
212 10898 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
213 10898 : if (ndr_flags & NDR_SCALARS) {
214 5449 : NDR_CHECK(ndr_pull_align(ndr, 5));
215 5449 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idx));
216 5449 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
217 5449 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
218 : }
219 10898 : if (ndr_flags & NDR_BUFFERS) {
220 5449 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
221 : }
222 10898 : return NDR_ERR_SUCCESS;
223 : }
224 :
225 36 : _PUBLIC_ void ndr_print_samr_SamEntry(struct ndr_print *ndr, const char *name, const struct samr_SamEntry *r)
226 : {
227 36 : ndr_print_struct(ndr, name, "samr_SamEntry");
228 36 : if (r == NULL) { ndr_print_null(ndr); return; }
229 36 : ndr->depth++;
230 36 : ndr_print_uint32(ndr, "idx", r->idx);
231 36 : ndr_print_lsa_String(ndr, "name", &r->name);
232 36 : ndr->depth--;
233 : }
234 :
235 557 : static enum ndr_err_code ndr_push_samr_SamArray(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_SamArray *r)
236 : {
237 0 : uint32_t cntr_entries_1;
238 557 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
239 557 : if (ndr_flags & NDR_SCALARS) {
240 557 : NDR_CHECK(ndr_push_align(ndr, 5));
241 557 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
242 557 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries));
243 557 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
244 : }
245 557 : if (ndr_flags & NDR_BUFFERS) {
246 557 : if (r->entries) {
247 511 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
248 9298 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
249 8787 : NDR_CHECK(ndr_push_samr_SamEntry(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
250 : }
251 9298 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
252 8787 : NDR_CHECK(ndr_push_samr_SamEntry(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
253 : }
254 : }
255 : }
256 557 : return NDR_ERR_SUCCESS;
257 : }
258 :
259 553 : static enum ndr_err_code ndr_pull_samr_SamArray(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_SamArray *r)
260 : {
261 0 : uint32_t _ptr_entries;
262 553 : uint32_t size_entries_1 = 0;
263 0 : uint32_t cntr_entries_1;
264 553 : TALLOC_CTX *_mem_save_entries_0 = NULL;
265 553 : TALLOC_CTX *_mem_save_entries_1 = NULL;
266 553 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
267 553 : if (ndr_flags & NDR_SCALARS) {
268 553 : NDR_CHECK(ndr_pull_align(ndr, 5));
269 553 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
270 553 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
271 553 : if (_ptr_entries) {
272 473 : NDR_PULL_ALLOC(ndr, r->entries);
273 : } else {
274 80 : r->entries = NULL;
275 : }
276 553 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
277 : }
278 553 : if (ndr_flags & NDR_BUFFERS) {
279 553 : if (r->entries) {
280 473 : _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
281 473 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
282 473 : NDR_CHECK(ndr_pull_array_size(ndr, &r->entries));
283 473 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->entries, &size_entries_1));
284 473 : NDR_PULL_ALLOC_N(ndr, r->entries, size_entries_1);
285 473 : _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
286 473 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
287 5922 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
288 5449 : NDR_CHECK(ndr_pull_samr_SamEntry(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
289 : }
290 5922 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
291 5449 : NDR_CHECK(ndr_pull_samr_SamEntry(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
292 : }
293 473 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0);
294 473 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
295 : }
296 553 : if (r->entries) {
297 473 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count));
298 : }
299 6002 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
300 0 : }
301 : }
302 553 : return NDR_ERR_SUCCESS;
303 : }
304 :
305 4 : _PUBLIC_ void ndr_print_samr_SamArray(struct ndr_print *ndr, const char *name, const struct samr_SamArray *r)
306 : {
307 0 : uint32_t cntr_entries_1;
308 4 : ndr_print_struct(ndr, name, "samr_SamArray");
309 4 : if (r == NULL) { ndr_print_null(ndr); return; }
310 4 : ndr->depth++;
311 4 : ndr_print_uint32(ndr, "count", r->count);
312 4 : ndr_print_ptr(ndr, "entries", r->entries);
313 4 : ndr->depth++;
314 4 : if (r->entries) {
315 4 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "entries", (uint32_t)(r->count));
316 4 : ndr->depth++;
317 40 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
318 36 : ndr_print_samr_SamEntry(ndr, "entries", &r->entries[cntr_entries_1]);
319 : }
320 4 : ndr->depth--;
321 : }
322 4 : ndr->depth--;
323 4 : ndr->depth--;
324 : }
325 :
326 852 : static enum ndr_err_code ndr_push_samr_DomainInfoClass(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_DomainInfoClass r)
327 : {
328 852 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
329 852 : return NDR_ERR_SUCCESS;
330 : }
331 :
332 584 : static enum ndr_err_code ndr_pull_samr_DomainInfoClass(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_DomainInfoClass *r)
333 : {
334 0 : uint16_t v;
335 584 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
336 584 : *r = v;
337 584 : return NDR_ERR_SUCCESS;
338 : }
339 :
340 0 : _PUBLIC_ void ndr_print_samr_DomainInfoClass(struct ndr_print *ndr, const char *name, enum samr_DomainInfoClass r)
341 : {
342 0 : const char *val = NULL;
343 :
344 0 : switch (r) {
345 0 : case DomainPasswordInformation: val = "DomainPasswordInformation"; break;
346 0 : case DomainGeneralInformation: val = "DomainGeneralInformation"; break;
347 0 : case DomainLogoffInformation: val = "DomainLogoffInformation"; break;
348 0 : case DomainOemInformation: val = "DomainOemInformation"; break;
349 0 : case DomainNameInformation: val = "DomainNameInformation"; break;
350 0 : case DomainReplicationInformation: val = "DomainReplicationInformation"; break;
351 0 : case DomainServerRoleInformation: val = "DomainServerRoleInformation"; break;
352 0 : case DomainModifiedInformation: val = "DomainModifiedInformation"; break;
353 0 : case DomainStateInformation: val = "DomainStateInformation"; break;
354 0 : case DomainUasInformation: val = "DomainUasInformation"; break;
355 0 : case DomainGeneralInformation2: val = "DomainGeneralInformation2"; break;
356 0 : case DomainLockoutInformation: val = "DomainLockoutInformation"; break;
357 0 : case DomainModifiedInformation2: val = "DomainModifiedInformation2"; break;
358 : }
359 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
360 0 : }
361 :
362 155 : static enum ndr_err_code ndr_push_samr_Role(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_Role r)
363 : {
364 155 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
365 155 : return NDR_ERR_SUCCESS;
366 : }
367 :
368 202 : static enum ndr_err_code ndr_pull_samr_Role(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_Role *r)
369 : {
370 0 : uint32_t v;
371 202 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
372 202 : *r = v;
373 202 : return NDR_ERR_SUCCESS;
374 : }
375 :
376 2 : _PUBLIC_ void ndr_print_samr_Role(struct ndr_print *ndr, const char *name, enum samr_Role r)
377 : {
378 2 : const char *val = NULL;
379 :
380 2 : switch (r) {
381 0 : case SAMR_ROLE_STANDALONE: val = "SAMR_ROLE_STANDALONE"; break;
382 0 : case SAMR_ROLE_DOMAIN_MEMBER: val = "SAMR_ROLE_DOMAIN_MEMBER"; break;
383 0 : case SAMR_ROLE_DOMAIN_BDC: val = "SAMR_ROLE_DOMAIN_BDC"; break;
384 2 : case SAMR_ROLE_DOMAIN_PDC: val = "SAMR_ROLE_DOMAIN_PDC"; break;
385 : }
386 2 : ndr_print_enum(ndr, name, "ENUM", val, r);
387 2 : }
388 :
389 6293 : _PUBLIC_ enum ndr_err_code ndr_push_samr_PasswordProperties(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
390 : {
391 6293 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
392 5465 : return NDR_ERR_SUCCESS;
393 : }
394 :
395 6022 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_PasswordProperties(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
396 : {
397 694 : uint32_t v;
398 6022 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
399 6022 : *r = v;
400 6022 : return NDR_ERR_SUCCESS;
401 : }
402 :
403 1694 : _PUBLIC_ void ndr_print_samr_PasswordProperties(struct ndr_print *ndr, const char *name, uint32_t r)
404 : {
405 1694 : ndr_print_uint32(ndr, name, r);
406 1694 : ndr->depth++;
407 1694 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DOMAIN_PASSWORD_COMPLEX", DOMAIN_PASSWORD_COMPLEX, r);
408 1694 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DOMAIN_PASSWORD_NO_ANON_CHANGE", DOMAIN_PASSWORD_NO_ANON_CHANGE, r);
409 1694 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DOMAIN_PASSWORD_NO_CLEAR_CHANGE", DOMAIN_PASSWORD_NO_CLEAR_CHANGE, r);
410 1694 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DOMAIN_PASSWORD_LOCKOUT_ADMINS", DOMAIN_PASSWORD_LOCKOUT_ADMINS, r);
411 1694 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DOMAIN_PASSWORD_STORE_CLEARTEXT", DOMAIN_PASSWORD_STORE_CLEARTEXT, r);
412 1694 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "DOMAIN_REFUSE_PASSWORD_CHANGE", DOMAIN_REFUSE_PASSWORD_CHANGE, r);
413 1694 : ndr->depth--;
414 1694 : }
415 :
416 154 : static enum ndr_err_code ndr_push_samr_DomainServerState(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_DomainServerState r)
417 : {
418 154 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
419 154 : return NDR_ERR_SUCCESS;
420 : }
421 :
422 201 : static enum ndr_err_code ndr_pull_samr_DomainServerState(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_DomainServerState *r)
423 : {
424 0 : uint32_t v;
425 201 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
426 201 : *r = v;
427 201 : return NDR_ERR_SUCCESS;
428 : }
429 :
430 2 : _PUBLIC_ void ndr_print_samr_DomainServerState(struct ndr_print *ndr, const char *name, enum samr_DomainServerState r)
431 : {
432 2 : const char *val = NULL;
433 :
434 2 : switch (r) {
435 0 : case DOMAIN_SERVER_ENABLED: val = "DOMAIN_SERVER_ENABLED"; break;
436 0 : case DOMAIN_SERVER_DISABLED: val = "DOMAIN_SERVER_DISABLED"; break;
437 : }
438 2 : ndr_print_enum(ndr, name, "ENUM", val, r);
439 2 : }
440 :
441 318 : _PUBLIC_ enum ndr_err_code ndr_push_samr_DomInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo1 *r)
442 : {
443 318 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
444 318 : if (ndr_flags & NDR_SCALARS) {
445 318 : NDR_CHECK(ndr_push_align(ndr, 4));
446 318 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->min_password_length));
447 318 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->password_history_length));
448 318 : NDR_CHECK(ndr_push_samr_PasswordProperties(ndr, NDR_SCALARS, r->password_properties));
449 318 : NDR_CHECK(ndr_push_dlong(ndr, NDR_SCALARS, r->max_password_age));
450 318 : NDR_CHECK(ndr_push_dlong(ndr, NDR_SCALARS, r->min_password_age));
451 318 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
452 : }
453 318 : if (ndr_flags & NDR_BUFFERS) {
454 0 : }
455 318 : return NDR_ERR_SUCCESS;
456 : }
457 :
458 317 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_DomInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo1 *r)
459 : {
460 317 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
461 317 : if (ndr_flags & NDR_SCALARS) {
462 317 : NDR_CHECK(ndr_pull_align(ndr, 4));
463 317 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->min_password_length));
464 317 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->password_history_length));
465 317 : NDR_CHECK(ndr_pull_samr_PasswordProperties(ndr, NDR_SCALARS, &r->password_properties));
466 317 : NDR_CHECK(ndr_pull_dlong(ndr, NDR_SCALARS, &r->max_password_age));
467 317 : NDR_CHECK(ndr_pull_dlong(ndr, NDR_SCALARS, &r->min_password_age));
468 317 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
469 : }
470 317 : if (ndr_flags & NDR_BUFFERS) {
471 2 : }
472 317 : return NDR_ERR_SUCCESS;
473 : }
474 :
475 0 : static void ndr_print_flags_samr_DomInfo1(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct samr_DomInfo1 *r)
476 : {
477 0 : ndr_print_samr_DomInfo1(ndr, name, r);
478 0 : }
479 :
480 4 : _PUBLIC_ void ndr_print_samr_DomInfo1(struct ndr_print *ndr, const char *name, const struct samr_DomInfo1 *r)
481 : {
482 4 : ndr_print_struct(ndr, name, "samr_DomInfo1");
483 4 : if (r == NULL) { ndr_print_null(ndr); return; }
484 4 : ndr->depth++;
485 4 : ndr_print_uint16(ndr, "min_password_length", r->min_password_length);
486 4 : ndr_print_uint16(ndr, "password_history_length", r->password_history_length);
487 4 : ndr_print_samr_PasswordProperties(ndr, "password_properties", r->password_properties);
488 4 : ndr_print_dlong(ndr, "max_password_age", r->max_password_age);
489 4 : ndr_print_dlong(ndr, "min_password_age", r->min_password_age);
490 4 : ndr->depth--;
491 : }
492 :
493 252 : static enum ndr_err_code ndr_push_samr_DomGeneralInformation(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomGeneralInformation *r)
494 : {
495 252 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
496 252 : if (ndr_flags & NDR_SCALARS) {
497 126 : NDR_CHECK(ndr_push_align(ndr, 5));
498 126 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->force_logoff_time));
499 126 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->oem_information));
500 126 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->domain_name));
501 126 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->primary));
502 126 : NDR_CHECK(ndr_push_udlong(ndr, NDR_SCALARS, r->sequence_num));
503 126 : NDR_CHECK(ndr_push_samr_DomainServerState(ndr, NDR_SCALARS, r->domain_server_state));
504 126 : NDR_CHECK(ndr_push_samr_Role(ndr, NDR_SCALARS, r->role));
505 126 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->unknown3));
506 126 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_users));
507 126 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_groups));
508 126 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_aliases));
509 126 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
510 : }
511 252 : if (ndr_flags & NDR_BUFFERS) {
512 126 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->oem_information));
513 126 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->domain_name));
514 126 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->primary));
515 : }
516 252 : return NDR_ERR_SUCCESS;
517 : }
518 :
519 330 : static enum ndr_err_code ndr_pull_samr_DomGeneralInformation(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomGeneralInformation *r)
520 : {
521 330 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
522 330 : if (ndr_flags & NDR_SCALARS) {
523 165 : NDR_CHECK(ndr_pull_align(ndr, 5));
524 165 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->force_logoff_time));
525 165 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->oem_information));
526 165 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->domain_name));
527 165 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->primary));
528 165 : NDR_CHECK(ndr_pull_udlong(ndr, NDR_SCALARS, &r->sequence_num));
529 165 : NDR_CHECK(ndr_pull_samr_DomainServerState(ndr, NDR_SCALARS, &r->domain_server_state));
530 165 : NDR_CHECK(ndr_pull_samr_Role(ndr, NDR_SCALARS, &r->role));
531 165 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->unknown3));
532 165 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_users));
533 165 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_groups));
534 165 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_aliases));
535 165 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
536 : }
537 330 : if (ndr_flags & NDR_BUFFERS) {
538 165 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->oem_information));
539 165 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->domain_name));
540 165 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->primary));
541 : }
542 330 : return NDR_ERR_SUCCESS;
543 : }
544 :
545 2 : _PUBLIC_ void ndr_print_samr_DomGeneralInformation(struct ndr_print *ndr, const char *name, const struct samr_DomGeneralInformation *r)
546 : {
547 2 : ndr_print_struct(ndr, name, "samr_DomGeneralInformation");
548 2 : if (r == NULL) { ndr_print_null(ndr); return; }
549 2 : ndr->depth++;
550 2 : ndr_print_NTTIME(ndr, "force_logoff_time", r->force_logoff_time);
551 2 : ndr_print_lsa_String(ndr, "oem_information", &r->oem_information);
552 2 : ndr_print_lsa_String(ndr, "domain_name", &r->domain_name);
553 2 : ndr_print_lsa_String(ndr, "primary", &r->primary);
554 2 : ndr_print_udlong(ndr, "sequence_num", r->sequence_num);
555 2 : ndr_print_samr_DomainServerState(ndr, "domain_server_state", r->domain_server_state);
556 2 : ndr_print_samr_Role(ndr, "role", r->role);
557 2 : ndr_print_uint32(ndr, "unknown3", r->unknown3);
558 2 : ndr_print_uint32(ndr, "num_users", r->num_users);
559 2 : ndr_print_uint32(ndr, "num_groups", r->num_groups);
560 2 : ndr_print_uint32(ndr, "num_aliases", r->num_aliases);
561 2 : ndr->depth--;
562 : }
563 :
564 33 : static enum ndr_err_code ndr_push_samr_DomInfo3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo3 *r)
565 : {
566 33 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
567 33 : if (ndr_flags & NDR_SCALARS) {
568 33 : NDR_CHECK(ndr_push_align(ndr, 4));
569 33 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->force_logoff_time));
570 33 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
571 : }
572 33 : if (ndr_flags & NDR_BUFFERS) {
573 0 : }
574 33 : return NDR_ERR_SUCCESS;
575 : }
576 :
577 41 : static enum ndr_err_code ndr_pull_samr_DomInfo3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo3 *r)
578 : {
579 41 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
580 41 : if (ndr_flags & NDR_SCALARS) {
581 41 : NDR_CHECK(ndr_pull_align(ndr, 4));
582 41 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->force_logoff_time));
583 41 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
584 : }
585 41 : if (ndr_flags & NDR_BUFFERS) {
586 0 : }
587 41 : return NDR_ERR_SUCCESS;
588 : }
589 :
590 0 : _PUBLIC_ void ndr_print_samr_DomInfo3(struct ndr_print *ndr, const char *name, const struct samr_DomInfo3 *r)
591 : {
592 0 : ndr_print_struct(ndr, name, "samr_DomInfo3");
593 0 : if (r == NULL) { ndr_print_null(ndr); return; }
594 0 : ndr->depth++;
595 0 : ndr_print_NTTIME(ndr, "force_logoff_time", r->force_logoff_time);
596 0 : ndr->depth--;
597 : }
598 :
599 76 : static enum ndr_err_code ndr_push_samr_DomOEMInformation(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomOEMInformation *r)
600 : {
601 76 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
602 76 : if (ndr_flags & NDR_SCALARS) {
603 38 : NDR_CHECK(ndr_push_align(ndr, 5));
604 38 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->oem_information));
605 38 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
606 : }
607 76 : if (ndr_flags & NDR_BUFFERS) {
608 38 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->oem_information));
609 : }
610 76 : return NDR_ERR_SUCCESS;
611 : }
612 :
613 84 : static enum ndr_err_code ndr_pull_samr_DomOEMInformation(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomOEMInformation *r)
614 : {
615 84 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
616 84 : if (ndr_flags & NDR_SCALARS) {
617 42 : NDR_CHECK(ndr_pull_align(ndr, 5));
618 42 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->oem_information));
619 42 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
620 : }
621 84 : if (ndr_flags & NDR_BUFFERS) {
622 42 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->oem_information));
623 : }
624 84 : return NDR_ERR_SUCCESS;
625 : }
626 :
627 0 : _PUBLIC_ void ndr_print_samr_DomOEMInformation(struct ndr_print *ndr, const char *name, const struct samr_DomOEMInformation *r)
628 : {
629 0 : ndr_print_struct(ndr, name, "samr_DomOEMInformation");
630 0 : if (r == NULL) { ndr_print_null(ndr); return; }
631 0 : ndr->depth++;
632 0 : ndr_print_lsa_String(ndr, "oem_information", &r->oem_information);
633 0 : ndr->depth--;
634 : }
635 :
636 58 : static enum ndr_err_code ndr_push_samr_DomInfo5(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo5 *r)
637 : {
638 58 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
639 58 : if (ndr_flags & NDR_SCALARS) {
640 29 : NDR_CHECK(ndr_push_align(ndr, 5));
641 29 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->domain_name));
642 29 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
643 : }
644 58 : if (ndr_flags & NDR_BUFFERS) {
645 29 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->domain_name));
646 : }
647 58 : return NDR_ERR_SUCCESS;
648 : }
649 :
650 74 : static enum ndr_err_code ndr_pull_samr_DomInfo5(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo5 *r)
651 : {
652 74 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
653 74 : if (ndr_flags & NDR_SCALARS) {
654 37 : NDR_CHECK(ndr_pull_align(ndr, 5));
655 37 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->domain_name));
656 37 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
657 : }
658 74 : if (ndr_flags & NDR_BUFFERS) {
659 37 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->domain_name));
660 : }
661 74 : return NDR_ERR_SUCCESS;
662 : }
663 :
664 0 : _PUBLIC_ void ndr_print_samr_DomInfo5(struct ndr_print *ndr, const char *name, const struct samr_DomInfo5 *r)
665 : {
666 0 : ndr_print_struct(ndr, name, "samr_DomInfo5");
667 0 : if (r == NULL) { ndr_print_null(ndr); return; }
668 0 : ndr->depth++;
669 0 : ndr_print_lsa_String(ndr, "domain_name", &r->domain_name);
670 0 : ndr->depth--;
671 : }
672 :
673 58 : static enum ndr_err_code ndr_push_samr_DomInfo6(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo6 *r)
674 : {
675 58 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
676 58 : if (ndr_flags & NDR_SCALARS) {
677 29 : NDR_CHECK(ndr_push_align(ndr, 5));
678 29 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->primary));
679 29 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
680 : }
681 58 : if (ndr_flags & NDR_BUFFERS) {
682 29 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->primary));
683 : }
684 58 : return NDR_ERR_SUCCESS;
685 : }
686 :
687 74 : static enum ndr_err_code ndr_pull_samr_DomInfo6(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo6 *r)
688 : {
689 74 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
690 74 : if (ndr_flags & NDR_SCALARS) {
691 37 : NDR_CHECK(ndr_pull_align(ndr, 5));
692 37 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->primary));
693 37 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
694 : }
695 74 : if (ndr_flags & NDR_BUFFERS) {
696 37 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->primary));
697 : }
698 74 : return NDR_ERR_SUCCESS;
699 : }
700 :
701 0 : _PUBLIC_ void ndr_print_samr_DomInfo6(struct ndr_print *ndr, const char *name, const struct samr_DomInfo6 *r)
702 : {
703 0 : ndr_print_struct(ndr, name, "samr_DomInfo6");
704 0 : if (r == NULL) { ndr_print_null(ndr); return; }
705 0 : ndr->depth++;
706 0 : ndr_print_lsa_String(ndr, "primary", &r->primary);
707 0 : ndr->depth--;
708 : }
709 :
710 29 : static enum ndr_err_code ndr_push_samr_DomInfo7(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo7 *r)
711 : {
712 29 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
713 29 : if (ndr_flags & NDR_SCALARS) {
714 29 : NDR_CHECK(ndr_push_align(ndr, 4));
715 29 : NDR_CHECK(ndr_push_samr_Role(ndr, NDR_SCALARS, r->role));
716 29 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
717 : }
718 29 : if (ndr_flags & NDR_BUFFERS) {
719 0 : }
720 29 : return NDR_ERR_SUCCESS;
721 : }
722 :
723 37 : static enum ndr_err_code ndr_pull_samr_DomInfo7(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo7 *r)
724 : {
725 37 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
726 37 : if (ndr_flags & NDR_SCALARS) {
727 37 : NDR_CHECK(ndr_pull_align(ndr, 4));
728 37 : NDR_CHECK(ndr_pull_samr_Role(ndr, NDR_SCALARS, &r->role));
729 37 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
730 : }
731 37 : if (ndr_flags & NDR_BUFFERS) {
732 0 : }
733 37 : return NDR_ERR_SUCCESS;
734 : }
735 :
736 0 : _PUBLIC_ void ndr_print_samr_DomInfo7(struct ndr_print *ndr, const char *name, const struct samr_DomInfo7 *r)
737 : {
738 0 : ndr_print_struct(ndr, name, "samr_DomInfo7");
739 0 : if (r == NULL) { ndr_print_null(ndr); return; }
740 0 : ndr->depth++;
741 0 : ndr_print_samr_Role(ndr, "role", r->role);
742 0 : ndr->depth--;
743 : }
744 :
745 36 : static enum ndr_err_code ndr_push_samr_DomInfo8(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo8 *r)
746 : {
747 36 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
748 36 : if (ndr_flags & NDR_SCALARS) {
749 36 : NDR_CHECK(ndr_push_align(ndr, 8));
750 36 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->sequence_num));
751 36 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->domain_create_time));
752 36 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
753 : }
754 36 : if (ndr_flags & NDR_BUFFERS) {
755 0 : }
756 36 : return NDR_ERR_SUCCESS;
757 : }
758 :
759 43 : static enum ndr_err_code ndr_pull_samr_DomInfo8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo8 *r)
760 : {
761 43 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
762 43 : if (ndr_flags & NDR_SCALARS) {
763 43 : NDR_CHECK(ndr_pull_align(ndr, 8));
764 43 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->sequence_num));
765 43 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->domain_create_time));
766 43 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
767 : }
768 43 : if (ndr_flags & NDR_BUFFERS) {
769 0 : }
770 43 : return NDR_ERR_SUCCESS;
771 : }
772 :
773 2 : _PUBLIC_ void ndr_print_samr_DomInfo8(struct ndr_print *ndr, const char *name, const struct samr_DomInfo8 *r)
774 : {
775 2 : ndr_print_struct(ndr, name, "samr_DomInfo8");
776 2 : if (r == NULL) { ndr_print_null(ndr); return; }
777 2 : ndr->depth++;
778 2 : ndr_print_hyper(ndr, "sequence_num", r->sequence_num);
779 2 : ndr_print_NTTIME(ndr, "domain_create_time", r->domain_create_time);
780 2 : ndr->depth--;
781 : }
782 :
783 28 : static enum ndr_err_code ndr_push_samr_DomInfo9(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo9 *r)
784 : {
785 28 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
786 28 : if (ndr_flags & NDR_SCALARS) {
787 28 : NDR_CHECK(ndr_push_align(ndr, 4));
788 28 : NDR_CHECK(ndr_push_samr_DomainServerState(ndr, NDR_SCALARS, r->domain_server_state));
789 28 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
790 : }
791 28 : if (ndr_flags & NDR_BUFFERS) {
792 0 : }
793 28 : return NDR_ERR_SUCCESS;
794 : }
795 :
796 36 : static enum ndr_err_code ndr_pull_samr_DomInfo9(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo9 *r)
797 : {
798 36 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
799 36 : if (ndr_flags & NDR_SCALARS) {
800 36 : NDR_CHECK(ndr_pull_align(ndr, 4));
801 36 : NDR_CHECK(ndr_pull_samr_DomainServerState(ndr, NDR_SCALARS, &r->domain_server_state));
802 36 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
803 : }
804 36 : if (ndr_flags & NDR_BUFFERS) {
805 0 : }
806 36 : return NDR_ERR_SUCCESS;
807 : }
808 :
809 0 : _PUBLIC_ void ndr_print_samr_DomInfo9(struct ndr_print *ndr, const char *name, const struct samr_DomInfo9 *r)
810 : {
811 0 : ndr_print_struct(ndr, name, "samr_DomInfo9");
812 0 : if (r == NULL) { ndr_print_null(ndr); return; }
813 0 : ndr->depth++;
814 0 : ndr_print_samr_DomainServerState(ndr, "domain_server_state", r->domain_server_state);
815 0 : ndr->depth--;
816 : }
817 :
818 56 : static enum ndr_err_code ndr_push_samr_DomGeneralInformation2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomGeneralInformation2 *r)
819 : {
820 56 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
821 56 : if (ndr_flags & NDR_SCALARS) {
822 28 : NDR_CHECK(ndr_push_align(ndr, 8));
823 28 : NDR_CHECK(ndr_push_samr_DomGeneralInformation(ndr, NDR_SCALARS, &r->general));
824 28 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->lockout_duration));
825 28 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->lockout_window));
826 28 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->lockout_threshold));
827 28 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
828 : }
829 56 : if (ndr_flags & NDR_BUFFERS) {
830 28 : NDR_CHECK(ndr_push_samr_DomGeneralInformation(ndr, NDR_BUFFERS, &r->general));
831 : }
832 56 : return NDR_ERR_SUCCESS;
833 : }
834 :
835 72 : static enum ndr_err_code ndr_pull_samr_DomGeneralInformation2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomGeneralInformation2 *r)
836 : {
837 72 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
838 72 : if (ndr_flags & NDR_SCALARS) {
839 36 : NDR_CHECK(ndr_pull_align(ndr, 8));
840 36 : NDR_CHECK(ndr_pull_samr_DomGeneralInformation(ndr, NDR_SCALARS, &r->general));
841 36 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->lockout_duration));
842 36 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->lockout_window));
843 36 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->lockout_threshold));
844 36 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
845 : }
846 72 : if (ndr_flags & NDR_BUFFERS) {
847 36 : NDR_CHECK(ndr_pull_samr_DomGeneralInformation(ndr, NDR_BUFFERS, &r->general));
848 : }
849 72 : return NDR_ERR_SUCCESS;
850 : }
851 :
852 0 : _PUBLIC_ void ndr_print_samr_DomGeneralInformation2(struct ndr_print *ndr, const char *name, const struct samr_DomGeneralInformation2 *r)
853 : {
854 0 : ndr_print_struct(ndr, name, "samr_DomGeneralInformation2");
855 0 : if (r == NULL) { ndr_print_null(ndr); return; }
856 0 : ndr->depth++;
857 0 : ndr_print_samr_DomGeneralInformation(ndr, "general", &r->general);
858 0 : ndr_print_hyper(ndr, "lockout_duration", r->lockout_duration);
859 0 : ndr_print_hyper(ndr, "lockout_window", r->lockout_window);
860 0 : ndr_print_uint16(ndr, "lockout_threshold", r->lockout_threshold);
861 0 : ndr->depth--;
862 : }
863 :
864 130 : static enum ndr_err_code ndr_push_samr_DomInfo12(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo12 *r)
865 : {
866 130 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
867 130 : if (ndr_flags & NDR_SCALARS) {
868 130 : NDR_CHECK(ndr_push_align(ndr, 8));
869 130 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->lockout_duration));
870 130 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->lockout_window));
871 130 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->lockout_threshold));
872 130 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
873 : }
874 130 : if (ndr_flags & NDR_BUFFERS) {
875 0 : }
876 130 : return NDR_ERR_SUCCESS;
877 : }
878 :
879 119 : static enum ndr_err_code ndr_pull_samr_DomInfo12(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo12 *r)
880 : {
881 119 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
882 119 : if (ndr_flags & NDR_SCALARS) {
883 119 : NDR_CHECK(ndr_pull_align(ndr, 8));
884 119 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->lockout_duration));
885 119 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->lockout_window));
886 119 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->lockout_threshold));
887 119 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
888 : }
889 119 : if (ndr_flags & NDR_BUFFERS) {
890 0 : }
891 119 : return NDR_ERR_SUCCESS;
892 : }
893 :
894 2 : _PUBLIC_ void ndr_print_samr_DomInfo12(struct ndr_print *ndr, const char *name, const struct samr_DomInfo12 *r)
895 : {
896 2 : ndr_print_struct(ndr, name, "samr_DomInfo12");
897 2 : if (r == NULL) { ndr_print_null(ndr); return; }
898 2 : ndr->depth++;
899 2 : ndr_print_hyper(ndr, "lockout_duration", r->lockout_duration);
900 2 : ndr_print_hyper(ndr, "lockout_window", r->lockout_window);
901 2 : ndr_print_uint16(ndr, "lockout_threshold", r->lockout_threshold);
902 2 : ndr->depth--;
903 : }
904 :
905 28 : static enum ndr_err_code ndr_push_samr_DomInfo13(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DomInfo13 *r)
906 : {
907 28 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
908 28 : if (ndr_flags & NDR_SCALARS) {
909 28 : NDR_CHECK(ndr_push_align(ndr, 8));
910 28 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->sequence_num));
911 28 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->domain_create_time));
912 28 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->modified_count_at_last_promotion));
913 28 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
914 : }
915 28 : if (ndr_flags & NDR_BUFFERS) {
916 0 : }
917 28 : return NDR_ERR_SUCCESS;
918 : }
919 :
920 36 : static enum ndr_err_code ndr_pull_samr_DomInfo13(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DomInfo13 *r)
921 : {
922 36 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
923 36 : if (ndr_flags & NDR_SCALARS) {
924 36 : NDR_CHECK(ndr_pull_align(ndr, 8));
925 36 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->sequence_num));
926 36 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->domain_create_time));
927 36 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->modified_count_at_last_promotion));
928 36 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
929 : }
930 36 : if (ndr_flags & NDR_BUFFERS) {
931 0 : }
932 36 : return NDR_ERR_SUCCESS;
933 : }
934 :
935 0 : _PUBLIC_ void ndr_print_samr_DomInfo13(struct ndr_print *ndr, const char *name, const struct samr_DomInfo13 *r)
936 : {
937 0 : ndr_print_struct(ndr, name, "samr_DomInfo13");
938 0 : if (r == NULL) { ndr_print_null(ndr); return; }
939 0 : ndr->depth++;
940 0 : ndr_print_hyper(ndr, "sequence_num", r->sequence_num);
941 0 : ndr_print_NTTIME(ndr, "domain_create_time", r->domain_create_time);
942 0 : ndr_print_hyper(ndr, "modified_count_at_last_promotion", r->modified_count_at_last_promotion);
943 0 : ndr->depth--;
944 : }
945 :
946 680 : static enum ndr_err_code ndr_push_samr_DomainInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_DomainInfo *r)
947 : {
948 0 : uint32_t level;
949 680 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
950 680 : if (ndr_flags & NDR_SCALARS) {
951 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
952 680 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
953 680 : NDR_CHECK(ndr_push_union_align(ndr, 8));
954 680 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
955 680 : NDR_CHECK(ndr_push_union_align(ndr, 8));
956 680 : switch (level) {
957 174 : case 1: {
958 174 : NDR_CHECK(ndr_push_samr_DomInfo1(ndr, NDR_SCALARS, &r->info1));
959 174 : break; }
960 :
961 98 : case 2: {
962 98 : NDR_CHECK(ndr_push_samr_DomGeneralInformation(ndr, NDR_SCALARS, &r->general));
963 98 : break; }
964 :
965 33 : case 3: {
966 33 : NDR_CHECK(ndr_push_samr_DomInfo3(ndr, NDR_SCALARS, &r->info3));
967 33 : break; }
968 :
969 38 : case 4: {
970 38 : NDR_CHECK(ndr_push_samr_DomOEMInformation(ndr, NDR_SCALARS, &r->oem));
971 38 : break; }
972 :
973 29 : case 5: {
974 29 : NDR_CHECK(ndr_push_samr_DomInfo5(ndr, NDR_SCALARS, &r->info5));
975 29 : break; }
976 :
977 29 : case 6: {
978 29 : NDR_CHECK(ndr_push_samr_DomInfo6(ndr, NDR_SCALARS, &r->info6));
979 29 : break; }
980 :
981 29 : case 7: {
982 29 : NDR_CHECK(ndr_push_samr_DomInfo7(ndr, NDR_SCALARS, &r->info7));
983 29 : break; }
984 :
985 36 : case 8: {
986 36 : NDR_CHECK(ndr_push_samr_DomInfo8(ndr, NDR_SCALARS, &r->info8));
987 36 : break; }
988 :
989 28 : case 9: {
990 28 : NDR_CHECK(ndr_push_samr_DomInfo9(ndr, NDR_SCALARS, &r->info9));
991 28 : break; }
992 :
993 28 : case 11: {
994 28 : NDR_CHECK(ndr_push_samr_DomGeneralInformation2(ndr, NDR_SCALARS, &r->general2));
995 28 : break; }
996 :
997 130 : case 12: {
998 130 : NDR_CHECK(ndr_push_samr_DomInfo12(ndr, NDR_SCALARS, &r->info12));
999 130 : break; }
1000 :
1001 28 : case 13: {
1002 28 : NDR_CHECK(ndr_push_samr_DomInfo13(ndr, NDR_SCALARS, &r->info13));
1003 28 : break; }
1004 :
1005 0 : default:
1006 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
1007 : }
1008 : }
1009 680 : if (ndr_flags & NDR_BUFFERS) {
1010 680 : if (!(ndr_flags & NDR_SCALARS)) {
1011 : /* We didn't get it above, and the token is not needed after this. */
1012 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1013 : }
1014 680 : switch (level) {
1015 174 : case 1:
1016 174 : break;
1017 :
1018 98 : case 2:
1019 98 : NDR_CHECK(ndr_push_samr_DomGeneralInformation(ndr, NDR_BUFFERS, &r->general));
1020 98 : break;
1021 :
1022 33 : case 3:
1023 33 : break;
1024 :
1025 38 : case 4:
1026 38 : NDR_CHECK(ndr_push_samr_DomOEMInformation(ndr, NDR_BUFFERS, &r->oem));
1027 38 : break;
1028 :
1029 29 : case 5:
1030 29 : NDR_CHECK(ndr_push_samr_DomInfo5(ndr, NDR_BUFFERS, &r->info5));
1031 29 : break;
1032 :
1033 29 : case 6:
1034 29 : NDR_CHECK(ndr_push_samr_DomInfo6(ndr, NDR_BUFFERS, &r->info6));
1035 29 : break;
1036 :
1037 29 : case 7:
1038 29 : break;
1039 :
1040 36 : case 8:
1041 36 : break;
1042 :
1043 28 : case 9:
1044 28 : break;
1045 :
1046 28 : case 11:
1047 28 : NDR_CHECK(ndr_push_samr_DomGeneralInformation2(ndr, NDR_BUFFERS, &r->general2));
1048 28 : break;
1049 :
1050 130 : case 12:
1051 130 : break;
1052 :
1053 28 : case 13:
1054 28 : break;
1055 :
1056 0 : default:
1057 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
1058 : }
1059 : }
1060 680 : return NDR_ERR_SUCCESS;
1061 : }
1062 :
1063 760 : static enum ndr_err_code ndr_pull_samr_DomainInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_DomainInfo *r)
1064 : {
1065 0 : uint32_t level;
1066 0 : uint16_t _level;
1067 760 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1068 760 : if (ndr_flags & NDR_SCALARS) {
1069 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1070 760 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1071 760 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
1072 760 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
1073 760 : if (_level != level) {
1074 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
1075 : }
1076 760 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
1077 760 : switch (level) {
1078 167 : case 1: {
1079 167 : NDR_CHECK(ndr_pull_samr_DomInfo1(ndr, NDR_SCALARS, &r->info1));
1080 167 : break; }
1081 :
1082 129 : case 2: {
1083 129 : NDR_CHECK(ndr_pull_samr_DomGeneralInformation(ndr, NDR_SCALARS, &r->general));
1084 129 : break; }
1085 :
1086 41 : case 3: {
1087 41 : NDR_CHECK(ndr_pull_samr_DomInfo3(ndr, NDR_SCALARS, &r->info3));
1088 41 : break; }
1089 :
1090 42 : case 4: {
1091 42 : NDR_CHECK(ndr_pull_samr_DomOEMInformation(ndr, NDR_SCALARS, &r->oem));
1092 42 : break; }
1093 :
1094 37 : case 5: {
1095 37 : NDR_CHECK(ndr_pull_samr_DomInfo5(ndr, NDR_SCALARS, &r->info5));
1096 37 : break; }
1097 :
1098 37 : case 6: {
1099 37 : NDR_CHECK(ndr_pull_samr_DomInfo6(ndr, NDR_SCALARS, &r->info6));
1100 37 : break; }
1101 :
1102 37 : case 7: {
1103 37 : NDR_CHECK(ndr_pull_samr_DomInfo7(ndr, NDR_SCALARS, &r->info7));
1104 37 : break; }
1105 :
1106 43 : case 8: {
1107 43 : NDR_CHECK(ndr_pull_samr_DomInfo8(ndr, NDR_SCALARS, &r->info8));
1108 43 : break; }
1109 :
1110 36 : case 9: {
1111 36 : NDR_CHECK(ndr_pull_samr_DomInfo9(ndr, NDR_SCALARS, &r->info9));
1112 36 : break; }
1113 :
1114 36 : case 11: {
1115 36 : NDR_CHECK(ndr_pull_samr_DomGeneralInformation2(ndr, NDR_SCALARS, &r->general2));
1116 36 : break; }
1117 :
1118 119 : case 12: {
1119 119 : NDR_CHECK(ndr_pull_samr_DomInfo12(ndr, NDR_SCALARS, &r->info12));
1120 119 : break; }
1121 :
1122 36 : case 13: {
1123 36 : NDR_CHECK(ndr_pull_samr_DomInfo13(ndr, NDR_SCALARS, &r->info13));
1124 36 : break; }
1125 :
1126 0 : default:
1127 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
1128 : }
1129 : }
1130 760 : if (ndr_flags & NDR_BUFFERS) {
1131 760 : if (!(ndr_flags & NDR_SCALARS)) {
1132 : /* We didn't get it above, and the token is not needed after this. */
1133 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1134 : }
1135 760 : switch (level) {
1136 167 : case 1:
1137 167 : break;
1138 :
1139 129 : case 2:
1140 129 : NDR_CHECK(ndr_pull_samr_DomGeneralInformation(ndr, NDR_BUFFERS, &r->general));
1141 129 : break;
1142 :
1143 41 : case 3:
1144 41 : break;
1145 :
1146 42 : case 4:
1147 42 : NDR_CHECK(ndr_pull_samr_DomOEMInformation(ndr, NDR_BUFFERS, &r->oem));
1148 42 : break;
1149 :
1150 37 : case 5:
1151 37 : NDR_CHECK(ndr_pull_samr_DomInfo5(ndr, NDR_BUFFERS, &r->info5));
1152 37 : break;
1153 :
1154 37 : case 6:
1155 37 : NDR_CHECK(ndr_pull_samr_DomInfo6(ndr, NDR_BUFFERS, &r->info6));
1156 37 : break;
1157 :
1158 37 : case 7:
1159 37 : break;
1160 :
1161 43 : case 8:
1162 43 : break;
1163 :
1164 36 : case 9:
1165 36 : break;
1166 :
1167 36 : case 11:
1168 36 : NDR_CHECK(ndr_pull_samr_DomGeneralInformation2(ndr, NDR_BUFFERS, &r->general2));
1169 36 : break;
1170 :
1171 119 : case 12:
1172 119 : break;
1173 :
1174 36 : case 13:
1175 36 : break;
1176 :
1177 0 : default:
1178 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
1179 : }
1180 : }
1181 760 : return NDR_ERR_SUCCESS;
1182 : }
1183 :
1184 8 : _PUBLIC_ void ndr_print_samr_DomainInfo(struct ndr_print *ndr, const char *name, const union samr_DomainInfo *r)
1185 : {
1186 0 : uint32_t level;
1187 8 : level = ndr_print_steal_switch_value(ndr, r);
1188 8 : ndr_print_union(ndr, name, level, "samr_DomainInfo");
1189 8 : switch (level) {
1190 2 : case 1:
1191 2 : ndr_print_samr_DomInfo1(ndr, "info1", &r->info1);
1192 2 : break;
1193 :
1194 2 : case 2:
1195 2 : ndr_print_samr_DomGeneralInformation(ndr, "general", &r->general);
1196 2 : break;
1197 :
1198 0 : case 3:
1199 0 : ndr_print_samr_DomInfo3(ndr, "info3", &r->info3);
1200 0 : break;
1201 :
1202 0 : case 4:
1203 0 : ndr_print_samr_DomOEMInformation(ndr, "oem", &r->oem);
1204 0 : break;
1205 :
1206 0 : case 5:
1207 0 : ndr_print_samr_DomInfo5(ndr, "info5", &r->info5);
1208 0 : break;
1209 :
1210 0 : case 6:
1211 0 : ndr_print_samr_DomInfo6(ndr, "info6", &r->info6);
1212 0 : break;
1213 :
1214 0 : case 7:
1215 0 : ndr_print_samr_DomInfo7(ndr, "info7", &r->info7);
1216 0 : break;
1217 :
1218 2 : case 8:
1219 2 : ndr_print_samr_DomInfo8(ndr, "info8", &r->info8);
1220 2 : break;
1221 :
1222 0 : case 9:
1223 0 : ndr_print_samr_DomInfo9(ndr, "info9", &r->info9);
1224 0 : break;
1225 :
1226 0 : case 11:
1227 0 : ndr_print_samr_DomGeneralInformation2(ndr, "general2", &r->general2);
1228 0 : break;
1229 :
1230 2 : case 12:
1231 2 : ndr_print_samr_DomInfo12(ndr, "info12", &r->info12);
1232 2 : break;
1233 :
1234 0 : case 13:
1235 0 : ndr_print_samr_DomInfo13(ndr, "info13", &r->info13);
1236 0 : break;
1237 :
1238 0 : default:
1239 0 : ndr_print_bad_level(ndr, name, level);
1240 : }
1241 8 : }
1242 :
1243 17706 : static enum ndr_err_code ndr_push_samr_Ids(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_Ids *r)
1244 : {
1245 34 : uint32_t cntr_ids_1;
1246 17706 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1247 17706 : if (ndr_flags & NDR_SCALARS) {
1248 17706 : NDR_CHECK(ndr_push_align(ndr, 5));
1249 17706 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
1250 17706 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->ids));
1251 17706 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1252 : }
1253 17706 : if (ndr_flags & NDR_BUFFERS) {
1254 17706 : if (r->ids) {
1255 17049 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
1256 35331 : for (cntr_ids_1 = 0; cntr_ids_1 < (r->count); cntr_ids_1++) {
1257 18282 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ids[cntr_ids_1]));
1258 : }
1259 : }
1260 : }
1261 17672 : return NDR_ERR_SUCCESS;
1262 : }
1263 :
1264 6753 : static enum ndr_err_code ndr_pull_samr_Ids(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_Ids *r)
1265 : {
1266 4 : uint32_t _ptr_ids;
1267 6753 : uint32_t size_ids_1 = 0;
1268 4 : uint32_t cntr_ids_1;
1269 6753 : TALLOC_CTX *_mem_save_ids_0 = NULL;
1270 6753 : TALLOC_CTX *_mem_save_ids_1 = NULL;
1271 6753 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1272 6753 : if (ndr_flags & NDR_SCALARS) {
1273 6753 : NDR_CHECK(ndr_pull_align(ndr, 5));
1274 6753 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
1275 6753 : if (r->count > 1024) {
1276 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->count), (uint32_t)(0), (uint32_t)(1024));
1277 : }
1278 6753 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_ids));
1279 6753 : if (_ptr_ids) {
1280 6094 : NDR_PULL_ALLOC(ndr, r->ids);
1281 : } else {
1282 659 : r->ids = NULL;
1283 : }
1284 6753 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1285 : }
1286 6753 : if (ndr_flags & NDR_BUFFERS) {
1287 6753 : if (r->ids) {
1288 6094 : _mem_save_ids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1289 6094 : NDR_PULL_SET_MEM_CTX(ndr, r->ids, 0);
1290 6094 : NDR_CHECK(ndr_pull_array_size(ndr, &r->ids));
1291 6094 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->ids, &size_ids_1));
1292 6094 : NDR_PULL_ALLOC_N(ndr, r->ids, size_ids_1);
1293 6094 : _mem_save_ids_1 = NDR_PULL_GET_MEM_CTX(ndr);
1294 6094 : NDR_PULL_SET_MEM_CTX(ndr, r->ids, 0);
1295 13309 : for (cntr_ids_1 = 0; cntr_ids_1 < (size_ids_1); cntr_ids_1++) {
1296 7215 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ids[cntr_ids_1]));
1297 : }
1298 6094 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ids_1, 0);
1299 6094 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_ids_0, 0);
1300 : }
1301 6753 : if (r->ids) {
1302 6094 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->ids, r->count));
1303 : }
1304 : }
1305 6749 : return NDR_ERR_SUCCESS;
1306 : }
1307 :
1308 466 : _PUBLIC_ void ndr_print_samr_Ids(struct ndr_print *ndr, const char *name, const struct samr_Ids *r)
1309 : {
1310 4 : uint32_t cntr_ids_1;
1311 466 : ndr_print_struct(ndr, name, "samr_Ids");
1312 466 : if (r == NULL) { ndr_print_null(ndr); return; }
1313 466 : ndr->depth++;
1314 466 : ndr_print_uint32(ndr, "count", r->count);
1315 466 : ndr_print_ptr(ndr, "ids", r->ids);
1316 466 : ndr->depth++;
1317 466 : if (r->ids) {
1318 466 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "ids", (uint32_t)(r->count));
1319 466 : ndr->depth++;
1320 922 : for (cntr_ids_1 = 0; cntr_ids_1 < (r->count); cntr_ids_1++) {
1321 456 : ndr_print_uint32(ndr, "ids", r->ids[cntr_ids_1]);
1322 : }
1323 466 : ndr->depth--;
1324 : }
1325 466 : ndr->depth--;
1326 466 : ndr->depth--;
1327 : }
1328 :
1329 210 : static enum ndr_err_code ndr_push_samr_GroupInfoAll(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_GroupInfoAll *r)
1330 : {
1331 210 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1332 210 : if (ndr_flags & NDR_SCALARS) {
1333 105 : NDR_CHECK(ndr_push_align(ndr, 5));
1334 105 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
1335 105 : NDR_CHECK(ndr_push_security_GroupAttrs(ndr, NDR_SCALARS, r->attributes));
1336 105 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_members));
1337 105 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
1338 105 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1339 : }
1340 210 : if (ndr_flags & NDR_BUFFERS) {
1341 105 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
1342 105 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
1343 : }
1344 210 : return NDR_ERR_SUCCESS;
1345 : }
1346 :
1347 228 : static enum ndr_err_code ndr_pull_samr_GroupInfoAll(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_GroupInfoAll *r)
1348 : {
1349 228 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1350 228 : if (ndr_flags & NDR_SCALARS) {
1351 114 : NDR_CHECK(ndr_pull_align(ndr, 5));
1352 114 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
1353 114 : NDR_CHECK(ndr_pull_security_GroupAttrs(ndr, NDR_SCALARS, &r->attributes));
1354 114 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_members));
1355 114 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
1356 114 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1357 : }
1358 228 : if (ndr_flags & NDR_BUFFERS) {
1359 114 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
1360 114 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
1361 : }
1362 228 : return NDR_ERR_SUCCESS;
1363 : }
1364 :
1365 6 : _PUBLIC_ void ndr_print_samr_GroupInfoAll(struct ndr_print *ndr, const char *name, const struct samr_GroupInfoAll *r)
1366 : {
1367 6 : ndr_print_struct(ndr, name, "samr_GroupInfoAll");
1368 6 : if (r == NULL) { ndr_print_null(ndr); return; }
1369 6 : ndr->depth++;
1370 6 : ndr_print_lsa_String(ndr, "name", &r->name);
1371 6 : ndr_print_security_GroupAttrs(ndr, "attributes", r->attributes);
1372 6 : ndr_print_uint32(ndr, "num_members", r->num_members);
1373 6 : ndr_print_lsa_String(ndr, "description", &r->description);
1374 6 : ndr->depth--;
1375 : }
1376 :
1377 50 : static enum ndr_err_code ndr_push_samr_GroupInfoAttributes(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_GroupInfoAttributes *r)
1378 : {
1379 50 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1380 50 : if (ndr_flags & NDR_SCALARS) {
1381 50 : NDR_CHECK(ndr_push_align(ndr, 4));
1382 50 : NDR_CHECK(ndr_push_security_GroupAttrs(ndr, NDR_SCALARS, r->attributes));
1383 50 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
1384 : }
1385 50 : if (ndr_flags & NDR_BUFFERS) {
1386 0 : }
1387 50 : return NDR_ERR_SUCCESS;
1388 : }
1389 :
1390 56 : static enum ndr_err_code ndr_pull_samr_GroupInfoAttributes(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_GroupInfoAttributes *r)
1391 : {
1392 56 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1393 56 : if (ndr_flags & NDR_SCALARS) {
1394 56 : NDR_CHECK(ndr_pull_align(ndr, 4));
1395 56 : NDR_CHECK(ndr_pull_security_GroupAttrs(ndr, NDR_SCALARS, &r->attributes));
1396 56 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
1397 : }
1398 56 : if (ndr_flags & NDR_BUFFERS) {
1399 0 : }
1400 56 : return NDR_ERR_SUCCESS;
1401 : }
1402 :
1403 0 : _PUBLIC_ void ndr_print_samr_GroupInfoAttributes(struct ndr_print *ndr, const char *name, const struct samr_GroupInfoAttributes *r)
1404 : {
1405 0 : ndr_print_struct(ndr, name, "samr_GroupInfoAttributes");
1406 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1407 0 : ndr->depth++;
1408 0 : ndr_print_security_GroupAttrs(ndr, "attributes", r->attributes);
1409 0 : ndr->depth--;
1410 : }
1411 :
1412 539 : static enum ndr_err_code ndr_push_samr_GroupInfoEnum(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_GroupInfoEnum r)
1413 : {
1414 539 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
1415 539 : return NDR_ERR_SUCCESS;
1416 : }
1417 :
1418 241 : static enum ndr_err_code ndr_pull_samr_GroupInfoEnum(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_GroupInfoEnum *r)
1419 : {
1420 0 : uint16_t v;
1421 241 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
1422 241 : *r = v;
1423 241 : return NDR_ERR_SUCCESS;
1424 : }
1425 :
1426 0 : _PUBLIC_ void ndr_print_samr_GroupInfoEnum(struct ndr_print *ndr, const char *name, enum samr_GroupInfoEnum r)
1427 : {
1428 0 : const char *val = NULL;
1429 :
1430 0 : switch (r) {
1431 0 : case GROUPINFOALL: val = "GROUPINFOALL"; break;
1432 0 : case GROUPINFONAME: val = "GROUPINFONAME"; break;
1433 0 : case GROUPINFOATTRIBUTES: val = "GROUPINFOATTRIBUTES"; break;
1434 0 : case GROUPINFODESCRIPTION: val = "GROUPINFODESCRIPTION"; break;
1435 0 : case GROUPINFOALL2: val = "GROUPINFOALL2"; break;
1436 : }
1437 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
1438 0 : }
1439 :
1440 252 : static enum ndr_err_code ndr_push_samr_GroupInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_GroupInfo *r)
1441 : {
1442 0 : uint32_t level;
1443 252 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1444 252 : if (ndr_flags & NDR_SCALARS) {
1445 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1446 252 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1447 252 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1448 252 : NDR_CHECK(ndr_push_samr_GroupInfoEnum(ndr, NDR_SCALARS, level));
1449 252 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1450 252 : switch (level) {
1451 51 : case GROUPINFOALL: {
1452 51 : NDR_CHECK(ndr_push_samr_GroupInfoAll(ndr, NDR_SCALARS, &r->all));
1453 51 : break; }
1454 :
1455 49 : case GROUPINFONAME: {
1456 49 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
1457 49 : break; }
1458 :
1459 50 : case GROUPINFOATTRIBUTES: {
1460 50 : NDR_CHECK(ndr_push_samr_GroupInfoAttributes(ndr, NDR_SCALARS, &r->attributes));
1461 50 : break; }
1462 :
1463 48 : case GROUPINFODESCRIPTION: {
1464 48 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
1465 48 : break; }
1466 :
1467 54 : case GROUPINFOALL2: {
1468 54 : NDR_CHECK(ndr_push_samr_GroupInfoAll(ndr, NDR_SCALARS, &r->all2));
1469 54 : break; }
1470 :
1471 0 : default:
1472 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
1473 : }
1474 : }
1475 252 : if (ndr_flags & NDR_BUFFERS) {
1476 252 : if (!(ndr_flags & NDR_SCALARS)) {
1477 : /* We didn't get it above, and the token is not needed after this. */
1478 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1479 : }
1480 252 : switch (level) {
1481 51 : case GROUPINFOALL:
1482 51 : NDR_CHECK(ndr_push_samr_GroupInfoAll(ndr, NDR_BUFFERS, &r->all));
1483 51 : break;
1484 :
1485 49 : case GROUPINFONAME:
1486 49 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
1487 49 : break;
1488 :
1489 50 : case GROUPINFOATTRIBUTES:
1490 50 : break;
1491 :
1492 48 : case GROUPINFODESCRIPTION:
1493 48 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
1494 48 : break;
1495 :
1496 54 : case GROUPINFOALL2:
1497 54 : NDR_CHECK(ndr_push_samr_GroupInfoAll(ndr, NDR_BUFFERS, &r->all2));
1498 54 : break;
1499 :
1500 0 : default:
1501 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
1502 : }
1503 : }
1504 252 : return NDR_ERR_SUCCESS;
1505 : }
1506 :
1507 279 : static enum ndr_err_code ndr_pull_samr_GroupInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_GroupInfo *r)
1508 : {
1509 0 : uint32_t level;
1510 0 : uint16_t _level;
1511 279 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1512 279 : if (ndr_flags & NDR_SCALARS) {
1513 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1514 279 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1515 279 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1516 279 : NDR_CHECK(ndr_pull_uint1632(ndr, NDR_SCALARS, &_level));
1517 279 : if (_level != level) {
1518 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
1519 : }
1520 279 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1521 279 : switch (level) {
1522 56 : case GROUPINFOALL: {
1523 56 : NDR_CHECK(ndr_pull_samr_GroupInfoAll(ndr, NDR_SCALARS, &r->all));
1524 56 : break; }
1525 :
1526 55 : case GROUPINFONAME: {
1527 55 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
1528 55 : break; }
1529 :
1530 56 : case GROUPINFOATTRIBUTES: {
1531 56 : NDR_CHECK(ndr_pull_samr_GroupInfoAttributes(ndr, NDR_SCALARS, &r->attributes));
1532 56 : break; }
1533 :
1534 54 : case GROUPINFODESCRIPTION: {
1535 54 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
1536 54 : break; }
1537 :
1538 58 : case GROUPINFOALL2: {
1539 58 : NDR_CHECK(ndr_pull_samr_GroupInfoAll(ndr, NDR_SCALARS, &r->all2));
1540 58 : break; }
1541 :
1542 0 : default:
1543 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
1544 : }
1545 : }
1546 279 : if (ndr_flags & NDR_BUFFERS) {
1547 279 : if (!(ndr_flags & NDR_SCALARS)) {
1548 : /* We didn't get it above, and the token is not needed after this. */
1549 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1550 : }
1551 279 : switch (level) {
1552 56 : case GROUPINFOALL:
1553 56 : NDR_CHECK(ndr_pull_samr_GroupInfoAll(ndr, NDR_BUFFERS, &r->all));
1554 56 : break;
1555 :
1556 55 : case GROUPINFONAME:
1557 55 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
1558 55 : break;
1559 :
1560 56 : case GROUPINFOATTRIBUTES:
1561 56 : break;
1562 :
1563 54 : case GROUPINFODESCRIPTION:
1564 54 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
1565 54 : break;
1566 :
1567 58 : case GROUPINFOALL2:
1568 58 : NDR_CHECK(ndr_pull_samr_GroupInfoAll(ndr, NDR_BUFFERS, &r->all2));
1569 58 : break;
1570 :
1571 0 : default:
1572 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
1573 : }
1574 : }
1575 279 : return NDR_ERR_SUCCESS;
1576 : }
1577 :
1578 6 : _PUBLIC_ void ndr_print_samr_GroupInfo(struct ndr_print *ndr, const char *name, const union samr_GroupInfo *r)
1579 : {
1580 0 : uint32_t level;
1581 6 : level = ndr_print_steal_switch_value(ndr, r);
1582 6 : ndr_print_union(ndr, name, level, "samr_GroupInfo");
1583 6 : switch (level) {
1584 2 : case GROUPINFOALL:
1585 2 : ndr_print_samr_GroupInfoAll(ndr, "all", &r->all);
1586 2 : break;
1587 :
1588 0 : case GROUPINFONAME:
1589 0 : ndr_print_lsa_String(ndr, "name", &r->name);
1590 0 : break;
1591 :
1592 0 : case GROUPINFOATTRIBUTES:
1593 0 : ndr_print_samr_GroupInfoAttributes(ndr, "attributes", &r->attributes);
1594 0 : break;
1595 :
1596 0 : case GROUPINFODESCRIPTION:
1597 0 : ndr_print_lsa_String(ndr, "description", &r->description);
1598 0 : break;
1599 :
1600 4 : case GROUPINFOALL2:
1601 4 : ndr_print_samr_GroupInfoAll(ndr, "all2", &r->all2);
1602 4 : break;
1603 :
1604 0 : default:
1605 0 : ndr_print_bad_level(ndr, name, level);
1606 : }
1607 6 : }
1608 :
1609 496 : static enum ndr_err_code ndr_push_samr_RidAttrArray(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_RidAttrArray *r)
1610 : {
1611 0 : uint32_t cntr_rids_1;
1612 0 : uint32_t cntr_attributes_1;
1613 496 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1614 496 : if (ndr_flags & NDR_SCALARS) {
1615 496 : NDR_CHECK(ndr_push_align(ndr, 5));
1616 496 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
1617 496 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->rids));
1618 496 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->attributes));
1619 496 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1620 : }
1621 496 : if (ndr_flags & NDR_BUFFERS) {
1622 496 : if (r->rids) {
1623 123 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
1624 256 : for (cntr_rids_1 = 0; cntr_rids_1 < (r->count); cntr_rids_1++) {
1625 133 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rids[cntr_rids_1]));
1626 : }
1627 : }
1628 496 : if (r->attributes) {
1629 123 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
1630 256 : for (cntr_attributes_1 = 0; cntr_attributes_1 < (r->count); cntr_attributes_1++) {
1631 133 : NDR_CHECK(ndr_push_security_GroupAttrs(ndr, NDR_SCALARS, r->attributes[cntr_attributes_1]));
1632 : }
1633 : }
1634 : }
1635 496 : return NDR_ERR_SUCCESS;
1636 : }
1637 :
1638 491 : static enum ndr_err_code ndr_pull_samr_RidAttrArray(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_RidAttrArray *r)
1639 : {
1640 0 : uint32_t _ptr_rids;
1641 491 : uint32_t size_rids_1 = 0;
1642 0 : uint32_t cntr_rids_1;
1643 491 : TALLOC_CTX *_mem_save_rids_0 = NULL;
1644 491 : TALLOC_CTX *_mem_save_rids_1 = NULL;
1645 0 : uint32_t _ptr_attributes;
1646 491 : uint32_t size_attributes_1 = 0;
1647 0 : uint32_t cntr_attributes_1;
1648 491 : TALLOC_CTX *_mem_save_attributes_0 = NULL;
1649 491 : TALLOC_CTX *_mem_save_attributes_1 = NULL;
1650 491 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1651 491 : if (ndr_flags & NDR_SCALARS) {
1652 491 : NDR_CHECK(ndr_pull_align(ndr, 5));
1653 491 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
1654 491 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_rids));
1655 491 : if (_ptr_rids) {
1656 122 : NDR_PULL_ALLOC(ndr, r->rids);
1657 : } else {
1658 369 : r->rids = NULL;
1659 : }
1660 491 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_attributes));
1661 491 : if (_ptr_attributes) {
1662 122 : NDR_PULL_ALLOC(ndr, r->attributes);
1663 : } else {
1664 369 : r->attributes = NULL;
1665 : }
1666 491 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1667 : }
1668 491 : if (ndr_flags & NDR_BUFFERS) {
1669 491 : if (r->rids) {
1670 122 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1671 122 : NDR_PULL_SET_MEM_CTX(ndr, r->rids, 0);
1672 122 : NDR_CHECK(ndr_pull_array_size(ndr, &r->rids));
1673 122 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->rids, &size_rids_1));
1674 122 : NDR_PULL_ALLOC_N(ndr, r->rids, size_rids_1);
1675 122 : _mem_save_rids_1 = NDR_PULL_GET_MEM_CTX(ndr);
1676 122 : NDR_PULL_SET_MEM_CTX(ndr, r->rids, 0);
1677 264 : for (cntr_rids_1 = 0; cntr_rids_1 < (size_rids_1); cntr_rids_1++) {
1678 142 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rids[cntr_rids_1]));
1679 : }
1680 122 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_1, 0);
1681 122 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, 0);
1682 : }
1683 491 : if (r->attributes) {
1684 122 : _mem_save_attributes_0 = NDR_PULL_GET_MEM_CTX(ndr);
1685 122 : NDR_PULL_SET_MEM_CTX(ndr, r->attributes, 0);
1686 122 : NDR_CHECK(ndr_pull_array_size(ndr, &r->attributes));
1687 122 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->attributes, &size_attributes_1));
1688 122 : NDR_PULL_ALLOC_N(ndr, r->attributes, size_attributes_1);
1689 122 : _mem_save_attributes_1 = NDR_PULL_GET_MEM_CTX(ndr);
1690 122 : NDR_PULL_SET_MEM_CTX(ndr, r->attributes, 0);
1691 264 : for (cntr_attributes_1 = 0; cntr_attributes_1 < (size_attributes_1); cntr_attributes_1++) {
1692 142 : NDR_CHECK(ndr_pull_security_GroupAttrs(ndr, NDR_SCALARS, &r->attributes[cntr_attributes_1]));
1693 : }
1694 122 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_attributes_1, 0);
1695 122 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_attributes_0, 0);
1696 : }
1697 491 : if (r->rids) {
1698 122 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->rids, r->count));
1699 : }
1700 491 : if (r->attributes) {
1701 122 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->attributes, r->count));
1702 : }
1703 : }
1704 491 : return NDR_ERR_SUCCESS;
1705 : }
1706 :
1707 26 : _PUBLIC_ void ndr_print_samr_RidAttrArray(struct ndr_print *ndr, const char *name, const struct samr_RidAttrArray *r)
1708 : {
1709 0 : uint32_t cntr_rids_1;
1710 0 : uint32_t cntr_attributes_1;
1711 26 : ndr_print_struct(ndr, name, "samr_RidAttrArray");
1712 26 : if (r == NULL) { ndr_print_null(ndr); return; }
1713 26 : ndr->depth++;
1714 26 : ndr_print_uint32(ndr, "count", r->count);
1715 26 : ndr_print_ptr(ndr, "rids", r->rids);
1716 26 : ndr->depth++;
1717 26 : if (r->rids) {
1718 10 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "rids", (uint32_t)(r->count));
1719 10 : ndr->depth++;
1720 20 : for (cntr_rids_1 = 0; cntr_rids_1 < (r->count); cntr_rids_1++) {
1721 10 : ndr_print_uint32(ndr, "rids", r->rids[cntr_rids_1]);
1722 : }
1723 10 : ndr->depth--;
1724 : }
1725 26 : ndr->depth--;
1726 26 : ndr_print_ptr(ndr, "attributes", r->attributes);
1727 26 : ndr->depth++;
1728 26 : if (r->attributes) {
1729 10 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "attributes", (uint32_t)(r->count));
1730 10 : ndr->depth++;
1731 20 : for (cntr_attributes_1 = 0; cntr_attributes_1 < (r->count); cntr_attributes_1++) {
1732 10 : ndr_print_security_GroupAttrs(ndr, "attributes", r->attributes[cntr_attributes_1]);
1733 : }
1734 10 : ndr->depth--;
1735 : }
1736 26 : ndr->depth--;
1737 26 : ndr->depth--;
1738 : }
1739 :
1740 164 : static enum ndr_err_code ndr_push_samr_AliasInfoAll(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_AliasInfoAll *r)
1741 : {
1742 164 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1743 164 : if (ndr_flags & NDR_SCALARS) {
1744 82 : NDR_CHECK(ndr_push_align(ndr, 5));
1745 82 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
1746 82 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_members));
1747 82 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
1748 82 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1749 : }
1750 164 : if (ndr_flags & NDR_BUFFERS) {
1751 82 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
1752 82 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
1753 : }
1754 164 : return NDR_ERR_SUCCESS;
1755 : }
1756 :
1757 184 : static enum ndr_err_code ndr_pull_samr_AliasInfoAll(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_AliasInfoAll *r)
1758 : {
1759 184 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1760 184 : if (ndr_flags & NDR_SCALARS) {
1761 92 : NDR_CHECK(ndr_pull_align(ndr, 5));
1762 92 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
1763 92 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_members));
1764 92 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
1765 92 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1766 : }
1767 184 : if (ndr_flags & NDR_BUFFERS) {
1768 92 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
1769 92 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
1770 : }
1771 184 : return NDR_ERR_SUCCESS;
1772 : }
1773 :
1774 0 : _PUBLIC_ void ndr_print_samr_AliasInfoAll(struct ndr_print *ndr, const char *name, const struct samr_AliasInfoAll *r)
1775 : {
1776 0 : ndr_print_struct(ndr, name, "samr_AliasInfoAll");
1777 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1778 0 : ndr->depth++;
1779 0 : ndr_print_lsa_String(ndr, "name", &r->name);
1780 0 : ndr_print_uint32(ndr, "num_members", r->num_members);
1781 0 : ndr_print_lsa_String(ndr, "description", &r->description);
1782 0 : ndr->depth--;
1783 : }
1784 :
1785 558 : static enum ndr_err_code ndr_push_samr_AliasInfoEnum(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_AliasInfoEnum r)
1786 : {
1787 558 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
1788 558 : return NDR_ERR_SUCCESS;
1789 : }
1790 :
1791 258 : static enum ndr_err_code ndr_pull_samr_AliasInfoEnum(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_AliasInfoEnum *r)
1792 : {
1793 0 : uint16_t v;
1794 258 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
1795 258 : *r = v;
1796 258 : return NDR_ERR_SUCCESS;
1797 : }
1798 :
1799 0 : _PUBLIC_ void ndr_print_samr_AliasInfoEnum(struct ndr_print *ndr, const char *name, enum samr_AliasInfoEnum r)
1800 : {
1801 0 : const char *val = NULL;
1802 :
1803 0 : switch (r) {
1804 0 : case ALIASINFOALL: val = "ALIASINFOALL"; break;
1805 0 : case ALIASINFONAME: val = "ALIASINFONAME"; break;
1806 0 : case ALIASINFODESCRIPTION: val = "ALIASINFODESCRIPTION"; break;
1807 : }
1808 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
1809 0 : }
1810 :
1811 262 : static enum ndr_err_code ndr_push_samr_AliasInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_AliasInfo *r)
1812 : {
1813 0 : uint32_t level;
1814 262 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1815 262 : if (ndr_flags & NDR_SCALARS) {
1816 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1817 262 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1818 262 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1819 262 : NDR_CHECK(ndr_push_samr_AliasInfoEnum(ndr, NDR_SCALARS, level));
1820 262 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1821 262 : switch (level) {
1822 82 : case ALIASINFOALL: {
1823 82 : NDR_CHECK(ndr_push_samr_AliasInfoAll(ndr, NDR_SCALARS, &r->all));
1824 82 : break; }
1825 :
1826 90 : case ALIASINFONAME: {
1827 90 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->name));
1828 90 : break; }
1829 :
1830 90 : case ALIASINFODESCRIPTION: {
1831 90 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
1832 90 : break; }
1833 :
1834 0 : default:
1835 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
1836 : }
1837 : }
1838 262 : if (ndr_flags & NDR_BUFFERS) {
1839 262 : if (!(ndr_flags & NDR_SCALARS)) {
1840 : /* We didn't get it above, and the token is not needed after this. */
1841 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1842 : }
1843 262 : switch (level) {
1844 82 : case ALIASINFOALL:
1845 82 : NDR_CHECK(ndr_push_samr_AliasInfoAll(ndr, NDR_BUFFERS, &r->all));
1846 82 : break;
1847 :
1848 90 : case ALIASINFONAME:
1849 90 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->name));
1850 90 : break;
1851 :
1852 90 : case ALIASINFODESCRIPTION:
1853 90 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
1854 90 : break;
1855 :
1856 0 : default:
1857 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
1858 : }
1859 : }
1860 262 : return NDR_ERR_SUCCESS;
1861 : }
1862 :
1863 292 : static enum ndr_err_code ndr_pull_samr_AliasInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_AliasInfo *r)
1864 : {
1865 0 : uint32_t level;
1866 0 : uint16_t _level;
1867 292 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1868 292 : if (ndr_flags & NDR_SCALARS) {
1869 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1870 292 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1871 292 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1872 292 : NDR_CHECK(ndr_pull_uint1632(ndr, NDR_SCALARS, &_level));
1873 292 : if (_level != level) {
1874 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
1875 : }
1876 292 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1877 292 : switch (level) {
1878 92 : case ALIASINFOALL: {
1879 92 : NDR_CHECK(ndr_pull_samr_AliasInfoAll(ndr, NDR_SCALARS, &r->all));
1880 92 : break; }
1881 :
1882 100 : case ALIASINFONAME: {
1883 100 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->name));
1884 100 : break; }
1885 :
1886 100 : case ALIASINFODESCRIPTION: {
1887 100 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
1888 100 : break; }
1889 :
1890 0 : default:
1891 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
1892 : }
1893 : }
1894 292 : if (ndr_flags & NDR_BUFFERS) {
1895 292 : if (!(ndr_flags & NDR_SCALARS)) {
1896 : /* We didn't get it above, and the token is not needed after this. */
1897 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1898 : }
1899 292 : switch (level) {
1900 92 : case ALIASINFOALL:
1901 92 : NDR_CHECK(ndr_pull_samr_AliasInfoAll(ndr, NDR_BUFFERS, &r->all));
1902 92 : break;
1903 :
1904 100 : case ALIASINFONAME:
1905 100 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->name));
1906 100 : break;
1907 :
1908 100 : case ALIASINFODESCRIPTION:
1909 100 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
1910 100 : break;
1911 :
1912 0 : default:
1913 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
1914 : }
1915 : }
1916 292 : return NDR_ERR_SUCCESS;
1917 : }
1918 :
1919 0 : _PUBLIC_ void ndr_print_samr_AliasInfo(struct ndr_print *ndr, const char *name, const union samr_AliasInfo *r)
1920 : {
1921 0 : uint32_t level;
1922 0 : level = ndr_print_steal_switch_value(ndr, r);
1923 0 : ndr_print_union(ndr, name, level, "samr_AliasInfo");
1924 0 : switch (level) {
1925 0 : case ALIASINFOALL:
1926 0 : ndr_print_samr_AliasInfoAll(ndr, "all", &r->all);
1927 0 : break;
1928 :
1929 0 : case ALIASINFONAME:
1930 0 : ndr_print_lsa_String(ndr, "name", &r->name);
1931 0 : break;
1932 :
1933 0 : case ALIASINFODESCRIPTION:
1934 0 : ndr_print_lsa_String(ndr, "description", &r->description);
1935 0 : break;
1936 :
1937 0 : default:
1938 0 : ndr_print_bad_level(ndr, name, level);
1939 : }
1940 0 : }
1941 :
1942 18767 : static enum ndr_err_code ndr_push_samr_UserInfoLevel(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_UserInfoLevel r)
1943 : {
1944 18767 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
1945 18497 : return NDR_ERR_SUCCESS;
1946 : }
1947 :
1948 17097 : static enum ndr_err_code ndr_pull_samr_UserInfoLevel(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_UserInfoLevel *r)
1949 : {
1950 278 : uint16_t v;
1951 17097 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
1952 17097 : *r = v;
1953 17097 : return NDR_ERR_SUCCESS;
1954 : }
1955 :
1956 8 : _PUBLIC_ void ndr_print_samr_UserInfoLevel(struct ndr_print *ndr, const char *name, enum samr_UserInfoLevel r)
1957 : {
1958 8 : const char *val = NULL;
1959 :
1960 8 : switch (r) {
1961 0 : case UserGeneralInformation: val = "UserGeneralInformation"; break;
1962 0 : case UserPreferencesInformation: val = "UserPreferencesInformation"; break;
1963 0 : case UserLogonInformation: val = "UserLogonInformation"; break;
1964 0 : case UserLogonHoursInformation: val = "UserLogonHoursInformation"; break;
1965 0 : case UserAccountInformation: val = "UserAccountInformation"; break;
1966 0 : case UserNameInformation: val = "UserNameInformation"; break;
1967 0 : case UserAccountNameInformation: val = "UserAccountNameInformation"; break;
1968 0 : case UserFullNameInformation: val = "UserFullNameInformation"; break;
1969 0 : case UserPrimaryGroupInformation: val = "UserPrimaryGroupInformation"; break;
1970 0 : case UserHomeInformation: val = "UserHomeInformation"; break;
1971 0 : case UserScriptInformation: val = "UserScriptInformation"; break;
1972 0 : case UserProfileInformation: val = "UserProfileInformation"; break;
1973 0 : case UserAdminCommentInformation: val = "UserAdminCommentInformation"; break;
1974 0 : case UserWorkStationsInformation: val = "UserWorkStationsInformation"; break;
1975 6 : case UserControlInformation: val = "UserControlInformation"; break;
1976 0 : case UserExpiresInformation: val = "UserExpiresInformation"; break;
1977 0 : case UserInternal1Information: val = "UserInternal1Information"; break;
1978 0 : case UserParametersInformation: val = "UserParametersInformation"; break;
1979 0 : case UserAllInformation: val = "UserAllInformation"; break;
1980 0 : case UserInternal4Information: val = "UserInternal4Information"; break;
1981 0 : case UserInternal5Information: val = "UserInternal5Information"; break;
1982 0 : case UserInternal4InformationNew: val = "UserInternal4InformationNew"; break;
1983 2 : case UserInternal5InformationNew: val = "UserInternal5InformationNew"; break;
1984 0 : case UserInternal7InformationNew: val = "UserInternal7InformationNew"; break;
1985 0 : case UserInternal8InformationNew: val = "UserInternal8InformationNew"; break;
1986 : }
1987 8 : ndr_print_enum(ndr, name, "ENUM", val, r);
1988 8 : }
1989 :
1990 614 : static enum ndr_err_code ndr_push_samr_UserInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo1 *r)
1991 : {
1992 614 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1993 614 : if (ndr_flags & NDR_SCALARS) {
1994 307 : NDR_CHECK(ndr_push_align(ndr, 5));
1995 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
1996 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->full_name));
1997 307 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->primary_gid));
1998 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
1999 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->comment));
2000 307 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2001 : }
2002 614 : if (ndr_flags & NDR_BUFFERS) {
2003 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2004 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2005 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
2006 307 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->comment));
2007 : }
2008 614 : return NDR_ERR_SUCCESS;
2009 : }
2010 :
2011 606 : static enum ndr_err_code ndr_pull_samr_UserInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo1 *r)
2012 : {
2013 606 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2014 606 : if (ndr_flags & NDR_SCALARS) {
2015 303 : NDR_CHECK(ndr_pull_align(ndr, 5));
2016 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2017 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2018 303 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->primary_gid));
2019 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
2020 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->comment));
2021 303 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2022 : }
2023 606 : if (ndr_flags & NDR_BUFFERS) {
2024 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2025 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2026 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
2027 303 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->comment));
2028 : }
2029 606 : return NDR_ERR_SUCCESS;
2030 : }
2031 :
2032 40 : _PUBLIC_ void ndr_print_samr_UserInfo1(struct ndr_print *ndr, const char *name, const struct samr_UserInfo1 *r)
2033 : {
2034 40 : ndr_print_struct(ndr, name, "samr_UserInfo1");
2035 40 : if (r == NULL) { ndr_print_null(ndr); return; }
2036 40 : ndr->depth++;
2037 40 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
2038 40 : ndr_print_lsa_String(ndr, "full_name", &r->full_name);
2039 40 : ndr_print_uint32(ndr, "primary_gid", r->primary_gid);
2040 40 : ndr_print_lsa_String(ndr, "description", &r->description);
2041 40 : ndr_print_lsa_String(ndr, "comment", &r->comment);
2042 40 : ndr->depth--;
2043 : }
2044 :
2045 862 : static enum ndr_err_code ndr_push_samr_UserInfo2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo2 *r)
2046 : {
2047 862 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2048 862 : if (ndr_flags & NDR_SCALARS) {
2049 431 : NDR_CHECK(ndr_push_align(ndr, 5));
2050 431 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->comment));
2051 431 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->reserved));
2052 431 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->country_code));
2053 431 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->code_page));
2054 431 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2055 : }
2056 862 : if (ndr_flags & NDR_BUFFERS) {
2057 431 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->comment));
2058 431 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->reserved));
2059 : }
2060 862 : return NDR_ERR_SUCCESS;
2061 : }
2062 :
2063 860 : static enum ndr_err_code ndr_pull_samr_UserInfo2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo2 *r)
2064 : {
2065 860 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2066 860 : if (ndr_flags & NDR_SCALARS) {
2067 430 : NDR_CHECK(ndr_pull_align(ndr, 5));
2068 430 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->comment));
2069 430 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->reserved));
2070 430 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->country_code));
2071 430 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->code_page));
2072 430 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2073 : }
2074 860 : if (ndr_flags & NDR_BUFFERS) {
2075 430 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->comment));
2076 430 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->reserved));
2077 : }
2078 860 : return NDR_ERR_SUCCESS;
2079 : }
2080 :
2081 18 : _PUBLIC_ void ndr_print_samr_UserInfo2(struct ndr_print *ndr, const char *name, const struct samr_UserInfo2 *r)
2082 : {
2083 18 : ndr_print_struct(ndr, name, "samr_UserInfo2");
2084 18 : if (r == NULL) { ndr_print_null(ndr); return; }
2085 18 : ndr->depth++;
2086 18 : ndr_print_lsa_String(ndr, "comment", &r->comment);
2087 18 : ndr_print_lsa_String(ndr, "reserved", &r->reserved);
2088 18 : ndr_print_uint16(ndr, "country_code", r->country_code);
2089 18 : ndr_print_uint16(ndr, "code_page", r->code_page);
2090 18 : ndr->depth--;
2091 : }
2092 :
2093 19498 : _PUBLIC_ enum ndr_err_code ndr_push_samr_LogonHours(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_LogonHours *r)
2094 : {
2095 : {
2096 19498 : libndr_flags _flags_save_STRUCT = ndr->flags;
2097 19498 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2098 19498 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2099 19498 : if (ndr_flags & NDR_SCALARS) {
2100 9749 : NDR_CHECK(ndr_push_align(ndr, 5));
2101 9749 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->units_per_week));
2102 9749 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->bits));
2103 9749 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2104 : }
2105 19498 : if (ndr_flags & NDR_BUFFERS) {
2106 9749 : if (r->bits) {
2107 6924 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 1260));
2108 6924 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
2109 6924 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->units_per_week / 8));
2110 6924 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->bits, r->units_per_week / 8));
2111 : }
2112 : }
2113 19498 : ndr->flags = _flags_save_STRUCT;
2114 : }
2115 19498 : return NDR_ERR_SUCCESS;
2116 : }
2117 :
2118 20340 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_LogonHours(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_LogonHours *r)
2119 : {
2120 360 : uint32_t _ptr_bits;
2121 20340 : uint32_t size_bits_1 = 0;
2122 20340 : uint32_t length_bits_1 = 0;
2123 20340 : TALLOC_CTX *_mem_save_bits_0 = NULL;
2124 : {
2125 20340 : libndr_flags _flags_save_STRUCT = ndr->flags;
2126 20340 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2127 20340 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2128 20340 : if (ndr_flags & NDR_SCALARS) {
2129 10170 : NDR_CHECK(ndr_pull_align(ndr, 5));
2130 10170 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->units_per_week));
2131 10170 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_bits));
2132 10170 : if (_ptr_bits) {
2133 7637 : NDR_PULL_ALLOC(ndr, r->bits);
2134 : } else {
2135 2533 : r->bits = NULL;
2136 : }
2137 10170 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2138 : }
2139 20340 : if (ndr_flags & NDR_BUFFERS) {
2140 10170 : if (r->bits) {
2141 7637 : _mem_save_bits_0 = NDR_PULL_GET_MEM_CTX(ndr);
2142 7637 : NDR_PULL_SET_MEM_CTX(ndr, r->bits, 0);
2143 7637 : NDR_CHECK(ndr_pull_array_size(ndr, &r->bits));
2144 7637 : NDR_CHECK(ndr_pull_array_length(ndr, &r->bits));
2145 7637 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->bits, &size_bits_1));
2146 7637 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->bits, &length_bits_1));
2147 7637 : if (length_bits_1 > size_bits_1) {
2148 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_bits_1, length_bits_1);
2149 : }
2150 7637 : NDR_PULL_ALLOC_N(ndr, r->bits, size_bits_1);
2151 7637 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->bits, length_bits_1));
2152 7637 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_bits_0, 0);
2153 : }
2154 10170 : if (r->bits) {
2155 7637 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->bits, 1260));
2156 : }
2157 10170 : if (r->bits) {
2158 7637 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->bits, r->units_per_week / 8));
2159 : }
2160 : }
2161 20340 : ndr->flags = _flags_save_STRUCT;
2162 : }
2163 20340 : return NDR_ERR_SUCCESS;
2164 : }
2165 :
2166 0 : static void ndr_print_flags_samr_LogonHours(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct samr_LogonHours *r)
2167 : {
2168 0 : ndr_print_samr_LogonHours(ndr, name, r);
2169 0 : }
2170 :
2171 90 : _PUBLIC_ void ndr_print_samr_LogonHours(struct ndr_print *ndr, const char *name, const struct samr_LogonHours *r)
2172 : {
2173 90 : ndr_print_struct(ndr, name, "samr_LogonHours");
2174 90 : if (r == NULL) { ndr_print_null(ndr); return; }
2175 : {
2176 90 : libndr_flags _flags_save_STRUCT = ndr->flags;
2177 90 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2178 90 : ndr->depth++;
2179 90 : ndr_print_uint16(ndr, "units_per_week", r->units_per_week);
2180 90 : ndr_print_ptr(ndr, "bits", r->bits);
2181 90 : ndr->depth++;
2182 90 : if (r->bits) {
2183 90 : ndr_print_array_uint8(ndr, "bits", r->bits, r->units_per_week / 8);
2184 : }
2185 90 : ndr->depth--;
2186 90 : ndr->depth--;
2187 90 : ndr->flags = _flags_save_STRUCT;
2188 : }
2189 : }
2190 :
2191 2992 : static enum ndr_err_code ndr_push_samr_UserInfo3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo3 *r)
2192 : {
2193 2992 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2194 2992 : if (ndr_flags & NDR_SCALARS) {
2195 1496 : NDR_CHECK(ndr_push_align(ndr, 5));
2196 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2197 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2198 1496 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
2199 1496 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->primary_gid));
2200 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
2201 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
2202 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
2203 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
2204 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->workstations));
2205 1496 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_logon));
2206 1496 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_logoff));
2207 1496 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_password_change));
2208 1496 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->allow_password_change));
2209 1496 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->force_password_change));
2210 1496 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
2211 1496 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->bad_password_count));
2212 1496 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->logon_count));
2213 1496 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->acct_flags));
2214 1496 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2215 : }
2216 2992 : if (ndr_flags & NDR_BUFFERS) {
2217 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2218 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2219 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
2220 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
2221 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
2222 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
2223 1496 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
2224 1496 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
2225 : }
2226 2992 : return NDR_ERR_SUCCESS;
2227 : }
2228 :
2229 3372 : static enum ndr_err_code ndr_pull_samr_UserInfo3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo3 *r)
2230 : {
2231 3372 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2232 3372 : if (ndr_flags & NDR_SCALARS) {
2233 1686 : NDR_CHECK(ndr_pull_align(ndr, 5));
2234 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2235 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2236 1686 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
2237 1686 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->primary_gid));
2238 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
2239 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
2240 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
2241 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
2242 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->workstations));
2243 1686 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_logon));
2244 1686 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_logoff));
2245 1686 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_password_change));
2246 1686 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->allow_password_change));
2247 1686 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->force_password_change));
2248 1686 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
2249 1686 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->bad_password_count));
2250 1686 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->logon_count));
2251 1686 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->acct_flags));
2252 1686 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2253 : }
2254 3372 : if (ndr_flags & NDR_BUFFERS) {
2255 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2256 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2257 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
2258 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
2259 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
2260 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
2261 1686 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
2262 1686 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
2263 : }
2264 3372 : return NDR_ERR_SUCCESS;
2265 : }
2266 :
2267 0 : _PUBLIC_ void ndr_print_samr_UserInfo3(struct ndr_print *ndr, const char *name, const struct samr_UserInfo3 *r)
2268 : {
2269 0 : ndr_print_struct(ndr, name, "samr_UserInfo3");
2270 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2271 0 : ndr->depth++;
2272 0 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
2273 0 : ndr_print_lsa_String(ndr, "full_name", &r->full_name);
2274 0 : ndr_print_uint32(ndr, "rid", r->rid);
2275 0 : ndr_print_uint32(ndr, "primary_gid", r->primary_gid);
2276 0 : ndr_print_lsa_String(ndr, "home_directory", &r->home_directory);
2277 0 : ndr_print_lsa_String(ndr, "home_drive", &r->home_drive);
2278 0 : ndr_print_lsa_String(ndr, "logon_script", &r->logon_script);
2279 0 : ndr_print_lsa_String(ndr, "profile_path", &r->profile_path);
2280 0 : ndr_print_lsa_String(ndr, "workstations", &r->workstations);
2281 0 : ndr_print_NTTIME(ndr, "last_logon", r->last_logon);
2282 0 : ndr_print_NTTIME(ndr, "last_logoff", r->last_logoff);
2283 0 : ndr_print_NTTIME(ndr, "last_password_change", r->last_password_change);
2284 0 : ndr_print_NTTIME(ndr, "allow_password_change", r->allow_password_change);
2285 0 : ndr_print_NTTIME(ndr, "force_password_change", r->force_password_change);
2286 0 : ndr_print_samr_LogonHours(ndr, "logon_hours", &r->logon_hours);
2287 0 : ndr_print_uint16(ndr, "bad_password_count", r->bad_password_count);
2288 0 : ndr_print_uint16(ndr, "logon_count", r->logon_count);
2289 0 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->acct_flags);
2290 0 : ndr->depth--;
2291 : }
2292 :
2293 516 : static enum ndr_err_code ndr_push_samr_UserInfo4(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo4 *r)
2294 : {
2295 516 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2296 516 : if (ndr_flags & NDR_SCALARS) {
2297 258 : NDR_CHECK(ndr_push_align(ndr, 5));
2298 258 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
2299 258 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2300 : }
2301 516 : if (ndr_flags & NDR_BUFFERS) {
2302 258 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
2303 : }
2304 516 : return NDR_ERR_SUCCESS;
2305 : }
2306 :
2307 532 : static enum ndr_err_code ndr_pull_samr_UserInfo4(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo4 *r)
2308 : {
2309 532 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2310 532 : if (ndr_flags & NDR_SCALARS) {
2311 266 : NDR_CHECK(ndr_pull_align(ndr, 5));
2312 266 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
2313 266 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2314 : }
2315 532 : if (ndr_flags & NDR_BUFFERS) {
2316 266 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
2317 : }
2318 532 : return NDR_ERR_SUCCESS;
2319 : }
2320 :
2321 0 : _PUBLIC_ void ndr_print_samr_UserInfo4(struct ndr_print *ndr, const char *name, const struct samr_UserInfo4 *r)
2322 : {
2323 0 : ndr_print_struct(ndr, name, "samr_UserInfo4");
2324 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2325 0 : ndr->depth++;
2326 0 : ndr_print_samr_LogonHours(ndr, "logon_hours", &r->logon_hours);
2327 0 : ndr->depth--;
2328 : }
2329 :
2330 3472 : static enum ndr_err_code ndr_push_samr_UserInfo5(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo5 *r)
2331 : {
2332 3472 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2333 3472 : if (ndr_flags & NDR_SCALARS) {
2334 1736 : NDR_CHECK(ndr_push_align(ndr, 5));
2335 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2336 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2337 1736 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
2338 1736 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->primary_gid));
2339 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
2340 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
2341 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
2342 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
2343 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
2344 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->workstations));
2345 1736 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_logon));
2346 1736 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_logoff));
2347 1736 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
2348 1736 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->bad_password_count));
2349 1736 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->logon_count));
2350 1736 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_password_change));
2351 1736 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->acct_expiry));
2352 1736 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->acct_flags));
2353 1736 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2354 : }
2355 3472 : if (ndr_flags & NDR_BUFFERS) {
2356 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2357 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2358 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
2359 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
2360 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
2361 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
2362 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
2363 1736 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
2364 1736 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
2365 : }
2366 3472 : return NDR_ERR_SUCCESS;
2367 : }
2368 :
2369 3884 : static enum ndr_err_code ndr_pull_samr_UserInfo5(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo5 *r)
2370 : {
2371 3884 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2372 3884 : if (ndr_flags & NDR_SCALARS) {
2373 1942 : NDR_CHECK(ndr_pull_align(ndr, 5));
2374 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2375 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2376 1942 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
2377 1942 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->primary_gid));
2378 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
2379 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
2380 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
2381 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
2382 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
2383 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->workstations));
2384 1942 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_logon));
2385 1942 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_logoff));
2386 1942 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
2387 1942 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->bad_password_count));
2388 1942 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->logon_count));
2389 1942 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_password_change));
2390 1942 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->acct_expiry));
2391 1942 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->acct_flags));
2392 1942 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2393 : }
2394 3884 : if (ndr_flags & NDR_BUFFERS) {
2395 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2396 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2397 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
2398 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
2399 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
2400 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
2401 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
2402 1942 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
2403 1942 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
2404 : }
2405 3884 : return NDR_ERR_SUCCESS;
2406 : }
2407 :
2408 4 : _PUBLIC_ void ndr_print_samr_UserInfo5(struct ndr_print *ndr, const char *name, const struct samr_UserInfo5 *r)
2409 : {
2410 4 : ndr_print_struct(ndr, name, "samr_UserInfo5");
2411 4 : if (r == NULL) { ndr_print_null(ndr); return; }
2412 4 : ndr->depth++;
2413 4 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
2414 4 : ndr_print_lsa_String(ndr, "full_name", &r->full_name);
2415 4 : ndr_print_uint32(ndr, "rid", r->rid);
2416 4 : ndr_print_uint32(ndr, "primary_gid", r->primary_gid);
2417 4 : ndr_print_lsa_String(ndr, "home_directory", &r->home_directory);
2418 4 : ndr_print_lsa_String(ndr, "home_drive", &r->home_drive);
2419 4 : ndr_print_lsa_String(ndr, "logon_script", &r->logon_script);
2420 4 : ndr_print_lsa_String(ndr, "profile_path", &r->profile_path);
2421 4 : ndr_print_lsa_String(ndr, "description", &r->description);
2422 4 : ndr_print_lsa_String(ndr, "workstations", &r->workstations);
2423 4 : ndr_print_NTTIME(ndr, "last_logon", r->last_logon);
2424 4 : ndr_print_NTTIME(ndr, "last_logoff", r->last_logoff);
2425 4 : ndr_print_samr_LogonHours(ndr, "logon_hours", &r->logon_hours);
2426 4 : ndr_print_uint16(ndr, "bad_password_count", r->bad_password_count);
2427 4 : ndr_print_uint16(ndr, "logon_count", r->logon_count);
2428 4 : ndr_print_NTTIME(ndr, "last_password_change", r->last_password_change);
2429 4 : ndr_print_NTTIME(ndr, "acct_expiry", r->acct_expiry);
2430 4 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->acct_flags);
2431 4 : ndr->depth--;
2432 : }
2433 :
2434 1524 : static enum ndr_err_code ndr_push_samr_UserInfo6(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo6 *r)
2435 : {
2436 1524 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2437 1524 : if (ndr_flags & NDR_SCALARS) {
2438 762 : NDR_CHECK(ndr_push_align(ndr, 5));
2439 762 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2440 762 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2441 762 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2442 : }
2443 1524 : if (ndr_flags & NDR_BUFFERS) {
2444 762 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2445 762 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2446 : }
2447 1524 : return NDR_ERR_SUCCESS;
2448 : }
2449 :
2450 1548 : static enum ndr_err_code ndr_pull_samr_UserInfo6(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo6 *r)
2451 : {
2452 1548 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2453 1548 : if (ndr_flags & NDR_SCALARS) {
2454 774 : NDR_CHECK(ndr_pull_align(ndr, 5));
2455 774 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2456 774 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2457 774 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2458 : }
2459 1548 : if (ndr_flags & NDR_BUFFERS) {
2460 774 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2461 774 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2462 : }
2463 1548 : return NDR_ERR_SUCCESS;
2464 : }
2465 :
2466 0 : _PUBLIC_ void ndr_print_samr_UserInfo6(struct ndr_print *ndr, const char *name, const struct samr_UserInfo6 *r)
2467 : {
2468 0 : ndr_print_struct(ndr, name, "samr_UserInfo6");
2469 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2470 0 : ndr->depth++;
2471 0 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
2472 0 : ndr_print_lsa_String(ndr, "full_name", &r->full_name);
2473 0 : ndr->depth--;
2474 : }
2475 :
2476 836 : static enum ndr_err_code ndr_push_samr_UserInfo7(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo7 *r)
2477 : {
2478 836 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2479 836 : if (ndr_flags & NDR_SCALARS) {
2480 418 : NDR_CHECK(ndr_push_align(ndr, 5));
2481 418 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2482 418 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2483 : }
2484 836 : if (ndr_flags & NDR_BUFFERS) {
2485 418 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2486 : }
2487 836 : return NDR_ERR_SUCCESS;
2488 : }
2489 :
2490 852 : static enum ndr_err_code ndr_pull_samr_UserInfo7(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo7 *r)
2491 : {
2492 852 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2493 852 : if (ndr_flags & NDR_SCALARS) {
2494 426 : NDR_CHECK(ndr_pull_align(ndr, 5));
2495 426 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
2496 426 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2497 : }
2498 852 : if (ndr_flags & NDR_BUFFERS) {
2499 426 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
2500 : }
2501 852 : return NDR_ERR_SUCCESS;
2502 : }
2503 :
2504 0 : _PUBLIC_ void ndr_print_samr_UserInfo7(struct ndr_print *ndr, const char *name, const struct samr_UserInfo7 *r)
2505 : {
2506 0 : ndr_print_struct(ndr, name, "samr_UserInfo7");
2507 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2508 0 : ndr->depth++;
2509 0 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
2510 0 : ndr->depth--;
2511 : }
2512 :
2513 504 : static enum ndr_err_code ndr_push_samr_UserInfo8(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo8 *r)
2514 : {
2515 504 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2516 504 : if (ndr_flags & NDR_SCALARS) {
2517 252 : NDR_CHECK(ndr_push_align(ndr, 5));
2518 252 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2519 252 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2520 : }
2521 504 : if (ndr_flags & NDR_BUFFERS) {
2522 252 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2523 : }
2524 504 : return NDR_ERR_SUCCESS;
2525 : }
2526 :
2527 528 : static enum ndr_err_code ndr_pull_samr_UserInfo8(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo8 *r)
2528 : {
2529 528 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2530 528 : if (ndr_flags & NDR_SCALARS) {
2531 264 : NDR_CHECK(ndr_pull_align(ndr, 5));
2532 264 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->full_name));
2533 264 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2534 : }
2535 528 : if (ndr_flags & NDR_BUFFERS) {
2536 264 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
2537 : }
2538 528 : return NDR_ERR_SUCCESS;
2539 : }
2540 :
2541 0 : _PUBLIC_ void ndr_print_samr_UserInfo8(struct ndr_print *ndr, const char *name, const struct samr_UserInfo8 *r)
2542 : {
2543 0 : ndr_print_struct(ndr, name, "samr_UserInfo8");
2544 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2545 0 : ndr->depth++;
2546 0 : ndr_print_lsa_String(ndr, "full_name", &r->full_name);
2547 0 : ndr->depth--;
2548 : }
2549 :
2550 102 : static enum ndr_err_code ndr_push_samr_UserInfo9(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo9 *r)
2551 : {
2552 102 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2553 102 : if (ndr_flags & NDR_SCALARS) {
2554 102 : NDR_CHECK(ndr_push_align(ndr, 4));
2555 102 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->primary_gid));
2556 102 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
2557 : }
2558 102 : if (ndr_flags & NDR_BUFFERS) {
2559 0 : }
2560 102 : return NDR_ERR_SUCCESS;
2561 : }
2562 :
2563 110 : static enum ndr_err_code ndr_pull_samr_UserInfo9(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo9 *r)
2564 : {
2565 110 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2566 110 : if (ndr_flags & NDR_SCALARS) {
2567 110 : NDR_CHECK(ndr_pull_align(ndr, 4));
2568 110 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->primary_gid));
2569 110 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
2570 : }
2571 110 : if (ndr_flags & NDR_BUFFERS) {
2572 0 : }
2573 110 : return NDR_ERR_SUCCESS;
2574 : }
2575 :
2576 0 : _PUBLIC_ void ndr_print_samr_UserInfo9(struct ndr_print *ndr, const char *name, const struct samr_UserInfo9 *r)
2577 : {
2578 0 : ndr_print_struct(ndr, name, "samr_UserInfo9");
2579 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2580 0 : ndr->depth++;
2581 0 : ndr_print_uint32(ndr, "primary_gid", r->primary_gid);
2582 0 : ndr->depth--;
2583 : }
2584 :
2585 998 : static enum ndr_err_code ndr_push_samr_UserInfo10(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo10 *r)
2586 : {
2587 998 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2588 998 : if (ndr_flags & NDR_SCALARS) {
2589 499 : NDR_CHECK(ndr_push_align(ndr, 5));
2590 499 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
2591 499 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
2592 499 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2593 : }
2594 998 : if (ndr_flags & NDR_BUFFERS) {
2595 499 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
2596 499 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
2597 : }
2598 998 : return NDR_ERR_SUCCESS;
2599 : }
2600 :
2601 996 : static enum ndr_err_code ndr_pull_samr_UserInfo10(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo10 *r)
2602 : {
2603 996 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2604 996 : if (ndr_flags & NDR_SCALARS) {
2605 498 : NDR_CHECK(ndr_pull_align(ndr, 5));
2606 498 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
2607 498 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
2608 498 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2609 : }
2610 996 : if (ndr_flags & NDR_BUFFERS) {
2611 498 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
2612 498 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
2613 : }
2614 996 : return NDR_ERR_SUCCESS;
2615 : }
2616 :
2617 26 : _PUBLIC_ void ndr_print_samr_UserInfo10(struct ndr_print *ndr, const char *name, const struct samr_UserInfo10 *r)
2618 : {
2619 26 : ndr_print_struct(ndr, name, "samr_UserInfo10");
2620 26 : if (r == NULL) { ndr_print_null(ndr); return; }
2621 26 : ndr->depth++;
2622 26 : ndr_print_lsa_String(ndr, "home_directory", &r->home_directory);
2623 26 : ndr_print_lsa_String(ndr, "home_drive", &r->home_drive);
2624 26 : ndr->depth--;
2625 : }
2626 :
2627 528 : static enum ndr_err_code ndr_push_samr_UserInfo11(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo11 *r)
2628 : {
2629 528 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2630 528 : if (ndr_flags & NDR_SCALARS) {
2631 264 : NDR_CHECK(ndr_push_align(ndr, 5));
2632 264 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
2633 264 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2634 : }
2635 528 : if (ndr_flags & NDR_BUFFERS) {
2636 264 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
2637 : }
2638 528 : return NDR_ERR_SUCCESS;
2639 : }
2640 :
2641 544 : static enum ndr_err_code ndr_pull_samr_UserInfo11(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo11 *r)
2642 : {
2643 544 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2644 544 : if (ndr_flags & NDR_SCALARS) {
2645 272 : NDR_CHECK(ndr_pull_align(ndr, 5));
2646 272 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
2647 272 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2648 : }
2649 544 : if (ndr_flags & NDR_BUFFERS) {
2650 272 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
2651 : }
2652 544 : return NDR_ERR_SUCCESS;
2653 : }
2654 :
2655 0 : _PUBLIC_ void ndr_print_samr_UserInfo11(struct ndr_print *ndr, const char *name, const struct samr_UserInfo11 *r)
2656 : {
2657 0 : ndr_print_struct(ndr, name, "samr_UserInfo11");
2658 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2659 0 : ndr->depth++;
2660 0 : ndr_print_lsa_String(ndr, "logon_script", &r->logon_script);
2661 0 : ndr->depth--;
2662 : }
2663 :
2664 556 : static enum ndr_err_code ndr_push_samr_UserInfo12(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo12 *r)
2665 : {
2666 556 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2667 556 : if (ndr_flags & NDR_SCALARS) {
2668 278 : NDR_CHECK(ndr_push_align(ndr, 5));
2669 278 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
2670 278 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2671 : }
2672 556 : if (ndr_flags & NDR_BUFFERS) {
2673 278 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
2674 : }
2675 556 : return NDR_ERR_SUCCESS;
2676 : }
2677 :
2678 576 : static enum ndr_err_code ndr_pull_samr_UserInfo12(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo12 *r)
2679 : {
2680 576 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2681 576 : if (ndr_flags & NDR_SCALARS) {
2682 288 : NDR_CHECK(ndr_pull_align(ndr, 5));
2683 288 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
2684 288 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2685 : }
2686 576 : if (ndr_flags & NDR_BUFFERS) {
2687 288 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
2688 : }
2689 576 : return NDR_ERR_SUCCESS;
2690 : }
2691 :
2692 0 : _PUBLIC_ void ndr_print_samr_UserInfo12(struct ndr_print *ndr, const char *name, const struct samr_UserInfo12 *r)
2693 : {
2694 0 : ndr_print_struct(ndr, name, "samr_UserInfo12");
2695 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2696 0 : ndr->depth++;
2697 0 : ndr_print_lsa_String(ndr, "profile_path", &r->profile_path);
2698 0 : ndr->depth--;
2699 : }
2700 :
2701 548 : static enum ndr_err_code ndr_push_samr_UserInfo13(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo13 *r)
2702 : {
2703 548 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2704 548 : if (ndr_flags & NDR_SCALARS) {
2705 274 : NDR_CHECK(ndr_push_align(ndr, 5));
2706 274 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
2707 274 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2708 : }
2709 548 : if (ndr_flags & NDR_BUFFERS) {
2710 274 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
2711 : }
2712 548 : return NDR_ERR_SUCCESS;
2713 : }
2714 :
2715 564 : static enum ndr_err_code ndr_pull_samr_UserInfo13(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo13 *r)
2716 : {
2717 564 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2718 564 : if (ndr_flags & NDR_SCALARS) {
2719 282 : NDR_CHECK(ndr_pull_align(ndr, 5));
2720 282 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
2721 282 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2722 : }
2723 564 : if (ndr_flags & NDR_BUFFERS) {
2724 282 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
2725 : }
2726 564 : return NDR_ERR_SUCCESS;
2727 : }
2728 :
2729 0 : _PUBLIC_ void ndr_print_samr_UserInfo13(struct ndr_print *ndr, const char *name, const struct samr_UserInfo13 *r)
2730 : {
2731 0 : ndr_print_struct(ndr, name, "samr_UserInfo13");
2732 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2733 0 : ndr->depth++;
2734 0 : ndr_print_lsa_String(ndr, "description", &r->description);
2735 0 : ndr->depth--;
2736 : }
2737 :
2738 540 : static enum ndr_err_code ndr_push_samr_UserInfo14(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo14 *r)
2739 : {
2740 540 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2741 540 : if (ndr_flags & NDR_SCALARS) {
2742 270 : NDR_CHECK(ndr_push_align(ndr, 5));
2743 270 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->workstations));
2744 270 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2745 : }
2746 540 : if (ndr_flags & NDR_BUFFERS) {
2747 270 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
2748 : }
2749 540 : return NDR_ERR_SUCCESS;
2750 : }
2751 :
2752 560 : static enum ndr_err_code ndr_pull_samr_UserInfo14(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo14 *r)
2753 : {
2754 560 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2755 560 : if (ndr_flags & NDR_SCALARS) {
2756 280 : NDR_CHECK(ndr_pull_align(ndr, 5));
2757 280 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->workstations));
2758 280 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2759 : }
2760 560 : if (ndr_flags & NDR_BUFFERS) {
2761 280 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
2762 : }
2763 560 : return NDR_ERR_SUCCESS;
2764 : }
2765 :
2766 0 : _PUBLIC_ void ndr_print_samr_UserInfo14(struct ndr_print *ndr, const char *name, const struct samr_UserInfo14 *r)
2767 : {
2768 0 : ndr_print_struct(ndr, name, "samr_UserInfo14");
2769 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2770 0 : ndr->depth++;
2771 0 : ndr_print_lsa_String(ndr, "workstations", &r->workstations);
2772 0 : ndr->depth--;
2773 : }
2774 :
2775 3165 : static enum ndr_err_code ndr_push_samr_UserInfo16(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo16 *r)
2776 : {
2777 3165 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2778 3165 : if (ndr_flags & NDR_SCALARS) {
2779 3165 : NDR_CHECK(ndr_push_align(ndr, 4));
2780 3165 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->acct_flags));
2781 3165 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
2782 : }
2783 3165 : if (ndr_flags & NDR_BUFFERS) {
2784 108 : }
2785 3165 : return NDR_ERR_SUCCESS;
2786 : }
2787 :
2788 3006 : static enum ndr_err_code ndr_pull_samr_UserInfo16(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo16 *r)
2789 : {
2790 3006 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2791 3006 : if (ndr_flags & NDR_SCALARS) {
2792 3006 : NDR_CHECK(ndr_pull_align(ndr, 4));
2793 3006 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->acct_flags));
2794 3006 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
2795 : }
2796 3006 : if (ndr_flags & NDR_BUFFERS) {
2797 94 : }
2798 3006 : return NDR_ERR_SUCCESS;
2799 : }
2800 :
2801 272 : _PUBLIC_ void ndr_print_samr_UserInfo16(struct ndr_print *ndr, const char *name, const struct samr_UserInfo16 *r)
2802 : {
2803 272 : ndr_print_struct(ndr, name, "samr_UserInfo16");
2804 272 : if (r == NULL) { ndr_print_null(ndr); return; }
2805 272 : ndr->depth++;
2806 272 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->acct_flags);
2807 272 : ndr->depth--;
2808 : }
2809 :
2810 230 : static enum ndr_err_code ndr_push_samr_UserInfo17(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo17 *r)
2811 : {
2812 230 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2813 230 : if (ndr_flags & NDR_SCALARS) {
2814 230 : NDR_CHECK(ndr_push_align(ndr, 4));
2815 230 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->acct_expiry));
2816 230 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
2817 : }
2818 230 : if (ndr_flags & NDR_BUFFERS) {
2819 0 : }
2820 230 : return NDR_ERR_SUCCESS;
2821 : }
2822 :
2823 240 : static enum ndr_err_code ndr_pull_samr_UserInfo17(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo17 *r)
2824 : {
2825 240 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2826 240 : if (ndr_flags & NDR_SCALARS) {
2827 240 : NDR_CHECK(ndr_pull_align(ndr, 4));
2828 240 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->acct_expiry));
2829 240 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
2830 : }
2831 240 : if (ndr_flags & NDR_BUFFERS) {
2832 0 : }
2833 240 : return NDR_ERR_SUCCESS;
2834 : }
2835 :
2836 0 : _PUBLIC_ void ndr_print_samr_UserInfo17(struct ndr_print *ndr, const char *name, const struct samr_UserInfo17 *r)
2837 : {
2838 0 : ndr_print_struct(ndr, name, "samr_UserInfo17");
2839 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2840 0 : ndr->depth++;
2841 0 : ndr_print_NTTIME(ndr, "acct_expiry", r->acct_expiry);
2842 0 : ndr->depth--;
2843 : }
2844 :
2845 5683 : _PUBLIC_ enum ndr_err_code ndr_push_samr_Password(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_Password *r)
2846 : {
2847 : {
2848 5683 : libndr_flags _flags_save_STRUCT = ndr->flags;
2849 5683 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2850 5683 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2851 5683 : if (ndr_flags & NDR_SCALARS) {
2852 5683 : NDR_CHECK(ndr_push_align(ndr, 1));
2853 5683 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->hash, 16));
2854 5683 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
2855 : }
2856 5683 : if (ndr_flags & NDR_BUFFERS) {
2857 49 : }
2858 5683 : ndr->flags = _flags_save_STRUCT;
2859 : }
2860 5683 : return NDR_ERR_SUCCESS;
2861 : }
2862 :
2863 14580 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_Password(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_Password *r)
2864 : {
2865 14580 : uint32_t size_hash_0 = 0;
2866 : {
2867 14580 : libndr_flags _flags_save_STRUCT = ndr->flags;
2868 14580 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2869 14580 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2870 14580 : if (ndr_flags & NDR_SCALARS) {
2871 14580 : NDR_CHECK(ndr_pull_align(ndr, 1));
2872 14580 : size_hash_0 = 16;
2873 14580 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->hash, size_hash_0));
2874 14580 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
2875 : }
2876 14580 : if (ndr_flags & NDR_BUFFERS) {
2877 63 : }
2878 14580 : ndr->flags = _flags_save_STRUCT;
2879 : }
2880 14580 : return NDR_ERR_SUCCESS;
2881 : }
2882 :
2883 0 : static void ndr_print_flags_samr_Password(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct samr_Password *r)
2884 : {
2885 0 : ndr_print_samr_Password(ndr, name, r);
2886 0 : }
2887 :
2888 87 : _PUBLIC_ void ndr_print_samr_Password(struct ndr_print *ndr, const char *name, const struct samr_Password *r)
2889 : {
2890 87 : ndr_print_struct(ndr, name, "samr_Password");
2891 87 : if (r == NULL) { ndr_print_null(ndr); return; }
2892 : {
2893 87 : libndr_flags _flags_save_STRUCT = ndr->flags;
2894 87 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2895 87 : ndr->depth++;
2896 87 : ndr_print_array_uint8(ndr, "hash", r->hash, 16);
2897 87 : ndr->depth--;
2898 87 : ndr->flags = _flags_save_STRUCT;
2899 : }
2900 : }
2901 :
2902 304 : static enum ndr_err_code ndr_push_samr_UserInfo18(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo18 *r)
2903 : {
2904 304 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2905 304 : if (ndr_flags & NDR_SCALARS) {
2906 304 : NDR_CHECK(ndr_push_align(ndr, 1));
2907 304 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, &r->nt_pwd));
2908 304 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, &r->lm_pwd));
2909 304 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->nt_pwd_active));
2910 304 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->lm_pwd_active));
2911 304 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->password_expired));
2912 304 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
2913 : }
2914 304 : if (ndr_flags & NDR_BUFFERS) {
2915 0 : }
2916 304 : return NDR_ERR_SUCCESS;
2917 : }
2918 :
2919 220 : static enum ndr_err_code ndr_pull_samr_UserInfo18(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo18 *r)
2920 : {
2921 220 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2922 220 : if (ndr_flags & NDR_SCALARS) {
2923 220 : NDR_CHECK(ndr_pull_align(ndr, 1));
2924 220 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, &r->nt_pwd));
2925 220 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, &r->lm_pwd));
2926 220 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->nt_pwd_active));
2927 220 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->lm_pwd_active));
2928 220 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->password_expired));
2929 220 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
2930 : }
2931 220 : if (ndr_flags & NDR_BUFFERS) {
2932 0 : }
2933 220 : return NDR_ERR_SUCCESS;
2934 : }
2935 :
2936 0 : _PUBLIC_ void ndr_print_samr_UserInfo18(struct ndr_print *ndr, const char *name, const struct samr_UserInfo18 *r)
2937 : {
2938 0 : ndr_print_struct(ndr, name, "samr_UserInfo18");
2939 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2940 0 : ndr->depth++;
2941 0 : ndr_print_samr_Password(ndr, "nt_pwd", &r->nt_pwd);
2942 0 : ndr_print_samr_Password(ndr, "lm_pwd", &r->lm_pwd);
2943 0 : ndr_print_uint8(ndr, "nt_pwd_active", r->nt_pwd_active);
2944 0 : ndr_print_uint8(ndr, "lm_pwd_active", r->lm_pwd_active);
2945 0 : ndr_print_uint8(ndr, "password_expired", r->password_expired);
2946 0 : ndr->depth--;
2947 : }
2948 :
2949 460 : static enum ndr_err_code ndr_push_samr_UserInfo20(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo20 *r)
2950 : {
2951 460 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2952 460 : if (ndr_flags & NDR_SCALARS) {
2953 230 : NDR_CHECK(ndr_push_align(ndr, 5));
2954 230 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_SCALARS, &r->parameters));
2955 230 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
2956 : }
2957 460 : if (ndr_flags & NDR_BUFFERS) {
2958 230 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_BUFFERS, &r->parameters));
2959 : }
2960 460 : return NDR_ERR_SUCCESS;
2961 : }
2962 :
2963 484 : static enum ndr_err_code ndr_pull_samr_UserInfo20(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo20 *r)
2964 : {
2965 484 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2966 484 : if (ndr_flags & NDR_SCALARS) {
2967 242 : NDR_CHECK(ndr_pull_align(ndr, 5));
2968 242 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_SCALARS, &r->parameters));
2969 242 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
2970 : }
2971 484 : if (ndr_flags & NDR_BUFFERS) {
2972 242 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_BUFFERS, &r->parameters));
2973 : }
2974 484 : return NDR_ERR_SUCCESS;
2975 : }
2976 :
2977 0 : _PUBLIC_ void ndr_print_samr_UserInfo20(struct ndr_print *ndr, const char *name, const struct samr_UserInfo20 *r)
2978 : {
2979 0 : ndr_print_struct(ndr, name, "samr_UserInfo20");
2980 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2981 0 : ndr->depth++;
2982 0 : ndr_print_lsa_BinaryString(ndr, "parameters", &r->parameters);
2983 0 : ndr->depth--;
2984 : }
2985 :
2986 6259 : static enum ndr_err_code ndr_push_samr_FieldsPresent(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
2987 : {
2988 6259 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
2989 6079 : return NDR_ERR_SUCCESS;
2990 : }
2991 :
2992 6276 : static enum ndr_err_code ndr_pull_samr_FieldsPresent(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
2993 : {
2994 180 : uint32_t v;
2995 6276 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
2996 6276 : *r = v;
2997 6276 : return NDR_ERR_SUCCESS;
2998 : }
2999 :
3000 86 : _PUBLIC_ void ndr_print_samr_FieldsPresent(struct ndr_print *ndr, const char *name, uint32_t r)
3001 : {
3002 86 : ndr_print_uint32(ndr, name, r);
3003 86 : ndr->depth++;
3004 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_ACCOUNT_NAME", SAMR_FIELD_ACCOUNT_NAME, r);
3005 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_FULL_NAME", SAMR_FIELD_FULL_NAME, r);
3006 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_RID", SAMR_FIELD_RID, r);
3007 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_PRIMARY_GID", SAMR_FIELD_PRIMARY_GID, r);
3008 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_DESCRIPTION", SAMR_FIELD_DESCRIPTION, r);
3009 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_COMMENT", SAMR_FIELD_COMMENT, r);
3010 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_HOME_DIRECTORY", SAMR_FIELD_HOME_DIRECTORY, r);
3011 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_HOME_DRIVE", SAMR_FIELD_HOME_DRIVE, r);
3012 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_LOGON_SCRIPT", SAMR_FIELD_LOGON_SCRIPT, r);
3013 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_PROFILE_PATH", SAMR_FIELD_PROFILE_PATH, r);
3014 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_WORKSTATIONS", SAMR_FIELD_WORKSTATIONS, r);
3015 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_LAST_LOGON", SAMR_FIELD_LAST_LOGON, r);
3016 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_LAST_LOGOFF", SAMR_FIELD_LAST_LOGOFF, r);
3017 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_LOGON_HOURS", SAMR_FIELD_LOGON_HOURS, r);
3018 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_BAD_PWD_COUNT", SAMR_FIELD_BAD_PWD_COUNT, r);
3019 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_NUM_LOGONS", SAMR_FIELD_NUM_LOGONS, r);
3020 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_ALLOW_PWD_CHANGE", SAMR_FIELD_ALLOW_PWD_CHANGE, r);
3021 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_FORCE_PWD_CHANGE", SAMR_FIELD_FORCE_PWD_CHANGE, r);
3022 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_LAST_PWD_CHANGE", SAMR_FIELD_LAST_PWD_CHANGE, r);
3023 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_ACCT_EXPIRY", SAMR_FIELD_ACCT_EXPIRY, r);
3024 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_ACCT_FLAGS", SAMR_FIELD_ACCT_FLAGS, r);
3025 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_PARAMETERS", SAMR_FIELD_PARAMETERS, r);
3026 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_COUNTRY_CODE", SAMR_FIELD_COUNTRY_CODE, r);
3027 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_CODE_PAGE", SAMR_FIELD_CODE_PAGE, r);
3028 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_NT_PASSWORD_PRESENT", SAMR_FIELD_NT_PASSWORD_PRESENT, r);
3029 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_LM_PASSWORD_PRESENT", SAMR_FIELD_LM_PASSWORD_PRESENT, r);
3030 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_PRIVATE_DATA", SAMR_FIELD_PRIVATE_DATA, r);
3031 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_EXPIRED_FLAG", SAMR_FIELD_EXPIRED_FLAG, r);
3032 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_SEC_DESC", SAMR_FIELD_SEC_DESC, r);
3033 86 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_FIELD_OWF_PWD", SAMR_FIELD_OWF_PWD, r);
3034 86 : ndr->depth--;
3035 86 : }
3036 :
3037 12518 : static enum ndr_err_code ndr_push_samr_UserInfo21(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo21 *r)
3038 : {
3039 12518 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3040 12518 : if (ndr_flags & NDR_SCALARS) {
3041 6259 : NDR_CHECK(ndr_push_align(ndr, 5));
3042 6259 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_logon));
3043 6259 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_logoff));
3044 6259 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->last_password_change));
3045 6259 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->acct_expiry));
3046 6259 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->allow_password_change));
3047 6259 : NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->force_password_change));
3048 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
3049 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->full_name));
3050 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
3051 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
3052 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
3053 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
3054 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
3055 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->workstations));
3056 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->comment));
3057 6259 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_SCALARS, &r->parameters));
3058 6259 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_SCALARS, &r->lm_owf_password));
3059 6259 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_SCALARS, &r->nt_owf_password));
3060 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->private_data));
3061 6259 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->buf_count));
3062 6259 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->buffer));
3063 6259 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
3064 6259 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->primary_gid));
3065 6259 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->acct_flags));
3066 6439 : NDR_CHECK(ndr_push_samr_FieldsPresent(ndr, NDR_SCALARS, r->fields_present));
3067 6259 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
3068 6259 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->bad_password_count));
3069 6259 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->logon_count));
3070 6259 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->country_code));
3071 6259 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->code_page));
3072 6259 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->lm_password_set));
3073 6259 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->nt_password_set));
3074 6259 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->password_expired));
3075 6259 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->private_data_sensitive));
3076 6259 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3077 : }
3078 12518 : if (ndr_flags & NDR_BUFFERS) {
3079 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
3080 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
3081 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
3082 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
3083 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
3084 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
3085 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
3086 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
3087 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->comment));
3088 6259 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_BUFFERS, &r->parameters));
3089 6259 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_BUFFERS, &r->lm_owf_password));
3090 6259 : NDR_CHECK(ndr_push_lsa_BinaryString(ndr, NDR_BUFFERS, &r->nt_owf_password));
3091 6259 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->private_data));
3092 6259 : if (r->buffer) {
3093 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->buf_count));
3094 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->buffer, r->buf_count));
3095 : }
3096 6259 : NDR_CHECK(ndr_push_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
3097 : }
3098 12158 : return NDR_ERR_SUCCESS;
3099 : }
3100 :
3101 12552 : static enum ndr_err_code ndr_pull_samr_UserInfo21(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo21 *r)
3102 : {
3103 360 : uint32_t _ptr_buffer;
3104 12552 : uint32_t size_buffer_1 = 0;
3105 12552 : TALLOC_CTX *_mem_save_buffer_0 = NULL;
3106 12552 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3107 12552 : if (ndr_flags & NDR_SCALARS) {
3108 6276 : NDR_CHECK(ndr_pull_align(ndr, 5));
3109 6276 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_logon));
3110 6276 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_logoff));
3111 6276 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->last_password_change));
3112 6276 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->acct_expiry));
3113 6276 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->allow_password_change));
3114 6276 : NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->force_password_change));
3115 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
3116 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->full_name));
3117 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_directory));
3118 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->home_drive));
3119 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->logon_script));
3120 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->profile_path));
3121 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
3122 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->workstations));
3123 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->comment));
3124 6276 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_SCALARS, &r->parameters));
3125 6276 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_SCALARS, &r->lm_owf_password));
3126 6276 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_SCALARS, &r->nt_owf_password));
3127 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->private_data));
3128 6276 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->buf_count));
3129 6276 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_buffer));
3130 6276 : if (_ptr_buffer) {
3131 0 : NDR_PULL_ALLOC(ndr, r->buffer);
3132 : } else {
3133 6276 : r->buffer = NULL;
3134 : }
3135 6276 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
3136 6276 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->primary_gid));
3137 6276 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->acct_flags));
3138 6456 : NDR_CHECK(ndr_pull_samr_FieldsPresent(ndr, NDR_SCALARS, &r->fields_present));
3139 6276 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_SCALARS, &r->logon_hours));
3140 6276 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->bad_password_count));
3141 6276 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->logon_count));
3142 6276 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->country_code));
3143 6276 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->code_page));
3144 6276 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->lm_password_set));
3145 6276 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->nt_password_set));
3146 6276 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->password_expired));
3147 6276 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->private_data_sensitive));
3148 6276 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3149 : }
3150 12552 : if (ndr_flags & NDR_BUFFERS) {
3151 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
3152 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
3153 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_directory));
3154 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->home_drive));
3155 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->logon_script));
3156 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->profile_path));
3157 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
3158 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->workstations));
3159 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->comment));
3160 6276 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_BUFFERS, &r->parameters));
3161 6276 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_BUFFERS, &r->lm_owf_password));
3162 6276 : NDR_CHECK(ndr_pull_lsa_BinaryString(ndr, NDR_BUFFERS, &r->nt_owf_password));
3163 6276 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->private_data));
3164 6276 : if (r->buffer) {
3165 0 : _mem_save_buffer_0 = NDR_PULL_GET_MEM_CTX(ndr);
3166 0 : NDR_PULL_SET_MEM_CTX(ndr, r->buffer, 0);
3167 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->buffer));
3168 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->buffer, &size_buffer_1));
3169 0 : NDR_PULL_ALLOC_N(ndr, r->buffer, size_buffer_1);
3170 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->buffer, size_buffer_1));
3171 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffer_0, 0);
3172 : }
3173 6276 : NDR_CHECK(ndr_pull_samr_LogonHours(ndr, NDR_BUFFERS, &r->logon_hours));
3174 6276 : if (r->buffer) {
3175 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->buffer, r->buf_count));
3176 : }
3177 : }
3178 12192 : return NDR_ERR_SUCCESS;
3179 : }
3180 :
3181 86 : _PUBLIC_ void ndr_print_samr_UserInfo21(struct ndr_print *ndr, const char *name, const struct samr_UserInfo21 *r)
3182 : {
3183 86 : ndr_print_struct(ndr, name, "samr_UserInfo21");
3184 86 : if (r == NULL) { ndr_print_null(ndr); return; }
3185 86 : ndr->depth++;
3186 86 : ndr_print_NTTIME(ndr, "last_logon", r->last_logon);
3187 86 : ndr_print_NTTIME(ndr, "last_logoff", r->last_logoff);
3188 86 : ndr_print_NTTIME(ndr, "last_password_change", r->last_password_change);
3189 86 : ndr_print_NTTIME(ndr, "acct_expiry", r->acct_expiry);
3190 86 : ndr_print_NTTIME(ndr, "allow_password_change", r->allow_password_change);
3191 86 : ndr_print_NTTIME(ndr, "force_password_change", r->force_password_change);
3192 86 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
3193 86 : ndr_print_lsa_String(ndr, "full_name", &r->full_name);
3194 86 : ndr_print_lsa_String(ndr, "home_directory", &r->home_directory);
3195 86 : ndr_print_lsa_String(ndr, "home_drive", &r->home_drive);
3196 86 : ndr_print_lsa_String(ndr, "logon_script", &r->logon_script);
3197 86 : ndr_print_lsa_String(ndr, "profile_path", &r->profile_path);
3198 86 : ndr_print_lsa_String(ndr, "description", &r->description);
3199 86 : ndr_print_lsa_String(ndr, "workstations", &r->workstations);
3200 86 : ndr_print_lsa_String(ndr, "comment", &r->comment);
3201 86 : ndr_print_lsa_BinaryString(ndr, "parameters", &r->parameters);
3202 86 : ndr_print_lsa_BinaryString(ndr, "lm_owf_password", &r->lm_owf_password);
3203 86 : ndr_print_lsa_BinaryString(ndr, "nt_owf_password", &r->nt_owf_password);
3204 86 : ndr_print_lsa_String(ndr, "private_data", &r->private_data);
3205 86 : ndr_print_uint32(ndr, "buf_count", r->buf_count);
3206 86 : ndr_print_ptr(ndr, "buffer", r->buffer);
3207 86 : ndr->depth++;
3208 86 : if (r->buffer) {
3209 0 : ndr_print_array_uint8(ndr, "buffer", r->buffer, r->buf_count);
3210 : }
3211 86 : ndr->depth--;
3212 86 : ndr_print_uint32(ndr, "rid", r->rid);
3213 86 : ndr_print_uint32(ndr, "primary_gid", r->primary_gid);
3214 86 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->acct_flags);
3215 86 : ndr_print_samr_FieldsPresent(ndr, "fields_present", r->fields_present);
3216 86 : ndr_print_samr_LogonHours(ndr, "logon_hours", &r->logon_hours);
3217 86 : ndr_print_uint16(ndr, "bad_password_count", r->bad_password_count);
3218 86 : ndr_print_uint16(ndr, "logon_count", r->logon_count);
3219 86 : ndr_print_uint16(ndr, "country_code", r->country_code);
3220 86 : ndr_print_uint16(ndr, "code_page", r->code_page);
3221 86 : ndr_print_uint8(ndr, "lm_password_set", r->lm_password_set);
3222 86 : ndr_print_uint8(ndr, "nt_password_set", r->nt_password_set);
3223 86 : ndr_print_uint8(ndr, "password_expired", r->password_expired);
3224 86 : ndr_print_uint8(ndr, "private_data_sensitive", r->private_data_sensitive);
3225 86 : ndr->depth--;
3226 : }
3227 :
3228 3615 : _PUBLIC_ enum ndr_err_code ndr_push_samr_CryptPassword(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_CryptPassword *r)
3229 : {
3230 : {
3231 3615 : libndr_flags _flags_save_STRUCT = ndr->flags;
3232 3615 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
3233 3615 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3234 3615 : if (ndr_flags & NDR_SCALARS) {
3235 3615 : NDR_CHECK(ndr_push_align(ndr, 1));
3236 3615 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->data, 516));
3237 3615 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
3238 : }
3239 3615 : if (ndr_flags & NDR_BUFFERS) {
3240 0 : }
3241 3615 : ndr->flags = _flags_save_STRUCT;
3242 : }
3243 3615 : return NDR_ERR_SUCCESS;
3244 : }
3245 :
3246 3073 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_CryptPassword(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_CryptPassword *r)
3247 : {
3248 3073 : uint32_t size_data_0 = 0;
3249 : {
3250 3073 : libndr_flags _flags_save_STRUCT = ndr->flags;
3251 3073 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
3252 3073 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3253 3073 : if (ndr_flags & NDR_SCALARS) {
3254 3073 : NDR_CHECK(ndr_pull_align(ndr, 1));
3255 3073 : size_data_0 = 516;
3256 3073 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->data, size_data_0));
3257 3073 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
3258 : }
3259 3073 : if (ndr_flags & NDR_BUFFERS) {
3260 4 : }
3261 3073 : ndr->flags = _flags_save_STRUCT;
3262 : }
3263 3073 : return NDR_ERR_SUCCESS;
3264 : }
3265 :
3266 0 : static void ndr_print_flags_samr_CryptPassword(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct samr_CryptPassword *r)
3267 : {
3268 0 : ndr_print_samr_CryptPassword(ndr, name, r);
3269 0 : }
3270 :
3271 4 : _PUBLIC_ void ndr_print_samr_CryptPassword(struct ndr_print *ndr, const char *name, const struct samr_CryptPassword *r)
3272 : {
3273 4 : ndr_print_struct(ndr, name, "samr_CryptPassword");
3274 4 : if (r == NULL) { ndr_print_null(ndr); return; }
3275 : {
3276 4 : libndr_flags _flags_save_STRUCT = ndr->flags;
3277 4 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
3278 4 : ndr->depth++;
3279 4 : ndr_print_array_uint8(ndr, "data", r->data, 516);
3280 4 : ndr->depth--;
3281 4 : ndr->flags = _flags_save_STRUCT;
3282 : }
3283 : }
3284 :
3285 176 : static enum ndr_err_code ndr_push_samr_UserInfo23(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo23 *r)
3286 : {
3287 176 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3288 176 : if (ndr_flags & NDR_SCALARS) {
3289 88 : NDR_CHECK(ndr_push_align(ndr, 5));
3290 88 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_SCALARS, &r->info));
3291 88 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, &r->password));
3292 88 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3293 : }
3294 176 : if (ndr_flags & NDR_BUFFERS) {
3295 88 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info));
3296 : }
3297 176 : return NDR_ERR_SUCCESS;
3298 : }
3299 :
3300 152 : static enum ndr_err_code ndr_pull_samr_UserInfo23(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo23 *r)
3301 : {
3302 152 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3303 152 : if (ndr_flags & NDR_SCALARS) {
3304 76 : NDR_CHECK(ndr_pull_align(ndr, 5));
3305 76 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_SCALARS, &r->info));
3306 76 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, &r->password));
3307 76 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3308 : }
3309 152 : if (ndr_flags & NDR_BUFFERS) {
3310 76 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info));
3311 : }
3312 152 : return NDR_ERR_SUCCESS;
3313 : }
3314 :
3315 0 : _PUBLIC_ void ndr_print_samr_UserInfo23(struct ndr_print *ndr, const char *name, const struct samr_UserInfo23 *r)
3316 : {
3317 0 : ndr_print_struct(ndr, name, "samr_UserInfo23");
3318 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3319 0 : ndr->depth++;
3320 0 : ndr_print_samr_UserInfo21(ndr, "info", &r->info);
3321 0 : ndr_print_samr_CryptPassword(ndr, "password", &r->password);
3322 0 : ndr->depth--;
3323 : }
3324 :
3325 287 : static enum ndr_err_code ndr_push_samr_UserInfo24(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo24 *r)
3326 : {
3327 287 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3328 287 : if (ndr_flags & NDR_SCALARS) {
3329 287 : NDR_CHECK(ndr_push_align(ndr, 1));
3330 287 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, &r->password));
3331 287 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->password_expired));
3332 287 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
3333 : }
3334 287 : if (ndr_flags & NDR_BUFFERS) {
3335 0 : }
3336 287 : return NDR_ERR_SUCCESS;
3337 : }
3338 :
3339 191 : static enum ndr_err_code ndr_pull_samr_UserInfo24(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo24 *r)
3340 : {
3341 191 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3342 191 : if (ndr_flags & NDR_SCALARS) {
3343 191 : NDR_CHECK(ndr_pull_align(ndr, 1));
3344 191 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, &r->password));
3345 191 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->password_expired));
3346 191 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
3347 : }
3348 191 : if (ndr_flags & NDR_BUFFERS) {
3349 0 : }
3350 191 : return NDR_ERR_SUCCESS;
3351 : }
3352 :
3353 0 : _PUBLIC_ void ndr_print_samr_UserInfo24(struct ndr_print *ndr, const char *name, const struct samr_UserInfo24 *r)
3354 : {
3355 0 : ndr_print_struct(ndr, name, "samr_UserInfo24");
3356 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3357 0 : ndr->depth++;
3358 0 : ndr_print_samr_CryptPassword(ndr, "password", &r->password);
3359 0 : ndr_print_uint8(ndr, "password_expired", r->password_expired);
3360 0 : ndr->depth--;
3361 : }
3362 :
3363 895 : static enum ndr_err_code ndr_push_samr_CryptPasswordEx(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_CryptPasswordEx *r)
3364 : {
3365 : {
3366 895 : libndr_flags _flags_save_STRUCT = ndr->flags;
3367 895 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
3368 895 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3369 895 : if (ndr_flags & NDR_SCALARS) {
3370 895 : NDR_CHECK(ndr_push_align(ndr, 1));
3371 895 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->data, 532));
3372 895 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
3373 : }
3374 895 : if (ndr_flags & NDR_BUFFERS) {
3375 90 : }
3376 895 : ndr->flags = _flags_save_STRUCT;
3377 : }
3378 895 : return NDR_ERR_SUCCESS;
3379 : }
3380 :
3381 850 : static enum ndr_err_code ndr_pull_samr_CryptPasswordEx(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_CryptPasswordEx *r)
3382 : {
3383 850 : uint32_t size_data_0 = 0;
3384 : {
3385 850 : libndr_flags _flags_save_STRUCT = ndr->flags;
3386 850 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
3387 850 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3388 850 : if (ndr_flags & NDR_SCALARS) {
3389 850 : NDR_CHECK(ndr_pull_align(ndr, 1));
3390 850 : size_data_0 = 532;
3391 850 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->data, size_data_0));
3392 850 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
3393 : }
3394 850 : if (ndr_flags & NDR_BUFFERS) {
3395 92 : }
3396 850 : ndr->flags = _flags_save_STRUCT;
3397 : }
3398 850 : return NDR_ERR_SUCCESS;
3399 : }
3400 :
3401 2 : _PUBLIC_ void ndr_print_samr_CryptPasswordEx(struct ndr_print *ndr, const char *name, const struct samr_CryptPasswordEx *r)
3402 : {
3403 2 : ndr_print_struct(ndr, name, "samr_CryptPasswordEx");
3404 2 : if (r == NULL) { ndr_print_null(ndr); return; }
3405 : {
3406 2 : libndr_flags _flags_save_STRUCT = ndr->flags;
3407 2 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
3408 2 : ndr->depth++;
3409 2 : ndr_print_array_uint8(ndr, "data", r->data, 532);
3410 2 : ndr->depth--;
3411 2 : ndr->flags = _flags_save_STRUCT;
3412 : }
3413 : }
3414 :
3415 1562 : static enum ndr_err_code ndr_push_samr_UserInfo25(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo25 *r)
3416 : {
3417 1472 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3418 1472 : if (ndr_flags & NDR_SCALARS) {
3419 781 : NDR_CHECK(ndr_push_align(ndr, 5));
3420 781 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_SCALARS, &r->info));
3421 781 : NDR_CHECK(ndr_push_samr_CryptPasswordEx(ndr, NDR_SCALARS, &r->password));
3422 781 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
3423 : }
3424 1472 : if (ndr_flags & NDR_BUFFERS) {
3425 781 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info));
3426 : }
3427 1382 : return NDR_ERR_SUCCESS;
3428 : }
3429 :
3430 1502 : static enum ndr_err_code ndr_pull_samr_UserInfo25(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo25 *r)
3431 : {
3432 1502 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3433 1502 : if (ndr_flags & NDR_SCALARS) {
3434 751 : NDR_CHECK(ndr_pull_align(ndr, 5));
3435 751 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_SCALARS, &r->info));
3436 751 : NDR_CHECK(ndr_pull_samr_CryptPasswordEx(ndr, NDR_SCALARS, &r->password));
3437 751 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
3438 : }
3439 1502 : if (ndr_flags & NDR_BUFFERS) {
3440 751 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info));
3441 : }
3442 1322 : return NDR_ERR_SUCCESS;
3443 : }
3444 :
3445 0 : _PUBLIC_ void ndr_print_samr_UserInfo25(struct ndr_print *ndr, const char *name, const struct samr_UserInfo25 *r)
3446 : {
3447 0 : ndr_print_struct(ndr, name, "samr_UserInfo25");
3448 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3449 0 : ndr->depth++;
3450 0 : ndr_print_samr_UserInfo21(ndr, "info", &r->info);
3451 0 : ndr_print_samr_CryptPasswordEx(ndr, "password", &r->password);
3452 0 : ndr->depth--;
3453 : }
3454 :
3455 114 : static enum ndr_err_code ndr_push_samr_UserInfo26(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo26 *r)
3456 : {
3457 114 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3458 114 : if (ndr_flags & NDR_SCALARS) {
3459 114 : NDR_CHECK(ndr_push_align(ndr, 1));
3460 114 : NDR_CHECK(ndr_push_samr_CryptPasswordEx(ndr, NDR_SCALARS, &r->password));
3461 114 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->password_expired));
3462 114 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
3463 : }
3464 114 : if (ndr_flags & NDR_BUFFERS) {
3465 0 : }
3466 114 : return NDR_ERR_SUCCESS;
3467 : }
3468 :
3469 99 : static enum ndr_err_code ndr_pull_samr_UserInfo26(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo26 *r)
3470 : {
3471 99 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3472 99 : if (ndr_flags & NDR_SCALARS) {
3473 99 : NDR_CHECK(ndr_pull_align(ndr, 1));
3474 99 : NDR_CHECK(ndr_pull_samr_CryptPasswordEx(ndr, NDR_SCALARS, &r->password));
3475 99 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->password_expired));
3476 99 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
3477 : }
3478 99 : if (ndr_flags & NDR_BUFFERS) {
3479 2 : }
3480 99 : return NDR_ERR_SUCCESS;
3481 : }
3482 :
3483 2 : _PUBLIC_ void ndr_print_samr_UserInfo26(struct ndr_print *ndr, const char *name, const struct samr_UserInfo26 *r)
3484 : {
3485 2 : ndr_print_struct(ndr, name, "samr_UserInfo26");
3486 2 : if (r == NULL) { ndr_print_null(ndr); return; }
3487 2 : ndr->depth++;
3488 2 : ndr_print_samr_CryptPasswordEx(ndr, "password", &r->password);
3489 2 : ndr_print_uint8(ndr, "password_expired", r->password_expired);
3490 2 : ndr->depth--;
3491 : }
3492 :
3493 314 : static enum ndr_err_code ndr_push_samr_EncryptedPasswordAES(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_EncryptedPasswordAES *r)
3494 : {
3495 314 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3496 314 : if (ndr_flags & NDR_SCALARS) {
3497 202 : NDR_CHECK(ndr_push_align(ndr, 8));
3498 202 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->auth_data, 64));
3499 202 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->salt, 16));
3500 202 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->cipher_len));
3501 202 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->cipher));
3502 202 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->PBKDF2Iterations));
3503 202 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
3504 : }
3505 314 : if (ndr_flags & NDR_BUFFERS) {
3506 202 : if (r->cipher) {
3507 202 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->cipher_len));
3508 202 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->cipher, r->cipher_len));
3509 : }
3510 : }
3511 314 : return NDR_ERR_SUCCESS;
3512 : }
3513 :
3514 306 : static enum ndr_err_code ndr_pull_samr_EncryptedPasswordAES(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_EncryptedPasswordAES *r)
3515 : {
3516 306 : uint32_t size_auth_data_0 = 0;
3517 306 : uint32_t size_salt_0 = 0;
3518 0 : uint32_t _ptr_cipher;
3519 306 : uint32_t size_cipher_1 = 0;
3520 306 : TALLOC_CTX *_mem_save_cipher_0 = NULL;
3521 306 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3522 306 : if (ndr_flags & NDR_SCALARS) {
3523 210 : NDR_CHECK(ndr_pull_align(ndr, 8));
3524 210 : size_auth_data_0 = 64;
3525 210 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->auth_data, size_auth_data_0));
3526 210 : size_salt_0 = 16;
3527 210 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->salt, size_salt_0));
3528 210 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->cipher_len));
3529 210 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_cipher));
3530 210 : if (_ptr_cipher) {
3531 210 : NDR_PULL_ALLOC(ndr, r->cipher);
3532 : } else {
3533 0 : r->cipher = NULL;
3534 : }
3535 210 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->PBKDF2Iterations));
3536 210 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
3537 : }
3538 306 : if (ndr_flags & NDR_BUFFERS) {
3539 210 : if (r->cipher) {
3540 210 : _mem_save_cipher_0 = NDR_PULL_GET_MEM_CTX(ndr);
3541 210 : NDR_PULL_SET_MEM_CTX(ndr, r->cipher, 0);
3542 210 : NDR_CHECK(ndr_pull_array_size(ndr, &r->cipher));
3543 210 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->cipher, &size_cipher_1));
3544 210 : NDR_PULL_ALLOC_N(ndr, r->cipher, size_cipher_1);
3545 210 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->cipher, size_cipher_1));
3546 210 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_cipher_0, 0);
3547 : }
3548 210 : if (r->cipher) {
3549 210 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->cipher, r->cipher_len));
3550 : }
3551 : }
3552 306 : return NDR_ERR_SUCCESS;
3553 : }
3554 :
3555 0 : _PUBLIC_ void ndr_print_samr_EncryptedPasswordAES(struct ndr_print *ndr, const char *name, const struct samr_EncryptedPasswordAES *r)
3556 : {
3557 0 : ndr_print_struct(ndr, name, "samr_EncryptedPasswordAES");
3558 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3559 0 : ndr->depth++;
3560 0 : ndr_print_array_uint8(ndr, "auth_data", r->auth_data, 64);
3561 0 : ndr_print_array_uint8(ndr, "salt", r->salt, 16);
3562 0 : ndr_print_uint32(ndr, "cipher_len", r->cipher_len);
3563 0 : ndr_print_ptr(ndr, "cipher", r->cipher);
3564 0 : ndr->depth++;
3565 0 : if (r->cipher) {
3566 0 : ndr_print_array_uint8(ndr, "cipher", r->cipher, r->cipher_len);
3567 : }
3568 0 : ndr->depth--;
3569 0 : ndr_print_hyper(ndr, "PBKDF2Iterations", r->PBKDF2Iterations);
3570 0 : ndr->depth--;
3571 : }
3572 :
3573 56 : static enum ndr_err_code ndr_push_samr_UserInfo31(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo31 *r)
3574 : {
3575 56 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3576 56 : if (ndr_flags & NDR_SCALARS) {
3577 28 : NDR_CHECK(ndr_push_align(ndr, 8));
3578 28 : NDR_CHECK(ndr_push_samr_EncryptedPasswordAES(ndr, NDR_SCALARS, &r->password));
3579 28 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->password_expired));
3580 28 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
3581 : }
3582 56 : if (ndr_flags & NDR_BUFFERS) {
3583 28 : NDR_CHECK(ndr_push_samr_EncryptedPasswordAES(ndr, NDR_BUFFERS, &r->password));
3584 : }
3585 56 : return NDR_ERR_SUCCESS;
3586 : }
3587 :
3588 48 : static enum ndr_err_code ndr_pull_samr_UserInfo31(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo31 *r)
3589 : {
3590 48 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3591 48 : if (ndr_flags & NDR_SCALARS) {
3592 24 : NDR_CHECK(ndr_pull_align(ndr, 8));
3593 24 : NDR_CHECK(ndr_pull_samr_EncryptedPasswordAES(ndr, NDR_SCALARS, &r->password));
3594 24 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->password_expired));
3595 24 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
3596 : }
3597 48 : if (ndr_flags & NDR_BUFFERS) {
3598 24 : NDR_CHECK(ndr_pull_samr_EncryptedPasswordAES(ndr, NDR_BUFFERS, &r->password));
3599 : }
3600 48 : return NDR_ERR_SUCCESS;
3601 : }
3602 :
3603 0 : _PUBLIC_ void ndr_print_samr_UserInfo31(struct ndr_print *ndr, const char *name, const struct samr_UserInfo31 *r)
3604 : {
3605 0 : ndr_print_struct(ndr, name, "samr_UserInfo31");
3606 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3607 0 : ndr->depth++;
3608 0 : ndr_print_samr_EncryptedPasswordAES(ndr, "password", &r->password);
3609 0 : ndr_print_uint8(ndr, "password_expired", r->password_expired);
3610 0 : ndr->depth--;
3611 : }
3612 :
3613 168 : static enum ndr_err_code ndr_push_samr_UserInfo32(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_UserInfo32 *r)
3614 : {
3615 168 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3616 168 : if (ndr_flags & NDR_SCALARS) {
3617 84 : NDR_CHECK(ndr_push_align(ndr, 8));
3618 84 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_SCALARS, &r->info));
3619 84 : NDR_CHECK(ndr_push_samr_EncryptedPasswordAES(ndr, NDR_SCALARS, &r->password));
3620 84 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
3621 : }
3622 168 : if (ndr_flags & NDR_BUFFERS) {
3623 84 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info));
3624 84 : NDR_CHECK(ndr_push_samr_EncryptedPasswordAES(ndr, NDR_BUFFERS, &r->password));
3625 : }
3626 168 : return NDR_ERR_SUCCESS;
3627 : }
3628 :
3629 144 : static enum ndr_err_code ndr_pull_samr_UserInfo32(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_UserInfo32 *r)
3630 : {
3631 144 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3632 144 : if (ndr_flags & NDR_SCALARS) {
3633 72 : NDR_CHECK(ndr_pull_align(ndr, 8));
3634 72 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_SCALARS, &r->info));
3635 72 : NDR_CHECK(ndr_pull_samr_EncryptedPasswordAES(ndr, NDR_SCALARS, &r->password));
3636 72 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
3637 : }
3638 144 : if (ndr_flags & NDR_BUFFERS) {
3639 72 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info));
3640 72 : NDR_CHECK(ndr_pull_samr_EncryptedPasswordAES(ndr, NDR_BUFFERS, &r->password));
3641 : }
3642 144 : return NDR_ERR_SUCCESS;
3643 : }
3644 :
3645 0 : _PUBLIC_ void ndr_print_samr_UserInfo32(struct ndr_print *ndr, const char *name, const struct samr_UserInfo32 *r)
3646 : {
3647 0 : ndr_print_struct(ndr, name, "samr_UserInfo32");
3648 0 : if (r == NULL) { ndr_print_null(ndr); return; }
3649 0 : ndr->depth++;
3650 0 : ndr_print_samr_UserInfo21(ndr, "info", &r->info);
3651 0 : ndr_print_samr_EncryptedPasswordAES(ndr, "password", &r->password);
3652 0 : ndr->depth--;
3653 : }
3654 :
3655 17964 : static enum ndr_err_code ndr_push_samr_UserInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_UserInfo *r)
3656 : {
3657 288 : uint32_t level;
3658 17964 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
3659 17964 : if (ndr_flags & NDR_SCALARS) {
3660 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
3661 17964 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
3662 17964 : NDR_CHECK(ndr_push_union_align(ndr, 8));
3663 17964 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
3664 17964 : NDR_CHECK(ndr_push_union_align(ndr, 8));
3665 17964 : switch (level) {
3666 307 : case 1: {
3667 307 : NDR_CHECK(ndr_push_samr_UserInfo1(ndr, NDR_SCALARS, &r->info1));
3668 307 : break; }
3669 :
3670 431 : case 2: {
3671 431 : NDR_CHECK(ndr_push_samr_UserInfo2(ndr, NDR_SCALARS, &r->info2));
3672 431 : break; }
3673 :
3674 1496 : case 3: {
3675 1496 : NDR_CHECK(ndr_push_samr_UserInfo3(ndr, NDR_SCALARS, &r->info3));
3676 1496 : break; }
3677 :
3678 258 : case 4: {
3679 258 : NDR_CHECK(ndr_push_samr_UserInfo4(ndr, NDR_SCALARS, &r->info4));
3680 258 : break; }
3681 :
3682 1736 : case 5: {
3683 1736 : NDR_CHECK(ndr_push_samr_UserInfo5(ndr, NDR_SCALARS, &r->info5));
3684 1736 : break; }
3685 :
3686 762 : case 6: {
3687 762 : NDR_CHECK(ndr_push_samr_UserInfo6(ndr, NDR_SCALARS, &r->info6));
3688 762 : break; }
3689 :
3690 418 : case 7: {
3691 418 : NDR_CHECK(ndr_push_samr_UserInfo7(ndr, NDR_SCALARS, &r->info7));
3692 418 : break; }
3693 :
3694 252 : case 8: {
3695 252 : NDR_CHECK(ndr_push_samr_UserInfo8(ndr, NDR_SCALARS, &r->info8));
3696 252 : break; }
3697 :
3698 102 : case 9: {
3699 102 : NDR_CHECK(ndr_push_samr_UserInfo9(ndr, NDR_SCALARS, &r->info9));
3700 102 : break; }
3701 :
3702 499 : case 10: {
3703 499 : NDR_CHECK(ndr_push_samr_UserInfo10(ndr, NDR_SCALARS, &r->info10));
3704 499 : break; }
3705 :
3706 264 : case 11: {
3707 264 : NDR_CHECK(ndr_push_samr_UserInfo11(ndr, NDR_SCALARS, &r->info11));
3708 264 : break; }
3709 :
3710 278 : case 12: {
3711 278 : NDR_CHECK(ndr_push_samr_UserInfo12(ndr, NDR_SCALARS, &r->info12));
3712 278 : break; }
3713 :
3714 274 : case 13: {
3715 274 : NDR_CHECK(ndr_push_samr_UserInfo13(ndr, NDR_SCALARS, &r->info13));
3716 274 : break; }
3717 :
3718 270 : case 14: {
3719 270 : NDR_CHECK(ndr_push_samr_UserInfo14(ndr, NDR_SCALARS, &r->info14));
3720 270 : break; }
3721 :
3722 3165 : case 16: {
3723 3165 : NDR_CHECK(ndr_push_samr_UserInfo16(ndr, NDR_SCALARS, &r->info16));
3724 3057 : break; }
3725 :
3726 230 : case 17: {
3727 230 : NDR_CHECK(ndr_push_samr_UserInfo17(ndr, NDR_SCALARS, &r->info17));
3728 230 : break; }
3729 :
3730 304 : case 18: {
3731 304 : NDR_CHECK(ndr_push_samr_UserInfo18(ndr, NDR_SCALARS, &r->info18));
3732 304 : break; }
3733 :
3734 230 : case 20: {
3735 230 : NDR_CHECK(ndr_push_samr_UserInfo20(ndr, NDR_SCALARS, &r->info20));
3736 230 : break; }
3737 :
3738 5306 : case 21: {
3739 5306 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_SCALARS, &r->info21));
3740 5216 : break; }
3741 :
3742 88 : case 23: {
3743 88 : NDR_CHECK(ndr_push_samr_UserInfo23(ndr, NDR_SCALARS, &r->info23));
3744 88 : break; }
3745 :
3746 287 : case 24: {
3747 287 : NDR_CHECK(ndr_push_samr_UserInfo24(ndr, NDR_SCALARS, &r->info24));
3748 287 : break; }
3749 :
3750 781 : case 25: {
3751 781 : NDR_CHECK(ndr_push_samr_UserInfo25(ndr, NDR_SCALARS, &r->info25));
3752 691 : break; }
3753 :
3754 114 : case 26: {
3755 114 : NDR_CHECK(ndr_push_samr_UserInfo26(ndr, NDR_SCALARS, &r->info26));
3756 114 : break; }
3757 :
3758 28 : case 31: {
3759 28 : NDR_CHECK(ndr_push_samr_UserInfo31(ndr, NDR_SCALARS, &r->info31));
3760 28 : break; }
3761 :
3762 84 : case 32: {
3763 84 : NDR_CHECK(ndr_push_samr_UserInfo32(ndr, NDR_SCALARS, &r->info32));
3764 84 : break; }
3765 :
3766 0 : default:
3767 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
3768 : }
3769 : }
3770 17964 : if (ndr_flags & NDR_BUFFERS) {
3771 17964 : if (!(ndr_flags & NDR_SCALARS)) {
3772 : /* We didn't get it above, and the token is not needed after this. */
3773 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
3774 : }
3775 17964 : switch (level) {
3776 307 : case 1:
3777 307 : NDR_CHECK(ndr_push_samr_UserInfo1(ndr, NDR_BUFFERS, &r->info1));
3778 307 : break;
3779 :
3780 431 : case 2:
3781 431 : NDR_CHECK(ndr_push_samr_UserInfo2(ndr, NDR_BUFFERS, &r->info2));
3782 431 : break;
3783 :
3784 1496 : case 3:
3785 1496 : NDR_CHECK(ndr_push_samr_UserInfo3(ndr, NDR_BUFFERS, &r->info3));
3786 1496 : break;
3787 :
3788 258 : case 4:
3789 258 : NDR_CHECK(ndr_push_samr_UserInfo4(ndr, NDR_BUFFERS, &r->info4));
3790 258 : break;
3791 :
3792 1736 : case 5:
3793 1736 : NDR_CHECK(ndr_push_samr_UserInfo5(ndr, NDR_BUFFERS, &r->info5));
3794 1736 : break;
3795 :
3796 762 : case 6:
3797 762 : NDR_CHECK(ndr_push_samr_UserInfo6(ndr, NDR_BUFFERS, &r->info6));
3798 762 : break;
3799 :
3800 418 : case 7:
3801 418 : NDR_CHECK(ndr_push_samr_UserInfo7(ndr, NDR_BUFFERS, &r->info7));
3802 418 : break;
3803 :
3804 252 : case 8:
3805 252 : NDR_CHECK(ndr_push_samr_UserInfo8(ndr, NDR_BUFFERS, &r->info8));
3806 252 : break;
3807 :
3808 102 : case 9:
3809 102 : break;
3810 :
3811 499 : case 10:
3812 499 : NDR_CHECK(ndr_push_samr_UserInfo10(ndr, NDR_BUFFERS, &r->info10));
3813 499 : break;
3814 :
3815 264 : case 11:
3816 264 : NDR_CHECK(ndr_push_samr_UserInfo11(ndr, NDR_BUFFERS, &r->info11));
3817 264 : break;
3818 :
3819 278 : case 12:
3820 278 : NDR_CHECK(ndr_push_samr_UserInfo12(ndr, NDR_BUFFERS, &r->info12));
3821 278 : break;
3822 :
3823 274 : case 13:
3824 274 : NDR_CHECK(ndr_push_samr_UserInfo13(ndr, NDR_BUFFERS, &r->info13));
3825 274 : break;
3826 :
3827 270 : case 14:
3828 270 : NDR_CHECK(ndr_push_samr_UserInfo14(ndr, NDR_BUFFERS, &r->info14));
3829 270 : break;
3830 :
3831 3057 : case 16:
3832 3057 : break;
3833 :
3834 230 : case 17:
3835 230 : break;
3836 :
3837 304 : case 18:
3838 304 : break;
3839 :
3840 230 : case 20:
3841 230 : NDR_CHECK(ndr_push_samr_UserInfo20(ndr, NDR_BUFFERS, &r->info20));
3842 230 : break;
3843 :
3844 5306 : case 21:
3845 5306 : NDR_CHECK(ndr_push_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info21));
3846 5216 : break;
3847 :
3848 88 : case 23:
3849 88 : NDR_CHECK(ndr_push_samr_UserInfo23(ndr, NDR_BUFFERS, &r->info23));
3850 88 : break;
3851 :
3852 287 : case 24:
3853 287 : break;
3854 :
3855 781 : case 25:
3856 871 : NDR_CHECK(ndr_push_samr_UserInfo25(ndr, NDR_BUFFERS, &r->info25));
3857 691 : break;
3858 :
3859 114 : case 26:
3860 114 : break;
3861 :
3862 28 : case 31:
3863 28 : NDR_CHECK(ndr_push_samr_UserInfo31(ndr, NDR_BUFFERS, &r->info31));
3864 28 : break;
3865 :
3866 84 : case 32:
3867 84 : NDR_CHECK(ndr_push_samr_UserInfo32(ndr, NDR_BUFFERS, &r->info32));
3868 84 : break;
3869 :
3870 0 : default:
3871 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
3872 : }
3873 : }
3874 17676 : return NDR_ERR_SUCCESS;
3875 : }
3876 :
3877 18119 : static enum ndr_err_code ndr_pull_samr_UserInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_UserInfo *r)
3878 : {
3879 276 : uint32_t level;
3880 276 : uint16_t _level;
3881 18119 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
3882 18119 : if (ndr_flags & NDR_SCALARS) {
3883 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
3884 18119 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
3885 18119 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
3886 18119 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
3887 18119 : if (_level != level) {
3888 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
3889 : }
3890 18119 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
3891 18119 : switch (level) {
3892 303 : case 1: {
3893 303 : NDR_CHECK(ndr_pull_samr_UserInfo1(ndr, NDR_SCALARS, &r->info1));
3894 303 : break; }
3895 :
3896 430 : case 2: {
3897 430 : NDR_CHECK(ndr_pull_samr_UserInfo2(ndr, NDR_SCALARS, &r->info2));
3898 430 : break; }
3899 :
3900 1686 : case 3: {
3901 1686 : NDR_CHECK(ndr_pull_samr_UserInfo3(ndr, NDR_SCALARS, &r->info3));
3902 1686 : break; }
3903 :
3904 266 : case 4: {
3905 266 : NDR_CHECK(ndr_pull_samr_UserInfo4(ndr, NDR_SCALARS, &r->info4));
3906 266 : break; }
3907 :
3908 1942 : case 5: {
3909 1942 : NDR_CHECK(ndr_pull_samr_UserInfo5(ndr, NDR_SCALARS, &r->info5));
3910 1942 : break; }
3911 :
3912 774 : case 6: {
3913 774 : NDR_CHECK(ndr_pull_samr_UserInfo6(ndr, NDR_SCALARS, &r->info6));
3914 774 : break; }
3915 :
3916 426 : case 7: {
3917 426 : NDR_CHECK(ndr_pull_samr_UserInfo7(ndr, NDR_SCALARS, &r->info7));
3918 426 : break; }
3919 :
3920 264 : case 8: {
3921 264 : NDR_CHECK(ndr_pull_samr_UserInfo8(ndr, NDR_SCALARS, &r->info8));
3922 264 : break; }
3923 :
3924 110 : case 9: {
3925 110 : NDR_CHECK(ndr_pull_samr_UserInfo9(ndr, NDR_SCALARS, &r->info9));
3926 110 : break; }
3927 :
3928 498 : case 10: {
3929 498 : NDR_CHECK(ndr_pull_samr_UserInfo10(ndr, NDR_SCALARS, &r->info10));
3930 498 : break; }
3931 :
3932 272 : case 11: {
3933 272 : NDR_CHECK(ndr_pull_samr_UserInfo11(ndr, NDR_SCALARS, &r->info11));
3934 272 : break; }
3935 :
3936 288 : case 12: {
3937 288 : NDR_CHECK(ndr_pull_samr_UserInfo12(ndr, NDR_SCALARS, &r->info12));
3938 288 : break; }
3939 :
3940 282 : case 13: {
3941 282 : NDR_CHECK(ndr_pull_samr_UserInfo13(ndr, NDR_SCALARS, &r->info13));
3942 282 : break; }
3943 :
3944 280 : case 14: {
3945 280 : NDR_CHECK(ndr_pull_samr_UserInfo14(ndr, NDR_SCALARS, &r->info14));
3946 280 : break; }
3947 :
3948 3006 : case 16: {
3949 3006 : NDR_CHECK(ndr_pull_samr_UserInfo16(ndr, NDR_SCALARS, &r->info16));
3950 2912 : break; }
3951 :
3952 240 : case 17: {
3953 240 : NDR_CHECK(ndr_pull_samr_UserInfo17(ndr, NDR_SCALARS, &r->info17));
3954 240 : break; }
3955 :
3956 220 : case 18: {
3957 220 : NDR_CHECK(ndr_pull_samr_UserInfo18(ndr, NDR_SCALARS, &r->info18));
3958 220 : break; }
3959 :
3960 242 : case 20: {
3961 242 : NDR_CHECK(ndr_pull_samr_UserInfo20(ndr, NDR_SCALARS, &r->info20));
3962 242 : break; }
3963 :
3964 5377 : case 21: {
3965 5377 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_SCALARS, &r->info21));
3966 5287 : break; }
3967 :
3968 76 : case 23: {
3969 76 : NDR_CHECK(ndr_pull_samr_UserInfo23(ndr, NDR_SCALARS, &r->info23));
3970 76 : break; }
3971 :
3972 191 : case 24: {
3973 191 : NDR_CHECK(ndr_pull_samr_UserInfo24(ndr, NDR_SCALARS, &r->info24));
3974 191 : break; }
3975 :
3976 751 : case 25: {
3977 751 : NDR_CHECK(ndr_pull_samr_UserInfo25(ndr, NDR_SCALARS, &r->info25));
3978 661 : break; }
3979 :
3980 99 : case 26: {
3981 99 : NDR_CHECK(ndr_pull_samr_UserInfo26(ndr, NDR_SCALARS, &r->info26));
3982 97 : break; }
3983 :
3984 24 : case 31: {
3985 24 : NDR_CHECK(ndr_pull_samr_UserInfo31(ndr, NDR_SCALARS, &r->info31));
3986 24 : break; }
3987 :
3988 72 : case 32: {
3989 72 : NDR_CHECK(ndr_pull_samr_UserInfo32(ndr, NDR_SCALARS, &r->info32));
3990 72 : break; }
3991 :
3992 0 : default:
3993 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
3994 : }
3995 : }
3996 18119 : if (ndr_flags & NDR_BUFFERS) {
3997 18119 : if (!(ndr_flags & NDR_SCALARS)) {
3998 : /* We didn't get it above, and the token is not needed after this. */
3999 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
4000 : }
4001 18119 : switch (level) {
4002 303 : case 1:
4003 303 : NDR_CHECK(ndr_pull_samr_UserInfo1(ndr, NDR_BUFFERS, &r->info1));
4004 303 : break;
4005 :
4006 430 : case 2:
4007 430 : NDR_CHECK(ndr_pull_samr_UserInfo2(ndr, NDR_BUFFERS, &r->info2));
4008 430 : break;
4009 :
4010 1686 : case 3:
4011 1686 : NDR_CHECK(ndr_pull_samr_UserInfo3(ndr, NDR_BUFFERS, &r->info3));
4012 1686 : break;
4013 :
4014 266 : case 4:
4015 266 : NDR_CHECK(ndr_pull_samr_UserInfo4(ndr, NDR_BUFFERS, &r->info4));
4016 266 : break;
4017 :
4018 1942 : case 5:
4019 1942 : NDR_CHECK(ndr_pull_samr_UserInfo5(ndr, NDR_BUFFERS, &r->info5));
4020 1942 : break;
4021 :
4022 774 : case 6:
4023 774 : NDR_CHECK(ndr_pull_samr_UserInfo6(ndr, NDR_BUFFERS, &r->info6));
4024 774 : break;
4025 :
4026 426 : case 7:
4027 426 : NDR_CHECK(ndr_pull_samr_UserInfo7(ndr, NDR_BUFFERS, &r->info7));
4028 426 : break;
4029 :
4030 264 : case 8:
4031 264 : NDR_CHECK(ndr_pull_samr_UserInfo8(ndr, NDR_BUFFERS, &r->info8));
4032 264 : break;
4033 :
4034 110 : case 9:
4035 110 : break;
4036 :
4037 498 : case 10:
4038 498 : NDR_CHECK(ndr_pull_samr_UserInfo10(ndr, NDR_BUFFERS, &r->info10));
4039 498 : break;
4040 :
4041 272 : case 11:
4042 272 : NDR_CHECK(ndr_pull_samr_UserInfo11(ndr, NDR_BUFFERS, &r->info11));
4043 272 : break;
4044 :
4045 288 : case 12:
4046 288 : NDR_CHECK(ndr_pull_samr_UserInfo12(ndr, NDR_BUFFERS, &r->info12));
4047 288 : break;
4048 :
4049 282 : case 13:
4050 282 : NDR_CHECK(ndr_pull_samr_UserInfo13(ndr, NDR_BUFFERS, &r->info13));
4051 282 : break;
4052 :
4053 280 : case 14:
4054 280 : NDR_CHECK(ndr_pull_samr_UserInfo14(ndr, NDR_BUFFERS, &r->info14));
4055 280 : break;
4056 :
4057 2912 : case 16:
4058 2912 : break;
4059 :
4060 240 : case 17:
4061 240 : break;
4062 :
4063 220 : case 18:
4064 220 : break;
4065 :
4066 242 : case 20:
4067 242 : NDR_CHECK(ndr_pull_samr_UserInfo20(ndr, NDR_BUFFERS, &r->info20));
4068 242 : break;
4069 :
4070 5377 : case 21:
4071 5377 : NDR_CHECK(ndr_pull_samr_UserInfo21(ndr, NDR_BUFFERS, &r->info21));
4072 5287 : break;
4073 :
4074 76 : case 23:
4075 76 : NDR_CHECK(ndr_pull_samr_UserInfo23(ndr, NDR_BUFFERS, &r->info23));
4076 76 : break;
4077 :
4078 191 : case 24:
4079 191 : break;
4080 :
4081 751 : case 25:
4082 751 : NDR_CHECK(ndr_pull_samr_UserInfo25(ndr, NDR_BUFFERS, &r->info25));
4083 661 : break;
4084 :
4085 97 : case 26:
4086 97 : break;
4087 :
4088 24 : case 31:
4089 24 : NDR_CHECK(ndr_pull_samr_UserInfo31(ndr, NDR_BUFFERS, &r->info31));
4090 24 : break;
4091 :
4092 72 : case 32:
4093 72 : NDR_CHECK(ndr_pull_samr_UserInfo32(ndr, NDR_BUFFERS, &r->info32));
4094 72 : break;
4095 :
4096 0 : default:
4097 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
4098 : }
4099 : }
4100 17843 : return NDR_ERR_SUCCESS;
4101 : }
4102 :
4103 448 : _PUBLIC_ void ndr_print_samr_UserInfo(struct ndr_print *ndr, const char *name, const union samr_UserInfo *r)
4104 : {
4105 42 : uint32_t level;
4106 448 : level = ndr_print_steal_switch_value(ndr, r);
4107 448 : ndr_print_union(ndr, name, level, "samr_UserInfo");
4108 448 : switch (level) {
4109 40 : case 1:
4110 40 : ndr_print_samr_UserInfo1(ndr, "info1", &r->info1);
4111 40 : break;
4112 :
4113 18 : case 2:
4114 18 : ndr_print_samr_UserInfo2(ndr, "info2", &r->info2);
4115 18 : break;
4116 :
4117 0 : case 3:
4118 0 : ndr_print_samr_UserInfo3(ndr, "info3", &r->info3);
4119 0 : break;
4120 :
4121 0 : case 4:
4122 0 : ndr_print_samr_UserInfo4(ndr, "info4", &r->info4);
4123 0 : break;
4124 :
4125 4 : case 5:
4126 4 : ndr_print_samr_UserInfo5(ndr, "info5", &r->info5);
4127 4 : break;
4128 :
4129 0 : case 6:
4130 0 : ndr_print_samr_UserInfo6(ndr, "info6", &r->info6);
4131 0 : break;
4132 :
4133 0 : case 7:
4134 0 : ndr_print_samr_UserInfo7(ndr, "info7", &r->info7);
4135 0 : break;
4136 :
4137 0 : case 8:
4138 0 : ndr_print_samr_UserInfo8(ndr, "info8", &r->info8);
4139 0 : break;
4140 :
4141 0 : case 9:
4142 0 : ndr_print_samr_UserInfo9(ndr, "info9", &r->info9);
4143 0 : break;
4144 :
4145 26 : case 10:
4146 26 : ndr_print_samr_UserInfo10(ndr, "info10", &r->info10);
4147 26 : break;
4148 :
4149 0 : case 11:
4150 0 : ndr_print_samr_UserInfo11(ndr, "info11", &r->info11);
4151 0 : break;
4152 :
4153 0 : case 12:
4154 0 : ndr_print_samr_UserInfo12(ndr, "info12", &r->info12);
4155 0 : break;
4156 :
4157 0 : case 13:
4158 0 : ndr_print_samr_UserInfo13(ndr, "info13", &r->info13);
4159 0 : break;
4160 :
4161 0 : case 14:
4162 0 : ndr_print_samr_UserInfo14(ndr, "info14", &r->info14);
4163 0 : break;
4164 :
4165 272 : case 16:
4166 272 : ndr_print_samr_UserInfo16(ndr, "info16", &r->info16);
4167 272 : break;
4168 :
4169 0 : case 17:
4170 0 : ndr_print_samr_UserInfo17(ndr, "info17", &r->info17);
4171 0 : break;
4172 :
4173 0 : case 18:
4174 0 : ndr_print_samr_UserInfo18(ndr, "info18", &r->info18);
4175 0 : break;
4176 :
4177 0 : case 20:
4178 0 : ndr_print_samr_UserInfo20(ndr, "info20", &r->info20);
4179 0 : break;
4180 :
4181 86 : case 21:
4182 86 : ndr_print_samr_UserInfo21(ndr, "info21", &r->info21);
4183 86 : break;
4184 :
4185 0 : case 23:
4186 0 : ndr_print_samr_UserInfo23(ndr, "info23", &r->info23);
4187 0 : break;
4188 :
4189 0 : case 24:
4190 0 : ndr_print_samr_UserInfo24(ndr, "info24", &r->info24);
4191 0 : break;
4192 :
4193 0 : case 25:
4194 0 : ndr_print_samr_UserInfo25(ndr, "info25", &r->info25);
4195 0 : break;
4196 :
4197 2 : case 26:
4198 2 : ndr_print_samr_UserInfo26(ndr, "info26", &r->info26);
4199 2 : break;
4200 :
4201 0 : case 31:
4202 0 : ndr_print_samr_UserInfo31(ndr, "info31", &r->info31);
4203 0 : break;
4204 :
4205 0 : case 32:
4206 0 : ndr_print_samr_UserInfo32(ndr, "info32", &r->info32);
4207 0 : break;
4208 :
4209 0 : default:
4210 0 : ndr_print_bad_level(ndr, name, level);
4211 : }
4212 448 : }
4213 :
4214 412520 : _PUBLIC_ enum ndr_err_code ndr_push_samr_RidWithAttribute(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_RidWithAttribute *r)
4215 : {
4216 412520 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4217 412520 : if (ndr_flags & NDR_SCALARS) {
4218 412520 : NDR_CHECK(ndr_push_align(ndr, 4));
4219 412520 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
4220 412520 : NDR_CHECK(ndr_push_security_GroupAttrs(ndr, NDR_SCALARS, r->attributes));
4221 412520 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
4222 : }
4223 412520 : if (ndr_flags & NDR_BUFFERS) {
4224 22283 : }
4225 412520 : return NDR_ERR_SUCCESS;
4226 : }
4227 :
4228 478430 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_RidWithAttribute(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_RidWithAttribute *r)
4229 : {
4230 478430 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4231 478430 : if (ndr_flags & NDR_SCALARS) {
4232 478430 : NDR_CHECK(ndr_pull_align(ndr, 4));
4233 478430 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
4234 478430 : NDR_CHECK(ndr_pull_security_GroupAttrs(ndr, NDR_SCALARS, &r->attributes));
4235 478430 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
4236 : }
4237 478430 : if (ndr_flags & NDR_BUFFERS) {
4238 18972 : }
4239 478430 : return NDR_ERR_SUCCESS;
4240 : }
4241 :
4242 0 : static void ndr_print_flags_samr_RidWithAttribute(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct samr_RidWithAttribute *r)
4243 : {
4244 0 : ndr_print_samr_RidWithAttribute(ndr, name, r);
4245 0 : }
4246 :
4247 19416 : _PUBLIC_ void ndr_print_samr_RidWithAttribute(struct ndr_print *ndr, const char *name, const struct samr_RidWithAttribute *r)
4248 : {
4249 19416 : ndr_print_struct(ndr, name, "samr_RidWithAttribute");
4250 19416 : if (r == NULL) { ndr_print_null(ndr); return; }
4251 19416 : ndr->depth++;
4252 19416 : ndr_print_uint32(ndr, "rid", r->rid);
4253 19416 : ndr_print_security_GroupAttrs(ndr, "attributes", r->attributes);
4254 19416 : ndr->depth--;
4255 : }
4256 :
4257 393402 : _PUBLIC_ enum ndr_err_code ndr_push_samr_RidWithAttributeArray(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_RidWithAttributeArray *r)
4258 : {
4259 15308 : uint32_t cntr_rids_1;
4260 393402 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4261 393402 : if (ndr_flags & NDR_SCALARS) {
4262 197830 : NDR_CHECK(ndr_push_align(ndr, 5));
4263 197830 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4264 197830 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->rids));
4265 197830 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4266 : }
4267 393402 : if (ndr_flags & NDR_BUFFERS) {
4268 197830 : if (r->rids) {
4269 125103 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4270 537623 : for (cntr_rids_1 = 0; cntr_rids_1 < (r->count); cntr_rids_1++) {
4271 412520 : NDR_CHECK(ndr_push_samr_RidWithAttribute(ndr, NDR_SCALARS, &r->rids[cntr_rids_1]));
4272 : }
4273 : }
4274 : }
4275 378094 : return NDR_ERR_SUCCESS;
4276 : }
4277 :
4278 645432 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_RidWithAttributeArray(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_RidWithAttributeArray *r)
4279 : {
4280 13476 : uint32_t _ptr_rids;
4281 645432 : uint32_t size_rids_1 = 0;
4282 13476 : uint32_t cntr_rids_1;
4283 645432 : TALLOC_CTX *_mem_save_rids_0 = NULL;
4284 645432 : TALLOC_CTX *_mem_save_rids_1 = NULL;
4285 645432 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4286 645432 : if (ndr_flags & NDR_SCALARS) {
4287 322966 : NDR_CHECK(ndr_pull_align(ndr, 5));
4288 322966 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4289 322966 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_rids));
4290 322966 : if (_ptr_rids) {
4291 251602 : NDR_PULL_ALLOC(ndr, r->rids);
4292 : } else {
4293 71364 : r->rids = NULL;
4294 : }
4295 322966 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4296 : }
4297 645432 : if (ndr_flags & NDR_BUFFERS) {
4298 322966 : if (r->rids) {
4299 251602 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
4300 251602 : NDR_PULL_SET_MEM_CTX(ndr, r->rids, 0);
4301 251602 : NDR_CHECK(ndr_pull_array_size(ndr, &r->rids));
4302 251602 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->rids, &size_rids_1));
4303 251602 : NDR_PULL_ALLOC_N(ndr, r->rids, size_rids_1);
4304 251602 : _mem_save_rids_1 = NDR_PULL_GET_MEM_CTX(ndr);
4305 251602 : NDR_PULL_SET_MEM_CTX(ndr, r->rids, 0);
4306 730032 : for (cntr_rids_1 = 0; cntr_rids_1 < (size_rids_1); cntr_rids_1++) {
4307 478430 : NDR_CHECK(ndr_pull_samr_RidWithAttribute(ndr, NDR_SCALARS, &r->rids[cntr_rids_1]));
4308 : }
4309 251602 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_1, 0);
4310 251602 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, 0);
4311 : }
4312 322966 : if (r->rids) {
4313 251602 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->rids, r->count));
4314 : }
4315 : }
4316 631956 : return NDR_ERR_SUCCESS;
4317 : }
4318 :
4319 0 : static void ndr_print_flags_samr_RidWithAttributeArray(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct samr_RidWithAttributeArray *r)
4320 : {
4321 0 : ndr_print_samr_RidWithAttributeArray(ndr, name, r);
4322 0 : }
4323 :
4324 3922 : _PUBLIC_ void ndr_print_samr_RidWithAttributeArray(struct ndr_print *ndr, const char *name, const struct samr_RidWithAttributeArray *r)
4325 : {
4326 670 : uint32_t cntr_rids_1;
4327 3922 : ndr_print_struct(ndr, name, "samr_RidWithAttributeArray");
4328 3922 : if (r == NULL) { ndr_print_null(ndr); return; }
4329 3922 : ndr->depth++;
4330 3922 : ndr_print_uint32(ndr, "count", r->count);
4331 3922 : ndr_print_ptr(ndr, "rids", r->rids);
4332 3922 : ndr->depth++;
4333 3922 : if (r->rids) {
4334 3909 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "rids", (uint32_t)(r->count));
4335 3909 : ndr->depth++;
4336 23325 : for (cntr_rids_1 = 0; cntr_rids_1 < (r->count); cntr_rids_1++) {
4337 19416 : ndr_print_samr_RidWithAttribute(ndr, "rids", &r->rids[cntr_rids_1]);
4338 : }
4339 3909 : ndr->depth--;
4340 : }
4341 3922 : ndr->depth--;
4342 3922 : ndr->depth--;
4343 : }
4344 :
4345 2566 : static enum ndr_err_code ndr_push_samr_DispEntryGeneral(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispEntryGeneral *r)
4346 : {
4347 2566 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4348 2566 : if (ndr_flags & NDR_SCALARS) {
4349 1283 : NDR_CHECK(ndr_push_align(ndr, 5));
4350 1283 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idx));
4351 1283 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
4352 1283 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->acct_flags));
4353 1283 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
4354 1283 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
4355 1283 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->full_name));
4356 1283 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4357 : }
4358 2566 : if (ndr_flags & NDR_BUFFERS) {
4359 1283 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
4360 1283 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
4361 1283 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
4362 : }
4363 2566 : return NDR_ERR_SUCCESS;
4364 : }
4365 :
4366 3358 : static enum ndr_err_code ndr_pull_samr_DispEntryGeneral(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispEntryGeneral *r)
4367 : {
4368 3358 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4369 3358 : if (ndr_flags & NDR_SCALARS) {
4370 1679 : NDR_CHECK(ndr_pull_align(ndr, 5));
4371 1679 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idx));
4372 1679 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
4373 1679 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->acct_flags));
4374 1679 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
4375 1679 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
4376 1679 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->full_name));
4377 1679 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4378 : }
4379 3358 : if (ndr_flags & NDR_BUFFERS) {
4380 1679 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
4381 1679 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
4382 1679 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->full_name));
4383 : }
4384 3358 : return NDR_ERR_SUCCESS;
4385 : }
4386 :
4387 24 : _PUBLIC_ void ndr_print_samr_DispEntryGeneral(struct ndr_print *ndr, const char *name, const struct samr_DispEntryGeneral *r)
4388 : {
4389 24 : ndr_print_struct(ndr, name, "samr_DispEntryGeneral");
4390 24 : if (r == NULL) { ndr_print_null(ndr); return; }
4391 24 : ndr->depth++;
4392 24 : ndr_print_uint32(ndr, "idx", r->idx);
4393 24 : ndr_print_uint32(ndr, "rid", r->rid);
4394 24 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->acct_flags);
4395 24 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
4396 24 : ndr_print_lsa_String(ndr, "description", &r->description);
4397 24 : ndr_print_lsa_String(ndr, "full_name", &r->full_name);
4398 24 : ndr->depth--;
4399 : }
4400 :
4401 290 : static enum ndr_err_code ndr_push_samr_DispInfoGeneral(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispInfoGeneral *r)
4402 : {
4403 0 : uint32_t cntr_entries_1;
4404 290 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4405 290 : if (ndr_flags & NDR_SCALARS) {
4406 145 : NDR_CHECK(ndr_push_align(ndr, 5));
4407 145 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4408 145 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries));
4409 145 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4410 : }
4411 290 : if (ndr_flags & NDR_BUFFERS) {
4412 145 : if (r->entries) {
4413 138 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4414 1421 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4415 1283 : NDR_CHECK(ndr_push_samr_DispEntryGeneral(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4416 : }
4417 1421 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4418 1283 : NDR_CHECK(ndr_push_samr_DispEntryGeneral(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4419 : }
4420 : }
4421 : }
4422 290 : return NDR_ERR_SUCCESS;
4423 : }
4424 :
4425 392 : static enum ndr_err_code ndr_pull_samr_DispInfoGeneral(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispInfoGeneral *r)
4426 : {
4427 0 : uint32_t _ptr_entries;
4428 392 : uint32_t size_entries_1 = 0;
4429 0 : uint32_t cntr_entries_1;
4430 392 : TALLOC_CTX *_mem_save_entries_0 = NULL;
4431 392 : TALLOC_CTX *_mem_save_entries_1 = NULL;
4432 392 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4433 392 : if (ndr_flags & NDR_SCALARS) {
4434 196 : NDR_CHECK(ndr_pull_align(ndr, 5));
4435 196 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4436 196 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
4437 196 : if (_ptr_entries) {
4438 177 : NDR_PULL_ALLOC(ndr, r->entries);
4439 : } else {
4440 19 : r->entries = NULL;
4441 : }
4442 196 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4443 : }
4444 392 : if (ndr_flags & NDR_BUFFERS) {
4445 196 : if (r->entries) {
4446 177 : _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
4447 177 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4448 177 : NDR_CHECK(ndr_pull_array_size(ndr, &r->entries));
4449 177 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->entries, &size_entries_1));
4450 177 : NDR_PULL_ALLOC_N(ndr, r->entries, size_entries_1);
4451 177 : _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
4452 177 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4453 1856 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4454 1679 : NDR_CHECK(ndr_pull_samr_DispEntryGeneral(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4455 : }
4456 1856 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4457 1679 : NDR_CHECK(ndr_pull_samr_DispEntryGeneral(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4458 : }
4459 177 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0);
4460 177 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
4461 : }
4462 196 : if (r->entries) {
4463 177 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count));
4464 : }
4465 1875 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4466 0 : }
4467 : }
4468 392 : return NDR_ERR_SUCCESS;
4469 : }
4470 :
4471 2 : _PUBLIC_ void ndr_print_samr_DispInfoGeneral(struct ndr_print *ndr, const char *name, const struct samr_DispInfoGeneral *r)
4472 : {
4473 0 : uint32_t cntr_entries_1;
4474 2 : ndr_print_struct(ndr, name, "samr_DispInfoGeneral");
4475 2 : if (r == NULL) { ndr_print_null(ndr); return; }
4476 2 : ndr->depth++;
4477 2 : ndr_print_uint32(ndr, "count", r->count);
4478 2 : ndr_print_ptr(ndr, "entries", r->entries);
4479 2 : ndr->depth++;
4480 2 : if (r->entries) {
4481 2 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "entries", (uint32_t)(r->count));
4482 2 : ndr->depth++;
4483 26 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4484 24 : ndr_print_samr_DispEntryGeneral(ndr, "entries", &r->entries[cntr_entries_1]);
4485 : }
4486 2 : ndr->depth--;
4487 : }
4488 2 : ndr->depth--;
4489 2 : ndr->depth--;
4490 : }
4491 :
4492 102 : static enum ndr_err_code ndr_push_samr_DispEntryFull(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispEntryFull *r)
4493 : {
4494 102 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4495 102 : if (ndr_flags & NDR_SCALARS) {
4496 51 : NDR_CHECK(ndr_push_align(ndr, 5));
4497 51 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idx));
4498 51 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
4499 51 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->acct_flags));
4500 51 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
4501 51 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
4502 51 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4503 : }
4504 102 : if (ndr_flags & NDR_BUFFERS) {
4505 51 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
4506 51 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
4507 : }
4508 102 : return NDR_ERR_SUCCESS;
4509 : }
4510 :
4511 114 : static enum ndr_err_code ndr_pull_samr_DispEntryFull(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispEntryFull *r)
4512 : {
4513 114 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4514 114 : if (ndr_flags & NDR_SCALARS) {
4515 57 : NDR_CHECK(ndr_pull_align(ndr, 5));
4516 57 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idx));
4517 57 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
4518 57 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->acct_flags));
4519 57 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
4520 57 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
4521 57 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4522 : }
4523 114 : if (ndr_flags & NDR_BUFFERS) {
4524 57 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
4525 57 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
4526 : }
4527 114 : return NDR_ERR_SUCCESS;
4528 : }
4529 :
4530 0 : _PUBLIC_ void ndr_print_samr_DispEntryFull(struct ndr_print *ndr, const char *name, const struct samr_DispEntryFull *r)
4531 : {
4532 0 : ndr_print_struct(ndr, name, "samr_DispEntryFull");
4533 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4534 0 : ndr->depth++;
4535 0 : ndr_print_uint32(ndr, "idx", r->idx);
4536 0 : ndr_print_uint32(ndr, "rid", r->rid);
4537 0 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->acct_flags);
4538 0 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
4539 0 : ndr_print_lsa_String(ndr, "description", &r->description);
4540 0 : ndr->depth--;
4541 : }
4542 :
4543 54 : static enum ndr_err_code ndr_push_samr_DispInfoFull(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispInfoFull *r)
4544 : {
4545 0 : uint32_t cntr_entries_1;
4546 54 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4547 54 : if (ndr_flags & NDR_SCALARS) {
4548 27 : NDR_CHECK(ndr_push_align(ndr, 5));
4549 27 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4550 27 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries));
4551 27 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4552 : }
4553 54 : if (ndr_flags & NDR_BUFFERS) {
4554 27 : if (r->entries) {
4555 26 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4556 77 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4557 51 : NDR_CHECK(ndr_push_samr_DispEntryFull(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4558 : }
4559 77 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4560 51 : NDR_CHECK(ndr_push_samr_DispEntryFull(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4561 : }
4562 : }
4563 : }
4564 54 : return NDR_ERR_SUCCESS;
4565 : }
4566 :
4567 78 : static enum ndr_err_code ndr_pull_samr_DispInfoFull(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispInfoFull *r)
4568 : {
4569 0 : uint32_t _ptr_entries;
4570 78 : uint32_t size_entries_1 = 0;
4571 0 : uint32_t cntr_entries_1;
4572 78 : TALLOC_CTX *_mem_save_entries_0 = NULL;
4573 78 : TALLOC_CTX *_mem_save_entries_1 = NULL;
4574 78 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4575 78 : if (ndr_flags & NDR_SCALARS) {
4576 39 : NDR_CHECK(ndr_pull_align(ndr, 5));
4577 39 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4578 39 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
4579 39 : if (_ptr_entries) {
4580 32 : NDR_PULL_ALLOC(ndr, r->entries);
4581 : } else {
4582 7 : r->entries = NULL;
4583 : }
4584 39 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4585 : }
4586 78 : if (ndr_flags & NDR_BUFFERS) {
4587 39 : if (r->entries) {
4588 32 : _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
4589 32 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4590 32 : NDR_CHECK(ndr_pull_array_size(ndr, &r->entries));
4591 32 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->entries, &size_entries_1));
4592 32 : NDR_PULL_ALLOC_N(ndr, r->entries, size_entries_1);
4593 32 : _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
4594 32 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4595 89 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4596 57 : NDR_CHECK(ndr_pull_samr_DispEntryFull(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4597 : }
4598 89 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4599 57 : NDR_CHECK(ndr_pull_samr_DispEntryFull(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4600 : }
4601 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0);
4602 32 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
4603 : }
4604 39 : if (r->entries) {
4605 32 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count));
4606 : }
4607 96 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4608 0 : }
4609 : }
4610 78 : return NDR_ERR_SUCCESS;
4611 : }
4612 :
4613 0 : _PUBLIC_ void ndr_print_samr_DispInfoFull(struct ndr_print *ndr, const char *name, const struct samr_DispInfoFull *r)
4614 : {
4615 0 : uint32_t cntr_entries_1;
4616 0 : ndr_print_struct(ndr, name, "samr_DispInfoFull");
4617 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4618 0 : ndr->depth++;
4619 0 : ndr_print_uint32(ndr, "count", r->count);
4620 0 : ndr_print_ptr(ndr, "entries", r->entries);
4621 0 : ndr->depth++;
4622 0 : if (r->entries) {
4623 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "entries", (uint32_t)(r->count));
4624 0 : ndr->depth++;
4625 0 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4626 0 : ndr_print_samr_DispEntryFull(ndr, "entries", &r->entries[cntr_entries_1]);
4627 : }
4628 0 : ndr->depth--;
4629 : }
4630 0 : ndr->depth--;
4631 0 : ndr->depth--;
4632 : }
4633 :
4634 2420 : static enum ndr_err_code ndr_push_samr_DispEntryFullGroup(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispEntryFullGroup *r)
4635 : {
4636 2420 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4637 2420 : if (ndr_flags & NDR_SCALARS) {
4638 1210 : NDR_CHECK(ndr_push_align(ndr, 5));
4639 1210 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idx));
4640 1210 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->rid));
4641 1210 : NDR_CHECK(ndr_push_security_GroupAttrs(ndr, NDR_SCALARS, r->acct_flags));
4642 1210 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->account_name));
4643 1210 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->description));
4644 1210 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4645 : }
4646 2420 : if (ndr_flags & NDR_BUFFERS) {
4647 1210 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
4648 1210 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->description));
4649 : }
4650 2420 : return NDR_ERR_SUCCESS;
4651 : }
4652 :
4653 2452 : static enum ndr_err_code ndr_pull_samr_DispEntryFullGroup(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispEntryFullGroup *r)
4654 : {
4655 2452 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4656 2452 : if (ndr_flags & NDR_SCALARS) {
4657 1226 : NDR_CHECK(ndr_pull_align(ndr, 5));
4658 1226 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idx));
4659 1226 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->rid));
4660 1226 : NDR_CHECK(ndr_pull_security_GroupAttrs(ndr, NDR_SCALARS, &r->acct_flags));
4661 1226 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->account_name));
4662 1226 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->description));
4663 1226 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4664 : }
4665 2452 : if (ndr_flags & NDR_BUFFERS) {
4666 1226 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->account_name));
4667 1226 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->description));
4668 : }
4669 2452 : return NDR_ERR_SUCCESS;
4670 : }
4671 :
4672 0 : _PUBLIC_ void ndr_print_samr_DispEntryFullGroup(struct ndr_print *ndr, const char *name, const struct samr_DispEntryFullGroup *r)
4673 : {
4674 0 : ndr_print_struct(ndr, name, "samr_DispEntryFullGroup");
4675 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4676 0 : ndr->depth++;
4677 0 : ndr_print_uint32(ndr, "idx", r->idx);
4678 0 : ndr_print_uint32(ndr, "rid", r->rid);
4679 0 : ndr_print_security_GroupAttrs(ndr, "acct_flags", r->acct_flags);
4680 0 : ndr_print_lsa_String(ndr, "account_name", &r->account_name);
4681 0 : ndr_print_lsa_String(ndr, "description", &r->description);
4682 0 : ndr->depth--;
4683 : }
4684 :
4685 146 : static enum ndr_err_code ndr_push_samr_DispInfoFullGroups(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispInfoFullGroups *r)
4686 : {
4687 0 : uint32_t cntr_entries_1;
4688 146 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4689 146 : if (ndr_flags & NDR_SCALARS) {
4690 73 : NDR_CHECK(ndr_push_align(ndr, 5));
4691 73 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4692 73 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries));
4693 73 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4694 : }
4695 146 : if (ndr_flags & NDR_BUFFERS) {
4696 73 : if (r->entries) {
4697 70 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4698 1280 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4699 1210 : NDR_CHECK(ndr_push_samr_DispEntryFullGroup(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4700 : }
4701 1280 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4702 1210 : NDR_CHECK(ndr_push_samr_DispEntryFullGroup(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4703 : }
4704 : }
4705 : }
4706 146 : return NDR_ERR_SUCCESS;
4707 : }
4708 :
4709 174 : static enum ndr_err_code ndr_pull_samr_DispInfoFullGroups(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispInfoFullGroups *r)
4710 : {
4711 0 : uint32_t _ptr_entries;
4712 174 : uint32_t size_entries_1 = 0;
4713 0 : uint32_t cntr_entries_1;
4714 174 : TALLOC_CTX *_mem_save_entries_0 = NULL;
4715 174 : TALLOC_CTX *_mem_save_entries_1 = NULL;
4716 174 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4717 174 : if (ndr_flags & NDR_SCALARS) {
4718 87 : NDR_CHECK(ndr_pull_align(ndr, 5));
4719 87 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4720 87 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
4721 87 : if (_ptr_entries) {
4722 76 : NDR_PULL_ALLOC(ndr, r->entries);
4723 : } else {
4724 11 : r->entries = NULL;
4725 : }
4726 87 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4727 : }
4728 174 : if (ndr_flags & NDR_BUFFERS) {
4729 87 : if (r->entries) {
4730 76 : _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
4731 76 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4732 76 : NDR_CHECK(ndr_pull_array_size(ndr, &r->entries));
4733 76 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->entries, &size_entries_1));
4734 76 : NDR_PULL_ALLOC_N(ndr, r->entries, size_entries_1);
4735 76 : _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
4736 76 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4737 1302 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4738 1226 : NDR_CHECK(ndr_pull_samr_DispEntryFullGroup(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4739 : }
4740 1302 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4741 1226 : NDR_CHECK(ndr_pull_samr_DispEntryFullGroup(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4742 : }
4743 76 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0);
4744 76 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
4745 : }
4746 87 : if (r->entries) {
4747 76 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count));
4748 : }
4749 1313 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4750 0 : }
4751 : }
4752 174 : return NDR_ERR_SUCCESS;
4753 : }
4754 :
4755 0 : _PUBLIC_ void ndr_print_samr_DispInfoFullGroups(struct ndr_print *ndr, const char *name, const struct samr_DispInfoFullGroups *r)
4756 : {
4757 0 : uint32_t cntr_entries_1;
4758 0 : ndr_print_struct(ndr, name, "samr_DispInfoFullGroups");
4759 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4760 0 : ndr->depth++;
4761 0 : ndr_print_uint32(ndr, "count", r->count);
4762 0 : ndr_print_ptr(ndr, "entries", r->entries);
4763 0 : ndr->depth++;
4764 0 : if (r->entries) {
4765 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "entries", (uint32_t)(r->count));
4766 0 : ndr->depth++;
4767 0 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4768 0 : ndr_print_samr_DispEntryFullGroup(ndr, "entries", &r->entries[cntr_entries_1]);
4769 : }
4770 0 : ndr->depth--;
4771 : }
4772 0 : ndr->depth--;
4773 0 : ndr->depth--;
4774 : }
4775 :
4776 1388 : static enum ndr_err_code ndr_push_samr_DispEntryAscii(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispEntryAscii *r)
4777 : {
4778 1388 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4779 1388 : if (ndr_flags & NDR_SCALARS) {
4780 694 : NDR_CHECK(ndr_push_align(ndr, 5));
4781 694 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->idx));
4782 694 : NDR_CHECK(ndr_push_lsa_AsciiStringLarge(ndr, NDR_SCALARS, &r->account_name));
4783 694 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4784 : }
4785 1388 : if (ndr_flags & NDR_BUFFERS) {
4786 694 : NDR_CHECK(ndr_push_lsa_AsciiStringLarge(ndr, NDR_BUFFERS, &r->account_name));
4787 : }
4788 1388 : return NDR_ERR_SUCCESS;
4789 : }
4790 :
4791 1564 : static enum ndr_err_code ndr_pull_samr_DispEntryAscii(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispEntryAscii *r)
4792 : {
4793 1564 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4794 1564 : if (ndr_flags & NDR_SCALARS) {
4795 782 : NDR_CHECK(ndr_pull_align(ndr, 5));
4796 782 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->idx));
4797 782 : NDR_CHECK(ndr_pull_lsa_AsciiStringLarge(ndr, NDR_SCALARS, &r->account_name));
4798 782 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4799 : }
4800 1564 : if (ndr_flags & NDR_BUFFERS) {
4801 782 : NDR_CHECK(ndr_pull_lsa_AsciiStringLarge(ndr, NDR_BUFFERS, &r->account_name));
4802 : }
4803 1564 : return NDR_ERR_SUCCESS;
4804 : }
4805 :
4806 0 : _PUBLIC_ void ndr_print_samr_DispEntryAscii(struct ndr_print *ndr, const char *name, const struct samr_DispEntryAscii *r)
4807 : {
4808 0 : ndr_print_struct(ndr, name, "samr_DispEntryAscii");
4809 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4810 0 : ndr->depth++;
4811 0 : ndr_print_uint32(ndr, "idx", r->idx);
4812 0 : ndr_print_lsa_AsciiStringLarge(ndr, "account_name", &r->account_name);
4813 0 : ndr->depth--;
4814 : }
4815 :
4816 268 : static enum ndr_err_code ndr_push_samr_DispInfoAscii(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_DispInfoAscii *r)
4817 : {
4818 0 : uint32_t cntr_entries_1;
4819 268 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4820 268 : if (ndr_flags & NDR_SCALARS) {
4821 134 : NDR_CHECK(ndr_push_align(ndr, 5));
4822 134 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->count));
4823 134 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->entries));
4824 134 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
4825 : }
4826 268 : if (ndr_flags & NDR_BUFFERS) {
4827 134 : if (r->entries) {
4828 132 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->count));
4829 826 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4830 694 : NDR_CHECK(ndr_push_samr_DispEntryAscii(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4831 : }
4832 826 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4833 694 : NDR_CHECK(ndr_push_samr_DispEntryAscii(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4834 : }
4835 : }
4836 : }
4837 268 : return NDR_ERR_SUCCESS;
4838 : }
4839 :
4840 348 : static enum ndr_err_code ndr_pull_samr_DispInfoAscii(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_DispInfoAscii *r)
4841 : {
4842 0 : uint32_t _ptr_entries;
4843 348 : uint32_t size_entries_1 = 0;
4844 0 : uint32_t cntr_entries_1;
4845 348 : TALLOC_CTX *_mem_save_entries_0 = NULL;
4846 348 : TALLOC_CTX *_mem_save_entries_1 = NULL;
4847 348 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4848 348 : if (ndr_flags & NDR_SCALARS) {
4849 174 : NDR_CHECK(ndr_pull_align(ndr, 5));
4850 174 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->count));
4851 174 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_entries));
4852 174 : if (_ptr_entries) {
4853 156 : NDR_PULL_ALLOC(ndr, r->entries);
4854 : } else {
4855 18 : r->entries = NULL;
4856 : }
4857 174 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
4858 : }
4859 348 : if (ndr_flags & NDR_BUFFERS) {
4860 174 : if (r->entries) {
4861 156 : _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
4862 156 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4863 156 : NDR_CHECK(ndr_pull_array_size(ndr, &r->entries));
4864 156 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->entries, &size_entries_1));
4865 156 : NDR_PULL_ALLOC_N(ndr, r->entries, size_entries_1);
4866 156 : _mem_save_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
4867 156 : NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
4868 938 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4869 782 : NDR_CHECK(ndr_pull_samr_DispEntryAscii(ndr, NDR_SCALARS, &r->entries[cntr_entries_1]));
4870 : }
4871 938 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4872 782 : NDR_CHECK(ndr_pull_samr_DispEntryAscii(ndr, NDR_BUFFERS, &r->entries[cntr_entries_1]));
4873 : }
4874 156 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_1, 0);
4875 156 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
4876 : }
4877 174 : if (r->entries) {
4878 156 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->entries, r->count));
4879 : }
4880 956 : for (cntr_entries_1 = 0; cntr_entries_1 < (size_entries_1); cntr_entries_1++) {
4881 0 : }
4882 : }
4883 348 : return NDR_ERR_SUCCESS;
4884 : }
4885 :
4886 0 : _PUBLIC_ void ndr_print_samr_DispInfoAscii(struct ndr_print *ndr, const char *name, const struct samr_DispInfoAscii *r)
4887 : {
4888 0 : uint32_t cntr_entries_1;
4889 0 : ndr_print_struct(ndr, name, "samr_DispInfoAscii");
4890 0 : if (r == NULL) { ndr_print_null(ndr); return; }
4891 0 : ndr->depth++;
4892 0 : ndr_print_uint32(ndr, "count", r->count);
4893 0 : ndr_print_ptr(ndr, "entries", r->entries);
4894 0 : ndr->depth++;
4895 0 : if (r->entries) {
4896 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "entries", (uint32_t)(r->count));
4897 0 : ndr->depth++;
4898 0 : for (cntr_entries_1 = 0; cntr_entries_1 < (r->count); cntr_entries_1++) {
4899 0 : ndr_print_samr_DispEntryAscii(ndr, "entries", &r->entries[cntr_entries_1]);
4900 : }
4901 0 : ndr->depth--;
4902 : }
4903 0 : ndr->depth--;
4904 0 : ndr->depth--;
4905 : }
4906 :
4907 379 : static enum ndr_err_code ndr_push_samr_DispInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_DispInfo *r)
4908 : {
4909 0 : uint32_t level;
4910 379 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
4911 379 : if (ndr_flags & NDR_SCALARS) {
4912 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
4913 379 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
4914 379 : NDR_CHECK(ndr_push_union_align(ndr, 5));
4915 379 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
4916 379 : NDR_CHECK(ndr_push_union_align(ndr, 5));
4917 379 : switch (level) {
4918 145 : case 1: {
4919 145 : NDR_CHECK(ndr_push_samr_DispInfoGeneral(ndr, NDR_SCALARS, &r->info1));
4920 145 : break; }
4921 :
4922 27 : case 2: {
4923 27 : NDR_CHECK(ndr_push_samr_DispInfoFull(ndr, NDR_SCALARS, &r->info2));
4924 27 : break; }
4925 :
4926 73 : case 3: {
4927 73 : NDR_CHECK(ndr_push_samr_DispInfoFullGroups(ndr, NDR_SCALARS, &r->info3));
4928 73 : break; }
4929 :
4930 57 : case 4: {
4931 57 : NDR_CHECK(ndr_push_samr_DispInfoAscii(ndr, NDR_SCALARS, &r->info4));
4932 57 : break; }
4933 :
4934 77 : case 5: {
4935 77 : NDR_CHECK(ndr_push_samr_DispInfoAscii(ndr, NDR_SCALARS, &r->info5));
4936 77 : break; }
4937 :
4938 0 : default:
4939 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
4940 : }
4941 : }
4942 379 : if (ndr_flags & NDR_BUFFERS) {
4943 379 : if (!(ndr_flags & NDR_SCALARS)) {
4944 : /* We didn't get it above, and the token is not needed after this. */
4945 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
4946 : }
4947 379 : switch (level) {
4948 145 : case 1:
4949 145 : NDR_CHECK(ndr_push_samr_DispInfoGeneral(ndr, NDR_BUFFERS, &r->info1));
4950 145 : break;
4951 :
4952 27 : case 2:
4953 27 : NDR_CHECK(ndr_push_samr_DispInfoFull(ndr, NDR_BUFFERS, &r->info2));
4954 27 : break;
4955 :
4956 73 : case 3:
4957 73 : NDR_CHECK(ndr_push_samr_DispInfoFullGroups(ndr, NDR_BUFFERS, &r->info3));
4958 73 : break;
4959 :
4960 57 : case 4:
4961 57 : NDR_CHECK(ndr_push_samr_DispInfoAscii(ndr, NDR_BUFFERS, &r->info4));
4962 57 : break;
4963 :
4964 77 : case 5:
4965 77 : NDR_CHECK(ndr_push_samr_DispInfoAscii(ndr, NDR_BUFFERS, &r->info5));
4966 77 : break;
4967 :
4968 0 : default:
4969 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
4970 : }
4971 : }
4972 379 : return NDR_ERR_SUCCESS;
4973 : }
4974 :
4975 496 : static enum ndr_err_code ndr_pull_samr_DispInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_DispInfo *r)
4976 : {
4977 0 : uint32_t level;
4978 0 : uint16_t _level;
4979 496 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
4980 496 : if (ndr_flags & NDR_SCALARS) {
4981 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
4982 496 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
4983 496 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
4984 496 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
4985 496 : if (_level != level) {
4986 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
4987 : }
4988 496 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
4989 496 : switch (level) {
4990 196 : case 1: {
4991 196 : NDR_CHECK(ndr_pull_samr_DispInfoGeneral(ndr, NDR_SCALARS, &r->info1));
4992 196 : break; }
4993 :
4994 39 : case 2: {
4995 39 : NDR_CHECK(ndr_pull_samr_DispInfoFull(ndr, NDR_SCALARS, &r->info2));
4996 39 : break; }
4997 :
4998 87 : case 3: {
4999 87 : NDR_CHECK(ndr_pull_samr_DispInfoFullGroups(ndr, NDR_SCALARS, &r->info3));
5000 87 : break; }
5001 :
5002 79 : case 4: {
5003 79 : NDR_CHECK(ndr_pull_samr_DispInfoAscii(ndr, NDR_SCALARS, &r->info4));
5004 79 : break; }
5005 :
5006 95 : case 5: {
5007 95 : NDR_CHECK(ndr_pull_samr_DispInfoAscii(ndr, NDR_SCALARS, &r->info5));
5008 95 : break; }
5009 :
5010 0 : default:
5011 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
5012 : }
5013 : }
5014 496 : if (ndr_flags & NDR_BUFFERS) {
5015 496 : if (!(ndr_flags & NDR_SCALARS)) {
5016 : /* We didn't get it above, and the token is not needed after this. */
5017 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
5018 : }
5019 496 : switch (level) {
5020 196 : case 1:
5021 196 : NDR_CHECK(ndr_pull_samr_DispInfoGeneral(ndr, NDR_BUFFERS, &r->info1));
5022 196 : break;
5023 :
5024 39 : case 2:
5025 39 : NDR_CHECK(ndr_pull_samr_DispInfoFull(ndr, NDR_BUFFERS, &r->info2));
5026 39 : break;
5027 :
5028 87 : case 3:
5029 87 : NDR_CHECK(ndr_pull_samr_DispInfoFullGroups(ndr, NDR_BUFFERS, &r->info3));
5030 87 : break;
5031 :
5032 79 : case 4:
5033 79 : NDR_CHECK(ndr_pull_samr_DispInfoAscii(ndr, NDR_BUFFERS, &r->info4));
5034 79 : break;
5035 :
5036 95 : case 5:
5037 95 : NDR_CHECK(ndr_pull_samr_DispInfoAscii(ndr, NDR_BUFFERS, &r->info5));
5038 95 : break;
5039 :
5040 0 : default:
5041 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
5042 : }
5043 : }
5044 496 : return NDR_ERR_SUCCESS;
5045 : }
5046 :
5047 2 : _PUBLIC_ void ndr_print_samr_DispInfo(struct ndr_print *ndr, const char *name, const union samr_DispInfo *r)
5048 : {
5049 0 : uint32_t level;
5050 2 : level = ndr_print_steal_switch_value(ndr, r);
5051 2 : ndr_print_union(ndr, name, level, "samr_DispInfo");
5052 2 : switch (level) {
5053 2 : case 1:
5054 2 : ndr_print_samr_DispInfoGeneral(ndr, "info1", &r->info1);
5055 2 : break;
5056 :
5057 0 : case 2:
5058 0 : ndr_print_samr_DispInfoFull(ndr, "info2", &r->info2);
5059 0 : break;
5060 :
5061 0 : case 3:
5062 0 : ndr_print_samr_DispInfoFullGroups(ndr, "info3", &r->info3);
5063 0 : break;
5064 :
5065 0 : case 4:
5066 0 : ndr_print_samr_DispInfoAscii(ndr, "info4", &r->info4);
5067 0 : break;
5068 :
5069 0 : case 5:
5070 0 : ndr_print_samr_DispInfoAscii(ndr, "info5", &r->info5);
5071 0 : break;
5072 :
5073 0 : default:
5074 0 : ndr_print_bad_level(ndr, name, level);
5075 : }
5076 2 : }
5077 :
5078 5975 : static enum ndr_err_code ndr_push_samr_PwInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_PwInfo *r)
5079 : {
5080 5975 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5081 5975 : if (ndr_flags & NDR_SCALARS) {
5082 5975 : NDR_CHECK(ndr_push_align(ndr, 4));
5083 5975 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->min_password_length));
5084 5975 : NDR_CHECK(ndr_push_samr_PasswordProperties(ndr, NDR_SCALARS, r->password_properties));
5085 5975 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
5086 : }
5087 5975 : if (ndr_flags & NDR_BUFFERS) {
5088 828 : }
5089 5975 : return NDR_ERR_SUCCESS;
5090 : }
5091 :
5092 5705 : static enum ndr_err_code ndr_pull_samr_PwInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_PwInfo *r)
5093 : {
5094 5705 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5095 5705 : if (ndr_flags & NDR_SCALARS) {
5096 5705 : NDR_CHECK(ndr_pull_align(ndr, 4));
5097 5705 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->min_password_length));
5098 5705 : NDR_CHECK(ndr_pull_samr_PasswordProperties(ndr, NDR_SCALARS, &r->password_properties));
5099 5705 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
5100 : }
5101 5705 : if (ndr_flags & NDR_BUFFERS) {
5102 692 : }
5103 5705 : return NDR_ERR_SUCCESS;
5104 : }
5105 :
5106 1690 : _PUBLIC_ void ndr_print_samr_PwInfo(struct ndr_print *ndr, const char *name, const struct samr_PwInfo *r)
5107 : {
5108 1690 : ndr_print_struct(ndr, name, "samr_PwInfo");
5109 1690 : if (r == NULL) { ndr_print_null(ndr); return; }
5110 1690 : ndr->depth++;
5111 1690 : ndr_print_uint16(ndr, "min_password_length", r->min_password_length);
5112 1690 : ndr_print_samr_PasswordProperties(ndr, "password_properties", r->password_properties);
5113 1690 : ndr->depth--;
5114 : }
5115 :
5116 527 : static enum ndr_err_code ndr_push_samr_ConnectVersion(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_ConnectVersion r)
5117 : {
5118 527 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
5119 527 : return NDR_ERR_SUCCESS;
5120 : }
5121 :
5122 480 : static enum ndr_err_code ndr_pull_samr_ConnectVersion(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_ConnectVersion *r)
5123 : {
5124 4 : uint32_t v;
5125 480 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
5126 480 : *r = v;
5127 480 : return NDR_ERR_SUCCESS;
5128 : }
5129 :
5130 10 : _PUBLIC_ void ndr_print_samr_ConnectVersion(struct ndr_print *ndr, const char *name, enum samr_ConnectVersion r)
5131 : {
5132 10 : const char *val = NULL;
5133 :
5134 10 : switch (r) {
5135 0 : case SAMR_CONNECT_PRE_W2K: val = "SAMR_CONNECT_PRE_W2K"; break;
5136 0 : case SAMR_CONNECT_W2K: val = "SAMR_CONNECT_W2K"; break;
5137 10 : case SAMR_CONNECT_AFTER_W2K: val = "SAMR_CONNECT_AFTER_W2K"; break;
5138 : }
5139 10 : ndr_print_enum(ndr, name, "ENUM", val, r);
5140 10 : }
5141 :
5142 1061 : _PUBLIC_ enum ndr_err_code ndr_push_samPwdChangeReason(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samPwdChangeReason r)
5143 : {
5144 1061 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
5145 1061 : return NDR_ERR_SUCCESS;
5146 : }
5147 :
5148 1067 : _PUBLIC_ enum ndr_err_code ndr_pull_samPwdChangeReason(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samPwdChangeReason *r)
5149 : {
5150 2 : uint32_t v;
5151 1067 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
5152 1067 : *r = v;
5153 1067 : return NDR_ERR_SUCCESS;
5154 : }
5155 :
5156 2 : _PUBLIC_ void ndr_print_samPwdChangeReason(struct ndr_print *ndr, const char *name, enum samPwdChangeReason r)
5157 : {
5158 2 : const char *val = NULL;
5159 :
5160 2 : switch (r) {
5161 0 : case SAM_PWD_CHANGE_NO_ERROR: val = "SAM_PWD_CHANGE_NO_ERROR"; break;
5162 0 : case SAM_PWD_CHANGE_PASSWORD_TOO_SHORT: val = "SAM_PWD_CHANGE_PASSWORD_TOO_SHORT"; break;
5163 0 : case SAM_PWD_CHANGE_PWD_IN_HISTORY: val = "SAM_PWD_CHANGE_PWD_IN_HISTORY"; break;
5164 0 : case SAM_PWD_CHANGE_USERNAME_IN_PASSWORD: val = "SAM_PWD_CHANGE_USERNAME_IN_PASSWORD"; break;
5165 0 : case SAM_PWD_CHANGE_FULLNAME_IN_PASSWORD: val = "SAM_PWD_CHANGE_FULLNAME_IN_PASSWORD"; break;
5166 2 : case SAM_PWD_CHANGE_NOT_COMPLEX: val = "SAM_PWD_CHANGE_NOT_COMPLEX"; break;
5167 0 : case SAM_PWD_CHANGE_MACHINE_NOT_DEFAULT: val = "SAM_PWD_CHANGE_MACHINE_NOT_DEFAULT"; break;
5168 0 : case SAM_PWD_CHANGE_FAILED_BY_FILTER: val = "SAM_PWD_CHANGE_FAILED_BY_FILTER"; break;
5169 0 : case SAM_PWD_CHANGE_PASSWORD_TOO_LONG: val = "SAM_PWD_CHANGE_PASSWORD_TOO_LONG"; break;
5170 : }
5171 2 : ndr_print_enum(ndr, name, "ENUM", val, r);
5172 2 : }
5173 :
5174 1061 : static enum ndr_err_code ndr_push_userPwdChangeFailureInformation(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct userPwdChangeFailureInformation *r)
5175 : {
5176 1061 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5177 1061 : if (ndr_flags & NDR_SCALARS) {
5178 1061 : NDR_CHECK(ndr_push_align(ndr, 5));
5179 1061 : NDR_CHECK(ndr_push_samPwdChangeReason(ndr, NDR_SCALARS, r->extendedFailureReason));
5180 1061 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->filterModuleName));
5181 1061 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5182 : }
5183 1061 : if (ndr_flags & NDR_BUFFERS) {
5184 1061 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->filterModuleName));
5185 : }
5186 1061 : return NDR_ERR_SUCCESS;
5187 : }
5188 :
5189 1053 : static enum ndr_err_code ndr_pull_userPwdChangeFailureInformation(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct userPwdChangeFailureInformation *r)
5190 : {
5191 1053 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5192 1053 : if (ndr_flags & NDR_SCALARS) {
5193 1053 : NDR_CHECK(ndr_pull_align(ndr, 5));
5194 1053 : NDR_CHECK(ndr_pull_samPwdChangeReason(ndr, NDR_SCALARS, &r->extendedFailureReason));
5195 1053 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->filterModuleName));
5196 1053 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5197 : }
5198 1053 : if (ndr_flags & NDR_BUFFERS) {
5199 1053 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->filterModuleName));
5200 : }
5201 1051 : return NDR_ERR_SUCCESS;
5202 : }
5203 :
5204 2 : _PUBLIC_ void ndr_print_userPwdChangeFailureInformation(struct ndr_print *ndr, const char *name, const struct userPwdChangeFailureInformation *r)
5205 : {
5206 2 : ndr_print_struct(ndr, name, "userPwdChangeFailureInformation");
5207 2 : if (r == NULL) { ndr_print_null(ndr); return; }
5208 2 : ndr->depth++;
5209 2 : ndr_print_samPwdChangeReason(ndr, "extendedFailureReason", r->extendedFailureReason);
5210 2 : ndr_print_lsa_String(ndr, "filterModuleName", &r->filterModuleName);
5211 2 : ndr->depth--;
5212 : }
5213 :
5214 401 : static enum ndr_err_code ndr_push_samr_SupportedFeatures(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_SupportedFeatures r)
5215 : {
5216 401 : NDR_CHECK(ndr_push_enum_uint32(ndr, NDR_SCALARS, r));
5217 401 : return NDR_ERR_SUCCESS;
5218 : }
5219 :
5220 402 : static enum ndr_err_code ndr_pull_samr_SupportedFeatures(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_SupportedFeatures *r)
5221 : {
5222 4 : uint32_t v;
5223 402 : NDR_CHECK(ndr_pull_enum_uint32(ndr, NDR_SCALARS, &v));
5224 402 : *r = v;
5225 402 : return NDR_ERR_SUCCESS;
5226 : }
5227 :
5228 10 : _PUBLIC_ void ndr_print_samr_SupportedFeatures(struct ndr_print *ndr, const char *name, enum samr_SupportedFeatures r)
5229 : {
5230 10 : const char *val = NULL;
5231 :
5232 10 : switch (r) {
5233 0 : case SAMR_CONNECT_FEATURE_RID_ONLY: val = "SAMR_CONNECT_FEATURE_RID_ONLY"; break;
5234 0 : case SAMR_CONNECT_FEATURE_RESRVED1: val = "SAMR_CONNECT_FEATURE_RESRVED1"; break;
5235 0 : case SAMR_CONNECT_FEATURE_RESRVED2: val = "SAMR_CONNECT_FEATURE_RESRVED2"; break;
5236 0 : case SAMR_CONNECT_FEATURE_USE_AES: val = "SAMR_CONNECT_FEATURE_USE_AES"; break;
5237 : }
5238 10 : ndr_print_enum(ndr, name, "ENUM", val, r);
5239 10 : }
5240 :
5241 401 : static enum ndr_err_code ndr_push_samr_ConnectInfo1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_ConnectInfo1 *r)
5242 : {
5243 401 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5244 401 : if (ndr_flags & NDR_SCALARS) {
5245 401 : NDR_CHECK(ndr_push_align(ndr, 4));
5246 401 : NDR_CHECK(ndr_push_samr_ConnectVersion(ndr, NDR_SCALARS, r->client_version));
5247 401 : NDR_CHECK(ndr_push_samr_SupportedFeatures(ndr, NDR_SCALARS, r->supported_features));
5248 401 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
5249 : }
5250 401 : if (ndr_flags & NDR_BUFFERS) {
5251 0 : }
5252 401 : return NDR_ERR_SUCCESS;
5253 : }
5254 :
5255 402 : static enum ndr_err_code ndr_pull_samr_ConnectInfo1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_ConnectInfo1 *r)
5256 : {
5257 402 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5258 402 : if (ndr_flags & NDR_SCALARS) {
5259 402 : NDR_CHECK(ndr_pull_align(ndr, 4));
5260 406 : NDR_CHECK(ndr_pull_samr_ConnectVersion(ndr, NDR_SCALARS, &r->client_version));
5261 406 : NDR_CHECK(ndr_pull_samr_SupportedFeatures(ndr, NDR_SCALARS, &r->supported_features));
5262 402 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
5263 : }
5264 402 : if (ndr_flags & NDR_BUFFERS) {
5265 4 : }
5266 402 : return NDR_ERR_SUCCESS;
5267 : }
5268 :
5269 10 : _PUBLIC_ void ndr_print_samr_ConnectInfo1(struct ndr_print *ndr, const char *name, const struct samr_ConnectInfo1 *r)
5270 : {
5271 10 : ndr_print_struct(ndr, name, "samr_ConnectInfo1");
5272 10 : if (r == NULL) { ndr_print_null(ndr); return; }
5273 10 : ndr->depth++;
5274 10 : ndr_print_samr_ConnectVersion(ndr, "client_version", r->client_version);
5275 10 : ndr_print_samr_SupportedFeatures(ndr, "supported_features", r->supported_features);
5276 10 : ndr->depth--;
5277 : }
5278 :
5279 401 : static enum ndr_err_code ndr_push_samr_ConnectInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_ConnectInfo *r)
5280 : {
5281 0 : uint32_t level;
5282 401 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5283 401 : if (ndr_flags & NDR_SCALARS) {
5284 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5285 401 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5286 401 : NDR_CHECK(ndr_push_union_align(ndr, 4));
5287 401 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, level));
5288 401 : NDR_CHECK(ndr_push_union_align(ndr, 4));
5289 401 : switch (level) {
5290 401 : case 1: {
5291 401 : NDR_CHECK(ndr_push_samr_ConnectInfo1(ndr, NDR_SCALARS, &r->info1));
5292 401 : break; }
5293 :
5294 0 : default:
5295 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
5296 : }
5297 : }
5298 401 : if (ndr_flags & NDR_BUFFERS) {
5299 0 : if (!(ndr_flags & NDR_SCALARS)) {
5300 : /* We didn't get it above, and the token is not needed after this. */
5301 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5302 : }
5303 0 : switch (level) {
5304 0 : case 1:
5305 0 : break;
5306 :
5307 0 : default:
5308 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
5309 : }
5310 : }
5311 401 : return NDR_ERR_SUCCESS;
5312 : }
5313 :
5314 402 : static enum ndr_err_code ndr_pull_samr_ConnectInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_ConnectInfo *r)
5315 : {
5316 4 : uint32_t level;
5317 4 : uint32_t _level;
5318 402 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5319 402 : if (ndr_flags & NDR_SCALARS) {
5320 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5321 402 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
5322 402 : NDR_CHECK(ndr_pull_union_align(ndr, 4));
5323 402 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &_level));
5324 402 : if (_level != level) {
5325 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" for r at %s", (uint32_t)_level, __location__);
5326 : }
5327 402 : NDR_CHECK(ndr_pull_union_align(ndr, 4));
5328 402 : switch (level) {
5329 402 : case 1: {
5330 402 : NDR_CHECK(ndr_pull_samr_ConnectInfo1(ndr, NDR_SCALARS, &r->info1));
5331 398 : break; }
5332 :
5333 0 : default:
5334 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
5335 : }
5336 : }
5337 402 : if (ndr_flags & NDR_BUFFERS) {
5338 0 : if (!(ndr_flags & NDR_SCALARS)) {
5339 : /* We didn't get it above, and the token is not needed after this. */
5340 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
5341 : }
5342 0 : switch (level) {
5343 0 : case 1:
5344 0 : break;
5345 :
5346 0 : default:
5347 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
5348 : }
5349 : }
5350 398 : return NDR_ERR_SUCCESS;
5351 : }
5352 :
5353 10 : _PUBLIC_ void ndr_print_samr_ConnectInfo(struct ndr_print *ndr, const char *name, const union samr_ConnectInfo *r)
5354 : {
5355 4 : uint32_t level;
5356 10 : level = ndr_print_steal_switch_value(ndr, r);
5357 10 : ndr_print_union(ndr, name, level, "samr_ConnectInfo");
5358 10 : switch (level) {
5359 10 : case 1:
5360 10 : ndr_print_samr_ConnectInfo1(ndr, "info1", &r->info1);
5361 10 : break;
5362 :
5363 0 : default:
5364 0 : ndr_print_bad_level(ndr, name, level);
5365 : }
5366 10 : }
5367 :
5368 15 : static enum ndr_err_code ndr_push_samr_ValidateFieldsPresent(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
5369 : {
5370 15 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
5371 15 : return NDR_ERR_SUCCESS;
5372 : }
5373 :
5374 15 : static enum ndr_err_code ndr_pull_samr_ValidateFieldsPresent(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
5375 : {
5376 0 : uint32_t v;
5377 15 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
5378 15 : *r = v;
5379 15 : return NDR_ERR_SUCCESS;
5380 : }
5381 :
5382 0 : _PUBLIC_ void ndr_print_samr_ValidateFieldsPresent(struct ndr_print *ndr, const char *name, uint32_t r)
5383 : {
5384 0 : ndr_print_uint32(ndr, name, r);
5385 0 : ndr->depth++;
5386 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_VALIDATE_FIELD_PASSWORD_LAST_SET", SAMR_VALIDATE_FIELD_PASSWORD_LAST_SET, r);
5387 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_VALIDATE_FIELD_BAD_PASSWORD_TIME", SAMR_VALIDATE_FIELD_BAD_PASSWORD_TIME, r);
5388 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_VALIDATE_FIELD_LOCKOUT_TIME", SAMR_VALIDATE_FIELD_LOCKOUT_TIME, r);
5389 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_VALIDATE_FIELD_BAD_PASSWORD_COUNT", SAMR_VALIDATE_FIELD_BAD_PASSWORD_COUNT, r);
5390 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_VALIDATE_FIELD_PASSWORD_HISTORY_LENGTH", SAMR_VALIDATE_FIELD_PASSWORD_HISTORY_LENGTH, r);
5391 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SAMR_VALIDATE_FIELD_PASSWORD_HISTORY", SAMR_VALIDATE_FIELD_PASSWORD_HISTORY, r);
5392 0 : ndr->depth--;
5393 0 : }
5394 :
5395 12 : static enum ndr_err_code ndr_push_samr_ValidatePasswordLevel(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_ValidatePasswordLevel r)
5396 : {
5397 12 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
5398 12 : return NDR_ERR_SUCCESS;
5399 : }
5400 :
5401 6 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordLevel(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_ValidatePasswordLevel *r)
5402 : {
5403 0 : uint16_t v;
5404 6 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
5405 6 : *r = v;
5406 6 : return NDR_ERR_SUCCESS;
5407 : }
5408 :
5409 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordLevel(struct ndr_print *ndr, const char *name, enum samr_ValidatePasswordLevel r)
5410 : {
5411 0 : const char *val = NULL;
5412 :
5413 0 : switch (r) {
5414 0 : case NetValidateAuthentication: val = "NetValidateAuthentication"; break;
5415 0 : case NetValidatePasswordChange: val = "NetValidatePasswordChange"; break;
5416 0 : case NetValidatePasswordReset: val = "NetValidatePasswordReset"; break;
5417 : }
5418 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
5419 0 : }
5420 :
5421 3 : static enum ndr_err_code ndr_push_samr_ValidationStatus(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum samr_ValidationStatus r)
5422 : {
5423 3 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
5424 3 : return NDR_ERR_SUCCESS;
5425 : }
5426 :
5427 9 : static enum ndr_err_code ndr_pull_samr_ValidationStatus(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum samr_ValidationStatus *r)
5428 : {
5429 0 : uint16_t v;
5430 9 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
5431 9 : *r = v;
5432 9 : return NDR_ERR_SUCCESS;
5433 : }
5434 :
5435 0 : _PUBLIC_ void ndr_print_samr_ValidationStatus(struct ndr_print *ndr, const char *name, enum samr_ValidationStatus r)
5436 : {
5437 0 : const char *val = NULL;
5438 :
5439 0 : switch (r) {
5440 0 : case SAMR_VALIDATION_STATUS_SUCCESS: val = "SAMR_VALIDATION_STATUS_SUCCESS"; break;
5441 0 : case SAMR_VALIDATION_STATUS_PASSWORD_MUST_CHANGE: val = "SAMR_VALIDATION_STATUS_PASSWORD_MUST_CHANGE"; break;
5442 0 : case SAMR_VALIDATION_STATUS_ACCOUNT_LOCKED_OUT: val = "SAMR_VALIDATION_STATUS_ACCOUNT_LOCKED_OUT"; break;
5443 0 : case SAMR_VALIDATION_STATUS_PASSWORD_EXPIRED: val = "SAMR_VALIDATION_STATUS_PASSWORD_EXPIRED"; break;
5444 0 : case SAMR_VALIDATION_STATUS_BAD_PASSWORD: val = "SAMR_VALIDATION_STATUS_BAD_PASSWORD"; break;
5445 0 : case SAMR_VALIDATION_STATUS_PWD_HISTORY_CONFLICT: val = "SAMR_VALIDATION_STATUS_PWD_HISTORY_CONFLICT"; break;
5446 0 : case SAMR_VALIDATION_STATUS_PWD_TOO_SHORT: val = "SAMR_VALIDATION_STATUS_PWD_TOO_SHORT"; break;
5447 0 : case SAMR_VALIDATION_STATUS_PWD_TOO_LONG: val = "SAMR_VALIDATION_STATUS_PWD_TOO_LONG"; break;
5448 0 : case SAMR_VALIDATION_STATUS_NOT_COMPLEX_ENOUGH: val = "SAMR_VALIDATION_STATUS_NOT_COMPLEX_ENOUGH"; break;
5449 0 : case SAMR_VALIDATION_STATUS_PASSWORD_TOO_RECENT: val = "SAMR_VALIDATION_STATUS_PASSWORD_TOO_RECENT"; break;
5450 0 : case SAMR_VALIDATION_STATUS_PASSWORD_FILTER_ERROR: val = "SAMR_VALIDATION_STATUS_PASSWORD_FILTER_ERROR"; break;
5451 : }
5452 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
5453 0 : }
5454 :
5455 24 : static enum ndr_err_code ndr_push_samr_ValidationBlob(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_ValidationBlob *r)
5456 : {
5457 24 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5458 24 : if (ndr_flags & NDR_SCALARS) {
5459 12 : NDR_CHECK(ndr_push_align(ndr, 5));
5460 12 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->length));
5461 12 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->data));
5462 12 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
5463 : }
5464 24 : if (ndr_flags & NDR_BUFFERS) {
5465 12 : if (r->data) {
5466 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->length));
5467 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->data, r->length));
5468 : }
5469 : }
5470 24 : return NDR_ERR_SUCCESS;
5471 : }
5472 :
5473 12 : static enum ndr_err_code ndr_pull_samr_ValidationBlob(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_ValidationBlob *r)
5474 : {
5475 0 : uint32_t _ptr_data;
5476 12 : uint32_t size_data_1 = 0;
5477 12 : TALLOC_CTX *_mem_save_data_0 = NULL;
5478 12 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5479 12 : if (ndr_flags & NDR_SCALARS) {
5480 6 : NDR_CHECK(ndr_pull_align(ndr, 5));
5481 6 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->length));
5482 6 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_data));
5483 6 : if (_ptr_data) {
5484 0 : NDR_PULL_ALLOC(ndr, r->data);
5485 : } else {
5486 6 : r->data = NULL;
5487 : }
5488 6 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
5489 : }
5490 12 : if (ndr_flags & NDR_BUFFERS) {
5491 6 : if (r->data) {
5492 0 : _mem_save_data_0 = NDR_PULL_GET_MEM_CTX(ndr);
5493 0 : NDR_PULL_SET_MEM_CTX(ndr, r->data, 0);
5494 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->data));
5495 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->data, &size_data_1));
5496 0 : NDR_PULL_ALLOC_N(ndr, r->data, size_data_1);
5497 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->data, size_data_1));
5498 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_data_0, 0);
5499 : }
5500 6 : if (r->data) {
5501 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->data, r->length));
5502 : }
5503 : }
5504 12 : return NDR_ERR_SUCCESS;
5505 : }
5506 :
5507 0 : _PUBLIC_ void ndr_print_samr_ValidationBlob(struct ndr_print *ndr, const char *name, const struct samr_ValidationBlob *r)
5508 : {
5509 0 : ndr_print_struct(ndr, name, "samr_ValidationBlob");
5510 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5511 0 : ndr->depth++;
5512 0 : ndr_print_uint32(ndr, "length", r->length);
5513 0 : ndr_print_ptr(ndr, "data", r->data);
5514 0 : ndr->depth++;
5515 0 : if (r->data) {
5516 0 : ndr_print_array_uint8(ndr, "data", r->data, r->length);
5517 : }
5518 0 : ndr->depth--;
5519 0 : ndr->depth--;
5520 : }
5521 :
5522 30 : static enum ndr_err_code ndr_push_samr_ValidatePasswordInfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_ValidatePasswordInfo *r)
5523 : {
5524 0 : uint32_t cntr_pwd_history_1;
5525 30 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5526 30 : if (ndr_flags & NDR_SCALARS) {
5527 15 : NDR_CHECK(ndr_push_align(ndr, 8));
5528 15 : NDR_CHECK(ndr_push_samr_ValidateFieldsPresent(ndr, NDR_SCALARS, r->fields_present));
5529 15 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, r->last_password_change));
5530 15 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, r->bad_password_time));
5531 15 : NDR_CHECK(ndr_push_NTTIME_hyper(ndr, NDR_SCALARS, r->lockout_time));
5532 15 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->bad_pwd_count));
5533 15 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->pwd_history_len));
5534 15 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->pwd_history));
5535 15 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
5536 : }
5537 30 : if (ndr_flags & NDR_BUFFERS) {
5538 15 : if (r->pwd_history) {
5539 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->pwd_history_len));
5540 0 : for (cntr_pwd_history_1 = 0; cntr_pwd_history_1 < (r->pwd_history_len); cntr_pwd_history_1++) {
5541 0 : NDR_CHECK(ndr_push_samr_ValidationBlob(ndr, NDR_SCALARS, &r->pwd_history[cntr_pwd_history_1]));
5542 : }
5543 0 : for (cntr_pwd_history_1 = 0; cntr_pwd_history_1 < (r->pwd_history_len); cntr_pwd_history_1++) {
5544 0 : NDR_CHECK(ndr_push_samr_ValidationBlob(ndr, NDR_BUFFERS, &r->pwd_history[cntr_pwd_history_1]));
5545 : }
5546 : }
5547 : }
5548 30 : return NDR_ERR_SUCCESS;
5549 : }
5550 :
5551 30 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordInfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_ValidatePasswordInfo *r)
5552 : {
5553 0 : uint32_t _ptr_pwd_history;
5554 30 : uint32_t size_pwd_history_1 = 0;
5555 0 : uint32_t cntr_pwd_history_1;
5556 30 : TALLOC_CTX *_mem_save_pwd_history_0 = NULL;
5557 30 : TALLOC_CTX *_mem_save_pwd_history_1 = NULL;
5558 30 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5559 30 : if (ndr_flags & NDR_SCALARS) {
5560 15 : NDR_CHECK(ndr_pull_align(ndr, 8));
5561 15 : NDR_CHECK(ndr_pull_samr_ValidateFieldsPresent(ndr, NDR_SCALARS, &r->fields_present));
5562 15 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, &r->last_password_change));
5563 15 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, &r->bad_password_time));
5564 15 : NDR_CHECK(ndr_pull_NTTIME_hyper(ndr, NDR_SCALARS, &r->lockout_time));
5565 15 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->bad_pwd_count));
5566 15 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->pwd_history_len));
5567 15 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_pwd_history));
5568 15 : if (_ptr_pwd_history) {
5569 0 : NDR_PULL_ALLOC(ndr, r->pwd_history);
5570 : } else {
5571 15 : r->pwd_history = NULL;
5572 : }
5573 15 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
5574 : }
5575 30 : if (ndr_flags & NDR_BUFFERS) {
5576 15 : if (r->pwd_history) {
5577 0 : _mem_save_pwd_history_0 = NDR_PULL_GET_MEM_CTX(ndr);
5578 0 : NDR_PULL_SET_MEM_CTX(ndr, r->pwd_history, 0);
5579 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->pwd_history));
5580 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->pwd_history, &size_pwd_history_1));
5581 0 : NDR_PULL_ALLOC_N(ndr, r->pwd_history, size_pwd_history_1);
5582 0 : _mem_save_pwd_history_1 = NDR_PULL_GET_MEM_CTX(ndr);
5583 0 : NDR_PULL_SET_MEM_CTX(ndr, r->pwd_history, 0);
5584 0 : for (cntr_pwd_history_1 = 0; cntr_pwd_history_1 < (size_pwd_history_1); cntr_pwd_history_1++) {
5585 0 : NDR_CHECK(ndr_pull_samr_ValidationBlob(ndr, NDR_SCALARS, &r->pwd_history[cntr_pwd_history_1]));
5586 : }
5587 0 : for (cntr_pwd_history_1 = 0; cntr_pwd_history_1 < (size_pwd_history_1); cntr_pwd_history_1++) {
5588 0 : NDR_CHECK(ndr_pull_samr_ValidationBlob(ndr, NDR_BUFFERS, &r->pwd_history[cntr_pwd_history_1]));
5589 : }
5590 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pwd_history_1, 0);
5591 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_pwd_history_0, 0);
5592 : }
5593 15 : if (r->pwd_history) {
5594 0 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->pwd_history, r->pwd_history_len));
5595 : }
5596 15 : for (cntr_pwd_history_1 = 0; cntr_pwd_history_1 < (size_pwd_history_1); cntr_pwd_history_1++) {
5597 0 : }
5598 : }
5599 30 : return NDR_ERR_SUCCESS;
5600 : }
5601 :
5602 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordInfo(struct ndr_print *ndr, const char *name, const struct samr_ValidatePasswordInfo *r)
5603 : {
5604 0 : uint32_t cntr_pwd_history_1;
5605 0 : ndr_print_struct(ndr, name, "samr_ValidatePasswordInfo");
5606 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5607 0 : ndr->depth++;
5608 0 : ndr_print_samr_ValidateFieldsPresent(ndr, "fields_present", r->fields_present);
5609 0 : ndr_print_NTTIME_hyper(ndr, "last_password_change", r->last_password_change);
5610 0 : ndr_print_NTTIME_hyper(ndr, "bad_password_time", r->bad_password_time);
5611 0 : ndr_print_NTTIME_hyper(ndr, "lockout_time", r->lockout_time);
5612 0 : ndr_print_uint32(ndr, "bad_pwd_count", r->bad_pwd_count);
5613 0 : ndr_print_uint32(ndr, "pwd_history_len", r->pwd_history_len);
5614 0 : ndr_print_ptr(ndr, "pwd_history", r->pwd_history);
5615 0 : ndr->depth++;
5616 0 : if (r->pwd_history) {
5617 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "pwd_history", (uint32_t)(r->pwd_history_len));
5618 0 : ndr->depth++;
5619 0 : for (cntr_pwd_history_1 = 0; cntr_pwd_history_1 < (r->pwd_history_len); cntr_pwd_history_1++) {
5620 0 : ndr_print_samr_ValidationBlob(ndr, "pwd_history", &r->pwd_history[cntr_pwd_history_1]);
5621 : }
5622 0 : ndr->depth--;
5623 : }
5624 0 : ndr->depth--;
5625 0 : ndr->depth--;
5626 : }
5627 :
5628 6 : static enum ndr_err_code ndr_push_samr_ValidatePasswordRepCtr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_ValidatePasswordRepCtr *r)
5629 : {
5630 6 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5631 6 : if (ndr_flags & NDR_SCALARS) {
5632 3 : NDR_CHECK(ndr_push_align(ndr, 8));
5633 3 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5634 3 : NDR_CHECK(ndr_push_samr_ValidationStatus(ndr, NDR_SCALARS, r->status));
5635 3 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
5636 : }
5637 6 : if (ndr_flags & NDR_BUFFERS) {
5638 3 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5639 : }
5640 6 : return NDR_ERR_SUCCESS;
5641 : }
5642 :
5643 18 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordRepCtr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_ValidatePasswordRepCtr *r)
5644 : {
5645 18 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5646 18 : if (ndr_flags & NDR_SCALARS) {
5647 9 : NDR_CHECK(ndr_pull_align(ndr, 8));
5648 9 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5649 9 : NDR_CHECK(ndr_pull_samr_ValidationStatus(ndr, NDR_SCALARS, &r->status));
5650 9 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
5651 : }
5652 18 : if (ndr_flags & NDR_BUFFERS) {
5653 9 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5654 : }
5655 18 : return NDR_ERR_SUCCESS;
5656 : }
5657 :
5658 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordRepCtr(struct ndr_print *ndr, const char *name, const struct samr_ValidatePasswordRepCtr *r)
5659 : {
5660 0 : ndr_print_struct(ndr, name, "samr_ValidatePasswordRepCtr");
5661 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5662 0 : ndr->depth++;
5663 0 : ndr_print_samr_ValidatePasswordInfo(ndr, "info", &r->info);
5664 0 : ndr_print_samr_ValidationStatus(ndr, "status", r->status);
5665 0 : ndr->depth--;
5666 : }
5667 :
5668 3 : static enum ndr_err_code ndr_push_samr_ValidatePasswordRep(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_ValidatePasswordRep *r)
5669 : {
5670 0 : uint32_t level;
5671 3 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5672 3 : if (ndr_flags & NDR_SCALARS) {
5673 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5674 3 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5675 3 : NDR_CHECK(ndr_push_union_align(ndr, 8));
5676 3 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
5677 3 : NDR_CHECK(ndr_push_union_align(ndr, 8));
5678 3 : switch (level) {
5679 0 : case 1: {
5680 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordRepCtr(ndr, NDR_SCALARS, &r->ctr1));
5681 0 : break; }
5682 :
5683 0 : case 2: {
5684 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordRepCtr(ndr, NDR_SCALARS, &r->ctr2));
5685 0 : break; }
5686 :
5687 3 : case 3: {
5688 3 : NDR_CHECK(ndr_push_samr_ValidatePasswordRepCtr(ndr, NDR_SCALARS, &r->ctr3));
5689 3 : break; }
5690 :
5691 0 : default:
5692 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
5693 : }
5694 : }
5695 3 : if (ndr_flags & NDR_BUFFERS) {
5696 3 : if (!(ndr_flags & NDR_SCALARS)) {
5697 : /* We didn't get it above, and the token is not needed after this. */
5698 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5699 : }
5700 3 : switch (level) {
5701 0 : case 1:
5702 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordRepCtr(ndr, NDR_BUFFERS, &r->ctr1));
5703 0 : break;
5704 :
5705 0 : case 2:
5706 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordRepCtr(ndr, NDR_BUFFERS, &r->ctr2));
5707 0 : break;
5708 :
5709 3 : case 3:
5710 3 : NDR_CHECK(ndr_push_samr_ValidatePasswordRepCtr(ndr, NDR_BUFFERS, &r->ctr3));
5711 3 : break;
5712 :
5713 0 : default:
5714 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
5715 : }
5716 : }
5717 3 : return NDR_ERR_SUCCESS;
5718 : }
5719 :
5720 9 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordRep(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_ValidatePasswordRep *r)
5721 : {
5722 0 : uint32_t level;
5723 0 : uint16_t _level;
5724 9 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5725 9 : if (ndr_flags & NDR_SCALARS) {
5726 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5727 9 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
5728 9 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
5729 9 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
5730 9 : if (_level != level) {
5731 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
5732 : }
5733 9 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
5734 9 : switch (level) {
5735 0 : case 1: {
5736 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordRepCtr(ndr, NDR_SCALARS, &r->ctr1));
5737 0 : break; }
5738 :
5739 0 : case 2: {
5740 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordRepCtr(ndr, NDR_SCALARS, &r->ctr2));
5741 0 : break; }
5742 :
5743 9 : case 3: {
5744 9 : NDR_CHECK(ndr_pull_samr_ValidatePasswordRepCtr(ndr, NDR_SCALARS, &r->ctr3));
5745 9 : break; }
5746 :
5747 0 : default:
5748 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
5749 : }
5750 : }
5751 9 : if (ndr_flags & NDR_BUFFERS) {
5752 9 : if (!(ndr_flags & NDR_SCALARS)) {
5753 : /* We didn't get it above, and the token is not needed after this. */
5754 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
5755 : }
5756 9 : switch (level) {
5757 0 : case 1:
5758 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordRepCtr(ndr, NDR_BUFFERS, &r->ctr1));
5759 0 : break;
5760 :
5761 0 : case 2:
5762 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordRepCtr(ndr, NDR_BUFFERS, &r->ctr2));
5763 0 : break;
5764 :
5765 9 : case 3:
5766 9 : NDR_CHECK(ndr_pull_samr_ValidatePasswordRepCtr(ndr, NDR_BUFFERS, &r->ctr3));
5767 9 : break;
5768 :
5769 0 : default:
5770 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
5771 : }
5772 : }
5773 9 : return NDR_ERR_SUCCESS;
5774 : }
5775 :
5776 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordRep(struct ndr_print *ndr, const char *name, const union samr_ValidatePasswordRep *r)
5777 : {
5778 0 : uint32_t level;
5779 0 : level = ndr_print_steal_switch_value(ndr, r);
5780 0 : ndr_print_union(ndr, name, level, "samr_ValidatePasswordRep");
5781 0 : switch (level) {
5782 0 : case 1:
5783 0 : ndr_print_samr_ValidatePasswordRepCtr(ndr, "ctr1", &r->ctr1);
5784 0 : break;
5785 :
5786 0 : case 2:
5787 0 : ndr_print_samr_ValidatePasswordRepCtr(ndr, "ctr2", &r->ctr2);
5788 0 : break;
5789 :
5790 0 : case 3:
5791 0 : ndr_print_samr_ValidatePasswordRepCtr(ndr, "ctr3", &r->ctr3);
5792 0 : break;
5793 :
5794 0 : default:
5795 0 : ndr_print_bad_level(ndr, name, level);
5796 : }
5797 0 : }
5798 :
5799 24 : static enum ndr_err_code ndr_push_samr_ValidatePasswordReq3(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_ValidatePasswordReq3 *r)
5800 : {
5801 24 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5802 24 : if (ndr_flags & NDR_SCALARS) {
5803 12 : NDR_CHECK(ndr_push_align(ndr, 8));
5804 12 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5805 12 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->password));
5806 12 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->account));
5807 12 : NDR_CHECK(ndr_push_samr_ValidationBlob(ndr, NDR_SCALARS, &r->hash));
5808 12 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->pwd_must_change_at_next_logon));
5809 12 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->clear_lockout));
5810 12 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
5811 : }
5812 24 : if (ndr_flags & NDR_BUFFERS) {
5813 12 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5814 12 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->password));
5815 12 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->account));
5816 12 : NDR_CHECK(ndr_push_samr_ValidationBlob(ndr, NDR_BUFFERS, &r->hash));
5817 : }
5818 24 : return NDR_ERR_SUCCESS;
5819 : }
5820 :
5821 12 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordReq3(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_ValidatePasswordReq3 *r)
5822 : {
5823 12 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5824 12 : if (ndr_flags & NDR_SCALARS) {
5825 6 : NDR_CHECK(ndr_pull_align(ndr, 8));
5826 6 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5827 6 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->password));
5828 6 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->account));
5829 6 : NDR_CHECK(ndr_pull_samr_ValidationBlob(ndr, NDR_SCALARS, &r->hash));
5830 6 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->pwd_must_change_at_next_logon));
5831 6 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->clear_lockout));
5832 6 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
5833 : }
5834 12 : if (ndr_flags & NDR_BUFFERS) {
5835 6 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5836 6 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->password));
5837 6 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->account));
5838 6 : NDR_CHECK(ndr_pull_samr_ValidationBlob(ndr, NDR_BUFFERS, &r->hash));
5839 : }
5840 12 : return NDR_ERR_SUCCESS;
5841 : }
5842 :
5843 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordReq3(struct ndr_print *ndr, const char *name, const struct samr_ValidatePasswordReq3 *r)
5844 : {
5845 0 : ndr_print_struct(ndr, name, "samr_ValidatePasswordReq3");
5846 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5847 0 : ndr->depth++;
5848 0 : ndr_print_samr_ValidatePasswordInfo(ndr, "info", &r->info);
5849 0 : ndr_print_lsa_StringLarge(ndr, "password", &r->password);
5850 0 : ndr_print_lsa_StringLarge(ndr, "account", &r->account);
5851 0 : ndr_print_samr_ValidationBlob(ndr, "hash", &r->hash);
5852 0 : ndr_print_uint8(ndr, "pwd_must_change_at_next_logon", r->pwd_must_change_at_next_logon);
5853 0 : ndr_print_uint8(ndr, "clear_lockout", r->clear_lockout);
5854 0 : ndr->depth--;
5855 : }
5856 :
5857 0 : static enum ndr_err_code ndr_push_samr_ValidatePasswordReq2(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_ValidatePasswordReq2 *r)
5858 : {
5859 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5860 0 : if (ndr_flags & NDR_SCALARS) {
5861 0 : NDR_CHECK(ndr_push_align(ndr, 8));
5862 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5863 0 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->password));
5864 0 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_SCALARS, &r->account));
5865 0 : NDR_CHECK(ndr_push_samr_ValidationBlob(ndr, NDR_SCALARS, &r->hash));
5866 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->password_matched));
5867 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
5868 : }
5869 0 : if (ndr_flags & NDR_BUFFERS) {
5870 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5871 0 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->password));
5872 0 : NDR_CHECK(ndr_push_lsa_StringLarge(ndr, NDR_BUFFERS, &r->account));
5873 0 : NDR_CHECK(ndr_push_samr_ValidationBlob(ndr, NDR_BUFFERS, &r->hash));
5874 : }
5875 0 : return NDR_ERR_SUCCESS;
5876 : }
5877 :
5878 0 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordReq2(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_ValidatePasswordReq2 *r)
5879 : {
5880 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5881 0 : if (ndr_flags & NDR_SCALARS) {
5882 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
5883 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5884 0 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->password));
5885 0 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_SCALARS, &r->account));
5886 0 : NDR_CHECK(ndr_pull_samr_ValidationBlob(ndr, NDR_SCALARS, &r->hash));
5887 0 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->password_matched));
5888 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
5889 : }
5890 0 : if (ndr_flags & NDR_BUFFERS) {
5891 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5892 0 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->password));
5893 0 : NDR_CHECK(ndr_pull_lsa_StringLarge(ndr, NDR_BUFFERS, &r->account));
5894 0 : NDR_CHECK(ndr_pull_samr_ValidationBlob(ndr, NDR_BUFFERS, &r->hash));
5895 : }
5896 0 : return NDR_ERR_SUCCESS;
5897 : }
5898 :
5899 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordReq2(struct ndr_print *ndr, const char *name, const struct samr_ValidatePasswordReq2 *r)
5900 : {
5901 0 : ndr_print_struct(ndr, name, "samr_ValidatePasswordReq2");
5902 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5903 0 : ndr->depth++;
5904 0 : ndr_print_samr_ValidatePasswordInfo(ndr, "info", &r->info);
5905 0 : ndr_print_lsa_StringLarge(ndr, "password", &r->password);
5906 0 : ndr_print_lsa_StringLarge(ndr, "account", &r->account);
5907 0 : ndr_print_samr_ValidationBlob(ndr, "hash", &r->hash);
5908 0 : ndr_print_uint8(ndr, "password_matched", r->password_matched);
5909 0 : ndr->depth--;
5910 : }
5911 :
5912 0 : static enum ndr_err_code ndr_push_samr_ValidatePasswordReq1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct samr_ValidatePasswordReq1 *r)
5913 : {
5914 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5915 0 : if (ndr_flags & NDR_SCALARS) {
5916 0 : NDR_CHECK(ndr_push_align(ndr, 8));
5917 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5918 0 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->password_matched));
5919 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
5920 : }
5921 0 : if (ndr_flags & NDR_BUFFERS) {
5922 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5923 : }
5924 0 : return NDR_ERR_SUCCESS;
5925 : }
5926 :
5927 0 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordReq1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct samr_ValidatePasswordReq1 *r)
5928 : {
5929 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
5930 0 : if (ndr_flags & NDR_SCALARS) {
5931 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
5932 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_SCALARS, &r->info));
5933 0 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->password_matched));
5934 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
5935 : }
5936 0 : if (ndr_flags & NDR_BUFFERS) {
5937 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordInfo(ndr, NDR_BUFFERS, &r->info));
5938 : }
5939 0 : return NDR_ERR_SUCCESS;
5940 : }
5941 :
5942 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordReq1(struct ndr_print *ndr, const char *name, const struct samr_ValidatePasswordReq1 *r)
5943 : {
5944 0 : ndr_print_struct(ndr, name, "samr_ValidatePasswordReq1");
5945 0 : if (r == NULL) { ndr_print_null(ndr); return; }
5946 0 : ndr->depth++;
5947 0 : ndr_print_samr_ValidatePasswordInfo(ndr, "info", &r->info);
5948 0 : ndr_print_uint8(ndr, "password_matched", r->password_matched);
5949 0 : ndr->depth--;
5950 : }
5951 :
5952 12 : static enum ndr_err_code ndr_push_samr_ValidatePasswordReq(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union samr_ValidatePasswordReq *r)
5953 : {
5954 0 : uint32_t level;
5955 12 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
5956 12 : if (ndr_flags & NDR_SCALARS) {
5957 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
5958 12 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5959 12 : NDR_CHECK(ndr_push_union_align(ndr, 8));
5960 12 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, level));
5961 12 : NDR_CHECK(ndr_push_union_align(ndr, 8));
5962 12 : switch (level) {
5963 0 : case 1: {
5964 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordReq1(ndr, NDR_SCALARS, &r->req1));
5965 0 : break; }
5966 :
5967 0 : case 2: {
5968 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordReq2(ndr, NDR_SCALARS, &r->req2));
5969 0 : break; }
5970 :
5971 12 : case 3: {
5972 12 : NDR_CHECK(ndr_push_samr_ValidatePasswordReq3(ndr, NDR_SCALARS, &r->req3));
5973 12 : break; }
5974 :
5975 0 : default:
5976 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
5977 : }
5978 : }
5979 12 : if (ndr_flags & NDR_BUFFERS) {
5980 12 : if (!(ndr_flags & NDR_SCALARS)) {
5981 : /* We didn't get it above, and the token is not needed after this. */
5982 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
5983 : }
5984 12 : switch (level) {
5985 0 : case 1:
5986 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordReq1(ndr, NDR_BUFFERS, &r->req1));
5987 0 : break;
5988 :
5989 0 : case 2:
5990 0 : NDR_CHECK(ndr_push_samr_ValidatePasswordReq2(ndr, NDR_BUFFERS, &r->req2));
5991 0 : break;
5992 :
5993 12 : case 3:
5994 12 : NDR_CHECK(ndr_push_samr_ValidatePasswordReq3(ndr, NDR_BUFFERS, &r->req3));
5995 12 : break;
5996 :
5997 0 : default:
5998 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
5999 : }
6000 : }
6001 12 : return NDR_ERR_SUCCESS;
6002 : }
6003 :
6004 6 : static enum ndr_err_code ndr_pull_samr_ValidatePasswordReq(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union samr_ValidatePasswordReq *r)
6005 : {
6006 0 : uint32_t level;
6007 0 : uint16_t _level;
6008 6 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
6009 6 : if (ndr_flags & NDR_SCALARS) {
6010 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
6011 6 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
6012 6 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
6013 6 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &_level));
6014 6 : if (_level != level) {
6015 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
6016 : }
6017 6 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
6018 6 : switch (level) {
6019 0 : case 1: {
6020 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordReq1(ndr, NDR_SCALARS, &r->req1));
6021 0 : break; }
6022 :
6023 0 : case 2: {
6024 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordReq2(ndr, NDR_SCALARS, &r->req2));
6025 0 : break; }
6026 :
6027 6 : case 3: {
6028 6 : NDR_CHECK(ndr_pull_samr_ValidatePasswordReq3(ndr, NDR_SCALARS, &r->req3));
6029 6 : break; }
6030 :
6031 0 : default:
6032 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
6033 : }
6034 : }
6035 6 : if (ndr_flags & NDR_BUFFERS) {
6036 6 : if (!(ndr_flags & NDR_SCALARS)) {
6037 : /* We didn't get it above, and the token is not needed after this. */
6038 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
6039 : }
6040 6 : switch (level) {
6041 0 : case 1:
6042 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordReq1(ndr, NDR_BUFFERS, &r->req1));
6043 0 : break;
6044 :
6045 0 : case 2:
6046 0 : NDR_CHECK(ndr_pull_samr_ValidatePasswordReq2(ndr, NDR_BUFFERS, &r->req2));
6047 0 : break;
6048 :
6049 6 : case 3:
6050 6 : NDR_CHECK(ndr_pull_samr_ValidatePasswordReq3(ndr, NDR_BUFFERS, &r->req3));
6051 6 : break;
6052 :
6053 0 : default:
6054 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
6055 : }
6056 : }
6057 6 : return NDR_ERR_SUCCESS;
6058 : }
6059 :
6060 0 : _PUBLIC_ void ndr_print_samr_ValidatePasswordReq(struct ndr_print *ndr, const char *name, const union samr_ValidatePasswordReq *r)
6061 : {
6062 0 : uint32_t level;
6063 0 : level = ndr_print_steal_switch_value(ndr, r);
6064 0 : ndr_print_union(ndr, name, level, "samr_ValidatePasswordReq");
6065 0 : switch (level) {
6066 0 : case 1:
6067 0 : ndr_print_samr_ValidatePasswordReq1(ndr, "req1", &r->req1);
6068 0 : break;
6069 :
6070 0 : case 2:
6071 0 : ndr_print_samr_ValidatePasswordReq2(ndr, "req2", &r->req2);
6072 0 : break;
6073 :
6074 0 : case 3:
6075 0 : ndr_print_samr_ValidatePasswordReq3(ndr, "req3", &r->req3);
6076 0 : break;
6077 :
6078 0 : default:
6079 0 : ndr_print_bad_level(ndr, name, level);
6080 : }
6081 0 : }
6082 :
6083 4196 : static enum ndr_err_code ndr_push_samr_Connect(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Connect *r)
6084 : {
6085 4196 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6086 4196 : if (flags & NDR_IN) {
6087 1975 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
6088 1975 : if (r->in.system_name) {
6089 0 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, *r->in.system_name));
6090 : }
6091 2193 : NDR_CHECK(ndr_push_samr_ConnectAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
6092 : }
6093 4196 : if (flags & NDR_OUT) {
6094 2221 : if (r->out.connect_handle == NULL) {
6095 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6096 : }
6097 2221 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
6098 2221 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6099 : }
6100 3716 : return NDR_ERR_SUCCESS;
6101 : }
6102 :
6103 3860 : static enum ndr_err_code ndr_pull_samr_Connect(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Connect *r)
6104 : {
6105 436 : uint32_t _ptr_system_name;
6106 3860 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
6107 3860 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
6108 3860 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6109 3860 : if (flags & NDR_IN) {
6110 1885 : NDR_ZERO_STRUCT(r->out);
6111 :
6112 1885 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
6113 1885 : if (_ptr_system_name) {
6114 0 : NDR_PULL_ALLOC(ndr, r->in.system_name);
6115 : } else {
6116 1885 : r->in.system_name = NULL;
6117 : }
6118 1885 : if (r->in.system_name) {
6119 0 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
6120 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
6121 0 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, r->in.system_name));
6122 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
6123 : }
6124 2103 : NDR_CHECK(ndr_pull_samr_ConnectAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
6125 1885 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
6126 1885 : NDR_ZERO_STRUCTP(r->out.connect_handle);
6127 : }
6128 3860 : if (flags & NDR_OUT) {
6129 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6130 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6131 1975 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6132 336 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
6133 : }
6134 1975 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6135 1975 : NDR_PULL_SET_MEM_CTX(ndr, r->out.connect_handle, LIBNDR_FLAG_REF_ALLOC);
6136 1975 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
6137 1975 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
6138 1975 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6139 : }
6140 3424 : return NDR_ERR_SUCCESS;
6141 : }
6142 :
6143 672 : _PUBLIC_ void ndr_print_samr_Connect(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Connect *r)
6144 : {
6145 672 : ndr_print_struct(ndr, name, "samr_Connect");
6146 672 : if (r == NULL) { ndr_print_null(ndr); return; }
6147 672 : ndr->depth++;
6148 672 : if (flags & NDR_SET_VALUES) {
6149 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6150 : }
6151 672 : if (flags & NDR_IN) {
6152 0 : ndr_print_struct(ndr, "in", "samr_Connect");
6153 0 : ndr->depth++;
6154 0 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
6155 0 : ndr->depth++;
6156 0 : if (r->in.system_name) {
6157 0 : ndr_print_uint16(ndr, "system_name", *r->in.system_name);
6158 : }
6159 0 : ndr->depth--;
6160 0 : ndr_print_samr_ConnectAccessMask(ndr, "access_mask", r->in.access_mask);
6161 0 : ndr->depth--;
6162 : }
6163 672 : if (flags & NDR_OUT) {
6164 672 : ndr_print_struct(ndr, "out", "samr_Connect");
6165 672 : ndr->depth++;
6166 672 : ndr_print_ptr(ndr, "connect_handle", r->out.connect_handle);
6167 672 : ndr->depth++;
6168 672 : ndr_print_policy_handle(ndr, "connect_handle", r->out.connect_handle);
6169 672 : ndr->depth--;
6170 672 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6171 672 : ndr->depth--;
6172 : }
6173 672 : ndr->depth--;
6174 : }
6175 :
6176 13667 : _PUBLIC_ enum ndr_err_code ndr_push_samr_Close(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Close *r)
6177 : {
6178 13667 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6179 13667 : if (flags & NDR_IN) {
6180 6720 : if (r->in.handle == NULL) {
6181 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6182 : }
6183 6720 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6184 : }
6185 13667 : if (flags & NDR_OUT) {
6186 6947 : if (r->out.handle == NULL) {
6187 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6188 : }
6189 6947 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.handle));
6190 6947 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6191 : }
6192 13641 : return NDR_ERR_SUCCESS;
6193 : }
6194 :
6195 13466 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_Close(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Close *r)
6196 : {
6197 13466 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6198 13466 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6199 13466 : if (flags & NDR_IN) {
6200 6776 : NDR_ZERO_STRUCT(r->out);
6201 :
6202 6776 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6203 6776 : NDR_PULL_ALLOC(ndr, r->in.handle);
6204 : }
6205 6776 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6206 6776 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6207 6776 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6208 6776 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6209 6776 : NDR_PULL_ALLOC(ndr, r->out.handle);
6210 6776 : *r->out.handle = *r->in.handle;
6211 : }
6212 13466 : if (flags & NDR_OUT) {
6213 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6214 : if (r->in.handle == NULL) {
6215 : NDR_PULL_ALLOC(ndr, r->in.handle);
6216 : NDR_ZERO_STRUCTP(r->in.handle);
6217 : }
6218 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6219 6690 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6220 3136 : NDR_PULL_ALLOC(ndr, r->out.handle);
6221 : }
6222 6690 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6223 6690 : NDR_PULL_SET_MEM_CTX(ndr, r->out.handle, LIBNDR_FLAG_REF_ALLOC);
6224 6690 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.handle));
6225 6690 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6226 6690 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6227 : }
6228 13438 : return NDR_ERR_SUCCESS;
6229 : }
6230 :
6231 414 : _PUBLIC_ void ndr_print_samr_Close(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Close *r)
6232 : {
6233 414 : ndr_print_struct(ndr, name, "samr_Close");
6234 414 : if (r == NULL) { ndr_print_null(ndr); return; }
6235 414 : ndr->depth++;
6236 414 : if (flags & NDR_SET_VALUES) {
6237 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6238 : }
6239 414 : if (flags & NDR_IN) {
6240 2 : ndr_print_struct(ndr, "in", "samr_Close");
6241 2 : ndr->depth++;
6242 2 : ndr_print_ptr(ndr, "handle", r->in.handle);
6243 2 : ndr->depth++;
6244 2 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6245 2 : ndr->depth--;
6246 2 : ndr->depth--;
6247 : }
6248 414 : if (flags & NDR_OUT) {
6249 412 : ndr_print_struct(ndr, "out", "samr_Close");
6250 412 : ndr->depth++;
6251 412 : ndr_print_ptr(ndr, "handle", r->out.handle);
6252 412 : ndr->depth++;
6253 412 : ndr_print_policy_handle(ndr, "handle", r->out.handle);
6254 412 : ndr->depth--;
6255 412 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6256 412 : ndr->depth--;
6257 : }
6258 414 : ndr->depth--;
6259 : }
6260 :
6261 4 : static enum ndr_err_code ndr_push_samr_SetSecurity(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetSecurity *r)
6262 : {
6263 4 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6264 4 : if (flags & NDR_IN) {
6265 4 : if (r->in.handle == NULL) {
6266 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6267 : }
6268 4 : if (r->in.sdbuf == NULL) {
6269 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6270 : }
6271 4 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6272 4 : NDR_CHECK(ndr_push_security_secinfo(ndr, NDR_SCALARS, r->in.sec_info));
6273 4 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sdbuf));
6274 : }
6275 4 : if (flags & NDR_OUT) {
6276 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6277 : }
6278 4 : return NDR_ERR_SUCCESS;
6279 : }
6280 :
6281 4 : static enum ndr_err_code ndr_pull_samr_SetSecurity(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetSecurity *r)
6282 : {
6283 4 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6284 4 : TALLOC_CTX *_mem_save_sdbuf_0 = NULL;
6285 4 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6286 4 : if (flags & NDR_IN) {
6287 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6288 0 : NDR_PULL_ALLOC(ndr, r->in.handle);
6289 : }
6290 0 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6291 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6292 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6293 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6294 0 : NDR_CHECK(ndr_pull_security_secinfo(ndr, NDR_SCALARS, &r->in.sec_info));
6295 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6296 0 : NDR_PULL_ALLOC(ndr, r->in.sdbuf);
6297 : }
6298 0 : _mem_save_sdbuf_0 = NDR_PULL_GET_MEM_CTX(ndr);
6299 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sdbuf, LIBNDR_FLAG_REF_ALLOC);
6300 0 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sdbuf));
6301 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sdbuf_0, LIBNDR_FLAG_REF_ALLOC);
6302 : }
6303 4 : if (flags & NDR_OUT) {
6304 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6305 : if (r->in.handle == NULL) {
6306 : NDR_PULL_ALLOC(ndr, r->in.handle);
6307 : NDR_ZERO_STRUCTP(r->in.handle);
6308 : }
6309 : if (r->in.sdbuf == NULL) {
6310 : NDR_PULL_ALLOC(ndr, r->in.sdbuf);
6311 : NDR_ZERO_STRUCTP(r->in.sdbuf);
6312 : }
6313 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6314 4 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6315 : }
6316 4 : return NDR_ERR_SUCCESS;
6317 : }
6318 :
6319 0 : _PUBLIC_ void ndr_print_samr_SetSecurity(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetSecurity *r)
6320 : {
6321 0 : ndr_print_struct(ndr, name, "samr_SetSecurity");
6322 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6323 0 : ndr->depth++;
6324 0 : if (flags & NDR_SET_VALUES) {
6325 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6326 : }
6327 0 : if (flags & NDR_IN) {
6328 0 : ndr_print_struct(ndr, "in", "samr_SetSecurity");
6329 0 : ndr->depth++;
6330 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6331 0 : ndr->depth++;
6332 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6333 0 : ndr->depth--;
6334 0 : ndr_print_security_secinfo(ndr, "sec_info", r->in.sec_info);
6335 0 : ndr_print_ptr(ndr, "sdbuf", r->in.sdbuf);
6336 0 : ndr->depth++;
6337 0 : ndr_print_sec_desc_buf(ndr, "sdbuf", r->in.sdbuf);
6338 0 : ndr->depth--;
6339 0 : ndr->depth--;
6340 : }
6341 0 : if (flags & NDR_OUT) {
6342 0 : ndr_print_struct(ndr, "out", "samr_SetSecurity");
6343 0 : ndr->depth++;
6344 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6345 0 : ndr->depth--;
6346 : }
6347 0 : ndr->depth--;
6348 : }
6349 :
6350 652 : static enum ndr_err_code ndr_push_samr_QuerySecurity(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QuerySecurity *r)
6351 : {
6352 652 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6353 652 : if (flags & NDR_IN) {
6354 330 : if (r->in.handle == NULL) {
6355 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6356 : }
6357 330 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6358 330 : NDR_CHECK(ndr_push_security_secinfo(ndr, NDR_SCALARS, r->in.sec_info));
6359 : }
6360 652 : if (flags & NDR_OUT) {
6361 322 : if (r->out.sdbuf == NULL) {
6362 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6363 : }
6364 322 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sdbuf));
6365 322 : if (*r->out.sdbuf) {
6366 322 : NDR_CHECK(ndr_push_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sdbuf));
6367 : }
6368 322 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6369 : }
6370 652 : return NDR_ERR_SUCCESS;
6371 : }
6372 :
6373 652 : static enum ndr_err_code ndr_pull_samr_QuerySecurity(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QuerySecurity *r)
6374 : {
6375 0 : uint32_t _ptr_sdbuf;
6376 652 : TALLOC_CTX *_mem_save_handle_0 = NULL;
6377 652 : TALLOC_CTX *_mem_save_sdbuf_0 = NULL;
6378 652 : TALLOC_CTX *_mem_save_sdbuf_1 = NULL;
6379 652 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6380 652 : if (flags & NDR_IN) {
6381 322 : NDR_ZERO_STRUCT(r->out);
6382 :
6383 322 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6384 322 : NDR_PULL_ALLOC(ndr, r->in.handle);
6385 : }
6386 322 : _mem_save_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6387 322 : NDR_PULL_SET_MEM_CTX(ndr, r->in.handle, LIBNDR_FLAG_REF_ALLOC);
6388 322 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.handle));
6389 322 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_handle_0, LIBNDR_FLAG_REF_ALLOC);
6390 322 : NDR_CHECK(ndr_pull_security_secinfo(ndr, NDR_SCALARS, &r->in.sec_info));
6391 322 : NDR_PULL_ALLOC(ndr, r->out.sdbuf);
6392 322 : NDR_ZERO_STRUCTP(r->out.sdbuf);
6393 : }
6394 652 : if (flags & NDR_OUT) {
6395 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6396 : if (r->in.handle == NULL) {
6397 : NDR_PULL_ALLOC(ndr, r->in.handle);
6398 : NDR_ZERO_STRUCTP(r->in.handle);
6399 : }
6400 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6401 330 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6402 137 : NDR_PULL_ALLOC(ndr, r->out.sdbuf);
6403 : }
6404 330 : _mem_save_sdbuf_0 = NDR_PULL_GET_MEM_CTX(ndr);
6405 330 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sdbuf, LIBNDR_FLAG_REF_ALLOC);
6406 330 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sdbuf));
6407 330 : if (_ptr_sdbuf) {
6408 330 : NDR_PULL_ALLOC(ndr, *r->out.sdbuf);
6409 : } else {
6410 0 : *r->out.sdbuf = NULL;
6411 : }
6412 330 : if (*r->out.sdbuf) {
6413 330 : _mem_save_sdbuf_1 = NDR_PULL_GET_MEM_CTX(ndr);
6414 330 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sdbuf, 0);
6415 330 : NDR_CHECK(ndr_pull_sec_desc_buf(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sdbuf));
6416 330 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sdbuf_1, 0);
6417 : }
6418 330 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sdbuf_0, LIBNDR_FLAG_REF_ALLOC);
6419 330 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6420 : }
6421 652 : return NDR_ERR_SUCCESS;
6422 : }
6423 :
6424 0 : _PUBLIC_ void ndr_print_samr_QuerySecurity(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QuerySecurity *r)
6425 : {
6426 0 : ndr_print_struct(ndr, name, "samr_QuerySecurity");
6427 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6428 0 : ndr->depth++;
6429 0 : if (flags & NDR_SET_VALUES) {
6430 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6431 : }
6432 0 : if (flags & NDR_IN) {
6433 0 : ndr_print_struct(ndr, "in", "samr_QuerySecurity");
6434 0 : ndr->depth++;
6435 0 : ndr_print_ptr(ndr, "handle", r->in.handle);
6436 0 : ndr->depth++;
6437 0 : ndr_print_policy_handle(ndr, "handle", r->in.handle);
6438 0 : ndr->depth--;
6439 0 : ndr_print_security_secinfo(ndr, "sec_info", r->in.sec_info);
6440 0 : ndr->depth--;
6441 : }
6442 0 : if (flags & NDR_OUT) {
6443 0 : ndr_print_struct(ndr, "out", "samr_QuerySecurity");
6444 0 : ndr->depth++;
6445 0 : ndr_print_ptr(ndr, "sdbuf", r->out.sdbuf);
6446 0 : ndr->depth++;
6447 0 : ndr_print_ptr(ndr, "sdbuf", *r->out.sdbuf);
6448 0 : ndr->depth++;
6449 0 : if (*r->out.sdbuf) {
6450 0 : ndr_print_sec_desc_buf(ndr, "sdbuf", *r->out.sdbuf);
6451 : }
6452 0 : ndr->depth--;
6453 0 : ndr->depth--;
6454 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6455 0 : ndr->depth--;
6456 : }
6457 0 : ndr->depth--;
6458 : }
6459 :
6460 0 : static enum ndr_err_code ndr_push_samr_Shutdown(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Shutdown *r)
6461 : {
6462 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6463 0 : if (flags & NDR_IN) {
6464 0 : if (r->in.connect_handle == NULL) {
6465 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6466 : }
6467 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6468 : }
6469 0 : if (flags & NDR_OUT) {
6470 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6471 : }
6472 0 : return NDR_ERR_SUCCESS;
6473 : }
6474 :
6475 0 : static enum ndr_err_code ndr_pull_samr_Shutdown(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Shutdown *r)
6476 : {
6477 0 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
6478 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6479 0 : if (flags & NDR_IN) {
6480 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6481 0 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6482 : }
6483 0 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6484 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.connect_handle, LIBNDR_FLAG_REF_ALLOC);
6485 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6486 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
6487 : }
6488 0 : if (flags & NDR_OUT) {
6489 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6490 : if (r->in.connect_handle == NULL) {
6491 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6492 : NDR_ZERO_STRUCTP(r->in.connect_handle);
6493 : }
6494 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6495 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6496 : }
6497 0 : return NDR_ERR_SUCCESS;
6498 : }
6499 :
6500 0 : _PUBLIC_ void ndr_print_samr_Shutdown(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Shutdown *r)
6501 : {
6502 0 : ndr_print_struct(ndr, name, "samr_Shutdown");
6503 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6504 0 : ndr->depth++;
6505 0 : if (flags & NDR_SET_VALUES) {
6506 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6507 : }
6508 0 : if (flags & NDR_IN) {
6509 0 : ndr_print_struct(ndr, "in", "samr_Shutdown");
6510 0 : ndr->depth++;
6511 0 : ndr_print_ptr(ndr, "connect_handle", r->in.connect_handle);
6512 0 : ndr->depth++;
6513 0 : ndr_print_policy_handle(ndr, "connect_handle", r->in.connect_handle);
6514 0 : ndr->depth--;
6515 0 : ndr->depth--;
6516 : }
6517 0 : if (flags & NDR_OUT) {
6518 0 : ndr_print_struct(ndr, "out", "samr_Shutdown");
6519 0 : ndr->depth++;
6520 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6521 0 : ndr->depth--;
6522 : }
6523 0 : ndr->depth--;
6524 : }
6525 :
6526 1898 : static enum ndr_err_code ndr_push_samr_LookupDomain(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_LookupDomain *r)
6527 : {
6528 1898 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6529 1898 : if (flags & NDR_IN) {
6530 934 : if (r->in.connect_handle == NULL) {
6531 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6532 : }
6533 934 : if (r->in.domain_name == NULL) {
6534 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6535 : }
6536 934 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6537 934 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.domain_name));
6538 : }
6539 1898 : if (flags & NDR_OUT) {
6540 964 : if (r->out.sid == NULL) {
6541 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6542 : }
6543 964 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sid));
6544 964 : if (*r->out.sid) {
6545 868 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sid));
6546 : }
6547 964 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6548 : }
6549 1898 : return NDR_ERR_SUCCESS;
6550 : }
6551 :
6552 1834 : static enum ndr_err_code ndr_pull_samr_LookupDomain(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_LookupDomain *r)
6553 : {
6554 0 : uint32_t _ptr_sid;
6555 1834 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
6556 1834 : TALLOC_CTX *_mem_save_domain_name_0 = NULL;
6557 1834 : TALLOC_CTX *_mem_save_sid_0 = NULL;
6558 1834 : TALLOC_CTX *_mem_save_sid_1 = NULL;
6559 1834 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6560 1834 : if (flags & NDR_IN) {
6561 900 : NDR_ZERO_STRUCT(r->out);
6562 :
6563 900 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6564 900 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6565 : }
6566 900 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6567 900 : NDR_PULL_SET_MEM_CTX(ndr, r->in.connect_handle, LIBNDR_FLAG_REF_ALLOC);
6568 900 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6569 900 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
6570 900 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6571 900 : NDR_PULL_ALLOC(ndr, r->in.domain_name);
6572 : }
6573 900 : _mem_save_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
6574 900 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_name, LIBNDR_FLAG_REF_ALLOC);
6575 900 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.domain_name));
6576 900 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_name_0, LIBNDR_FLAG_REF_ALLOC);
6577 900 : NDR_PULL_ALLOC(ndr, r->out.sid);
6578 900 : NDR_ZERO_STRUCTP(r->out.sid);
6579 : }
6580 1834 : if (flags & NDR_OUT) {
6581 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6582 : if (r->in.connect_handle == NULL) {
6583 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6584 : NDR_ZERO_STRUCTP(r->in.connect_handle);
6585 : }
6586 : if (r->in.domain_name == NULL) {
6587 : NDR_PULL_ALLOC(ndr, r->in.domain_name);
6588 : NDR_ZERO_STRUCTP(r->in.domain_name);
6589 : }
6590 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6591 934 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6592 262 : NDR_PULL_ALLOC(ndr, r->out.sid);
6593 : }
6594 934 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
6595 934 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sid, LIBNDR_FLAG_REF_ALLOC);
6596 934 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
6597 934 : if (_ptr_sid) {
6598 806 : NDR_PULL_ALLOC(ndr, *r->out.sid);
6599 : } else {
6600 128 : *r->out.sid = NULL;
6601 : }
6602 934 : if (*r->out.sid) {
6603 806 : _mem_save_sid_1 = NDR_PULL_GET_MEM_CTX(ndr);
6604 806 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sid, 0);
6605 806 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sid));
6606 806 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_1, 0);
6607 : }
6608 934 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
6609 934 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6610 : }
6611 1834 : return NDR_ERR_SUCCESS;
6612 : }
6613 :
6614 128 : _PUBLIC_ void ndr_print_samr_LookupDomain(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_LookupDomain *r)
6615 : {
6616 128 : ndr_print_struct(ndr, name, "samr_LookupDomain");
6617 128 : if (r == NULL) { ndr_print_null(ndr); return; }
6618 128 : ndr->depth++;
6619 128 : if (flags & NDR_SET_VALUES) {
6620 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6621 : }
6622 128 : if (flags & NDR_IN) {
6623 0 : ndr_print_struct(ndr, "in", "samr_LookupDomain");
6624 0 : ndr->depth++;
6625 0 : ndr_print_ptr(ndr, "connect_handle", r->in.connect_handle);
6626 0 : ndr->depth++;
6627 0 : ndr_print_policy_handle(ndr, "connect_handle", r->in.connect_handle);
6628 0 : ndr->depth--;
6629 0 : ndr_print_ptr(ndr, "domain_name", r->in.domain_name);
6630 0 : ndr->depth++;
6631 0 : ndr_print_lsa_String(ndr, "domain_name", r->in.domain_name);
6632 0 : ndr->depth--;
6633 0 : ndr->depth--;
6634 : }
6635 128 : if (flags & NDR_OUT) {
6636 128 : ndr_print_struct(ndr, "out", "samr_LookupDomain");
6637 128 : ndr->depth++;
6638 128 : ndr_print_ptr(ndr, "sid", r->out.sid);
6639 128 : ndr->depth++;
6640 128 : ndr_print_ptr(ndr, "sid", *r->out.sid);
6641 128 : ndr->depth++;
6642 128 : if (*r->out.sid) {
6643 128 : ndr_print_dom_sid2(ndr, "sid", *r->out.sid);
6644 : }
6645 128 : ndr->depth--;
6646 128 : ndr->depth--;
6647 128 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6648 128 : ndr->depth--;
6649 : }
6650 128 : ndr->depth--;
6651 : }
6652 :
6653 416 : static enum ndr_err_code ndr_push_samr_EnumDomains(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_EnumDomains *r)
6654 : {
6655 416 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6656 416 : if (flags & NDR_IN) {
6657 226 : if (r->in.connect_handle == NULL) {
6658 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6659 : }
6660 226 : if (r->in.resume_handle == NULL) {
6661 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6662 : }
6663 226 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6664 226 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
6665 226 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buf_size));
6666 : }
6667 416 : if (flags & NDR_OUT) {
6668 190 : if (r->out.resume_handle == NULL) {
6669 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6670 : }
6671 190 : if (r->out.sam == NULL) {
6672 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6673 : }
6674 190 : if (r->out.num_entries == NULL) {
6675 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6676 : }
6677 190 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
6678 190 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sam));
6679 190 : if (*r->out.sam) {
6680 168 : NDR_CHECK(ndr_push_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
6681 : }
6682 190 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.num_entries));
6683 190 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6684 : }
6685 416 : return NDR_ERR_SUCCESS;
6686 : }
6687 :
6688 416 : static enum ndr_err_code ndr_pull_samr_EnumDomains(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_EnumDomains *r)
6689 : {
6690 0 : uint32_t _ptr_sam;
6691 416 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
6692 416 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
6693 416 : TALLOC_CTX *_mem_save_sam_0 = NULL;
6694 416 : TALLOC_CTX *_mem_save_sam_1 = NULL;
6695 416 : TALLOC_CTX *_mem_save_num_entries_0 = NULL;
6696 416 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6697 416 : if (flags & NDR_IN) {
6698 190 : NDR_ZERO_STRUCT(r->out);
6699 :
6700 190 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6701 190 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6702 : }
6703 190 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6704 190 : NDR_PULL_SET_MEM_CTX(ndr, r->in.connect_handle, LIBNDR_FLAG_REF_ALLOC);
6705 190 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6706 190 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
6707 190 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6708 190 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
6709 : }
6710 190 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6711 190 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
6712 190 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
6713 190 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
6714 190 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.buf_size));
6715 190 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
6716 190 : *r->out.resume_handle = *r->in.resume_handle;
6717 190 : NDR_PULL_ALLOC(ndr, r->out.sam);
6718 190 : NDR_ZERO_STRUCTP(r->out.sam);
6719 190 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
6720 190 : NDR_ZERO_STRUCTP(r->out.num_entries);
6721 : }
6722 416 : if (flags & NDR_OUT) {
6723 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6724 : if (r->in.connect_handle == NULL) {
6725 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6726 : NDR_ZERO_STRUCTP(r->in.connect_handle);
6727 : }
6728 : if (r->in.resume_handle == NULL) {
6729 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
6730 : NDR_ZERO_STRUCTP(r->in.resume_handle);
6731 : }
6732 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6733 226 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6734 92 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
6735 : }
6736 226 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6737 226 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
6738 226 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
6739 226 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
6740 226 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6741 92 : NDR_PULL_ALLOC(ndr, r->out.sam);
6742 : }
6743 226 : _mem_save_sam_0 = NDR_PULL_GET_MEM_CTX(ndr);
6744 226 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sam, LIBNDR_FLAG_REF_ALLOC);
6745 226 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sam));
6746 226 : if (_ptr_sam) {
6747 204 : NDR_PULL_ALLOC(ndr, *r->out.sam);
6748 : } else {
6749 22 : *r->out.sam = NULL;
6750 : }
6751 226 : if (*r->out.sam) {
6752 204 : _mem_save_sam_1 = NDR_PULL_GET_MEM_CTX(ndr);
6753 204 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sam, 0);
6754 204 : NDR_CHECK(ndr_pull_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
6755 204 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_1, 0);
6756 : }
6757 226 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_0, LIBNDR_FLAG_REF_ALLOC);
6758 226 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6759 92 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
6760 : }
6761 226 : _mem_save_num_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
6762 226 : NDR_PULL_SET_MEM_CTX(ndr, r->out.num_entries, LIBNDR_FLAG_REF_ALLOC);
6763 226 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.num_entries));
6764 226 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_num_entries_0, LIBNDR_FLAG_REF_ALLOC);
6765 226 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6766 : }
6767 416 : return NDR_ERR_SUCCESS;
6768 : }
6769 :
6770 0 : _PUBLIC_ void ndr_print_samr_EnumDomains(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_EnumDomains *r)
6771 : {
6772 0 : ndr_print_struct(ndr, name, "samr_EnumDomains");
6773 0 : if (r == NULL) { ndr_print_null(ndr); return; }
6774 0 : ndr->depth++;
6775 0 : if (flags & NDR_SET_VALUES) {
6776 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6777 : }
6778 0 : if (flags & NDR_IN) {
6779 0 : ndr_print_struct(ndr, "in", "samr_EnumDomains");
6780 0 : ndr->depth++;
6781 0 : ndr_print_ptr(ndr, "connect_handle", r->in.connect_handle);
6782 0 : ndr->depth++;
6783 0 : ndr_print_policy_handle(ndr, "connect_handle", r->in.connect_handle);
6784 0 : ndr->depth--;
6785 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
6786 0 : ndr->depth++;
6787 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
6788 0 : ndr->depth--;
6789 0 : ndr_print_uint32(ndr, "buf_size", r->in.buf_size);
6790 0 : ndr->depth--;
6791 : }
6792 0 : if (flags & NDR_OUT) {
6793 0 : ndr_print_struct(ndr, "out", "samr_EnumDomains");
6794 0 : ndr->depth++;
6795 0 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
6796 0 : ndr->depth++;
6797 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
6798 0 : ndr->depth--;
6799 0 : ndr_print_ptr(ndr, "sam", r->out.sam);
6800 0 : ndr->depth++;
6801 0 : ndr_print_ptr(ndr, "sam", *r->out.sam);
6802 0 : ndr->depth++;
6803 0 : if (*r->out.sam) {
6804 0 : ndr_print_samr_SamArray(ndr, "sam", *r->out.sam);
6805 : }
6806 0 : ndr->depth--;
6807 0 : ndr->depth--;
6808 0 : ndr_print_ptr(ndr, "num_entries", r->out.num_entries);
6809 0 : ndr->depth++;
6810 0 : ndr_print_uint32(ndr, "num_entries", *r->out.num_entries);
6811 0 : ndr->depth--;
6812 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6813 0 : ndr->depth--;
6814 : }
6815 0 : ndr->depth--;
6816 : }
6817 :
6818 6244 : _PUBLIC_ enum ndr_err_code ndr_push_samr_OpenDomain(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_OpenDomain *r)
6819 : {
6820 6244 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6821 6244 : if (flags & NDR_IN) {
6822 2776 : if (r->in.connect_handle == NULL) {
6823 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6824 : }
6825 2776 : if (r->in.sid == NULL) {
6826 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6827 : }
6828 2776 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6829 2986 : NDR_CHECK(ndr_push_samr_DomainAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
6830 2776 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
6831 : }
6832 6244 : if (flags & NDR_OUT) {
6833 3468 : if (r->out.domain_handle == NULL) {
6834 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6835 : }
6836 3468 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.domain_handle));
6837 3468 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6838 : }
6839 5778 : return NDR_ERR_SUCCESS;
6840 : }
6841 :
6842 5914 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_OpenDomain(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_OpenDomain *r)
6843 : {
6844 5914 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
6845 5914 : TALLOC_CTX *_mem_save_sid_0 = NULL;
6846 5914 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
6847 5914 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6848 5914 : if (flags & NDR_IN) {
6849 3148 : NDR_ZERO_STRUCT(r->out);
6850 :
6851 3148 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6852 3148 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6853 : }
6854 3148 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6855 3148 : NDR_PULL_SET_MEM_CTX(ndr, r->in.connect_handle, LIBNDR_FLAG_REF_ALLOC);
6856 3148 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
6857 3148 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
6858 3364 : NDR_CHECK(ndr_pull_samr_DomainAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
6859 3148 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6860 3148 : NDR_PULL_ALLOC(ndr, r->in.sid);
6861 : }
6862 3148 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
6863 3148 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
6864 3148 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
6865 3148 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
6866 3148 : NDR_PULL_ALLOC(ndr, r->out.domain_handle);
6867 3148 : NDR_ZERO_STRUCTP(r->out.domain_handle);
6868 : }
6869 5914 : if (flags & NDR_OUT) {
6870 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6871 : if (r->in.connect_handle == NULL) {
6872 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
6873 : NDR_ZERO_STRUCTP(r->in.connect_handle);
6874 : }
6875 : if (r->in.sid == NULL) {
6876 : NDR_PULL_ALLOC(ndr, r->in.sid);
6877 : NDR_ZERO_STRUCTP(r->in.sid);
6878 : }
6879 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6880 2766 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6881 1149 : NDR_PULL_ALLOC(ndr, r->out.domain_handle);
6882 : }
6883 2766 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6884 2766 : NDR_PULL_SET_MEM_CTX(ndr, r->out.domain_handle, LIBNDR_FLAG_REF_ALLOC);
6885 2766 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.domain_handle));
6886 2766 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
6887 2766 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6888 : }
6889 5486 : return NDR_ERR_SUCCESS;
6890 : }
6891 :
6892 664 : _PUBLIC_ void ndr_print_samr_OpenDomain(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_OpenDomain *r)
6893 : {
6894 664 : ndr_print_struct(ndr, name, "samr_OpenDomain");
6895 664 : if (r == NULL) { ndr_print_null(ndr); return; }
6896 664 : ndr->depth++;
6897 664 : if (flags & NDR_SET_VALUES) {
6898 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
6899 : }
6900 664 : if (flags & NDR_IN) {
6901 2 : ndr_print_struct(ndr, "in", "samr_OpenDomain");
6902 2 : ndr->depth++;
6903 2 : ndr_print_ptr(ndr, "connect_handle", r->in.connect_handle);
6904 2 : ndr->depth++;
6905 2 : ndr_print_policy_handle(ndr, "connect_handle", r->in.connect_handle);
6906 2 : ndr->depth--;
6907 2 : ndr_print_samr_DomainAccessMask(ndr, "access_mask", r->in.access_mask);
6908 2 : ndr_print_ptr(ndr, "sid", r->in.sid);
6909 2 : ndr->depth++;
6910 2 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
6911 2 : ndr->depth--;
6912 2 : ndr->depth--;
6913 : }
6914 664 : if (flags & NDR_OUT) {
6915 662 : ndr_print_struct(ndr, "out", "samr_OpenDomain");
6916 662 : ndr->depth++;
6917 662 : ndr_print_ptr(ndr, "domain_handle", r->out.domain_handle);
6918 662 : ndr->depth++;
6919 662 : ndr_print_policy_handle(ndr, "domain_handle", r->out.domain_handle);
6920 662 : ndr->depth--;
6921 662 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
6922 662 : ndr->depth--;
6923 : }
6924 664 : ndr->depth--;
6925 : }
6926 :
6927 614 : static enum ndr_err_code ndr_push_samr_QueryDomainInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryDomainInfo *r)
6928 : {
6929 614 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
6930 614 : if (flags & NDR_IN) {
6931 363 : if (r->in.domain_handle == NULL) {
6932 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6933 : }
6934 363 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
6935 363 : NDR_CHECK(ndr_push_samr_DomainInfoClass(ndr, NDR_SCALARS, r->in.level));
6936 : }
6937 614 : if (flags & NDR_OUT) {
6938 251 : if (r->out.info == NULL) {
6939 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
6940 : }
6941 251 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
6942 251 : if (*r->out.info) {
6943 251 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
6944 251 : NDR_CHECK(ndr_push_samr_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
6945 : }
6946 251 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
6947 : }
6948 614 : return NDR_ERR_SUCCESS;
6949 : }
6950 :
6951 610 : static enum ndr_err_code ndr_pull_samr_QueryDomainInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryDomainInfo *r)
6952 : {
6953 0 : uint32_t _ptr_info;
6954 610 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
6955 610 : TALLOC_CTX *_mem_save_info_0 = NULL;
6956 610 : TALLOC_CTX *_mem_save_info_1 = NULL;
6957 610 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
6958 610 : if (flags & NDR_IN) {
6959 247 : NDR_ZERO_STRUCT(r->out);
6960 :
6961 247 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6962 247 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
6963 : }
6964 247 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
6965 247 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
6966 247 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
6967 247 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
6968 247 : NDR_CHECK(ndr_pull_samr_DomainInfoClass(ndr, NDR_SCALARS, &r->in.level));
6969 247 : NDR_PULL_ALLOC(ndr, r->out.info);
6970 247 : NDR_ZERO_STRUCTP(r->out.info);
6971 : }
6972 610 : if (flags & NDR_OUT) {
6973 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
6974 : if (r->in.domain_handle == NULL) {
6975 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
6976 : NDR_ZERO_STRUCTP(r->in.domain_handle);
6977 : }
6978 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
6979 363 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
6980 23 : NDR_PULL_ALLOC(ndr, r->out.info);
6981 : }
6982 363 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
6983 363 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
6984 363 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
6985 363 : if (_ptr_info) {
6986 363 : NDR_PULL_ALLOC(ndr, *r->out.info);
6987 : } else {
6988 0 : *r->out.info = NULL;
6989 : }
6990 363 : if (*r->out.info) {
6991 363 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
6992 363 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
6993 363 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
6994 363 : NDR_CHECK(ndr_pull_samr_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
6995 363 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
6996 : }
6997 363 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
6998 363 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
6999 : }
7000 610 : return NDR_ERR_SUCCESS;
7001 : }
7002 :
7003 8 : _PUBLIC_ void ndr_print_samr_QueryDomainInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryDomainInfo *r)
7004 : {
7005 8 : ndr_print_struct(ndr, name, "samr_QueryDomainInfo");
7006 8 : if (r == NULL) { ndr_print_null(ndr); return; }
7007 8 : ndr->depth++;
7008 8 : if (flags & NDR_SET_VALUES) {
7009 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7010 : }
7011 8 : if (flags & NDR_IN) {
7012 0 : ndr_print_struct(ndr, "in", "samr_QueryDomainInfo");
7013 0 : ndr->depth++;
7014 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7015 0 : ndr->depth++;
7016 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7017 0 : ndr->depth--;
7018 0 : ndr_print_samr_DomainInfoClass(ndr, "level", r->in.level);
7019 0 : ndr->depth--;
7020 : }
7021 8 : if (flags & NDR_OUT) {
7022 8 : ndr_print_struct(ndr, "out", "samr_QueryDomainInfo");
7023 8 : ndr->depth++;
7024 8 : ndr_print_ptr(ndr, "info", r->out.info);
7025 8 : ndr->depth++;
7026 8 : ndr_print_ptr(ndr, "info", *r->out.info);
7027 8 : ndr->depth++;
7028 8 : if (*r->out.info) {
7029 8 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
7030 8 : ndr_print_samr_DomainInfo(ndr, "info", *r->out.info);
7031 : }
7032 8 : ndr->depth--;
7033 8 : ndr->depth--;
7034 8 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7035 8 : ndr->depth--;
7036 : }
7037 8 : ndr->depth--;
7038 : }
7039 :
7040 536 : static enum ndr_err_code ndr_push_samr_SetDomainInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetDomainInfo *r)
7041 : {
7042 536 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7043 536 : if (flags & NDR_IN) {
7044 314 : if (r->in.domain_handle == NULL) {
7045 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7046 : }
7047 314 : if (r->in.info == NULL) {
7048 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7049 : }
7050 314 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7051 314 : NDR_CHECK(ndr_push_samr_DomainInfoClass(ndr, NDR_SCALARS, r->in.level));
7052 314 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
7053 314 : NDR_CHECK(ndr_push_samr_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
7054 : }
7055 536 : if (flags & NDR_OUT) {
7056 222 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7057 : }
7058 536 : return NDR_ERR_SUCCESS;
7059 : }
7060 :
7061 536 : static enum ndr_err_code ndr_pull_samr_SetDomainInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetDomainInfo *r)
7062 : {
7063 536 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
7064 536 : TALLOC_CTX *_mem_save_info_0 = NULL;
7065 536 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7066 536 : if (flags & NDR_IN) {
7067 222 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7068 222 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7069 : }
7070 222 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7071 222 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
7072 222 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7073 222 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
7074 222 : NDR_CHECK(ndr_pull_samr_DomainInfoClass(ndr, NDR_SCALARS, &r->in.level));
7075 222 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7076 222 : NDR_PULL_ALLOC(ndr, r->in.info);
7077 : }
7078 222 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
7079 222 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
7080 222 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
7081 222 : NDR_CHECK(ndr_pull_samr_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
7082 222 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
7083 : }
7084 536 : if (flags & NDR_OUT) {
7085 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7086 : if (r->in.domain_handle == NULL) {
7087 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7088 : NDR_ZERO_STRUCTP(r->in.domain_handle);
7089 : }
7090 : if (r->in.info == NULL) {
7091 : NDR_PULL_ALLOC(ndr, r->in.info);
7092 : NDR_ZERO_STRUCTP(r->in.info);
7093 : }
7094 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7095 314 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7096 : }
7097 536 : return NDR_ERR_SUCCESS;
7098 : }
7099 :
7100 0 : _PUBLIC_ void ndr_print_samr_SetDomainInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetDomainInfo *r)
7101 : {
7102 0 : ndr_print_struct(ndr, name, "samr_SetDomainInfo");
7103 0 : if (r == NULL) { ndr_print_null(ndr); return; }
7104 0 : ndr->depth++;
7105 0 : if (flags & NDR_SET_VALUES) {
7106 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7107 : }
7108 0 : if (flags & NDR_IN) {
7109 0 : ndr_print_struct(ndr, "in", "samr_SetDomainInfo");
7110 0 : ndr->depth++;
7111 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7112 0 : ndr->depth++;
7113 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7114 0 : ndr->depth--;
7115 0 : ndr_print_samr_DomainInfoClass(ndr, "level", r->in.level);
7116 0 : ndr_print_ptr(ndr, "info", r->in.info);
7117 0 : ndr->depth++;
7118 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
7119 0 : ndr_print_samr_DomainInfo(ndr, "info", r->in.info);
7120 0 : ndr->depth--;
7121 0 : ndr->depth--;
7122 : }
7123 0 : if (flags & NDR_OUT) {
7124 0 : ndr_print_struct(ndr, "out", "samr_SetDomainInfo");
7125 0 : ndr->depth++;
7126 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7127 0 : ndr->depth--;
7128 : }
7129 0 : ndr->depth--;
7130 : }
7131 :
7132 3177 : static enum ndr_err_code ndr_push_samr_CreateDomainGroup(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_CreateDomainGroup *r)
7133 : {
7134 3177 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7135 3177 : if (flags & NDR_IN) {
7136 1589 : if (r->in.domain_handle == NULL) {
7137 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7138 : }
7139 1589 : if (r->in.name == NULL) {
7140 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7141 : }
7142 1589 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7143 1589 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
7144 1589 : NDR_CHECK(ndr_push_samr_GroupAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
7145 : }
7146 3177 : if (flags & NDR_OUT) {
7147 1588 : if (r->out.group_handle == NULL) {
7148 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7149 : }
7150 1588 : if (r->out.rid == NULL) {
7151 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7152 : }
7153 1588 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.group_handle));
7154 1588 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.rid));
7155 1588 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7156 : }
7157 3177 : return NDR_ERR_SUCCESS;
7158 : }
7159 :
7160 3174 : static enum ndr_err_code ndr_pull_samr_CreateDomainGroup(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_CreateDomainGroup *r)
7161 : {
7162 3174 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
7163 3174 : TALLOC_CTX *_mem_save_name_0 = NULL;
7164 3174 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
7165 3174 : TALLOC_CTX *_mem_save_rid_0 = NULL;
7166 3174 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7167 3174 : if (flags & NDR_IN) {
7168 1585 : NDR_ZERO_STRUCT(r->out);
7169 :
7170 1585 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7171 1585 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7172 : }
7173 1585 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7174 1585 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
7175 1585 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7176 1585 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
7177 1585 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7178 1585 : NDR_PULL_ALLOC(ndr, r->in.name);
7179 : }
7180 1585 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
7181 1585 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, LIBNDR_FLAG_REF_ALLOC);
7182 1585 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
7183 1585 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
7184 1585 : NDR_CHECK(ndr_pull_samr_GroupAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
7185 1585 : NDR_PULL_ALLOC(ndr, r->out.group_handle);
7186 1585 : NDR_ZERO_STRUCTP(r->out.group_handle);
7187 1585 : NDR_PULL_ALLOC(ndr, r->out.rid);
7188 1585 : NDR_ZERO_STRUCTP(r->out.rid);
7189 : }
7190 3174 : if (flags & NDR_OUT) {
7191 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7192 : if (r->in.domain_handle == NULL) {
7193 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7194 : NDR_ZERO_STRUCTP(r->in.domain_handle);
7195 : }
7196 : if (r->in.name == NULL) {
7197 : NDR_PULL_ALLOC(ndr, r->in.name);
7198 : NDR_ZERO_STRUCTP(r->in.name);
7199 : }
7200 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7201 1589 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7202 75 : NDR_PULL_ALLOC(ndr, r->out.group_handle);
7203 : }
7204 1589 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7205 1589 : NDR_PULL_SET_MEM_CTX(ndr, r->out.group_handle, LIBNDR_FLAG_REF_ALLOC);
7206 1589 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.group_handle));
7207 1589 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
7208 1589 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7209 75 : NDR_PULL_ALLOC(ndr, r->out.rid);
7210 : }
7211 1589 : _mem_save_rid_0 = NDR_PULL_GET_MEM_CTX(ndr);
7212 1589 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rid, LIBNDR_FLAG_REF_ALLOC);
7213 1589 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.rid));
7214 1589 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rid_0, LIBNDR_FLAG_REF_ALLOC);
7215 1589 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7216 : }
7217 3174 : return NDR_ERR_SUCCESS;
7218 : }
7219 :
7220 6 : _PUBLIC_ void ndr_print_samr_CreateDomainGroup(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_CreateDomainGroup *r)
7221 : {
7222 6 : ndr_print_struct(ndr, name, "samr_CreateDomainGroup");
7223 6 : if (r == NULL) { ndr_print_null(ndr); return; }
7224 6 : ndr->depth++;
7225 6 : if (flags & NDR_SET_VALUES) {
7226 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7227 : }
7228 6 : if (flags & NDR_IN) {
7229 0 : ndr_print_struct(ndr, "in", "samr_CreateDomainGroup");
7230 0 : ndr->depth++;
7231 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7232 0 : ndr->depth++;
7233 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7234 0 : ndr->depth--;
7235 0 : ndr_print_ptr(ndr, "name", r->in.name);
7236 0 : ndr->depth++;
7237 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
7238 0 : ndr->depth--;
7239 0 : ndr_print_samr_GroupAccessMask(ndr, "access_mask", r->in.access_mask);
7240 0 : ndr->depth--;
7241 : }
7242 6 : if (flags & NDR_OUT) {
7243 6 : ndr_print_struct(ndr, "out", "samr_CreateDomainGroup");
7244 6 : ndr->depth++;
7245 6 : ndr_print_ptr(ndr, "group_handle", r->out.group_handle);
7246 6 : ndr->depth++;
7247 6 : ndr_print_policy_handle(ndr, "group_handle", r->out.group_handle);
7248 6 : ndr->depth--;
7249 6 : ndr_print_ptr(ndr, "rid", r->out.rid);
7250 6 : ndr->depth++;
7251 6 : ndr_print_uint32(ndr, "rid", *r->out.rid);
7252 6 : ndr->depth--;
7253 6 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7254 6 : ndr->depth--;
7255 : }
7256 6 : ndr->depth--;
7257 : }
7258 :
7259 305 : static enum ndr_err_code ndr_push_samr_EnumDomainGroups(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_EnumDomainGroups *r)
7260 : {
7261 305 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7262 305 : if (flags & NDR_IN) {
7263 147 : if (r->in.domain_handle == NULL) {
7264 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7265 : }
7266 147 : if (r->in.resume_handle == NULL) {
7267 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7268 : }
7269 147 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7270 147 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
7271 147 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_size));
7272 : }
7273 305 : if (flags & NDR_OUT) {
7274 158 : if (r->out.resume_handle == NULL) {
7275 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7276 : }
7277 158 : if (r->out.sam == NULL) {
7278 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7279 : }
7280 158 : if (r->out.num_entries == NULL) {
7281 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7282 : }
7283 158 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
7284 158 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sam));
7285 158 : if (*r->out.sam) {
7286 158 : NDR_CHECK(ndr_push_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
7287 : }
7288 158 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.num_entries));
7289 158 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7290 : }
7291 305 : return NDR_ERR_SUCCESS;
7292 : }
7293 :
7294 304 : static enum ndr_err_code ndr_pull_samr_EnumDomainGroups(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_EnumDomainGroups *r)
7295 : {
7296 0 : uint32_t _ptr_sam;
7297 304 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
7298 304 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
7299 304 : TALLOC_CTX *_mem_save_sam_0 = NULL;
7300 304 : TALLOC_CTX *_mem_save_sam_1 = NULL;
7301 304 : TALLOC_CTX *_mem_save_num_entries_0 = NULL;
7302 304 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7303 304 : if (flags & NDR_IN) {
7304 157 : NDR_ZERO_STRUCT(r->out);
7305 :
7306 157 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7307 157 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7308 : }
7309 157 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7310 157 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
7311 157 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7312 157 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
7313 157 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7314 157 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7315 : }
7316 157 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7317 157 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7318 157 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
7319 157 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7320 157 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_size));
7321 157 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7322 157 : *r->out.resume_handle = *r->in.resume_handle;
7323 157 : NDR_PULL_ALLOC(ndr, r->out.sam);
7324 157 : NDR_ZERO_STRUCTP(r->out.sam);
7325 157 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
7326 157 : NDR_ZERO_STRUCTP(r->out.num_entries);
7327 : }
7328 304 : if (flags & NDR_OUT) {
7329 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7330 : if (r->in.domain_handle == NULL) {
7331 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7332 : NDR_ZERO_STRUCTP(r->in.domain_handle);
7333 : }
7334 : if (r->in.resume_handle == NULL) {
7335 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7336 : NDR_ZERO_STRUCTP(r->in.resume_handle);
7337 : }
7338 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7339 147 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7340 70 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7341 : }
7342 147 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7343 147 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7344 147 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
7345 147 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7346 147 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7347 70 : NDR_PULL_ALLOC(ndr, r->out.sam);
7348 : }
7349 147 : _mem_save_sam_0 = NDR_PULL_GET_MEM_CTX(ndr);
7350 147 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sam, LIBNDR_FLAG_REF_ALLOC);
7351 147 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sam));
7352 147 : if (_ptr_sam) {
7353 147 : NDR_PULL_ALLOC(ndr, *r->out.sam);
7354 : } else {
7355 0 : *r->out.sam = NULL;
7356 : }
7357 147 : if (*r->out.sam) {
7358 147 : _mem_save_sam_1 = NDR_PULL_GET_MEM_CTX(ndr);
7359 147 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sam, 0);
7360 147 : NDR_CHECK(ndr_pull_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
7361 147 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_1, 0);
7362 : }
7363 147 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_0, LIBNDR_FLAG_REF_ALLOC);
7364 147 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7365 70 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
7366 : }
7367 147 : _mem_save_num_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
7368 147 : NDR_PULL_SET_MEM_CTX(ndr, r->out.num_entries, LIBNDR_FLAG_REF_ALLOC);
7369 147 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.num_entries));
7370 147 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_num_entries_0, LIBNDR_FLAG_REF_ALLOC);
7371 147 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7372 : }
7373 304 : return NDR_ERR_SUCCESS;
7374 : }
7375 :
7376 2 : _PUBLIC_ void ndr_print_samr_EnumDomainGroups(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_EnumDomainGroups *r)
7377 : {
7378 2 : ndr_print_struct(ndr, name, "samr_EnumDomainGroups");
7379 2 : if (r == NULL) { ndr_print_null(ndr); return; }
7380 2 : ndr->depth++;
7381 2 : if (flags & NDR_SET_VALUES) {
7382 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7383 : }
7384 2 : if (flags & NDR_IN) {
7385 0 : ndr_print_struct(ndr, "in", "samr_EnumDomainGroups");
7386 0 : ndr->depth++;
7387 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7388 0 : ndr->depth++;
7389 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7390 0 : ndr->depth--;
7391 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
7392 0 : ndr->depth++;
7393 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
7394 0 : ndr->depth--;
7395 0 : ndr_print_uint32(ndr, "max_size", r->in.max_size);
7396 0 : ndr->depth--;
7397 : }
7398 2 : if (flags & NDR_OUT) {
7399 2 : ndr_print_struct(ndr, "out", "samr_EnumDomainGroups");
7400 2 : ndr->depth++;
7401 2 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
7402 2 : ndr->depth++;
7403 2 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
7404 2 : ndr->depth--;
7405 2 : ndr_print_ptr(ndr, "sam", r->out.sam);
7406 2 : ndr->depth++;
7407 2 : ndr_print_ptr(ndr, "sam", *r->out.sam);
7408 2 : ndr->depth++;
7409 2 : if (*r->out.sam) {
7410 2 : ndr_print_samr_SamArray(ndr, "sam", *r->out.sam);
7411 : }
7412 2 : ndr->depth--;
7413 2 : ndr->depth--;
7414 2 : ndr_print_ptr(ndr, "num_entries", r->out.num_entries);
7415 2 : ndr->depth++;
7416 2 : ndr_print_uint32(ndr, "num_entries", *r->out.num_entries);
7417 2 : ndr->depth--;
7418 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7419 2 : ndr->depth--;
7420 : }
7421 2 : ndr->depth--;
7422 : }
7423 :
7424 2542 : static enum ndr_err_code ndr_push_samr_CreateUser(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_CreateUser *r)
7425 : {
7426 2542 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7427 2542 : if (flags & NDR_IN) {
7428 1581 : if (r->in.domain_handle == NULL) {
7429 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7430 : }
7431 1581 : if (r->in.account_name == NULL) {
7432 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7433 : }
7434 1581 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7435 1581 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account_name));
7436 1582 : NDR_CHECK(ndr_push_samr_UserAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
7437 : }
7438 2542 : if (flags & NDR_OUT) {
7439 961 : if (r->out.user_handle == NULL) {
7440 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7441 : }
7442 961 : if (r->out.rid == NULL) {
7443 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7444 : }
7445 961 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
7446 961 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.rid));
7447 961 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7448 : }
7449 2541 : return NDR_ERR_SUCCESS;
7450 : }
7451 :
7452 2536 : static enum ndr_err_code ndr_pull_samr_CreateUser(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_CreateUser *r)
7453 : {
7454 2536 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
7455 2536 : TALLOC_CTX *_mem_save_account_name_0 = NULL;
7456 2536 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
7457 2536 : TALLOC_CTX *_mem_save_rid_0 = NULL;
7458 2536 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7459 2536 : if (flags & NDR_IN) {
7460 954 : NDR_ZERO_STRUCT(r->out);
7461 :
7462 954 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7463 954 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7464 : }
7465 954 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7466 954 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
7467 954 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7468 954 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
7469 954 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7470 954 : NDR_PULL_ALLOC(ndr, r->in.account_name);
7471 : }
7472 954 : _mem_save_account_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
7473 954 : NDR_PULL_SET_MEM_CTX(ndr, r->in.account_name, LIBNDR_FLAG_REF_ALLOC);
7474 954 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account_name));
7475 954 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_name_0, LIBNDR_FLAG_REF_ALLOC);
7476 958 : NDR_CHECK(ndr_pull_samr_UserAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
7477 954 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
7478 954 : NDR_ZERO_STRUCTP(r->out.user_handle);
7479 954 : NDR_PULL_ALLOC(ndr, r->out.rid);
7480 954 : NDR_ZERO_STRUCTP(r->out.rid);
7481 : }
7482 2536 : if (flags & NDR_OUT) {
7483 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7484 : if (r->in.domain_handle == NULL) {
7485 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7486 : NDR_ZERO_STRUCTP(r->in.domain_handle);
7487 : }
7488 : if (r->in.account_name == NULL) {
7489 : NDR_PULL_ALLOC(ndr, r->in.account_name);
7490 : NDR_ZERO_STRUCTP(r->in.account_name);
7491 : }
7492 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7493 1582 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7494 13 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
7495 : }
7496 1582 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7497 1582 : NDR_PULL_SET_MEM_CTX(ndr, r->out.user_handle, LIBNDR_FLAG_REF_ALLOC);
7498 1582 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
7499 1582 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
7500 1582 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7501 13 : NDR_PULL_ALLOC(ndr, r->out.rid);
7502 : }
7503 1582 : _mem_save_rid_0 = NDR_PULL_GET_MEM_CTX(ndr);
7504 1582 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rid, LIBNDR_FLAG_REF_ALLOC);
7505 1582 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.rid));
7506 1582 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rid_0, LIBNDR_FLAG_REF_ALLOC);
7507 1582 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7508 : }
7509 2530 : return NDR_ERR_SUCCESS;
7510 : }
7511 :
7512 27 : _PUBLIC_ void ndr_print_samr_CreateUser(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_CreateUser *r)
7513 : {
7514 27 : ndr_print_struct(ndr, name, "samr_CreateUser");
7515 27 : if (r == NULL) { ndr_print_null(ndr); return; }
7516 27 : ndr->depth++;
7517 27 : if (flags & NDR_SET_VALUES) {
7518 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7519 : }
7520 27 : if (flags & NDR_IN) {
7521 3 : ndr_print_struct(ndr, "in", "samr_CreateUser");
7522 3 : ndr->depth++;
7523 3 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7524 3 : ndr->depth++;
7525 3 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7526 3 : ndr->depth--;
7527 3 : ndr_print_ptr(ndr, "account_name", r->in.account_name);
7528 3 : ndr->depth++;
7529 3 : ndr_print_lsa_String(ndr, "account_name", r->in.account_name);
7530 3 : ndr->depth--;
7531 3 : ndr_print_samr_UserAccessMask(ndr, "access_mask", r->in.access_mask);
7532 3 : ndr->depth--;
7533 : }
7534 27 : if (flags & NDR_OUT) {
7535 24 : ndr_print_struct(ndr, "out", "samr_CreateUser");
7536 24 : ndr->depth++;
7537 24 : ndr_print_ptr(ndr, "user_handle", r->out.user_handle);
7538 24 : ndr->depth++;
7539 24 : ndr_print_policy_handle(ndr, "user_handle", r->out.user_handle);
7540 24 : ndr->depth--;
7541 24 : ndr_print_ptr(ndr, "rid", r->out.rid);
7542 24 : ndr->depth++;
7543 24 : ndr_print_uint32(ndr, "rid", *r->out.rid);
7544 24 : ndr->depth--;
7545 24 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7546 24 : ndr->depth--;
7547 : }
7548 27 : ndr->depth--;
7549 : }
7550 :
7551 312 : static enum ndr_err_code ndr_push_samr_EnumDomainUsers(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_EnumDomainUsers *r)
7552 : {
7553 312 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7554 312 : if (flags & NDR_IN) {
7555 154 : if (r->in.domain_handle == NULL) {
7556 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7557 : }
7558 154 : if (r->in.resume_handle == NULL) {
7559 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7560 : }
7561 154 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7562 154 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
7563 154 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->in.acct_flags));
7564 154 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_size));
7565 : }
7566 312 : if (flags & NDR_OUT) {
7567 158 : if (r->out.resume_handle == NULL) {
7568 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7569 : }
7570 158 : if (r->out.sam == NULL) {
7571 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7572 : }
7573 158 : if (r->out.num_entries == NULL) {
7574 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7575 : }
7576 158 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
7577 158 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sam));
7578 158 : if (*r->out.sam) {
7579 158 : NDR_CHECK(ndr_push_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
7580 : }
7581 158 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.num_entries));
7582 158 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7583 : }
7584 312 : return NDR_ERR_SUCCESS;
7585 : }
7586 :
7587 312 : static enum ndr_err_code ndr_pull_samr_EnumDomainUsers(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_EnumDomainUsers *r)
7588 : {
7589 0 : uint32_t _ptr_sam;
7590 312 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
7591 312 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
7592 312 : TALLOC_CTX *_mem_save_sam_0 = NULL;
7593 312 : TALLOC_CTX *_mem_save_sam_1 = NULL;
7594 312 : TALLOC_CTX *_mem_save_num_entries_0 = NULL;
7595 312 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7596 312 : if (flags & NDR_IN) {
7597 158 : NDR_ZERO_STRUCT(r->out);
7598 :
7599 158 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7600 158 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7601 : }
7602 158 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7603 158 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
7604 158 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7605 158 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
7606 158 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7607 158 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7608 : }
7609 158 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7610 158 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7611 158 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
7612 158 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7613 158 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->in.acct_flags));
7614 158 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_size));
7615 158 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7616 158 : *r->out.resume_handle = *r->in.resume_handle;
7617 158 : NDR_PULL_ALLOC(ndr, r->out.sam);
7618 158 : NDR_ZERO_STRUCTP(r->out.sam);
7619 158 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
7620 158 : NDR_ZERO_STRUCTP(r->out.num_entries);
7621 : }
7622 312 : if (flags & NDR_OUT) {
7623 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7624 : if (r->in.domain_handle == NULL) {
7625 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7626 : NDR_ZERO_STRUCTP(r->in.domain_handle);
7627 : }
7628 : if (r->in.resume_handle == NULL) {
7629 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7630 : NDR_ZERO_STRUCTP(r->in.resume_handle);
7631 : }
7632 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7633 154 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7634 60 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7635 : }
7636 154 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7637 154 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7638 154 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
7639 154 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7640 154 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7641 60 : NDR_PULL_ALLOC(ndr, r->out.sam);
7642 : }
7643 154 : _mem_save_sam_0 = NDR_PULL_GET_MEM_CTX(ndr);
7644 154 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sam, LIBNDR_FLAG_REF_ALLOC);
7645 154 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sam));
7646 154 : if (_ptr_sam) {
7647 154 : NDR_PULL_ALLOC(ndr, *r->out.sam);
7648 : } else {
7649 0 : *r->out.sam = NULL;
7650 : }
7651 154 : if (*r->out.sam) {
7652 154 : _mem_save_sam_1 = NDR_PULL_GET_MEM_CTX(ndr);
7653 154 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sam, 0);
7654 154 : NDR_CHECK(ndr_pull_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
7655 154 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_1, 0);
7656 : }
7657 154 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_0, LIBNDR_FLAG_REF_ALLOC);
7658 154 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7659 60 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
7660 : }
7661 154 : _mem_save_num_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
7662 154 : NDR_PULL_SET_MEM_CTX(ndr, r->out.num_entries, LIBNDR_FLAG_REF_ALLOC);
7663 154 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.num_entries));
7664 154 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_num_entries_0, LIBNDR_FLAG_REF_ALLOC);
7665 154 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7666 : }
7667 312 : return NDR_ERR_SUCCESS;
7668 : }
7669 :
7670 0 : _PUBLIC_ void ndr_print_samr_EnumDomainUsers(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_EnumDomainUsers *r)
7671 : {
7672 0 : ndr_print_struct(ndr, name, "samr_EnumDomainUsers");
7673 0 : if (r == NULL) { ndr_print_null(ndr); return; }
7674 0 : ndr->depth++;
7675 0 : if (flags & NDR_SET_VALUES) {
7676 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7677 : }
7678 0 : if (flags & NDR_IN) {
7679 0 : ndr_print_struct(ndr, "in", "samr_EnumDomainUsers");
7680 0 : ndr->depth++;
7681 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7682 0 : ndr->depth++;
7683 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7684 0 : ndr->depth--;
7685 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
7686 0 : ndr->depth++;
7687 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
7688 0 : ndr->depth--;
7689 0 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->in.acct_flags);
7690 0 : ndr_print_uint32(ndr, "max_size", r->in.max_size);
7691 0 : ndr->depth--;
7692 : }
7693 0 : if (flags & NDR_OUT) {
7694 0 : ndr_print_struct(ndr, "out", "samr_EnumDomainUsers");
7695 0 : ndr->depth++;
7696 0 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
7697 0 : ndr->depth++;
7698 0 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
7699 0 : ndr->depth--;
7700 0 : ndr_print_ptr(ndr, "sam", r->out.sam);
7701 0 : ndr->depth++;
7702 0 : ndr_print_ptr(ndr, "sam", *r->out.sam);
7703 0 : ndr->depth++;
7704 0 : if (*r->out.sam) {
7705 0 : ndr_print_samr_SamArray(ndr, "sam", *r->out.sam);
7706 : }
7707 0 : ndr->depth--;
7708 0 : ndr->depth--;
7709 0 : ndr_print_ptr(ndr, "num_entries", r->out.num_entries);
7710 0 : ndr->depth++;
7711 0 : ndr_print_uint32(ndr, "num_entries", *r->out.num_entries);
7712 0 : ndr->depth--;
7713 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7714 0 : ndr->depth--;
7715 : }
7716 0 : ndr->depth--;
7717 : }
7718 :
7719 3016 : static enum ndr_err_code ndr_push_samr_CreateDomAlias(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_CreateDomAlias *r)
7720 : {
7721 3016 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7722 3016 : if (flags & NDR_IN) {
7723 1510 : if (r->in.domain_handle == NULL) {
7724 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7725 : }
7726 1510 : if (r->in.alias_name == NULL) {
7727 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7728 : }
7729 1510 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7730 1510 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.alias_name));
7731 1510 : NDR_CHECK(ndr_push_samr_AliasAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
7732 : }
7733 3016 : if (flags & NDR_OUT) {
7734 1506 : if (r->out.alias_handle == NULL) {
7735 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7736 : }
7737 1506 : if (r->out.rid == NULL) {
7738 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7739 : }
7740 1506 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.alias_handle));
7741 1506 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.rid));
7742 1506 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7743 : }
7744 3016 : return NDR_ERR_SUCCESS;
7745 : }
7746 :
7747 3016 : static enum ndr_err_code ndr_pull_samr_CreateDomAlias(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_CreateDomAlias *r)
7748 : {
7749 3016 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
7750 3016 : TALLOC_CTX *_mem_save_alias_name_0 = NULL;
7751 3016 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
7752 3016 : TALLOC_CTX *_mem_save_rid_0 = NULL;
7753 3016 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7754 3016 : if (flags & NDR_IN) {
7755 1506 : NDR_ZERO_STRUCT(r->out);
7756 :
7757 1506 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7758 1506 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7759 : }
7760 1506 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7761 1506 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
7762 1506 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7763 1506 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
7764 1506 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7765 1506 : NDR_PULL_ALLOC(ndr, r->in.alias_name);
7766 : }
7767 1506 : _mem_save_alias_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
7768 1506 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_name, LIBNDR_FLAG_REF_ALLOC);
7769 1506 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.alias_name));
7770 1506 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_name_0, LIBNDR_FLAG_REF_ALLOC);
7771 1506 : NDR_CHECK(ndr_pull_samr_AliasAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
7772 1506 : NDR_PULL_ALLOC(ndr, r->out.alias_handle);
7773 1506 : NDR_ZERO_STRUCTP(r->out.alias_handle);
7774 1506 : NDR_PULL_ALLOC(ndr, r->out.rid);
7775 1506 : NDR_ZERO_STRUCTP(r->out.rid);
7776 : }
7777 3016 : if (flags & NDR_OUT) {
7778 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7779 : if (r->in.domain_handle == NULL) {
7780 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7781 : NDR_ZERO_STRUCTP(r->in.domain_handle);
7782 : }
7783 : if (r->in.alias_name == NULL) {
7784 : NDR_PULL_ALLOC(ndr, r->in.alias_name);
7785 : NDR_ZERO_STRUCTP(r->in.alias_name);
7786 : }
7787 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7788 1510 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7789 0 : NDR_PULL_ALLOC(ndr, r->out.alias_handle);
7790 : }
7791 1510 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7792 1510 : NDR_PULL_SET_MEM_CTX(ndr, r->out.alias_handle, LIBNDR_FLAG_REF_ALLOC);
7793 1510 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.alias_handle));
7794 1510 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
7795 1510 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7796 0 : NDR_PULL_ALLOC(ndr, r->out.rid);
7797 : }
7798 1510 : _mem_save_rid_0 = NDR_PULL_GET_MEM_CTX(ndr);
7799 1510 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rid, LIBNDR_FLAG_REF_ALLOC);
7800 1510 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.rid));
7801 1510 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rid_0, LIBNDR_FLAG_REF_ALLOC);
7802 1510 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7803 : }
7804 3016 : return NDR_ERR_SUCCESS;
7805 : }
7806 :
7807 0 : _PUBLIC_ void ndr_print_samr_CreateDomAlias(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_CreateDomAlias *r)
7808 : {
7809 0 : ndr_print_struct(ndr, name, "samr_CreateDomAlias");
7810 0 : if (r == NULL) { ndr_print_null(ndr); return; }
7811 0 : ndr->depth++;
7812 0 : if (flags & NDR_SET_VALUES) {
7813 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7814 : }
7815 0 : if (flags & NDR_IN) {
7816 0 : ndr_print_struct(ndr, "in", "samr_CreateDomAlias");
7817 0 : ndr->depth++;
7818 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7819 0 : ndr->depth++;
7820 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7821 0 : ndr->depth--;
7822 0 : ndr_print_ptr(ndr, "alias_name", r->in.alias_name);
7823 0 : ndr->depth++;
7824 0 : ndr_print_lsa_String(ndr, "alias_name", r->in.alias_name);
7825 0 : ndr->depth--;
7826 0 : ndr_print_samr_AliasAccessMask(ndr, "access_mask", r->in.access_mask);
7827 0 : ndr->depth--;
7828 : }
7829 0 : if (flags & NDR_OUT) {
7830 0 : ndr_print_struct(ndr, "out", "samr_CreateDomAlias");
7831 0 : ndr->depth++;
7832 0 : ndr_print_ptr(ndr, "alias_handle", r->out.alias_handle);
7833 0 : ndr->depth++;
7834 0 : ndr_print_policy_handle(ndr, "alias_handle", r->out.alias_handle);
7835 0 : ndr->depth--;
7836 0 : ndr_print_ptr(ndr, "rid", r->out.rid);
7837 0 : ndr->depth++;
7838 0 : ndr_print_uint32(ndr, "rid", *r->out.rid);
7839 0 : ndr->depth--;
7840 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
7841 0 : ndr->depth--;
7842 : }
7843 0 : ndr->depth--;
7844 : }
7845 :
7846 121 : static enum ndr_err_code ndr_push_samr_EnumDomainAliases(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_EnumDomainAliases *r)
7847 : {
7848 121 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
7849 121 : if (flags & NDR_IN) {
7850 48 : if (r->in.domain_handle == NULL) {
7851 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7852 : }
7853 48 : if (r->in.resume_handle == NULL) {
7854 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7855 : }
7856 48 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7857 48 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->in.resume_handle));
7858 48 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_size));
7859 : }
7860 121 : if (flags & NDR_OUT) {
7861 73 : if (r->out.resume_handle == NULL) {
7862 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7863 : }
7864 73 : if (r->out.sam == NULL) {
7865 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7866 : }
7867 73 : if (r->out.num_entries == NULL) {
7868 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
7869 : }
7870 73 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.resume_handle));
7871 73 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sam));
7872 73 : if (*r->out.sam) {
7873 73 : NDR_CHECK(ndr_push_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
7874 : }
7875 73 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.num_entries));
7876 73 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
7877 : }
7878 121 : return NDR_ERR_SUCCESS;
7879 : }
7880 :
7881 120 : static enum ndr_err_code ndr_pull_samr_EnumDomainAliases(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_EnumDomainAliases *r)
7882 : {
7883 0 : uint32_t _ptr_sam;
7884 120 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
7885 120 : TALLOC_CTX *_mem_save_resume_handle_0 = NULL;
7886 120 : TALLOC_CTX *_mem_save_sam_0 = NULL;
7887 120 : TALLOC_CTX *_mem_save_sam_1 = NULL;
7888 120 : TALLOC_CTX *_mem_save_num_entries_0 = NULL;
7889 120 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
7890 120 : if (flags & NDR_IN) {
7891 72 : NDR_ZERO_STRUCT(r->out);
7892 :
7893 72 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7894 72 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7895 : }
7896 72 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7897 72 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
7898 72 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
7899 72 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
7900 72 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7901 72 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7902 : }
7903 72 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7904 72 : NDR_PULL_SET_MEM_CTX(ndr, r->in.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7905 72 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->in.resume_handle));
7906 72 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7907 72 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_size));
7908 72 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7909 72 : *r->out.resume_handle = *r->in.resume_handle;
7910 72 : NDR_PULL_ALLOC(ndr, r->out.sam);
7911 72 : NDR_ZERO_STRUCTP(r->out.sam);
7912 72 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
7913 72 : NDR_ZERO_STRUCTP(r->out.num_entries);
7914 : }
7915 120 : if (flags & NDR_OUT) {
7916 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
7917 : if (r->in.domain_handle == NULL) {
7918 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
7919 : NDR_ZERO_STRUCTP(r->in.domain_handle);
7920 : }
7921 : if (r->in.resume_handle == NULL) {
7922 : NDR_PULL_ALLOC(ndr, r->in.resume_handle);
7923 : NDR_ZERO_STRUCTP(r->in.resume_handle);
7924 : }
7925 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
7926 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7927 23 : NDR_PULL_ALLOC(ndr, r->out.resume_handle);
7928 : }
7929 48 : _mem_save_resume_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
7930 48 : NDR_PULL_SET_MEM_CTX(ndr, r->out.resume_handle, LIBNDR_FLAG_REF_ALLOC);
7931 48 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.resume_handle));
7932 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_resume_handle_0, LIBNDR_FLAG_REF_ALLOC);
7933 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7934 23 : NDR_PULL_ALLOC(ndr, r->out.sam);
7935 : }
7936 48 : _mem_save_sam_0 = NDR_PULL_GET_MEM_CTX(ndr);
7937 48 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sam, LIBNDR_FLAG_REF_ALLOC);
7938 48 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sam));
7939 48 : if (_ptr_sam) {
7940 48 : NDR_PULL_ALLOC(ndr, *r->out.sam);
7941 : } else {
7942 0 : *r->out.sam = NULL;
7943 : }
7944 48 : if (*r->out.sam) {
7945 48 : _mem_save_sam_1 = NDR_PULL_GET_MEM_CTX(ndr);
7946 48 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sam, 0);
7947 48 : NDR_CHECK(ndr_pull_samr_SamArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sam));
7948 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_1, 0);
7949 : }
7950 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sam_0, LIBNDR_FLAG_REF_ALLOC);
7951 48 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
7952 23 : NDR_PULL_ALLOC(ndr, r->out.num_entries);
7953 : }
7954 48 : _mem_save_num_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
7955 48 : NDR_PULL_SET_MEM_CTX(ndr, r->out.num_entries, LIBNDR_FLAG_REF_ALLOC);
7956 48 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.num_entries));
7957 48 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_num_entries_0, LIBNDR_FLAG_REF_ALLOC);
7958 48 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
7959 : }
7960 120 : return NDR_ERR_SUCCESS;
7961 : }
7962 :
7963 2 : _PUBLIC_ void ndr_print_samr_EnumDomainAliases(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_EnumDomainAliases *r)
7964 : {
7965 2 : ndr_print_struct(ndr, name, "samr_EnumDomainAliases");
7966 2 : if (r == NULL) { ndr_print_null(ndr); return; }
7967 2 : ndr->depth++;
7968 2 : if (flags & NDR_SET_VALUES) {
7969 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
7970 : }
7971 2 : if (flags & NDR_IN) {
7972 0 : ndr_print_struct(ndr, "in", "samr_EnumDomainAliases");
7973 0 : ndr->depth++;
7974 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
7975 0 : ndr->depth++;
7976 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
7977 0 : ndr->depth--;
7978 0 : ndr_print_ptr(ndr, "resume_handle", r->in.resume_handle);
7979 0 : ndr->depth++;
7980 0 : ndr_print_uint32(ndr, "resume_handle", *r->in.resume_handle);
7981 0 : ndr->depth--;
7982 0 : ndr_print_uint32(ndr, "max_size", r->in.max_size);
7983 0 : ndr->depth--;
7984 : }
7985 2 : if (flags & NDR_OUT) {
7986 2 : ndr_print_struct(ndr, "out", "samr_EnumDomainAliases");
7987 2 : ndr->depth++;
7988 2 : ndr_print_ptr(ndr, "resume_handle", r->out.resume_handle);
7989 2 : ndr->depth++;
7990 2 : ndr_print_uint32(ndr, "resume_handle", *r->out.resume_handle);
7991 2 : ndr->depth--;
7992 2 : ndr_print_ptr(ndr, "sam", r->out.sam);
7993 2 : ndr->depth++;
7994 2 : ndr_print_ptr(ndr, "sam", *r->out.sam);
7995 2 : ndr->depth++;
7996 2 : if (*r->out.sam) {
7997 2 : ndr_print_samr_SamArray(ndr, "sam", *r->out.sam);
7998 : }
7999 2 : ndr->depth--;
8000 2 : ndr->depth--;
8001 2 : ndr_print_ptr(ndr, "num_entries", r->out.num_entries);
8002 2 : ndr->depth++;
8003 2 : ndr_print_uint32(ndr, "num_entries", *r->out.num_entries);
8004 2 : ndr->depth--;
8005 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8006 2 : ndr->depth--;
8007 : }
8008 2 : ndr->depth--;
8009 : }
8010 :
8011 4491 : static enum ndr_err_code ndr_push_samr_GetAliasMembership(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetAliasMembership *r)
8012 : {
8013 4491 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8014 4491 : if (flags & NDR_IN) {
8015 430 : if (r->in.domain_handle == NULL) {
8016 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8017 : }
8018 430 : if (r->in.sids == NULL) {
8019 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8020 : }
8021 430 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8022 430 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
8023 : }
8024 4491 : if (flags & NDR_OUT) {
8025 4061 : if (r->out.rids == NULL) {
8026 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8027 : }
8028 4061 : NDR_CHECK(ndr_push_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.rids));
8029 4061 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8030 : }
8031 4491 : return NDR_ERR_SUCCESS;
8032 : }
8033 :
8034 4486 : static enum ndr_err_code ndr_pull_samr_GetAliasMembership(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetAliasMembership *r)
8035 : {
8036 4486 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
8037 4486 : TALLOC_CTX *_mem_save_sids_0 = NULL;
8038 4486 : TALLOC_CTX *_mem_save_rids_0 = NULL;
8039 4486 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8040 4486 : if (flags & NDR_IN) {
8041 4056 : NDR_ZERO_STRUCT(r->out);
8042 :
8043 4056 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8044 4056 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8045 : }
8046 4056 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8047 4056 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
8048 4056 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8049 4056 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
8050 4056 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8051 4056 : NDR_PULL_ALLOC(ndr, r->in.sids);
8052 : }
8053 4056 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
8054 4056 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
8055 4056 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
8056 4056 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
8057 4056 : NDR_PULL_ALLOC(ndr, r->out.rids);
8058 4056 : NDR_ZERO_STRUCTP(r->out.rids);
8059 : }
8060 4486 : if (flags & NDR_OUT) {
8061 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8062 : if (r->in.domain_handle == NULL) {
8063 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8064 : NDR_ZERO_STRUCTP(r->in.domain_handle);
8065 : }
8066 : if (r->in.sids == NULL) {
8067 : NDR_PULL_ALLOC(ndr, r->in.sids);
8068 : NDR_ZERO_STRUCTP(r->in.sids);
8069 : }
8070 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8071 430 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8072 91 : NDR_PULL_ALLOC(ndr, r->out.rids);
8073 : }
8074 430 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
8075 430 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rids, LIBNDR_FLAG_REF_ALLOC);
8076 430 : NDR_CHECK(ndr_pull_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.rids));
8077 430 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, LIBNDR_FLAG_REF_ALLOC);
8078 430 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8079 : }
8080 4486 : return NDR_ERR_SUCCESS;
8081 : }
8082 :
8083 10 : _PUBLIC_ void ndr_print_samr_GetAliasMembership(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetAliasMembership *r)
8084 : {
8085 10 : ndr_print_struct(ndr, name, "samr_GetAliasMembership");
8086 10 : if (r == NULL) { ndr_print_null(ndr); return; }
8087 10 : ndr->depth++;
8088 10 : if (flags & NDR_SET_VALUES) {
8089 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8090 : }
8091 10 : if (flags & NDR_IN) {
8092 0 : ndr_print_struct(ndr, "in", "samr_GetAliasMembership");
8093 0 : ndr->depth++;
8094 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
8095 0 : ndr->depth++;
8096 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
8097 0 : ndr->depth--;
8098 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
8099 0 : ndr->depth++;
8100 0 : ndr_print_lsa_SidArray(ndr, "sids", r->in.sids);
8101 0 : ndr->depth--;
8102 0 : ndr->depth--;
8103 : }
8104 10 : if (flags & NDR_OUT) {
8105 10 : ndr_print_struct(ndr, "out", "samr_GetAliasMembership");
8106 10 : ndr->depth++;
8107 10 : ndr_print_ptr(ndr, "rids", r->out.rids);
8108 10 : ndr->depth++;
8109 10 : ndr_print_samr_Ids(ndr, "rids", r->out.rids);
8110 10 : ndr->depth--;
8111 10 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8112 10 : ndr->depth--;
8113 : }
8114 10 : ndr->depth--;
8115 : }
8116 :
8117 8662 : _PUBLIC_ enum ndr_err_code ndr_push_samr_LookupNames(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_LookupNames *r)
8118 : {
8119 17 : uint32_t cntr_names_0;
8120 8662 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8121 8662 : if (flags & NDR_IN) {
8122 2628 : if (r->in.domain_handle == NULL) {
8123 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8124 : }
8125 2628 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8126 2628 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_names));
8127 2628 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 1000));
8128 2628 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
8129 2628 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.num_names));
8130 5643 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
8131 3015 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
8132 : }
8133 5643 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
8134 3015 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
8135 : }
8136 : }
8137 8662 : if (flags & NDR_OUT) {
8138 6034 : if (r->out.rids == NULL) {
8139 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8140 : }
8141 6034 : if (r->out.types == NULL) {
8142 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8143 : }
8144 6034 : NDR_CHECK(ndr_push_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.rids));
8145 6034 : NDR_CHECK(ndr_push_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.types));
8146 6034 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8147 : }
8148 8645 : return NDR_ERR_SUCCESS;
8149 : }
8150 :
8151 8568 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_LookupNames(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_LookupNames *r)
8152 : {
8153 8568 : uint32_t size_names_0 = 0;
8154 8568 : uint32_t length_names_0 = 0;
8155 21 : uint32_t cntr_names_0;
8156 8568 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
8157 8568 : TALLOC_CTX *_mem_save_names_0 = NULL;
8158 8568 : TALLOC_CTX *_mem_save_rids_0 = NULL;
8159 8568 : TALLOC_CTX *_mem_save_types_0 = NULL;
8160 8568 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8161 8568 : if (flags & NDR_IN) {
8162 5938 : NDR_ZERO_STRUCT(r->out);
8163 :
8164 5938 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8165 5938 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8166 : }
8167 5938 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8168 5938 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
8169 5938 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8170 5938 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
8171 5938 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_names));
8172 5938 : if (r->in.num_names > 1000) {
8173 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->in.num_names), (uint32_t)(0), (uint32_t)(1000));
8174 : }
8175 5938 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.names));
8176 5938 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.names));
8177 5938 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.names, &size_names_0));
8178 5938 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->in.names, &length_names_0));
8179 5938 : if (length_names_0 > size_names_0) {
8180 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_names_0, length_names_0);
8181 : }
8182 5938 : NDR_PULL_ALLOC_N(ndr, r->in.names, size_names_0);
8183 5938 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
8184 5938 : NDR_PULL_SET_MEM_CTX(ndr, r->in.names, 0);
8185 12231 : for (cntr_names_0 = 0; cntr_names_0 < (length_names_0); cntr_names_0++) {
8186 6293 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS, &r->in.names[cntr_names_0]));
8187 : }
8188 12231 : for (cntr_names_0 = 0; cntr_names_0 < (length_names_0); cntr_names_0++) {
8189 6293 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_BUFFERS, &r->in.names[cntr_names_0]));
8190 : }
8191 5938 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, 0);
8192 5938 : NDR_PULL_ALLOC(ndr, r->out.rids);
8193 5938 : NDR_ZERO_STRUCTP(r->out.rids);
8194 5938 : NDR_PULL_ALLOC(ndr, r->out.types);
8195 5938 : NDR_ZERO_STRUCTP(r->out.types);
8196 5938 : if (r->in.names) {
8197 5938 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->in.names, 1000));
8198 : }
8199 5938 : if (r->in.names) {
8200 5938 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->in.names, r->in.num_names));
8201 : }
8202 12231 : for (cntr_names_0 = 0; cntr_names_0 < (length_names_0); cntr_names_0++) {
8203 19 : }
8204 : }
8205 8568 : if (flags & NDR_OUT) {
8206 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8207 : if (r->in.domain_handle == NULL) {
8208 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8209 : NDR_ZERO_STRUCTP(r->in.domain_handle);
8210 : }
8211 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8212 2630 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8213 399 : NDR_PULL_ALLOC(ndr, r->out.rids);
8214 : }
8215 2630 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
8216 2630 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rids, LIBNDR_FLAG_REF_ALLOC);
8217 2630 : NDR_CHECK(ndr_pull_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.rids));
8218 2630 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, LIBNDR_FLAG_REF_ALLOC);
8219 2630 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8220 399 : NDR_PULL_ALLOC(ndr, r->out.types);
8221 : }
8222 2630 : _mem_save_types_0 = NDR_PULL_GET_MEM_CTX(ndr);
8223 2630 : NDR_PULL_SET_MEM_CTX(ndr, r->out.types, LIBNDR_FLAG_REF_ALLOC);
8224 2630 : NDR_CHECK(ndr_pull_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.types));
8225 2630 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_types_0, LIBNDR_FLAG_REF_ALLOC);
8226 2630 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8227 : }
8228 8547 : return NDR_ERR_SUCCESS;
8229 : }
8230 :
8231 200 : _PUBLIC_ void ndr_print_samr_LookupNames(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_LookupNames *r)
8232 : {
8233 4 : uint32_t cntr_names_0;
8234 200 : ndr_print_struct(ndr, name, "samr_LookupNames");
8235 200 : if (r == NULL) { ndr_print_null(ndr); return; }
8236 200 : ndr->depth++;
8237 200 : if (flags & NDR_SET_VALUES) {
8238 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8239 : }
8240 200 : if (flags & NDR_IN) {
8241 2 : ndr_print_struct(ndr, "in", "samr_LookupNames");
8242 2 : ndr->depth++;
8243 2 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
8244 2 : ndr->depth++;
8245 2 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
8246 2 : ndr->depth--;
8247 2 : ndr_print_uint32(ndr, "num_names", r->in.num_names);
8248 2 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "names", (uint32_t)(r->in.num_names));
8249 2 : ndr->depth++;
8250 4 : for (cntr_names_0 = 0; cntr_names_0 < (r->in.num_names); cntr_names_0++) {
8251 2 : ndr_print_lsa_String(ndr, "names", &r->in.names[cntr_names_0]);
8252 : }
8253 2 : ndr->depth--;
8254 2 : ndr->depth--;
8255 : }
8256 200 : if (flags & NDR_OUT) {
8257 198 : ndr_print_struct(ndr, "out", "samr_LookupNames");
8258 198 : ndr->depth++;
8259 198 : ndr_print_ptr(ndr, "rids", r->out.rids);
8260 198 : ndr->depth++;
8261 198 : ndr_print_samr_Ids(ndr, "rids", r->out.rids);
8262 198 : ndr->depth--;
8263 198 : ndr_print_ptr(ndr, "types", r->out.types);
8264 198 : ndr->depth++;
8265 198 : ndr_print_samr_Ids(ndr, "types", r->out.types);
8266 198 : ndr->depth--;
8267 198 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8268 198 : ndr->depth--;
8269 : }
8270 200 : ndr->depth--;
8271 : }
8272 :
8273 2640 : static enum ndr_err_code ndr_push_samr_LookupRids(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_LookupRids *r)
8274 : {
8275 0 : uint32_t cntr_rids_0;
8276 2640 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8277 2640 : if (flags & NDR_IN) {
8278 1063 : if (r->in.domain_handle == NULL) {
8279 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8280 : }
8281 1063 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8282 1063 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.num_rids));
8283 1063 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 1000));
8284 1063 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
8285 1063 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->in.num_rids));
8286 2154 : for (cntr_rids_0 = 0; cntr_rids_0 < (r->in.num_rids); cntr_rids_0++) {
8287 1091 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.rids[cntr_rids_0]));
8288 : }
8289 : }
8290 2640 : if (flags & NDR_OUT) {
8291 1577 : if (r->out.names == NULL) {
8292 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8293 : }
8294 1577 : if (r->out.types == NULL) {
8295 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8296 : }
8297 1577 : NDR_CHECK(ndr_push_lsa_Strings(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
8298 1577 : NDR_CHECK(ndr_push_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.types));
8299 1577 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8300 : }
8301 2640 : return NDR_ERR_SUCCESS;
8302 : }
8303 :
8304 2610 : static enum ndr_err_code ndr_pull_samr_LookupRids(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_LookupRids *r)
8305 : {
8306 2610 : uint32_t size_rids_0 = 0;
8307 2610 : uint32_t length_rids_0 = 0;
8308 0 : uint32_t cntr_rids_0;
8309 2610 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
8310 2610 : TALLOC_CTX *_mem_save_rids_0 = NULL;
8311 2610 : TALLOC_CTX *_mem_save_names_0 = NULL;
8312 2610 : TALLOC_CTX *_mem_save_types_0 = NULL;
8313 2610 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8314 2610 : if (flags & NDR_IN) {
8315 1547 : NDR_ZERO_STRUCT(r->out);
8316 :
8317 1547 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8318 1547 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8319 : }
8320 1547 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8321 1547 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
8322 1547 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8323 1547 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
8324 1547 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.num_rids));
8325 1547 : if (r->in.num_rids > 1000) {
8326 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->in.num_rids), (uint32_t)(0), (uint32_t)(1000));
8327 : }
8328 1547 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.rids));
8329 1547 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.rids));
8330 1547 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->in.rids, &size_rids_0));
8331 1547 : NDR_CHECK(ndr_get_array_length(ndr, (void*)&r->in.rids, &length_rids_0));
8332 1547 : if (length_rids_0 > size_rids_0) {
8333 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_rids_0, length_rids_0);
8334 : }
8335 1547 : NDR_PULL_ALLOC_N(ndr, r->in.rids, size_rids_0);
8336 1547 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
8337 1547 : NDR_PULL_SET_MEM_CTX(ndr, r->in.rids, 0);
8338 6024 : for (cntr_rids_0 = 0; cntr_rids_0 < (length_rids_0); cntr_rids_0++) {
8339 4477 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.rids[cntr_rids_0]));
8340 : }
8341 1547 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, 0);
8342 1547 : NDR_PULL_ALLOC(ndr, r->out.names);
8343 1547 : NDR_ZERO_STRUCTP(r->out.names);
8344 1547 : NDR_PULL_ALLOC(ndr, r->out.types);
8345 1547 : NDR_ZERO_STRUCTP(r->out.types);
8346 1547 : if (r->in.rids) {
8347 1547 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->in.rids, 1000));
8348 : }
8349 1547 : if (r->in.rids) {
8350 1547 : NDR_CHECK(ndr_check_steal_array_length(ndr, (void*)&r->in.rids, r->in.num_rids));
8351 : }
8352 : }
8353 2610 : if (flags & NDR_OUT) {
8354 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8355 : if (r->in.domain_handle == NULL) {
8356 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8357 : NDR_ZERO_STRUCTP(r->in.domain_handle);
8358 : }
8359 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8360 1063 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8361 40 : NDR_PULL_ALLOC(ndr, r->out.names);
8362 : }
8363 1063 : _mem_save_names_0 = NDR_PULL_GET_MEM_CTX(ndr);
8364 1063 : NDR_PULL_SET_MEM_CTX(ndr, r->out.names, LIBNDR_FLAG_REF_ALLOC);
8365 1063 : NDR_CHECK(ndr_pull_lsa_Strings(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.names));
8366 1063 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_names_0, LIBNDR_FLAG_REF_ALLOC);
8367 1063 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8368 40 : NDR_PULL_ALLOC(ndr, r->out.types);
8369 : }
8370 1063 : _mem_save_types_0 = NDR_PULL_GET_MEM_CTX(ndr);
8371 1063 : NDR_PULL_SET_MEM_CTX(ndr, r->out.types, LIBNDR_FLAG_REF_ALLOC);
8372 1063 : NDR_CHECK(ndr_pull_samr_Ids(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.types));
8373 1063 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_types_0, LIBNDR_FLAG_REF_ALLOC);
8374 1063 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8375 : }
8376 2610 : return NDR_ERR_SUCCESS;
8377 : }
8378 :
8379 60 : _PUBLIC_ void ndr_print_samr_LookupRids(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_LookupRids *r)
8380 : {
8381 0 : uint32_t cntr_rids_0;
8382 60 : ndr_print_struct(ndr, name, "samr_LookupRids");
8383 60 : if (r == NULL) { ndr_print_null(ndr); return; }
8384 60 : ndr->depth++;
8385 60 : if (flags & NDR_SET_VALUES) {
8386 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8387 : }
8388 60 : if (flags & NDR_IN) {
8389 0 : ndr_print_struct(ndr, "in", "samr_LookupRids");
8390 0 : ndr->depth++;
8391 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
8392 0 : ndr->depth++;
8393 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
8394 0 : ndr->depth--;
8395 0 : ndr_print_uint32(ndr, "num_rids", r->in.num_rids);
8396 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "rids", (uint32_t)(r->in.num_rids));
8397 0 : ndr->depth++;
8398 0 : for (cntr_rids_0 = 0; cntr_rids_0 < (r->in.num_rids); cntr_rids_0++) {
8399 0 : ndr_print_uint32(ndr, "rids", r->in.rids[cntr_rids_0]);
8400 : }
8401 0 : ndr->depth--;
8402 0 : ndr->depth--;
8403 : }
8404 60 : if (flags & NDR_OUT) {
8405 60 : ndr_print_struct(ndr, "out", "samr_LookupRids");
8406 60 : ndr->depth++;
8407 60 : ndr_print_ptr(ndr, "names", r->out.names);
8408 60 : ndr->depth++;
8409 60 : ndr_print_lsa_Strings(ndr, "names", r->out.names);
8410 60 : ndr->depth--;
8411 60 : ndr_print_ptr(ndr, "types", r->out.types);
8412 60 : ndr->depth++;
8413 60 : ndr_print_samr_Ids(ndr, "types", r->out.types);
8414 60 : ndr->depth--;
8415 60 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8416 60 : ndr->depth--;
8417 : }
8418 60 : ndr->depth--;
8419 : }
8420 :
8421 1184 : static enum ndr_err_code ndr_push_samr_OpenGroup(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_OpenGroup *r)
8422 : {
8423 1184 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8424 1184 : if (flags & NDR_IN) {
8425 588 : if (r->in.domain_handle == NULL) {
8426 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8427 : }
8428 588 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8429 588 : NDR_CHECK(ndr_push_samr_GroupAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
8430 588 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.rid));
8431 : }
8432 1184 : if (flags & NDR_OUT) {
8433 596 : if (r->out.group_handle == NULL) {
8434 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8435 : }
8436 596 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.group_handle));
8437 596 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8438 : }
8439 1184 : return NDR_ERR_SUCCESS;
8440 : }
8441 :
8442 1162 : static enum ndr_err_code ndr_pull_samr_OpenGroup(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_OpenGroup *r)
8443 : {
8444 1162 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
8445 1162 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
8446 1162 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8447 1162 : if (flags & NDR_IN) {
8448 580 : NDR_ZERO_STRUCT(r->out);
8449 :
8450 580 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8451 580 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8452 : }
8453 580 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8454 580 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
8455 580 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
8456 580 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
8457 580 : NDR_CHECK(ndr_pull_samr_GroupAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
8458 580 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.rid));
8459 580 : NDR_PULL_ALLOC(ndr, r->out.group_handle);
8460 580 : NDR_ZERO_STRUCTP(r->out.group_handle);
8461 : }
8462 1162 : if (flags & NDR_OUT) {
8463 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8464 : if (r->in.domain_handle == NULL) {
8465 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
8466 : NDR_ZERO_STRUCTP(r->in.domain_handle);
8467 : }
8468 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8469 582 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8470 181 : NDR_PULL_ALLOC(ndr, r->out.group_handle);
8471 : }
8472 582 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8473 582 : NDR_PULL_SET_MEM_CTX(ndr, r->out.group_handle, LIBNDR_FLAG_REF_ALLOC);
8474 582 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.group_handle));
8475 582 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8476 582 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8477 : }
8478 1162 : return NDR_ERR_SUCCESS;
8479 : }
8480 :
8481 40 : _PUBLIC_ void ndr_print_samr_OpenGroup(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_OpenGroup *r)
8482 : {
8483 40 : ndr_print_struct(ndr, name, "samr_OpenGroup");
8484 40 : if (r == NULL) { ndr_print_null(ndr); return; }
8485 40 : ndr->depth++;
8486 40 : if (flags & NDR_SET_VALUES) {
8487 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8488 : }
8489 40 : if (flags & NDR_IN) {
8490 0 : ndr_print_struct(ndr, "in", "samr_OpenGroup");
8491 0 : ndr->depth++;
8492 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
8493 0 : ndr->depth++;
8494 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
8495 0 : ndr->depth--;
8496 0 : ndr_print_samr_GroupAccessMask(ndr, "access_mask", r->in.access_mask);
8497 0 : ndr_print_uint32(ndr, "rid", r->in.rid);
8498 0 : ndr->depth--;
8499 : }
8500 40 : if (flags & NDR_OUT) {
8501 40 : ndr_print_struct(ndr, "out", "samr_OpenGroup");
8502 40 : ndr->depth++;
8503 40 : ndr_print_ptr(ndr, "group_handle", r->out.group_handle);
8504 40 : ndr->depth++;
8505 40 : ndr_print_policy_handle(ndr, "group_handle", r->out.group_handle);
8506 40 : ndr->depth--;
8507 40 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8508 40 : ndr->depth--;
8509 : }
8510 40 : ndr->depth--;
8511 : }
8512 :
8513 497 : static enum ndr_err_code ndr_push_samr_QueryGroupInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryGroupInfo *r)
8514 : {
8515 497 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8516 497 : if (flags & NDR_IN) {
8517 266 : if (r->in.group_handle == NULL) {
8518 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8519 : }
8520 266 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8521 266 : NDR_CHECK(ndr_push_samr_GroupInfoEnum(ndr, NDR_SCALARS, r->in.level));
8522 : }
8523 497 : if (flags & NDR_OUT) {
8524 231 : if (r->out.info == NULL) {
8525 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8526 : }
8527 231 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
8528 231 : if (*r->out.info) {
8529 231 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
8530 231 : NDR_CHECK(ndr_push_samr_GroupInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
8531 : }
8532 231 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8533 : }
8534 497 : return NDR_ERR_SUCCESS;
8535 : }
8536 :
8537 494 : static enum ndr_err_code ndr_pull_samr_QueryGroupInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryGroupInfo *r)
8538 : {
8539 0 : uint32_t _ptr_info;
8540 494 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
8541 494 : TALLOC_CTX *_mem_save_info_0 = NULL;
8542 494 : TALLOC_CTX *_mem_save_info_1 = NULL;
8543 494 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8544 494 : if (flags & NDR_IN) {
8545 228 : NDR_ZERO_STRUCT(r->out);
8546 :
8547 228 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8548 228 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8549 : }
8550 228 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8551 228 : NDR_PULL_SET_MEM_CTX(ndr, r->in.group_handle, LIBNDR_FLAG_REF_ALLOC);
8552 228 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8553 228 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8554 228 : NDR_CHECK(ndr_pull_samr_GroupInfoEnum(ndr, NDR_SCALARS, &r->in.level));
8555 228 : NDR_PULL_ALLOC(ndr, r->out.info);
8556 228 : NDR_ZERO_STRUCTP(r->out.info);
8557 : }
8558 494 : if (flags & NDR_OUT) {
8559 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8560 : if (r->in.group_handle == NULL) {
8561 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8562 : NDR_ZERO_STRUCTP(r->in.group_handle);
8563 : }
8564 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8565 266 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8566 13 : NDR_PULL_ALLOC(ndr, r->out.info);
8567 : }
8568 266 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
8569 266 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
8570 266 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
8571 266 : if (_ptr_info) {
8572 266 : NDR_PULL_ALLOC(ndr, *r->out.info);
8573 : } else {
8574 0 : *r->out.info = NULL;
8575 : }
8576 266 : if (*r->out.info) {
8577 266 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
8578 266 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
8579 266 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
8580 266 : NDR_CHECK(ndr_pull_samr_GroupInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
8581 266 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
8582 : }
8583 266 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
8584 266 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8585 : }
8586 494 : return NDR_ERR_SUCCESS;
8587 : }
8588 :
8589 6 : _PUBLIC_ void ndr_print_samr_QueryGroupInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryGroupInfo *r)
8590 : {
8591 6 : ndr_print_struct(ndr, name, "samr_QueryGroupInfo");
8592 6 : if (r == NULL) { ndr_print_null(ndr); return; }
8593 6 : ndr->depth++;
8594 6 : if (flags & NDR_SET_VALUES) {
8595 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8596 : }
8597 6 : if (flags & NDR_IN) {
8598 0 : ndr_print_struct(ndr, "in", "samr_QueryGroupInfo");
8599 0 : ndr->depth++;
8600 0 : ndr_print_ptr(ndr, "group_handle", r->in.group_handle);
8601 0 : ndr->depth++;
8602 0 : ndr_print_policy_handle(ndr, "group_handle", r->in.group_handle);
8603 0 : ndr->depth--;
8604 0 : ndr_print_samr_GroupInfoEnum(ndr, "level", r->in.level);
8605 0 : ndr->depth--;
8606 : }
8607 6 : if (flags & NDR_OUT) {
8608 6 : ndr_print_struct(ndr, "out", "samr_QueryGroupInfo");
8609 6 : ndr->depth++;
8610 6 : ndr_print_ptr(ndr, "info", r->out.info);
8611 6 : ndr->depth++;
8612 6 : ndr_print_ptr(ndr, "info", *r->out.info);
8613 6 : ndr->depth++;
8614 6 : if (*r->out.info) {
8615 6 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
8616 6 : ndr_print_samr_GroupInfo(ndr, "info", *r->out.info);
8617 : }
8618 6 : ndr->depth--;
8619 6 : ndr->depth--;
8620 6 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8621 6 : ndr->depth--;
8622 : }
8623 6 : ndr->depth--;
8624 : }
8625 :
8626 34 : static enum ndr_err_code ndr_push_samr_SetGroupInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetGroupInfo *r)
8627 : {
8628 34 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8629 34 : if (flags & NDR_IN) {
8630 21 : if (r->in.group_handle == NULL) {
8631 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8632 : }
8633 21 : if (r->in.info == NULL) {
8634 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8635 : }
8636 21 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8637 21 : NDR_CHECK(ndr_push_samr_GroupInfoEnum(ndr, NDR_SCALARS, r->in.level));
8638 21 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
8639 21 : NDR_CHECK(ndr_push_samr_GroupInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
8640 : }
8641 34 : if (flags & NDR_OUT) {
8642 13 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8643 : }
8644 34 : return NDR_ERR_SUCCESS;
8645 : }
8646 :
8647 34 : static enum ndr_err_code ndr_pull_samr_SetGroupInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetGroupInfo *r)
8648 : {
8649 34 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
8650 34 : TALLOC_CTX *_mem_save_info_0 = NULL;
8651 34 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8652 34 : if (flags & NDR_IN) {
8653 13 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8654 13 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8655 : }
8656 13 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8657 13 : NDR_PULL_SET_MEM_CTX(ndr, r->in.group_handle, LIBNDR_FLAG_REF_ALLOC);
8658 13 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8659 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8660 13 : NDR_CHECK(ndr_pull_samr_GroupInfoEnum(ndr, NDR_SCALARS, &r->in.level));
8661 13 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8662 13 : NDR_PULL_ALLOC(ndr, r->in.info);
8663 : }
8664 13 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
8665 13 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
8666 13 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
8667 13 : NDR_CHECK(ndr_pull_samr_GroupInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
8668 13 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
8669 : }
8670 34 : if (flags & NDR_OUT) {
8671 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8672 : if (r->in.group_handle == NULL) {
8673 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8674 : NDR_ZERO_STRUCTP(r->in.group_handle);
8675 : }
8676 : if (r->in.info == NULL) {
8677 : NDR_PULL_ALLOC(ndr, r->in.info);
8678 : NDR_ZERO_STRUCTP(r->in.info);
8679 : }
8680 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8681 21 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8682 : }
8683 34 : return NDR_ERR_SUCCESS;
8684 : }
8685 :
8686 0 : _PUBLIC_ void ndr_print_samr_SetGroupInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetGroupInfo *r)
8687 : {
8688 0 : ndr_print_struct(ndr, name, "samr_SetGroupInfo");
8689 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8690 0 : ndr->depth++;
8691 0 : if (flags & NDR_SET_VALUES) {
8692 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8693 : }
8694 0 : if (flags & NDR_IN) {
8695 0 : ndr_print_struct(ndr, "in", "samr_SetGroupInfo");
8696 0 : ndr->depth++;
8697 0 : ndr_print_ptr(ndr, "group_handle", r->in.group_handle);
8698 0 : ndr->depth++;
8699 0 : ndr_print_policy_handle(ndr, "group_handle", r->in.group_handle);
8700 0 : ndr->depth--;
8701 0 : ndr_print_samr_GroupInfoEnum(ndr, "level", r->in.level);
8702 0 : ndr_print_ptr(ndr, "info", r->in.info);
8703 0 : ndr->depth++;
8704 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
8705 0 : ndr_print_samr_GroupInfo(ndr, "info", r->in.info);
8706 0 : ndr->depth--;
8707 0 : ndr->depth--;
8708 : }
8709 0 : if (flags & NDR_OUT) {
8710 0 : ndr_print_struct(ndr, "out", "samr_SetGroupInfo");
8711 0 : ndr->depth++;
8712 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8713 0 : ndr->depth--;
8714 : }
8715 0 : ndr->depth--;
8716 : }
8717 :
8718 168 : static enum ndr_err_code ndr_push_samr_AddGroupMember(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_AddGroupMember *r)
8719 : {
8720 168 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8721 168 : if (flags & NDR_IN) {
8722 87 : if (r->in.group_handle == NULL) {
8723 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8724 : }
8725 87 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8726 87 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.rid));
8727 87 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.flags));
8728 : }
8729 168 : if (flags & NDR_OUT) {
8730 81 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8731 : }
8732 168 : return NDR_ERR_SUCCESS;
8733 : }
8734 :
8735 168 : static enum ndr_err_code ndr_pull_samr_AddGroupMember(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_AddGroupMember *r)
8736 : {
8737 168 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
8738 168 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8739 168 : if (flags & NDR_IN) {
8740 81 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8741 81 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8742 : }
8743 81 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8744 81 : NDR_PULL_SET_MEM_CTX(ndr, r->in.group_handle, LIBNDR_FLAG_REF_ALLOC);
8745 81 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8746 81 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8747 81 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.rid));
8748 81 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.flags));
8749 : }
8750 168 : if (flags & NDR_OUT) {
8751 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8752 : if (r->in.group_handle == NULL) {
8753 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8754 : NDR_ZERO_STRUCTP(r->in.group_handle);
8755 : }
8756 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8757 87 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8758 : }
8759 168 : return NDR_ERR_SUCCESS;
8760 : }
8761 :
8762 0 : _PUBLIC_ void ndr_print_samr_AddGroupMember(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_AddGroupMember *r)
8763 : {
8764 0 : ndr_print_struct(ndr, name, "samr_AddGroupMember");
8765 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8766 0 : ndr->depth++;
8767 0 : if (flags & NDR_SET_VALUES) {
8768 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8769 : }
8770 0 : if (flags & NDR_IN) {
8771 0 : ndr_print_struct(ndr, "in", "samr_AddGroupMember");
8772 0 : ndr->depth++;
8773 0 : ndr_print_ptr(ndr, "group_handle", r->in.group_handle);
8774 0 : ndr->depth++;
8775 0 : ndr_print_policy_handle(ndr, "group_handle", r->in.group_handle);
8776 0 : ndr->depth--;
8777 0 : ndr_print_uint32(ndr, "rid", r->in.rid);
8778 0 : ndr_print_uint32(ndr, "flags", r->in.flags);
8779 0 : ndr->depth--;
8780 : }
8781 0 : if (flags & NDR_OUT) {
8782 0 : ndr_print_struct(ndr, "out", "samr_AddGroupMember");
8783 0 : ndr->depth++;
8784 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8785 0 : ndr->depth--;
8786 : }
8787 0 : ndr->depth--;
8788 : }
8789 :
8790 1067 : static enum ndr_err_code ndr_push_samr_DeleteDomainGroup(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_DeleteDomainGroup *r)
8791 : {
8792 1067 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8793 1067 : if (flags & NDR_IN) {
8794 533 : if (r->in.group_handle == NULL) {
8795 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8796 : }
8797 533 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8798 : }
8799 1067 : if (flags & NDR_OUT) {
8800 534 : if (r->out.group_handle == NULL) {
8801 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8802 : }
8803 534 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.group_handle));
8804 534 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8805 : }
8806 1067 : return NDR_ERR_SUCCESS;
8807 : }
8808 :
8809 1064 : static enum ndr_err_code ndr_pull_samr_DeleteDomainGroup(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_DeleteDomainGroup *r)
8810 : {
8811 1064 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
8812 1064 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8813 1064 : if (flags & NDR_IN) {
8814 531 : NDR_ZERO_STRUCT(r->out);
8815 :
8816 531 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8817 531 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8818 : }
8819 531 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8820 531 : NDR_PULL_SET_MEM_CTX(ndr, r->in.group_handle, LIBNDR_FLAG_REF_ALLOC);
8821 531 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8822 531 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8823 531 : NDR_PULL_ALLOC(ndr, r->out.group_handle);
8824 531 : *r->out.group_handle = *r->in.group_handle;
8825 : }
8826 1064 : if (flags & NDR_OUT) {
8827 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8828 : if (r->in.group_handle == NULL) {
8829 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8830 : NDR_ZERO_STRUCTP(r->in.group_handle);
8831 : }
8832 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8833 533 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8834 74 : NDR_PULL_ALLOC(ndr, r->out.group_handle);
8835 : }
8836 533 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8837 533 : NDR_PULL_SET_MEM_CTX(ndr, r->out.group_handle, LIBNDR_FLAG_REF_ALLOC);
8838 533 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.group_handle));
8839 533 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8840 533 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8841 : }
8842 1064 : return NDR_ERR_SUCCESS;
8843 : }
8844 :
8845 6 : _PUBLIC_ void ndr_print_samr_DeleteDomainGroup(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_DeleteDomainGroup *r)
8846 : {
8847 6 : ndr_print_struct(ndr, name, "samr_DeleteDomainGroup");
8848 6 : if (r == NULL) { ndr_print_null(ndr); return; }
8849 6 : ndr->depth++;
8850 6 : if (flags & NDR_SET_VALUES) {
8851 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8852 : }
8853 6 : if (flags & NDR_IN) {
8854 0 : ndr_print_struct(ndr, "in", "samr_DeleteDomainGroup");
8855 0 : ndr->depth++;
8856 0 : ndr_print_ptr(ndr, "group_handle", r->in.group_handle);
8857 0 : ndr->depth++;
8858 0 : ndr_print_policy_handle(ndr, "group_handle", r->in.group_handle);
8859 0 : ndr->depth--;
8860 0 : ndr->depth--;
8861 : }
8862 6 : if (flags & NDR_OUT) {
8863 6 : ndr_print_struct(ndr, "out", "samr_DeleteDomainGroup");
8864 6 : ndr->depth++;
8865 6 : ndr_print_ptr(ndr, "group_handle", r->out.group_handle);
8866 6 : ndr->depth++;
8867 6 : ndr_print_policy_handle(ndr, "group_handle", r->out.group_handle);
8868 6 : ndr->depth--;
8869 6 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8870 6 : ndr->depth--;
8871 : }
8872 6 : ndr->depth--;
8873 : }
8874 :
8875 158 : static enum ndr_err_code ndr_push_samr_DeleteGroupMember(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_DeleteGroupMember *r)
8876 : {
8877 158 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8878 158 : if (flags & NDR_IN) {
8879 81 : if (r->in.group_handle == NULL) {
8880 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8881 : }
8882 81 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8883 81 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.rid));
8884 : }
8885 158 : if (flags & NDR_OUT) {
8886 77 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8887 : }
8888 158 : return NDR_ERR_SUCCESS;
8889 : }
8890 :
8891 158 : static enum ndr_err_code ndr_pull_samr_DeleteGroupMember(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_DeleteGroupMember *r)
8892 : {
8893 158 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
8894 158 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8895 158 : if (flags & NDR_IN) {
8896 77 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8897 77 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8898 : }
8899 77 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8900 77 : NDR_PULL_SET_MEM_CTX(ndr, r->in.group_handle, LIBNDR_FLAG_REF_ALLOC);
8901 77 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8902 77 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8903 77 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.rid));
8904 : }
8905 158 : if (flags & NDR_OUT) {
8906 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8907 : if (r->in.group_handle == NULL) {
8908 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8909 : NDR_ZERO_STRUCTP(r->in.group_handle);
8910 : }
8911 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8912 81 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
8913 : }
8914 158 : return NDR_ERR_SUCCESS;
8915 : }
8916 :
8917 0 : _PUBLIC_ void ndr_print_samr_DeleteGroupMember(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_DeleteGroupMember *r)
8918 : {
8919 0 : ndr_print_struct(ndr, name, "samr_DeleteGroupMember");
8920 0 : if (r == NULL) { ndr_print_null(ndr); return; }
8921 0 : ndr->depth++;
8922 0 : if (flags & NDR_SET_VALUES) {
8923 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
8924 : }
8925 0 : if (flags & NDR_IN) {
8926 0 : ndr_print_struct(ndr, "in", "samr_DeleteGroupMember");
8927 0 : ndr->depth++;
8928 0 : ndr_print_ptr(ndr, "group_handle", r->in.group_handle);
8929 0 : ndr->depth++;
8930 0 : ndr_print_policy_handle(ndr, "group_handle", r->in.group_handle);
8931 0 : ndr->depth--;
8932 0 : ndr_print_uint32(ndr, "rid", r->in.rid);
8933 0 : ndr->depth--;
8934 : }
8935 0 : if (flags & NDR_OUT) {
8936 0 : ndr_print_struct(ndr, "out", "samr_DeleteGroupMember");
8937 0 : ndr->depth++;
8938 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
8939 0 : ndr->depth--;
8940 : }
8941 0 : ndr->depth--;
8942 : }
8943 :
8944 987 : static enum ndr_err_code ndr_push_samr_QueryGroupMember(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryGroupMember *r)
8945 : {
8946 987 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
8947 987 : if (flags & NDR_IN) {
8948 491 : if (r->in.group_handle == NULL) {
8949 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8950 : }
8951 491 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8952 : }
8953 987 : if (flags & NDR_OUT) {
8954 496 : if (r->out.rids == NULL) {
8955 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
8956 : }
8957 496 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.rids));
8958 496 : if (*r->out.rids) {
8959 496 : NDR_CHECK(ndr_push_samr_RidAttrArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.rids));
8960 : }
8961 496 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
8962 : }
8963 987 : return NDR_ERR_SUCCESS;
8964 : }
8965 :
8966 974 : static enum ndr_err_code ndr_pull_samr_QueryGroupMember(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryGroupMember *r)
8967 : {
8968 0 : uint32_t _ptr_rids;
8969 974 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
8970 974 : TALLOC_CTX *_mem_save_rids_0 = NULL;
8971 974 : TALLOC_CTX *_mem_save_rids_1 = NULL;
8972 974 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
8973 974 : if (flags & NDR_IN) {
8974 483 : NDR_ZERO_STRUCT(r->out);
8975 :
8976 483 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8977 483 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8978 : }
8979 483 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
8980 483 : NDR_PULL_SET_MEM_CTX(ndr, r->in.group_handle, LIBNDR_FLAG_REF_ALLOC);
8981 483 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
8982 483 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
8983 483 : NDR_PULL_ALLOC(ndr, r->out.rids);
8984 483 : NDR_ZERO_STRUCTP(r->out.rids);
8985 : }
8986 974 : if (flags & NDR_OUT) {
8987 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
8988 : if (r->in.group_handle == NULL) {
8989 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
8990 : NDR_ZERO_STRUCTP(r->in.group_handle);
8991 : }
8992 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
8993 491 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
8994 92 : NDR_PULL_ALLOC(ndr, r->out.rids);
8995 : }
8996 491 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
8997 491 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rids, LIBNDR_FLAG_REF_ALLOC);
8998 491 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_rids));
8999 491 : if (_ptr_rids) {
9000 491 : NDR_PULL_ALLOC(ndr, *r->out.rids);
9001 : } else {
9002 0 : *r->out.rids = NULL;
9003 : }
9004 491 : if (*r->out.rids) {
9005 491 : _mem_save_rids_1 = NDR_PULL_GET_MEM_CTX(ndr);
9006 491 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.rids, 0);
9007 491 : NDR_CHECK(ndr_pull_samr_RidAttrArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.rids));
9008 491 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_1, 0);
9009 : }
9010 491 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, LIBNDR_FLAG_REF_ALLOC);
9011 491 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9012 : }
9013 974 : return NDR_ERR_SUCCESS;
9014 : }
9015 :
9016 26 : _PUBLIC_ void ndr_print_samr_QueryGroupMember(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryGroupMember *r)
9017 : {
9018 26 : ndr_print_struct(ndr, name, "samr_QueryGroupMember");
9019 26 : if (r == NULL) { ndr_print_null(ndr); return; }
9020 26 : ndr->depth++;
9021 26 : if (flags & NDR_SET_VALUES) {
9022 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9023 : }
9024 26 : if (flags & NDR_IN) {
9025 0 : ndr_print_struct(ndr, "in", "samr_QueryGroupMember");
9026 0 : ndr->depth++;
9027 0 : ndr_print_ptr(ndr, "group_handle", r->in.group_handle);
9028 0 : ndr->depth++;
9029 0 : ndr_print_policy_handle(ndr, "group_handle", r->in.group_handle);
9030 0 : ndr->depth--;
9031 0 : ndr->depth--;
9032 : }
9033 26 : if (flags & NDR_OUT) {
9034 26 : ndr_print_struct(ndr, "out", "samr_QueryGroupMember");
9035 26 : ndr->depth++;
9036 26 : ndr_print_ptr(ndr, "rids", r->out.rids);
9037 26 : ndr->depth++;
9038 26 : ndr_print_ptr(ndr, "rids", *r->out.rids);
9039 26 : ndr->depth++;
9040 26 : if (*r->out.rids) {
9041 26 : ndr_print_samr_RidAttrArray(ndr, "rids", *r->out.rids);
9042 : }
9043 26 : ndr->depth--;
9044 26 : ndr->depth--;
9045 26 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9046 26 : ndr->depth--;
9047 : }
9048 26 : ndr->depth--;
9049 : }
9050 :
9051 0 : static enum ndr_err_code ndr_push_samr_SetMemberAttributesOfGroup(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetMemberAttributesOfGroup *r)
9052 : {
9053 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9054 0 : if (flags & NDR_IN) {
9055 0 : if (r->in.group_handle == NULL) {
9056 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9057 : }
9058 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
9059 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown1));
9060 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
9061 : }
9062 0 : if (flags & NDR_OUT) {
9063 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9064 : }
9065 0 : return NDR_ERR_SUCCESS;
9066 : }
9067 :
9068 0 : static enum ndr_err_code ndr_pull_samr_SetMemberAttributesOfGroup(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetMemberAttributesOfGroup *r)
9069 : {
9070 0 : TALLOC_CTX *_mem_save_group_handle_0 = NULL;
9071 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9072 0 : if (flags & NDR_IN) {
9073 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9074 0 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
9075 : }
9076 0 : _mem_save_group_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9077 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.group_handle, LIBNDR_FLAG_REF_ALLOC);
9078 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.group_handle));
9079 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_handle_0, LIBNDR_FLAG_REF_ALLOC);
9080 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
9081 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
9082 : }
9083 0 : if (flags & NDR_OUT) {
9084 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9085 : if (r->in.group_handle == NULL) {
9086 : NDR_PULL_ALLOC(ndr, r->in.group_handle);
9087 : NDR_ZERO_STRUCTP(r->in.group_handle);
9088 : }
9089 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9090 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9091 : }
9092 0 : return NDR_ERR_SUCCESS;
9093 : }
9094 :
9095 0 : _PUBLIC_ void ndr_print_samr_SetMemberAttributesOfGroup(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetMemberAttributesOfGroup *r)
9096 : {
9097 0 : ndr_print_struct(ndr, name, "samr_SetMemberAttributesOfGroup");
9098 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9099 0 : ndr->depth++;
9100 0 : if (flags & NDR_SET_VALUES) {
9101 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9102 : }
9103 0 : if (flags & NDR_IN) {
9104 0 : ndr_print_struct(ndr, "in", "samr_SetMemberAttributesOfGroup");
9105 0 : ndr->depth++;
9106 0 : ndr_print_ptr(ndr, "group_handle", r->in.group_handle);
9107 0 : ndr->depth++;
9108 0 : ndr_print_policy_handle(ndr, "group_handle", r->in.group_handle);
9109 0 : ndr->depth--;
9110 0 : ndr_print_uint32(ndr, "unknown1", r->in.unknown1);
9111 0 : ndr_print_uint32(ndr, "unknown2", r->in.unknown2);
9112 0 : ndr->depth--;
9113 : }
9114 0 : if (flags & NDR_OUT) {
9115 0 : ndr_print_struct(ndr, "out", "samr_SetMemberAttributesOfGroup");
9116 0 : ndr->depth++;
9117 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9118 0 : ndr->depth--;
9119 : }
9120 0 : ndr->depth--;
9121 : }
9122 :
9123 1392 : static enum ndr_err_code ndr_push_samr_OpenAlias(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_OpenAlias *r)
9124 : {
9125 1392 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9126 1392 : if (flags & NDR_IN) {
9127 1311 : if (r->in.domain_handle == NULL) {
9128 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9129 : }
9130 1311 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
9131 1311 : NDR_CHECK(ndr_push_samr_AliasAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
9132 1311 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.rid));
9133 : }
9134 1392 : if (flags & NDR_OUT) {
9135 81 : if (r->out.alias_handle == NULL) {
9136 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9137 : }
9138 81 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.alias_handle));
9139 81 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9140 : }
9141 1392 : return NDR_ERR_SUCCESS;
9142 : }
9143 :
9144 1392 : static enum ndr_err_code ndr_pull_samr_OpenAlias(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_OpenAlias *r)
9145 : {
9146 1392 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
9147 1392 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
9148 1392 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9149 1392 : if (flags & NDR_IN) {
9150 81 : NDR_ZERO_STRUCT(r->out);
9151 :
9152 81 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9153 81 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
9154 : }
9155 81 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9156 81 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
9157 81 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
9158 81 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
9159 81 : NDR_CHECK(ndr_pull_samr_AliasAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
9160 81 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.rid));
9161 81 : NDR_PULL_ALLOC(ndr, r->out.alias_handle);
9162 81 : NDR_ZERO_STRUCTP(r->out.alias_handle);
9163 : }
9164 1392 : if (flags & NDR_OUT) {
9165 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9166 : if (r->in.domain_handle == NULL) {
9167 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
9168 : NDR_ZERO_STRUCTP(r->in.domain_handle);
9169 : }
9170 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9171 1311 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9172 1224 : NDR_PULL_ALLOC(ndr, r->out.alias_handle);
9173 : }
9174 1311 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9175 1311 : NDR_PULL_SET_MEM_CTX(ndr, r->out.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9176 1311 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.alias_handle));
9177 1311 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9178 1311 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9179 : }
9180 1392 : return NDR_ERR_SUCCESS;
9181 : }
9182 :
9183 0 : _PUBLIC_ void ndr_print_samr_OpenAlias(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_OpenAlias *r)
9184 : {
9185 0 : ndr_print_struct(ndr, name, "samr_OpenAlias");
9186 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9187 0 : ndr->depth++;
9188 0 : if (flags & NDR_SET_VALUES) {
9189 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9190 : }
9191 0 : if (flags & NDR_IN) {
9192 0 : ndr_print_struct(ndr, "in", "samr_OpenAlias");
9193 0 : ndr->depth++;
9194 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
9195 0 : ndr->depth++;
9196 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
9197 0 : ndr->depth--;
9198 0 : ndr_print_samr_AliasAccessMask(ndr, "access_mask", r->in.access_mask);
9199 0 : ndr_print_uint32(ndr, "rid", r->in.rid);
9200 0 : ndr->depth--;
9201 : }
9202 0 : if (flags & NDR_OUT) {
9203 0 : ndr_print_struct(ndr, "out", "samr_OpenAlias");
9204 0 : ndr->depth++;
9205 0 : ndr_print_ptr(ndr, "alias_handle", r->out.alias_handle);
9206 0 : ndr->depth++;
9207 0 : ndr_print_policy_handle(ndr, "alias_handle", r->out.alias_handle);
9208 0 : ndr->depth--;
9209 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9210 0 : ndr->depth--;
9211 : }
9212 0 : ndr->depth--;
9213 : }
9214 :
9215 538 : static enum ndr_err_code ndr_push_samr_QueryAliasInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryAliasInfo *r)
9216 : {
9217 538 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9218 538 : if (flags & NDR_IN) {
9219 286 : if (r->in.alias_handle == NULL) {
9220 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9221 : }
9222 286 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9223 286 : NDR_CHECK(ndr_push_samr_AliasInfoEnum(ndr, NDR_SCALARS, r->in.level));
9224 : }
9225 538 : if (flags & NDR_OUT) {
9226 252 : if (r->out.info == NULL) {
9227 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9228 : }
9229 252 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
9230 252 : if (*r->out.info) {
9231 252 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
9232 252 : NDR_CHECK(ndr_push_samr_AliasInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
9233 : }
9234 252 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9235 : }
9236 538 : return NDR_ERR_SUCCESS;
9237 : }
9238 :
9239 538 : static enum ndr_err_code ndr_pull_samr_QueryAliasInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryAliasInfo *r)
9240 : {
9241 0 : uint32_t _ptr_info;
9242 538 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
9243 538 : TALLOC_CTX *_mem_save_info_0 = NULL;
9244 538 : TALLOC_CTX *_mem_save_info_1 = NULL;
9245 538 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9246 538 : if (flags & NDR_IN) {
9247 252 : NDR_ZERO_STRUCT(r->out);
9248 :
9249 252 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9250 252 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9251 : }
9252 252 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9253 252 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9254 252 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9255 252 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9256 252 : NDR_CHECK(ndr_pull_samr_AliasInfoEnum(ndr, NDR_SCALARS, &r->in.level));
9257 252 : NDR_PULL_ALLOC(ndr, r->out.info);
9258 252 : NDR_ZERO_STRUCTP(r->out.info);
9259 : }
9260 538 : if (flags & NDR_OUT) {
9261 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9262 : if (r->in.alias_handle == NULL) {
9263 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9264 : NDR_ZERO_STRUCTP(r->in.alias_handle);
9265 : }
9266 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9267 286 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9268 0 : NDR_PULL_ALLOC(ndr, r->out.info);
9269 : }
9270 286 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
9271 286 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
9272 286 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
9273 286 : if (_ptr_info) {
9274 286 : NDR_PULL_ALLOC(ndr, *r->out.info);
9275 : } else {
9276 0 : *r->out.info = NULL;
9277 : }
9278 286 : if (*r->out.info) {
9279 286 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
9280 286 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
9281 286 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
9282 286 : NDR_CHECK(ndr_pull_samr_AliasInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
9283 286 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
9284 : }
9285 286 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
9286 286 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9287 : }
9288 538 : return NDR_ERR_SUCCESS;
9289 : }
9290 :
9291 0 : _PUBLIC_ void ndr_print_samr_QueryAliasInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryAliasInfo *r)
9292 : {
9293 0 : ndr_print_struct(ndr, name, "samr_QueryAliasInfo");
9294 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9295 0 : ndr->depth++;
9296 0 : if (flags & NDR_SET_VALUES) {
9297 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9298 : }
9299 0 : if (flags & NDR_IN) {
9300 0 : ndr_print_struct(ndr, "in", "samr_QueryAliasInfo");
9301 0 : ndr->depth++;
9302 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
9303 0 : ndr->depth++;
9304 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
9305 0 : ndr->depth--;
9306 0 : ndr_print_samr_AliasInfoEnum(ndr, "level", r->in.level);
9307 0 : ndr->depth--;
9308 : }
9309 0 : if (flags & NDR_OUT) {
9310 0 : ndr_print_struct(ndr, "out", "samr_QueryAliasInfo");
9311 0 : ndr->depth++;
9312 0 : ndr_print_ptr(ndr, "info", r->out.info);
9313 0 : ndr->depth++;
9314 0 : ndr_print_ptr(ndr, "info", *r->out.info);
9315 0 : ndr->depth++;
9316 0 : if (*r->out.info) {
9317 0 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
9318 0 : ndr_print_samr_AliasInfo(ndr, "info", *r->out.info);
9319 : }
9320 0 : ndr->depth--;
9321 0 : ndr->depth--;
9322 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9323 0 : ndr->depth--;
9324 : }
9325 0 : ndr->depth--;
9326 : }
9327 :
9328 16 : static enum ndr_err_code ndr_push_samr_SetAliasInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetAliasInfo *r)
9329 : {
9330 16 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9331 16 : if (flags & NDR_IN) {
9332 10 : if (r->in.alias_handle == NULL) {
9333 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9334 : }
9335 10 : if (r->in.info == NULL) {
9336 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9337 : }
9338 10 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9339 10 : NDR_CHECK(ndr_push_samr_AliasInfoEnum(ndr, NDR_SCALARS, r->in.level));
9340 10 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
9341 10 : NDR_CHECK(ndr_push_samr_AliasInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
9342 : }
9343 16 : if (flags & NDR_OUT) {
9344 6 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9345 : }
9346 16 : return NDR_ERR_SUCCESS;
9347 : }
9348 :
9349 16 : static enum ndr_err_code ndr_pull_samr_SetAliasInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetAliasInfo *r)
9350 : {
9351 16 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
9352 16 : TALLOC_CTX *_mem_save_info_0 = NULL;
9353 16 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9354 16 : if (flags & NDR_IN) {
9355 6 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9356 6 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9357 : }
9358 6 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9359 6 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9360 6 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9361 6 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9362 6 : NDR_CHECK(ndr_pull_samr_AliasInfoEnum(ndr, NDR_SCALARS, &r->in.level));
9363 6 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9364 6 : NDR_PULL_ALLOC(ndr, r->in.info);
9365 : }
9366 6 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
9367 6 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
9368 6 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
9369 6 : NDR_CHECK(ndr_pull_samr_AliasInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
9370 6 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
9371 : }
9372 16 : if (flags & NDR_OUT) {
9373 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9374 : if (r->in.alias_handle == NULL) {
9375 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9376 : NDR_ZERO_STRUCTP(r->in.alias_handle);
9377 : }
9378 : if (r->in.info == NULL) {
9379 : NDR_PULL_ALLOC(ndr, r->in.info);
9380 : NDR_ZERO_STRUCTP(r->in.info);
9381 : }
9382 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9383 10 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9384 : }
9385 16 : return NDR_ERR_SUCCESS;
9386 : }
9387 :
9388 0 : _PUBLIC_ void ndr_print_samr_SetAliasInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetAliasInfo *r)
9389 : {
9390 0 : ndr_print_struct(ndr, name, "samr_SetAliasInfo");
9391 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9392 0 : ndr->depth++;
9393 0 : if (flags & NDR_SET_VALUES) {
9394 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9395 : }
9396 0 : if (flags & NDR_IN) {
9397 0 : ndr_print_struct(ndr, "in", "samr_SetAliasInfo");
9398 0 : ndr->depth++;
9399 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
9400 0 : ndr->depth++;
9401 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
9402 0 : ndr->depth--;
9403 0 : ndr_print_samr_AliasInfoEnum(ndr, "level", r->in.level);
9404 0 : ndr_print_ptr(ndr, "info", r->in.info);
9405 0 : ndr->depth++;
9406 0 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
9407 0 : ndr_print_samr_AliasInfo(ndr, "info", r->in.info);
9408 0 : ndr->depth--;
9409 0 : ndr->depth--;
9410 : }
9411 0 : if (flags & NDR_OUT) {
9412 0 : ndr_print_struct(ndr, "out", "samr_SetAliasInfo");
9413 0 : ndr->depth++;
9414 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9415 0 : ndr->depth--;
9416 : }
9417 0 : ndr->depth--;
9418 : }
9419 :
9420 908 : static enum ndr_err_code ndr_push_samr_DeleteDomAlias(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_DeleteDomAlias *r)
9421 : {
9422 908 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9423 908 : if (flags & NDR_IN) {
9424 455 : if (r->in.alias_handle == NULL) {
9425 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9426 : }
9427 455 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9428 : }
9429 908 : if (flags & NDR_OUT) {
9430 453 : if (r->out.alias_handle == NULL) {
9431 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9432 : }
9433 453 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.alias_handle));
9434 453 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9435 : }
9436 908 : return NDR_ERR_SUCCESS;
9437 : }
9438 :
9439 908 : static enum ndr_err_code ndr_pull_samr_DeleteDomAlias(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_DeleteDomAlias *r)
9440 : {
9441 908 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
9442 908 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9443 908 : if (flags & NDR_IN) {
9444 453 : NDR_ZERO_STRUCT(r->out);
9445 :
9446 453 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9447 453 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9448 : }
9449 453 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9450 453 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9451 453 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9452 453 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9453 453 : NDR_PULL_ALLOC(ndr, r->out.alias_handle);
9454 453 : *r->out.alias_handle = *r->in.alias_handle;
9455 : }
9456 908 : if (flags & NDR_OUT) {
9457 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9458 : if (r->in.alias_handle == NULL) {
9459 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9460 : NDR_ZERO_STRUCTP(r->in.alias_handle);
9461 : }
9462 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9463 455 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9464 0 : NDR_PULL_ALLOC(ndr, r->out.alias_handle);
9465 : }
9466 455 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9467 455 : NDR_PULL_SET_MEM_CTX(ndr, r->out.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9468 455 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.alias_handle));
9469 455 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9470 455 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9471 : }
9472 908 : return NDR_ERR_SUCCESS;
9473 : }
9474 :
9475 0 : _PUBLIC_ void ndr_print_samr_DeleteDomAlias(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_DeleteDomAlias *r)
9476 : {
9477 0 : ndr_print_struct(ndr, name, "samr_DeleteDomAlias");
9478 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9479 0 : ndr->depth++;
9480 0 : if (flags & NDR_SET_VALUES) {
9481 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9482 : }
9483 0 : if (flags & NDR_IN) {
9484 0 : ndr_print_struct(ndr, "in", "samr_DeleteDomAlias");
9485 0 : ndr->depth++;
9486 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
9487 0 : ndr->depth++;
9488 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
9489 0 : ndr->depth--;
9490 0 : ndr->depth--;
9491 : }
9492 0 : if (flags & NDR_OUT) {
9493 0 : ndr_print_struct(ndr, "out", "samr_DeleteDomAlias");
9494 0 : ndr->depth++;
9495 0 : ndr_print_ptr(ndr, "alias_handle", r->out.alias_handle);
9496 0 : ndr->depth++;
9497 0 : ndr_print_policy_handle(ndr, "alias_handle", r->out.alias_handle);
9498 0 : ndr->depth--;
9499 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9500 0 : ndr->depth--;
9501 : }
9502 0 : ndr->depth--;
9503 : }
9504 :
9505 8 : static enum ndr_err_code ndr_push_samr_AddAliasMember(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_AddAliasMember *r)
9506 : {
9507 8 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9508 8 : if (flags & NDR_IN) {
9509 5 : if (r->in.alias_handle == NULL) {
9510 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9511 : }
9512 5 : if (r->in.sid == NULL) {
9513 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9514 : }
9515 5 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9516 5 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9517 : }
9518 8 : if (flags & NDR_OUT) {
9519 3 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9520 : }
9521 8 : return NDR_ERR_SUCCESS;
9522 : }
9523 :
9524 8 : static enum ndr_err_code ndr_pull_samr_AddAliasMember(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_AddAliasMember *r)
9525 : {
9526 8 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
9527 8 : TALLOC_CTX *_mem_save_sid_0 = NULL;
9528 8 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9529 8 : if (flags & NDR_IN) {
9530 3 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9531 3 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9532 : }
9533 3 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9534 3 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9535 3 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9536 3 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9537 3 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9538 3 : NDR_PULL_ALLOC(ndr, r->in.sid);
9539 : }
9540 3 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
9541 3 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
9542 3 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9543 3 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
9544 : }
9545 8 : if (flags & NDR_OUT) {
9546 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9547 : if (r->in.alias_handle == NULL) {
9548 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9549 : NDR_ZERO_STRUCTP(r->in.alias_handle);
9550 : }
9551 : if (r->in.sid == NULL) {
9552 : NDR_PULL_ALLOC(ndr, r->in.sid);
9553 : NDR_ZERO_STRUCTP(r->in.sid);
9554 : }
9555 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9556 5 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9557 : }
9558 8 : return NDR_ERR_SUCCESS;
9559 : }
9560 :
9561 0 : _PUBLIC_ void ndr_print_samr_AddAliasMember(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_AddAliasMember *r)
9562 : {
9563 0 : ndr_print_struct(ndr, name, "samr_AddAliasMember");
9564 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9565 0 : ndr->depth++;
9566 0 : if (flags & NDR_SET_VALUES) {
9567 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9568 : }
9569 0 : if (flags & NDR_IN) {
9570 0 : ndr_print_struct(ndr, "in", "samr_AddAliasMember");
9571 0 : ndr->depth++;
9572 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
9573 0 : ndr->depth++;
9574 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
9575 0 : ndr->depth--;
9576 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
9577 0 : ndr->depth++;
9578 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
9579 0 : ndr->depth--;
9580 0 : ndr->depth--;
9581 : }
9582 0 : if (flags & NDR_OUT) {
9583 0 : ndr_print_struct(ndr, "out", "samr_AddAliasMember");
9584 0 : ndr->depth++;
9585 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9586 0 : ndr->depth--;
9587 : }
9588 0 : ndr->depth--;
9589 : }
9590 :
9591 8 : static enum ndr_err_code ndr_push_samr_DeleteAliasMember(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_DeleteAliasMember *r)
9592 : {
9593 8 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9594 8 : if (flags & NDR_IN) {
9595 5 : if (r->in.alias_handle == NULL) {
9596 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9597 : }
9598 5 : if (r->in.sid == NULL) {
9599 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9600 : }
9601 5 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9602 5 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9603 : }
9604 8 : if (flags & NDR_OUT) {
9605 3 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9606 : }
9607 8 : return NDR_ERR_SUCCESS;
9608 : }
9609 :
9610 8 : static enum ndr_err_code ndr_pull_samr_DeleteAliasMember(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_DeleteAliasMember *r)
9611 : {
9612 8 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
9613 8 : TALLOC_CTX *_mem_save_sid_0 = NULL;
9614 8 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9615 8 : if (flags & NDR_IN) {
9616 3 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9617 3 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9618 : }
9619 3 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9620 3 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9621 3 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9622 3 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9623 3 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9624 3 : NDR_PULL_ALLOC(ndr, r->in.sid);
9625 : }
9626 3 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
9627 3 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
9628 3 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
9629 3 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
9630 : }
9631 8 : if (flags & NDR_OUT) {
9632 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9633 : if (r->in.alias_handle == NULL) {
9634 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9635 : NDR_ZERO_STRUCTP(r->in.alias_handle);
9636 : }
9637 : if (r->in.sid == NULL) {
9638 : NDR_PULL_ALLOC(ndr, r->in.sid);
9639 : NDR_ZERO_STRUCTP(r->in.sid);
9640 : }
9641 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9642 5 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9643 : }
9644 8 : return NDR_ERR_SUCCESS;
9645 : }
9646 :
9647 0 : _PUBLIC_ void ndr_print_samr_DeleteAliasMember(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_DeleteAliasMember *r)
9648 : {
9649 0 : ndr_print_struct(ndr, name, "samr_DeleteAliasMember");
9650 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9651 0 : ndr->depth++;
9652 0 : if (flags & NDR_SET_VALUES) {
9653 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9654 : }
9655 0 : if (flags & NDR_IN) {
9656 0 : ndr_print_struct(ndr, "in", "samr_DeleteAliasMember");
9657 0 : ndr->depth++;
9658 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
9659 0 : ndr->depth++;
9660 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
9661 0 : ndr->depth--;
9662 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
9663 0 : ndr->depth++;
9664 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
9665 0 : ndr->depth--;
9666 0 : ndr->depth--;
9667 : }
9668 0 : if (flags & NDR_OUT) {
9669 0 : ndr_print_struct(ndr, "out", "samr_DeleteAliasMember");
9670 0 : ndr->depth++;
9671 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9672 0 : ndr->depth--;
9673 : }
9674 0 : ndr->depth--;
9675 : }
9676 :
9677 1392 : static enum ndr_err_code ndr_push_samr_GetMembersInAlias(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetMembersInAlias *r)
9678 : {
9679 1392 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9680 1392 : if (flags & NDR_IN) {
9681 1311 : if (r->in.alias_handle == NULL) {
9682 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9683 : }
9684 1311 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9685 : }
9686 1392 : if (flags & NDR_OUT) {
9687 81 : if (r->out.sids == NULL) {
9688 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9689 : }
9690 81 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
9691 81 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9692 : }
9693 1392 : return NDR_ERR_SUCCESS;
9694 : }
9695 :
9696 1392 : static enum ndr_err_code ndr_pull_samr_GetMembersInAlias(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetMembersInAlias *r)
9697 : {
9698 1392 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
9699 1392 : TALLOC_CTX *_mem_save_sids_0 = NULL;
9700 1392 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9701 1392 : if (flags & NDR_IN) {
9702 81 : NDR_ZERO_STRUCT(r->out);
9703 :
9704 81 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9705 81 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9706 : }
9707 81 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9708 81 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
9709 81 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
9710 81 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
9711 81 : NDR_PULL_ALLOC(ndr, r->out.sids);
9712 81 : NDR_ZERO_STRUCTP(r->out.sids);
9713 : }
9714 1392 : if (flags & NDR_OUT) {
9715 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9716 : if (r->in.alias_handle == NULL) {
9717 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
9718 : NDR_ZERO_STRUCTP(r->in.alias_handle);
9719 : }
9720 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9721 1311 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9722 1224 : NDR_PULL_ALLOC(ndr, r->out.sids);
9723 : }
9724 1311 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
9725 1311 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sids, LIBNDR_FLAG_REF_ALLOC);
9726 1311 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.sids));
9727 1311 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
9728 1311 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9729 : }
9730 1392 : return NDR_ERR_SUCCESS;
9731 : }
9732 :
9733 0 : _PUBLIC_ void ndr_print_samr_GetMembersInAlias(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetMembersInAlias *r)
9734 : {
9735 0 : ndr_print_struct(ndr, name, "samr_GetMembersInAlias");
9736 0 : if (r == NULL) { ndr_print_null(ndr); return; }
9737 0 : ndr->depth++;
9738 0 : if (flags & NDR_SET_VALUES) {
9739 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9740 : }
9741 0 : if (flags & NDR_IN) {
9742 0 : ndr_print_struct(ndr, "in", "samr_GetMembersInAlias");
9743 0 : ndr->depth++;
9744 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
9745 0 : ndr->depth++;
9746 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
9747 0 : ndr->depth--;
9748 0 : ndr->depth--;
9749 : }
9750 0 : if (flags & NDR_OUT) {
9751 0 : ndr_print_struct(ndr, "out", "samr_GetMembersInAlias");
9752 0 : ndr->depth++;
9753 0 : ndr_print_ptr(ndr, "sids", r->out.sids);
9754 0 : ndr->depth++;
9755 0 : ndr_print_lsa_SidArray(ndr, "sids", r->out.sids);
9756 0 : ndr->depth--;
9757 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9758 0 : ndr->depth--;
9759 : }
9760 0 : ndr->depth--;
9761 : }
9762 :
9763 6811 : _PUBLIC_ enum ndr_err_code ndr_push_samr_OpenUser(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_OpenUser *r)
9764 : {
9765 6811 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9766 6811 : if (flags & NDR_IN) {
9767 2487 : if (r->in.domain_handle == NULL) {
9768 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9769 : }
9770 2487 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
9771 2487 : NDR_CHECK(ndr_push_samr_UserAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
9772 2487 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.rid));
9773 : }
9774 6811 : if (flags & NDR_OUT) {
9775 4324 : if (r->out.user_handle == NULL) {
9776 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9777 : }
9778 4324 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
9779 4324 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9780 : }
9781 6811 : return NDR_ERR_SUCCESS;
9782 : }
9783 :
9784 6713 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_OpenUser(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_OpenUser *r)
9785 : {
9786 6713 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
9787 6713 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
9788 6713 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9789 6713 : if (flags & NDR_IN) {
9790 4230 : NDR_ZERO_STRUCT(r->out);
9791 :
9792 4230 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9793 4230 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
9794 : }
9795 4230 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9796 4230 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
9797 4230 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
9798 4230 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
9799 4232 : NDR_CHECK(ndr_pull_samr_UserAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
9800 4230 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.rid));
9801 4230 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
9802 4230 : NDR_ZERO_STRUCTP(r->out.user_handle);
9803 : }
9804 6713 : if (flags & NDR_OUT) {
9805 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9806 : if (r->in.domain_handle == NULL) {
9807 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
9808 : NDR_ZERO_STRUCTP(r->in.domain_handle);
9809 : }
9810 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9811 2483 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9812 1256 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
9813 : }
9814 2483 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9815 2483 : NDR_PULL_SET_MEM_CTX(ndr, r->out.user_handle, LIBNDR_FLAG_REF_ALLOC);
9816 2483 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
9817 2483 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
9818 2483 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9819 : }
9820 6709 : return NDR_ERR_SUCCESS;
9821 : }
9822 :
9823 204 : _PUBLIC_ void ndr_print_samr_OpenUser(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_OpenUser *r)
9824 : {
9825 204 : ndr_print_struct(ndr, name, "samr_OpenUser");
9826 204 : if (r == NULL) { ndr_print_null(ndr); return; }
9827 204 : ndr->depth++;
9828 204 : if (flags & NDR_SET_VALUES) {
9829 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9830 : }
9831 204 : if (flags & NDR_IN) {
9832 2 : ndr_print_struct(ndr, "in", "samr_OpenUser");
9833 2 : ndr->depth++;
9834 2 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
9835 2 : ndr->depth++;
9836 2 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
9837 2 : ndr->depth--;
9838 2 : ndr_print_samr_UserAccessMask(ndr, "access_mask", r->in.access_mask);
9839 2 : ndr_print_uint32(ndr, "rid", r->in.rid);
9840 2 : ndr->depth--;
9841 : }
9842 204 : if (flags & NDR_OUT) {
9843 202 : ndr_print_struct(ndr, "out", "samr_OpenUser");
9844 202 : ndr->depth++;
9845 202 : ndr_print_ptr(ndr, "user_handle", r->out.user_handle);
9846 202 : ndr->depth++;
9847 202 : ndr_print_policy_handle(ndr, "user_handle", r->out.user_handle);
9848 202 : ndr->depth--;
9849 202 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9850 202 : ndr->depth--;
9851 : }
9852 204 : ndr->depth--;
9853 : }
9854 :
9855 2592 : static enum ndr_err_code ndr_push_samr_DeleteUser(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_DeleteUser *r)
9856 : {
9857 2592 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9858 2592 : if (flags & NDR_IN) {
9859 1245 : if (r->in.user_handle == NULL) {
9860 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9861 : }
9862 1245 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
9863 : }
9864 2592 : if (flags & NDR_OUT) {
9865 1347 : if (r->out.user_handle == NULL) {
9866 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9867 : }
9868 1347 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
9869 1347 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9870 : }
9871 2394 : return NDR_ERR_SUCCESS;
9872 : }
9873 :
9874 2458 : static enum ndr_err_code ndr_pull_samr_DeleteUser(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_DeleteUser *r)
9875 : {
9876 2458 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
9877 2458 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9878 2458 : if (flags & NDR_IN) {
9879 1213 : NDR_ZERO_STRUCT(r->out);
9880 :
9881 1213 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9882 1213 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
9883 : }
9884 1213 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9885 1213 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
9886 1213 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
9887 1213 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
9888 1213 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
9889 1213 : *r->out.user_handle = *r->in.user_handle;
9890 : }
9891 2458 : if (flags & NDR_OUT) {
9892 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9893 : if (r->in.user_handle == NULL) {
9894 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
9895 : NDR_ZERO_STRUCTP(r->in.user_handle);
9896 : }
9897 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9898 1245 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9899 140 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
9900 : }
9901 1245 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9902 1245 : NDR_PULL_SET_MEM_CTX(ndr, r->out.user_handle, LIBNDR_FLAG_REF_ALLOC);
9903 1245 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
9904 1245 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
9905 1245 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
9906 : }
9907 2278 : return NDR_ERR_SUCCESS;
9908 : }
9909 :
9910 268 : _PUBLIC_ void ndr_print_samr_DeleteUser(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_DeleteUser *r)
9911 : {
9912 268 : ndr_print_struct(ndr, name, "samr_DeleteUser");
9913 268 : if (r == NULL) { ndr_print_null(ndr); return; }
9914 268 : ndr->depth++;
9915 268 : if (flags & NDR_SET_VALUES) {
9916 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
9917 : }
9918 268 : if (flags & NDR_IN) {
9919 0 : ndr_print_struct(ndr, "in", "samr_DeleteUser");
9920 0 : ndr->depth++;
9921 0 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
9922 0 : ndr->depth++;
9923 0 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
9924 0 : ndr->depth--;
9925 0 : ndr->depth--;
9926 : }
9927 268 : if (flags & NDR_OUT) {
9928 268 : ndr_print_struct(ndr, "out", "samr_DeleteUser");
9929 268 : ndr->depth++;
9930 268 : ndr_print_ptr(ndr, "user_handle", r->out.user_handle);
9931 268 : ndr->depth++;
9932 268 : ndr_print_policy_handle(ndr, "user_handle", r->out.user_handle);
9933 268 : ndr->depth--;
9934 268 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
9935 268 : ndr->depth--;
9936 : }
9937 268 : ndr->depth--;
9938 : }
9939 :
9940 23787 : _PUBLIC_ enum ndr_err_code ndr_push_samr_QueryUserInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryUserInfo *r)
9941 : {
9942 23787 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
9943 23787 : if (flags & NDR_IN) {
9944 12330 : if (r->in.user_handle == NULL) {
9945 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9946 : }
9947 12330 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
9948 12420 : NDR_CHECK(ndr_push_samr_UserInfoLevel(ndr, NDR_SCALARS, r->in.level));
9949 : }
9950 23787 : if (flags & NDR_OUT) {
9951 11457 : if (r->out.info == NULL) {
9952 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
9953 : }
9954 11457 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
9955 11457 : if (*r->out.info) {
9956 11457 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
9957 11457 : NDR_CHECK(ndr_push_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
9958 : }
9959 11457 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
9960 : }
9961 23589 : return NDR_ERR_SUCCESS;
9962 : }
9963 :
9964 23572 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_QueryUserInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryUserInfo *r)
9965 : {
9966 186 : uint32_t _ptr_info;
9967 23572 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
9968 23572 : TALLOC_CTX *_mem_save_info_0 = NULL;
9969 23572 : TALLOC_CTX *_mem_save_info_1 = NULL;
9970 23572 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
9971 23572 : if (flags & NDR_IN) {
9972 11240 : NDR_ZERO_STRUCT(r->out);
9973 :
9974 11240 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9975 11240 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
9976 : }
9977 11240 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
9978 11240 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
9979 11240 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
9980 11240 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
9981 11334 : NDR_CHECK(ndr_pull_samr_UserInfoLevel(ndr, NDR_SCALARS, &r->in.level));
9982 11240 : NDR_PULL_ALLOC(ndr, r->out.info);
9983 11240 : NDR_ZERO_STRUCTP(r->out.info);
9984 : }
9985 23572 : if (flags & NDR_OUT) {
9986 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
9987 : if (r->in.user_handle == NULL) {
9988 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
9989 : NDR_ZERO_STRUCTP(r->in.user_handle);
9990 : }
9991 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
9992 12332 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
9993 3715 : NDR_PULL_ALLOC(ndr, r->out.info);
9994 : }
9995 12332 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
9996 12332 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
9997 12332 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
9998 12332 : if (_ptr_info) {
9999 12332 : NDR_PULL_ALLOC(ndr, *r->out.info);
10000 : } else {
10001 0 : *r->out.info = NULL;
10002 : }
10003 12332 : if (*r->out.info) {
10004 12332 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
10005 12332 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
10006 12332 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
10007 12332 : NDR_CHECK(ndr_pull_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
10008 12332 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
10009 : }
10010 12332 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
10011 12332 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10012 : }
10013 23386 : return NDR_ERR_SUCCESS;
10014 : }
10015 :
10016 448 : _PUBLIC_ void ndr_print_samr_QueryUserInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryUserInfo *r)
10017 : {
10018 448 : ndr_print_struct(ndr, name, "samr_QueryUserInfo");
10019 448 : if (r == NULL) { ndr_print_null(ndr); return; }
10020 448 : ndr->depth++;
10021 448 : if (flags & NDR_SET_VALUES) {
10022 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10023 : }
10024 448 : if (flags & NDR_IN) {
10025 4 : ndr_print_struct(ndr, "in", "samr_QueryUserInfo");
10026 4 : ndr->depth++;
10027 4 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
10028 4 : ndr->depth++;
10029 4 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
10030 4 : ndr->depth--;
10031 4 : ndr_print_samr_UserInfoLevel(ndr, "level", r->in.level);
10032 4 : ndr->depth--;
10033 : }
10034 448 : if (flags & NDR_OUT) {
10035 444 : ndr_print_struct(ndr, "out", "samr_QueryUserInfo");
10036 444 : ndr->depth++;
10037 444 : ndr_print_ptr(ndr, "info", r->out.info);
10038 444 : ndr->depth++;
10039 444 : ndr_print_ptr(ndr, "info", *r->out.info);
10040 444 : ndr->depth++;
10041 444 : if (*r->out.info) {
10042 444 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
10043 444 : ndr_print_samr_UserInfo(ndr, "info", *r->out.info);
10044 : }
10045 444 : ndr->depth--;
10046 444 : ndr->depth--;
10047 444 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10048 444 : ndr->depth--;
10049 : }
10050 448 : ndr->depth--;
10051 : }
10052 :
10053 6243 : _PUBLIC_ enum ndr_err_code ndr_push_samr_SetUserInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetUserInfo *r)
10054 : {
10055 6243 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10056 6243 : if (flags & NDR_IN) {
10057 3275 : if (r->in.user_handle == NULL) {
10058 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10059 : }
10060 3275 : if (r->in.info == NULL) {
10061 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10062 : }
10063 3275 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10064 3365 : NDR_CHECK(ndr_push_samr_UserInfoLevel(ndr, NDR_SCALARS, r->in.level));
10065 3275 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
10066 3275 : NDR_CHECK(ndr_push_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
10067 : }
10068 6243 : if (flags & NDR_OUT) {
10069 2968 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10070 : }
10071 6045 : return NDR_ERR_SUCCESS;
10072 : }
10073 :
10074 6062 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_SetUserInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetUserInfo *r)
10075 : {
10076 6062 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
10077 6062 : TALLOC_CTX *_mem_save_info_0 = NULL;
10078 6062 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10079 6062 : if (flags & NDR_IN) {
10080 2785 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10081 2785 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10082 : }
10083 2785 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10084 2785 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
10085 2785 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10086 2785 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
10087 2877 : NDR_CHECK(ndr_pull_samr_UserInfoLevel(ndr, NDR_SCALARS, &r->in.level));
10088 2785 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10089 2785 : NDR_PULL_ALLOC(ndr, r->in.info);
10090 : }
10091 2785 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
10092 2785 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
10093 2785 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
10094 2785 : NDR_CHECK(ndr_pull_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
10095 2785 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
10096 : }
10097 6062 : if (flags & NDR_OUT) {
10098 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10099 : if (r->in.user_handle == NULL) {
10100 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10101 : NDR_ZERO_STRUCTP(r->in.user_handle);
10102 : }
10103 : if (r->in.info == NULL) {
10104 : NDR_PULL_ALLOC(ndr, r->in.info);
10105 : NDR_ZERO_STRUCTP(r->in.info);
10106 : }
10107 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10108 3277 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10109 : }
10110 5878 : return NDR_ERR_SUCCESS;
10111 : }
10112 :
10113 374 : _PUBLIC_ void ndr_print_samr_SetUserInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetUserInfo *r)
10114 : {
10115 374 : ndr_print_struct(ndr, name, "samr_SetUserInfo");
10116 374 : if (r == NULL) { ndr_print_null(ndr); return; }
10117 374 : ndr->depth++;
10118 374 : if (flags & NDR_SET_VALUES) {
10119 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10120 : }
10121 374 : if (flags & NDR_IN) {
10122 2 : ndr_print_struct(ndr, "in", "samr_SetUserInfo");
10123 2 : ndr->depth++;
10124 2 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
10125 2 : ndr->depth++;
10126 2 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
10127 2 : ndr->depth--;
10128 2 : ndr_print_samr_UserInfoLevel(ndr, "level", r->in.level);
10129 2 : ndr_print_ptr(ndr, "info", r->in.info);
10130 2 : ndr->depth++;
10131 2 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
10132 2 : ndr_print_samr_UserInfo(ndr, "info", r->in.info);
10133 2 : ndr->depth--;
10134 2 : ndr->depth--;
10135 : }
10136 374 : if (flags & NDR_OUT) {
10137 372 : ndr_print_struct(ndr, "out", "samr_SetUserInfo");
10138 372 : ndr->depth++;
10139 372 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10140 372 : ndr->depth--;
10141 : }
10142 374 : ndr->depth--;
10143 : }
10144 :
10145 52 : static enum ndr_err_code ndr_push_samr_ChangePasswordUser(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_ChangePasswordUser *r)
10146 : {
10147 52 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10148 52 : if (flags & NDR_IN) {
10149 28 : if (r->in.user_handle == NULL) {
10150 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10151 : }
10152 28 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10153 28 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.lm_present));
10154 28 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.old_lm_crypted));
10155 28 : if (r->in.old_lm_crypted) {
10156 28 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.old_lm_crypted));
10157 : }
10158 28 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.new_lm_crypted));
10159 28 : if (r->in.new_lm_crypted) {
10160 28 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.new_lm_crypted));
10161 : }
10162 28 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.nt_present));
10163 28 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.old_nt_crypted));
10164 28 : if (r->in.old_nt_crypted) {
10165 28 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.old_nt_crypted));
10166 : }
10167 28 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.new_nt_crypted));
10168 28 : if (r->in.new_nt_crypted) {
10169 28 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.new_nt_crypted));
10170 : }
10171 28 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.cross1_present));
10172 28 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.nt_cross));
10173 28 : if (r->in.nt_cross) {
10174 28 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.nt_cross));
10175 : }
10176 28 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.cross2_present));
10177 28 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.lm_cross));
10178 28 : if (r->in.lm_cross) {
10179 28 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.lm_cross));
10180 : }
10181 : }
10182 52 : if (flags & NDR_OUT) {
10183 24 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10184 : }
10185 52 : return NDR_ERR_SUCCESS;
10186 : }
10187 :
10188 52 : static enum ndr_err_code ndr_pull_samr_ChangePasswordUser(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_ChangePasswordUser *r)
10189 : {
10190 0 : uint32_t _ptr_old_lm_crypted;
10191 0 : uint32_t _ptr_new_lm_crypted;
10192 0 : uint32_t _ptr_old_nt_crypted;
10193 0 : uint32_t _ptr_new_nt_crypted;
10194 0 : uint32_t _ptr_nt_cross;
10195 0 : uint32_t _ptr_lm_cross;
10196 52 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
10197 52 : TALLOC_CTX *_mem_save_old_lm_crypted_0 = NULL;
10198 52 : TALLOC_CTX *_mem_save_new_lm_crypted_0 = NULL;
10199 52 : TALLOC_CTX *_mem_save_old_nt_crypted_0 = NULL;
10200 52 : TALLOC_CTX *_mem_save_new_nt_crypted_0 = NULL;
10201 52 : TALLOC_CTX *_mem_save_nt_cross_0 = NULL;
10202 52 : TALLOC_CTX *_mem_save_lm_cross_0 = NULL;
10203 52 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10204 52 : if (flags & NDR_IN) {
10205 24 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10206 24 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10207 : }
10208 24 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10209 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
10210 24 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10211 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
10212 24 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.lm_present));
10213 24 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_lm_crypted));
10214 24 : if (_ptr_old_lm_crypted) {
10215 24 : NDR_PULL_ALLOC(ndr, r->in.old_lm_crypted);
10216 : } else {
10217 0 : r->in.old_lm_crypted = NULL;
10218 : }
10219 24 : if (r->in.old_lm_crypted) {
10220 24 : _mem_save_old_lm_crypted_0 = NDR_PULL_GET_MEM_CTX(ndr);
10221 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.old_lm_crypted, 0);
10222 24 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.old_lm_crypted));
10223 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_lm_crypted_0, 0);
10224 : }
10225 24 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_new_lm_crypted));
10226 24 : if (_ptr_new_lm_crypted) {
10227 24 : NDR_PULL_ALLOC(ndr, r->in.new_lm_crypted);
10228 : } else {
10229 0 : r->in.new_lm_crypted = NULL;
10230 : }
10231 24 : if (r->in.new_lm_crypted) {
10232 24 : _mem_save_new_lm_crypted_0 = NDR_PULL_GET_MEM_CTX(ndr);
10233 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.new_lm_crypted, 0);
10234 24 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.new_lm_crypted));
10235 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_lm_crypted_0, 0);
10236 : }
10237 24 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.nt_present));
10238 24 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_old_nt_crypted));
10239 24 : if (_ptr_old_nt_crypted) {
10240 24 : NDR_PULL_ALLOC(ndr, r->in.old_nt_crypted);
10241 : } else {
10242 0 : r->in.old_nt_crypted = NULL;
10243 : }
10244 24 : if (r->in.old_nt_crypted) {
10245 24 : _mem_save_old_nt_crypted_0 = NDR_PULL_GET_MEM_CTX(ndr);
10246 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.old_nt_crypted, 0);
10247 24 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.old_nt_crypted));
10248 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_old_nt_crypted_0, 0);
10249 : }
10250 24 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_new_nt_crypted));
10251 24 : if (_ptr_new_nt_crypted) {
10252 24 : NDR_PULL_ALLOC(ndr, r->in.new_nt_crypted);
10253 : } else {
10254 0 : r->in.new_nt_crypted = NULL;
10255 : }
10256 24 : if (r->in.new_nt_crypted) {
10257 24 : _mem_save_new_nt_crypted_0 = NDR_PULL_GET_MEM_CTX(ndr);
10258 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.new_nt_crypted, 0);
10259 24 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.new_nt_crypted));
10260 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_new_nt_crypted_0, 0);
10261 : }
10262 24 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.cross1_present));
10263 24 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_nt_cross));
10264 24 : if (_ptr_nt_cross) {
10265 24 : NDR_PULL_ALLOC(ndr, r->in.nt_cross);
10266 : } else {
10267 0 : r->in.nt_cross = NULL;
10268 : }
10269 24 : if (r->in.nt_cross) {
10270 24 : _mem_save_nt_cross_0 = NDR_PULL_GET_MEM_CTX(ndr);
10271 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.nt_cross, 0);
10272 24 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.nt_cross));
10273 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_nt_cross_0, 0);
10274 : }
10275 24 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.cross2_present));
10276 24 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_lm_cross));
10277 24 : if (_ptr_lm_cross) {
10278 24 : NDR_PULL_ALLOC(ndr, r->in.lm_cross);
10279 : } else {
10280 0 : r->in.lm_cross = NULL;
10281 : }
10282 24 : if (r->in.lm_cross) {
10283 24 : _mem_save_lm_cross_0 = NDR_PULL_GET_MEM_CTX(ndr);
10284 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.lm_cross, 0);
10285 24 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.lm_cross));
10286 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_lm_cross_0, 0);
10287 : }
10288 : }
10289 52 : if (flags & NDR_OUT) {
10290 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10291 : if (r->in.user_handle == NULL) {
10292 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10293 : NDR_ZERO_STRUCTP(r->in.user_handle);
10294 : }
10295 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10296 28 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10297 : }
10298 52 : return NDR_ERR_SUCCESS;
10299 : }
10300 :
10301 0 : _PUBLIC_ void ndr_print_samr_ChangePasswordUser(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_ChangePasswordUser *r)
10302 : {
10303 0 : ndr_print_struct(ndr, name, "samr_ChangePasswordUser");
10304 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10305 0 : ndr->depth++;
10306 0 : if (flags & NDR_SET_VALUES) {
10307 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10308 : }
10309 0 : if (flags & NDR_IN) {
10310 0 : ndr_print_struct(ndr, "in", "samr_ChangePasswordUser");
10311 0 : ndr->depth++;
10312 0 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
10313 0 : ndr->depth++;
10314 0 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
10315 0 : ndr->depth--;
10316 0 : ndr_print_uint8(ndr, "lm_present", r->in.lm_present);
10317 0 : ndr_print_ptr(ndr, "old_lm_crypted", r->in.old_lm_crypted);
10318 0 : ndr->depth++;
10319 0 : if (r->in.old_lm_crypted) {
10320 0 : ndr_print_samr_Password(ndr, "old_lm_crypted", r->in.old_lm_crypted);
10321 : }
10322 0 : ndr->depth--;
10323 0 : ndr_print_ptr(ndr, "new_lm_crypted", r->in.new_lm_crypted);
10324 0 : ndr->depth++;
10325 0 : if (r->in.new_lm_crypted) {
10326 0 : ndr_print_samr_Password(ndr, "new_lm_crypted", r->in.new_lm_crypted);
10327 : }
10328 0 : ndr->depth--;
10329 0 : ndr_print_uint8(ndr, "nt_present", r->in.nt_present);
10330 0 : ndr_print_ptr(ndr, "old_nt_crypted", r->in.old_nt_crypted);
10331 0 : ndr->depth++;
10332 0 : if (r->in.old_nt_crypted) {
10333 0 : ndr_print_samr_Password(ndr, "old_nt_crypted", r->in.old_nt_crypted);
10334 : }
10335 0 : ndr->depth--;
10336 0 : ndr_print_ptr(ndr, "new_nt_crypted", r->in.new_nt_crypted);
10337 0 : ndr->depth++;
10338 0 : if (r->in.new_nt_crypted) {
10339 0 : ndr_print_samr_Password(ndr, "new_nt_crypted", r->in.new_nt_crypted);
10340 : }
10341 0 : ndr->depth--;
10342 0 : ndr_print_uint8(ndr, "cross1_present", r->in.cross1_present);
10343 0 : ndr_print_ptr(ndr, "nt_cross", r->in.nt_cross);
10344 0 : ndr->depth++;
10345 0 : if (r->in.nt_cross) {
10346 0 : ndr_print_samr_Password(ndr, "nt_cross", r->in.nt_cross);
10347 : }
10348 0 : ndr->depth--;
10349 0 : ndr_print_uint8(ndr, "cross2_present", r->in.cross2_present);
10350 0 : ndr_print_ptr(ndr, "lm_cross", r->in.lm_cross);
10351 0 : ndr->depth++;
10352 0 : if (r->in.lm_cross) {
10353 0 : ndr_print_samr_Password(ndr, "lm_cross", r->in.lm_cross);
10354 : }
10355 0 : ndr->depth--;
10356 0 : ndr->depth--;
10357 : }
10358 0 : if (flags & NDR_OUT) {
10359 0 : ndr_print_struct(ndr, "out", "samr_ChangePasswordUser");
10360 0 : ndr->depth++;
10361 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10362 0 : ndr->depth--;
10363 : }
10364 0 : ndr->depth--;
10365 : }
10366 :
10367 2758 : static enum ndr_err_code ndr_push_samr_GetGroupsForUser(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetGroupsForUser *r)
10368 : {
10369 2758 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10370 2758 : if (flags & NDR_IN) {
10371 500 : if (r->in.user_handle == NULL) {
10372 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10373 : }
10374 500 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10375 : }
10376 2758 : if (flags & NDR_OUT) {
10377 2258 : if (r->out.rids == NULL) {
10378 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10379 : }
10380 2258 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.rids));
10381 2258 : if (*r->out.rids) {
10382 2258 : NDR_CHECK(ndr_push_samr_RidWithAttributeArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.rids));
10383 : }
10384 2258 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10385 : }
10386 2758 : return NDR_ERR_SUCCESS;
10387 : }
10388 :
10389 2746 : static enum ndr_err_code ndr_pull_samr_GetGroupsForUser(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetGroupsForUser *r)
10390 : {
10391 0 : uint32_t _ptr_rids;
10392 2746 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
10393 2746 : TALLOC_CTX *_mem_save_rids_0 = NULL;
10394 2746 : TALLOC_CTX *_mem_save_rids_1 = NULL;
10395 2746 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10396 2746 : if (flags & NDR_IN) {
10397 2246 : NDR_ZERO_STRUCT(r->out);
10398 :
10399 2246 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10400 2246 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10401 : }
10402 2246 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10403 2246 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
10404 2246 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10405 2246 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
10406 2246 : NDR_PULL_ALLOC(ndr, r->out.rids);
10407 2246 : NDR_ZERO_STRUCTP(r->out.rids);
10408 : }
10409 2746 : if (flags & NDR_OUT) {
10410 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10411 : if (r->in.user_handle == NULL) {
10412 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10413 : NDR_ZERO_STRUCTP(r->in.user_handle);
10414 : }
10415 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10416 500 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10417 104 : NDR_PULL_ALLOC(ndr, r->out.rids);
10418 : }
10419 500 : _mem_save_rids_0 = NDR_PULL_GET_MEM_CTX(ndr);
10420 500 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rids, LIBNDR_FLAG_REF_ALLOC);
10421 500 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_rids));
10422 500 : if (_ptr_rids) {
10423 500 : NDR_PULL_ALLOC(ndr, *r->out.rids);
10424 : } else {
10425 0 : *r->out.rids = NULL;
10426 : }
10427 500 : if (*r->out.rids) {
10428 500 : _mem_save_rids_1 = NDR_PULL_GET_MEM_CTX(ndr);
10429 500 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.rids, 0);
10430 500 : NDR_CHECK(ndr_pull_samr_RidWithAttributeArray(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.rids));
10431 500 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_1, 0);
10432 : }
10433 500 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rids_0, LIBNDR_FLAG_REF_ALLOC);
10434 500 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10435 : }
10436 2746 : return NDR_ERR_SUCCESS;
10437 : }
10438 :
10439 24 : _PUBLIC_ void ndr_print_samr_GetGroupsForUser(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetGroupsForUser *r)
10440 : {
10441 24 : ndr_print_struct(ndr, name, "samr_GetGroupsForUser");
10442 24 : if (r == NULL) { ndr_print_null(ndr); return; }
10443 24 : ndr->depth++;
10444 24 : if (flags & NDR_SET_VALUES) {
10445 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10446 : }
10447 24 : if (flags & NDR_IN) {
10448 0 : ndr_print_struct(ndr, "in", "samr_GetGroupsForUser");
10449 0 : ndr->depth++;
10450 0 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
10451 0 : ndr->depth++;
10452 0 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
10453 0 : ndr->depth--;
10454 0 : ndr->depth--;
10455 : }
10456 24 : if (flags & NDR_OUT) {
10457 24 : ndr_print_struct(ndr, "out", "samr_GetGroupsForUser");
10458 24 : ndr->depth++;
10459 24 : ndr_print_ptr(ndr, "rids", r->out.rids);
10460 24 : ndr->depth++;
10461 24 : ndr_print_ptr(ndr, "rids", *r->out.rids);
10462 24 : ndr->depth++;
10463 24 : if (*r->out.rids) {
10464 24 : ndr_print_samr_RidWithAttributeArray(ndr, "rids", *r->out.rids);
10465 : }
10466 24 : ndr->depth--;
10467 24 : ndr->depth--;
10468 24 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10469 24 : ndr->depth--;
10470 : }
10471 24 : ndr->depth--;
10472 : }
10473 :
10474 707 : static enum ndr_err_code ndr_push_samr_QueryDisplayInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryDisplayInfo *r)
10475 : {
10476 707 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10477 707 : if (flags & NDR_IN) {
10478 392 : if (r->in.domain_handle == NULL) {
10479 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10480 : }
10481 392 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10482 392 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
10483 392 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.start_idx));
10484 392 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_entries));
10485 392 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buf_size));
10486 : }
10487 707 : if (flags & NDR_OUT) {
10488 315 : if (r->out.total_size == NULL) {
10489 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10490 : }
10491 315 : if (r->out.returned_size == NULL) {
10492 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10493 : }
10494 315 : if (r->out.info == NULL) {
10495 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10496 : }
10497 315 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.total_size));
10498 315 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.returned_size));
10499 315 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
10500 315 : NDR_CHECK(ndr_push_samr_DispInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
10501 315 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10502 : }
10503 707 : return NDR_ERR_SUCCESS;
10504 : }
10505 :
10506 706 : static enum ndr_err_code ndr_pull_samr_QueryDisplayInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryDisplayInfo *r)
10507 : {
10508 706 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
10509 706 : TALLOC_CTX *_mem_save_total_size_0 = NULL;
10510 706 : TALLOC_CTX *_mem_save_returned_size_0 = NULL;
10511 706 : TALLOC_CTX *_mem_save_info_0 = NULL;
10512 706 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10513 706 : if (flags & NDR_IN) {
10514 314 : NDR_ZERO_STRUCT(r->out);
10515 :
10516 314 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10517 314 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10518 : }
10519 314 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10520 314 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
10521 314 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10522 314 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
10523 314 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
10524 314 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.start_idx));
10525 314 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_entries));
10526 314 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.buf_size));
10527 314 : NDR_PULL_ALLOC(ndr, r->out.total_size);
10528 314 : NDR_ZERO_STRUCTP(r->out.total_size);
10529 314 : NDR_PULL_ALLOC(ndr, r->out.returned_size);
10530 314 : NDR_ZERO_STRUCTP(r->out.returned_size);
10531 314 : NDR_PULL_ALLOC(ndr, r->out.info);
10532 314 : NDR_ZERO_STRUCTP(r->out.info);
10533 : }
10534 706 : if (flags & NDR_OUT) {
10535 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10536 : if (r->in.domain_handle == NULL) {
10537 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10538 : NDR_ZERO_STRUCTP(r->in.domain_handle);
10539 : }
10540 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10541 392 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10542 46 : NDR_PULL_ALLOC(ndr, r->out.total_size);
10543 : }
10544 392 : _mem_save_total_size_0 = NDR_PULL_GET_MEM_CTX(ndr);
10545 392 : NDR_PULL_SET_MEM_CTX(ndr, r->out.total_size, LIBNDR_FLAG_REF_ALLOC);
10546 392 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.total_size));
10547 392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_total_size_0, LIBNDR_FLAG_REF_ALLOC);
10548 392 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10549 46 : NDR_PULL_ALLOC(ndr, r->out.returned_size);
10550 : }
10551 392 : _mem_save_returned_size_0 = NDR_PULL_GET_MEM_CTX(ndr);
10552 392 : NDR_PULL_SET_MEM_CTX(ndr, r->out.returned_size, LIBNDR_FLAG_REF_ALLOC);
10553 392 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.returned_size));
10554 392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_returned_size_0, LIBNDR_FLAG_REF_ALLOC);
10555 392 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10556 46 : NDR_PULL_ALLOC(ndr, r->out.info);
10557 : }
10558 392 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
10559 392 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
10560 392 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
10561 392 : NDR_CHECK(ndr_pull_samr_DispInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
10562 392 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
10563 392 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10564 : }
10565 706 : return NDR_ERR_SUCCESS;
10566 : }
10567 :
10568 2 : _PUBLIC_ void ndr_print_samr_QueryDisplayInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryDisplayInfo *r)
10569 : {
10570 2 : ndr_print_struct(ndr, name, "samr_QueryDisplayInfo");
10571 2 : if (r == NULL) { ndr_print_null(ndr); return; }
10572 2 : ndr->depth++;
10573 2 : if (flags & NDR_SET_VALUES) {
10574 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10575 : }
10576 2 : if (flags & NDR_IN) {
10577 0 : ndr_print_struct(ndr, "in", "samr_QueryDisplayInfo");
10578 0 : ndr->depth++;
10579 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
10580 0 : ndr->depth++;
10581 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
10582 0 : ndr->depth--;
10583 0 : ndr_print_uint16(ndr, "level", r->in.level);
10584 0 : ndr_print_uint32(ndr, "start_idx", r->in.start_idx);
10585 0 : ndr_print_uint32(ndr, "max_entries", r->in.max_entries);
10586 0 : ndr_print_uint32(ndr, "buf_size", r->in.buf_size);
10587 0 : ndr->depth--;
10588 : }
10589 2 : if (flags & NDR_OUT) {
10590 2 : ndr_print_struct(ndr, "out", "samr_QueryDisplayInfo");
10591 2 : ndr->depth++;
10592 2 : ndr_print_ptr(ndr, "total_size", r->out.total_size);
10593 2 : ndr->depth++;
10594 2 : ndr_print_uint32(ndr, "total_size", *r->out.total_size);
10595 2 : ndr->depth--;
10596 2 : ndr_print_ptr(ndr, "returned_size", r->out.returned_size);
10597 2 : ndr->depth++;
10598 2 : ndr_print_uint32(ndr, "returned_size", *r->out.returned_size);
10599 2 : ndr->depth--;
10600 2 : ndr_print_ptr(ndr, "info", r->out.info);
10601 2 : ndr->depth++;
10602 2 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
10603 2 : ndr_print_samr_DispInfo(ndr, "info", r->out.info);
10604 2 : ndr->depth--;
10605 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10606 2 : ndr->depth--;
10607 : }
10608 2 : ndr->depth--;
10609 : }
10610 :
10611 40 : static enum ndr_err_code ndr_push_samr_GetDisplayEnumerationIndex(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetDisplayEnumerationIndex *r)
10612 : {
10613 40 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10614 40 : if (flags & NDR_IN) {
10615 40 : if (r->in.domain_handle == NULL) {
10616 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10617 : }
10618 40 : if (r->in.name == NULL) {
10619 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10620 : }
10621 40 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10622 40 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
10623 40 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
10624 : }
10625 40 : if (flags & NDR_OUT) {
10626 0 : if (r->out.idx == NULL) {
10627 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10628 : }
10629 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.idx));
10630 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10631 : }
10632 40 : return NDR_ERR_SUCCESS;
10633 : }
10634 :
10635 40 : static enum ndr_err_code ndr_pull_samr_GetDisplayEnumerationIndex(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetDisplayEnumerationIndex *r)
10636 : {
10637 40 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
10638 40 : TALLOC_CTX *_mem_save_name_0 = NULL;
10639 40 : TALLOC_CTX *_mem_save_idx_0 = NULL;
10640 40 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10641 40 : if (flags & NDR_IN) {
10642 0 : NDR_ZERO_STRUCT(r->out);
10643 :
10644 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10645 0 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10646 : }
10647 0 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10648 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
10649 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10650 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
10651 0 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
10652 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10653 0 : NDR_PULL_ALLOC(ndr, r->in.name);
10654 : }
10655 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
10656 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, LIBNDR_FLAG_REF_ALLOC);
10657 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
10658 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
10659 0 : NDR_PULL_ALLOC(ndr, r->out.idx);
10660 0 : NDR_ZERO_STRUCTP(r->out.idx);
10661 : }
10662 40 : if (flags & NDR_OUT) {
10663 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10664 : if (r->in.domain_handle == NULL) {
10665 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10666 : NDR_ZERO_STRUCTP(r->in.domain_handle);
10667 : }
10668 : if (r->in.name == NULL) {
10669 : NDR_PULL_ALLOC(ndr, r->in.name);
10670 : NDR_ZERO_STRUCTP(r->in.name);
10671 : }
10672 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10673 40 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10674 0 : NDR_PULL_ALLOC(ndr, r->out.idx);
10675 : }
10676 40 : _mem_save_idx_0 = NDR_PULL_GET_MEM_CTX(ndr);
10677 40 : NDR_PULL_SET_MEM_CTX(ndr, r->out.idx, LIBNDR_FLAG_REF_ALLOC);
10678 40 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.idx));
10679 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_idx_0, LIBNDR_FLAG_REF_ALLOC);
10680 40 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10681 : }
10682 40 : return NDR_ERR_SUCCESS;
10683 : }
10684 :
10685 0 : _PUBLIC_ void ndr_print_samr_GetDisplayEnumerationIndex(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetDisplayEnumerationIndex *r)
10686 : {
10687 0 : ndr_print_struct(ndr, name, "samr_GetDisplayEnumerationIndex");
10688 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10689 0 : ndr->depth++;
10690 0 : if (flags & NDR_SET_VALUES) {
10691 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10692 : }
10693 0 : if (flags & NDR_IN) {
10694 0 : ndr_print_struct(ndr, "in", "samr_GetDisplayEnumerationIndex");
10695 0 : ndr->depth++;
10696 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
10697 0 : ndr->depth++;
10698 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
10699 0 : ndr->depth--;
10700 0 : ndr_print_uint16(ndr, "level", r->in.level);
10701 0 : ndr_print_ptr(ndr, "name", r->in.name);
10702 0 : ndr->depth++;
10703 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
10704 0 : ndr->depth--;
10705 0 : ndr->depth--;
10706 : }
10707 0 : if (flags & NDR_OUT) {
10708 0 : ndr_print_struct(ndr, "out", "samr_GetDisplayEnumerationIndex");
10709 0 : ndr->depth++;
10710 0 : ndr_print_ptr(ndr, "idx", r->out.idx);
10711 0 : ndr->depth++;
10712 0 : ndr_print_uint32(ndr, "idx", *r->out.idx);
10713 0 : ndr->depth--;
10714 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10715 0 : ndr->depth--;
10716 : }
10717 0 : ndr->depth--;
10718 : }
10719 :
10720 16 : static enum ndr_err_code ndr_push_samr_TestPrivateFunctionsDomain(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_TestPrivateFunctionsDomain *r)
10721 : {
10722 16 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10723 16 : if (flags & NDR_IN) {
10724 10 : if (r->in.domain_handle == NULL) {
10725 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10726 : }
10727 10 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10728 : }
10729 16 : if (flags & NDR_OUT) {
10730 6 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10731 : }
10732 16 : return NDR_ERR_SUCCESS;
10733 : }
10734 :
10735 12 : static enum ndr_err_code ndr_pull_samr_TestPrivateFunctionsDomain(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_TestPrivateFunctionsDomain *r)
10736 : {
10737 12 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
10738 12 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10739 12 : if (flags & NDR_IN) {
10740 6 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10741 6 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10742 : }
10743 6 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10744 6 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
10745 6 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10746 6 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
10747 : }
10748 12 : if (flags & NDR_OUT) {
10749 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10750 : if (r->in.domain_handle == NULL) {
10751 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10752 : NDR_ZERO_STRUCTP(r->in.domain_handle);
10753 : }
10754 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10755 6 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10756 : }
10757 12 : return NDR_ERR_SUCCESS;
10758 : }
10759 :
10760 0 : _PUBLIC_ void ndr_print_samr_TestPrivateFunctionsDomain(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_TestPrivateFunctionsDomain *r)
10761 : {
10762 0 : ndr_print_struct(ndr, name, "samr_TestPrivateFunctionsDomain");
10763 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10764 0 : ndr->depth++;
10765 0 : if (flags & NDR_SET_VALUES) {
10766 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10767 : }
10768 0 : if (flags & NDR_IN) {
10769 0 : ndr_print_struct(ndr, "in", "samr_TestPrivateFunctionsDomain");
10770 0 : ndr->depth++;
10771 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
10772 0 : ndr->depth++;
10773 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
10774 0 : ndr->depth--;
10775 0 : ndr->depth--;
10776 : }
10777 0 : if (flags & NDR_OUT) {
10778 0 : ndr_print_struct(ndr, "out", "samr_TestPrivateFunctionsDomain");
10779 0 : ndr->depth++;
10780 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10781 0 : ndr->depth--;
10782 : }
10783 0 : ndr->depth--;
10784 : }
10785 :
10786 26 : static enum ndr_err_code ndr_push_samr_TestPrivateFunctionsUser(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_TestPrivateFunctionsUser *r)
10787 : {
10788 26 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10789 26 : if (flags & NDR_IN) {
10790 14 : if (r->in.user_handle == NULL) {
10791 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10792 : }
10793 14 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10794 : }
10795 26 : if (flags & NDR_OUT) {
10796 12 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10797 : }
10798 26 : return NDR_ERR_SUCCESS;
10799 : }
10800 :
10801 24 : static enum ndr_err_code ndr_pull_samr_TestPrivateFunctionsUser(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_TestPrivateFunctionsUser *r)
10802 : {
10803 24 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
10804 24 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10805 24 : if (flags & NDR_IN) {
10806 12 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10807 12 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10808 : }
10809 12 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10810 12 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
10811 12 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10812 12 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
10813 : }
10814 24 : if (flags & NDR_OUT) {
10815 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10816 : if (r->in.user_handle == NULL) {
10817 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10818 : NDR_ZERO_STRUCTP(r->in.user_handle);
10819 : }
10820 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10821 12 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10822 : }
10823 24 : return NDR_ERR_SUCCESS;
10824 : }
10825 :
10826 0 : _PUBLIC_ void ndr_print_samr_TestPrivateFunctionsUser(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_TestPrivateFunctionsUser *r)
10827 : {
10828 0 : ndr_print_struct(ndr, name, "samr_TestPrivateFunctionsUser");
10829 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10830 0 : ndr->depth++;
10831 0 : if (flags & NDR_SET_VALUES) {
10832 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10833 : }
10834 0 : if (flags & NDR_IN) {
10835 0 : ndr_print_struct(ndr, "in", "samr_TestPrivateFunctionsUser");
10836 0 : ndr->depth++;
10837 0 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
10838 0 : ndr->depth++;
10839 0 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
10840 0 : ndr->depth--;
10841 0 : ndr->depth--;
10842 : }
10843 0 : if (flags & NDR_OUT) {
10844 0 : ndr_print_struct(ndr, "out", "samr_TestPrivateFunctionsUser");
10845 0 : ndr->depth++;
10846 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10847 0 : ndr->depth--;
10848 : }
10849 0 : ndr->depth--;
10850 : }
10851 :
10852 3236 : _PUBLIC_ enum ndr_err_code ndr_push_samr_GetUserPwInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetUserPwInfo *r)
10853 : {
10854 3236 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10855 3236 : if (flags & NDR_IN) {
10856 1707 : if (r->in.user_handle == NULL) {
10857 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10858 : }
10859 1707 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10860 : }
10861 3236 : if (flags & NDR_OUT) {
10862 1529 : if (r->out.info == NULL) {
10863 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10864 : }
10865 1529 : NDR_CHECK(ndr_push_samr_PwInfo(ndr, NDR_SCALARS, r->out.info));
10866 1529 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10867 : }
10868 3038 : return NDR_ERR_SUCCESS;
10869 : }
10870 :
10871 3116 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_GetUserPwInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetUserPwInfo *r)
10872 : {
10873 3116 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
10874 3116 : TALLOC_CTX *_mem_save_info_0 = NULL;
10875 3116 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10876 3116 : if (flags & NDR_IN) {
10877 1407 : NDR_ZERO_STRUCT(r->out);
10878 :
10879 1407 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10880 1407 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10881 : }
10882 1407 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10883 1407 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
10884 1407 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
10885 1407 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
10886 1407 : NDR_PULL_ALLOC(ndr, r->out.info);
10887 1407 : NDR_ZERO_STRUCTP(r->out.info);
10888 : }
10889 3116 : if (flags & NDR_OUT) {
10890 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10891 : if (r->in.user_handle == NULL) {
10892 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
10893 : NDR_ZERO_STRUCTP(r->in.user_handle);
10894 : }
10895 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10896 1709 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10897 132 : NDR_PULL_ALLOC(ndr, r->out.info);
10898 : }
10899 1709 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
10900 1709 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
10901 1709 : NDR_CHECK(ndr_pull_samr_PwInfo(ndr, NDR_SCALARS, r->out.info));
10902 1709 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
10903 1709 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10904 : }
10905 2932 : return NDR_ERR_SUCCESS;
10906 : }
10907 :
10908 252 : _PUBLIC_ void ndr_print_samr_GetUserPwInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetUserPwInfo *r)
10909 : {
10910 252 : ndr_print_struct(ndr, name, "samr_GetUserPwInfo");
10911 252 : if (r == NULL) { ndr_print_null(ndr); return; }
10912 252 : ndr->depth++;
10913 252 : if (flags & NDR_SET_VALUES) {
10914 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
10915 : }
10916 252 : if (flags & NDR_IN) {
10917 2 : ndr_print_struct(ndr, "in", "samr_GetUserPwInfo");
10918 2 : ndr->depth++;
10919 2 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
10920 2 : ndr->depth++;
10921 2 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
10922 2 : ndr->depth--;
10923 2 : ndr->depth--;
10924 : }
10925 252 : if (flags & NDR_OUT) {
10926 250 : ndr_print_struct(ndr, "out", "samr_GetUserPwInfo");
10927 250 : ndr->depth++;
10928 250 : ndr_print_ptr(ndr, "info", r->out.info);
10929 250 : ndr->depth++;
10930 250 : ndr_print_samr_PwInfo(ndr, "info", r->out.info);
10931 250 : ndr->depth--;
10932 250 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
10933 250 : ndr->depth--;
10934 : }
10935 252 : ndr->depth--;
10936 : }
10937 :
10938 26 : static enum ndr_err_code ndr_push_samr_RemoveMemberFromForeignDomain(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_RemoveMemberFromForeignDomain *r)
10939 : {
10940 26 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
10941 26 : if (flags & NDR_IN) {
10942 16 : if (r->in.domain_handle == NULL) {
10943 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10944 : }
10945 16 : if (r->in.sid == NULL) {
10946 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
10947 : }
10948 16 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10949 16 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
10950 : }
10951 26 : if (flags & NDR_OUT) {
10952 10 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
10953 : }
10954 26 : return NDR_ERR_SUCCESS;
10955 : }
10956 :
10957 26 : static enum ndr_err_code ndr_pull_samr_RemoveMemberFromForeignDomain(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_RemoveMemberFromForeignDomain *r)
10958 : {
10959 26 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
10960 26 : TALLOC_CTX *_mem_save_sid_0 = NULL;
10961 26 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
10962 26 : if (flags & NDR_IN) {
10963 10 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10964 10 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10965 : }
10966 10 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
10967 10 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
10968 10 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
10969 10 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
10970 10 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
10971 10 : NDR_PULL_ALLOC(ndr, r->in.sid);
10972 : }
10973 10 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
10974 10 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sid, LIBNDR_FLAG_REF_ALLOC);
10975 10 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sid));
10976 10 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
10977 : }
10978 26 : if (flags & NDR_OUT) {
10979 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
10980 : if (r->in.domain_handle == NULL) {
10981 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
10982 : NDR_ZERO_STRUCTP(r->in.domain_handle);
10983 : }
10984 : if (r->in.sid == NULL) {
10985 : NDR_PULL_ALLOC(ndr, r->in.sid);
10986 : NDR_ZERO_STRUCTP(r->in.sid);
10987 : }
10988 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
10989 16 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
10990 : }
10991 26 : return NDR_ERR_SUCCESS;
10992 : }
10993 :
10994 0 : _PUBLIC_ void ndr_print_samr_RemoveMemberFromForeignDomain(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_RemoveMemberFromForeignDomain *r)
10995 : {
10996 0 : ndr_print_struct(ndr, name, "samr_RemoveMemberFromForeignDomain");
10997 0 : if (r == NULL) { ndr_print_null(ndr); return; }
10998 0 : ndr->depth++;
10999 0 : if (flags & NDR_SET_VALUES) {
11000 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11001 : }
11002 0 : if (flags & NDR_IN) {
11003 0 : ndr_print_struct(ndr, "in", "samr_RemoveMemberFromForeignDomain");
11004 0 : ndr->depth++;
11005 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
11006 0 : ndr->depth++;
11007 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
11008 0 : ndr->depth--;
11009 0 : ndr_print_ptr(ndr, "sid", r->in.sid);
11010 0 : ndr->depth++;
11011 0 : ndr_print_dom_sid2(ndr, "sid", r->in.sid);
11012 0 : ndr->depth--;
11013 0 : ndr->depth--;
11014 : }
11015 0 : if (flags & NDR_OUT) {
11016 0 : ndr_print_struct(ndr, "out", "samr_RemoveMemberFromForeignDomain");
11017 0 : ndr->depth++;
11018 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11019 0 : ndr->depth--;
11020 : }
11021 0 : ndr->depth--;
11022 : }
11023 :
11024 290 : static enum ndr_err_code ndr_push_samr_QueryDomainInfo2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryDomainInfo2 *r)
11025 : {
11026 290 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11027 290 : if (flags & NDR_IN) {
11028 175 : if (r->in.domain_handle == NULL) {
11029 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11030 : }
11031 175 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11032 175 : NDR_CHECK(ndr_push_samr_DomainInfoClass(ndr, NDR_SCALARS, r->in.level));
11033 : }
11034 290 : if (flags & NDR_OUT) {
11035 115 : if (r->out.info == NULL) {
11036 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11037 : }
11038 115 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
11039 115 : if (*r->out.info) {
11040 115 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
11041 115 : NDR_CHECK(ndr_push_samr_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11042 : }
11043 115 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11044 : }
11045 290 : return NDR_ERR_SUCCESS;
11046 : }
11047 :
11048 290 : static enum ndr_err_code ndr_pull_samr_QueryDomainInfo2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryDomainInfo2 *r)
11049 : {
11050 0 : uint32_t _ptr_info;
11051 290 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
11052 290 : TALLOC_CTX *_mem_save_info_0 = NULL;
11053 290 : TALLOC_CTX *_mem_save_info_1 = NULL;
11054 290 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11055 290 : if (flags & NDR_IN) {
11056 115 : NDR_ZERO_STRUCT(r->out);
11057 :
11058 115 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11059 115 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11060 : }
11061 115 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11062 115 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
11063 115 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11064 115 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
11065 115 : NDR_CHECK(ndr_pull_samr_DomainInfoClass(ndr, NDR_SCALARS, &r->in.level));
11066 115 : NDR_PULL_ALLOC(ndr, r->out.info);
11067 115 : NDR_ZERO_STRUCTP(r->out.info);
11068 : }
11069 290 : if (flags & NDR_OUT) {
11070 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11071 : if (r->in.domain_handle == NULL) {
11072 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11073 : NDR_ZERO_STRUCTP(r->in.domain_handle);
11074 : }
11075 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11076 175 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11077 1 : NDR_PULL_ALLOC(ndr, r->out.info);
11078 : }
11079 175 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11080 175 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
11081 175 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
11082 175 : if (_ptr_info) {
11083 175 : NDR_PULL_ALLOC(ndr, *r->out.info);
11084 : } else {
11085 0 : *r->out.info = NULL;
11086 : }
11087 175 : if (*r->out.info) {
11088 175 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
11089 175 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
11090 175 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
11091 175 : NDR_CHECK(ndr_pull_samr_DomainInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11092 175 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
11093 : }
11094 175 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11095 175 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11096 : }
11097 290 : return NDR_ERR_SUCCESS;
11098 : }
11099 :
11100 0 : _PUBLIC_ void ndr_print_samr_QueryDomainInfo2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryDomainInfo2 *r)
11101 : {
11102 0 : ndr_print_struct(ndr, name, "samr_QueryDomainInfo2");
11103 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11104 0 : ndr->depth++;
11105 0 : if (flags & NDR_SET_VALUES) {
11106 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11107 : }
11108 0 : if (flags & NDR_IN) {
11109 0 : ndr_print_struct(ndr, "in", "samr_QueryDomainInfo2");
11110 0 : ndr->depth++;
11111 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
11112 0 : ndr->depth++;
11113 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
11114 0 : ndr->depth--;
11115 0 : ndr_print_samr_DomainInfoClass(ndr, "level", r->in.level);
11116 0 : ndr->depth--;
11117 : }
11118 0 : if (flags & NDR_OUT) {
11119 0 : ndr_print_struct(ndr, "out", "samr_QueryDomainInfo2");
11120 0 : ndr->depth++;
11121 0 : ndr_print_ptr(ndr, "info", r->out.info);
11122 0 : ndr->depth++;
11123 0 : ndr_print_ptr(ndr, "info", *r->out.info);
11124 0 : ndr->depth++;
11125 0 : if (*r->out.info) {
11126 0 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
11127 0 : ndr_print_samr_DomainInfo(ndr, "info", *r->out.info);
11128 : }
11129 0 : ndr->depth--;
11130 0 : ndr->depth--;
11131 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11132 0 : ndr->depth--;
11133 : }
11134 0 : ndr->depth--;
11135 : }
11136 :
11137 2326 : static enum ndr_err_code ndr_push_samr_QueryUserInfo2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryUserInfo2 *r)
11138 : {
11139 2326 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11140 2326 : if (flags & NDR_IN) {
11141 1128 : if (r->in.user_handle == NULL) {
11142 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11143 : }
11144 1128 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
11145 1128 : NDR_CHECK(ndr_push_samr_UserInfoLevel(ndr, NDR_SCALARS, r->in.level));
11146 : }
11147 2326 : if (flags & NDR_OUT) {
11148 1198 : if (r->out.info == NULL) {
11149 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11150 : }
11151 1198 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.info));
11152 1198 : if (*r->out.info) {
11153 1198 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.info, r->in.level));
11154 1198 : NDR_CHECK(ndr_push_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11155 : }
11156 1198 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11157 : }
11158 2326 : return NDR_ERR_SUCCESS;
11159 : }
11160 :
11161 2326 : static enum ndr_err_code ndr_pull_samr_QueryUserInfo2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryUserInfo2 *r)
11162 : {
11163 0 : uint32_t _ptr_info;
11164 2326 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
11165 2326 : TALLOC_CTX *_mem_save_info_0 = NULL;
11166 2326 : TALLOC_CTX *_mem_save_info_1 = NULL;
11167 2326 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11168 2326 : if (flags & NDR_IN) {
11169 1198 : NDR_ZERO_STRUCT(r->out);
11170 :
11171 1198 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11172 1198 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
11173 : }
11174 1198 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11175 1198 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
11176 1198 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
11177 1198 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
11178 1198 : NDR_CHECK(ndr_pull_samr_UserInfoLevel(ndr, NDR_SCALARS, &r->in.level));
11179 1198 : NDR_PULL_ALLOC(ndr, r->out.info);
11180 1198 : NDR_ZERO_STRUCTP(r->out.info);
11181 : }
11182 2326 : if (flags & NDR_OUT) {
11183 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11184 : if (r->in.user_handle == NULL) {
11185 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
11186 : NDR_ZERO_STRUCTP(r->in.user_handle);
11187 : }
11188 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11189 1128 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11190 138 : NDR_PULL_ALLOC(ndr, r->out.info);
11191 : }
11192 1128 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11193 1128 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
11194 1128 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
11195 1128 : if (_ptr_info) {
11196 1128 : NDR_PULL_ALLOC(ndr, *r->out.info);
11197 : } else {
11198 0 : *r->out.info = NULL;
11199 : }
11200 1128 : if (*r->out.info) {
11201 1128 : _mem_save_info_1 = NDR_PULL_GET_MEM_CTX(ndr);
11202 1128 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.info, 0);
11203 1128 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.info, r->in.level));
11204 1128 : NDR_CHECK(ndr_pull_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.info));
11205 1128 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_1, 0);
11206 : }
11207 1128 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11208 1128 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11209 : }
11210 2326 : return NDR_ERR_SUCCESS;
11211 : }
11212 :
11213 0 : _PUBLIC_ void ndr_print_samr_QueryUserInfo2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryUserInfo2 *r)
11214 : {
11215 0 : ndr_print_struct(ndr, name, "samr_QueryUserInfo2");
11216 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11217 0 : ndr->depth++;
11218 0 : if (flags & NDR_SET_VALUES) {
11219 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11220 : }
11221 0 : if (flags & NDR_IN) {
11222 0 : ndr_print_struct(ndr, "in", "samr_QueryUserInfo2");
11223 0 : ndr->depth++;
11224 0 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
11225 0 : ndr->depth++;
11226 0 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
11227 0 : ndr->depth--;
11228 0 : ndr_print_samr_UserInfoLevel(ndr, "level", r->in.level);
11229 0 : ndr->depth--;
11230 : }
11231 0 : if (flags & NDR_OUT) {
11232 0 : ndr_print_struct(ndr, "out", "samr_QueryUserInfo2");
11233 0 : ndr->depth++;
11234 0 : ndr_print_ptr(ndr, "info", r->out.info);
11235 0 : ndr->depth++;
11236 0 : ndr_print_ptr(ndr, "info", *r->out.info);
11237 0 : ndr->depth++;
11238 0 : if (*r->out.info) {
11239 0 : ndr_print_set_switch_value(ndr, *r->out.info, r->in.level);
11240 0 : ndr_print_samr_UserInfo(ndr, "info", *r->out.info);
11241 : }
11242 0 : ndr->depth--;
11243 0 : ndr->depth--;
11244 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11245 0 : ndr->depth--;
11246 : }
11247 0 : ndr->depth--;
11248 : }
11249 :
11250 88 : static enum ndr_err_code ndr_push_samr_QueryDisplayInfo2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryDisplayInfo2 *r)
11251 : {
11252 88 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11253 88 : if (flags & NDR_IN) {
11254 54 : if (r->in.domain_handle == NULL) {
11255 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11256 : }
11257 54 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11258 54 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
11259 54 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.start_idx));
11260 54 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_entries));
11261 54 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buf_size));
11262 : }
11263 88 : if (flags & NDR_OUT) {
11264 34 : if (r->out.total_size == NULL) {
11265 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11266 : }
11267 34 : if (r->out.returned_size == NULL) {
11268 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11269 : }
11270 34 : if (r->out.info == NULL) {
11271 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11272 : }
11273 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.total_size));
11274 34 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.returned_size));
11275 34 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
11276 34 : NDR_CHECK(ndr_push_samr_DispInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
11277 34 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11278 : }
11279 88 : return NDR_ERR_SUCCESS;
11280 : }
11281 :
11282 88 : static enum ndr_err_code ndr_pull_samr_QueryDisplayInfo2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryDisplayInfo2 *r)
11283 : {
11284 88 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
11285 88 : TALLOC_CTX *_mem_save_total_size_0 = NULL;
11286 88 : TALLOC_CTX *_mem_save_returned_size_0 = NULL;
11287 88 : TALLOC_CTX *_mem_save_info_0 = NULL;
11288 88 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11289 88 : if (flags & NDR_IN) {
11290 34 : NDR_ZERO_STRUCT(r->out);
11291 :
11292 34 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11293 34 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11294 : }
11295 34 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11296 34 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
11297 34 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11298 34 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
11299 34 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
11300 34 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.start_idx));
11301 34 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_entries));
11302 34 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.buf_size));
11303 34 : NDR_PULL_ALLOC(ndr, r->out.total_size);
11304 34 : NDR_ZERO_STRUCTP(r->out.total_size);
11305 34 : NDR_PULL_ALLOC(ndr, r->out.returned_size);
11306 34 : NDR_ZERO_STRUCTP(r->out.returned_size);
11307 34 : NDR_PULL_ALLOC(ndr, r->out.info);
11308 34 : NDR_ZERO_STRUCTP(r->out.info);
11309 : }
11310 88 : if (flags & NDR_OUT) {
11311 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11312 : if (r->in.domain_handle == NULL) {
11313 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11314 : NDR_ZERO_STRUCTP(r->in.domain_handle);
11315 : }
11316 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11317 54 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11318 4 : NDR_PULL_ALLOC(ndr, r->out.total_size);
11319 : }
11320 54 : _mem_save_total_size_0 = NDR_PULL_GET_MEM_CTX(ndr);
11321 54 : NDR_PULL_SET_MEM_CTX(ndr, r->out.total_size, LIBNDR_FLAG_REF_ALLOC);
11322 54 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.total_size));
11323 54 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_total_size_0, LIBNDR_FLAG_REF_ALLOC);
11324 54 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11325 4 : NDR_PULL_ALLOC(ndr, r->out.returned_size);
11326 : }
11327 54 : _mem_save_returned_size_0 = NDR_PULL_GET_MEM_CTX(ndr);
11328 54 : NDR_PULL_SET_MEM_CTX(ndr, r->out.returned_size, LIBNDR_FLAG_REF_ALLOC);
11329 54 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.returned_size));
11330 54 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_returned_size_0, LIBNDR_FLAG_REF_ALLOC);
11331 54 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11332 4 : NDR_PULL_ALLOC(ndr, r->out.info);
11333 : }
11334 54 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11335 54 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
11336 54 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
11337 54 : NDR_CHECK(ndr_pull_samr_DispInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
11338 54 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11339 54 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11340 : }
11341 88 : return NDR_ERR_SUCCESS;
11342 : }
11343 :
11344 0 : _PUBLIC_ void ndr_print_samr_QueryDisplayInfo2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryDisplayInfo2 *r)
11345 : {
11346 0 : ndr_print_struct(ndr, name, "samr_QueryDisplayInfo2");
11347 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11348 0 : ndr->depth++;
11349 0 : if (flags & NDR_SET_VALUES) {
11350 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11351 : }
11352 0 : if (flags & NDR_IN) {
11353 0 : ndr_print_struct(ndr, "in", "samr_QueryDisplayInfo2");
11354 0 : ndr->depth++;
11355 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
11356 0 : ndr->depth++;
11357 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
11358 0 : ndr->depth--;
11359 0 : ndr_print_uint16(ndr, "level", r->in.level);
11360 0 : ndr_print_uint32(ndr, "start_idx", r->in.start_idx);
11361 0 : ndr_print_uint32(ndr, "max_entries", r->in.max_entries);
11362 0 : ndr_print_uint32(ndr, "buf_size", r->in.buf_size);
11363 0 : ndr->depth--;
11364 : }
11365 0 : if (flags & NDR_OUT) {
11366 0 : ndr_print_struct(ndr, "out", "samr_QueryDisplayInfo2");
11367 0 : ndr->depth++;
11368 0 : ndr_print_ptr(ndr, "total_size", r->out.total_size);
11369 0 : ndr->depth++;
11370 0 : ndr_print_uint32(ndr, "total_size", *r->out.total_size);
11371 0 : ndr->depth--;
11372 0 : ndr_print_ptr(ndr, "returned_size", r->out.returned_size);
11373 0 : ndr->depth++;
11374 0 : ndr_print_uint32(ndr, "returned_size", *r->out.returned_size);
11375 0 : ndr->depth--;
11376 0 : ndr_print_ptr(ndr, "info", r->out.info);
11377 0 : ndr->depth++;
11378 0 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
11379 0 : ndr_print_samr_DispInfo(ndr, "info", r->out.info);
11380 0 : ndr->depth--;
11381 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11382 0 : ndr->depth--;
11383 : }
11384 0 : ndr->depth--;
11385 : }
11386 :
11387 40 : static enum ndr_err_code ndr_push_samr_GetDisplayEnumerationIndex2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetDisplayEnumerationIndex2 *r)
11388 : {
11389 40 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11390 40 : if (flags & NDR_IN) {
11391 40 : if (r->in.domain_handle == NULL) {
11392 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11393 : }
11394 40 : if (r->in.name == NULL) {
11395 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11396 : }
11397 40 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11398 40 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
11399 40 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
11400 : }
11401 40 : if (flags & NDR_OUT) {
11402 0 : if (r->out.idx == NULL) {
11403 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11404 : }
11405 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.idx));
11406 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11407 : }
11408 40 : return NDR_ERR_SUCCESS;
11409 : }
11410 :
11411 40 : static enum ndr_err_code ndr_pull_samr_GetDisplayEnumerationIndex2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetDisplayEnumerationIndex2 *r)
11412 : {
11413 40 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
11414 40 : TALLOC_CTX *_mem_save_name_0 = NULL;
11415 40 : TALLOC_CTX *_mem_save_idx_0 = NULL;
11416 40 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11417 40 : if (flags & NDR_IN) {
11418 0 : NDR_ZERO_STRUCT(r->out);
11419 :
11420 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11421 0 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11422 : }
11423 0 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11424 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
11425 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11426 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
11427 0 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
11428 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11429 0 : NDR_PULL_ALLOC(ndr, r->in.name);
11430 : }
11431 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
11432 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, LIBNDR_FLAG_REF_ALLOC);
11433 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
11434 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, LIBNDR_FLAG_REF_ALLOC);
11435 0 : NDR_PULL_ALLOC(ndr, r->out.idx);
11436 0 : NDR_ZERO_STRUCTP(r->out.idx);
11437 : }
11438 40 : if (flags & NDR_OUT) {
11439 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11440 : if (r->in.domain_handle == NULL) {
11441 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11442 : NDR_ZERO_STRUCTP(r->in.domain_handle);
11443 : }
11444 : if (r->in.name == NULL) {
11445 : NDR_PULL_ALLOC(ndr, r->in.name);
11446 : NDR_ZERO_STRUCTP(r->in.name);
11447 : }
11448 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11449 40 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11450 0 : NDR_PULL_ALLOC(ndr, r->out.idx);
11451 : }
11452 40 : _mem_save_idx_0 = NDR_PULL_GET_MEM_CTX(ndr);
11453 40 : NDR_PULL_SET_MEM_CTX(ndr, r->out.idx, LIBNDR_FLAG_REF_ALLOC);
11454 40 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.idx));
11455 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_idx_0, LIBNDR_FLAG_REF_ALLOC);
11456 40 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11457 : }
11458 40 : return NDR_ERR_SUCCESS;
11459 : }
11460 :
11461 0 : _PUBLIC_ void ndr_print_samr_GetDisplayEnumerationIndex2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetDisplayEnumerationIndex2 *r)
11462 : {
11463 0 : ndr_print_struct(ndr, name, "samr_GetDisplayEnumerationIndex2");
11464 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11465 0 : ndr->depth++;
11466 0 : if (flags & NDR_SET_VALUES) {
11467 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11468 : }
11469 0 : if (flags & NDR_IN) {
11470 0 : ndr_print_struct(ndr, "in", "samr_GetDisplayEnumerationIndex2");
11471 0 : ndr->depth++;
11472 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
11473 0 : ndr->depth++;
11474 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
11475 0 : ndr->depth--;
11476 0 : ndr_print_uint16(ndr, "level", r->in.level);
11477 0 : ndr_print_ptr(ndr, "name", r->in.name);
11478 0 : ndr->depth++;
11479 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
11480 0 : ndr->depth--;
11481 0 : ndr->depth--;
11482 : }
11483 0 : if (flags & NDR_OUT) {
11484 0 : ndr_print_struct(ndr, "out", "samr_GetDisplayEnumerationIndex2");
11485 0 : ndr->depth++;
11486 0 : ndr_print_ptr(ndr, "idx", r->out.idx);
11487 0 : ndr->depth++;
11488 0 : ndr_print_uint32(ndr, "idx", *r->out.idx);
11489 0 : ndr->depth--;
11490 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11491 0 : ndr->depth--;
11492 : }
11493 0 : ndr->depth--;
11494 : }
11495 :
11496 2176 : static enum ndr_err_code ndr_push_samr_CreateUser2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_CreateUser2 *r)
11497 : {
11498 2176 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11499 2176 : if (flags & NDR_IN) {
11500 1038 : if (r->in.domain_handle == NULL) {
11501 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11502 : }
11503 1038 : if (r->in.account_name == NULL) {
11504 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11505 : }
11506 1038 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11507 1038 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account_name));
11508 1038 : NDR_CHECK(ndr_push_samr_AcctFlags(ndr, NDR_SCALARS, r->in.acct_flags));
11509 1128 : NDR_CHECK(ndr_push_samr_UserAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
11510 : }
11511 2176 : if (flags & NDR_OUT) {
11512 1138 : if (r->out.user_handle == NULL) {
11513 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11514 : }
11515 1138 : if (r->out.access_granted == NULL) {
11516 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11517 : }
11518 1138 : if (r->out.rid == NULL) {
11519 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11520 : }
11521 1138 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
11522 1138 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.access_granted));
11523 1138 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.rid));
11524 1138 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11525 : }
11526 1978 : return NDR_ERR_SUCCESS;
11527 : }
11528 :
11529 2051 : static enum ndr_err_code ndr_pull_samr_CreateUser2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_CreateUser2 *r)
11530 : {
11531 2051 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
11532 2051 : TALLOC_CTX *_mem_save_account_name_0 = NULL;
11533 2051 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
11534 2051 : TALLOC_CTX *_mem_save_access_granted_0 = NULL;
11535 2051 : TALLOC_CTX *_mem_save_rid_0 = NULL;
11536 2051 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11537 2051 : if (flags & NDR_IN) {
11538 1013 : NDR_ZERO_STRUCT(r->out);
11539 :
11540 1013 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11541 1013 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11542 : }
11543 1013 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11544 1013 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
11545 1013 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11546 1013 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
11547 1013 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11548 1013 : NDR_PULL_ALLOC(ndr, r->in.account_name);
11549 : }
11550 1013 : _mem_save_account_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
11551 1013 : NDR_PULL_SET_MEM_CTX(ndr, r->in.account_name, LIBNDR_FLAG_REF_ALLOC);
11552 1013 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account_name));
11553 1013 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_name_0, LIBNDR_FLAG_REF_ALLOC);
11554 1013 : NDR_CHECK(ndr_pull_samr_AcctFlags(ndr, NDR_SCALARS, &r->in.acct_flags));
11555 1103 : NDR_CHECK(ndr_pull_samr_UserAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
11556 1013 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
11557 1013 : NDR_ZERO_STRUCTP(r->out.user_handle);
11558 1013 : NDR_PULL_ALLOC(ndr, r->out.access_granted);
11559 1013 : NDR_ZERO_STRUCTP(r->out.access_granted);
11560 1013 : NDR_PULL_ALLOC(ndr, r->out.rid);
11561 1013 : NDR_ZERO_STRUCTP(r->out.rid);
11562 : }
11563 2051 : if (flags & NDR_OUT) {
11564 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11565 : if (r->in.domain_handle == NULL) {
11566 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11567 : NDR_ZERO_STRUCTP(r->in.domain_handle);
11568 : }
11569 : if (r->in.account_name == NULL) {
11570 : NDR_PULL_ALLOC(ndr, r->in.account_name);
11571 : NDR_ZERO_STRUCTP(r->in.account_name);
11572 : }
11573 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11574 1038 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11575 138 : NDR_PULL_ALLOC(ndr, r->out.user_handle);
11576 : }
11577 1038 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11578 1038 : NDR_PULL_SET_MEM_CTX(ndr, r->out.user_handle, LIBNDR_FLAG_REF_ALLOC);
11579 1038 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.user_handle));
11580 1038 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
11581 1038 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11582 138 : NDR_PULL_ALLOC(ndr, r->out.access_granted);
11583 : }
11584 1038 : _mem_save_access_granted_0 = NDR_PULL_GET_MEM_CTX(ndr);
11585 1038 : NDR_PULL_SET_MEM_CTX(ndr, r->out.access_granted, LIBNDR_FLAG_REF_ALLOC);
11586 1038 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.access_granted));
11587 1038 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_access_granted_0, LIBNDR_FLAG_REF_ALLOC);
11588 1038 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11589 138 : NDR_PULL_ALLOC(ndr, r->out.rid);
11590 : }
11591 1038 : _mem_save_rid_0 = NDR_PULL_GET_MEM_CTX(ndr);
11592 1038 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rid, LIBNDR_FLAG_REF_ALLOC);
11593 1038 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.rid));
11594 1038 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rid_0, LIBNDR_FLAG_REF_ALLOC);
11595 1038 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11596 : }
11597 1871 : return NDR_ERR_SUCCESS;
11598 : }
11599 :
11600 250 : _PUBLIC_ void ndr_print_samr_CreateUser2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_CreateUser2 *r)
11601 : {
11602 250 : ndr_print_struct(ndr, name, "samr_CreateUser2");
11603 250 : if (r == NULL) { ndr_print_null(ndr); return; }
11604 250 : ndr->depth++;
11605 250 : if (flags & NDR_SET_VALUES) {
11606 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11607 : }
11608 250 : if (flags & NDR_IN) {
11609 0 : ndr_print_struct(ndr, "in", "samr_CreateUser2");
11610 0 : ndr->depth++;
11611 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
11612 0 : ndr->depth++;
11613 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
11614 0 : ndr->depth--;
11615 0 : ndr_print_ptr(ndr, "account_name", r->in.account_name);
11616 0 : ndr->depth++;
11617 0 : ndr_print_lsa_String(ndr, "account_name", r->in.account_name);
11618 0 : ndr->depth--;
11619 0 : ndr_print_samr_AcctFlags(ndr, "acct_flags", r->in.acct_flags);
11620 0 : ndr_print_samr_UserAccessMask(ndr, "access_mask", r->in.access_mask);
11621 0 : ndr->depth--;
11622 : }
11623 250 : if (flags & NDR_OUT) {
11624 250 : ndr_print_struct(ndr, "out", "samr_CreateUser2");
11625 250 : ndr->depth++;
11626 250 : ndr_print_ptr(ndr, "user_handle", r->out.user_handle);
11627 250 : ndr->depth++;
11628 250 : ndr_print_policy_handle(ndr, "user_handle", r->out.user_handle);
11629 250 : ndr->depth--;
11630 250 : ndr_print_ptr(ndr, "access_granted", r->out.access_granted);
11631 250 : ndr->depth++;
11632 250 : ndr_print_uint32(ndr, "access_granted", *r->out.access_granted);
11633 250 : ndr->depth--;
11634 250 : ndr_print_ptr(ndr, "rid", r->out.rid);
11635 250 : ndr->depth++;
11636 250 : ndr_print_uint32(ndr, "rid", *r->out.rid);
11637 250 : ndr->depth--;
11638 250 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11639 250 : ndr->depth--;
11640 : }
11641 250 : ndr->depth--;
11642 : }
11643 :
11644 80 : static enum ndr_err_code ndr_push_samr_QueryDisplayInfo3(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_QueryDisplayInfo3 *r)
11645 : {
11646 80 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11647 80 : if (flags & NDR_IN) {
11648 50 : if (r->in.domain_handle == NULL) {
11649 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11650 : }
11651 50 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11652 50 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->in.level));
11653 50 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.start_idx));
11654 50 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.max_entries));
11655 50 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.buf_size));
11656 : }
11657 80 : if (flags & NDR_OUT) {
11658 30 : if (r->out.total_size == NULL) {
11659 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11660 : }
11661 30 : if (r->out.returned_size == NULL) {
11662 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11663 : }
11664 30 : if (r->out.info == NULL) {
11665 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11666 : }
11667 30 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.total_size));
11668 30 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.returned_size));
11669 30 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info, r->in.level));
11670 30 : NDR_CHECK(ndr_push_samr_DispInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
11671 30 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11672 : }
11673 80 : return NDR_ERR_SUCCESS;
11674 : }
11675 :
11676 80 : static enum ndr_err_code ndr_pull_samr_QueryDisplayInfo3(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_QueryDisplayInfo3 *r)
11677 : {
11678 80 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
11679 80 : TALLOC_CTX *_mem_save_total_size_0 = NULL;
11680 80 : TALLOC_CTX *_mem_save_returned_size_0 = NULL;
11681 80 : TALLOC_CTX *_mem_save_info_0 = NULL;
11682 80 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11683 80 : if (flags & NDR_IN) {
11684 30 : NDR_ZERO_STRUCT(r->out);
11685 :
11686 30 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11687 30 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11688 : }
11689 30 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11690 30 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
11691 30 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
11692 30 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
11693 30 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->in.level));
11694 30 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.start_idx));
11695 30 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.max_entries));
11696 30 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.buf_size));
11697 30 : NDR_PULL_ALLOC(ndr, r->out.total_size);
11698 30 : NDR_ZERO_STRUCTP(r->out.total_size);
11699 30 : NDR_PULL_ALLOC(ndr, r->out.returned_size);
11700 30 : NDR_ZERO_STRUCTP(r->out.returned_size);
11701 30 : NDR_PULL_ALLOC(ndr, r->out.info);
11702 30 : NDR_ZERO_STRUCTP(r->out.info);
11703 : }
11704 80 : if (flags & NDR_OUT) {
11705 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11706 : if (r->in.domain_handle == NULL) {
11707 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
11708 : NDR_ZERO_STRUCTP(r->in.domain_handle);
11709 : }
11710 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11711 50 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11712 0 : NDR_PULL_ALLOC(ndr, r->out.total_size);
11713 : }
11714 50 : _mem_save_total_size_0 = NDR_PULL_GET_MEM_CTX(ndr);
11715 50 : NDR_PULL_SET_MEM_CTX(ndr, r->out.total_size, LIBNDR_FLAG_REF_ALLOC);
11716 50 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.total_size));
11717 50 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_total_size_0, LIBNDR_FLAG_REF_ALLOC);
11718 50 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11719 0 : NDR_PULL_ALLOC(ndr, r->out.returned_size);
11720 : }
11721 50 : _mem_save_returned_size_0 = NDR_PULL_GET_MEM_CTX(ndr);
11722 50 : NDR_PULL_SET_MEM_CTX(ndr, r->out.returned_size, LIBNDR_FLAG_REF_ALLOC);
11723 50 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.returned_size));
11724 50 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_returned_size_0, LIBNDR_FLAG_REF_ALLOC);
11725 50 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11726 0 : NDR_PULL_ALLOC(ndr, r->out.info);
11727 : }
11728 50 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
11729 50 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
11730 50 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info, r->in.level));
11731 50 : NDR_CHECK(ndr_pull_samr_DispInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->out.info));
11732 50 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
11733 50 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11734 : }
11735 80 : return NDR_ERR_SUCCESS;
11736 : }
11737 :
11738 0 : _PUBLIC_ void ndr_print_samr_QueryDisplayInfo3(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_QueryDisplayInfo3 *r)
11739 : {
11740 0 : ndr_print_struct(ndr, name, "samr_QueryDisplayInfo3");
11741 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11742 0 : ndr->depth++;
11743 0 : if (flags & NDR_SET_VALUES) {
11744 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11745 : }
11746 0 : if (flags & NDR_IN) {
11747 0 : ndr_print_struct(ndr, "in", "samr_QueryDisplayInfo3");
11748 0 : ndr->depth++;
11749 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
11750 0 : ndr->depth++;
11751 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
11752 0 : ndr->depth--;
11753 0 : ndr_print_uint16(ndr, "level", r->in.level);
11754 0 : ndr_print_uint32(ndr, "start_idx", r->in.start_idx);
11755 0 : ndr_print_uint32(ndr, "max_entries", r->in.max_entries);
11756 0 : ndr_print_uint32(ndr, "buf_size", r->in.buf_size);
11757 0 : ndr->depth--;
11758 : }
11759 0 : if (flags & NDR_OUT) {
11760 0 : ndr_print_struct(ndr, "out", "samr_QueryDisplayInfo3");
11761 0 : ndr->depth++;
11762 0 : ndr_print_ptr(ndr, "total_size", r->out.total_size);
11763 0 : ndr->depth++;
11764 0 : ndr_print_uint32(ndr, "total_size", *r->out.total_size);
11765 0 : ndr->depth--;
11766 0 : ndr_print_ptr(ndr, "returned_size", r->out.returned_size);
11767 0 : ndr->depth++;
11768 0 : ndr_print_uint32(ndr, "returned_size", *r->out.returned_size);
11769 0 : ndr->depth--;
11770 0 : ndr_print_ptr(ndr, "info", r->out.info);
11771 0 : ndr->depth++;
11772 0 : ndr_print_set_switch_value(ndr, r->out.info, r->in.level);
11773 0 : ndr_print_samr_DispInfo(ndr, "info", r->out.info);
11774 0 : ndr->depth--;
11775 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11776 0 : ndr->depth--;
11777 : }
11778 0 : ndr->depth--;
11779 : }
11780 :
11781 0 : static enum ndr_err_code ndr_push_samr_AddMultipleMembersToAlias(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_AddMultipleMembersToAlias *r)
11782 : {
11783 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11784 0 : if (flags & NDR_IN) {
11785 0 : if (r->in.alias_handle == NULL) {
11786 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11787 : }
11788 0 : if (r->in.sids == NULL) {
11789 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11790 : }
11791 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
11792 0 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
11793 : }
11794 0 : if (flags & NDR_OUT) {
11795 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11796 : }
11797 0 : return NDR_ERR_SUCCESS;
11798 : }
11799 :
11800 0 : static enum ndr_err_code ndr_pull_samr_AddMultipleMembersToAlias(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_AddMultipleMembersToAlias *r)
11801 : {
11802 0 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
11803 0 : TALLOC_CTX *_mem_save_sids_0 = NULL;
11804 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11805 0 : if (flags & NDR_IN) {
11806 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11807 0 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
11808 : }
11809 0 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11810 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
11811 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
11812 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
11813 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11814 0 : NDR_PULL_ALLOC(ndr, r->in.sids);
11815 : }
11816 0 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
11817 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
11818 0 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
11819 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
11820 : }
11821 0 : if (flags & NDR_OUT) {
11822 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11823 : if (r->in.alias_handle == NULL) {
11824 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
11825 : NDR_ZERO_STRUCTP(r->in.alias_handle);
11826 : }
11827 : if (r->in.sids == NULL) {
11828 : NDR_PULL_ALLOC(ndr, r->in.sids);
11829 : NDR_ZERO_STRUCTP(r->in.sids);
11830 : }
11831 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11832 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11833 : }
11834 0 : return NDR_ERR_SUCCESS;
11835 : }
11836 :
11837 0 : _PUBLIC_ void ndr_print_samr_AddMultipleMembersToAlias(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_AddMultipleMembersToAlias *r)
11838 : {
11839 0 : ndr_print_struct(ndr, name, "samr_AddMultipleMembersToAlias");
11840 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11841 0 : ndr->depth++;
11842 0 : if (flags & NDR_SET_VALUES) {
11843 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11844 : }
11845 0 : if (flags & NDR_IN) {
11846 0 : ndr_print_struct(ndr, "in", "samr_AddMultipleMembersToAlias");
11847 0 : ndr->depth++;
11848 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
11849 0 : ndr->depth++;
11850 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
11851 0 : ndr->depth--;
11852 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
11853 0 : ndr->depth++;
11854 0 : ndr_print_lsa_SidArray(ndr, "sids", r->in.sids);
11855 0 : ndr->depth--;
11856 0 : ndr->depth--;
11857 : }
11858 0 : if (flags & NDR_OUT) {
11859 0 : ndr_print_struct(ndr, "out", "samr_AddMultipleMembersToAlias");
11860 0 : ndr->depth++;
11861 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11862 0 : ndr->depth--;
11863 : }
11864 0 : ndr->depth--;
11865 : }
11866 :
11867 0 : static enum ndr_err_code ndr_push_samr_RemoveMultipleMembersFromAlias(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_RemoveMultipleMembersFromAlias *r)
11868 : {
11869 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11870 0 : if (flags & NDR_IN) {
11871 0 : if (r->in.alias_handle == NULL) {
11872 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11873 : }
11874 0 : if (r->in.sids == NULL) {
11875 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11876 : }
11877 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
11878 0 : NDR_CHECK(ndr_push_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
11879 : }
11880 0 : if (flags & NDR_OUT) {
11881 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11882 : }
11883 0 : return NDR_ERR_SUCCESS;
11884 : }
11885 :
11886 0 : static enum ndr_err_code ndr_pull_samr_RemoveMultipleMembersFromAlias(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_RemoveMultipleMembersFromAlias *r)
11887 : {
11888 0 : TALLOC_CTX *_mem_save_alias_handle_0 = NULL;
11889 0 : TALLOC_CTX *_mem_save_sids_0 = NULL;
11890 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11891 0 : if (flags & NDR_IN) {
11892 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11893 0 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
11894 : }
11895 0 : _mem_save_alias_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
11896 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.alias_handle, LIBNDR_FLAG_REF_ALLOC);
11897 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.alias_handle));
11898 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_alias_handle_0, LIBNDR_FLAG_REF_ALLOC);
11899 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
11900 0 : NDR_PULL_ALLOC(ndr, r->in.sids);
11901 : }
11902 0 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
11903 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.sids, LIBNDR_FLAG_REF_ALLOC);
11904 0 : NDR_CHECK(ndr_pull_lsa_SidArray(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.sids));
11905 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, LIBNDR_FLAG_REF_ALLOC);
11906 : }
11907 0 : if (flags & NDR_OUT) {
11908 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
11909 : if (r->in.alias_handle == NULL) {
11910 : NDR_PULL_ALLOC(ndr, r->in.alias_handle);
11911 : NDR_ZERO_STRUCTP(r->in.alias_handle);
11912 : }
11913 : if (r->in.sids == NULL) {
11914 : NDR_PULL_ALLOC(ndr, r->in.sids);
11915 : NDR_ZERO_STRUCTP(r->in.sids);
11916 : }
11917 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
11918 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
11919 : }
11920 0 : return NDR_ERR_SUCCESS;
11921 : }
11922 :
11923 0 : _PUBLIC_ void ndr_print_samr_RemoveMultipleMembersFromAlias(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_RemoveMultipleMembersFromAlias *r)
11924 : {
11925 0 : ndr_print_struct(ndr, name, "samr_RemoveMultipleMembersFromAlias");
11926 0 : if (r == NULL) { ndr_print_null(ndr); return; }
11927 0 : ndr->depth++;
11928 0 : if (flags & NDR_SET_VALUES) {
11929 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
11930 : }
11931 0 : if (flags & NDR_IN) {
11932 0 : ndr_print_struct(ndr, "in", "samr_RemoveMultipleMembersFromAlias");
11933 0 : ndr->depth++;
11934 0 : ndr_print_ptr(ndr, "alias_handle", r->in.alias_handle);
11935 0 : ndr->depth++;
11936 0 : ndr_print_policy_handle(ndr, "alias_handle", r->in.alias_handle);
11937 0 : ndr->depth--;
11938 0 : ndr_print_ptr(ndr, "sids", r->in.sids);
11939 0 : ndr->depth++;
11940 0 : ndr_print_lsa_SidArray(ndr, "sids", r->in.sids);
11941 0 : ndr->depth--;
11942 0 : ndr->depth--;
11943 : }
11944 0 : if (flags & NDR_OUT) {
11945 0 : ndr_print_struct(ndr, "out", "samr_RemoveMultipleMembersFromAlias");
11946 0 : ndr->depth++;
11947 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
11948 0 : ndr->depth--;
11949 : }
11950 0 : ndr->depth--;
11951 : }
11952 :
11953 84 : static enum ndr_err_code ndr_push_samr_OemChangePasswordUser2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_OemChangePasswordUser2 *r)
11954 : {
11955 84 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
11956 84 : if (flags & NDR_IN) {
11957 56 : if (r->in.account == NULL) {
11958 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
11959 : }
11960 56 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server));
11961 56 : if (r->in.server) {
11962 56 : NDR_CHECK(ndr_push_lsa_AsciiString(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
11963 : }
11964 56 : NDR_CHECK(ndr_push_lsa_AsciiString(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
11965 56 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.password));
11966 56 : if (r->in.password) {
11967 52 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, r->in.password));
11968 : }
11969 56 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.hash));
11970 56 : if (r->in.hash) {
11971 48 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.hash));
11972 : }
11973 : }
11974 84 : if (flags & NDR_OUT) {
11975 28 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
11976 : }
11977 84 : return NDR_ERR_SUCCESS;
11978 : }
11979 :
11980 84 : static enum ndr_err_code ndr_pull_samr_OemChangePasswordUser2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_OemChangePasswordUser2 *r)
11981 : {
11982 0 : uint32_t _ptr_server;
11983 0 : uint32_t _ptr_password;
11984 0 : uint32_t _ptr_hash;
11985 84 : TALLOC_CTX *_mem_save_server_0 = NULL;
11986 84 : TALLOC_CTX *_mem_save_account_0 = NULL;
11987 84 : TALLOC_CTX *_mem_save_password_0 = NULL;
11988 84 : TALLOC_CTX *_mem_save_hash_0 = NULL;
11989 84 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
11990 84 : if (flags & NDR_IN) {
11991 28 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server));
11992 28 : if (_ptr_server) {
11993 28 : NDR_PULL_ALLOC(ndr, r->in.server);
11994 : } else {
11995 0 : r->in.server = NULL;
11996 : }
11997 28 : if (r->in.server) {
11998 28 : _mem_save_server_0 = NDR_PULL_GET_MEM_CTX(ndr);
11999 28 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server, 0);
12000 28 : NDR_CHECK(ndr_pull_lsa_AsciiString(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
12001 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_0, 0);
12002 : }
12003 28 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12004 28 : NDR_PULL_ALLOC(ndr, r->in.account);
12005 : }
12006 28 : _mem_save_account_0 = NDR_PULL_GET_MEM_CTX(ndr);
12007 28 : NDR_PULL_SET_MEM_CTX(ndr, r->in.account, LIBNDR_FLAG_REF_ALLOC);
12008 28 : NDR_CHECK(ndr_pull_lsa_AsciiString(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
12009 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_0, LIBNDR_FLAG_REF_ALLOC);
12010 28 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_password));
12011 28 : if (_ptr_password) {
12012 28 : NDR_PULL_ALLOC(ndr, r->in.password);
12013 : } else {
12014 0 : r->in.password = NULL;
12015 : }
12016 28 : if (r->in.password) {
12017 28 : _mem_save_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
12018 28 : NDR_PULL_SET_MEM_CTX(ndr, r->in.password, 0);
12019 28 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, r->in.password));
12020 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_password_0, 0);
12021 : }
12022 28 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_hash));
12023 28 : if (_ptr_hash) {
12024 28 : NDR_PULL_ALLOC(ndr, r->in.hash);
12025 : } else {
12026 0 : r->in.hash = NULL;
12027 : }
12028 28 : if (r->in.hash) {
12029 28 : _mem_save_hash_0 = NDR_PULL_GET_MEM_CTX(ndr);
12030 28 : NDR_PULL_SET_MEM_CTX(ndr, r->in.hash, 0);
12031 28 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.hash));
12032 28 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_hash_0, 0);
12033 : }
12034 : }
12035 84 : if (flags & NDR_OUT) {
12036 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12037 : if (r->in.account == NULL) {
12038 : NDR_PULL_ALLOC(ndr, r->in.account);
12039 : NDR_ZERO_STRUCTP(r->in.account);
12040 : }
12041 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12042 56 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12043 : }
12044 84 : return NDR_ERR_SUCCESS;
12045 : }
12046 :
12047 0 : _PUBLIC_ void ndr_print_samr_OemChangePasswordUser2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_OemChangePasswordUser2 *r)
12048 : {
12049 0 : ndr_print_struct(ndr, name, "samr_OemChangePasswordUser2");
12050 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12051 0 : ndr->depth++;
12052 0 : if (flags & NDR_SET_VALUES) {
12053 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12054 : }
12055 0 : if (flags & NDR_IN) {
12056 0 : ndr_print_struct(ndr, "in", "samr_OemChangePasswordUser2");
12057 0 : ndr->depth++;
12058 0 : ndr_print_ptr(ndr, "server", r->in.server);
12059 0 : ndr->depth++;
12060 0 : if (r->in.server) {
12061 0 : ndr_print_lsa_AsciiString(ndr, "server", r->in.server);
12062 : }
12063 0 : ndr->depth--;
12064 0 : ndr_print_ptr(ndr, "account", r->in.account);
12065 0 : ndr->depth++;
12066 0 : ndr_print_lsa_AsciiString(ndr, "account", r->in.account);
12067 0 : ndr->depth--;
12068 0 : ndr_print_ptr(ndr, "password", r->in.password);
12069 0 : ndr->depth++;
12070 0 : if (r->in.password) {
12071 0 : ndr_print_samr_CryptPassword(ndr, "password", r->in.password);
12072 : }
12073 0 : ndr->depth--;
12074 0 : ndr_print_ptr(ndr, "hash", r->in.hash);
12075 0 : ndr->depth++;
12076 0 : if (r->in.hash) {
12077 0 : ndr_print_samr_Password(ndr, "hash", r->in.hash);
12078 : }
12079 0 : ndr->depth--;
12080 0 : ndr->depth--;
12081 : }
12082 0 : if (flags & NDR_OUT) {
12083 0 : ndr_print_struct(ndr, "out", "samr_OemChangePasswordUser2");
12084 0 : ndr->depth++;
12085 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12086 0 : ndr->depth--;
12087 : }
12088 0 : ndr->depth--;
12089 : }
12090 :
12091 356 : static enum ndr_err_code ndr_push_samr_ChangePasswordUser2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_ChangePasswordUser2 *r)
12092 : {
12093 356 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12094 356 : if (flags & NDR_IN) {
12095 183 : if (r->in.account == NULL) {
12096 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12097 : }
12098 183 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server));
12099 183 : if (r->in.server) {
12100 183 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
12101 : }
12102 183 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
12103 183 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.nt_password));
12104 183 : if (r->in.nt_password) {
12105 176 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, r->in.nt_password));
12106 : }
12107 183 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.nt_verifier));
12108 183 : if (r->in.nt_verifier) {
12109 176 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.nt_verifier));
12110 : }
12111 183 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.lm_change));
12112 183 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.lm_password));
12113 183 : if (r->in.lm_password) {
12114 164 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, r->in.lm_password));
12115 : }
12116 183 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.lm_verifier));
12117 183 : if (r->in.lm_verifier) {
12118 164 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.lm_verifier));
12119 : }
12120 : }
12121 356 : if (flags & NDR_OUT) {
12122 173 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12123 : }
12124 356 : return NDR_ERR_SUCCESS;
12125 : }
12126 :
12127 356 : static enum ndr_err_code ndr_pull_samr_ChangePasswordUser2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_ChangePasswordUser2 *r)
12128 : {
12129 0 : uint32_t _ptr_server;
12130 0 : uint32_t _ptr_nt_password;
12131 0 : uint32_t _ptr_nt_verifier;
12132 0 : uint32_t _ptr_lm_password;
12133 0 : uint32_t _ptr_lm_verifier;
12134 356 : TALLOC_CTX *_mem_save_server_0 = NULL;
12135 356 : TALLOC_CTX *_mem_save_account_0 = NULL;
12136 356 : TALLOC_CTX *_mem_save_nt_password_0 = NULL;
12137 356 : TALLOC_CTX *_mem_save_nt_verifier_0 = NULL;
12138 356 : TALLOC_CTX *_mem_save_lm_password_0 = NULL;
12139 356 : TALLOC_CTX *_mem_save_lm_verifier_0 = NULL;
12140 356 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12141 356 : if (flags & NDR_IN) {
12142 173 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server));
12143 173 : if (_ptr_server) {
12144 173 : NDR_PULL_ALLOC(ndr, r->in.server);
12145 : } else {
12146 0 : r->in.server = NULL;
12147 : }
12148 173 : if (r->in.server) {
12149 173 : _mem_save_server_0 = NDR_PULL_GET_MEM_CTX(ndr);
12150 173 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server, 0);
12151 173 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
12152 173 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_0, 0);
12153 : }
12154 173 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12155 173 : NDR_PULL_ALLOC(ndr, r->in.account);
12156 : }
12157 173 : _mem_save_account_0 = NDR_PULL_GET_MEM_CTX(ndr);
12158 173 : NDR_PULL_SET_MEM_CTX(ndr, r->in.account, LIBNDR_FLAG_REF_ALLOC);
12159 173 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
12160 173 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_0, LIBNDR_FLAG_REF_ALLOC);
12161 173 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_nt_password));
12162 173 : if (_ptr_nt_password) {
12163 170 : NDR_PULL_ALLOC(ndr, r->in.nt_password);
12164 : } else {
12165 3 : r->in.nt_password = NULL;
12166 : }
12167 173 : if (r->in.nt_password) {
12168 170 : _mem_save_nt_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
12169 170 : NDR_PULL_SET_MEM_CTX(ndr, r->in.nt_password, 0);
12170 170 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, r->in.nt_password));
12171 170 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_nt_password_0, 0);
12172 : }
12173 173 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_nt_verifier));
12174 173 : if (_ptr_nt_verifier) {
12175 170 : NDR_PULL_ALLOC(ndr, r->in.nt_verifier);
12176 : } else {
12177 3 : r->in.nt_verifier = NULL;
12178 : }
12179 173 : if (r->in.nt_verifier) {
12180 170 : _mem_save_nt_verifier_0 = NDR_PULL_GET_MEM_CTX(ndr);
12181 170 : NDR_PULL_SET_MEM_CTX(ndr, r->in.nt_verifier, 0);
12182 170 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.nt_verifier));
12183 170 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_nt_verifier_0, 0);
12184 : }
12185 173 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.lm_change));
12186 173 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_lm_password));
12187 173 : if (_ptr_lm_password) {
12188 158 : NDR_PULL_ALLOC(ndr, r->in.lm_password);
12189 : } else {
12190 15 : r->in.lm_password = NULL;
12191 : }
12192 173 : if (r->in.lm_password) {
12193 158 : _mem_save_lm_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
12194 158 : NDR_PULL_SET_MEM_CTX(ndr, r->in.lm_password, 0);
12195 158 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, r->in.lm_password));
12196 158 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_lm_password_0, 0);
12197 : }
12198 173 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_lm_verifier));
12199 173 : if (_ptr_lm_verifier) {
12200 158 : NDR_PULL_ALLOC(ndr, r->in.lm_verifier);
12201 : } else {
12202 15 : r->in.lm_verifier = NULL;
12203 : }
12204 173 : if (r->in.lm_verifier) {
12205 158 : _mem_save_lm_verifier_0 = NDR_PULL_GET_MEM_CTX(ndr);
12206 158 : NDR_PULL_SET_MEM_CTX(ndr, r->in.lm_verifier, 0);
12207 158 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.lm_verifier));
12208 158 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_lm_verifier_0, 0);
12209 : }
12210 : }
12211 356 : if (flags & NDR_OUT) {
12212 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12213 : if (r->in.account == NULL) {
12214 : NDR_PULL_ALLOC(ndr, r->in.account);
12215 : NDR_ZERO_STRUCTP(r->in.account);
12216 : }
12217 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12218 183 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12219 : }
12220 356 : return NDR_ERR_SUCCESS;
12221 : }
12222 :
12223 0 : _PUBLIC_ void ndr_print_samr_ChangePasswordUser2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_ChangePasswordUser2 *r)
12224 : {
12225 0 : ndr_print_struct(ndr, name, "samr_ChangePasswordUser2");
12226 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12227 0 : ndr->depth++;
12228 0 : if (flags & NDR_SET_VALUES) {
12229 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12230 : }
12231 0 : if (flags & NDR_IN) {
12232 0 : ndr_print_struct(ndr, "in", "samr_ChangePasswordUser2");
12233 0 : ndr->depth++;
12234 0 : ndr_print_ptr(ndr, "server", r->in.server);
12235 0 : ndr->depth++;
12236 0 : if (r->in.server) {
12237 0 : ndr_print_lsa_String(ndr, "server", r->in.server);
12238 : }
12239 0 : ndr->depth--;
12240 0 : ndr_print_ptr(ndr, "account", r->in.account);
12241 0 : ndr->depth++;
12242 0 : ndr_print_lsa_String(ndr, "account", r->in.account);
12243 0 : ndr->depth--;
12244 0 : ndr_print_ptr(ndr, "nt_password", r->in.nt_password);
12245 0 : ndr->depth++;
12246 0 : if (r->in.nt_password) {
12247 0 : ndr_print_samr_CryptPassword(ndr, "nt_password", r->in.nt_password);
12248 : }
12249 0 : ndr->depth--;
12250 0 : ndr_print_ptr(ndr, "nt_verifier", r->in.nt_verifier);
12251 0 : ndr->depth++;
12252 0 : if (r->in.nt_verifier) {
12253 0 : ndr_print_samr_Password(ndr, "nt_verifier", r->in.nt_verifier);
12254 : }
12255 0 : ndr->depth--;
12256 0 : ndr_print_uint8(ndr, "lm_change", r->in.lm_change);
12257 0 : ndr_print_ptr(ndr, "lm_password", r->in.lm_password);
12258 0 : ndr->depth++;
12259 0 : if (r->in.lm_password) {
12260 0 : ndr_print_samr_CryptPassword(ndr, "lm_password", r->in.lm_password);
12261 : }
12262 0 : ndr->depth--;
12263 0 : ndr_print_ptr(ndr, "lm_verifier", r->in.lm_verifier);
12264 0 : ndr->depth++;
12265 0 : if (r->in.lm_verifier) {
12266 0 : ndr_print_samr_Password(ndr, "lm_verifier", r->in.lm_verifier);
12267 : }
12268 0 : ndr->depth--;
12269 0 : ndr->depth--;
12270 : }
12271 0 : if (flags & NDR_OUT) {
12272 0 : ndr_print_struct(ndr, "out", "samr_ChangePasswordUser2");
12273 0 : ndr->depth++;
12274 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12275 0 : ndr->depth--;
12276 : }
12277 0 : ndr->depth--;
12278 : }
12279 :
12280 8442 : static enum ndr_err_code ndr_push_samr_GetDomPwInfo(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetDomPwInfo *r)
12281 : {
12282 8442 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12283 8442 : if (flags & NDR_IN) {
12284 3996 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.domain_name));
12285 3996 : if (r->in.domain_name) {
12286 3996 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.domain_name));
12287 : }
12288 : }
12289 8442 : if (flags & NDR_OUT) {
12290 4446 : if (r->out.info == NULL) {
12291 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12292 : }
12293 4446 : NDR_CHECK(ndr_push_samr_PwInfo(ndr, NDR_SCALARS, r->out.info));
12294 4446 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12295 : }
12296 7122 : return NDR_ERR_SUCCESS;
12297 : }
12298 :
12299 7722 : static enum ndr_err_code ndr_pull_samr_GetDomPwInfo(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetDomPwInfo *r)
12300 : {
12301 1200 : uint32_t _ptr_domain_name;
12302 7722 : TALLOC_CTX *_mem_save_domain_name_0 = NULL;
12303 7722 : TALLOC_CTX *_mem_save_info_0 = NULL;
12304 7722 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12305 7722 : if (flags & NDR_IN) {
12306 3726 : NDR_ZERO_STRUCT(r->out);
12307 :
12308 3726 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_domain_name));
12309 3726 : if (_ptr_domain_name) {
12310 3726 : NDR_PULL_ALLOC(ndr, r->in.domain_name);
12311 : } else {
12312 0 : r->in.domain_name = NULL;
12313 : }
12314 3726 : if (r->in.domain_name) {
12315 3726 : _mem_save_domain_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
12316 3726 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_name, 0);
12317 3726 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.domain_name));
12318 3726 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_name_0, 0);
12319 : }
12320 3726 : NDR_PULL_ALLOC(ndr, r->out.info);
12321 3726 : NDR_ZERO_STRUCTP(r->out.info);
12322 : }
12323 7722 : if (flags & NDR_OUT) {
12324 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12325 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12326 3996 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12327 720 : NDR_PULL_ALLOC(ndr, r->out.info);
12328 : }
12329 3996 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
12330 3996 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info, LIBNDR_FLAG_REF_ALLOC);
12331 3996 : NDR_CHECK(ndr_pull_samr_PwInfo(ndr, NDR_SCALARS, r->out.info));
12332 3996 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
12333 3996 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12334 : }
12335 6522 : return NDR_ERR_SUCCESS;
12336 : }
12337 :
12338 1440 : _PUBLIC_ void ndr_print_samr_GetDomPwInfo(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetDomPwInfo *r)
12339 : {
12340 1440 : ndr_print_struct(ndr, name, "samr_GetDomPwInfo");
12341 1440 : if (r == NULL) { ndr_print_null(ndr); return; }
12342 1440 : ndr->depth++;
12343 1440 : if (flags & NDR_SET_VALUES) {
12344 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12345 : }
12346 1440 : if (flags & NDR_IN) {
12347 0 : ndr_print_struct(ndr, "in", "samr_GetDomPwInfo");
12348 0 : ndr->depth++;
12349 0 : ndr_print_ptr(ndr, "domain_name", r->in.domain_name);
12350 0 : ndr->depth++;
12351 0 : if (r->in.domain_name) {
12352 0 : ndr_print_lsa_String(ndr, "domain_name", r->in.domain_name);
12353 : }
12354 0 : ndr->depth--;
12355 0 : ndr->depth--;
12356 : }
12357 1440 : if (flags & NDR_OUT) {
12358 1440 : ndr_print_struct(ndr, "out", "samr_GetDomPwInfo");
12359 1440 : ndr->depth++;
12360 1440 : ndr_print_ptr(ndr, "info", r->out.info);
12361 1440 : ndr->depth++;
12362 1440 : ndr_print_samr_PwInfo(ndr, "info", r->out.info);
12363 1440 : ndr->depth--;
12364 1440 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12365 1440 : ndr->depth--;
12366 : }
12367 1440 : ndr->depth--;
12368 : }
12369 :
12370 2166 : static enum ndr_err_code ndr_push_samr_Connect2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Connect2 *r)
12371 : {
12372 2166 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12373 2166 : if (flags & NDR_IN) {
12374 874 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
12375 874 : if (r->in.system_name) {
12376 277 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
12377 277 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
12378 277 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
12379 277 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.system_name, ndr_charset_length(r->in.system_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
12380 : }
12381 874 : NDR_CHECK(ndr_push_samr_ConnectAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
12382 : }
12383 2166 : if (flags & NDR_OUT) {
12384 1292 : if (r->out.connect_handle == NULL) {
12385 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12386 : }
12387 1292 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
12388 1292 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12389 : }
12390 2162 : return NDR_ERR_SUCCESS;
12391 : }
12392 :
12393 2166 : static enum ndr_err_code ndr_pull_samr_Connect2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Connect2 *r)
12394 : {
12395 4 : uint32_t _ptr_system_name;
12396 2166 : uint32_t size_system_name_1 = 0;
12397 2166 : uint32_t length_system_name_1 = 0;
12398 2166 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
12399 2166 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
12400 2166 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12401 2166 : if (flags & NDR_IN) {
12402 1292 : NDR_ZERO_STRUCT(r->out);
12403 :
12404 1292 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
12405 1292 : if (_ptr_system_name) {
12406 743 : NDR_PULL_ALLOC(ndr, r->in.system_name);
12407 : } else {
12408 549 : r->in.system_name = NULL;
12409 : }
12410 1292 : if (r->in.system_name) {
12411 743 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
12412 743 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
12413 743 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.system_name));
12414 743 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.system_name));
12415 743 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.system_name, &size_system_name_1));
12416 743 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.system_name, &length_system_name_1));
12417 743 : if (length_system_name_1 > size_system_name_1) {
12418 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_system_name_1, length_system_name_1);
12419 : }
12420 743 : NDR_CHECK(ndr_check_string_terminator(ndr, length_system_name_1, sizeof(uint16_t)));
12421 743 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.system_name, length_system_name_1, sizeof(uint16_t), CH_UTF16));
12422 743 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
12423 : }
12424 1296 : NDR_CHECK(ndr_pull_samr_ConnectAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
12425 1292 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
12426 1292 : NDR_ZERO_STRUCTP(r->out.connect_handle);
12427 : }
12428 2166 : if (flags & NDR_OUT) {
12429 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12430 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12431 874 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12432 712 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
12433 : }
12434 874 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12435 874 : NDR_PULL_SET_MEM_CTX(ndr, r->out.connect_handle, LIBNDR_FLAG_REF_ALLOC);
12436 874 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
12437 874 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
12438 874 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12439 : }
12440 2162 : return NDR_ERR_SUCCESS;
12441 : }
12442 :
12443 0 : _PUBLIC_ void ndr_print_samr_Connect2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Connect2 *r)
12444 : {
12445 0 : ndr_print_struct(ndr, name, "samr_Connect2");
12446 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12447 0 : ndr->depth++;
12448 0 : if (flags & NDR_SET_VALUES) {
12449 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12450 : }
12451 0 : if (flags & NDR_IN) {
12452 0 : ndr_print_struct(ndr, "in", "samr_Connect2");
12453 0 : ndr->depth++;
12454 0 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
12455 0 : ndr->depth++;
12456 0 : if (r->in.system_name) {
12457 0 : ndr_print_string(ndr, "system_name", r->in.system_name);
12458 : }
12459 0 : ndr->depth--;
12460 0 : ndr_print_samr_ConnectAccessMask(ndr, "access_mask", r->in.access_mask);
12461 0 : ndr->depth--;
12462 : }
12463 0 : if (flags & NDR_OUT) {
12464 0 : ndr_print_struct(ndr, "out", "samr_Connect2");
12465 0 : ndr->depth++;
12466 0 : ndr_print_ptr(ndr, "connect_handle", r->out.connect_handle);
12467 0 : ndr->depth++;
12468 0 : ndr_print_policy_handle(ndr, "connect_handle", r->out.connect_handle);
12469 0 : ndr->depth--;
12470 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12471 0 : ndr->depth--;
12472 : }
12473 0 : ndr->depth--;
12474 : }
12475 :
12476 4028 : _PUBLIC_ enum ndr_err_code ndr_push_samr_SetUserInfo2(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetUserInfo2 *r)
12477 : {
12478 4028 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12479 4028 : if (flags & NDR_IN) {
12480 2034 : if (r->in.user_handle == NULL) {
12481 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12482 : }
12483 2034 : if (r->in.info == NULL) {
12484 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12485 : }
12486 2034 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
12487 2124 : NDR_CHECK(ndr_push_samr_UserInfoLevel(ndr, NDR_SCALARS, r->in.level));
12488 2034 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info, r->in.level));
12489 2034 : NDR_CHECK(ndr_push_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
12490 : }
12491 4028 : if (flags & NDR_OUT) {
12492 1994 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12493 : }
12494 3830 : return NDR_ERR_SUCCESS;
12495 : }
12496 :
12497 3910 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_SetUserInfo2(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetUserInfo2 *r)
12498 : {
12499 3910 : TALLOC_CTX *_mem_save_user_handle_0 = NULL;
12500 3910 : TALLOC_CTX *_mem_save_info_0 = NULL;
12501 3910 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12502 3910 : if (flags & NDR_IN) {
12503 1874 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12504 1874 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
12505 : }
12506 1874 : _mem_save_user_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12507 1874 : NDR_PULL_SET_MEM_CTX(ndr, r->in.user_handle, LIBNDR_FLAG_REF_ALLOC);
12508 1874 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.user_handle));
12509 1874 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_handle_0, LIBNDR_FLAG_REF_ALLOC);
12510 1966 : NDR_CHECK(ndr_pull_samr_UserInfoLevel(ndr, NDR_SCALARS, &r->in.level));
12511 1874 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12512 1874 : NDR_PULL_ALLOC(ndr, r->in.info);
12513 : }
12514 1874 : _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
12515 1874 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info, LIBNDR_FLAG_REF_ALLOC);
12516 1874 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info, r->in.level));
12517 1874 : NDR_CHECK(ndr_pull_samr_UserInfo(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.info));
12518 1874 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, LIBNDR_FLAG_REF_ALLOC);
12519 : }
12520 3910 : if (flags & NDR_OUT) {
12521 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12522 : if (r->in.user_handle == NULL) {
12523 : NDR_PULL_ALLOC(ndr, r->in.user_handle);
12524 : NDR_ZERO_STRUCTP(r->in.user_handle);
12525 : }
12526 : if (r->in.info == NULL) {
12527 : NDR_PULL_ALLOC(ndr, r->in.info);
12528 : NDR_ZERO_STRUCTP(r->in.info);
12529 : }
12530 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12531 2036 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12532 : }
12533 3726 : return NDR_ERR_SUCCESS;
12534 : }
12535 :
12536 248 : _PUBLIC_ void ndr_print_samr_SetUserInfo2(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetUserInfo2 *r)
12537 : {
12538 248 : ndr_print_struct(ndr, name, "samr_SetUserInfo2");
12539 248 : if (r == NULL) { ndr_print_null(ndr); return; }
12540 248 : ndr->depth++;
12541 248 : if (flags & NDR_SET_VALUES) {
12542 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12543 : }
12544 248 : if (flags & NDR_IN) {
12545 2 : ndr_print_struct(ndr, "in", "samr_SetUserInfo2");
12546 2 : ndr->depth++;
12547 2 : ndr_print_ptr(ndr, "user_handle", r->in.user_handle);
12548 2 : ndr->depth++;
12549 2 : ndr_print_policy_handle(ndr, "user_handle", r->in.user_handle);
12550 2 : ndr->depth--;
12551 2 : ndr_print_samr_UserInfoLevel(ndr, "level", r->in.level);
12552 2 : ndr_print_ptr(ndr, "info", r->in.info);
12553 2 : ndr->depth++;
12554 2 : ndr_print_set_switch_value(ndr, r->in.info, r->in.level);
12555 2 : ndr_print_samr_UserInfo(ndr, "info", r->in.info);
12556 2 : ndr->depth--;
12557 2 : ndr->depth--;
12558 : }
12559 248 : if (flags & NDR_OUT) {
12560 246 : ndr_print_struct(ndr, "out", "samr_SetUserInfo2");
12561 246 : ndr->depth++;
12562 246 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12563 246 : ndr->depth--;
12564 : }
12565 248 : ndr->depth--;
12566 : }
12567 :
12568 0 : static enum ndr_err_code ndr_push_samr_SetBootKeyInformation(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetBootKeyInformation *r)
12569 : {
12570 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12571 0 : if (flags & NDR_IN) {
12572 0 : if (r->in.connect_handle == NULL) {
12573 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12574 : }
12575 0 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
12576 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown1));
12577 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown2));
12578 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown3));
12579 : }
12580 0 : if (flags & NDR_OUT) {
12581 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12582 : }
12583 0 : return NDR_ERR_SUCCESS;
12584 : }
12585 :
12586 0 : static enum ndr_err_code ndr_pull_samr_SetBootKeyInformation(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetBootKeyInformation *r)
12587 : {
12588 0 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
12589 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12590 0 : if (flags & NDR_IN) {
12591 0 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12592 0 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
12593 : }
12594 0 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12595 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.connect_handle, LIBNDR_FLAG_REF_ALLOC);
12596 0 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.connect_handle));
12597 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
12598 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown1));
12599 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown2));
12600 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown3));
12601 : }
12602 0 : if (flags & NDR_OUT) {
12603 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12604 : if (r->in.connect_handle == NULL) {
12605 : NDR_PULL_ALLOC(ndr, r->in.connect_handle);
12606 : NDR_ZERO_STRUCTP(r->in.connect_handle);
12607 : }
12608 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12609 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12610 : }
12611 0 : return NDR_ERR_SUCCESS;
12612 : }
12613 :
12614 0 : _PUBLIC_ void ndr_print_samr_SetBootKeyInformation(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetBootKeyInformation *r)
12615 : {
12616 0 : ndr_print_struct(ndr, name, "samr_SetBootKeyInformation");
12617 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12618 0 : ndr->depth++;
12619 0 : if (flags & NDR_SET_VALUES) {
12620 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12621 : }
12622 0 : if (flags & NDR_IN) {
12623 0 : ndr_print_struct(ndr, "in", "samr_SetBootKeyInformation");
12624 0 : ndr->depth++;
12625 0 : ndr_print_ptr(ndr, "connect_handle", r->in.connect_handle);
12626 0 : ndr->depth++;
12627 0 : ndr_print_policy_handle(ndr, "connect_handle", r->in.connect_handle);
12628 0 : ndr->depth--;
12629 0 : ndr_print_uint32(ndr, "unknown1", r->in.unknown1);
12630 0 : ndr_print_uint32(ndr, "unknown2", r->in.unknown2);
12631 0 : ndr_print_uint32(ndr, "unknown3", r->in.unknown3);
12632 0 : ndr->depth--;
12633 : }
12634 0 : if (flags & NDR_OUT) {
12635 0 : ndr_print_struct(ndr, "out", "samr_SetBootKeyInformation");
12636 0 : ndr->depth++;
12637 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12638 0 : ndr->depth--;
12639 : }
12640 0 : ndr->depth--;
12641 : }
12642 :
12643 16 : static enum ndr_err_code ndr_push_samr_GetBootKeyInformation(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_GetBootKeyInformation *r)
12644 : {
12645 16 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12646 16 : if (flags & NDR_IN) {
12647 10 : if (r->in.domain_handle == NULL) {
12648 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12649 : }
12650 10 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
12651 : }
12652 16 : if (flags & NDR_OUT) {
12653 6 : if (r->out.unknown == NULL) {
12654 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12655 : }
12656 6 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.unknown));
12657 6 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12658 : }
12659 16 : return NDR_ERR_SUCCESS;
12660 : }
12661 :
12662 12 : static enum ndr_err_code ndr_pull_samr_GetBootKeyInformation(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_GetBootKeyInformation *r)
12663 : {
12664 12 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
12665 12 : TALLOC_CTX *_mem_save_unknown_0 = NULL;
12666 12 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12667 12 : if (flags & NDR_IN) {
12668 6 : NDR_ZERO_STRUCT(r->out);
12669 :
12670 6 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12671 6 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
12672 : }
12673 6 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12674 6 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
12675 6 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
12676 6 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
12677 6 : NDR_PULL_ALLOC(ndr, r->out.unknown);
12678 6 : NDR_ZERO_STRUCTP(r->out.unknown);
12679 : }
12680 12 : if (flags & NDR_OUT) {
12681 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12682 : if (r->in.domain_handle == NULL) {
12683 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
12684 : NDR_ZERO_STRUCTP(r->in.domain_handle);
12685 : }
12686 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12687 6 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12688 0 : NDR_PULL_ALLOC(ndr, r->out.unknown);
12689 : }
12690 6 : _mem_save_unknown_0 = NDR_PULL_GET_MEM_CTX(ndr);
12691 6 : NDR_PULL_SET_MEM_CTX(ndr, r->out.unknown, LIBNDR_FLAG_REF_ALLOC);
12692 6 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.unknown));
12693 6 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_unknown_0, LIBNDR_FLAG_REF_ALLOC);
12694 6 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12695 : }
12696 12 : return NDR_ERR_SUCCESS;
12697 : }
12698 :
12699 0 : _PUBLIC_ void ndr_print_samr_GetBootKeyInformation(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_GetBootKeyInformation *r)
12700 : {
12701 0 : ndr_print_struct(ndr, name, "samr_GetBootKeyInformation");
12702 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12703 0 : ndr->depth++;
12704 0 : if (flags & NDR_SET_VALUES) {
12705 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12706 : }
12707 0 : if (flags & NDR_IN) {
12708 0 : ndr_print_struct(ndr, "in", "samr_GetBootKeyInformation");
12709 0 : ndr->depth++;
12710 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
12711 0 : ndr->depth++;
12712 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
12713 0 : ndr->depth--;
12714 0 : ndr->depth--;
12715 : }
12716 0 : if (flags & NDR_OUT) {
12717 0 : ndr_print_struct(ndr, "out", "samr_GetBootKeyInformation");
12718 0 : ndr->depth++;
12719 0 : ndr_print_ptr(ndr, "unknown", r->out.unknown);
12720 0 : ndr->depth++;
12721 0 : ndr_print_uint32(ndr, "unknown", *r->out.unknown);
12722 0 : ndr->depth--;
12723 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12724 0 : ndr->depth--;
12725 : }
12726 0 : ndr->depth--;
12727 : }
12728 :
12729 204 : static enum ndr_err_code ndr_push_samr_Connect3(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Connect3 *r)
12730 : {
12731 204 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12732 204 : if (flags & NDR_IN) {
12733 126 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
12734 126 : if (r->in.system_name) {
12735 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
12736 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
12737 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
12738 0 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.system_name, ndr_charset_length(r->in.system_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
12739 : }
12740 126 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown));
12741 126 : NDR_CHECK(ndr_push_samr_ConnectAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
12742 : }
12743 204 : if (flags & NDR_OUT) {
12744 78 : if (r->out.connect_handle == NULL) {
12745 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12746 : }
12747 78 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
12748 78 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12749 : }
12750 204 : return NDR_ERR_SUCCESS;
12751 : }
12752 :
12753 204 : static enum ndr_err_code ndr_pull_samr_Connect3(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Connect3 *r)
12754 : {
12755 0 : uint32_t _ptr_system_name;
12756 204 : uint32_t size_system_name_1 = 0;
12757 204 : uint32_t length_system_name_1 = 0;
12758 204 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
12759 204 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
12760 204 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12761 204 : if (flags & NDR_IN) {
12762 78 : NDR_ZERO_STRUCT(r->out);
12763 :
12764 78 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
12765 78 : if (_ptr_system_name) {
12766 0 : NDR_PULL_ALLOC(ndr, r->in.system_name);
12767 : } else {
12768 78 : r->in.system_name = NULL;
12769 : }
12770 78 : if (r->in.system_name) {
12771 0 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
12772 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
12773 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.system_name));
12774 0 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.system_name));
12775 0 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.system_name, &size_system_name_1));
12776 0 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.system_name, &length_system_name_1));
12777 0 : if (length_system_name_1 > size_system_name_1) {
12778 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_system_name_1, length_system_name_1);
12779 : }
12780 0 : NDR_CHECK(ndr_check_string_terminator(ndr, length_system_name_1, sizeof(uint16_t)));
12781 0 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.system_name, length_system_name_1, sizeof(uint16_t), CH_UTF16));
12782 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
12783 : }
12784 78 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown));
12785 78 : NDR_CHECK(ndr_pull_samr_ConnectAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
12786 78 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
12787 78 : NDR_ZERO_STRUCTP(r->out.connect_handle);
12788 : }
12789 204 : if (flags & NDR_OUT) {
12790 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12791 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12792 126 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12793 0 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
12794 : }
12795 126 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12796 126 : NDR_PULL_SET_MEM_CTX(ndr, r->out.connect_handle, LIBNDR_FLAG_REF_ALLOC);
12797 126 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
12798 126 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
12799 126 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12800 : }
12801 204 : return NDR_ERR_SUCCESS;
12802 : }
12803 :
12804 0 : _PUBLIC_ void ndr_print_samr_Connect3(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Connect3 *r)
12805 : {
12806 0 : ndr_print_struct(ndr, name, "samr_Connect3");
12807 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12808 0 : ndr->depth++;
12809 0 : if (flags & NDR_SET_VALUES) {
12810 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12811 : }
12812 0 : if (flags & NDR_IN) {
12813 0 : ndr_print_struct(ndr, "in", "samr_Connect3");
12814 0 : ndr->depth++;
12815 0 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
12816 0 : ndr->depth++;
12817 0 : if (r->in.system_name) {
12818 0 : ndr_print_string(ndr, "system_name", r->in.system_name);
12819 : }
12820 0 : ndr->depth--;
12821 0 : ndr_print_uint32(ndr, "unknown", r->in.unknown);
12822 0 : ndr_print_samr_ConnectAccessMask(ndr, "access_mask", r->in.access_mask);
12823 0 : ndr->depth--;
12824 : }
12825 0 : if (flags & NDR_OUT) {
12826 0 : ndr_print_struct(ndr, "out", "samr_Connect3");
12827 0 : ndr->depth++;
12828 0 : ndr_print_ptr(ndr, "connect_handle", r->out.connect_handle);
12829 0 : ndr->depth++;
12830 0 : ndr_print_policy_handle(ndr, "connect_handle", r->out.connect_handle);
12831 0 : ndr->depth--;
12832 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12833 0 : ndr->depth--;
12834 : }
12835 0 : ndr->depth--;
12836 : }
12837 :
12838 204 : static enum ndr_err_code ndr_push_samr_Connect4(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Connect4 *r)
12839 : {
12840 204 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12841 204 : if (flags & NDR_IN) {
12842 126 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
12843 126 : if (r->in.system_name) {
12844 126 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
12845 126 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
12846 126 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
12847 126 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.system_name, ndr_charset_length(r->in.system_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
12848 : }
12849 126 : NDR_CHECK(ndr_push_samr_ConnectVersion(ndr, NDR_SCALARS, r->in.client_version));
12850 126 : NDR_CHECK(ndr_push_samr_ConnectAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
12851 : }
12852 204 : if (flags & NDR_OUT) {
12853 78 : if (r->out.connect_handle == NULL) {
12854 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12855 : }
12856 78 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
12857 78 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12858 : }
12859 204 : return NDR_ERR_SUCCESS;
12860 : }
12861 :
12862 204 : static enum ndr_err_code ndr_pull_samr_Connect4(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Connect4 *r)
12863 : {
12864 0 : uint32_t _ptr_system_name;
12865 204 : uint32_t size_system_name_1 = 0;
12866 204 : uint32_t length_system_name_1 = 0;
12867 204 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
12868 204 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
12869 204 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
12870 204 : if (flags & NDR_IN) {
12871 78 : NDR_ZERO_STRUCT(r->out);
12872 :
12873 78 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
12874 78 : if (_ptr_system_name) {
12875 78 : NDR_PULL_ALLOC(ndr, r->in.system_name);
12876 : } else {
12877 0 : r->in.system_name = NULL;
12878 : }
12879 78 : if (r->in.system_name) {
12880 78 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
12881 78 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
12882 78 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.system_name));
12883 78 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.system_name));
12884 78 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.system_name, &size_system_name_1));
12885 78 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.system_name, &length_system_name_1));
12886 78 : if (length_system_name_1 > size_system_name_1) {
12887 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_system_name_1, length_system_name_1);
12888 : }
12889 78 : NDR_CHECK(ndr_check_string_terminator(ndr, length_system_name_1, sizeof(uint16_t)));
12890 78 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.system_name, length_system_name_1, sizeof(uint16_t), CH_UTF16));
12891 78 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
12892 : }
12893 78 : NDR_CHECK(ndr_pull_samr_ConnectVersion(ndr, NDR_SCALARS, &r->in.client_version));
12894 78 : NDR_CHECK(ndr_pull_samr_ConnectAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
12895 78 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
12896 78 : NDR_ZERO_STRUCTP(r->out.connect_handle);
12897 : }
12898 204 : if (flags & NDR_OUT) {
12899 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
12900 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
12901 126 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
12902 0 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
12903 : }
12904 126 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
12905 126 : NDR_PULL_SET_MEM_CTX(ndr, r->out.connect_handle, LIBNDR_FLAG_REF_ALLOC);
12906 126 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
12907 126 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
12908 126 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
12909 : }
12910 204 : return NDR_ERR_SUCCESS;
12911 : }
12912 :
12913 0 : _PUBLIC_ void ndr_print_samr_Connect4(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Connect4 *r)
12914 : {
12915 0 : ndr_print_struct(ndr, name, "samr_Connect4");
12916 0 : if (r == NULL) { ndr_print_null(ndr); return; }
12917 0 : ndr->depth++;
12918 0 : if (flags & NDR_SET_VALUES) {
12919 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
12920 : }
12921 0 : if (flags & NDR_IN) {
12922 0 : ndr_print_struct(ndr, "in", "samr_Connect4");
12923 0 : ndr->depth++;
12924 0 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
12925 0 : ndr->depth++;
12926 0 : if (r->in.system_name) {
12927 0 : ndr_print_string(ndr, "system_name", r->in.system_name);
12928 : }
12929 0 : ndr->depth--;
12930 0 : ndr_print_samr_ConnectVersion(ndr, "client_version", r->in.client_version);
12931 0 : ndr_print_samr_ConnectAccessMask(ndr, "access_mask", r->in.access_mask);
12932 0 : ndr->depth--;
12933 : }
12934 0 : if (flags & NDR_OUT) {
12935 0 : ndr_print_struct(ndr, "out", "samr_Connect4");
12936 0 : ndr->depth++;
12937 0 : ndr_print_ptr(ndr, "connect_handle", r->out.connect_handle);
12938 0 : ndr->depth++;
12939 0 : ndr_print_policy_handle(ndr, "connect_handle", r->out.connect_handle);
12940 0 : ndr->depth--;
12941 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
12942 0 : ndr->depth--;
12943 : }
12944 0 : ndr->depth--;
12945 : }
12946 :
12947 2678 : _PUBLIC_ enum ndr_err_code ndr_push_samr_ChangePasswordUser3(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_ChangePasswordUser3 *r)
12948 : {
12949 2678 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
12950 2678 : if (flags & NDR_IN) {
12951 1436 : if (r->in.account == NULL) {
12952 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12953 : }
12954 1436 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server));
12955 1436 : if (r->in.server) {
12956 1436 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
12957 : }
12958 1436 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
12959 1436 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.nt_password));
12960 1436 : if (r->in.nt_password) {
12961 1436 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, r->in.nt_password));
12962 : }
12963 1436 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.nt_verifier));
12964 1436 : if (r->in.nt_verifier) {
12965 1436 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.nt_verifier));
12966 : }
12967 1436 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->in.lm_change));
12968 1436 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.lm_password));
12969 1436 : if (r->in.lm_password) {
12970 1412 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, r->in.lm_password));
12971 : }
12972 1436 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.lm_verifier));
12973 1436 : if (r->in.lm_verifier) {
12974 1412 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.lm_verifier));
12975 : }
12976 1436 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.password3));
12977 1436 : if (r->in.password3) {
12978 0 : NDR_CHECK(ndr_push_samr_CryptPassword(ndr, NDR_SCALARS, r->in.password3));
12979 : }
12980 : }
12981 2678 : if (flags & NDR_OUT) {
12982 1242 : if (r->out.dominfo == NULL) {
12983 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12984 : }
12985 1242 : if (r->out.reject == NULL) {
12986 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
12987 : }
12988 1242 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.dominfo));
12989 1242 : if (*r->out.dominfo) {
12990 144 : NDR_CHECK(ndr_push_samr_DomInfo1(ndr, NDR_SCALARS, *r->out.dominfo));
12991 : }
12992 1242 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.reject));
12993 1242 : if (*r->out.reject) {
12994 1061 : NDR_CHECK(ndr_push_userPwdChangeFailureInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.reject));
12995 : }
12996 1242 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
12997 : }
12998 2678 : return NDR_ERR_SUCCESS;
12999 : }
13000 :
13001 2682 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_ChangePasswordUser3(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_ChangePasswordUser3 *r)
13002 : {
13003 4 : uint32_t _ptr_server;
13004 4 : uint32_t _ptr_nt_password;
13005 4 : uint32_t _ptr_nt_verifier;
13006 4 : uint32_t _ptr_lm_password;
13007 4 : uint32_t _ptr_lm_verifier;
13008 4 : uint32_t _ptr_password3;
13009 4 : uint32_t _ptr_dominfo;
13010 4 : uint32_t _ptr_reject;
13011 2682 : TALLOC_CTX *_mem_save_server_0 = NULL;
13012 2682 : TALLOC_CTX *_mem_save_account_0 = NULL;
13013 2682 : TALLOC_CTX *_mem_save_nt_password_0 = NULL;
13014 2682 : TALLOC_CTX *_mem_save_nt_verifier_0 = NULL;
13015 2682 : TALLOC_CTX *_mem_save_lm_password_0 = NULL;
13016 2682 : TALLOC_CTX *_mem_save_lm_verifier_0 = NULL;
13017 2682 : TALLOC_CTX *_mem_save_password3_0 = NULL;
13018 2682 : TALLOC_CTX *_mem_save_dominfo_0 = NULL;
13019 2682 : TALLOC_CTX *_mem_save_dominfo_1 = NULL;
13020 2682 : TALLOC_CTX *_mem_save_reject_0 = NULL;
13021 2682 : TALLOC_CTX *_mem_save_reject_1 = NULL;
13022 2682 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13023 2682 : if (flags & NDR_IN) {
13024 1244 : NDR_ZERO_STRUCT(r->out);
13025 :
13026 1244 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server));
13027 1244 : if (_ptr_server) {
13028 1244 : NDR_PULL_ALLOC(ndr, r->in.server);
13029 : } else {
13030 0 : r->in.server = NULL;
13031 : }
13032 1244 : if (r->in.server) {
13033 1244 : _mem_save_server_0 = NDR_PULL_GET_MEM_CTX(ndr);
13034 1244 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server, 0);
13035 1244 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
13036 1244 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_0, 0);
13037 : }
13038 1244 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13039 1244 : NDR_PULL_ALLOC(ndr, r->in.account);
13040 : }
13041 1244 : _mem_save_account_0 = NDR_PULL_GET_MEM_CTX(ndr);
13042 1244 : NDR_PULL_SET_MEM_CTX(ndr, r->in.account, LIBNDR_FLAG_REF_ALLOC);
13043 1244 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
13044 1244 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_0, LIBNDR_FLAG_REF_ALLOC);
13045 1244 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_nt_password));
13046 1244 : if (_ptr_nt_password) {
13047 1244 : NDR_PULL_ALLOC(ndr, r->in.nt_password);
13048 : } else {
13049 0 : r->in.nt_password = NULL;
13050 : }
13051 1244 : if (r->in.nt_password) {
13052 1244 : _mem_save_nt_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
13053 1244 : NDR_PULL_SET_MEM_CTX(ndr, r->in.nt_password, 0);
13054 1244 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, r->in.nt_password));
13055 1244 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_nt_password_0, 0);
13056 : }
13057 1244 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_nt_verifier));
13058 1244 : if (_ptr_nt_verifier) {
13059 1244 : NDR_PULL_ALLOC(ndr, r->in.nt_verifier);
13060 : } else {
13061 0 : r->in.nt_verifier = NULL;
13062 : }
13063 1244 : if (r->in.nt_verifier) {
13064 1244 : _mem_save_nt_verifier_0 = NDR_PULL_GET_MEM_CTX(ndr);
13065 1244 : NDR_PULL_SET_MEM_CTX(ndr, r->in.nt_verifier, 0);
13066 1244 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.nt_verifier));
13067 1244 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_nt_verifier_0, 0);
13068 : }
13069 1244 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->in.lm_change));
13070 1244 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_lm_password));
13071 1244 : if (_ptr_lm_password) {
13072 1206 : NDR_PULL_ALLOC(ndr, r->in.lm_password);
13073 : } else {
13074 38 : r->in.lm_password = NULL;
13075 : }
13076 1244 : if (r->in.lm_password) {
13077 1206 : _mem_save_lm_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
13078 1206 : NDR_PULL_SET_MEM_CTX(ndr, r->in.lm_password, 0);
13079 1206 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, r->in.lm_password));
13080 1206 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_lm_password_0, 0);
13081 : }
13082 1244 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_lm_verifier));
13083 1244 : if (_ptr_lm_verifier) {
13084 1206 : NDR_PULL_ALLOC(ndr, r->in.lm_verifier);
13085 : } else {
13086 38 : r->in.lm_verifier = NULL;
13087 : }
13088 1244 : if (r->in.lm_verifier) {
13089 1206 : _mem_save_lm_verifier_0 = NDR_PULL_GET_MEM_CTX(ndr);
13090 1206 : NDR_PULL_SET_MEM_CTX(ndr, r->in.lm_verifier, 0);
13091 1206 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.lm_verifier));
13092 1206 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_lm_verifier_0, 0);
13093 : }
13094 1244 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_password3));
13095 1244 : if (_ptr_password3) {
13096 0 : NDR_PULL_ALLOC(ndr, r->in.password3);
13097 : } else {
13098 1244 : r->in.password3 = NULL;
13099 : }
13100 1244 : if (r->in.password3) {
13101 0 : _mem_save_password3_0 = NDR_PULL_GET_MEM_CTX(ndr);
13102 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.password3, 0);
13103 0 : NDR_CHECK(ndr_pull_samr_CryptPassword(ndr, NDR_SCALARS, r->in.password3));
13104 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_password3_0, 0);
13105 : }
13106 1244 : NDR_PULL_ALLOC(ndr, r->out.dominfo);
13107 1244 : NDR_ZERO_STRUCTP(r->out.dominfo);
13108 1244 : NDR_PULL_ALLOC(ndr, r->out.reject);
13109 1244 : NDR_ZERO_STRUCTP(r->out.reject);
13110 : }
13111 2682 : if (flags & NDR_OUT) {
13112 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13113 : if (r->in.account == NULL) {
13114 : NDR_PULL_ALLOC(ndr, r->in.account);
13115 : NDR_ZERO_STRUCTP(r->in.account);
13116 : }
13117 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13118 1438 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13119 14 : NDR_PULL_ALLOC(ndr, r->out.dominfo);
13120 : }
13121 1438 : _mem_save_dominfo_0 = NDR_PULL_GET_MEM_CTX(ndr);
13122 1438 : NDR_PULL_SET_MEM_CTX(ndr, r->out.dominfo, LIBNDR_FLAG_REF_ALLOC);
13123 1438 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_dominfo));
13124 1438 : if (_ptr_dominfo) {
13125 150 : NDR_PULL_ALLOC(ndr, *r->out.dominfo);
13126 : } else {
13127 1288 : *r->out.dominfo = NULL;
13128 : }
13129 1438 : if (*r->out.dominfo) {
13130 150 : _mem_save_dominfo_1 = NDR_PULL_GET_MEM_CTX(ndr);
13131 150 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.dominfo, 0);
13132 150 : NDR_CHECK(ndr_pull_samr_DomInfo1(ndr, NDR_SCALARS, *r->out.dominfo));
13133 150 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dominfo_1, 0);
13134 : }
13135 1438 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dominfo_0, LIBNDR_FLAG_REF_ALLOC);
13136 1438 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13137 14 : NDR_PULL_ALLOC(ndr, r->out.reject);
13138 : }
13139 1438 : _mem_save_reject_0 = NDR_PULL_GET_MEM_CTX(ndr);
13140 1438 : NDR_PULL_SET_MEM_CTX(ndr, r->out.reject, LIBNDR_FLAG_REF_ALLOC);
13141 1438 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_reject));
13142 1438 : if (_ptr_reject) {
13143 1053 : NDR_PULL_ALLOC(ndr, *r->out.reject);
13144 : } else {
13145 385 : *r->out.reject = NULL;
13146 : }
13147 1438 : if (*r->out.reject) {
13148 1053 : _mem_save_reject_1 = NDR_PULL_GET_MEM_CTX(ndr);
13149 1053 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.reject, 0);
13150 1053 : NDR_CHECK(ndr_pull_userPwdChangeFailureInformation(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.reject));
13151 1053 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_reject_1, 0);
13152 : }
13153 1438 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_reject_0, LIBNDR_FLAG_REF_ALLOC);
13154 1438 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13155 : }
13156 2678 : return NDR_ERR_SUCCESS;
13157 : }
13158 :
13159 4 : _PUBLIC_ void ndr_print_samr_ChangePasswordUser3(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_ChangePasswordUser3 *r)
13160 : {
13161 4 : ndr_print_struct(ndr, name, "samr_ChangePasswordUser3");
13162 4 : if (r == NULL) { ndr_print_null(ndr); return; }
13163 4 : ndr->depth++;
13164 4 : if (flags & NDR_SET_VALUES) {
13165 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13166 : }
13167 4 : if (flags & NDR_IN) {
13168 2 : ndr_print_struct(ndr, "in", "samr_ChangePasswordUser3");
13169 2 : ndr->depth++;
13170 2 : ndr_print_ptr(ndr, "server", r->in.server);
13171 2 : ndr->depth++;
13172 2 : if (r->in.server) {
13173 2 : ndr_print_lsa_String(ndr, "server", r->in.server);
13174 : }
13175 2 : ndr->depth--;
13176 2 : ndr_print_ptr(ndr, "account", r->in.account);
13177 2 : ndr->depth++;
13178 2 : ndr_print_lsa_String(ndr, "account", r->in.account);
13179 2 : ndr->depth--;
13180 2 : ndr_print_ptr(ndr, "nt_password", r->in.nt_password);
13181 2 : ndr->depth++;
13182 2 : if (r->in.nt_password) {
13183 2 : ndr_print_samr_CryptPassword(ndr, "nt_password", r->in.nt_password);
13184 : }
13185 2 : ndr->depth--;
13186 2 : ndr_print_ptr(ndr, "nt_verifier", r->in.nt_verifier);
13187 2 : ndr->depth++;
13188 2 : if (r->in.nt_verifier) {
13189 2 : ndr_print_samr_Password(ndr, "nt_verifier", r->in.nt_verifier);
13190 : }
13191 2 : ndr->depth--;
13192 2 : ndr_print_uint8(ndr, "lm_change", r->in.lm_change);
13193 2 : ndr_print_ptr(ndr, "lm_password", r->in.lm_password);
13194 2 : ndr->depth++;
13195 2 : if (r->in.lm_password) {
13196 2 : ndr_print_samr_CryptPassword(ndr, "lm_password", r->in.lm_password);
13197 : }
13198 2 : ndr->depth--;
13199 2 : ndr_print_ptr(ndr, "lm_verifier", r->in.lm_verifier);
13200 2 : ndr->depth++;
13201 2 : if (r->in.lm_verifier) {
13202 2 : ndr_print_samr_Password(ndr, "lm_verifier", r->in.lm_verifier);
13203 : }
13204 2 : ndr->depth--;
13205 2 : ndr_print_ptr(ndr, "password3", r->in.password3);
13206 2 : ndr->depth++;
13207 2 : if (r->in.password3) {
13208 0 : ndr_print_samr_CryptPassword(ndr, "password3", r->in.password3);
13209 : }
13210 2 : ndr->depth--;
13211 2 : ndr->depth--;
13212 : }
13213 4 : if (flags & NDR_OUT) {
13214 2 : ndr_print_struct(ndr, "out", "samr_ChangePasswordUser3");
13215 2 : ndr->depth++;
13216 2 : ndr_print_ptr(ndr, "dominfo", r->out.dominfo);
13217 2 : ndr->depth++;
13218 2 : ndr_print_ptr(ndr, "dominfo", *r->out.dominfo);
13219 2 : ndr->depth++;
13220 2 : if (*r->out.dominfo) {
13221 2 : ndr_print_samr_DomInfo1(ndr, "dominfo", *r->out.dominfo);
13222 : }
13223 2 : ndr->depth--;
13224 2 : ndr->depth--;
13225 2 : ndr_print_ptr(ndr, "reject", r->out.reject);
13226 2 : ndr->depth++;
13227 2 : ndr_print_ptr(ndr, "reject", *r->out.reject);
13228 2 : ndr->depth++;
13229 2 : if (*r->out.reject) {
13230 2 : ndr_print_userPwdChangeFailureInformation(ndr, "reject", *r->out.reject);
13231 : }
13232 2 : ndr->depth--;
13233 2 : ndr->depth--;
13234 2 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13235 2 : ndr->depth--;
13236 : }
13237 4 : ndr->depth--;
13238 : }
13239 :
13240 401 : _PUBLIC_ enum ndr_err_code ndr_push_samr_Connect5(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Connect5 *r)
13241 : {
13242 401 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13243 401 : if (flags & NDR_IN) {
13244 227 : if (r->in.info_in == NULL) {
13245 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13246 : }
13247 227 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.system_name));
13248 227 : if (r->in.system_name) {
13249 226 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
13250 226 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
13251 226 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->in.system_name, CH_UTF16)));
13252 226 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->in.system_name, ndr_charset_length(r->in.system_name, CH_UTF16), sizeof(uint16_t), CH_UTF16));
13253 : }
13254 227 : NDR_CHECK(ndr_push_samr_ConnectAccessMask(ndr, NDR_SCALARS, r->in.access_mask));
13255 227 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.level_in));
13256 227 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.info_in, r->in.level_in));
13257 227 : NDR_CHECK(ndr_push_samr_ConnectInfo(ndr, NDR_SCALARS, r->in.info_in));
13258 : }
13259 401 : if (flags & NDR_OUT) {
13260 174 : if (r->out.level_out == NULL) {
13261 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13262 : }
13263 174 : if (r->out.info_out == NULL) {
13264 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13265 : }
13266 174 : if (r->out.connect_handle == NULL) {
13267 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13268 : }
13269 174 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, *r->out.level_out));
13270 174 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->out.info_out, *r->out.level_out));
13271 174 : NDR_CHECK(ndr_push_samr_ConnectInfo(ndr, NDR_SCALARS, r->out.info_out));
13272 174 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
13273 174 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13274 : }
13275 401 : return NDR_ERR_SUCCESS;
13276 : }
13277 :
13278 402 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_Connect5(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Connect5 *r)
13279 : {
13280 4 : uint32_t _ptr_system_name;
13281 402 : uint32_t size_system_name_1 = 0;
13282 402 : uint32_t length_system_name_1 = 0;
13283 402 : TALLOC_CTX *_mem_save_system_name_0 = NULL;
13284 402 : TALLOC_CTX *_mem_save_info_in_0 = NULL;
13285 402 : TALLOC_CTX *_mem_save_level_out_0 = NULL;
13286 402 : TALLOC_CTX *_mem_save_info_out_0 = NULL;
13287 402 : TALLOC_CTX *_mem_save_connect_handle_0 = NULL;
13288 402 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13289 402 : if (flags & NDR_IN) {
13290 173 : NDR_ZERO_STRUCT(r->out);
13291 :
13292 173 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_system_name));
13293 173 : if (_ptr_system_name) {
13294 172 : NDR_PULL_ALLOC(ndr, r->in.system_name);
13295 : } else {
13296 1 : r->in.system_name = NULL;
13297 : }
13298 173 : if (r->in.system_name) {
13299 172 : _mem_save_system_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
13300 172 : NDR_PULL_SET_MEM_CTX(ndr, r->in.system_name, 0);
13301 172 : NDR_CHECK(ndr_pull_array_size(ndr, &r->in.system_name));
13302 172 : NDR_CHECK(ndr_pull_array_length(ndr, &r->in.system_name));
13303 172 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->in.system_name, &size_system_name_1));
13304 172 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->in.system_name, &length_system_name_1));
13305 172 : if (length_system_name_1 > size_system_name_1) {
13306 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_system_name_1, length_system_name_1);
13307 : }
13308 172 : NDR_CHECK(ndr_check_string_terminator(ndr, length_system_name_1, sizeof(uint16_t)));
13309 172 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->in.system_name, length_system_name_1, sizeof(uint16_t), CH_UTF16));
13310 172 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_system_name_0, 0);
13311 : }
13312 175 : NDR_CHECK(ndr_pull_samr_ConnectAccessMask(ndr, NDR_SCALARS, &r->in.access_mask));
13313 173 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.level_in));
13314 173 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13315 173 : NDR_PULL_ALLOC(ndr, r->in.info_in);
13316 : }
13317 173 : _mem_save_info_in_0 = NDR_PULL_GET_MEM_CTX(ndr);
13318 173 : NDR_PULL_SET_MEM_CTX(ndr, r->in.info_in, LIBNDR_FLAG_REF_ALLOC);
13319 173 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.info_in, r->in.level_in));
13320 173 : NDR_CHECK(ndr_pull_samr_ConnectInfo(ndr, NDR_SCALARS, r->in.info_in));
13321 173 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_in_0, LIBNDR_FLAG_REF_ALLOC);
13322 173 : NDR_PULL_ALLOC(ndr, r->out.level_out);
13323 173 : NDR_ZERO_STRUCTP(r->out.level_out);
13324 173 : NDR_PULL_ALLOC(ndr, r->out.info_out);
13325 173 : NDR_ZERO_STRUCTP(r->out.info_out);
13326 173 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
13327 173 : NDR_ZERO_STRUCTP(r->out.connect_handle);
13328 : }
13329 402 : if (flags & NDR_OUT) {
13330 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13331 : if (r->in.info_in == NULL) {
13332 : NDR_PULL_ALLOC(ndr, r->in.info_in);
13333 : NDR_ZERO_STRUCTP(r->in.info_in);
13334 : }
13335 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13336 229 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13337 88 : NDR_PULL_ALLOC(ndr, r->out.level_out);
13338 : }
13339 229 : _mem_save_level_out_0 = NDR_PULL_GET_MEM_CTX(ndr);
13340 229 : NDR_PULL_SET_MEM_CTX(ndr, r->out.level_out, LIBNDR_FLAG_REF_ALLOC);
13341 229 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, r->out.level_out));
13342 229 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_level_out_0, LIBNDR_FLAG_REF_ALLOC);
13343 229 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13344 88 : NDR_PULL_ALLOC(ndr, r->out.info_out);
13345 : }
13346 229 : _mem_save_info_out_0 = NDR_PULL_GET_MEM_CTX(ndr);
13347 229 : NDR_PULL_SET_MEM_CTX(ndr, r->out.info_out, LIBNDR_FLAG_REF_ALLOC);
13348 229 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->out.info_out, *r->out.level_out));
13349 229 : NDR_CHECK(ndr_pull_samr_ConnectInfo(ndr, NDR_SCALARS, r->out.info_out));
13350 229 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_out_0, LIBNDR_FLAG_REF_ALLOC);
13351 229 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13352 88 : NDR_PULL_ALLOC(ndr, r->out.connect_handle);
13353 : }
13354 229 : _mem_save_connect_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
13355 229 : NDR_PULL_SET_MEM_CTX(ndr, r->out.connect_handle, LIBNDR_FLAG_REF_ALLOC);
13356 229 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->out.connect_handle));
13357 229 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_connect_handle_0, LIBNDR_FLAG_REF_ALLOC);
13358 229 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13359 : }
13360 398 : return NDR_ERR_SUCCESS;
13361 : }
13362 :
13363 10 : _PUBLIC_ void ndr_print_samr_Connect5(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Connect5 *r)
13364 : {
13365 10 : ndr_print_struct(ndr, name, "samr_Connect5");
13366 10 : if (r == NULL) { ndr_print_null(ndr); return; }
13367 10 : ndr->depth++;
13368 10 : if (flags & NDR_SET_VALUES) {
13369 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13370 : }
13371 10 : if (flags & NDR_IN) {
13372 2 : ndr_print_struct(ndr, "in", "samr_Connect5");
13373 2 : ndr->depth++;
13374 2 : ndr_print_ptr(ndr, "system_name", r->in.system_name);
13375 2 : ndr->depth++;
13376 2 : if (r->in.system_name) {
13377 2 : ndr_print_string(ndr, "system_name", r->in.system_name);
13378 : }
13379 2 : ndr->depth--;
13380 2 : ndr_print_samr_ConnectAccessMask(ndr, "access_mask", r->in.access_mask);
13381 2 : ndr_print_uint32(ndr, "level_in", r->in.level_in);
13382 2 : ndr_print_ptr(ndr, "info_in", r->in.info_in);
13383 2 : ndr->depth++;
13384 2 : ndr_print_set_switch_value(ndr, r->in.info_in, r->in.level_in);
13385 2 : ndr_print_samr_ConnectInfo(ndr, "info_in", r->in.info_in);
13386 2 : ndr->depth--;
13387 2 : ndr->depth--;
13388 : }
13389 10 : if (flags & NDR_OUT) {
13390 8 : ndr_print_struct(ndr, "out", "samr_Connect5");
13391 8 : ndr->depth++;
13392 8 : ndr_print_ptr(ndr, "level_out", r->out.level_out);
13393 8 : ndr->depth++;
13394 8 : ndr_print_uint32(ndr, "level_out", *r->out.level_out);
13395 8 : ndr->depth--;
13396 8 : ndr_print_ptr(ndr, "info_out", r->out.info_out);
13397 8 : ndr->depth++;
13398 8 : ndr_print_set_switch_value(ndr, r->out.info_out, *r->out.level_out);
13399 8 : ndr_print_samr_ConnectInfo(ndr, "info_out", r->out.info_out);
13400 8 : ndr->depth--;
13401 8 : ndr_print_ptr(ndr, "connect_handle", r->out.connect_handle);
13402 8 : ndr->depth++;
13403 8 : ndr_print_policy_handle(ndr, "connect_handle", r->out.connect_handle);
13404 8 : ndr->depth--;
13405 8 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13406 8 : ndr->depth--;
13407 : }
13408 10 : ndr->depth--;
13409 : }
13410 :
13411 64 : static enum ndr_err_code ndr_push_samr_RidToSid(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_RidToSid *r)
13412 : {
13413 64 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13414 64 : if (flags & NDR_IN) {
13415 40 : if (r->in.domain_handle == NULL) {
13416 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13417 : }
13418 40 : NDR_CHECK(ndr_push_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
13419 40 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.rid));
13420 : }
13421 64 : if (flags & NDR_OUT) {
13422 24 : if (r->out.sid == NULL) {
13423 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13424 : }
13425 24 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.sid));
13426 24 : if (*r->out.sid) {
13427 24 : NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sid));
13428 : }
13429 24 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13430 : }
13431 64 : return NDR_ERR_SUCCESS;
13432 : }
13433 :
13434 64 : static enum ndr_err_code ndr_pull_samr_RidToSid(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_RidToSid *r)
13435 : {
13436 0 : uint32_t _ptr_sid;
13437 64 : TALLOC_CTX *_mem_save_domain_handle_0 = NULL;
13438 64 : TALLOC_CTX *_mem_save_sid_0 = NULL;
13439 64 : TALLOC_CTX *_mem_save_sid_1 = NULL;
13440 64 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13441 64 : if (flags & NDR_IN) {
13442 24 : NDR_ZERO_STRUCT(r->out);
13443 :
13444 24 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13445 24 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
13446 : }
13447 24 : _mem_save_domain_handle_0 = NDR_PULL_GET_MEM_CTX(ndr);
13448 24 : NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_handle, LIBNDR_FLAG_REF_ALLOC);
13449 24 : NDR_CHECK(ndr_pull_policy_handle(ndr, NDR_SCALARS, r->in.domain_handle));
13450 24 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_handle_0, LIBNDR_FLAG_REF_ALLOC);
13451 24 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.rid));
13452 24 : NDR_PULL_ALLOC(ndr, r->out.sid);
13453 24 : NDR_ZERO_STRUCTP(r->out.sid);
13454 : }
13455 64 : if (flags & NDR_OUT) {
13456 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13457 : if (r->in.domain_handle == NULL) {
13458 : NDR_PULL_ALLOC(ndr, r->in.domain_handle);
13459 : NDR_ZERO_STRUCTP(r->in.domain_handle);
13460 : }
13461 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13462 40 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13463 0 : NDR_PULL_ALLOC(ndr, r->out.sid);
13464 : }
13465 40 : _mem_save_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
13466 40 : NDR_PULL_SET_MEM_CTX(ndr, r->out.sid, LIBNDR_FLAG_REF_ALLOC);
13467 40 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid));
13468 40 : if (_ptr_sid) {
13469 40 : NDR_PULL_ALLOC(ndr, *r->out.sid);
13470 : } else {
13471 0 : *r->out.sid = NULL;
13472 : }
13473 40 : if (*r->out.sid) {
13474 40 : _mem_save_sid_1 = NDR_PULL_GET_MEM_CTX(ndr);
13475 40 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.sid, 0);
13476 40 : NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.sid));
13477 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_1, 0);
13478 : }
13479 40 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_0, LIBNDR_FLAG_REF_ALLOC);
13480 40 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13481 : }
13482 64 : return NDR_ERR_SUCCESS;
13483 : }
13484 :
13485 0 : _PUBLIC_ void ndr_print_samr_RidToSid(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_RidToSid *r)
13486 : {
13487 0 : ndr_print_struct(ndr, name, "samr_RidToSid");
13488 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13489 0 : ndr->depth++;
13490 0 : if (flags & NDR_SET_VALUES) {
13491 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13492 : }
13493 0 : if (flags & NDR_IN) {
13494 0 : ndr_print_struct(ndr, "in", "samr_RidToSid");
13495 0 : ndr->depth++;
13496 0 : ndr_print_ptr(ndr, "domain_handle", r->in.domain_handle);
13497 0 : ndr->depth++;
13498 0 : ndr_print_policy_handle(ndr, "domain_handle", r->in.domain_handle);
13499 0 : ndr->depth--;
13500 0 : ndr_print_uint32(ndr, "rid", r->in.rid);
13501 0 : ndr->depth--;
13502 : }
13503 0 : if (flags & NDR_OUT) {
13504 0 : ndr_print_struct(ndr, "out", "samr_RidToSid");
13505 0 : ndr->depth++;
13506 0 : ndr_print_ptr(ndr, "sid", r->out.sid);
13507 0 : ndr->depth++;
13508 0 : ndr_print_ptr(ndr, "sid", *r->out.sid);
13509 0 : ndr->depth++;
13510 0 : if (*r->out.sid) {
13511 0 : ndr_print_dom_sid2(ndr, "sid", *r->out.sid);
13512 : }
13513 0 : ndr->depth--;
13514 0 : ndr->depth--;
13515 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13516 0 : ndr->depth--;
13517 : }
13518 0 : ndr->depth--;
13519 : }
13520 :
13521 0 : static enum ndr_err_code ndr_push_samr_SetDsrmPassword(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_SetDsrmPassword *r)
13522 : {
13523 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13524 0 : if (flags & NDR_IN) {
13525 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.name));
13526 0 : if (r->in.name) {
13527 0 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
13528 : }
13529 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->in.unknown));
13530 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.hash));
13531 0 : if (r->in.hash) {
13532 0 : NDR_CHECK(ndr_push_samr_Password(ndr, NDR_SCALARS, r->in.hash));
13533 : }
13534 : }
13535 0 : if (flags & NDR_OUT) {
13536 0 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13537 : }
13538 0 : return NDR_ERR_SUCCESS;
13539 : }
13540 :
13541 0 : static enum ndr_err_code ndr_pull_samr_SetDsrmPassword(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_SetDsrmPassword *r)
13542 : {
13543 0 : uint32_t _ptr_name;
13544 0 : uint32_t _ptr_hash;
13545 0 : TALLOC_CTX *_mem_save_name_0 = NULL;
13546 0 : TALLOC_CTX *_mem_save_hash_0 = NULL;
13547 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13548 0 : if (flags & NDR_IN) {
13549 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
13550 0 : if (_ptr_name) {
13551 0 : NDR_PULL_ALLOC(ndr, r->in.name);
13552 : } else {
13553 0 : r->in.name = NULL;
13554 : }
13555 0 : if (r->in.name) {
13556 0 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
13557 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.name, 0);
13558 0 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.name));
13559 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
13560 : }
13561 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->in.unknown));
13562 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_hash));
13563 0 : if (_ptr_hash) {
13564 0 : NDR_PULL_ALLOC(ndr, r->in.hash);
13565 : } else {
13566 0 : r->in.hash = NULL;
13567 : }
13568 0 : if (r->in.hash) {
13569 0 : _mem_save_hash_0 = NDR_PULL_GET_MEM_CTX(ndr);
13570 0 : NDR_PULL_SET_MEM_CTX(ndr, r->in.hash, 0);
13571 0 : NDR_CHECK(ndr_pull_samr_Password(ndr, NDR_SCALARS, r->in.hash));
13572 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_hash_0, 0);
13573 : }
13574 : }
13575 0 : if (flags & NDR_OUT) {
13576 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13577 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13578 0 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13579 : }
13580 0 : return NDR_ERR_SUCCESS;
13581 : }
13582 :
13583 0 : _PUBLIC_ void ndr_print_samr_SetDsrmPassword(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_SetDsrmPassword *r)
13584 : {
13585 0 : ndr_print_struct(ndr, name, "samr_SetDsrmPassword");
13586 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13587 0 : ndr->depth++;
13588 0 : if (flags & NDR_SET_VALUES) {
13589 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13590 : }
13591 0 : if (flags & NDR_IN) {
13592 0 : ndr_print_struct(ndr, "in", "samr_SetDsrmPassword");
13593 0 : ndr->depth++;
13594 0 : ndr_print_ptr(ndr, "name", r->in.name);
13595 0 : ndr->depth++;
13596 0 : if (r->in.name) {
13597 0 : ndr_print_lsa_String(ndr, "name", r->in.name);
13598 : }
13599 0 : ndr->depth--;
13600 0 : ndr_print_uint32(ndr, "unknown", r->in.unknown);
13601 0 : ndr_print_ptr(ndr, "hash", r->in.hash);
13602 0 : ndr->depth++;
13603 0 : if (r->in.hash) {
13604 0 : ndr_print_samr_Password(ndr, "hash", r->in.hash);
13605 : }
13606 0 : ndr->depth--;
13607 0 : ndr->depth--;
13608 : }
13609 0 : if (flags & NDR_OUT) {
13610 0 : ndr_print_struct(ndr, "out", "samr_SetDsrmPassword");
13611 0 : ndr->depth++;
13612 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13613 0 : ndr->depth--;
13614 : }
13615 0 : ndr->depth--;
13616 : }
13617 :
13618 15 : static enum ndr_err_code ndr_push_samr_ValidatePassword(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_ValidatePassword *r)
13619 : {
13620 15 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13621 15 : if (flags & NDR_IN) {
13622 12 : if (r->in.req == NULL) {
13623 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13624 : }
13625 12 : NDR_CHECK(ndr_push_samr_ValidatePasswordLevel(ndr, NDR_SCALARS, r->in.level));
13626 12 : NDR_CHECK(ndr_push_set_switch_value(ndr, r->in.req, r->in.level));
13627 12 : NDR_CHECK(ndr_push_samr_ValidatePasswordReq(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.req));
13628 : }
13629 15 : if (flags & NDR_OUT) {
13630 3 : if (r->out.rep == NULL) {
13631 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13632 : }
13633 3 : NDR_CHECK(ndr_push_unique_ptr(ndr, *r->out.rep));
13634 3 : if (*r->out.rep) {
13635 3 : NDR_CHECK(ndr_push_set_switch_value(ndr, *r->out.rep, r->in.level));
13636 3 : NDR_CHECK(ndr_push_samr_ValidatePasswordRep(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.rep));
13637 : }
13638 3 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13639 : }
13640 15 : return NDR_ERR_SUCCESS;
13641 : }
13642 :
13643 15 : static enum ndr_err_code ndr_pull_samr_ValidatePassword(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_ValidatePassword *r)
13644 : {
13645 0 : uint32_t _ptr_rep;
13646 15 : TALLOC_CTX *_mem_save_req_0 = NULL;
13647 15 : TALLOC_CTX *_mem_save_rep_0 = NULL;
13648 15 : TALLOC_CTX *_mem_save_rep_1 = NULL;
13649 15 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13650 15 : if (flags & NDR_IN) {
13651 6 : NDR_ZERO_STRUCT(r->out);
13652 :
13653 6 : NDR_CHECK(ndr_pull_samr_ValidatePasswordLevel(ndr, NDR_SCALARS, &r->in.level));
13654 6 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13655 6 : NDR_PULL_ALLOC(ndr, r->in.req);
13656 : }
13657 6 : _mem_save_req_0 = NDR_PULL_GET_MEM_CTX(ndr);
13658 6 : NDR_PULL_SET_MEM_CTX(ndr, r->in.req, LIBNDR_FLAG_REF_ALLOC);
13659 6 : NDR_CHECK(ndr_pull_set_switch_value(ndr, r->in.req, r->in.level));
13660 6 : NDR_CHECK(ndr_pull_samr_ValidatePasswordReq(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.req));
13661 6 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_req_0, LIBNDR_FLAG_REF_ALLOC);
13662 6 : NDR_PULL_ALLOC(ndr, r->out.rep);
13663 6 : NDR_ZERO_STRUCTP(r->out.rep);
13664 : }
13665 15 : if (flags & NDR_OUT) {
13666 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13667 : if (r->in.req == NULL) {
13668 : NDR_PULL_ALLOC(ndr, r->in.req);
13669 : NDR_ZERO_STRUCTP(r->in.req);
13670 : }
13671 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13672 9 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13673 0 : NDR_PULL_ALLOC(ndr, r->out.rep);
13674 : }
13675 9 : _mem_save_rep_0 = NDR_PULL_GET_MEM_CTX(ndr);
13676 9 : NDR_PULL_SET_MEM_CTX(ndr, r->out.rep, LIBNDR_FLAG_REF_ALLOC);
13677 9 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_rep));
13678 9 : if (_ptr_rep) {
13679 9 : NDR_PULL_ALLOC(ndr, *r->out.rep);
13680 : } else {
13681 0 : *r->out.rep = NULL;
13682 : }
13683 9 : if (*r->out.rep) {
13684 9 : _mem_save_rep_1 = NDR_PULL_GET_MEM_CTX(ndr);
13685 9 : NDR_PULL_SET_MEM_CTX(ndr, *r->out.rep, 0);
13686 9 : NDR_CHECK(ndr_pull_set_switch_value(ndr, *r->out.rep, r->in.level));
13687 9 : NDR_CHECK(ndr_pull_samr_ValidatePasswordRep(ndr, NDR_SCALARS|NDR_BUFFERS, *r->out.rep));
13688 9 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rep_1, 0);
13689 : }
13690 9 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_rep_0, LIBNDR_FLAG_REF_ALLOC);
13691 9 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
13692 : }
13693 15 : return NDR_ERR_SUCCESS;
13694 : }
13695 :
13696 0 : _PUBLIC_ void ndr_print_samr_ValidatePassword(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_ValidatePassword *r)
13697 : {
13698 0 : ndr_print_struct(ndr, name, "samr_ValidatePassword");
13699 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13700 0 : ndr->depth++;
13701 0 : if (flags & NDR_SET_VALUES) {
13702 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13703 : }
13704 0 : if (flags & NDR_IN) {
13705 0 : ndr_print_struct(ndr, "in", "samr_ValidatePassword");
13706 0 : ndr->depth++;
13707 0 : ndr_print_samr_ValidatePasswordLevel(ndr, "level", r->in.level);
13708 0 : ndr_print_ptr(ndr, "req", r->in.req);
13709 0 : ndr->depth++;
13710 0 : ndr_print_set_switch_value(ndr, r->in.req, r->in.level);
13711 0 : ndr_print_samr_ValidatePasswordReq(ndr, "req", r->in.req);
13712 0 : ndr->depth--;
13713 0 : ndr->depth--;
13714 : }
13715 0 : if (flags & NDR_OUT) {
13716 0 : ndr_print_struct(ndr, "out", "samr_ValidatePassword");
13717 0 : ndr->depth++;
13718 0 : ndr_print_ptr(ndr, "rep", r->out.rep);
13719 0 : ndr->depth++;
13720 0 : ndr_print_ptr(ndr, "rep", *r->out.rep);
13721 0 : ndr->depth++;
13722 0 : if (*r->out.rep) {
13723 0 : ndr_print_set_switch_value(ndr, *r->out.rep, r->in.level);
13724 0 : ndr_print_samr_ValidatePasswordRep(ndr, "rep", *r->out.rep);
13725 : }
13726 0 : ndr->depth--;
13727 0 : ndr->depth--;
13728 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
13729 0 : ndr->depth--;
13730 : }
13731 0 : ndr->depth--;
13732 : }
13733 :
13734 0 : static enum ndr_err_code ndr_push_samr_Opnum68NotUsedOnWire(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Opnum68NotUsedOnWire *r)
13735 : {
13736 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13737 0 : if (flags & NDR_IN) {
13738 : }
13739 0 : if (flags & NDR_OUT) {
13740 : }
13741 0 : return NDR_ERR_SUCCESS;
13742 : }
13743 :
13744 0 : static enum ndr_err_code ndr_pull_samr_Opnum68NotUsedOnWire(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Opnum68NotUsedOnWire *r)
13745 : {
13746 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13747 0 : if (flags & NDR_IN) {
13748 : }
13749 0 : if (flags & NDR_OUT) {
13750 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13751 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13752 : }
13753 0 : return NDR_ERR_SUCCESS;
13754 : }
13755 :
13756 0 : _PUBLIC_ void ndr_print_samr_Opnum68NotUsedOnWire(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Opnum68NotUsedOnWire *r)
13757 : {
13758 0 : ndr_print_struct(ndr, name, "samr_Opnum68NotUsedOnWire");
13759 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13760 0 : ndr->depth++;
13761 0 : if (flags & NDR_SET_VALUES) {
13762 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13763 : }
13764 0 : if (flags & NDR_IN) {
13765 0 : ndr_print_struct(ndr, "in", "samr_Opnum68NotUsedOnWire");
13766 0 : ndr->depth++;
13767 0 : ndr->depth--;
13768 : }
13769 0 : if (flags & NDR_OUT) {
13770 0 : ndr_print_struct(ndr, "out", "samr_Opnum68NotUsedOnWire");
13771 0 : ndr->depth++;
13772 0 : ndr->depth--;
13773 : }
13774 0 : ndr->depth--;
13775 : }
13776 :
13777 0 : static enum ndr_err_code ndr_push_samr_Opnum69NotUsedOnWire(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Opnum69NotUsedOnWire *r)
13778 : {
13779 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13780 0 : if (flags & NDR_IN) {
13781 : }
13782 0 : if (flags & NDR_OUT) {
13783 : }
13784 0 : return NDR_ERR_SUCCESS;
13785 : }
13786 :
13787 0 : static enum ndr_err_code ndr_pull_samr_Opnum69NotUsedOnWire(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Opnum69NotUsedOnWire *r)
13788 : {
13789 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13790 0 : if (flags & NDR_IN) {
13791 : }
13792 0 : if (flags & NDR_OUT) {
13793 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13794 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13795 : }
13796 0 : return NDR_ERR_SUCCESS;
13797 : }
13798 :
13799 0 : _PUBLIC_ void ndr_print_samr_Opnum69NotUsedOnWire(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Opnum69NotUsedOnWire *r)
13800 : {
13801 0 : ndr_print_struct(ndr, name, "samr_Opnum69NotUsedOnWire");
13802 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13803 0 : ndr->depth++;
13804 0 : if (flags & NDR_SET_VALUES) {
13805 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13806 : }
13807 0 : if (flags & NDR_IN) {
13808 0 : ndr_print_struct(ndr, "in", "samr_Opnum69NotUsedOnWire");
13809 0 : ndr->depth++;
13810 0 : ndr->depth--;
13811 : }
13812 0 : if (flags & NDR_OUT) {
13813 0 : ndr_print_struct(ndr, "out", "samr_Opnum69NotUsedOnWire");
13814 0 : ndr->depth++;
13815 0 : ndr->depth--;
13816 : }
13817 0 : ndr->depth--;
13818 : }
13819 :
13820 0 : static enum ndr_err_code ndr_push_samr_Opnum70NotUsedOnWire(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Opnum70NotUsedOnWire *r)
13821 : {
13822 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13823 0 : if (flags & NDR_IN) {
13824 : }
13825 0 : if (flags & NDR_OUT) {
13826 : }
13827 0 : return NDR_ERR_SUCCESS;
13828 : }
13829 :
13830 0 : static enum ndr_err_code ndr_pull_samr_Opnum70NotUsedOnWire(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Opnum70NotUsedOnWire *r)
13831 : {
13832 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13833 0 : if (flags & NDR_IN) {
13834 : }
13835 0 : if (flags & NDR_OUT) {
13836 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13837 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13838 : }
13839 0 : return NDR_ERR_SUCCESS;
13840 : }
13841 :
13842 0 : _PUBLIC_ void ndr_print_samr_Opnum70NotUsedOnWire(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Opnum70NotUsedOnWire *r)
13843 : {
13844 0 : ndr_print_struct(ndr, name, "samr_Opnum70NotUsedOnWire");
13845 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13846 0 : ndr->depth++;
13847 0 : if (flags & NDR_SET_VALUES) {
13848 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13849 : }
13850 0 : if (flags & NDR_IN) {
13851 0 : ndr_print_struct(ndr, "in", "samr_Opnum70NotUsedOnWire");
13852 0 : ndr->depth++;
13853 0 : ndr->depth--;
13854 : }
13855 0 : if (flags & NDR_OUT) {
13856 0 : ndr_print_struct(ndr, "out", "samr_Opnum70NotUsedOnWire");
13857 0 : ndr->depth++;
13858 0 : ndr->depth--;
13859 : }
13860 0 : ndr->depth--;
13861 : }
13862 :
13863 0 : static enum ndr_err_code ndr_push_samr_Opnum71NotUsedOnWire(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Opnum71NotUsedOnWire *r)
13864 : {
13865 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13866 0 : if (flags & NDR_IN) {
13867 : }
13868 0 : if (flags & NDR_OUT) {
13869 : }
13870 0 : return NDR_ERR_SUCCESS;
13871 : }
13872 :
13873 0 : static enum ndr_err_code ndr_pull_samr_Opnum71NotUsedOnWire(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Opnum71NotUsedOnWire *r)
13874 : {
13875 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13876 0 : if (flags & NDR_IN) {
13877 : }
13878 0 : if (flags & NDR_OUT) {
13879 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13880 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13881 : }
13882 0 : return NDR_ERR_SUCCESS;
13883 : }
13884 :
13885 0 : _PUBLIC_ void ndr_print_samr_Opnum71NotUsedOnWire(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Opnum71NotUsedOnWire *r)
13886 : {
13887 0 : ndr_print_struct(ndr, name, "samr_Opnum71NotUsedOnWire");
13888 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13889 0 : ndr->depth++;
13890 0 : if (flags & NDR_SET_VALUES) {
13891 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13892 : }
13893 0 : if (flags & NDR_IN) {
13894 0 : ndr_print_struct(ndr, "in", "samr_Opnum71NotUsedOnWire");
13895 0 : ndr->depth++;
13896 0 : ndr->depth--;
13897 : }
13898 0 : if (flags & NDR_OUT) {
13899 0 : ndr_print_struct(ndr, "out", "samr_Opnum71NotUsedOnWire");
13900 0 : ndr->depth++;
13901 0 : ndr->depth--;
13902 : }
13903 0 : ndr->depth--;
13904 : }
13905 :
13906 0 : static enum ndr_err_code ndr_push_samr_Opnum72NotUsedOnWire(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_Opnum72NotUsedOnWire *r)
13907 : {
13908 0 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13909 0 : if (flags & NDR_IN) {
13910 : }
13911 0 : if (flags & NDR_OUT) {
13912 : }
13913 0 : return NDR_ERR_SUCCESS;
13914 : }
13915 :
13916 0 : static enum ndr_err_code ndr_pull_samr_Opnum72NotUsedOnWire(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_Opnum72NotUsedOnWire *r)
13917 : {
13918 0 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13919 0 : if (flags & NDR_IN) {
13920 : }
13921 0 : if (flags & NDR_OUT) {
13922 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
13923 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
13924 : }
13925 0 : return NDR_ERR_SUCCESS;
13926 : }
13927 :
13928 0 : _PUBLIC_ void ndr_print_samr_Opnum72NotUsedOnWire(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_Opnum72NotUsedOnWire *r)
13929 : {
13930 0 : ndr_print_struct(ndr, name, "samr_Opnum72NotUsedOnWire");
13931 0 : if (r == NULL) { ndr_print_null(ndr); return; }
13932 0 : ndr->depth++;
13933 0 : if (flags & NDR_SET_VALUES) {
13934 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
13935 : }
13936 0 : if (flags & NDR_IN) {
13937 0 : ndr_print_struct(ndr, "in", "samr_Opnum72NotUsedOnWire");
13938 0 : ndr->depth++;
13939 0 : ndr->depth--;
13940 : }
13941 0 : if (flags & NDR_OUT) {
13942 0 : ndr_print_struct(ndr, "out", "samr_Opnum72NotUsedOnWire");
13943 0 : ndr->depth++;
13944 0 : ndr->depth--;
13945 : }
13946 0 : ndr->depth--;
13947 : }
13948 :
13949 204 : _PUBLIC_ enum ndr_err_code ndr_push_samr_ChangePasswordUser4(struct ndr_push *ndr, ndr_flags_type flags, const struct samr_ChangePasswordUser4 *r)
13950 : {
13951 204 : NDR_PUSH_CHECK_FN_FLAGS(ndr, flags);
13952 204 : if (flags & NDR_IN) {
13953 90 : if (r->in.account == NULL) {
13954 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13955 : }
13956 90 : if (r->in.password == NULL) {
13957 0 : return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer");
13958 : }
13959 90 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->in.server));
13960 90 : if (r->in.server) {
13961 90 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
13962 : }
13963 90 : NDR_CHECK(ndr_push_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
13964 90 : NDR_CHECK(ndr_push_samr_EncryptedPasswordAES(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.password));
13965 : }
13966 204 : if (flags & NDR_OUT) {
13967 114 : NDR_CHECK(ndr_push_NTSTATUS(ndr, NDR_SCALARS, r->out.result));
13968 : }
13969 204 : return NDR_ERR_SUCCESS;
13970 : }
13971 :
13972 204 : _PUBLIC_ enum ndr_err_code ndr_pull_samr_ChangePasswordUser4(struct ndr_pull *ndr, ndr_flags_type flags, struct samr_ChangePasswordUser4 *r)
13973 : {
13974 0 : uint32_t _ptr_server;
13975 204 : TALLOC_CTX *_mem_save_server_0 = NULL;
13976 204 : TALLOC_CTX *_mem_save_account_0 = NULL;
13977 204 : TALLOC_CTX *_mem_save_password_0 = NULL;
13978 204 : NDR_PULL_CHECK_FN_FLAGS(ndr, flags);
13979 204 : if (flags & NDR_IN) {
13980 114 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_server));
13981 114 : if (_ptr_server) {
13982 114 : NDR_PULL_ALLOC(ndr, r->in.server);
13983 : } else {
13984 0 : r->in.server = NULL;
13985 : }
13986 114 : if (r->in.server) {
13987 114 : _mem_save_server_0 = NDR_PULL_GET_MEM_CTX(ndr);
13988 114 : NDR_PULL_SET_MEM_CTX(ndr, r->in.server, 0);
13989 114 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.server));
13990 114 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_server_0, 0);
13991 : }
13992 114 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
13993 114 : NDR_PULL_ALLOC(ndr, r->in.account);
13994 : }
13995 114 : _mem_save_account_0 = NDR_PULL_GET_MEM_CTX(ndr);
13996 114 : NDR_PULL_SET_MEM_CTX(ndr, r->in.account, LIBNDR_FLAG_REF_ALLOC);
13997 114 : NDR_CHECK(ndr_pull_lsa_String(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.account));
13998 114 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_account_0, LIBNDR_FLAG_REF_ALLOC);
13999 114 : if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) {
14000 114 : NDR_PULL_ALLOC(ndr, r->in.password);
14001 : }
14002 114 : _mem_save_password_0 = NDR_PULL_GET_MEM_CTX(ndr);
14003 114 : NDR_PULL_SET_MEM_CTX(ndr, r->in.password, LIBNDR_FLAG_REF_ALLOC);
14004 114 : NDR_CHECK(ndr_pull_samr_EncryptedPasswordAES(ndr, NDR_SCALARS|NDR_BUFFERS, r->in.password));
14005 114 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_password_0, LIBNDR_FLAG_REF_ALLOC);
14006 : }
14007 204 : if (flags & NDR_OUT) {
14008 : #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
14009 : if (r->in.account == NULL) {
14010 : NDR_PULL_ALLOC(ndr, r->in.account);
14011 : NDR_ZERO_STRUCTP(r->in.account);
14012 : }
14013 : if (r->in.password == NULL) {
14014 : NDR_PULL_ALLOC(ndr, r->in.password);
14015 : NDR_ZERO_STRUCTP(r->in.password);
14016 : }
14017 : #endif /* FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION */
14018 90 : NDR_CHECK(ndr_pull_NTSTATUS(ndr, NDR_SCALARS, &r->out.result));
14019 : }
14020 204 : return NDR_ERR_SUCCESS;
14021 : }
14022 :
14023 0 : _PUBLIC_ void ndr_print_samr_ChangePasswordUser4(struct ndr_print *ndr, const char *name, ndr_flags_type flags, const struct samr_ChangePasswordUser4 *r)
14024 : {
14025 0 : ndr_print_struct(ndr, name, "samr_ChangePasswordUser4");
14026 0 : if (r == NULL) { ndr_print_null(ndr); return; }
14027 0 : ndr->depth++;
14028 0 : if (flags & NDR_SET_VALUES) {
14029 0 : ndr->flags |= LIBNDR_PRINT_SET_VALUES;
14030 : }
14031 0 : if (flags & NDR_IN) {
14032 0 : ndr_print_struct(ndr, "in", "samr_ChangePasswordUser4");
14033 0 : ndr->depth++;
14034 0 : ndr_print_ptr(ndr, "server", r->in.server);
14035 0 : ndr->depth++;
14036 0 : if (r->in.server) {
14037 0 : ndr_print_lsa_String(ndr, "server", r->in.server);
14038 : }
14039 0 : ndr->depth--;
14040 0 : ndr_print_ptr(ndr, "account", r->in.account);
14041 0 : ndr->depth++;
14042 0 : ndr_print_lsa_String(ndr, "account", r->in.account);
14043 0 : ndr->depth--;
14044 0 : ndr_print_ptr(ndr, "password", r->in.password);
14045 0 : ndr->depth++;
14046 0 : ndr_print_samr_EncryptedPasswordAES(ndr, "password", r->in.password);
14047 0 : ndr->depth--;
14048 0 : ndr->depth--;
14049 : }
14050 0 : if (flags & NDR_OUT) {
14051 0 : ndr_print_struct(ndr, "out", "samr_ChangePasswordUser4");
14052 0 : ndr->depth++;
14053 0 : ndr_print_NTSTATUS(ndr, "result", r->out.result);
14054 0 : ndr->depth--;
14055 : }
14056 0 : ndr->depth--;
14057 : }
14058 :
14059 : #ifndef SKIP_NDR_TABLE_samr
14060 : static const struct ndr_interface_public_struct samr_public_structs[] = {
14061 : {
14062 : .name = "samr_DomInfo1",
14063 : .struct_size = sizeof(struct samr_DomInfo1 ),
14064 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_samr_DomInfo1,
14065 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_samr_DomInfo1,
14066 : .ndr_print = (ndr_print_function_t) ndr_print_flags_samr_DomInfo1,
14067 : },
14068 : {
14069 : .name = "samr_LogonHours",
14070 : .struct_size = sizeof(struct samr_LogonHours ),
14071 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_samr_LogonHours,
14072 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_samr_LogonHours,
14073 : .ndr_print = (ndr_print_function_t) ndr_print_flags_samr_LogonHours,
14074 : },
14075 : {
14076 : .name = "samr_Password",
14077 : .struct_size = sizeof(struct samr_Password ),
14078 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_samr_Password,
14079 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_samr_Password,
14080 : .ndr_print = (ndr_print_function_t) ndr_print_flags_samr_Password,
14081 : },
14082 : {
14083 : .name = "samr_CryptPassword",
14084 : .struct_size = sizeof(struct samr_CryptPassword ),
14085 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_samr_CryptPassword,
14086 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_samr_CryptPassword,
14087 : .ndr_print = (ndr_print_function_t) ndr_print_flags_samr_CryptPassword,
14088 : },
14089 : {
14090 : .name = "samr_RidWithAttribute",
14091 : .struct_size = sizeof(struct samr_RidWithAttribute ),
14092 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_samr_RidWithAttribute,
14093 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_samr_RidWithAttribute,
14094 : .ndr_print = (ndr_print_function_t) ndr_print_flags_samr_RidWithAttribute,
14095 : },
14096 : {
14097 : .name = "samr_RidWithAttributeArray",
14098 : .struct_size = sizeof(struct samr_RidWithAttributeArray ),
14099 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_samr_RidWithAttributeArray,
14100 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_samr_RidWithAttributeArray,
14101 : .ndr_print = (ndr_print_function_t) ndr_print_flags_samr_RidWithAttributeArray,
14102 : },
14103 : { .name = NULL }
14104 : };
14105 :
14106 : static const struct ndr_interface_call samr_calls[] = {
14107 : {
14108 : "samr_Connect",
14109 : sizeof(struct samr_Connect),
14110 : (ndr_push_flags_fn_t) ndr_push_samr_Connect,
14111 : (ndr_pull_flags_fn_t) ndr_pull_samr_Connect,
14112 : (ndr_print_function_t) ndr_print_samr_Connect,
14113 : { 0, NULL },
14114 : { 0, NULL },
14115 : },
14116 : {
14117 : "samr_Close",
14118 : sizeof(struct samr_Close),
14119 : (ndr_push_flags_fn_t) ndr_push_samr_Close,
14120 : (ndr_pull_flags_fn_t) ndr_pull_samr_Close,
14121 : (ndr_print_function_t) ndr_print_samr_Close,
14122 : { 0, NULL },
14123 : { 0, NULL },
14124 : },
14125 : {
14126 : "samr_SetSecurity",
14127 : sizeof(struct samr_SetSecurity),
14128 : (ndr_push_flags_fn_t) ndr_push_samr_SetSecurity,
14129 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetSecurity,
14130 : (ndr_print_function_t) ndr_print_samr_SetSecurity,
14131 : { 0, NULL },
14132 : { 0, NULL },
14133 : },
14134 : {
14135 : "samr_QuerySecurity",
14136 : sizeof(struct samr_QuerySecurity),
14137 : (ndr_push_flags_fn_t) ndr_push_samr_QuerySecurity,
14138 : (ndr_pull_flags_fn_t) ndr_pull_samr_QuerySecurity,
14139 : (ndr_print_function_t) ndr_print_samr_QuerySecurity,
14140 : { 0, NULL },
14141 : { 0, NULL },
14142 : },
14143 : {
14144 : "samr_Shutdown",
14145 : sizeof(struct samr_Shutdown),
14146 : (ndr_push_flags_fn_t) ndr_push_samr_Shutdown,
14147 : (ndr_pull_flags_fn_t) ndr_pull_samr_Shutdown,
14148 : (ndr_print_function_t) ndr_print_samr_Shutdown,
14149 : { 0, NULL },
14150 : { 0, NULL },
14151 : },
14152 : {
14153 : "samr_LookupDomain",
14154 : sizeof(struct samr_LookupDomain),
14155 : (ndr_push_flags_fn_t) ndr_push_samr_LookupDomain,
14156 : (ndr_pull_flags_fn_t) ndr_pull_samr_LookupDomain,
14157 : (ndr_print_function_t) ndr_print_samr_LookupDomain,
14158 : { 0, NULL },
14159 : { 0, NULL },
14160 : },
14161 : {
14162 : "samr_EnumDomains",
14163 : sizeof(struct samr_EnumDomains),
14164 : (ndr_push_flags_fn_t) ndr_push_samr_EnumDomains,
14165 : (ndr_pull_flags_fn_t) ndr_pull_samr_EnumDomains,
14166 : (ndr_print_function_t) ndr_print_samr_EnumDomains,
14167 : { 0, NULL },
14168 : { 0, NULL },
14169 : },
14170 : {
14171 : "samr_OpenDomain",
14172 : sizeof(struct samr_OpenDomain),
14173 : (ndr_push_flags_fn_t) ndr_push_samr_OpenDomain,
14174 : (ndr_pull_flags_fn_t) ndr_pull_samr_OpenDomain,
14175 : (ndr_print_function_t) ndr_print_samr_OpenDomain,
14176 : { 0, NULL },
14177 : { 0, NULL },
14178 : },
14179 : {
14180 : "samr_QueryDomainInfo",
14181 : sizeof(struct samr_QueryDomainInfo),
14182 : (ndr_push_flags_fn_t) ndr_push_samr_QueryDomainInfo,
14183 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryDomainInfo,
14184 : (ndr_print_function_t) ndr_print_samr_QueryDomainInfo,
14185 : { 0, NULL },
14186 : { 0, NULL },
14187 : },
14188 : {
14189 : "samr_SetDomainInfo",
14190 : sizeof(struct samr_SetDomainInfo),
14191 : (ndr_push_flags_fn_t) ndr_push_samr_SetDomainInfo,
14192 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetDomainInfo,
14193 : (ndr_print_function_t) ndr_print_samr_SetDomainInfo,
14194 : { 0, NULL },
14195 : { 0, NULL },
14196 : },
14197 : {
14198 : "samr_CreateDomainGroup",
14199 : sizeof(struct samr_CreateDomainGroup),
14200 : (ndr_push_flags_fn_t) ndr_push_samr_CreateDomainGroup,
14201 : (ndr_pull_flags_fn_t) ndr_pull_samr_CreateDomainGroup,
14202 : (ndr_print_function_t) ndr_print_samr_CreateDomainGroup,
14203 : { 0, NULL },
14204 : { 0, NULL },
14205 : },
14206 : {
14207 : "samr_EnumDomainGroups",
14208 : sizeof(struct samr_EnumDomainGroups),
14209 : (ndr_push_flags_fn_t) ndr_push_samr_EnumDomainGroups,
14210 : (ndr_pull_flags_fn_t) ndr_pull_samr_EnumDomainGroups,
14211 : (ndr_print_function_t) ndr_print_samr_EnumDomainGroups,
14212 : { 0, NULL },
14213 : { 0, NULL },
14214 : },
14215 : {
14216 : "samr_CreateUser",
14217 : sizeof(struct samr_CreateUser),
14218 : (ndr_push_flags_fn_t) ndr_push_samr_CreateUser,
14219 : (ndr_pull_flags_fn_t) ndr_pull_samr_CreateUser,
14220 : (ndr_print_function_t) ndr_print_samr_CreateUser,
14221 : { 0, NULL },
14222 : { 0, NULL },
14223 : },
14224 : {
14225 : "samr_EnumDomainUsers",
14226 : sizeof(struct samr_EnumDomainUsers),
14227 : (ndr_push_flags_fn_t) ndr_push_samr_EnumDomainUsers,
14228 : (ndr_pull_flags_fn_t) ndr_pull_samr_EnumDomainUsers,
14229 : (ndr_print_function_t) ndr_print_samr_EnumDomainUsers,
14230 : { 0, NULL },
14231 : { 0, NULL },
14232 : },
14233 : {
14234 : "samr_CreateDomAlias",
14235 : sizeof(struct samr_CreateDomAlias),
14236 : (ndr_push_flags_fn_t) ndr_push_samr_CreateDomAlias,
14237 : (ndr_pull_flags_fn_t) ndr_pull_samr_CreateDomAlias,
14238 : (ndr_print_function_t) ndr_print_samr_CreateDomAlias,
14239 : { 0, NULL },
14240 : { 0, NULL },
14241 : },
14242 : {
14243 : "samr_EnumDomainAliases",
14244 : sizeof(struct samr_EnumDomainAliases),
14245 : (ndr_push_flags_fn_t) ndr_push_samr_EnumDomainAliases,
14246 : (ndr_pull_flags_fn_t) ndr_pull_samr_EnumDomainAliases,
14247 : (ndr_print_function_t) ndr_print_samr_EnumDomainAliases,
14248 : { 0, NULL },
14249 : { 0, NULL },
14250 : },
14251 : {
14252 : "samr_GetAliasMembership",
14253 : sizeof(struct samr_GetAliasMembership),
14254 : (ndr_push_flags_fn_t) ndr_push_samr_GetAliasMembership,
14255 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetAliasMembership,
14256 : (ndr_print_function_t) ndr_print_samr_GetAliasMembership,
14257 : { 0, NULL },
14258 : { 0, NULL },
14259 : },
14260 : {
14261 : "samr_LookupNames",
14262 : sizeof(struct samr_LookupNames),
14263 : (ndr_push_flags_fn_t) ndr_push_samr_LookupNames,
14264 : (ndr_pull_flags_fn_t) ndr_pull_samr_LookupNames,
14265 : (ndr_print_function_t) ndr_print_samr_LookupNames,
14266 : { 0, NULL },
14267 : { 0, NULL },
14268 : },
14269 : {
14270 : "samr_LookupRids",
14271 : sizeof(struct samr_LookupRids),
14272 : (ndr_push_flags_fn_t) ndr_push_samr_LookupRids,
14273 : (ndr_pull_flags_fn_t) ndr_pull_samr_LookupRids,
14274 : (ndr_print_function_t) ndr_print_samr_LookupRids,
14275 : { 0, NULL },
14276 : { 0, NULL },
14277 : },
14278 : {
14279 : "samr_OpenGroup",
14280 : sizeof(struct samr_OpenGroup),
14281 : (ndr_push_flags_fn_t) ndr_push_samr_OpenGroup,
14282 : (ndr_pull_flags_fn_t) ndr_pull_samr_OpenGroup,
14283 : (ndr_print_function_t) ndr_print_samr_OpenGroup,
14284 : { 0, NULL },
14285 : { 0, NULL },
14286 : },
14287 : {
14288 : "samr_QueryGroupInfo",
14289 : sizeof(struct samr_QueryGroupInfo),
14290 : (ndr_push_flags_fn_t) ndr_push_samr_QueryGroupInfo,
14291 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryGroupInfo,
14292 : (ndr_print_function_t) ndr_print_samr_QueryGroupInfo,
14293 : { 0, NULL },
14294 : { 0, NULL },
14295 : },
14296 : {
14297 : "samr_SetGroupInfo",
14298 : sizeof(struct samr_SetGroupInfo),
14299 : (ndr_push_flags_fn_t) ndr_push_samr_SetGroupInfo,
14300 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetGroupInfo,
14301 : (ndr_print_function_t) ndr_print_samr_SetGroupInfo,
14302 : { 0, NULL },
14303 : { 0, NULL },
14304 : },
14305 : {
14306 : "samr_AddGroupMember",
14307 : sizeof(struct samr_AddGroupMember),
14308 : (ndr_push_flags_fn_t) ndr_push_samr_AddGroupMember,
14309 : (ndr_pull_flags_fn_t) ndr_pull_samr_AddGroupMember,
14310 : (ndr_print_function_t) ndr_print_samr_AddGroupMember,
14311 : { 0, NULL },
14312 : { 0, NULL },
14313 : },
14314 : {
14315 : "samr_DeleteDomainGroup",
14316 : sizeof(struct samr_DeleteDomainGroup),
14317 : (ndr_push_flags_fn_t) ndr_push_samr_DeleteDomainGroup,
14318 : (ndr_pull_flags_fn_t) ndr_pull_samr_DeleteDomainGroup,
14319 : (ndr_print_function_t) ndr_print_samr_DeleteDomainGroup,
14320 : { 0, NULL },
14321 : { 0, NULL },
14322 : },
14323 : {
14324 : "samr_DeleteGroupMember",
14325 : sizeof(struct samr_DeleteGroupMember),
14326 : (ndr_push_flags_fn_t) ndr_push_samr_DeleteGroupMember,
14327 : (ndr_pull_flags_fn_t) ndr_pull_samr_DeleteGroupMember,
14328 : (ndr_print_function_t) ndr_print_samr_DeleteGroupMember,
14329 : { 0, NULL },
14330 : { 0, NULL },
14331 : },
14332 : {
14333 : "samr_QueryGroupMember",
14334 : sizeof(struct samr_QueryGroupMember),
14335 : (ndr_push_flags_fn_t) ndr_push_samr_QueryGroupMember,
14336 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryGroupMember,
14337 : (ndr_print_function_t) ndr_print_samr_QueryGroupMember,
14338 : { 0, NULL },
14339 : { 0, NULL },
14340 : },
14341 : {
14342 : "samr_SetMemberAttributesOfGroup",
14343 : sizeof(struct samr_SetMemberAttributesOfGroup),
14344 : (ndr_push_flags_fn_t) ndr_push_samr_SetMemberAttributesOfGroup,
14345 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetMemberAttributesOfGroup,
14346 : (ndr_print_function_t) ndr_print_samr_SetMemberAttributesOfGroup,
14347 : { 0, NULL },
14348 : { 0, NULL },
14349 : },
14350 : {
14351 : "samr_OpenAlias",
14352 : sizeof(struct samr_OpenAlias),
14353 : (ndr_push_flags_fn_t) ndr_push_samr_OpenAlias,
14354 : (ndr_pull_flags_fn_t) ndr_pull_samr_OpenAlias,
14355 : (ndr_print_function_t) ndr_print_samr_OpenAlias,
14356 : { 0, NULL },
14357 : { 0, NULL },
14358 : },
14359 : {
14360 : "samr_QueryAliasInfo",
14361 : sizeof(struct samr_QueryAliasInfo),
14362 : (ndr_push_flags_fn_t) ndr_push_samr_QueryAliasInfo,
14363 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryAliasInfo,
14364 : (ndr_print_function_t) ndr_print_samr_QueryAliasInfo,
14365 : { 0, NULL },
14366 : { 0, NULL },
14367 : },
14368 : {
14369 : "samr_SetAliasInfo",
14370 : sizeof(struct samr_SetAliasInfo),
14371 : (ndr_push_flags_fn_t) ndr_push_samr_SetAliasInfo,
14372 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetAliasInfo,
14373 : (ndr_print_function_t) ndr_print_samr_SetAliasInfo,
14374 : { 0, NULL },
14375 : { 0, NULL },
14376 : },
14377 : {
14378 : "samr_DeleteDomAlias",
14379 : sizeof(struct samr_DeleteDomAlias),
14380 : (ndr_push_flags_fn_t) ndr_push_samr_DeleteDomAlias,
14381 : (ndr_pull_flags_fn_t) ndr_pull_samr_DeleteDomAlias,
14382 : (ndr_print_function_t) ndr_print_samr_DeleteDomAlias,
14383 : { 0, NULL },
14384 : { 0, NULL },
14385 : },
14386 : {
14387 : "samr_AddAliasMember",
14388 : sizeof(struct samr_AddAliasMember),
14389 : (ndr_push_flags_fn_t) ndr_push_samr_AddAliasMember,
14390 : (ndr_pull_flags_fn_t) ndr_pull_samr_AddAliasMember,
14391 : (ndr_print_function_t) ndr_print_samr_AddAliasMember,
14392 : { 0, NULL },
14393 : { 0, NULL },
14394 : },
14395 : {
14396 : "samr_DeleteAliasMember",
14397 : sizeof(struct samr_DeleteAliasMember),
14398 : (ndr_push_flags_fn_t) ndr_push_samr_DeleteAliasMember,
14399 : (ndr_pull_flags_fn_t) ndr_pull_samr_DeleteAliasMember,
14400 : (ndr_print_function_t) ndr_print_samr_DeleteAliasMember,
14401 : { 0, NULL },
14402 : { 0, NULL },
14403 : },
14404 : {
14405 : "samr_GetMembersInAlias",
14406 : sizeof(struct samr_GetMembersInAlias),
14407 : (ndr_push_flags_fn_t) ndr_push_samr_GetMembersInAlias,
14408 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetMembersInAlias,
14409 : (ndr_print_function_t) ndr_print_samr_GetMembersInAlias,
14410 : { 0, NULL },
14411 : { 0, NULL },
14412 : },
14413 : {
14414 : "samr_OpenUser",
14415 : sizeof(struct samr_OpenUser),
14416 : (ndr_push_flags_fn_t) ndr_push_samr_OpenUser,
14417 : (ndr_pull_flags_fn_t) ndr_pull_samr_OpenUser,
14418 : (ndr_print_function_t) ndr_print_samr_OpenUser,
14419 : { 0, NULL },
14420 : { 0, NULL },
14421 : },
14422 : {
14423 : "samr_DeleteUser",
14424 : sizeof(struct samr_DeleteUser),
14425 : (ndr_push_flags_fn_t) ndr_push_samr_DeleteUser,
14426 : (ndr_pull_flags_fn_t) ndr_pull_samr_DeleteUser,
14427 : (ndr_print_function_t) ndr_print_samr_DeleteUser,
14428 : { 0, NULL },
14429 : { 0, NULL },
14430 : },
14431 : {
14432 : "samr_QueryUserInfo",
14433 : sizeof(struct samr_QueryUserInfo),
14434 : (ndr_push_flags_fn_t) ndr_push_samr_QueryUserInfo,
14435 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryUserInfo,
14436 : (ndr_print_function_t) ndr_print_samr_QueryUserInfo,
14437 : { 0, NULL },
14438 : { 0, NULL },
14439 : },
14440 : {
14441 : "samr_SetUserInfo",
14442 : sizeof(struct samr_SetUserInfo),
14443 : (ndr_push_flags_fn_t) ndr_push_samr_SetUserInfo,
14444 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetUserInfo,
14445 : (ndr_print_function_t) ndr_print_samr_SetUserInfo,
14446 : { 0, NULL },
14447 : { 0, NULL },
14448 : },
14449 : {
14450 : "samr_ChangePasswordUser",
14451 : sizeof(struct samr_ChangePasswordUser),
14452 : (ndr_push_flags_fn_t) ndr_push_samr_ChangePasswordUser,
14453 : (ndr_pull_flags_fn_t) ndr_pull_samr_ChangePasswordUser,
14454 : (ndr_print_function_t) ndr_print_samr_ChangePasswordUser,
14455 : { 0, NULL },
14456 : { 0, NULL },
14457 : },
14458 : {
14459 : "samr_GetGroupsForUser",
14460 : sizeof(struct samr_GetGroupsForUser),
14461 : (ndr_push_flags_fn_t) ndr_push_samr_GetGroupsForUser,
14462 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetGroupsForUser,
14463 : (ndr_print_function_t) ndr_print_samr_GetGroupsForUser,
14464 : { 0, NULL },
14465 : { 0, NULL },
14466 : },
14467 : {
14468 : "samr_QueryDisplayInfo",
14469 : sizeof(struct samr_QueryDisplayInfo),
14470 : (ndr_push_flags_fn_t) ndr_push_samr_QueryDisplayInfo,
14471 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryDisplayInfo,
14472 : (ndr_print_function_t) ndr_print_samr_QueryDisplayInfo,
14473 : { 0, NULL },
14474 : { 0, NULL },
14475 : },
14476 : {
14477 : "samr_GetDisplayEnumerationIndex",
14478 : sizeof(struct samr_GetDisplayEnumerationIndex),
14479 : (ndr_push_flags_fn_t) ndr_push_samr_GetDisplayEnumerationIndex,
14480 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetDisplayEnumerationIndex,
14481 : (ndr_print_function_t) ndr_print_samr_GetDisplayEnumerationIndex,
14482 : { 0, NULL },
14483 : { 0, NULL },
14484 : },
14485 : {
14486 : "samr_TestPrivateFunctionsDomain",
14487 : sizeof(struct samr_TestPrivateFunctionsDomain),
14488 : (ndr_push_flags_fn_t) ndr_push_samr_TestPrivateFunctionsDomain,
14489 : (ndr_pull_flags_fn_t) ndr_pull_samr_TestPrivateFunctionsDomain,
14490 : (ndr_print_function_t) ndr_print_samr_TestPrivateFunctionsDomain,
14491 : { 0, NULL },
14492 : { 0, NULL },
14493 : },
14494 : {
14495 : "samr_TestPrivateFunctionsUser",
14496 : sizeof(struct samr_TestPrivateFunctionsUser),
14497 : (ndr_push_flags_fn_t) ndr_push_samr_TestPrivateFunctionsUser,
14498 : (ndr_pull_flags_fn_t) ndr_pull_samr_TestPrivateFunctionsUser,
14499 : (ndr_print_function_t) ndr_print_samr_TestPrivateFunctionsUser,
14500 : { 0, NULL },
14501 : { 0, NULL },
14502 : },
14503 : {
14504 : "samr_GetUserPwInfo",
14505 : sizeof(struct samr_GetUserPwInfo),
14506 : (ndr_push_flags_fn_t) ndr_push_samr_GetUserPwInfo,
14507 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetUserPwInfo,
14508 : (ndr_print_function_t) ndr_print_samr_GetUserPwInfo,
14509 : { 0, NULL },
14510 : { 0, NULL },
14511 : },
14512 : {
14513 : "samr_RemoveMemberFromForeignDomain",
14514 : sizeof(struct samr_RemoveMemberFromForeignDomain),
14515 : (ndr_push_flags_fn_t) ndr_push_samr_RemoveMemberFromForeignDomain,
14516 : (ndr_pull_flags_fn_t) ndr_pull_samr_RemoveMemberFromForeignDomain,
14517 : (ndr_print_function_t) ndr_print_samr_RemoveMemberFromForeignDomain,
14518 : { 0, NULL },
14519 : { 0, NULL },
14520 : },
14521 : {
14522 : "samr_QueryDomainInfo2",
14523 : sizeof(struct samr_QueryDomainInfo2),
14524 : (ndr_push_flags_fn_t) ndr_push_samr_QueryDomainInfo2,
14525 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryDomainInfo2,
14526 : (ndr_print_function_t) ndr_print_samr_QueryDomainInfo2,
14527 : { 0, NULL },
14528 : { 0, NULL },
14529 : },
14530 : {
14531 : "samr_QueryUserInfo2",
14532 : sizeof(struct samr_QueryUserInfo2),
14533 : (ndr_push_flags_fn_t) ndr_push_samr_QueryUserInfo2,
14534 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryUserInfo2,
14535 : (ndr_print_function_t) ndr_print_samr_QueryUserInfo2,
14536 : { 0, NULL },
14537 : { 0, NULL },
14538 : },
14539 : {
14540 : "samr_QueryDisplayInfo2",
14541 : sizeof(struct samr_QueryDisplayInfo2),
14542 : (ndr_push_flags_fn_t) ndr_push_samr_QueryDisplayInfo2,
14543 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryDisplayInfo2,
14544 : (ndr_print_function_t) ndr_print_samr_QueryDisplayInfo2,
14545 : { 0, NULL },
14546 : { 0, NULL },
14547 : },
14548 : {
14549 : "samr_GetDisplayEnumerationIndex2",
14550 : sizeof(struct samr_GetDisplayEnumerationIndex2),
14551 : (ndr_push_flags_fn_t) ndr_push_samr_GetDisplayEnumerationIndex2,
14552 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetDisplayEnumerationIndex2,
14553 : (ndr_print_function_t) ndr_print_samr_GetDisplayEnumerationIndex2,
14554 : { 0, NULL },
14555 : { 0, NULL },
14556 : },
14557 : {
14558 : "samr_CreateUser2",
14559 : sizeof(struct samr_CreateUser2),
14560 : (ndr_push_flags_fn_t) ndr_push_samr_CreateUser2,
14561 : (ndr_pull_flags_fn_t) ndr_pull_samr_CreateUser2,
14562 : (ndr_print_function_t) ndr_print_samr_CreateUser2,
14563 : { 0, NULL },
14564 : { 0, NULL },
14565 : },
14566 : {
14567 : "samr_QueryDisplayInfo3",
14568 : sizeof(struct samr_QueryDisplayInfo3),
14569 : (ndr_push_flags_fn_t) ndr_push_samr_QueryDisplayInfo3,
14570 : (ndr_pull_flags_fn_t) ndr_pull_samr_QueryDisplayInfo3,
14571 : (ndr_print_function_t) ndr_print_samr_QueryDisplayInfo3,
14572 : { 0, NULL },
14573 : { 0, NULL },
14574 : },
14575 : {
14576 : "samr_AddMultipleMembersToAlias",
14577 : sizeof(struct samr_AddMultipleMembersToAlias),
14578 : (ndr_push_flags_fn_t) ndr_push_samr_AddMultipleMembersToAlias,
14579 : (ndr_pull_flags_fn_t) ndr_pull_samr_AddMultipleMembersToAlias,
14580 : (ndr_print_function_t) ndr_print_samr_AddMultipleMembersToAlias,
14581 : { 0, NULL },
14582 : { 0, NULL },
14583 : },
14584 : {
14585 : "samr_RemoveMultipleMembersFromAlias",
14586 : sizeof(struct samr_RemoveMultipleMembersFromAlias),
14587 : (ndr_push_flags_fn_t) ndr_push_samr_RemoveMultipleMembersFromAlias,
14588 : (ndr_pull_flags_fn_t) ndr_pull_samr_RemoveMultipleMembersFromAlias,
14589 : (ndr_print_function_t) ndr_print_samr_RemoveMultipleMembersFromAlias,
14590 : { 0, NULL },
14591 : { 0, NULL },
14592 : },
14593 : {
14594 : "samr_OemChangePasswordUser2",
14595 : sizeof(struct samr_OemChangePasswordUser2),
14596 : (ndr_push_flags_fn_t) ndr_push_samr_OemChangePasswordUser2,
14597 : (ndr_pull_flags_fn_t) ndr_pull_samr_OemChangePasswordUser2,
14598 : (ndr_print_function_t) ndr_print_samr_OemChangePasswordUser2,
14599 : { 0, NULL },
14600 : { 0, NULL },
14601 : },
14602 : {
14603 : "samr_ChangePasswordUser2",
14604 : sizeof(struct samr_ChangePasswordUser2),
14605 : (ndr_push_flags_fn_t) ndr_push_samr_ChangePasswordUser2,
14606 : (ndr_pull_flags_fn_t) ndr_pull_samr_ChangePasswordUser2,
14607 : (ndr_print_function_t) ndr_print_samr_ChangePasswordUser2,
14608 : { 0, NULL },
14609 : { 0, NULL },
14610 : },
14611 : {
14612 : "samr_GetDomPwInfo",
14613 : sizeof(struct samr_GetDomPwInfo),
14614 : (ndr_push_flags_fn_t) ndr_push_samr_GetDomPwInfo,
14615 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetDomPwInfo,
14616 : (ndr_print_function_t) ndr_print_samr_GetDomPwInfo,
14617 : { 0, NULL },
14618 : { 0, NULL },
14619 : },
14620 : {
14621 : "samr_Connect2",
14622 : sizeof(struct samr_Connect2),
14623 : (ndr_push_flags_fn_t) ndr_push_samr_Connect2,
14624 : (ndr_pull_flags_fn_t) ndr_pull_samr_Connect2,
14625 : (ndr_print_function_t) ndr_print_samr_Connect2,
14626 : { 0, NULL },
14627 : { 0, NULL },
14628 : },
14629 : {
14630 : "samr_SetUserInfo2",
14631 : sizeof(struct samr_SetUserInfo2),
14632 : (ndr_push_flags_fn_t) ndr_push_samr_SetUserInfo2,
14633 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetUserInfo2,
14634 : (ndr_print_function_t) ndr_print_samr_SetUserInfo2,
14635 : { 0, NULL },
14636 : { 0, NULL },
14637 : },
14638 : {
14639 : "samr_SetBootKeyInformation",
14640 : sizeof(struct samr_SetBootKeyInformation),
14641 : (ndr_push_flags_fn_t) ndr_push_samr_SetBootKeyInformation,
14642 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetBootKeyInformation,
14643 : (ndr_print_function_t) ndr_print_samr_SetBootKeyInformation,
14644 : { 0, NULL },
14645 : { 0, NULL },
14646 : },
14647 : {
14648 : "samr_GetBootKeyInformation",
14649 : sizeof(struct samr_GetBootKeyInformation),
14650 : (ndr_push_flags_fn_t) ndr_push_samr_GetBootKeyInformation,
14651 : (ndr_pull_flags_fn_t) ndr_pull_samr_GetBootKeyInformation,
14652 : (ndr_print_function_t) ndr_print_samr_GetBootKeyInformation,
14653 : { 0, NULL },
14654 : { 0, NULL },
14655 : },
14656 : {
14657 : "samr_Connect3",
14658 : sizeof(struct samr_Connect3),
14659 : (ndr_push_flags_fn_t) ndr_push_samr_Connect3,
14660 : (ndr_pull_flags_fn_t) ndr_pull_samr_Connect3,
14661 : (ndr_print_function_t) ndr_print_samr_Connect3,
14662 : { 0, NULL },
14663 : { 0, NULL },
14664 : },
14665 : {
14666 : "samr_Connect4",
14667 : sizeof(struct samr_Connect4),
14668 : (ndr_push_flags_fn_t) ndr_push_samr_Connect4,
14669 : (ndr_pull_flags_fn_t) ndr_pull_samr_Connect4,
14670 : (ndr_print_function_t) ndr_print_samr_Connect4,
14671 : { 0, NULL },
14672 : { 0, NULL },
14673 : },
14674 : {
14675 : "samr_ChangePasswordUser3",
14676 : sizeof(struct samr_ChangePasswordUser3),
14677 : (ndr_push_flags_fn_t) ndr_push_samr_ChangePasswordUser3,
14678 : (ndr_pull_flags_fn_t) ndr_pull_samr_ChangePasswordUser3,
14679 : (ndr_print_function_t) ndr_print_samr_ChangePasswordUser3,
14680 : { 0, NULL },
14681 : { 0, NULL },
14682 : },
14683 : {
14684 : "samr_Connect5",
14685 : sizeof(struct samr_Connect5),
14686 : (ndr_push_flags_fn_t) ndr_push_samr_Connect5,
14687 : (ndr_pull_flags_fn_t) ndr_pull_samr_Connect5,
14688 : (ndr_print_function_t) ndr_print_samr_Connect5,
14689 : { 0, NULL },
14690 : { 0, NULL },
14691 : },
14692 : {
14693 : "samr_RidToSid",
14694 : sizeof(struct samr_RidToSid),
14695 : (ndr_push_flags_fn_t) ndr_push_samr_RidToSid,
14696 : (ndr_pull_flags_fn_t) ndr_pull_samr_RidToSid,
14697 : (ndr_print_function_t) ndr_print_samr_RidToSid,
14698 : { 0, NULL },
14699 : { 0, NULL },
14700 : },
14701 : {
14702 : "samr_SetDsrmPassword",
14703 : sizeof(struct samr_SetDsrmPassword),
14704 : (ndr_push_flags_fn_t) ndr_push_samr_SetDsrmPassword,
14705 : (ndr_pull_flags_fn_t) ndr_pull_samr_SetDsrmPassword,
14706 : (ndr_print_function_t) ndr_print_samr_SetDsrmPassword,
14707 : { 0, NULL },
14708 : { 0, NULL },
14709 : },
14710 : {
14711 : "samr_ValidatePassword",
14712 : sizeof(struct samr_ValidatePassword),
14713 : (ndr_push_flags_fn_t) ndr_push_samr_ValidatePassword,
14714 : (ndr_pull_flags_fn_t) ndr_pull_samr_ValidatePassword,
14715 : (ndr_print_function_t) ndr_print_samr_ValidatePassword,
14716 : { 0, NULL },
14717 : { 0, NULL },
14718 : },
14719 : {
14720 : "samr_Opnum68NotUsedOnWire",
14721 : sizeof(struct samr_Opnum68NotUsedOnWire),
14722 : (ndr_push_flags_fn_t) ndr_push_samr_Opnum68NotUsedOnWire,
14723 : (ndr_pull_flags_fn_t) ndr_pull_samr_Opnum68NotUsedOnWire,
14724 : (ndr_print_function_t) ndr_print_samr_Opnum68NotUsedOnWire,
14725 : { 0, NULL },
14726 : { 0, NULL },
14727 : },
14728 : {
14729 : "samr_Opnum69NotUsedOnWire",
14730 : sizeof(struct samr_Opnum69NotUsedOnWire),
14731 : (ndr_push_flags_fn_t) ndr_push_samr_Opnum69NotUsedOnWire,
14732 : (ndr_pull_flags_fn_t) ndr_pull_samr_Opnum69NotUsedOnWire,
14733 : (ndr_print_function_t) ndr_print_samr_Opnum69NotUsedOnWire,
14734 : { 0, NULL },
14735 : { 0, NULL },
14736 : },
14737 : {
14738 : "samr_Opnum70NotUsedOnWire",
14739 : sizeof(struct samr_Opnum70NotUsedOnWire),
14740 : (ndr_push_flags_fn_t) ndr_push_samr_Opnum70NotUsedOnWire,
14741 : (ndr_pull_flags_fn_t) ndr_pull_samr_Opnum70NotUsedOnWire,
14742 : (ndr_print_function_t) ndr_print_samr_Opnum70NotUsedOnWire,
14743 : { 0, NULL },
14744 : { 0, NULL },
14745 : },
14746 : {
14747 : "samr_Opnum71NotUsedOnWire",
14748 : sizeof(struct samr_Opnum71NotUsedOnWire),
14749 : (ndr_push_flags_fn_t) ndr_push_samr_Opnum71NotUsedOnWire,
14750 : (ndr_pull_flags_fn_t) ndr_pull_samr_Opnum71NotUsedOnWire,
14751 : (ndr_print_function_t) ndr_print_samr_Opnum71NotUsedOnWire,
14752 : { 0, NULL },
14753 : { 0, NULL },
14754 : },
14755 : {
14756 : "samr_Opnum72NotUsedOnWire",
14757 : sizeof(struct samr_Opnum72NotUsedOnWire),
14758 : (ndr_push_flags_fn_t) ndr_push_samr_Opnum72NotUsedOnWire,
14759 : (ndr_pull_flags_fn_t) ndr_pull_samr_Opnum72NotUsedOnWire,
14760 : (ndr_print_function_t) ndr_print_samr_Opnum72NotUsedOnWire,
14761 : { 0, NULL },
14762 : { 0, NULL },
14763 : },
14764 : {
14765 : "samr_ChangePasswordUser4",
14766 : sizeof(struct samr_ChangePasswordUser4),
14767 : (ndr_push_flags_fn_t) ndr_push_samr_ChangePasswordUser4,
14768 : (ndr_pull_flags_fn_t) ndr_pull_samr_ChangePasswordUser4,
14769 : (ndr_print_function_t) ndr_print_samr_ChangePasswordUser4,
14770 : { 0, NULL },
14771 : { 0, NULL },
14772 : },
14773 : { .name = NULL }
14774 : };
14775 :
14776 : static const char * const samr_endpoint_strings[] = {
14777 : "ncacn_np:[\\pipe\\samr]",
14778 : "ncacn_ip_tcp:",
14779 : "ncalrpc:",
14780 : };
14781 :
14782 : static const struct ndr_interface_string_array samr_endpoints = {
14783 : .count = 3,
14784 : .names = samr_endpoint_strings
14785 : };
14786 :
14787 : static const char * const samr_authservice_strings[] = {
14788 : "host",
14789 : };
14790 :
14791 : static const struct ndr_interface_string_array samr_authservices = {
14792 : .count = 1,
14793 : .names = samr_authservice_strings
14794 : };
14795 :
14796 :
14797 : const struct ndr_interface_table ndr_table_samr = {
14798 : .name = "samr",
14799 : .syntax_id = {
14800 : {0x12345778,0x1234,0xabcd,{0xef,0x00},{0x01,0x23,0x45,0x67,0x89,0xac}},
14801 : NDR_SAMR_VERSION
14802 : },
14803 : .helpstring = NDR_SAMR_HELPSTRING,
14804 : .num_calls = 74,
14805 : .calls = samr_calls,
14806 : .num_public_structs = 6,
14807 : .public_structs = samr_public_structs,
14808 : .endpoints = &samr_endpoints,
14809 : .authservices = &samr_authservices
14810 : };
14811 :
14812 : #endif /* SKIP_NDR_TABLE_samr */
|