Line data Source code
1 : /* parser auto-generated by pidl */
2 :
3 : #include "includes.h"
4 : #include "bin/default/librpc/gen_ndr/ndr_claims.h"
5 :
6 : #include "librpc/ndr/ndr_compression.h"
7 15730 : static enum ndr_err_code ndr_push_CLAIM_TYPE(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum CLAIM_TYPE r)
8 : {
9 15730 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
10 15240 : return NDR_ERR_SUCCESS;
11 : }
12 :
13 2344 : static enum ndr_err_code ndr_pull_CLAIM_TYPE(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum CLAIM_TYPE *r)
14 : {
15 68 : uint16_t v;
16 2344 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
17 2344 : *r = v;
18 2344 : return NDR_ERR_SUCCESS;
19 : }
20 :
21 11 : _PUBLIC_ void ndr_print_CLAIM_TYPE(struct ndr_print *ndr, const char *name, enum CLAIM_TYPE r)
22 : {
23 11 : const char *val = NULL;
24 :
25 11 : switch (r) {
26 0 : case CLAIM_TYPE_INT64: val = "CLAIM_TYPE_INT64"; break;
27 4 : case CLAIM_TYPE_UINT64: val = "CLAIM_TYPE_UINT64"; break;
28 4 : case CLAIM_TYPE_STRING: val = "CLAIM_TYPE_STRING"; break;
29 3 : case CLAIM_TYPE_BOOLEAN: val = "CLAIM_TYPE_BOOLEAN"; break;
30 : }
31 11 : ndr_print_enum(ndr, name, "ENUM", val, r);
32 11 : }
33 :
34 3775 : static enum ndr_err_code ndr_push_CLAIMS_SOURCE_TYPE(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum CLAIMS_SOURCE_TYPE r)
35 : {
36 3775 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
37 3710 : return NDR_ERR_SUCCESS;
38 : }
39 :
40 635 : static enum ndr_err_code ndr_pull_CLAIMS_SOURCE_TYPE(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum CLAIMS_SOURCE_TYPE *r)
41 : {
42 18 : uint16_t v;
43 635 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
44 635 : *r = v;
45 635 : return NDR_ERR_SUCCESS;
46 : }
47 :
48 3 : _PUBLIC_ void ndr_print_CLAIMS_SOURCE_TYPE(struct ndr_print *ndr, const char *name, enum CLAIMS_SOURCE_TYPE r)
49 : {
50 3 : const char *val = NULL;
51 :
52 3 : switch (r) {
53 3 : case CLAIMS_SOURCE_TYPE_AD: val = "CLAIMS_SOURCE_TYPE_AD"; break;
54 0 : case CLAIMS_SOURCE_TYPE_CERTIFICATE: val = "CLAIMS_SOURCE_TYPE_CERTIFICATE"; break;
55 : }
56 3 : ndr_print_enum(ndr, name, "ENUM", val, r);
57 3 : }
58 :
59 745 : static enum ndr_err_code ndr_push_CLAIMS_COMPRESSION_FORMAT(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum CLAIMS_COMPRESSION_FORMAT r)
60 : {
61 745 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
62 732 : return NDR_ERR_SUCCESS;
63 : }
64 :
65 624 : static enum ndr_err_code ndr_pull_CLAIMS_COMPRESSION_FORMAT(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum CLAIMS_COMPRESSION_FORMAT *r)
66 : {
67 17 : uint16_t v;
68 624 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
69 624 : *r = v;
70 624 : return NDR_ERR_SUCCESS;
71 : }
72 :
73 2 : _PUBLIC_ void ndr_print_CLAIMS_COMPRESSION_FORMAT(struct ndr_print *ndr, const char *name, enum CLAIMS_COMPRESSION_FORMAT r)
74 : {
75 2 : const char *val = NULL;
76 :
77 2 : switch (r) {
78 1 : case CLAIMS_COMPRESSION_FORMAT_NONE: val = "CLAIMS_COMPRESSION_FORMAT_NONE"; break;
79 0 : case CLAIMS_COMPRESSION_FORMAT_LZNT1: val = "CLAIMS_COMPRESSION_FORMAT_LZNT1"; break;
80 0 : case CLAIMS_COMPRESSION_FORMAT_XPRESS: val = "CLAIMS_COMPRESSION_FORMAT_XPRESS"; break;
81 1 : case CLAIMS_COMPRESSION_FORMAT_XPRESS_HUFF: val = "CLAIMS_COMPRESSION_FORMAT_XPRESS_HUFF"; break;
82 : }
83 2 : ndr_print_enum(ndr, name, "ENUM", val, r);
84 2 : }
85 :
86 2820 : static enum ndr_err_code ndr_push_CLAIM_INT64(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIM_INT64 *r)
87 : {
88 10 : uint32_t cntr_values_1;
89 2820 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
90 2820 : if (ndr_flags & NDR_SCALARS) {
91 1410 : NDR_CHECK(ndr_push_align(ndr, 5));
92 1410 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->value_count));
93 1410 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->values));
94 1410 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
95 : }
96 2820 : if (ndr_flags & NDR_BUFFERS) {
97 1410 : if (r->values) {
98 1410 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->value_count));
99 3360 : for (cntr_values_1 = 0; cntr_values_1 < (r->value_count); cntr_values_1++) {
100 1950 : NDR_CHECK(ndr_push_int64(ndr, NDR_SCALARS, r->values[cntr_values_1]));
101 : }
102 : }
103 : }
104 2810 : return NDR_ERR_SUCCESS;
105 : }
106 :
107 106 : static enum ndr_err_code ndr_pull_CLAIM_INT64(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIM_INT64 *r)
108 : {
109 2 : uint32_t _ptr_values;
110 106 : uint32_t size_values_1 = 0;
111 2 : uint32_t cntr_values_1;
112 106 : TALLOC_CTX *_mem_save_values_0 = NULL;
113 106 : TALLOC_CTX *_mem_save_values_1 = NULL;
114 106 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
115 106 : if (ndr_flags & NDR_SCALARS) {
116 53 : NDR_CHECK(ndr_pull_align(ndr, 5));
117 53 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->value_count));
118 53 : if (r->value_count > 10*1024*1024) {
119 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->value_count), (uint32_t)(0), (uint32_t)(10*1024*1024));
120 : }
121 53 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_values));
122 53 : if (_ptr_values) {
123 53 : NDR_PULL_ALLOC(ndr, r->values);
124 : } else {
125 0 : r->values = NULL;
126 : }
127 53 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
128 : }
129 106 : if (ndr_flags & NDR_BUFFERS) {
130 53 : if (r->values) {
131 53 : _mem_save_values_0 = NDR_PULL_GET_MEM_CTX(ndr);
132 53 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
133 53 : NDR_CHECK(ndr_pull_array_size(ndr, &r->values));
134 53 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->values, &size_values_1));
135 53 : NDR_PULL_ALLOC_N(ndr, r->values, size_values_1);
136 53 : _mem_save_values_1 = NDR_PULL_GET_MEM_CTX(ndr);
137 53 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
138 246 : for (cntr_values_1 = 0; cntr_values_1 < (size_values_1); cntr_values_1++) {
139 193 : NDR_CHECK(ndr_pull_int64(ndr, NDR_SCALARS, &r->values[cntr_values_1]));
140 : }
141 53 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_1, 0);
142 53 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_0, 0);
143 : }
144 53 : if (r->values) {
145 53 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->values, r->value_count));
146 : }
147 : }
148 104 : return NDR_ERR_SUCCESS;
149 : }
150 :
151 0 : _PUBLIC_ void ndr_print_CLAIM_INT64(struct ndr_print *ndr, const char *name, const struct CLAIM_INT64 *r)
152 : {
153 0 : uint32_t cntr_values_1;
154 0 : ndr_print_struct(ndr, name, "CLAIM_INT64");
155 0 : if (r == NULL) { ndr_print_null(ndr); return; }
156 0 : ndr->depth++;
157 0 : ndr_print_uint32(ndr, "value_count", r->value_count);
158 0 : ndr_print_ptr(ndr, "values", r->values);
159 0 : ndr->depth++;
160 0 : if (r->values) {
161 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "values", (uint32_t)(r->value_count));
162 0 : ndr->depth++;
163 0 : for (cntr_values_1 = 0; cntr_values_1 < (r->value_count); cntr_values_1++) {
164 0 : ndr_print_int64(ndr, "values", r->values[cntr_values_1]);
165 : }
166 0 : ndr->depth--;
167 : }
168 0 : ndr->depth--;
169 0 : ndr->depth--;
170 : }
171 :
172 2590 : static enum ndr_err_code ndr_push_CLAIM_UINT64(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIM_UINT64 *r)
173 : {
174 300 : uint32_t cntr_values_1;
175 2590 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
176 2590 : if (ndr_flags & NDR_SCALARS) {
177 1295 : NDR_CHECK(ndr_push_align(ndr, 5));
178 1295 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->value_count));
179 1295 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->values));
180 1295 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
181 : }
182 2590 : if (ndr_flags & NDR_BUFFERS) {
183 1295 : if (r->values) {
184 1295 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->value_count));
185 1004565 : for (cntr_values_1 = 0; cntr_values_1 < (r->value_count); cntr_values_1++) {
186 1003270 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r->values[cntr_values_1]));
187 : }
188 : }
189 : }
190 2290 : return NDR_ERR_SUCCESS;
191 : }
192 :
193 718 : static enum ndr_err_code ndr_pull_CLAIM_UINT64(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIM_UINT64 *r)
194 : {
195 84 : uint32_t _ptr_values;
196 718 : uint32_t size_values_1 = 0;
197 84 : uint32_t cntr_values_1;
198 718 : TALLOC_CTX *_mem_save_values_0 = NULL;
199 718 : TALLOC_CTX *_mem_save_values_1 = NULL;
200 718 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
201 718 : if (ndr_flags & NDR_SCALARS) {
202 359 : NDR_CHECK(ndr_pull_align(ndr, 5));
203 359 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->value_count));
204 359 : if (r->value_count > 10*1024*1024) {
205 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->value_count), (uint32_t)(0), (uint32_t)(10*1024*1024));
206 : }
207 359 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_values));
208 359 : if (_ptr_values) {
209 359 : NDR_PULL_ALLOC(ndr, r->values);
210 : } else {
211 0 : r->values = NULL;
212 : }
213 359 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
214 : }
215 718 : if (ndr_flags & NDR_BUFFERS) {
216 359 : if (r->values) {
217 359 : _mem_save_values_0 = NDR_PULL_GET_MEM_CTX(ndr);
218 359 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
219 359 : NDR_CHECK(ndr_pull_array_size(ndr, &r->values));
220 359 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->values, &size_values_1));
221 359 : NDR_PULL_ALLOC_N(ndr, r->values, size_values_1);
222 359 : _mem_save_values_1 = NDR_PULL_GET_MEM_CTX(ndr);
223 359 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
224 101452 : for (cntr_values_1 = 0; cntr_values_1 < (size_values_1); cntr_values_1++) {
225 101093 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &r->values[cntr_values_1]));
226 : }
227 359 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_1, 0);
228 359 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_0, 0);
229 : }
230 359 : if (r->values) {
231 359 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->values, r->value_count));
232 : }
233 : }
234 634 : return NDR_ERR_SUCCESS;
235 : }
236 :
237 7 : _PUBLIC_ void ndr_print_CLAIM_UINT64(struct ndr_print *ndr, const char *name, const struct CLAIM_UINT64 *r)
238 : {
239 7 : uint32_t cntr_values_1;
240 7 : ndr_print_struct(ndr, name, "CLAIM_UINT64");
241 7 : if (r == NULL) { ndr_print_null(ndr); return; }
242 7 : ndr->depth++;
243 7 : ndr_print_uint32(ndr, "value_count", r->value_count);
244 7 : ndr_print_ptr(ndr, "values", r->values);
245 7 : ndr->depth++;
246 7 : if (r->values) {
247 7 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "values", (uint32_t)(r->value_count));
248 7 : ndr->depth++;
249 26 : for (cntr_values_1 = 0; cntr_values_1 < (r->value_count); cntr_values_1++) {
250 19 : ndr_print_hyper(ndr, "values", r->values[cntr_values_1]);
251 : }
252 7 : ndr->depth--;
253 : }
254 7 : ndr->depth--;
255 7 : ndr->depth--;
256 : }
257 :
258 10280 : static enum ndr_err_code ndr_push_CLAIM_STRING(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIM_STRING *r)
259 : {
260 180 : uint32_t cntr_values_1;
261 10280 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
262 10280 : if (ndr_flags & NDR_SCALARS) {
263 5140 : NDR_CHECK(ndr_push_align(ndr, 5));
264 5140 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->value_count));
265 5140 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->values));
266 5140 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
267 : }
268 10280 : if (ndr_flags & NDR_BUFFERS) {
269 5140 : if (r->values) {
270 5140 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->value_count));
271 11285 : for (cntr_values_1 = 0; cntr_values_1 < (r->value_count); cntr_values_1++) {
272 6145 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->values[cntr_values_1]));
273 : }
274 11285 : for (cntr_values_1 = 0; cntr_values_1 < (r->value_count); cntr_values_1++) {
275 6145 : if (r->values[cntr_values_1]) {
276 6145 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->values[cntr_values_1], CH_UTF16)));
277 6145 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
278 6145 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->values[cntr_values_1], CH_UTF16)));
279 6145 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->values[cntr_values_1], ndr_charset_length(r->values[cntr_values_1], CH_UTF16), sizeof(uint16_t), CH_UTF16));
280 : }
281 : }
282 : }
283 : }
284 10100 : return NDR_ERR_SUCCESS;
285 : }
286 :
287 3856 : static enum ndr_err_code ndr_pull_CLAIM_STRING(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIM_STRING *r)
288 : {
289 50 : uint32_t _ptr_values;
290 3856 : uint32_t size_values_1 = 0;
291 50 : uint32_t cntr_values_1;
292 3856 : uint32_t size_values_3 = 0;
293 3856 : uint32_t length_values_3 = 0;
294 3856 : TALLOC_CTX *_mem_save_values_0 = NULL;
295 3856 : TALLOC_CTX *_mem_save_values_1 = NULL;
296 3856 : TALLOC_CTX *_mem_save_values_2 = NULL;
297 3856 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
298 3856 : if (ndr_flags & NDR_SCALARS) {
299 1928 : NDR_CHECK(ndr_pull_align(ndr, 5));
300 1928 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->value_count));
301 1928 : if (r->value_count > 10*1024*1024) {
302 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->value_count), (uint32_t)(0), (uint32_t)(10*1024*1024));
303 : }
304 1928 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_values));
305 1928 : if (_ptr_values) {
306 1928 : NDR_PULL_ALLOC(ndr, r->values);
307 : } else {
308 0 : r->values = NULL;
309 : }
310 1928 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
311 : }
312 3856 : if (ndr_flags & NDR_BUFFERS) {
313 1928 : if (r->values) {
314 1928 : _mem_save_values_0 = NDR_PULL_GET_MEM_CTX(ndr);
315 1928 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
316 1928 : NDR_CHECK(ndr_pull_array_size(ndr, &r->values));
317 1928 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->values, &size_values_1));
318 1928 : NDR_PULL_ALLOC_N(ndr, r->values, size_values_1);
319 1928 : _mem_save_values_1 = NDR_PULL_GET_MEM_CTX(ndr);
320 1928 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
321 4397 : for (cntr_values_1 = 0; cntr_values_1 < (size_values_1); cntr_values_1++) {
322 2469 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_values));
323 2469 : if (_ptr_values) {
324 2469 : NDR_PULL_ALLOC(ndr, r->values[cntr_values_1]);
325 : } else {
326 0 : r->values[cntr_values_1] = NULL;
327 : }
328 : }
329 4397 : for (cntr_values_1 = 0; cntr_values_1 < (size_values_1); cntr_values_1++) {
330 2469 : if (r->values[cntr_values_1]) {
331 2469 : _mem_save_values_2 = NDR_PULL_GET_MEM_CTX(ndr);
332 2469 : NDR_PULL_SET_MEM_CTX(ndr, r->values[cntr_values_1], 0);
333 2469 : NDR_CHECK(ndr_pull_array_size(ndr, &r->values[cntr_values_1]));
334 2469 : NDR_CHECK(ndr_pull_array_length(ndr, &r->values[cntr_values_1]));
335 2469 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->values[cntr_values_1], &size_values_3));
336 2469 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->values[cntr_values_1], &length_values_3));
337 2469 : if (length_values_3 > size_values_3) {
338 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_values_3, length_values_3);
339 : }
340 2469 : NDR_CHECK(ndr_check_string_terminator(ndr, length_values_3, sizeof(uint16_t)));
341 2469 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->values[cntr_values_1], length_values_3, sizeof(uint16_t), CH_UTF16));
342 2469 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_2, 0);
343 : }
344 : }
345 1928 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_1, 0);
346 1928 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_0, 0);
347 : }
348 1928 : if (r->values) {
349 1928 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->values, r->value_count));
350 : }
351 4397 : for (cntr_values_1 = 0; cntr_values_1 < (size_values_1); cntr_values_1++) {
352 83 : }
353 : }
354 3806 : return NDR_ERR_SUCCESS;
355 : }
356 :
357 4 : _PUBLIC_ void ndr_print_CLAIM_STRING(struct ndr_print *ndr, const char *name, const struct CLAIM_STRING *r)
358 : {
359 4 : uint32_t cntr_values_1;
360 4 : ndr_print_struct(ndr, name, "CLAIM_STRING");
361 4 : if (r == NULL) { ndr_print_null(ndr); return; }
362 4 : ndr->depth++;
363 4 : ndr_print_uint32(ndr, "value_count", r->value_count);
364 4 : ndr_print_ptr(ndr, "values", r->values);
365 4 : ndr->depth++;
366 4 : if (r->values) {
367 4 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "values", (uint32_t)(r->value_count));
368 4 : ndr->depth++;
369 17 : for (cntr_values_1 = 0; cntr_values_1 < (r->value_count); cntr_values_1++) {
370 13 : ndr_print_ptr(ndr, "values", r->values[cntr_values_1]);
371 13 : ndr->depth++;
372 13 : if (r->values[cntr_values_1]) {
373 13 : ndr_print_string(ndr, "values", r->values[cntr_values_1]);
374 : }
375 13 : ndr->depth--;
376 : }
377 4 : ndr->depth--;
378 : }
379 4 : ndr->depth--;
380 4 : ndr->depth--;
381 : }
382 :
383 15730 : static enum ndr_err_code ndr_push_CLAIM_ENTRY_VALUES(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union CLAIM_ENTRY_VALUES *r)
384 : {
385 490 : uint32_t level;
386 : {
387 15730 : libndr_flags _flags_save_UNION = ndr->flags;
388 15730 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
389 15730 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
390 15730 : if (ndr_flags & NDR_SCALARS) {
391 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
392 7865 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
393 7865 : NDR_CHECK(ndr_push_union_align(ndr, 5));
394 8110 : NDR_CHECK(ndr_push_CLAIM_TYPE(ndr, NDR_SCALARS, level));
395 7865 : NDR_CHECK(ndr_push_union_align(ndr, 5));
396 7865 : switch (level) {
397 1410 : case CLAIM_TYPE_INT64: {
398 1410 : NDR_CHECK(ndr_push_CLAIM_INT64(ndr, NDR_SCALARS, &r->claim_int64));
399 1405 : break; }
400 :
401 720 : case CLAIM_TYPE_UINT64: {
402 720 : NDR_CHECK(ndr_push_CLAIM_UINT64(ndr, NDR_SCALARS, &r->claim_uint64));
403 630 : break; }
404 :
405 5140 : case CLAIM_TYPE_STRING: {
406 5140 : NDR_CHECK(ndr_push_CLAIM_STRING(ndr, NDR_SCALARS, &r->claim_string));
407 5050 : break; }
408 :
409 575 : case CLAIM_TYPE_BOOLEAN: {
410 575 : NDR_CHECK(ndr_push_CLAIM_UINT64(ndr, NDR_SCALARS, &r->claim_boolean));
411 515 : break; }
412 :
413 20 : default: {
414 20 : break; }
415 :
416 : }
417 : }
418 15730 : if (ndr_flags & NDR_BUFFERS) {
419 7865 : if (!(ndr_flags & NDR_SCALARS)) {
420 : /* We didn't get it above, and the token is not needed after this. */
421 7865 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
422 : }
423 7865 : switch (level) {
424 1410 : case CLAIM_TYPE_INT64:
425 1410 : NDR_CHECK(ndr_push_CLAIM_INT64(ndr, NDR_BUFFERS, &r->claim_int64));
426 1405 : break;
427 :
428 720 : case CLAIM_TYPE_UINT64:
429 720 : NDR_CHECK(ndr_push_CLAIM_UINT64(ndr, NDR_BUFFERS, &r->claim_uint64));
430 630 : break;
431 :
432 5140 : case CLAIM_TYPE_STRING:
433 5140 : NDR_CHECK(ndr_push_CLAIM_STRING(ndr, NDR_BUFFERS, &r->claim_string));
434 5050 : break;
435 :
436 575 : case CLAIM_TYPE_BOOLEAN:
437 575 : NDR_CHECK(ndr_push_CLAIM_UINT64(ndr, NDR_BUFFERS, &r->claim_boolean));
438 515 : break;
439 :
440 20 : default:
441 20 : break;
442 :
443 : }
444 : }
445 15730 : ndr->flags = _flags_save_UNION;
446 : }
447 15730 : return NDR_ERR_SUCCESS;
448 : }
449 :
450 4688 : static enum ndr_err_code ndr_pull_CLAIM_ENTRY_VALUES(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union CLAIM_ENTRY_VALUES *r)
451 : {
452 136 : uint32_t level;
453 136 : uint16_t _level;
454 : {
455 4688 : libndr_flags _flags_save_UNION = ndr->flags;
456 4688 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
457 4688 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
458 4688 : if (ndr_flags & NDR_SCALARS) {
459 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
460 2344 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
461 2344 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
462 2344 : NDR_CHECK(ndr_pull_uint1632(ndr, NDR_SCALARS, &_level));
463 2344 : if (_level != level) {
464 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu16" for r at %s", (uint16_t)_level, __location__);
465 : }
466 2344 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
467 2344 : switch (level) {
468 53 : case CLAIM_TYPE_INT64: {
469 53 : NDR_CHECK(ndr_pull_CLAIM_INT64(ndr, NDR_SCALARS, &r->claim_int64));
470 52 : break; }
471 :
472 245 : case CLAIM_TYPE_UINT64: {
473 245 : NDR_CHECK(ndr_pull_CLAIM_UINT64(ndr, NDR_SCALARS, &r->claim_uint64));
474 220 : break; }
475 :
476 1928 : case CLAIM_TYPE_STRING: {
477 1928 : NDR_CHECK(ndr_pull_CLAIM_STRING(ndr, NDR_SCALARS, &r->claim_string));
478 1903 : break; }
479 :
480 114 : case CLAIM_TYPE_BOOLEAN: {
481 114 : NDR_CHECK(ndr_pull_CLAIM_UINT64(ndr, NDR_SCALARS, &r->claim_boolean));
482 97 : break; }
483 :
484 4 : default: {
485 4 : break; }
486 :
487 : }
488 : }
489 4688 : if (ndr_flags & NDR_BUFFERS) {
490 2344 : if (!(ndr_flags & NDR_SCALARS)) {
491 : /* We didn't get it above, and the token is not needed after this. */
492 2344 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
493 : }
494 2344 : switch (level) {
495 53 : case CLAIM_TYPE_INT64:
496 53 : NDR_CHECK(ndr_pull_CLAIM_INT64(ndr, NDR_BUFFERS, &r->claim_int64));
497 52 : break;
498 :
499 245 : case CLAIM_TYPE_UINT64:
500 245 : NDR_CHECK(ndr_pull_CLAIM_UINT64(ndr, NDR_BUFFERS, &r->claim_uint64));
501 220 : break;
502 :
503 1928 : case CLAIM_TYPE_STRING:
504 1928 : NDR_CHECK(ndr_pull_CLAIM_STRING(ndr, NDR_BUFFERS, &r->claim_string));
505 1903 : break;
506 :
507 114 : case CLAIM_TYPE_BOOLEAN:
508 114 : NDR_CHECK(ndr_pull_CLAIM_UINT64(ndr, NDR_BUFFERS, &r->claim_boolean));
509 97 : break;
510 :
511 4 : default:
512 4 : break;
513 :
514 : }
515 : }
516 4688 : ndr->flags = _flags_save_UNION;
517 : }
518 4688 : return NDR_ERR_SUCCESS;
519 : }
520 :
521 11 : _PUBLIC_ void ndr_print_CLAIM_ENTRY_VALUES(struct ndr_print *ndr, const char *name, const union CLAIM_ENTRY_VALUES *r)
522 : {
523 11 : uint32_t level;
524 : {
525 11 : libndr_flags _flags_save_UNION = ndr->flags;
526 11 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
527 11 : level = ndr_print_steal_switch_value(ndr, r);
528 11 : ndr_print_union(ndr, name, level, "CLAIM_ENTRY_VALUES");
529 11 : switch (level) {
530 0 : case CLAIM_TYPE_INT64:
531 0 : ndr_print_CLAIM_INT64(ndr, "claim_int64", &r->claim_int64);
532 0 : break;
533 :
534 4 : case CLAIM_TYPE_UINT64:
535 4 : ndr_print_CLAIM_UINT64(ndr, "claim_uint64", &r->claim_uint64);
536 4 : break;
537 :
538 4 : case CLAIM_TYPE_STRING:
539 4 : ndr_print_CLAIM_STRING(ndr, "claim_string", &r->claim_string);
540 4 : break;
541 :
542 3 : case CLAIM_TYPE_BOOLEAN:
543 3 : ndr_print_CLAIM_UINT64(ndr, "claim_boolean", &r->claim_boolean);
544 3 : break;
545 :
546 0 : default:
547 0 : break;
548 :
549 : }
550 11 : ndr->flags = _flags_save_UNION;
551 : }
552 11 : }
553 :
554 15730 : static enum ndr_err_code ndr_push_CLAIM_ENTRY(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIM_ENTRY *r)
555 : {
556 15730 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
557 15730 : if (ndr_flags & NDR_SCALARS) {
558 7865 : NDR_CHECK(ndr_push_align(ndr, 5));
559 7865 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->id));
560 8110 : NDR_CHECK(ndr_push_CLAIM_TYPE(ndr, NDR_SCALARS, r->type));
561 7865 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->values, r->type));
562 7865 : NDR_CHECK(ndr_push_CLAIM_ENTRY_VALUES(ndr, NDR_SCALARS, &r->values));
563 7865 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
564 : }
565 15730 : if (ndr_flags & NDR_BUFFERS) {
566 7865 : if (r->id) {
567 7865 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->id, CH_UTF16)));
568 7865 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, 0));
569 7865 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, ndr_charset_length(r->id, CH_UTF16)));
570 7865 : NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->id, ndr_charset_length(r->id, CH_UTF16), sizeof(uint16_t), CH_UTF16));
571 : }
572 7865 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->values, r->type));
573 7865 : NDR_CHECK(ndr_push_CLAIM_ENTRY_VALUES(ndr, NDR_BUFFERS, &r->values));
574 : }
575 15240 : return NDR_ERR_SUCCESS;
576 : }
577 :
578 4688 : static enum ndr_err_code ndr_pull_CLAIM_ENTRY(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIM_ENTRY *r)
579 : {
580 136 : uint32_t _ptr_id;
581 4688 : uint32_t size_id_1 = 0;
582 4688 : uint32_t length_id_1 = 0;
583 4688 : TALLOC_CTX *_mem_save_id_0 = NULL;
584 4688 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
585 4688 : if (ndr_flags & NDR_SCALARS) {
586 2344 : NDR_CHECK(ndr_pull_align(ndr, 5));
587 2344 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_id));
588 2344 : if (_ptr_id) {
589 2344 : NDR_PULL_ALLOC(ndr, r->id);
590 : } else {
591 0 : r->id = NULL;
592 : }
593 2412 : NDR_CHECK(ndr_pull_CLAIM_TYPE(ndr, NDR_SCALARS, &r->type));
594 2344 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->values, r->type));
595 2344 : NDR_CHECK(ndr_pull_CLAIM_ENTRY_VALUES(ndr, NDR_SCALARS, &r->values));
596 2344 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
597 : }
598 4688 : if (ndr_flags & NDR_BUFFERS) {
599 2344 : if (r->id) {
600 2344 : _mem_save_id_0 = NDR_PULL_GET_MEM_CTX(ndr);
601 2344 : NDR_PULL_SET_MEM_CTX(ndr, r->id, 0);
602 2344 : NDR_CHECK(ndr_pull_array_size(ndr, &r->id));
603 2344 : NDR_CHECK(ndr_pull_array_length(ndr, &r->id));
604 2344 : NDR_CHECK(ndr_steal_array_size(ndr, (void*)&r->id, &size_id_1));
605 2344 : NDR_CHECK(ndr_steal_array_length(ndr, (void*)&r->id, &length_id_1));
606 2344 : if (length_id_1 > size_id_1) {
607 0 : return ndr_pull_error(ndr, NDR_ERR_ARRAY_SIZE, "Bad array size %"PRIu32": should exceed array length %"PRIu32"", size_id_1, length_id_1);
608 : }
609 2344 : NDR_CHECK(ndr_check_string_terminator(ndr, length_id_1, sizeof(uint16_t)));
610 2344 : NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->id, length_id_1, sizeof(uint16_t), CH_UTF16));
611 2344 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_id_0, 0);
612 : }
613 2344 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->values, r->type));
614 2344 : NDR_CHECK(ndr_pull_CLAIM_ENTRY_VALUES(ndr, NDR_BUFFERS, &r->values));
615 : }
616 4552 : return NDR_ERR_SUCCESS;
617 : }
618 :
619 11 : _PUBLIC_ void ndr_print_CLAIM_ENTRY(struct ndr_print *ndr, const char *name, const struct CLAIM_ENTRY *r)
620 : {
621 11 : ndr_print_struct(ndr, name, "CLAIM_ENTRY");
622 11 : if (r == NULL) { ndr_print_null(ndr); return; }
623 11 : ndr->depth++;
624 11 : ndr_print_ptr(ndr, "id", r->id);
625 11 : ndr->depth++;
626 11 : if (r->id) {
627 11 : ndr_print_string(ndr, "id", r->id);
628 : }
629 11 : ndr->depth--;
630 11 : ndr_print_CLAIM_TYPE(ndr, "type", r->type);
631 11 : ndr_print_set_switch_value(ndr, &r->values, r->type);
632 11 : ndr_print_CLAIM_ENTRY_VALUES(ndr, "values", &r->values);
633 11 : ndr->depth--;
634 : }
635 :
636 7550 : static enum ndr_err_code ndr_push_CLAIMS_ARRAY(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIMS_ARRAY *r)
637 : {
638 130 : uint32_t cntr_claim_entries_1;
639 7550 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
640 7550 : if (ndr_flags & NDR_SCALARS) {
641 3775 : NDR_CHECK(ndr_push_align(ndr, 5));
642 3840 : NDR_CHECK(ndr_push_CLAIMS_SOURCE_TYPE(ndr, NDR_SCALARS, r->claims_source_type));
643 3775 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->claims_count));
644 3775 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->claim_entries));
645 3775 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
646 : }
647 7550 : if (ndr_flags & NDR_BUFFERS) {
648 3775 : if (r->claim_entries) {
649 3775 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->claims_count));
650 11640 : for (cntr_claim_entries_1 = 0; cntr_claim_entries_1 < (r->claims_count); cntr_claim_entries_1++) {
651 7865 : NDR_CHECK(ndr_push_CLAIM_ENTRY(ndr, NDR_SCALARS, &r->claim_entries[cntr_claim_entries_1]));
652 : }
653 11640 : for (cntr_claim_entries_1 = 0; cntr_claim_entries_1 < (r->claims_count); cntr_claim_entries_1++) {
654 7865 : NDR_CHECK(ndr_push_CLAIM_ENTRY(ndr, NDR_BUFFERS, &r->claim_entries[cntr_claim_entries_1]));
655 : }
656 : }
657 : }
658 7420 : return NDR_ERR_SUCCESS;
659 : }
660 :
661 1270 : static enum ndr_err_code ndr_pull_CLAIMS_ARRAY(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIMS_ARRAY *r)
662 : {
663 36 : uint32_t _ptr_claim_entries;
664 1270 : uint32_t size_claim_entries_1 = 0;
665 36 : uint32_t cntr_claim_entries_1;
666 1270 : TALLOC_CTX *_mem_save_claim_entries_0 = NULL;
667 1270 : TALLOC_CTX *_mem_save_claim_entries_1 = NULL;
668 1270 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
669 1270 : if (ndr_flags & NDR_SCALARS) {
670 635 : NDR_CHECK(ndr_pull_align(ndr, 5));
671 653 : NDR_CHECK(ndr_pull_CLAIMS_SOURCE_TYPE(ndr, NDR_SCALARS, &r->claims_source_type));
672 635 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->claims_count));
673 635 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_claim_entries));
674 635 : if (_ptr_claim_entries) {
675 635 : NDR_PULL_ALLOC(ndr, r->claim_entries);
676 : } else {
677 0 : r->claim_entries = NULL;
678 : }
679 635 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
680 : }
681 1270 : if (ndr_flags & NDR_BUFFERS) {
682 635 : if (r->claim_entries) {
683 635 : _mem_save_claim_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
684 635 : NDR_PULL_SET_MEM_CTX(ndr, r->claim_entries, 0);
685 635 : NDR_CHECK(ndr_pull_array_size(ndr, &r->claim_entries));
686 635 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->claim_entries, &size_claim_entries_1));
687 635 : NDR_PULL_ALLOC_N(ndr, r->claim_entries, size_claim_entries_1);
688 635 : _mem_save_claim_entries_1 = NDR_PULL_GET_MEM_CTX(ndr);
689 635 : NDR_PULL_SET_MEM_CTX(ndr, r->claim_entries, 0);
690 2979 : for (cntr_claim_entries_1 = 0; cntr_claim_entries_1 < (size_claim_entries_1); cntr_claim_entries_1++) {
691 2344 : NDR_CHECK(ndr_pull_CLAIM_ENTRY(ndr, NDR_SCALARS, &r->claim_entries[cntr_claim_entries_1]));
692 : }
693 2979 : for (cntr_claim_entries_1 = 0; cntr_claim_entries_1 < (size_claim_entries_1); cntr_claim_entries_1++) {
694 2344 : NDR_CHECK(ndr_pull_CLAIM_ENTRY(ndr, NDR_BUFFERS, &r->claim_entries[cntr_claim_entries_1]));
695 : }
696 635 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_claim_entries_1, 0);
697 635 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_claim_entries_0, 0);
698 : }
699 635 : if (r->claim_entries) {
700 635 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->claim_entries, r->claims_count));
701 : }
702 2979 : for (cntr_claim_entries_1 = 0; cntr_claim_entries_1 < (size_claim_entries_1); cntr_claim_entries_1++) {
703 68 : }
704 : }
705 1234 : return NDR_ERR_SUCCESS;
706 : }
707 :
708 3 : _PUBLIC_ void ndr_print_CLAIMS_ARRAY(struct ndr_print *ndr, const char *name, const struct CLAIMS_ARRAY *r)
709 : {
710 3 : uint32_t cntr_claim_entries_1;
711 3 : ndr_print_struct(ndr, name, "CLAIMS_ARRAY");
712 3 : if (r == NULL) { ndr_print_null(ndr); return; }
713 3 : ndr->depth++;
714 3 : ndr_print_CLAIMS_SOURCE_TYPE(ndr, "claims_source_type", r->claims_source_type);
715 3 : ndr_print_uint32(ndr, "claims_count", r->claims_count);
716 3 : ndr_print_ptr(ndr, "claim_entries", r->claim_entries);
717 3 : ndr->depth++;
718 3 : if (r->claim_entries) {
719 3 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "claim_entries", (uint32_t)(r->claims_count));
720 3 : ndr->depth++;
721 14 : for (cntr_claim_entries_1 = 0; cntr_claim_entries_1 < (r->claims_count); cntr_claim_entries_1++) {
722 11 : ndr_print_CLAIM_ENTRY(ndr, "claim_entries", &r->claim_entries[cntr_claim_entries_1]);
723 : }
724 3 : ndr->depth--;
725 : }
726 3 : ndr->depth--;
727 3 : ndr->depth--;
728 : }
729 :
730 745 : static enum ndr_err_code ndr_push_CLAIMS_SET_METADATA_CTR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIMS_SET_METADATA_CTR *r)
731 : {
732 745 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
733 745 : if (ndr_flags & NDR_SCALARS) {
734 745 : NDR_CHECK(ndr_push_align(ndr, 5));
735 745 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->metadata));
736 745 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
737 : }
738 745 : if (ndr_flags & NDR_BUFFERS) {
739 745 : if (r->metadata) {
740 745 : NDR_CHECK(ndr_push_CLAIMS_SET_METADATA(ndr, NDR_SCALARS|NDR_BUFFERS, r->metadata));
741 : }
742 : }
743 732 : return NDR_ERR_SUCCESS;
744 : }
745 :
746 624 : static enum ndr_err_code ndr_pull_CLAIMS_SET_METADATA_CTR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIMS_SET_METADATA_CTR *r)
747 : {
748 17 : uint32_t _ptr_metadata;
749 624 : TALLOC_CTX *_mem_save_metadata_0 = NULL;
750 624 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
751 624 : if (ndr_flags & NDR_SCALARS) {
752 624 : NDR_CHECK(ndr_pull_align(ndr, 5));
753 624 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_metadata));
754 624 : if (_ptr_metadata) {
755 624 : NDR_PULL_ALLOC(ndr, r->metadata);
756 : } else {
757 0 : r->metadata = NULL;
758 : }
759 624 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
760 : }
761 624 : if (ndr_flags & NDR_BUFFERS) {
762 624 : if (r->metadata) {
763 624 : _mem_save_metadata_0 = NDR_PULL_GET_MEM_CTX(ndr);
764 624 : NDR_PULL_SET_MEM_CTX(ndr, r->metadata, 0);
765 624 : NDR_CHECK(ndr_pull_CLAIMS_SET_METADATA(ndr, NDR_SCALARS|NDR_BUFFERS, r->metadata));
766 624 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_metadata_0, 0);
767 : }
768 : }
769 607 : return NDR_ERR_SUCCESS;
770 : }
771 :
772 2 : _PUBLIC_ void ndr_print_CLAIMS_SET_METADATA_CTR(struct ndr_print *ndr, const char *name, const struct CLAIMS_SET_METADATA_CTR *r)
773 : {
774 2 : ndr_print_struct(ndr, name, "CLAIMS_SET_METADATA_CTR");
775 2 : if (r == NULL) { ndr_print_null(ndr); return; }
776 2 : ndr->depth++;
777 2 : ndr_print_ptr(ndr, "metadata", r->metadata);
778 2 : ndr->depth++;
779 2 : if (r->metadata) {
780 2 : ndr_print_CLAIMS_SET_METADATA(ndr, "metadata", r->metadata);
781 : }
782 2 : ndr->depth--;
783 2 : ndr->depth--;
784 : }
785 :
786 3725 : static enum ndr_err_code ndr_push_CLAIMS_SET_CTR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIMS_SET_CTR *r)
787 : {
788 3725 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
789 3725 : if (ndr_flags & NDR_SCALARS) {
790 3725 : NDR_CHECK(ndr_push_align(ndr, 5));
791 3725 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->claims));
792 3725 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
793 : }
794 3725 : if (ndr_flags & NDR_BUFFERS) {
795 3725 : if (r->claims) {
796 3725 : NDR_CHECK(ndr_push_CLAIMS_SET(ndr, NDR_SCALARS|NDR_BUFFERS, r->claims));
797 : }
798 : }
799 3660 : return NDR_ERR_SUCCESS;
800 : }
801 :
802 625 : static enum ndr_err_code ndr_pull_CLAIMS_SET_CTR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIMS_SET_CTR *r)
803 : {
804 18 : uint32_t _ptr_claims;
805 625 : TALLOC_CTX *_mem_save_claims_0 = NULL;
806 625 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
807 625 : if (ndr_flags & NDR_SCALARS) {
808 625 : NDR_CHECK(ndr_pull_align(ndr, 5));
809 625 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_claims));
810 625 : if (_ptr_claims) {
811 625 : NDR_PULL_ALLOC(ndr, r->claims);
812 : } else {
813 0 : r->claims = NULL;
814 : }
815 625 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
816 : }
817 625 : if (ndr_flags & NDR_BUFFERS) {
818 625 : if (r->claims) {
819 625 : _mem_save_claims_0 = NDR_PULL_GET_MEM_CTX(ndr);
820 625 : NDR_PULL_SET_MEM_CTX(ndr, r->claims, 0);
821 625 : NDR_CHECK(ndr_pull_CLAIMS_SET(ndr, NDR_SCALARS|NDR_BUFFERS, r->claims));
822 625 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_claims_0, 0);
823 : }
824 : }
825 607 : return NDR_ERR_SUCCESS;
826 : }
827 :
828 3 : _PUBLIC_ void ndr_print_CLAIMS_SET_CTR(struct ndr_print *ndr, const char *name, const struct CLAIMS_SET_CTR *r)
829 : {
830 3 : ndr_print_struct(ndr, name, "CLAIMS_SET_CTR");
831 3 : if (r == NULL) { ndr_print_null(ndr); return; }
832 3 : ndr->depth++;
833 3 : ndr_print_ptr(ndr, "claims", r->claims);
834 3 : ndr->depth++;
835 3 : if (r->claims) {
836 3 : ndr_print_CLAIMS_SET(ndr, "claims", r->claims);
837 : }
838 3 : ndr->depth--;
839 3 : ndr->depth--;
840 : }
841 :
842 3725 : _PUBLIC_ enum ndr_err_code ndr_push_CLAIMS_SET(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIMS_SET *r)
843 : {
844 65 : uint32_t cntr_claims_arrays_1;
845 3725 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
846 3725 : if (ndr_flags & NDR_SCALARS) {
847 3725 : NDR_CHECK(ndr_push_align(ndr, 5));
848 3725 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->claims_array_count));
849 3725 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->claims_arrays));
850 3725 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->reserved_type));
851 3725 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->reserved_field_size));
852 3725 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->reserved_field));
853 3725 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
854 : }
855 3725 : if (ndr_flags & NDR_BUFFERS) {
856 3725 : if (r->claims_arrays) {
857 3725 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->claims_array_count));
858 7500 : for (cntr_claims_arrays_1 = 0; cntr_claims_arrays_1 < (r->claims_array_count); cntr_claims_arrays_1++) {
859 3775 : NDR_CHECK(ndr_push_CLAIMS_ARRAY(ndr, NDR_SCALARS, &r->claims_arrays[cntr_claims_arrays_1]));
860 : }
861 7500 : for (cntr_claims_arrays_1 = 0; cntr_claims_arrays_1 < (r->claims_array_count); cntr_claims_arrays_1++) {
862 3775 : NDR_CHECK(ndr_push_CLAIMS_ARRAY(ndr, NDR_BUFFERS, &r->claims_arrays[cntr_claims_arrays_1]));
863 : }
864 : }
865 3725 : if (r->reserved_field) {
866 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->reserved_field_size));
867 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->reserved_field, r->reserved_field_size));
868 : }
869 : }
870 3660 : return NDR_ERR_SUCCESS;
871 : }
872 :
873 625 : _PUBLIC_ enum ndr_err_code ndr_pull_CLAIMS_SET(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIMS_SET *r)
874 : {
875 18 : uint32_t _ptr_claims_arrays;
876 625 : uint32_t size_claims_arrays_1 = 0;
877 18 : uint32_t cntr_claims_arrays_1;
878 625 : TALLOC_CTX *_mem_save_claims_arrays_0 = NULL;
879 625 : TALLOC_CTX *_mem_save_claims_arrays_1 = NULL;
880 18 : uint32_t _ptr_reserved_field;
881 625 : uint32_t size_reserved_field_1 = 0;
882 625 : TALLOC_CTX *_mem_save_reserved_field_0 = NULL;
883 625 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
884 625 : if (ndr_flags & NDR_SCALARS) {
885 625 : NDR_CHECK(ndr_pull_align(ndr, 5));
886 625 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->claims_array_count));
887 625 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_claims_arrays));
888 625 : if (_ptr_claims_arrays) {
889 625 : NDR_PULL_ALLOC(ndr, r->claims_arrays);
890 : } else {
891 0 : r->claims_arrays = NULL;
892 : }
893 625 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->reserved_type));
894 625 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->reserved_field_size));
895 625 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_reserved_field));
896 625 : if (_ptr_reserved_field) {
897 0 : NDR_PULL_ALLOC(ndr, r->reserved_field);
898 : } else {
899 625 : r->reserved_field = NULL;
900 : }
901 625 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
902 : }
903 625 : if (ndr_flags & NDR_BUFFERS) {
904 625 : if (r->claims_arrays) {
905 625 : _mem_save_claims_arrays_0 = NDR_PULL_GET_MEM_CTX(ndr);
906 625 : NDR_PULL_SET_MEM_CTX(ndr, r->claims_arrays, 0);
907 625 : NDR_CHECK(ndr_pull_array_size(ndr, &r->claims_arrays));
908 625 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->claims_arrays, &size_claims_arrays_1));
909 625 : NDR_PULL_ALLOC_N(ndr, r->claims_arrays, size_claims_arrays_1);
910 625 : _mem_save_claims_arrays_1 = NDR_PULL_GET_MEM_CTX(ndr);
911 625 : NDR_PULL_SET_MEM_CTX(ndr, r->claims_arrays, 0);
912 1260 : for (cntr_claims_arrays_1 = 0; cntr_claims_arrays_1 < (size_claims_arrays_1); cntr_claims_arrays_1++) {
913 635 : NDR_CHECK(ndr_pull_CLAIMS_ARRAY(ndr, NDR_SCALARS, &r->claims_arrays[cntr_claims_arrays_1]));
914 : }
915 1260 : for (cntr_claims_arrays_1 = 0; cntr_claims_arrays_1 < (size_claims_arrays_1); cntr_claims_arrays_1++) {
916 635 : NDR_CHECK(ndr_pull_CLAIMS_ARRAY(ndr, NDR_BUFFERS, &r->claims_arrays[cntr_claims_arrays_1]));
917 : }
918 625 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_claims_arrays_1, 0);
919 625 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_claims_arrays_0, 0);
920 : }
921 625 : if (r->reserved_field) {
922 0 : _mem_save_reserved_field_0 = NDR_PULL_GET_MEM_CTX(ndr);
923 0 : NDR_PULL_SET_MEM_CTX(ndr, r->reserved_field, 0);
924 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->reserved_field));
925 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->reserved_field, &size_reserved_field_1));
926 0 : NDR_PULL_ALLOC_N(ndr, r->reserved_field, size_reserved_field_1);
927 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->reserved_field, size_reserved_field_1));
928 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_reserved_field_0, 0);
929 : }
930 625 : if (r->claims_arrays) {
931 625 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->claims_arrays, r->claims_array_count));
932 : }
933 1260 : for (cntr_claims_arrays_1 = 0; cntr_claims_arrays_1 < (size_claims_arrays_1); cntr_claims_arrays_1++) {
934 18 : }
935 625 : if (r->reserved_field) {
936 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->reserved_field, r->reserved_field_size));
937 : }
938 : }
939 607 : return NDR_ERR_SUCCESS;
940 : }
941 :
942 0 : static void ndr_print_flags_CLAIMS_SET(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct CLAIMS_SET *r)
943 : {
944 0 : ndr_print_CLAIMS_SET(ndr, name, r);
945 0 : }
946 :
947 3 : _PUBLIC_ void ndr_print_CLAIMS_SET(struct ndr_print *ndr, const char *name, const struct CLAIMS_SET *r)
948 : {
949 3 : uint32_t cntr_claims_arrays_1;
950 3 : ndr_print_struct(ndr, name, "CLAIMS_SET");
951 3 : if (r == NULL) { ndr_print_null(ndr); return; }
952 3 : ndr->depth++;
953 3 : ndr_print_uint32(ndr, "claims_array_count", r->claims_array_count);
954 3 : ndr_print_ptr(ndr, "claims_arrays", r->claims_arrays);
955 3 : ndr->depth++;
956 3 : if (r->claims_arrays) {
957 3 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "claims_arrays", (uint32_t)(r->claims_array_count));
958 3 : ndr->depth++;
959 6 : for (cntr_claims_arrays_1 = 0; cntr_claims_arrays_1 < (r->claims_array_count); cntr_claims_arrays_1++) {
960 3 : ndr_print_CLAIMS_ARRAY(ndr, "claims_arrays", &r->claims_arrays[cntr_claims_arrays_1]);
961 : }
962 3 : ndr->depth--;
963 : }
964 3 : ndr->depth--;
965 3 : ndr_print_uint16(ndr, "reserved_type", r->reserved_type);
966 3 : ndr_print_uint32(ndr, "reserved_field_size", r->reserved_field_size);
967 3 : ndr_print_ptr(ndr, "reserved_field", r->reserved_field);
968 3 : ndr->depth++;
969 3 : if (r->reserved_field) {
970 0 : ndr_print_array_uint8(ndr, "reserved_field", r->reserved_field, r->reserved_field_size);
971 : }
972 3 : ndr->depth--;
973 3 : ndr->depth--;
974 : }
975 :
976 3725 : _PUBLIC_ enum ndr_err_code ndr_push_CLAIMS_SET_NDR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIMS_SET_NDR *r)
977 : {
978 3725 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
979 3725 : if (ndr_flags & NDR_SCALARS) {
980 3725 : NDR_CHECK(ndr_push_align(ndr, 1));
981 : {
982 65 : struct ndr_push *_ndr_claims;
983 3725 : NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_claims, 0xFFFFFC01, -1));
984 3725 : NDR_CHECK(ndr_push_CLAIMS_SET_CTR(_ndr_claims, NDR_SCALARS|NDR_BUFFERS, &r->claims));
985 3725 : NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_claims, 0xFFFFFC01, -1));
986 : }
987 3725 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
988 : }
989 3725 : if (ndr_flags & NDR_BUFFERS) {
990 65 : }
991 3725 : return NDR_ERR_SUCCESS;
992 : }
993 :
994 625 : _PUBLIC_ enum ndr_err_code ndr_pull_CLAIMS_SET_NDR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIMS_SET_NDR *r)
995 : {
996 625 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
997 625 : if (ndr_flags & NDR_SCALARS) {
998 625 : NDR_CHECK(ndr_pull_align(ndr, 1));
999 : {
1000 18 : struct ndr_pull *_ndr_claims;
1001 625 : NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_claims, 0xFFFFFC01, -1));
1002 625 : NDR_CHECK(ndr_pull_CLAIMS_SET_CTR(_ndr_claims, NDR_SCALARS|NDR_BUFFERS, &r->claims));
1003 625 : NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_claims, 0xFFFFFC01, -1));
1004 : }
1005 625 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
1006 : }
1007 625 : if (ndr_flags & NDR_BUFFERS) {
1008 18 : }
1009 625 : return NDR_ERR_SUCCESS;
1010 : }
1011 :
1012 1 : static void ndr_print_flags_CLAIMS_SET_NDR(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct CLAIMS_SET_NDR *r)
1013 : {
1014 1 : ndr_print_CLAIMS_SET_NDR(ndr, name, r);
1015 1 : }
1016 :
1017 3 : _PUBLIC_ void ndr_print_CLAIMS_SET_NDR(struct ndr_print *ndr, const char *name, const struct CLAIMS_SET_NDR *r)
1018 : {
1019 3 : ndr_print_struct(ndr, name, "CLAIMS_SET_NDR");
1020 3 : if (r == NULL) { ndr_print_null(ndr); return; }
1021 3 : ndr->depth++;
1022 3 : ndr_print_CLAIMS_SET_CTR(ndr, "claims", &r->claims);
1023 3 : ndr->depth--;
1024 : }
1025 :
1026 2235 : _PUBLIC_ size_t ndr_size_CLAIMS_SET_NDR(const struct CLAIMS_SET_NDR *r, libndr_flags flags)
1027 : {
1028 2235 : return ndr_size_struct(r, flags, (ndr_push_flags_fn_t)ndr_push_CLAIMS_SET_NDR);
1029 : }
1030 :
1031 745 : _PUBLIC_ enum ndr_err_code ndr_push_CLAIMS_SET_METADATA_NDR(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIMS_SET_METADATA_NDR *r)
1032 : {
1033 745 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1034 745 : if (ndr_flags & NDR_SCALARS) {
1035 745 : NDR_CHECK(ndr_push_align(ndr, 1));
1036 : {
1037 13 : struct ndr_push *_ndr_claims;
1038 745 : NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_claims, 0xFFFFFC01, -1));
1039 745 : NDR_CHECK(ndr_push_CLAIMS_SET_METADATA_CTR(_ndr_claims, NDR_SCALARS|NDR_BUFFERS, &r->claims));
1040 745 : NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_claims, 0xFFFFFC01, -1));
1041 : }
1042 745 : NDR_CHECK(ndr_push_trailer_align(ndr, 1));
1043 : }
1044 745 : if (ndr_flags & NDR_BUFFERS) {
1045 13 : }
1046 745 : return NDR_ERR_SUCCESS;
1047 : }
1048 :
1049 624 : _PUBLIC_ enum ndr_err_code ndr_pull_CLAIMS_SET_METADATA_NDR(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIMS_SET_METADATA_NDR *r)
1050 : {
1051 624 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1052 624 : if (ndr_flags & NDR_SCALARS) {
1053 624 : NDR_CHECK(ndr_pull_align(ndr, 1));
1054 : {
1055 17 : struct ndr_pull *_ndr_claims;
1056 624 : NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_claims, 0xFFFFFC01, -1));
1057 624 : NDR_CHECK(ndr_pull_CLAIMS_SET_METADATA_CTR(_ndr_claims, NDR_SCALARS|NDR_BUFFERS, &r->claims));
1058 624 : NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_claims, 0xFFFFFC01, -1));
1059 : }
1060 624 : NDR_CHECK(ndr_pull_trailer_align(ndr, 1));
1061 : }
1062 624 : if (ndr_flags & NDR_BUFFERS) {
1063 17 : }
1064 624 : return NDR_ERR_SUCCESS;
1065 : }
1066 :
1067 2 : static void ndr_print_flags_CLAIMS_SET_METADATA_NDR(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct CLAIMS_SET_METADATA_NDR *r)
1068 : {
1069 2 : ndr_print_CLAIMS_SET_METADATA_NDR(ndr, name, r);
1070 2 : }
1071 :
1072 2 : _PUBLIC_ void ndr_print_CLAIMS_SET_METADATA_NDR(struct ndr_print *ndr, const char *name, const struct CLAIMS_SET_METADATA_NDR *r)
1073 : {
1074 2 : ndr_print_struct(ndr, name, "CLAIMS_SET_METADATA_NDR");
1075 2 : if (r == NULL) { ndr_print_null(ndr); return; }
1076 2 : ndr->depth++;
1077 2 : ndr_print_CLAIMS_SET_METADATA_CTR(ndr, "claims", &r->claims);
1078 2 : ndr->depth--;
1079 : }
1080 :
1081 745 : _PUBLIC_ enum ndr_err_code ndr_push_CLAIMS_SET_METADATA(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIMS_SET_METADATA *r)
1082 : {
1083 745 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1084 745 : if (ndr_flags & NDR_SCALARS) {
1085 745 : NDR_CHECK(ndr_push_align(ndr, 5));
1086 745 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_claims_compressed_size(r->claims_set, r->compression_format, ndr->flags)));
1087 745 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->claims_set));
1088 758 : NDR_CHECK(ndr_push_CLAIMS_COMPRESSION_FORMAT(ndr, NDR_SCALARS, ndr_claims_actual_wire_compression_alg(r->compression_format, ndr_size_CLAIMS_SET_NDR(r->claims_set, ndr->flags))));
1089 745 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_size_CLAIMS_SET_NDR(r->claims_set, ndr->flags)));
1090 745 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->reserved_type));
1091 745 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->reserved_field_size));
1092 745 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->reserved_field));
1093 745 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1094 : }
1095 745 : if (ndr_flags & NDR_BUFFERS) {
1096 745 : if (r->claims_set) {
1097 : {
1098 13 : struct ndr_push *_ndr_claims_set;
1099 745 : NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_claims_set, 4, -1));
1100 : {
1101 13 : struct ndr_push *_ndr_claims_set_compressed;
1102 745 : NDR_CHECK(ndr_push_compression_state_init(_ndr_claims_set, ndr_claims_compression_alg(ndr_claims_actual_wire_compression_alg(r->compression_format, ndr_size_CLAIMS_SET_NDR(r->claims_set, ndr->flags)))));
1103 745 : NDR_CHECK(ndr_push_compression_start(_ndr_claims_set, &_ndr_claims_set_compressed));
1104 745 : NDR_CHECK(ndr_push_CLAIMS_SET_NDR(_ndr_claims_set_compressed, NDR_SCALARS|NDR_BUFFERS, r->claims_set));
1105 745 : NDR_CHECK(ndr_push_compression_end(_ndr_claims_set, _ndr_claims_set_compressed));
1106 745 : TALLOC_FREE(_ndr_claims_set->cstate);
1107 : }
1108 745 : NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_claims_set, 4, -1));
1109 : }
1110 : }
1111 745 : if (r->reserved_field) {
1112 0 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->reserved_field_size));
1113 0 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->reserved_field, r->reserved_field_size));
1114 : }
1115 : }
1116 732 : return NDR_ERR_SUCCESS;
1117 : }
1118 :
1119 624 : _PUBLIC_ enum ndr_err_code ndr_pull_CLAIMS_SET_METADATA(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIMS_SET_METADATA *r)
1120 : {
1121 17 : uint32_t _ptr_claims_set;
1122 624 : TALLOC_CTX *_mem_save_claims_set_0 = NULL;
1123 17 : uint32_t _ptr_reserved_field;
1124 624 : uint32_t size_reserved_field_1 = 0;
1125 624 : TALLOC_CTX *_mem_save_reserved_field_0 = NULL;
1126 624 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1127 624 : if (ndr_flags & NDR_SCALARS) {
1128 624 : NDR_CHECK(ndr_pull_align(ndr, 5));
1129 624 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->claims_set_size));
1130 624 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_claims_set));
1131 624 : if (_ptr_claims_set) {
1132 624 : NDR_PULL_ALLOC(ndr, r->claims_set);
1133 : } else {
1134 0 : r->claims_set = NULL;
1135 : }
1136 641 : NDR_CHECK(ndr_pull_CLAIMS_COMPRESSION_FORMAT(ndr, NDR_SCALARS, &r->compression_format));
1137 624 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->uncompressed_claims_set_size));
1138 624 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->reserved_type));
1139 624 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->reserved_field_size));
1140 624 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_reserved_field));
1141 624 : if (_ptr_reserved_field) {
1142 0 : NDR_PULL_ALLOC(ndr, r->reserved_field);
1143 : } else {
1144 624 : r->reserved_field = NULL;
1145 : }
1146 624 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1147 : }
1148 624 : if (ndr_flags & NDR_BUFFERS) {
1149 624 : if (r->claims_set) {
1150 624 : _mem_save_claims_set_0 = NDR_PULL_GET_MEM_CTX(ndr);
1151 624 : NDR_PULL_SET_MEM_CTX(ndr, r->claims_set, 0);
1152 : {
1153 17 : struct ndr_pull *_ndr_claims_set;
1154 624 : NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_claims_set, 4, -1));
1155 : {
1156 17 : struct ndr_pull *_ndr_claims_set_compressed;
1157 624 : NDR_CHECK(ndr_pull_compression_start(_ndr_claims_set, &_ndr_claims_set_compressed, ndr_claims_compression_alg(r->compression_format), r->uncompressed_claims_set_size, r->claims_set_size));
1158 624 : NDR_CHECK(ndr_pull_CLAIMS_SET_NDR(_ndr_claims_set_compressed, NDR_SCALARS|NDR_BUFFERS, r->claims_set));
1159 624 : NDR_CHECK(ndr_pull_compression_end(_ndr_claims_set, _ndr_claims_set_compressed, ndr_claims_compression_alg(r->compression_format), r->uncompressed_claims_set_size));
1160 : }
1161 624 : NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_claims_set, 4, -1));
1162 : }
1163 624 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_claims_set_0, 0);
1164 : }
1165 624 : if (r->reserved_field) {
1166 0 : _mem_save_reserved_field_0 = NDR_PULL_GET_MEM_CTX(ndr);
1167 0 : NDR_PULL_SET_MEM_CTX(ndr, r->reserved_field, 0);
1168 0 : NDR_CHECK(ndr_pull_array_size(ndr, &r->reserved_field));
1169 0 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->reserved_field, &size_reserved_field_1));
1170 0 : NDR_PULL_ALLOC_N(ndr, r->reserved_field, size_reserved_field_1);
1171 0 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->reserved_field, size_reserved_field_1));
1172 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_reserved_field_0, 0);
1173 : }
1174 624 : if (r->reserved_field) {
1175 0 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->reserved_field, r->reserved_field_size));
1176 : }
1177 : }
1178 607 : return NDR_ERR_SUCCESS;
1179 : }
1180 :
1181 0 : static void ndr_print_flags_CLAIMS_SET_METADATA(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct CLAIMS_SET_METADATA *r)
1182 : {
1183 0 : ndr_print_CLAIMS_SET_METADATA(ndr, name, r);
1184 0 : }
1185 :
1186 2 : _PUBLIC_ void ndr_print_CLAIMS_SET_METADATA(struct ndr_print *ndr, const char *name, const struct CLAIMS_SET_METADATA *r)
1187 : {
1188 2 : ndr_print_struct(ndr, name, "CLAIMS_SET_METADATA");
1189 2 : if (r == NULL) { ndr_print_null(ndr); return; }
1190 2 : ndr->depth++;
1191 2 : ndr_print_uint32(ndr, "claims_set_size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?ndr_claims_compressed_size(r->claims_set, r->compression_format, ndr->flags):r->claims_set_size);
1192 2 : ndr_print_ptr(ndr, "claims_set", r->claims_set);
1193 2 : ndr->depth++;
1194 2 : if (r->claims_set) {
1195 2 : ndr_print_CLAIMS_SET_NDR(ndr, "claims_set", r->claims_set);
1196 : }
1197 2 : ndr->depth--;
1198 2 : ndr_print_CLAIMS_COMPRESSION_FORMAT(ndr, "compression_format", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?ndr_claims_actual_wire_compression_alg(r->compression_format, ndr_size_CLAIMS_SET_NDR(r->claims_set, ndr->flags)):r->compression_format);
1199 2 : ndr_print_uint32(ndr, "uncompressed_claims_set_size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?ndr_size_CLAIMS_SET_NDR(r->claims_set, ndr->flags):r->uncompressed_claims_set_size);
1200 2 : ndr_print_uint16(ndr, "reserved_type", r->reserved_type);
1201 2 : ndr_print_uint32(ndr, "reserved_field_size", r->reserved_field_size);
1202 2 : ndr_print_ptr(ndr, "reserved_field", r->reserved_field);
1203 2 : ndr->depth++;
1204 2 : if (r->reserved_field) {
1205 0 : ndr_print_array_uint8(ndr, "reserved_field", r->reserved_field, r->reserved_field_size);
1206 : }
1207 2 : ndr->depth--;
1208 2 : ndr->depth--;
1209 : }
1210 :
1211 : #ifndef SKIP_NDR_TABLE_claims
1212 : static const struct ndr_interface_public_struct claims_public_structs[] = {
1213 : {
1214 : .name = "CLAIMS_SET",
1215 : .struct_size = sizeof(struct CLAIMS_SET ),
1216 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_CLAIMS_SET,
1217 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_CLAIMS_SET,
1218 : .ndr_print = (ndr_print_function_t) ndr_print_flags_CLAIMS_SET,
1219 : },
1220 : {
1221 : .name = "CLAIMS_SET_NDR",
1222 : .struct_size = sizeof(struct CLAIMS_SET_NDR ),
1223 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_CLAIMS_SET_NDR,
1224 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_CLAIMS_SET_NDR,
1225 : .ndr_print = (ndr_print_function_t) ndr_print_flags_CLAIMS_SET_NDR,
1226 : },
1227 : {
1228 : .name = "CLAIMS_SET_METADATA_NDR",
1229 : .struct_size = sizeof(struct CLAIMS_SET_METADATA_NDR ),
1230 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_CLAIMS_SET_METADATA_NDR,
1231 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_CLAIMS_SET_METADATA_NDR,
1232 : .ndr_print = (ndr_print_function_t) ndr_print_flags_CLAIMS_SET_METADATA_NDR,
1233 : },
1234 : {
1235 : .name = "CLAIMS_SET_METADATA",
1236 : .struct_size = sizeof(struct CLAIMS_SET_METADATA ),
1237 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_CLAIMS_SET_METADATA,
1238 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_CLAIMS_SET_METADATA,
1239 : .ndr_print = (ndr_print_function_t) ndr_print_flags_CLAIMS_SET_METADATA,
1240 : },
1241 : { .name = NULL }
1242 : };
1243 :
1244 : static const struct ndr_interface_call claims_calls[] = {
1245 : { .name = NULL }
1246 : };
1247 :
1248 : static const char * const claims_endpoint_strings[] = {
1249 : "ncacn_np:[\\pipe\\claims]",
1250 : };
1251 :
1252 : static const struct ndr_interface_string_array claims_endpoints = {
1253 : .count = 1,
1254 : .names = claims_endpoint_strings
1255 : };
1256 :
1257 : static const char * const claims_authservice_strings[] = {
1258 : "host",
1259 : };
1260 :
1261 : static const struct ndr_interface_string_array claims_authservices = {
1262 : .count = 1,
1263 : .names = claims_authservice_strings
1264 : };
1265 :
1266 :
1267 : const struct ndr_interface_table ndr_table_claims = {
1268 : .name = "claims",
1269 : .syntax_id = {
1270 : {0xbba9cb76,0xeb0c,0x462c,{0xaa,0x1b},{0x5d,0x8c,0x34,0x41,0x57,0x01}},
1271 : NDR_CLAIMS_VERSION
1272 : },
1273 : .helpstring = NDR_CLAIMS_HELPSTRING,
1274 : .num_calls = 0,
1275 : .calls = claims_calls,
1276 : .num_public_structs = 4,
1277 : .public_structs = claims_public_structs,
1278 : .endpoints = &claims_endpoints,
1279 : .authservices = &claims_authservices
1280 : };
1281 :
1282 : #endif /* SKIP_NDR_TABLE_claims */
|