Line data Source code
1 : /* parser auto-generated by pidl */
2 :
3 : #include "includes.h"
4 : #include "bin/default/librpc/gen_ndr/ndr_conditional_ace.h"
5 :
6 : #include "librpc/gen_ndr/ndr_security.h"
7 0 : static enum ndr_err_code ndr_push_token_type(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum token_type r)
8 : {
9 0 : NDR_CHECK(ndr_push_enum_uint8(ndr, NDR_SCALARS, r));
10 0 : return NDR_ERR_SUCCESS;
11 : }
12 :
13 0 : static enum ndr_err_code ndr_pull_token_type(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum token_type *r)
14 : {
15 0 : uint8_t v;
16 0 : NDR_CHECK(ndr_pull_enum_uint8(ndr, NDR_SCALARS, &v));
17 0 : *r = v;
18 0 : return NDR_ERR_SUCCESS;
19 : }
20 :
21 0 : _PUBLIC_ void ndr_print_token_type(struct ndr_print *ndr, const char *name, enum token_type r)
22 : {
23 0 : const char *val = NULL;
24 :
25 0 : switch (r) {
26 0 : case CONDITIONAL_ACE_TOKEN_INVALID_OR_PADDING: val = "CONDITIONAL_ACE_TOKEN_INVALID_OR_PADDING"; break;
27 0 : case CONDITIONAL_ACE_TOKEN_INT8: val = "CONDITIONAL_ACE_TOKEN_INT8"; break;
28 0 : case CONDITIONAL_ACE_TOKEN_INT16: val = "CONDITIONAL_ACE_TOKEN_INT16"; break;
29 0 : case CONDITIONAL_ACE_TOKEN_INT32: val = "CONDITIONAL_ACE_TOKEN_INT32"; break;
30 0 : case CONDITIONAL_ACE_TOKEN_INT64: val = "CONDITIONAL_ACE_TOKEN_INT64"; break;
31 0 : case CONDITIONAL_ACE_TOKEN_UNICODE: val = "CONDITIONAL_ACE_TOKEN_UNICODE"; break;
32 0 : case CONDITIONAL_ACE_TOKEN_OCTET_STRING: val = "CONDITIONAL_ACE_TOKEN_OCTET_STRING"; break;
33 0 : case CONDITIONAL_ACE_TOKEN_COMPOSITE: val = "CONDITIONAL_ACE_TOKEN_COMPOSITE"; break;
34 0 : case CONDITIONAL_ACE_TOKEN_SID: val = "CONDITIONAL_ACE_TOKEN_SID"; break;
35 0 : case CONDITIONAL_ACE_LOCAL_ATTRIBUTE: val = "CONDITIONAL_ACE_LOCAL_ATTRIBUTE"; break;
36 0 : case CONDITIONAL_ACE_USER_ATTRIBUTE: val = "CONDITIONAL_ACE_USER_ATTRIBUTE"; break;
37 0 : case CONDITIONAL_ACE_RESOURCE_ATTRIBUTE: val = "CONDITIONAL_ACE_RESOURCE_ATTRIBUTE"; break;
38 0 : case CONDITIONAL_ACE_DEVICE_ATTRIBUTE: val = "CONDITIONAL_ACE_DEVICE_ATTRIBUTE"; break;
39 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF: val = "CONDITIONAL_ACE_TOKEN_MEMBER_OF"; break;
40 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF: val = "CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF"; break;
41 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF_ANY: val = "CONDITIONAL_ACE_TOKEN_MEMBER_OF_ANY"; break;
42 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF_ANY: val = "CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF_ANY"; break;
43 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF: val = "CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF"; break;
44 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF: val = "CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF"; break;
45 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF_ANY: val = "CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF_ANY"; break;
46 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF_ANY: val = "CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF_ANY"; break;
47 0 : case CONDITIONAL_ACE_TOKEN_EQUAL: val = "CONDITIONAL_ACE_TOKEN_EQUAL"; break;
48 0 : case CONDITIONAL_ACE_TOKEN_NOT_EQUAL: val = "CONDITIONAL_ACE_TOKEN_NOT_EQUAL"; break;
49 0 : case CONDITIONAL_ACE_TOKEN_LESS_THAN: val = "CONDITIONAL_ACE_TOKEN_LESS_THAN"; break;
50 0 : case CONDITIONAL_ACE_TOKEN_LESS_OR_EQUAL: val = "CONDITIONAL_ACE_TOKEN_LESS_OR_EQUAL"; break;
51 0 : case CONDITIONAL_ACE_TOKEN_GREATER_THAN: val = "CONDITIONAL_ACE_TOKEN_GREATER_THAN"; break;
52 0 : case CONDITIONAL_ACE_TOKEN_GREATER_OR_EQUAL: val = "CONDITIONAL_ACE_TOKEN_GREATER_OR_EQUAL"; break;
53 0 : case CONDITIONAL_ACE_TOKEN_CONTAINS: val = "CONDITIONAL_ACE_TOKEN_CONTAINS"; break;
54 0 : case CONDITIONAL_ACE_TOKEN_ANY_OF: val = "CONDITIONAL_ACE_TOKEN_ANY_OF"; break;
55 0 : case CONDITIONAL_ACE_TOKEN_NOT_CONTAINS: val = "CONDITIONAL_ACE_TOKEN_NOT_CONTAINS"; break;
56 0 : case CONDITIONAL_ACE_TOKEN_NOT_ANY_OF: val = "CONDITIONAL_ACE_TOKEN_NOT_ANY_OF"; break;
57 0 : case CONDITIONAL_ACE_TOKEN_EXISTS: val = "CONDITIONAL_ACE_TOKEN_EXISTS"; break;
58 0 : case CONDITIONAL_ACE_TOKEN_NOT_EXISTS: val = "CONDITIONAL_ACE_TOKEN_NOT_EXISTS"; break;
59 0 : case CONDITIONAL_ACE_TOKEN_NOT: val = "CONDITIONAL_ACE_TOKEN_NOT"; break;
60 0 : case CONDITIONAL_ACE_TOKEN_AND: val = "CONDITIONAL_ACE_TOKEN_AND"; break;
61 0 : case CONDITIONAL_ACE_TOKEN_OR: val = "CONDITIONAL_ACE_TOKEN_OR"; break;
62 0 : case CONDITIONAL_ACE_SAMBA_RESULT_BOOL: val = "CONDITIONAL_ACE_SAMBA_RESULT_BOOL"; break;
63 0 : case CONDITIONAL_ACE_SAMBA_RESULT_NULL: val = "CONDITIONAL_ACE_SAMBA_RESULT_NULL"; break;
64 0 : case CONDITIONAL_ACE_SAMBA_RESULT_ERROR: val = "CONDITIONAL_ACE_SAMBA_RESULT_ERROR"; break;
65 0 : case CONDITIONAL_ACE_SAMBA_SDDL_PAREN: val = "CONDITIONAL_ACE_SAMBA_SDDL_PAREN"; break;
66 0 : case CONDITIONAL_ACE_SAMBA_SDDL_PAREN_END: val = "CONDITIONAL_ACE_SAMBA_SDDL_PAREN_END"; break;
67 : }
68 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
69 0 : }
70 :
71 0 : static enum ndr_err_code ndr_push_ace_condition_result(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_result *r)
72 : {
73 : {
74 0 : libndr_flags _flags_save_STRUCT = ndr->flags;
75 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_NOALIGN);
76 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
77 0 : if (ndr_flags & NDR_SCALARS) {
78 0 : NDR_CHECK(ndr_push_align(ndr, 8));
79 0 : NDR_CHECK(ndr_push_int64(ndr, NDR_SCALARS, r->value));
80 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
81 : }
82 0 : if (ndr_flags & NDR_BUFFERS) {
83 0 : }
84 0 : ndr->flags = _flags_save_STRUCT;
85 : }
86 0 : return NDR_ERR_SUCCESS;
87 : }
88 :
89 0 : static enum ndr_err_code ndr_pull_ace_condition_result(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_result *r)
90 : {
91 : {
92 0 : libndr_flags _flags_save_STRUCT = ndr->flags;
93 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_NOALIGN);
94 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
95 0 : if (ndr_flags & NDR_SCALARS) {
96 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
97 0 : NDR_CHECK(ndr_pull_int64(ndr, NDR_SCALARS, &r->value));
98 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
99 : }
100 0 : if (ndr_flags & NDR_BUFFERS) {
101 0 : }
102 0 : ndr->flags = _flags_save_STRUCT;
103 : }
104 0 : return NDR_ERR_SUCCESS;
105 : }
106 :
107 0 : _PUBLIC_ void ndr_print_ace_condition_result(struct ndr_print *ndr, const char *name, const struct ace_condition_result *r)
108 : {
109 0 : ndr_print_struct(ndr, name, "ace_condition_result");
110 0 : if (r == NULL) { ndr_print_null(ndr); return; }
111 : {
112 0 : libndr_flags _flags_save_STRUCT = ndr->flags;
113 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_NOALIGN);
114 0 : ndr->depth++;
115 0 : ndr_print_int64(ndr, "value", r->value);
116 0 : ndr->depth--;
117 0 : ndr->flags = _flags_save_STRUCT;
118 : }
119 : }
120 :
121 636 : _PUBLIC_ enum ndr_err_code ndr_push_ace_condition_int(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_int *r)
122 : {
123 636 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
124 636 : if (ndr_flags & NDR_SCALARS) {
125 636 : NDR_CHECK(ndr_push_align(ndr, 8));
126 636 : NDR_CHECK(ndr_push_int64(ndr, NDR_SCALARS, r->value));
127 636 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->sign));
128 636 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r->base));
129 636 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
130 : }
131 636 : if (ndr_flags & NDR_BUFFERS) {
132 564 : }
133 636 : return NDR_ERR_SUCCESS;
134 : }
135 :
136 156 : _PUBLIC_ enum ndr_err_code ndr_pull_ace_condition_int(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_int *r)
137 : {
138 156 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
139 156 : if (ndr_flags & NDR_SCALARS) {
140 156 : NDR_CHECK(ndr_pull_align(ndr, 8));
141 156 : NDR_CHECK(ndr_pull_int64(ndr, NDR_SCALARS, &r->value));
142 156 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->sign));
143 156 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &r->base));
144 156 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
145 : }
146 156 : if (ndr_flags & NDR_BUFFERS) {
147 48 : }
148 156 : return NDR_ERR_SUCCESS;
149 : }
150 :
151 0 : static void ndr_print_flags_ace_condition_int(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct ace_condition_int *r)
152 : {
153 0 : ndr_print_ace_condition_int(ndr, name, r);
154 0 : }
155 :
156 0 : _PUBLIC_ void ndr_print_ace_condition_int(struct ndr_print *ndr, const char *name, const struct ace_condition_int *r)
157 : {
158 0 : ndr_print_struct(ndr, name, "ace_condition_int");
159 0 : if (r == NULL) { ndr_print_null(ndr); return; }
160 0 : ndr->depth++;
161 0 : ndr_print_int64(ndr, "value", r->value);
162 0 : ndr_print_uint8(ndr, "sign", r->sign);
163 0 : ndr_print_uint8(ndr, "base", r->base);
164 0 : ndr->depth--;
165 : }
166 :
167 2737 : _PUBLIC_ enum ndr_err_code ndr_push_ace_condition_unicode(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_unicode *r)
168 : {
169 2737 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
170 2737 : if (ndr_flags & NDR_SCALARS) {
171 2737 : NDR_CHECK(ndr_push_align(ndr, 4));
172 : {
173 2737 : libndr_flags _flags_save_string = ndr->flags;
174 2737 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_BYTESIZE|LIBNDR_FLAG_STR_NO_EMBEDDED_NUL);
175 2737 : NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->value));
176 2737 : ndr->flags = _flags_save_string;
177 : }
178 2737 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
179 : }
180 2737 : if (ndr_flags & NDR_BUFFERS) {
181 1893 : }
182 2737 : return NDR_ERR_SUCCESS;
183 : }
184 :
185 1699 : _PUBLIC_ enum ndr_err_code ndr_pull_ace_condition_unicode(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_unicode *r)
186 : {
187 1699 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
188 1699 : if (ndr_flags & NDR_SCALARS) {
189 1699 : NDR_CHECK(ndr_pull_align(ndr, 4));
190 : {
191 1699 : libndr_flags _flags_save_string = ndr->flags;
192 1699 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_BYTESIZE|LIBNDR_FLAG_STR_NO_EMBEDDED_NUL);
193 1699 : NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->value));
194 1699 : ndr->flags = _flags_save_string;
195 : }
196 1699 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
197 : }
198 1699 : if (ndr_flags & NDR_BUFFERS) {
199 241 : }
200 1699 : return NDR_ERR_SUCCESS;
201 : }
202 :
203 0 : static void ndr_print_flags_ace_condition_unicode(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct ace_condition_unicode *r)
204 : {
205 0 : ndr_print_ace_condition_unicode(ndr, name, r);
206 0 : }
207 :
208 0 : _PUBLIC_ void ndr_print_ace_condition_unicode(struct ndr_print *ndr, const char *name, const struct ace_condition_unicode *r)
209 : {
210 0 : ndr_print_struct(ndr, name, "ace_condition_unicode");
211 0 : if (r == NULL) { ndr_print_null(ndr); return; }
212 0 : ndr->depth++;
213 : {
214 0 : libndr_flags _flags_save_string = ndr->flags;
215 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_NOTERM|LIBNDR_FLAG_STR_BYTESIZE|LIBNDR_FLAG_STR_NO_EMBEDDED_NUL);
216 0 : ndr_print_string(ndr, "value", r->value);
217 0 : ndr->flags = _flags_save_string;
218 : }
219 0 : ndr->depth--;
220 : }
221 :
222 755 : _PUBLIC_ enum ndr_err_code ndr_push_ace_condition_sid(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_sid *r)
223 : {
224 755 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
225 755 : if (ndr_flags & NDR_SCALARS) {
226 755 : NDR_CHECK(ndr_push_align(ndr, 1));
227 : {
228 479 : struct ndr_push *_ndr_sid;
229 755 : NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_sid, 4, -1));
230 755 : NDR_CHECK(ndr_push_dom_sid(_ndr_sid, NDR_SCALARS, &r->sid));
231 755 : NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_sid, 4, -1));
232 : }
233 755 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
234 : }
235 755 : if (ndr_flags & NDR_BUFFERS) {
236 479 : }
237 755 : return NDR_ERR_SUCCESS;
238 : }
239 :
240 515 : _PUBLIC_ enum ndr_err_code ndr_pull_ace_condition_sid(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_sid *r)
241 : {
242 515 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
243 515 : if (ndr_flags & NDR_SCALARS) {
244 515 : NDR_CHECK(ndr_pull_align(ndr, 1));
245 : {
246 92 : struct ndr_pull *_ndr_sid;
247 515 : NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_sid, 4, -1));
248 515 : NDR_CHECK(ndr_pull_dom_sid(_ndr_sid, NDR_SCALARS, &r->sid));
249 515 : NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_sid, 4, -1));
250 : }
251 515 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
252 : }
253 515 : if (ndr_flags & NDR_BUFFERS) {
254 92 : }
255 515 : return NDR_ERR_SUCCESS;
256 : }
257 :
258 0 : static void ndr_print_flags_ace_condition_sid(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct ace_condition_sid *r)
259 : {
260 0 : ndr_print_ace_condition_sid(ndr, name, r);
261 0 : }
262 :
263 0 : _PUBLIC_ void ndr_print_ace_condition_sid(struct ndr_print *ndr, const char *name, const struct ace_condition_sid *r)
264 : {
265 0 : ndr_print_struct(ndr, name, "ace_condition_sid");
266 0 : if (r == NULL) { ndr_print_null(ndr); return; }
267 0 : ndr->depth++;
268 0 : ndr_print_dom_sid(ndr, "sid", &r->sid);
269 0 : ndr->depth--;
270 : }
271 :
272 0 : static enum ndr_err_code ndr_push_ace_condition_composite(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_composite *r)
273 : {
274 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
275 0 : if (ndr_flags & NDR_SCALARS) {
276 0 : NDR_CHECK(ndr_push_align(ndr, 5));
277 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->tokens));
278 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->n_members));
279 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
280 : }
281 0 : if (ndr_flags & NDR_BUFFERS) {
282 0 : if (r->tokens) {
283 0 : NDR_CHECK(ndr_push_ace_condition_token(ndr, NDR_SCALARS|NDR_BUFFERS, r->tokens));
284 : }
285 : }
286 0 : return NDR_ERR_SUCCESS;
287 : }
288 :
289 0 : static enum ndr_err_code ndr_pull_ace_condition_composite(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_composite *r)
290 : {
291 0 : uint32_t _ptr_tokens;
292 0 : TALLOC_CTX *_mem_save_tokens_0 = NULL;
293 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
294 0 : if (ndr_flags & NDR_SCALARS) {
295 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
296 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_tokens));
297 0 : if (_ptr_tokens) {
298 0 : NDR_PULL_ALLOC(ndr, r->tokens);
299 : } else {
300 0 : r->tokens = NULL;
301 : }
302 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->n_members));
303 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
304 : }
305 0 : if (ndr_flags & NDR_BUFFERS) {
306 0 : if (r->tokens) {
307 0 : _mem_save_tokens_0 = NDR_PULL_GET_MEM_CTX(ndr);
308 0 : NDR_PULL_SET_MEM_CTX(ndr, r->tokens, 0);
309 0 : NDR_CHECK(ndr_pull_ace_condition_token(ndr, NDR_SCALARS|NDR_BUFFERS, r->tokens));
310 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_tokens_0, 0);
311 : }
312 : }
313 0 : return NDR_ERR_SUCCESS;
314 : }
315 :
316 0 : _PUBLIC_ void ndr_print_ace_condition_composite(struct ndr_print *ndr, const char *name, const struct ace_condition_composite *r)
317 : {
318 0 : ndr_print_struct(ndr, name, "ace_condition_composite");
319 0 : if (r == NULL) { ndr_print_null(ndr); return; }
320 0 : ndr->depth++;
321 0 : ndr_print_ptr(ndr, "tokens", r->tokens);
322 0 : ndr->depth++;
323 0 : if (r->tokens) {
324 0 : ndr_print_ace_condition_token(ndr, "tokens", r->tokens);
325 : }
326 0 : ndr->depth--;
327 0 : ndr_print_uint32(ndr, "n_members", r->n_members);
328 0 : ndr->depth--;
329 : }
330 :
331 0 : static enum ndr_err_code ndr_push_ace_condition_op(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_op *r)
332 : {
333 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
334 0 : if (ndr_flags & NDR_SCALARS) {
335 0 : NDR_CHECK(ndr_push_align(ndr, 4));
336 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->sddl_position));
337 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
338 : }
339 0 : if (ndr_flags & NDR_BUFFERS) {
340 0 : }
341 0 : return NDR_ERR_SUCCESS;
342 : }
343 :
344 0 : static enum ndr_err_code ndr_pull_ace_condition_op(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_op *r)
345 : {
346 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
347 0 : if (ndr_flags & NDR_SCALARS) {
348 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
349 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sddl_position));
350 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
351 : }
352 0 : if (ndr_flags & NDR_BUFFERS) {
353 0 : }
354 0 : return NDR_ERR_SUCCESS;
355 : }
356 :
357 0 : _PUBLIC_ void ndr_print_ace_condition_op(struct ndr_print *ndr, const char *name, const struct ace_condition_op *r)
358 : {
359 0 : ndr_print_struct(ndr, name, "ace_condition_op");
360 0 : if (r == NULL) { ndr_print_null(ndr); return; }
361 0 : ndr->depth++;
362 0 : ndr_print_uint32(ndr, "sddl_position", r->sddl_position);
363 0 : ndr->depth--;
364 : }
365 :
366 0 : static enum ndr_err_code ndr_push_ace_condition_sddl_op(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_sddl_op *r)
367 : {
368 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
369 0 : if (ndr_flags & NDR_SCALARS) {
370 0 : NDR_CHECK(ndr_push_align(ndr, 4));
371 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->start));
372 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->position));
373 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
374 : }
375 0 : if (ndr_flags & NDR_BUFFERS) {
376 0 : }
377 0 : return NDR_ERR_SUCCESS;
378 : }
379 :
380 0 : static enum ndr_err_code ndr_pull_ace_condition_sddl_op(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_sddl_op *r)
381 : {
382 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
383 0 : if (ndr_flags & NDR_SCALARS) {
384 0 : NDR_CHECK(ndr_pull_align(ndr, 4));
385 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->start));
386 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->position));
387 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
388 : }
389 0 : if (ndr_flags & NDR_BUFFERS) {
390 0 : }
391 0 : return NDR_ERR_SUCCESS;
392 : }
393 :
394 0 : _PUBLIC_ void ndr_print_ace_condition_sddl_op(struct ndr_print *ndr, const char *name, const struct ace_condition_sddl_op *r)
395 : {
396 0 : ndr_print_struct(ndr, name, "ace_condition_sddl_op");
397 0 : if (r == NULL) { ndr_print_null(ndr); return; }
398 0 : ndr->depth++;
399 0 : ndr_print_uint32(ndr, "start", r->start);
400 0 : ndr_print_uint32(ndr, "position", r->position);
401 0 : ndr->depth--;
402 : }
403 :
404 0 : static enum ndr_err_code ndr_push_ace_condition_token_data(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union ace_condition_token_data *r)
405 : {
406 0 : uint32_t level;
407 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
408 0 : if (ndr_flags & NDR_SCALARS) {
409 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
410 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
411 0 : NDR_CHECK(ndr_push_union_align(ndr, 8));
412 0 : switch (level) {
413 0 : case CONDITIONAL_ACE_TOKEN_SID: {
414 0 : NDR_CHECK(ndr_push_ace_condition_sid(ndr, NDR_SCALARS, &r->sid));
415 0 : break; }
416 :
417 0 : case CONDITIONAL_ACE_TOKEN_COMPOSITE: {
418 0 : NDR_CHECK(ndr_push_ace_condition_composite(ndr, NDR_SCALARS, &r->composite));
419 0 : break; }
420 :
421 0 : case CONDITIONAL_ACE_TOKEN_OCTET_STRING: {
422 0 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->bytes));
423 0 : break; }
424 :
425 0 : case CONDITIONAL_ACE_TOKEN_UNICODE: {
426 0 : NDR_CHECK(ndr_push_ace_condition_unicode(ndr, NDR_SCALARS, &r->unicode));
427 0 : break; }
428 :
429 0 : case CONDITIONAL_ACE_LOCAL_ATTRIBUTE: {
430 0 : NDR_CHECK(ndr_push_ace_condition_unicode(ndr, NDR_SCALARS, &r->local_attr));
431 0 : break; }
432 :
433 0 : case CONDITIONAL_ACE_USER_ATTRIBUTE: {
434 0 : NDR_CHECK(ndr_push_ace_condition_unicode(ndr, NDR_SCALARS, &r->user_attr));
435 0 : break; }
436 :
437 0 : case CONDITIONAL_ACE_DEVICE_ATTRIBUTE: {
438 0 : NDR_CHECK(ndr_push_ace_condition_unicode(ndr, NDR_SCALARS, &r->device_attr));
439 0 : break; }
440 :
441 0 : case CONDITIONAL_ACE_RESOURCE_ATTRIBUTE: {
442 0 : NDR_CHECK(ndr_push_ace_condition_unicode(ndr, NDR_SCALARS, &r->resource_attr));
443 0 : break; }
444 :
445 0 : case CONDITIONAL_ACE_TOKEN_INT64: {
446 0 : NDR_CHECK(ndr_push_ace_condition_int(ndr, NDR_SCALARS, &r->int64));
447 0 : break; }
448 :
449 0 : case CONDITIONAL_ACE_TOKEN_INT32: {
450 0 : NDR_CHECK(ndr_push_ace_condition_int(ndr, NDR_SCALARS, &r->int32));
451 0 : break; }
452 :
453 0 : case CONDITIONAL_ACE_TOKEN_INT16: {
454 0 : NDR_CHECK(ndr_push_ace_condition_int(ndr, NDR_SCALARS, &r->int16));
455 0 : break; }
456 :
457 0 : case CONDITIONAL_ACE_TOKEN_INT8: {
458 0 : NDR_CHECK(ndr_push_ace_condition_int(ndr, NDR_SCALARS, &r->int8));
459 0 : break; }
460 :
461 0 : case CONDITIONAL_ACE_SAMBA_SDDL_PAREN: {
462 0 : NDR_CHECK(ndr_push_ace_condition_sddl_op(ndr, NDR_SCALARS, &r->sddl_op));
463 0 : break; }
464 :
465 0 : case CONDITIONAL_ACE_SAMBA_RESULT_BOOL: {
466 0 : NDR_CHECK(ndr_push_ace_condition_result(ndr, NDR_SCALARS, &r->result));
467 0 : break; }
468 :
469 0 : case CONDITIONAL_ACE_SAMBA_RESULT_NULL: {
470 0 : NDR_CHECK(ndr_push_ace_condition_result(ndr, NDR_SCALARS, &r->result_null));
471 0 : break; }
472 :
473 0 : case CONDITIONAL_ACE_SAMBA_RESULT_ERROR: {
474 0 : NDR_CHECK(ndr_push_ace_condition_result(ndr, NDR_SCALARS, &r->result_error));
475 0 : break; }
476 :
477 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF: {
478 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->member_of));
479 0 : break; }
480 :
481 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF: {
482 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->device_member_of));
483 0 : break; }
484 :
485 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF_ANY: {
486 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->member_of_any));
487 0 : break; }
488 :
489 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF_ANY: {
490 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->device_member_of_any));
491 0 : break; }
492 :
493 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF: {
494 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_member_of));
495 0 : break; }
496 :
497 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF: {
498 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_device_member_of));
499 0 : break; }
500 :
501 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF_ANY: {
502 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_member_of_any));
503 0 : break; }
504 :
505 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF_ANY: {
506 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_device_member_of_any));
507 0 : break; }
508 :
509 0 : case CONDITIONAL_ACE_TOKEN_EQUAL: {
510 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->equal));
511 0 : break; }
512 :
513 0 : case CONDITIONAL_ACE_TOKEN_NOT_EQUAL: {
514 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_equal));
515 0 : break; }
516 :
517 0 : case CONDITIONAL_ACE_TOKEN_LESS_THAN: {
518 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->less_than));
519 0 : break; }
520 :
521 0 : case CONDITIONAL_ACE_TOKEN_LESS_OR_EQUAL: {
522 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->less_or_equal));
523 0 : break; }
524 :
525 0 : case CONDITIONAL_ACE_TOKEN_GREATER_THAN: {
526 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->greater_than));
527 0 : break; }
528 :
529 0 : case CONDITIONAL_ACE_TOKEN_GREATER_OR_EQUAL: {
530 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->greater_or_equal));
531 0 : break; }
532 :
533 0 : case CONDITIONAL_ACE_TOKEN_CONTAINS: {
534 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->contains));
535 0 : break; }
536 :
537 0 : case CONDITIONAL_ACE_TOKEN_ANY_OF: {
538 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->any_of));
539 0 : break; }
540 :
541 0 : case CONDITIONAL_ACE_TOKEN_NOT_CONTAINS: {
542 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_contains));
543 0 : break; }
544 :
545 0 : case CONDITIONAL_ACE_TOKEN_NOT_ANY_OF: {
546 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_any_of));
547 0 : break; }
548 :
549 0 : case CONDITIONAL_ACE_TOKEN_AND: {
550 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->and));
551 0 : break; }
552 :
553 0 : case CONDITIONAL_ACE_TOKEN_OR: {
554 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->or));
555 0 : break; }
556 :
557 0 : case CONDITIONAL_ACE_TOKEN_NOT: {
558 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not));
559 0 : break; }
560 :
561 0 : case CONDITIONAL_ACE_TOKEN_EXISTS: {
562 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->exists));
563 0 : break; }
564 :
565 0 : case CONDITIONAL_ACE_TOKEN_NOT_EXISTS: {
566 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->not_exists));
567 0 : break; }
568 :
569 0 : default: {
570 0 : NDR_CHECK(ndr_push_ace_condition_op(ndr, NDR_SCALARS, &r->op));
571 0 : break; }
572 :
573 : }
574 : }
575 0 : if (ndr_flags & NDR_BUFFERS) {
576 0 : if (!(ndr_flags & NDR_SCALARS)) {
577 : /* We didn't get it above, and the token is not needed after this. */
578 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
579 : }
580 0 : switch (level) {
581 0 : case CONDITIONAL_ACE_TOKEN_SID:
582 0 : break;
583 :
584 0 : case CONDITIONAL_ACE_TOKEN_COMPOSITE:
585 0 : NDR_CHECK(ndr_push_ace_condition_composite(ndr, NDR_BUFFERS, &r->composite));
586 0 : break;
587 :
588 0 : case CONDITIONAL_ACE_TOKEN_OCTET_STRING:
589 0 : break;
590 :
591 0 : case CONDITIONAL_ACE_TOKEN_UNICODE:
592 0 : break;
593 :
594 0 : case CONDITIONAL_ACE_LOCAL_ATTRIBUTE:
595 0 : break;
596 :
597 0 : case CONDITIONAL_ACE_USER_ATTRIBUTE:
598 0 : break;
599 :
600 0 : case CONDITIONAL_ACE_DEVICE_ATTRIBUTE:
601 0 : break;
602 :
603 0 : case CONDITIONAL_ACE_RESOURCE_ATTRIBUTE:
604 0 : break;
605 :
606 0 : case CONDITIONAL_ACE_TOKEN_INT64:
607 0 : break;
608 :
609 0 : case CONDITIONAL_ACE_TOKEN_INT32:
610 0 : break;
611 :
612 0 : case CONDITIONAL_ACE_TOKEN_INT16:
613 0 : break;
614 :
615 0 : case CONDITIONAL_ACE_TOKEN_INT8:
616 0 : break;
617 :
618 0 : case CONDITIONAL_ACE_SAMBA_SDDL_PAREN:
619 0 : break;
620 :
621 0 : case CONDITIONAL_ACE_SAMBA_RESULT_BOOL:
622 0 : break;
623 :
624 0 : case CONDITIONAL_ACE_SAMBA_RESULT_NULL:
625 0 : break;
626 :
627 0 : case CONDITIONAL_ACE_SAMBA_RESULT_ERROR:
628 0 : break;
629 :
630 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF:
631 0 : break;
632 :
633 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF:
634 0 : break;
635 :
636 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF_ANY:
637 0 : break;
638 :
639 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF_ANY:
640 0 : break;
641 :
642 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF:
643 0 : break;
644 :
645 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF:
646 0 : break;
647 :
648 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF_ANY:
649 0 : break;
650 :
651 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF_ANY:
652 0 : break;
653 :
654 0 : case CONDITIONAL_ACE_TOKEN_EQUAL:
655 0 : break;
656 :
657 0 : case CONDITIONAL_ACE_TOKEN_NOT_EQUAL:
658 0 : break;
659 :
660 0 : case CONDITIONAL_ACE_TOKEN_LESS_THAN:
661 0 : break;
662 :
663 0 : case CONDITIONAL_ACE_TOKEN_LESS_OR_EQUAL:
664 0 : break;
665 :
666 0 : case CONDITIONAL_ACE_TOKEN_GREATER_THAN:
667 0 : break;
668 :
669 0 : case CONDITIONAL_ACE_TOKEN_GREATER_OR_EQUAL:
670 0 : break;
671 :
672 0 : case CONDITIONAL_ACE_TOKEN_CONTAINS:
673 0 : break;
674 :
675 0 : case CONDITIONAL_ACE_TOKEN_ANY_OF:
676 0 : break;
677 :
678 0 : case CONDITIONAL_ACE_TOKEN_NOT_CONTAINS:
679 0 : break;
680 :
681 0 : case CONDITIONAL_ACE_TOKEN_NOT_ANY_OF:
682 0 : break;
683 :
684 0 : case CONDITIONAL_ACE_TOKEN_AND:
685 0 : break;
686 :
687 0 : case CONDITIONAL_ACE_TOKEN_OR:
688 0 : break;
689 :
690 0 : case CONDITIONAL_ACE_TOKEN_NOT:
691 0 : break;
692 :
693 0 : case CONDITIONAL_ACE_TOKEN_EXISTS:
694 0 : break;
695 :
696 0 : case CONDITIONAL_ACE_TOKEN_NOT_EXISTS:
697 0 : break;
698 :
699 0 : default:
700 0 : break;
701 :
702 : }
703 : }
704 0 : return NDR_ERR_SUCCESS;
705 : }
706 :
707 0 : static enum ndr_err_code ndr_pull_ace_condition_token_data(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union ace_condition_token_data *r)
708 : {
709 0 : uint32_t level;
710 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
711 0 : if (ndr_flags & NDR_SCALARS) {
712 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
713 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
714 0 : NDR_CHECK(ndr_pull_union_align(ndr, 8));
715 0 : switch (level) {
716 0 : case CONDITIONAL_ACE_TOKEN_SID: {
717 0 : NDR_CHECK(ndr_pull_ace_condition_sid(ndr, NDR_SCALARS, &r->sid));
718 0 : break; }
719 :
720 0 : case CONDITIONAL_ACE_TOKEN_COMPOSITE: {
721 0 : NDR_CHECK(ndr_pull_ace_condition_composite(ndr, NDR_SCALARS, &r->composite));
722 0 : break; }
723 :
724 0 : case CONDITIONAL_ACE_TOKEN_OCTET_STRING: {
725 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->bytes));
726 0 : break; }
727 :
728 0 : case CONDITIONAL_ACE_TOKEN_UNICODE: {
729 0 : NDR_CHECK(ndr_pull_ace_condition_unicode(ndr, NDR_SCALARS, &r->unicode));
730 0 : break; }
731 :
732 0 : case CONDITIONAL_ACE_LOCAL_ATTRIBUTE: {
733 0 : NDR_CHECK(ndr_pull_ace_condition_unicode(ndr, NDR_SCALARS, &r->local_attr));
734 0 : break; }
735 :
736 0 : case CONDITIONAL_ACE_USER_ATTRIBUTE: {
737 0 : NDR_CHECK(ndr_pull_ace_condition_unicode(ndr, NDR_SCALARS, &r->user_attr));
738 0 : break; }
739 :
740 0 : case CONDITIONAL_ACE_DEVICE_ATTRIBUTE: {
741 0 : NDR_CHECK(ndr_pull_ace_condition_unicode(ndr, NDR_SCALARS, &r->device_attr));
742 0 : break; }
743 :
744 0 : case CONDITIONAL_ACE_RESOURCE_ATTRIBUTE: {
745 0 : NDR_CHECK(ndr_pull_ace_condition_unicode(ndr, NDR_SCALARS, &r->resource_attr));
746 0 : break; }
747 :
748 0 : case CONDITIONAL_ACE_TOKEN_INT64: {
749 0 : NDR_CHECK(ndr_pull_ace_condition_int(ndr, NDR_SCALARS, &r->int64));
750 0 : break; }
751 :
752 0 : case CONDITIONAL_ACE_TOKEN_INT32: {
753 0 : NDR_CHECK(ndr_pull_ace_condition_int(ndr, NDR_SCALARS, &r->int32));
754 0 : break; }
755 :
756 0 : case CONDITIONAL_ACE_TOKEN_INT16: {
757 0 : NDR_CHECK(ndr_pull_ace_condition_int(ndr, NDR_SCALARS, &r->int16));
758 0 : break; }
759 :
760 0 : case CONDITIONAL_ACE_TOKEN_INT8: {
761 0 : NDR_CHECK(ndr_pull_ace_condition_int(ndr, NDR_SCALARS, &r->int8));
762 0 : break; }
763 :
764 0 : case CONDITIONAL_ACE_SAMBA_SDDL_PAREN: {
765 0 : NDR_CHECK(ndr_pull_ace_condition_sddl_op(ndr, NDR_SCALARS, &r->sddl_op));
766 0 : break; }
767 :
768 0 : case CONDITIONAL_ACE_SAMBA_RESULT_BOOL: {
769 0 : NDR_CHECK(ndr_pull_ace_condition_result(ndr, NDR_SCALARS, &r->result));
770 0 : break; }
771 :
772 0 : case CONDITIONAL_ACE_SAMBA_RESULT_NULL: {
773 0 : NDR_CHECK(ndr_pull_ace_condition_result(ndr, NDR_SCALARS, &r->result_null));
774 0 : break; }
775 :
776 0 : case CONDITIONAL_ACE_SAMBA_RESULT_ERROR: {
777 0 : NDR_CHECK(ndr_pull_ace_condition_result(ndr, NDR_SCALARS, &r->result_error));
778 0 : break; }
779 :
780 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF: {
781 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->member_of));
782 0 : break; }
783 :
784 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF: {
785 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->device_member_of));
786 0 : break; }
787 :
788 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF_ANY: {
789 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->member_of_any));
790 0 : break; }
791 :
792 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF_ANY: {
793 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->device_member_of_any));
794 0 : break; }
795 :
796 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF: {
797 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_member_of));
798 0 : break; }
799 :
800 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF: {
801 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_device_member_of));
802 0 : break; }
803 :
804 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF_ANY: {
805 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_member_of_any));
806 0 : break; }
807 :
808 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF_ANY: {
809 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_device_member_of_any));
810 0 : break; }
811 :
812 0 : case CONDITIONAL_ACE_TOKEN_EQUAL: {
813 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->equal));
814 0 : break; }
815 :
816 0 : case CONDITIONAL_ACE_TOKEN_NOT_EQUAL: {
817 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_equal));
818 0 : break; }
819 :
820 0 : case CONDITIONAL_ACE_TOKEN_LESS_THAN: {
821 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->less_than));
822 0 : break; }
823 :
824 0 : case CONDITIONAL_ACE_TOKEN_LESS_OR_EQUAL: {
825 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->less_or_equal));
826 0 : break; }
827 :
828 0 : case CONDITIONAL_ACE_TOKEN_GREATER_THAN: {
829 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->greater_than));
830 0 : break; }
831 :
832 0 : case CONDITIONAL_ACE_TOKEN_GREATER_OR_EQUAL: {
833 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->greater_or_equal));
834 0 : break; }
835 :
836 0 : case CONDITIONAL_ACE_TOKEN_CONTAINS: {
837 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->contains));
838 0 : break; }
839 :
840 0 : case CONDITIONAL_ACE_TOKEN_ANY_OF: {
841 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->any_of));
842 0 : break; }
843 :
844 0 : case CONDITIONAL_ACE_TOKEN_NOT_CONTAINS: {
845 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_contains));
846 0 : break; }
847 :
848 0 : case CONDITIONAL_ACE_TOKEN_NOT_ANY_OF: {
849 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_any_of));
850 0 : break; }
851 :
852 0 : case CONDITIONAL_ACE_TOKEN_AND: {
853 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->and));
854 0 : break; }
855 :
856 0 : case CONDITIONAL_ACE_TOKEN_OR: {
857 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->or));
858 0 : break; }
859 :
860 0 : case CONDITIONAL_ACE_TOKEN_NOT: {
861 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not));
862 0 : break; }
863 :
864 0 : case CONDITIONAL_ACE_TOKEN_EXISTS: {
865 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->exists));
866 0 : break; }
867 :
868 0 : case CONDITIONAL_ACE_TOKEN_NOT_EXISTS: {
869 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->not_exists));
870 0 : break; }
871 :
872 0 : default: {
873 0 : NDR_CHECK(ndr_pull_ace_condition_op(ndr, NDR_SCALARS, &r->op));
874 0 : break; }
875 :
876 : }
877 : }
878 0 : if (ndr_flags & NDR_BUFFERS) {
879 0 : if (!(ndr_flags & NDR_SCALARS)) {
880 : /* We didn't get it above, and the token is not needed after this. */
881 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
882 : }
883 0 : switch (level) {
884 0 : case CONDITIONAL_ACE_TOKEN_SID:
885 0 : break;
886 :
887 0 : case CONDITIONAL_ACE_TOKEN_COMPOSITE:
888 0 : NDR_CHECK(ndr_pull_ace_condition_composite(ndr, NDR_BUFFERS, &r->composite));
889 0 : break;
890 :
891 0 : case CONDITIONAL_ACE_TOKEN_OCTET_STRING:
892 0 : break;
893 :
894 0 : case CONDITIONAL_ACE_TOKEN_UNICODE:
895 0 : break;
896 :
897 0 : case CONDITIONAL_ACE_LOCAL_ATTRIBUTE:
898 0 : break;
899 :
900 0 : case CONDITIONAL_ACE_USER_ATTRIBUTE:
901 0 : break;
902 :
903 0 : case CONDITIONAL_ACE_DEVICE_ATTRIBUTE:
904 0 : break;
905 :
906 0 : case CONDITIONAL_ACE_RESOURCE_ATTRIBUTE:
907 0 : break;
908 :
909 0 : case CONDITIONAL_ACE_TOKEN_INT64:
910 0 : break;
911 :
912 0 : case CONDITIONAL_ACE_TOKEN_INT32:
913 0 : break;
914 :
915 0 : case CONDITIONAL_ACE_TOKEN_INT16:
916 0 : break;
917 :
918 0 : case CONDITIONAL_ACE_TOKEN_INT8:
919 0 : break;
920 :
921 0 : case CONDITIONAL_ACE_SAMBA_SDDL_PAREN:
922 0 : break;
923 :
924 0 : case CONDITIONAL_ACE_SAMBA_RESULT_BOOL:
925 0 : break;
926 :
927 0 : case CONDITIONAL_ACE_SAMBA_RESULT_NULL:
928 0 : break;
929 :
930 0 : case CONDITIONAL_ACE_SAMBA_RESULT_ERROR:
931 0 : break;
932 :
933 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF:
934 0 : break;
935 :
936 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF:
937 0 : break;
938 :
939 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF_ANY:
940 0 : break;
941 :
942 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF_ANY:
943 0 : break;
944 :
945 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF:
946 0 : break;
947 :
948 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF:
949 0 : break;
950 :
951 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF_ANY:
952 0 : break;
953 :
954 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF_ANY:
955 0 : break;
956 :
957 0 : case CONDITIONAL_ACE_TOKEN_EQUAL:
958 0 : break;
959 :
960 0 : case CONDITIONAL_ACE_TOKEN_NOT_EQUAL:
961 0 : break;
962 :
963 0 : case CONDITIONAL_ACE_TOKEN_LESS_THAN:
964 0 : break;
965 :
966 0 : case CONDITIONAL_ACE_TOKEN_LESS_OR_EQUAL:
967 0 : break;
968 :
969 0 : case CONDITIONAL_ACE_TOKEN_GREATER_THAN:
970 0 : break;
971 :
972 0 : case CONDITIONAL_ACE_TOKEN_GREATER_OR_EQUAL:
973 0 : break;
974 :
975 0 : case CONDITIONAL_ACE_TOKEN_CONTAINS:
976 0 : break;
977 :
978 0 : case CONDITIONAL_ACE_TOKEN_ANY_OF:
979 0 : break;
980 :
981 0 : case CONDITIONAL_ACE_TOKEN_NOT_CONTAINS:
982 0 : break;
983 :
984 0 : case CONDITIONAL_ACE_TOKEN_NOT_ANY_OF:
985 0 : break;
986 :
987 0 : case CONDITIONAL_ACE_TOKEN_AND:
988 0 : break;
989 :
990 0 : case CONDITIONAL_ACE_TOKEN_OR:
991 0 : break;
992 :
993 0 : case CONDITIONAL_ACE_TOKEN_NOT:
994 0 : break;
995 :
996 0 : case CONDITIONAL_ACE_TOKEN_EXISTS:
997 0 : break;
998 :
999 0 : case CONDITIONAL_ACE_TOKEN_NOT_EXISTS:
1000 0 : break;
1001 :
1002 0 : default:
1003 0 : break;
1004 :
1005 : }
1006 : }
1007 0 : return NDR_ERR_SUCCESS;
1008 : }
1009 :
1010 0 : _PUBLIC_ void ndr_print_ace_condition_token_data(struct ndr_print *ndr, const char *name, const union ace_condition_token_data *r)
1011 : {
1012 0 : uint32_t level;
1013 0 : level = ndr_print_steal_switch_value(ndr, r);
1014 0 : ndr_print_union(ndr, name, level, "ace_condition_token_data");
1015 0 : switch (level) {
1016 0 : case CONDITIONAL_ACE_TOKEN_SID:
1017 0 : ndr_print_ace_condition_sid(ndr, "sid", &r->sid);
1018 0 : break;
1019 :
1020 0 : case CONDITIONAL_ACE_TOKEN_COMPOSITE:
1021 0 : ndr_print_ace_condition_composite(ndr, "composite", &r->composite);
1022 0 : break;
1023 :
1024 0 : case CONDITIONAL_ACE_TOKEN_OCTET_STRING:
1025 0 : ndr_print_DATA_BLOB(ndr, "bytes", r->bytes);
1026 0 : break;
1027 :
1028 0 : case CONDITIONAL_ACE_TOKEN_UNICODE:
1029 0 : ndr_print_ace_condition_unicode(ndr, "unicode", &r->unicode);
1030 0 : break;
1031 :
1032 0 : case CONDITIONAL_ACE_LOCAL_ATTRIBUTE:
1033 0 : ndr_print_ace_condition_unicode(ndr, "local_attr", &r->local_attr);
1034 0 : break;
1035 :
1036 0 : case CONDITIONAL_ACE_USER_ATTRIBUTE:
1037 0 : ndr_print_ace_condition_unicode(ndr, "user_attr", &r->user_attr);
1038 0 : break;
1039 :
1040 0 : case CONDITIONAL_ACE_DEVICE_ATTRIBUTE:
1041 0 : ndr_print_ace_condition_unicode(ndr, "device_attr", &r->device_attr);
1042 0 : break;
1043 :
1044 0 : case CONDITIONAL_ACE_RESOURCE_ATTRIBUTE:
1045 0 : ndr_print_ace_condition_unicode(ndr, "resource_attr", &r->resource_attr);
1046 0 : break;
1047 :
1048 0 : case CONDITIONAL_ACE_TOKEN_INT64:
1049 0 : ndr_print_ace_condition_int(ndr, "int64", &r->int64);
1050 0 : break;
1051 :
1052 0 : case CONDITIONAL_ACE_TOKEN_INT32:
1053 0 : ndr_print_ace_condition_int(ndr, "int32", &r->int32);
1054 0 : break;
1055 :
1056 0 : case CONDITIONAL_ACE_TOKEN_INT16:
1057 0 : ndr_print_ace_condition_int(ndr, "int16", &r->int16);
1058 0 : break;
1059 :
1060 0 : case CONDITIONAL_ACE_TOKEN_INT8:
1061 0 : ndr_print_ace_condition_int(ndr, "int8", &r->int8);
1062 0 : break;
1063 :
1064 0 : case CONDITIONAL_ACE_SAMBA_SDDL_PAREN:
1065 0 : ndr_print_ace_condition_sddl_op(ndr, "sddl_op", &r->sddl_op);
1066 0 : break;
1067 :
1068 0 : case CONDITIONAL_ACE_SAMBA_RESULT_BOOL:
1069 0 : ndr_print_ace_condition_result(ndr, "result", &r->result);
1070 0 : break;
1071 :
1072 0 : case CONDITIONAL_ACE_SAMBA_RESULT_NULL:
1073 0 : ndr_print_ace_condition_result(ndr, "result_null", &r->result_null);
1074 0 : break;
1075 :
1076 0 : case CONDITIONAL_ACE_SAMBA_RESULT_ERROR:
1077 0 : ndr_print_ace_condition_result(ndr, "result_error", &r->result_error);
1078 0 : break;
1079 :
1080 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF:
1081 0 : ndr_print_ace_condition_op(ndr, "member_of", &r->member_of);
1082 0 : break;
1083 :
1084 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF:
1085 0 : ndr_print_ace_condition_op(ndr, "device_member_of", &r->device_member_of);
1086 0 : break;
1087 :
1088 0 : case CONDITIONAL_ACE_TOKEN_MEMBER_OF_ANY:
1089 0 : ndr_print_ace_condition_op(ndr, "member_of_any", &r->member_of_any);
1090 0 : break;
1091 :
1092 0 : case CONDITIONAL_ACE_TOKEN_DEVICE_MEMBER_OF_ANY:
1093 0 : ndr_print_ace_condition_op(ndr, "device_member_of_any", &r->device_member_of_any);
1094 0 : break;
1095 :
1096 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF:
1097 0 : ndr_print_ace_condition_op(ndr, "not_member_of", &r->not_member_of);
1098 0 : break;
1099 :
1100 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF:
1101 0 : ndr_print_ace_condition_op(ndr, "not_device_member_of", &r->not_device_member_of);
1102 0 : break;
1103 :
1104 0 : case CONDITIONAL_ACE_TOKEN_NOT_MEMBER_OF_ANY:
1105 0 : ndr_print_ace_condition_op(ndr, "not_member_of_any", &r->not_member_of_any);
1106 0 : break;
1107 :
1108 0 : case CONDITIONAL_ACE_TOKEN_NOT_DEVICE_MEMBER_OF_ANY:
1109 0 : ndr_print_ace_condition_op(ndr, "not_device_member_of_any", &r->not_device_member_of_any);
1110 0 : break;
1111 :
1112 0 : case CONDITIONAL_ACE_TOKEN_EQUAL:
1113 0 : ndr_print_ace_condition_op(ndr, "equal", &r->equal);
1114 0 : break;
1115 :
1116 0 : case CONDITIONAL_ACE_TOKEN_NOT_EQUAL:
1117 0 : ndr_print_ace_condition_op(ndr, "not_equal", &r->not_equal);
1118 0 : break;
1119 :
1120 0 : case CONDITIONAL_ACE_TOKEN_LESS_THAN:
1121 0 : ndr_print_ace_condition_op(ndr, "less_than", &r->less_than);
1122 0 : break;
1123 :
1124 0 : case CONDITIONAL_ACE_TOKEN_LESS_OR_EQUAL:
1125 0 : ndr_print_ace_condition_op(ndr, "less_or_equal", &r->less_or_equal);
1126 0 : break;
1127 :
1128 0 : case CONDITIONAL_ACE_TOKEN_GREATER_THAN:
1129 0 : ndr_print_ace_condition_op(ndr, "greater_than", &r->greater_than);
1130 0 : break;
1131 :
1132 0 : case CONDITIONAL_ACE_TOKEN_GREATER_OR_EQUAL:
1133 0 : ndr_print_ace_condition_op(ndr, "greater_or_equal", &r->greater_or_equal);
1134 0 : break;
1135 :
1136 0 : case CONDITIONAL_ACE_TOKEN_CONTAINS:
1137 0 : ndr_print_ace_condition_op(ndr, "contains", &r->contains);
1138 0 : break;
1139 :
1140 0 : case CONDITIONAL_ACE_TOKEN_ANY_OF:
1141 0 : ndr_print_ace_condition_op(ndr, "any_of", &r->any_of);
1142 0 : break;
1143 :
1144 0 : case CONDITIONAL_ACE_TOKEN_NOT_CONTAINS:
1145 0 : ndr_print_ace_condition_op(ndr, "not_contains", &r->not_contains);
1146 0 : break;
1147 :
1148 0 : case CONDITIONAL_ACE_TOKEN_NOT_ANY_OF:
1149 0 : ndr_print_ace_condition_op(ndr, "not_any_of", &r->not_any_of);
1150 0 : break;
1151 :
1152 0 : case CONDITIONAL_ACE_TOKEN_AND:
1153 0 : ndr_print_ace_condition_op(ndr, "and", &r->and);
1154 0 : break;
1155 :
1156 0 : case CONDITIONAL_ACE_TOKEN_OR:
1157 0 : ndr_print_ace_condition_op(ndr, "or", &r->or);
1158 0 : break;
1159 :
1160 0 : case CONDITIONAL_ACE_TOKEN_NOT:
1161 0 : ndr_print_ace_condition_op(ndr, "not", &r->not);
1162 0 : break;
1163 :
1164 0 : case CONDITIONAL_ACE_TOKEN_EXISTS:
1165 0 : ndr_print_ace_condition_op(ndr, "exists", &r->exists);
1166 0 : break;
1167 :
1168 0 : case CONDITIONAL_ACE_TOKEN_NOT_EXISTS:
1169 0 : ndr_print_ace_condition_op(ndr, "not_exists", &r->not_exists);
1170 0 : break;
1171 :
1172 0 : default:
1173 0 : ndr_print_ace_condition_op(ndr, "op", &r->op);
1174 0 : break;
1175 :
1176 : }
1177 0 : }
1178 :
1179 0 : _PUBLIC_ enum ndr_err_code ndr_push_ace_condition_token(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_token *r)
1180 : {
1181 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1182 0 : if (ndr_flags & NDR_SCALARS) {
1183 0 : NDR_CHECK(ndr_push_align(ndr, 8));
1184 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->data, r->type));
1185 0 : NDR_CHECK(ndr_push_ace_condition_token_data(ndr, NDR_SCALARS, &r->data));
1186 0 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->flags));
1187 0 : NDR_CHECK(ndr_push_token_type(ndr, NDR_SCALARS, r->type));
1188 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
1189 : }
1190 0 : if (ndr_flags & NDR_BUFFERS) {
1191 0 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->data, r->type));
1192 0 : NDR_CHECK(ndr_push_ace_condition_token_data(ndr, NDR_BUFFERS, &r->data));
1193 : }
1194 0 : return NDR_ERR_SUCCESS;
1195 : }
1196 :
1197 0 : _PUBLIC_ enum ndr_err_code ndr_pull_ace_condition_token(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_token *r)
1198 : {
1199 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1200 0 : if (ndr_flags & NDR_SCALARS) {
1201 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
1202 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->data, r->type));
1203 0 : NDR_CHECK(ndr_pull_ace_condition_token_data(ndr, NDR_SCALARS, &r->data));
1204 0 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->flags));
1205 0 : NDR_CHECK(ndr_pull_token_type(ndr, NDR_SCALARS, &r->type));
1206 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
1207 : }
1208 0 : if (ndr_flags & NDR_BUFFERS) {
1209 0 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->data, r->type));
1210 0 : NDR_CHECK(ndr_pull_ace_condition_token_data(ndr, NDR_BUFFERS, &r->data));
1211 : }
1212 0 : return NDR_ERR_SUCCESS;
1213 : }
1214 :
1215 0 : static void ndr_print_flags_ace_condition_token(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct ace_condition_token *r)
1216 : {
1217 0 : ndr_print_ace_condition_token(ndr, name, r);
1218 0 : }
1219 :
1220 0 : _PUBLIC_ void ndr_print_ace_condition_token(struct ndr_print *ndr, const char *name, const struct ace_condition_token *r)
1221 : {
1222 0 : ndr_print_struct(ndr, name, "ace_condition_token");
1223 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1224 0 : ndr->depth++;
1225 0 : ndr_print_set_switch_value(ndr, &r->data, r->type);
1226 0 : ndr_print_ace_condition_token_data(ndr, "data", &r->data);
1227 0 : ndr_print_uint16(ndr, "flags", r->flags);
1228 0 : ndr_print_token_type(ndr, "type", r->type);
1229 0 : ndr->depth--;
1230 : }
1231 :
1232 0 : _PUBLIC_ enum ndr_err_code ndr_push_ace_condition_script(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct ace_condition_script *r)
1233 : {
1234 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1235 0 : if (ndr_flags & NDR_SCALARS) {
1236 0 : NDR_CHECK(ndr_push_align(ndr, 5));
1237 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->tokens));
1238 0 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->stack));
1239 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->length));
1240 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1241 : }
1242 0 : if (ndr_flags & NDR_BUFFERS) {
1243 0 : if (r->tokens) {
1244 0 : NDR_CHECK(ndr_push_ace_condition_token(ndr, NDR_SCALARS|NDR_BUFFERS, r->tokens));
1245 : }
1246 0 : if (r->stack) {
1247 0 : NDR_CHECK(ndr_push_ace_condition_token(ndr, NDR_SCALARS|NDR_BUFFERS, r->stack));
1248 : }
1249 : }
1250 0 : return NDR_ERR_SUCCESS;
1251 : }
1252 :
1253 0 : _PUBLIC_ enum ndr_err_code ndr_pull_ace_condition_script(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct ace_condition_script *r)
1254 : {
1255 0 : uint32_t _ptr_tokens;
1256 0 : TALLOC_CTX *_mem_save_tokens_0 = NULL;
1257 0 : uint32_t _ptr_stack;
1258 0 : TALLOC_CTX *_mem_save_stack_0 = NULL;
1259 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1260 0 : if (ndr_flags & NDR_SCALARS) {
1261 0 : NDR_CHECK(ndr_pull_align(ndr, 5));
1262 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_tokens));
1263 0 : if (_ptr_tokens) {
1264 0 : NDR_PULL_ALLOC(ndr, r->tokens);
1265 : } else {
1266 0 : r->tokens = NULL;
1267 : }
1268 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_stack));
1269 0 : if (_ptr_stack) {
1270 0 : NDR_PULL_ALLOC(ndr, r->stack);
1271 : } else {
1272 0 : r->stack = NULL;
1273 : }
1274 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->length));
1275 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1276 : }
1277 0 : if (ndr_flags & NDR_BUFFERS) {
1278 0 : if (r->tokens) {
1279 0 : _mem_save_tokens_0 = NDR_PULL_GET_MEM_CTX(ndr);
1280 0 : NDR_PULL_SET_MEM_CTX(ndr, r->tokens, 0);
1281 0 : NDR_CHECK(ndr_pull_ace_condition_token(ndr, NDR_SCALARS|NDR_BUFFERS, r->tokens));
1282 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_tokens_0, 0);
1283 : }
1284 0 : if (r->stack) {
1285 0 : _mem_save_stack_0 = NDR_PULL_GET_MEM_CTX(ndr);
1286 0 : NDR_PULL_SET_MEM_CTX(ndr, r->stack, 0);
1287 0 : NDR_CHECK(ndr_pull_ace_condition_token(ndr, NDR_SCALARS|NDR_BUFFERS, r->stack));
1288 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_stack_0, 0);
1289 : }
1290 : }
1291 0 : return NDR_ERR_SUCCESS;
1292 : }
1293 :
1294 0 : static void ndr_print_flags_ace_condition_script(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct ace_condition_script *r)
1295 : {
1296 0 : ndr_print_ace_condition_script(ndr, name, r);
1297 0 : }
1298 :
1299 0 : _PUBLIC_ void ndr_print_ace_condition_script(struct ndr_print *ndr, const char *name, const struct ace_condition_script *r)
1300 : {
1301 0 : ndr_print_struct(ndr, name, "ace_condition_script");
1302 0 : if (r == NULL) { ndr_print_null(ndr); return; }
1303 0 : ndr->depth++;
1304 0 : ndr_print_ptr(ndr, "tokens", r->tokens);
1305 0 : ndr->depth++;
1306 0 : if (r->tokens) {
1307 0 : ndr_print_ace_condition_token(ndr, "tokens", r->tokens);
1308 : }
1309 0 : ndr->depth--;
1310 0 : ndr_print_ptr(ndr, "stack", r->stack);
1311 0 : ndr->depth++;
1312 0 : if (r->stack) {
1313 0 : ndr_print_ace_condition_token(ndr, "stack", r->stack);
1314 : }
1315 0 : ndr->depth--;
1316 0 : ndr_print_uint32(ndr, "length", r->length);
1317 0 : ndr->depth--;
1318 : }
1319 :
1320 : #ifndef SKIP_NDR_TABLE_conditional_ace
1321 : static const struct ndr_interface_public_struct conditional_ace_public_structs[] = {
1322 : {
1323 : .name = "ace_condition_int",
1324 : .struct_size = sizeof(struct ace_condition_int ),
1325 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_ace_condition_int,
1326 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_ace_condition_int,
1327 : .ndr_print = (ndr_print_function_t) ndr_print_flags_ace_condition_int,
1328 : },
1329 : {
1330 : .name = "ace_condition_unicode",
1331 : .struct_size = sizeof(struct ace_condition_unicode ),
1332 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_ace_condition_unicode,
1333 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_ace_condition_unicode,
1334 : .ndr_print = (ndr_print_function_t) ndr_print_flags_ace_condition_unicode,
1335 : },
1336 : {
1337 : .name = "ace_condition_sid",
1338 : .struct_size = sizeof(struct ace_condition_sid ),
1339 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_ace_condition_sid,
1340 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_ace_condition_sid,
1341 : .ndr_print = (ndr_print_function_t) ndr_print_flags_ace_condition_sid,
1342 : },
1343 : {
1344 : .name = "ace_condition_token",
1345 : .struct_size = sizeof(struct ace_condition_token ),
1346 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_ace_condition_token,
1347 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_ace_condition_token,
1348 : .ndr_print = (ndr_print_function_t) ndr_print_flags_ace_condition_token,
1349 : },
1350 : {
1351 : .name = "ace_condition_script",
1352 : .struct_size = sizeof(struct ace_condition_script ),
1353 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_ace_condition_script,
1354 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_ace_condition_script,
1355 : .ndr_print = (ndr_print_function_t) ndr_print_flags_ace_condition_script,
1356 : },
1357 : { .name = NULL }
1358 : };
1359 :
1360 : static const struct ndr_interface_call conditional_ace_calls[] = {
1361 : { .name = NULL }
1362 : };
1363 :
1364 : static const char * const conditional_ace_endpoint_strings[] = {
1365 : "ncacn_np:[\\pipe\\conditional_ace]",
1366 : };
1367 :
1368 : static const struct ndr_interface_string_array conditional_ace_endpoints = {
1369 : .count = 1,
1370 : .names = conditional_ace_endpoint_strings
1371 : };
1372 :
1373 : static const char * const conditional_ace_authservice_strings[] = {
1374 : "host",
1375 : };
1376 :
1377 : static const struct ndr_interface_string_array conditional_ace_authservices = {
1378 : .count = 1,
1379 : .names = conditional_ace_authservice_strings
1380 : };
1381 :
1382 :
1383 : const struct ndr_interface_table ndr_table_conditional_ace = {
1384 : .name = "conditional_ace",
1385 : .num_calls = 0,
1386 : .calls = conditional_ace_calls,
1387 : .num_public_structs = 5,
1388 : .public_structs = conditional_ace_public_structs,
1389 : .endpoints = &conditional_ace_endpoints,
1390 : .authservices = &conditional_ace_authservices
1391 : };
1392 :
1393 : #endif /* SKIP_NDR_TABLE_conditional_ace */
|