f9e93e52102eae34b32c437929380ae9ebf7ed9f
[kai/samba.git] / source3 / librpc / gen_ndr / ndr_krb5pac.c
1 /* parser auto-generated by pidl */
2
3 #include "includes.h"
4 #include "librpc/gen_ndr/ndr_krb5pac.h"
5
6 #include "librpc/gen_ndr/ndr_security.h"
7 #include "librpc/gen_ndr/ndr_netlogon.h"
8 #include "librpc/gen_ndr/ndr_samr.h"
9 static enum ndr_err_code ndr_push_PAC_LOGON_NAME(struct ndr_push *ndr, int ndr_flags, const struct PAC_LOGON_NAME *r)
10 {
11         if (ndr_flags & NDR_SCALARS) {
12                 NDR_CHECK(ndr_push_align(ndr, 4));
13                 NDR_CHECK(ndr_push_NTTIME(ndr, NDR_SCALARS, r->logon_time));
14                 NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, 2 * strlen_m(r->account_name)));
15                 NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->account_name, 2 * strlen_m(r->account_name), sizeof(uint8_t), CH_UTF16));
16         }
17         if (ndr_flags & NDR_BUFFERS) {
18         }
19         return NDR_ERR_SUCCESS;
20 }
21
22 static enum ndr_err_code ndr_pull_PAC_LOGON_NAME(struct ndr_pull *ndr, int ndr_flags, struct PAC_LOGON_NAME *r)
23 {
24         if (ndr_flags & NDR_SCALARS) {
25                 NDR_CHECK(ndr_pull_align(ndr, 4));
26                 NDR_CHECK(ndr_pull_NTTIME(ndr, NDR_SCALARS, &r->logon_time));
27                 NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
28                 NDR_CHECK(ndr_pull_charset(ndr, NDR_SCALARS, &r->account_name, r->size, sizeof(uint8_t), CH_UTF16));
29         }
30         if (ndr_flags & NDR_BUFFERS) {
31         }
32         return NDR_ERR_SUCCESS;
33 }
34
35 _PUBLIC_ void ndr_print_PAC_LOGON_NAME(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_NAME *r)
36 {
37         ndr_print_struct(ndr, name, "PAC_LOGON_NAME");
38         ndr->depth++;
39         ndr_print_NTTIME(ndr, "logon_time", r->logon_time);
40         ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?2 * strlen_m(r->account_name):r->size);
41         ndr_print_string(ndr, "account_name", r->account_name);
42         ndr->depth--;
43 }
44
45 _PUBLIC_ enum ndr_err_code ndr_push_PAC_SIGNATURE_DATA(struct ndr_push *ndr, int ndr_flags, const struct PAC_SIGNATURE_DATA *r)
46 {
47         {
48                 uint32_t _flags_save_STRUCT = ndr->flags;
49                 ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
50                 if (ndr_flags & NDR_SCALARS) {
51                         NDR_CHECK(ndr_push_align(ndr, 4));
52                         NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->type));
53                         {
54                                 uint32_t _flags_save_DATA_BLOB = ndr->flags;
55                                 ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
56                                 NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->signature));
57                                 ndr->flags = _flags_save_DATA_BLOB;
58                         }
59                 }
60                 if (ndr_flags & NDR_BUFFERS) {
61                 }
62                 ndr->flags = _flags_save_STRUCT;
63         }
64         return NDR_ERR_SUCCESS;
65 }
66
67 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_SIGNATURE_DATA(struct ndr_pull *ndr, int ndr_flags, struct PAC_SIGNATURE_DATA *r)
68 {
69         {
70                 uint32_t _flags_save_STRUCT = ndr->flags;
71                 ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
72                 if (ndr_flags & NDR_SCALARS) {
73                         NDR_CHECK(ndr_pull_align(ndr, 4));
74                         NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->type));
75                         {
76                                 uint32_t _flags_save_DATA_BLOB = ndr->flags;
77                                 ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
78                                 NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->signature));
79                                 ndr->flags = _flags_save_DATA_BLOB;
80                         }
81                 }
82                 if (ndr_flags & NDR_BUFFERS) {
83                 }
84                 ndr->flags = _flags_save_STRUCT;
85         }
86         return NDR_ERR_SUCCESS;
87 }
88
89 _PUBLIC_ void ndr_print_PAC_SIGNATURE_DATA(struct ndr_print *ndr, const char *name, const struct PAC_SIGNATURE_DATA *r)
90 {
91         ndr_print_struct(ndr, name, "PAC_SIGNATURE_DATA");
92         {
93                 uint32_t _flags_save_STRUCT = ndr->flags;
94                 ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
95                 ndr->depth++;
96                 ndr_print_uint32(ndr, "type", r->type);
97                 ndr_print_DATA_BLOB(ndr, "signature", r->signature);
98                 ndr->depth--;
99                 ndr->flags = _flags_save_STRUCT;
100         }
101 }
102
103 static enum ndr_err_code ndr_push_PAC_LOGON_INFO(struct ndr_push *ndr, int ndr_flags, const struct PAC_LOGON_INFO *r)
104 {
105         if (ndr_flags & NDR_SCALARS) {
106                 NDR_CHECK(ndr_push_align(ndr, 4));
107                 NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
108                 NDR_CHECK(ndr_push_unique_ptr(ndr, r->res_group_dom_sid));
109                 NDR_CHECK(ndr_push_samr_RidWithAttributeArray(ndr, NDR_SCALARS, &r->res_groups));
110         }
111         if (ndr_flags & NDR_BUFFERS) {
112                 NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
113                 if (r->res_group_dom_sid) {
114                         NDR_CHECK(ndr_push_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->res_group_dom_sid));
115                 }
116                 NDR_CHECK(ndr_push_samr_RidWithAttributeArray(ndr, NDR_BUFFERS, &r->res_groups));
117         }
118         return NDR_ERR_SUCCESS;
119 }
120
121 static enum ndr_err_code ndr_pull_PAC_LOGON_INFO(struct ndr_pull *ndr, int ndr_flags, struct PAC_LOGON_INFO *r)
122 {
123         uint32_t _ptr_res_group_dom_sid;
124         TALLOC_CTX *_mem_save_res_group_dom_sid_0;
125         if (ndr_flags & NDR_SCALARS) {
126                 NDR_CHECK(ndr_pull_align(ndr, 4));
127                 NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
128                 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_res_group_dom_sid));
129                 if (_ptr_res_group_dom_sid) {
130                         NDR_PULL_ALLOC(ndr, r->res_group_dom_sid);
131                 } else {
132                         r->res_group_dom_sid = NULL;
133                 }
134                 NDR_CHECK(ndr_pull_samr_RidWithAttributeArray(ndr, NDR_SCALARS, &r->res_groups));
135         }
136         if (ndr_flags & NDR_BUFFERS) {
137                 NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
138                 if (r->res_group_dom_sid) {
139                         _mem_save_res_group_dom_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
140                         NDR_PULL_SET_MEM_CTX(ndr, r->res_group_dom_sid, 0);
141                         NDR_CHECK(ndr_pull_dom_sid2(ndr, NDR_SCALARS|NDR_BUFFERS, r->res_group_dom_sid));
142                         NDR_PULL_SET_MEM_CTX(ndr, _mem_save_res_group_dom_sid_0, 0);
143                 }
144                 NDR_CHECK(ndr_pull_samr_RidWithAttributeArray(ndr, NDR_BUFFERS, &r->res_groups));
145         }
146         return NDR_ERR_SUCCESS;
147 }
148
149 _PUBLIC_ void ndr_print_PAC_LOGON_INFO(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_INFO *r)
150 {
151         ndr_print_struct(ndr, name, "PAC_LOGON_INFO");
152         ndr->depth++;
153         ndr_print_netr_SamInfo3(ndr, "info3", &r->info3);
154         ndr_print_ptr(ndr, "res_group_dom_sid", r->res_group_dom_sid);
155         ndr->depth++;
156         if (r->res_group_dom_sid) {
157                 ndr_print_dom_sid2(ndr, "res_group_dom_sid", r->res_group_dom_sid);
158         }
159         ndr->depth--;
160         ndr_print_samr_RidWithAttributeArray(ndr, "res_groups", &r->res_groups);
161         ndr->depth--;
162 }
163
164 static size_t ndr_size_PAC_LOGON_INFO(const struct PAC_LOGON_INFO *r, int flags)
165 {
166         return ndr_size_struct(r, flags, (ndr_push_flags_fn_t)ndr_push_PAC_LOGON_INFO);
167 }
168
169 _PUBLIC_ enum ndr_err_code ndr_push_PAC_LOGON_INFO_CTR(struct ndr_push *ndr, int ndr_flags, const struct PAC_LOGON_INFO_CTR *r)
170 {
171         if (ndr_flags & NDR_SCALARS) {
172                 NDR_CHECK(ndr_push_align(ndr, 4));
173                 NDR_CHECK(ndr_push_unique_ptr(ndr, r->info));
174         }
175         if (ndr_flags & NDR_BUFFERS) {
176                 if (r->info) {
177                         NDR_CHECK(ndr_push_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, r->info));
178                 }
179         }
180         return NDR_ERR_SUCCESS;
181 }
182
183 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_LOGON_INFO_CTR(struct ndr_pull *ndr, int ndr_flags, struct PAC_LOGON_INFO_CTR *r)
184 {
185         uint32_t _ptr_info;
186         TALLOC_CTX *_mem_save_info_0;
187         if (ndr_flags & NDR_SCALARS) {
188                 NDR_CHECK(ndr_pull_align(ndr, 4));
189                 NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
190                 if (_ptr_info) {
191                         NDR_PULL_ALLOC(ndr, r->info);
192                 } else {
193                         r->info = NULL;
194                 }
195         }
196         if (ndr_flags & NDR_BUFFERS) {
197                 if (r->info) {
198                         _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
199                         NDR_PULL_SET_MEM_CTX(ndr, r->info, 0);
200                         NDR_CHECK(ndr_pull_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, r->info));
201                         NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, 0);
202                 }
203         }
204         return NDR_ERR_SUCCESS;
205 }
206
207 _PUBLIC_ void ndr_print_PAC_LOGON_INFO_CTR(struct ndr_print *ndr, const char *name, const struct PAC_LOGON_INFO_CTR *r)
208 {
209         ndr_print_struct(ndr, name, "PAC_LOGON_INFO_CTR");
210         ndr->depth++;
211         ndr_print_ptr(ndr, "info", r->info);
212         ndr->depth++;
213         if (r->info) {
214                 ndr_print_PAC_LOGON_INFO(ndr, "info", r->info);
215         }
216         ndr->depth--;
217         ndr->depth--;
218 }
219
220 _PUBLIC_ enum ndr_err_code ndr_push_PAC_TYPE(struct ndr_push *ndr, int ndr_flags, enum PAC_TYPE r)
221 {
222         NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
223         return NDR_ERR_SUCCESS;
224 }
225
226 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_TYPE(struct ndr_pull *ndr, int ndr_flags, enum PAC_TYPE *r)
227 {
228         uint32_t v;
229         NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
230         *r = v;
231         return NDR_ERR_SUCCESS;
232 }
233
234 _PUBLIC_ void ndr_print_PAC_TYPE(struct ndr_print *ndr, const char *name, enum PAC_TYPE r)
235 {
236         const char *val = NULL;
237
238         switch (r) {
239                 case PAC_TYPE_LOGON_INFO: val = "PAC_TYPE_LOGON_INFO"; break;
240                 case PAC_TYPE_SRV_CHECKSUM: val = "PAC_TYPE_SRV_CHECKSUM"; break;
241                 case PAC_TYPE_KDC_CHECKSUM: val = "PAC_TYPE_KDC_CHECKSUM"; break;
242                 case PAC_TYPE_LOGON_NAME: val = "PAC_TYPE_LOGON_NAME"; break;
243                 case PAC_TYPE_CONSTRAINED_DELEGATION: val = "PAC_TYPE_CONSTRAINED_DELEGATION"; break;
244                 case PAC_TYPE_UNKNOWN_12: val = "PAC_TYPE_UNKNOWN_12"; break;
245         }
246         ndr_print_enum(ndr, name, "ENUM", val, r);
247 }
248
249 static enum ndr_err_code ndr_push_DATA_BLOB_REM(struct ndr_push *ndr, int ndr_flags, const struct DATA_BLOB_REM *r)
250 {
251         if (ndr_flags & NDR_SCALARS) {
252                 NDR_CHECK(ndr_push_align(ndr, 4));
253                 {
254                         uint32_t _flags_save_DATA_BLOB = ndr->flags;
255                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
256                         NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->remaining));
257                         ndr->flags = _flags_save_DATA_BLOB;
258                 }
259         }
260         if (ndr_flags & NDR_BUFFERS) {
261         }
262         return NDR_ERR_SUCCESS;
263 }
264
265 static enum ndr_err_code ndr_pull_DATA_BLOB_REM(struct ndr_pull *ndr, int ndr_flags, struct DATA_BLOB_REM *r)
266 {
267         if (ndr_flags & NDR_SCALARS) {
268                 NDR_CHECK(ndr_pull_align(ndr, 4));
269                 {
270                         uint32_t _flags_save_DATA_BLOB = ndr->flags;
271                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
272                         NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->remaining));
273                         ndr->flags = _flags_save_DATA_BLOB;
274                 }
275         }
276         if (ndr_flags & NDR_BUFFERS) {
277         }
278         return NDR_ERR_SUCCESS;
279 }
280
281 _PUBLIC_ void ndr_print_DATA_BLOB_REM(struct ndr_print *ndr, const char *name, const struct DATA_BLOB_REM *r)
282 {
283         ndr_print_struct(ndr, name, "DATA_BLOB_REM");
284         ndr->depth++;
285         ndr_print_DATA_BLOB(ndr, "remaining", r->remaining);
286         ndr->depth--;
287 }
288
289 _PUBLIC_ enum ndr_err_code ndr_push_PAC_INFO(struct ndr_push *ndr, int ndr_flags, const union PAC_INFO *r)
290 {
291         if (ndr_flags & NDR_SCALARS) {
292                 int level = ndr_push_get_switch_value(ndr, r);
293                 switch (level) {
294                         case PAC_TYPE_LOGON_INFO: {
295                                 {
296                                         struct ndr_push *_ndr_logon_info;
297                                         NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_logon_info, 0xFFFFFC01, -1));
298                                         NDR_CHECK(ndr_push_PAC_LOGON_INFO_CTR(_ndr_logon_info, NDR_SCALARS|NDR_BUFFERS, &r->logon_info));
299                                         NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_logon_info, 0xFFFFFC01, -1));
300                                 }
301                         break; }
302
303                         case PAC_TYPE_SRV_CHECKSUM: {
304                                 NDR_CHECK(ndr_push_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->srv_cksum));
305                         break; }
306
307                         case PAC_TYPE_KDC_CHECKSUM: {
308                                 NDR_CHECK(ndr_push_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->kdc_cksum));
309                         break; }
310
311                         case PAC_TYPE_LOGON_NAME: {
312                                 NDR_CHECK(ndr_push_PAC_LOGON_NAME(ndr, NDR_SCALARS, &r->logon_name));
313                         break; }
314
315                         default: {
316                                 {
317                                         struct ndr_push *_ndr_unknown;
318                                         NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_unknown, 0, -1));
319                                         NDR_CHECK(ndr_push_DATA_BLOB_REM(_ndr_unknown, NDR_SCALARS, &r->unknown));
320                                         NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_unknown, 0, -1));
321                                 }
322                         break; }
323
324                 }
325         }
326         if (ndr_flags & NDR_BUFFERS) {
327                 int level = ndr_push_get_switch_value(ndr, r);
328                 switch (level) {
329                         case PAC_TYPE_LOGON_INFO:
330                         break;
331
332                         case PAC_TYPE_SRV_CHECKSUM:
333                         break;
334
335                         case PAC_TYPE_KDC_CHECKSUM:
336                         break;
337
338                         case PAC_TYPE_LOGON_NAME:
339                         break;
340
341                         default:
342                         break;
343
344                 }
345         }
346         return NDR_ERR_SUCCESS;
347 }
348
349 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_INFO(struct ndr_pull *ndr, int ndr_flags, union PAC_INFO *r)
350 {
351         int level;
352         level = ndr_pull_get_switch_value(ndr, r);
353         if (ndr_flags & NDR_SCALARS) {
354                 switch (level) {
355                         case PAC_TYPE_LOGON_INFO: {
356                                 {
357                                         struct ndr_pull *_ndr_logon_info;
358                                         NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_logon_info, 0xFFFFFC01, -1));
359                                         NDR_CHECK(ndr_pull_PAC_LOGON_INFO_CTR(_ndr_logon_info, NDR_SCALARS|NDR_BUFFERS, &r->logon_info));
360                                         NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_logon_info, 0xFFFFFC01, -1));
361                                 }
362                         break; }
363
364                         case PAC_TYPE_SRV_CHECKSUM: {
365                                 NDR_CHECK(ndr_pull_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->srv_cksum));
366                         break; }
367
368                         case PAC_TYPE_KDC_CHECKSUM: {
369                                 NDR_CHECK(ndr_pull_PAC_SIGNATURE_DATA(ndr, NDR_SCALARS, &r->kdc_cksum));
370                         break; }
371
372                         case PAC_TYPE_LOGON_NAME: {
373                                 NDR_CHECK(ndr_pull_PAC_LOGON_NAME(ndr, NDR_SCALARS, &r->logon_name));
374                         break; }
375
376                         default: {
377                                 {
378                                         struct ndr_pull *_ndr_unknown;
379                                         NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_unknown, 0, -1));
380                                         NDR_CHECK(ndr_pull_DATA_BLOB_REM(_ndr_unknown, NDR_SCALARS, &r->unknown));
381                                         NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_unknown, 0, -1));
382                                 }
383                         break; }
384
385                 }
386         }
387         if (ndr_flags & NDR_BUFFERS) {
388                 switch (level) {
389                         case PAC_TYPE_LOGON_INFO:
390                         break;
391
392                         case PAC_TYPE_SRV_CHECKSUM:
393                         break;
394
395                         case PAC_TYPE_KDC_CHECKSUM:
396                         break;
397
398                         case PAC_TYPE_LOGON_NAME:
399                         break;
400
401                         default:
402                         break;
403
404                 }
405         }
406         return NDR_ERR_SUCCESS;
407 }
408
409 _PUBLIC_ void ndr_print_PAC_INFO(struct ndr_print *ndr, const char *name, const union PAC_INFO *r)
410 {
411         int level;
412         level = ndr_print_get_switch_value(ndr, r);
413         ndr_print_union(ndr, name, level, "PAC_INFO");
414         switch (level) {
415                 case PAC_TYPE_LOGON_INFO:
416                         ndr_print_PAC_LOGON_INFO_CTR(ndr, "logon_info", &r->logon_info);
417                 break;
418
419                 case PAC_TYPE_SRV_CHECKSUM:
420                         ndr_print_PAC_SIGNATURE_DATA(ndr, "srv_cksum", &r->srv_cksum);
421                 break;
422
423                 case PAC_TYPE_KDC_CHECKSUM:
424                         ndr_print_PAC_SIGNATURE_DATA(ndr, "kdc_cksum", &r->kdc_cksum);
425                 break;
426
427                 case PAC_TYPE_LOGON_NAME:
428                         ndr_print_PAC_LOGON_NAME(ndr, "logon_name", &r->logon_name);
429                 break;
430
431                 default:
432                         ndr_print_DATA_BLOB_REM(ndr, "unknown", &r->unknown);
433                 break;
434
435         }
436 }
437
438 _PUBLIC_ size_t ndr_size_PAC_INFO(const union PAC_INFO *r, uint32_t level, int flags)
439 {
440         return ndr_size_union(r, flags, level, (ndr_push_flags_fn_t)ndr_push_PAC_INFO);
441 }
442
443 _PUBLIC_ enum ndr_err_code ndr_push_PAC_DATA(struct ndr_push *ndr, int ndr_flags, const struct PAC_DATA *r)
444 {
445         uint32_t cntr_buffers_0;
446         if (ndr_flags & NDR_SCALARS) {
447                 NDR_CHECK(ndr_push_align(ndr, 4));
448                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_buffers));
449                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version));
450                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
451                         NDR_CHECK(ndr_push_PAC_BUFFER(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
452                 }
453         }
454         if (ndr_flags & NDR_BUFFERS) {
455                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
456                         NDR_CHECK(ndr_push_PAC_BUFFER(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
457                 }
458         }
459         return NDR_ERR_SUCCESS;
460 }
461
462 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_DATA(struct ndr_pull *ndr, int ndr_flags, struct PAC_DATA *r)
463 {
464         uint32_t cntr_buffers_0;
465         TALLOC_CTX *_mem_save_buffers_0;
466         if (ndr_flags & NDR_SCALARS) {
467                 NDR_CHECK(ndr_pull_align(ndr, 4));
468                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_buffers));
469                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version));
470                 NDR_PULL_ALLOC_N(ndr, r->buffers, r->num_buffers);
471                 _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
472                 NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
473                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
474                         NDR_CHECK(ndr_pull_PAC_BUFFER(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
475                 }
476                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
477         }
478         if (ndr_flags & NDR_BUFFERS) {
479                 _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
480                 NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
481                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
482                         NDR_CHECK(ndr_pull_PAC_BUFFER(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
483                 }
484                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
485         }
486         return NDR_ERR_SUCCESS;
487 }
488
489 _PUBLIC_ void ndr_print_PAC_DATA(struct ndr_print *ndr, const char *name, const struct PAC_DATA *r)
490 {
491         uint32_t cntr_buffers_0;
492         ndr_print_struct(ndr, name, "PAC_DATA");
493         ndr->depth++;
494         ndr_print_uint32(ndr, "num_buffers", r->num_buffers);
495         ndr_print_uint32(ndr, "version", r->version);
496         ndr->print(ndr, "%s: ARRAY(%d)", "buffers", (int)r->num_buffers);
497         ndr->depth++;
498         for (cntr_buffers_0=0;cntr_buffers_0<r->num_buffers;cntr_buffers_0++) {
499                 char *idx_0=NULL;
500                 if (asprintf(&idx_0, "[%d]", cntr_buffers_0) != -1) {
501                         ndr_print_PAC_BUFFER(ndr, "buffers", &r->buffers[cntr_buffers_0]);
502                         free(idx_0);
503                 }
504         }
505         ndr->depth--;
506         ndr->depth--;
507 }
508
509 _PUBLIC_ enum ndr_err_code ndr_push_PAC_BUFFER_RAW(struct ndr_push *ndr, int ndr_flags, const struct PAC_BUFFER_RAW *r)
510 {
511         if (ndr_flags & NDR_SCALARS) {
512                 NDR_CHECK(ndr_push_align(ndr, 4));
513                 NDR_CHECK(ndr_push_PAC_TYPE(ndr, NDR_SCALARS, r->type));
514                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ndr_size));
515                 {
516                         uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
517                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
518                         NDR_CHECK(ndr_push_relative_ptr1(ndr, r->info));
519                         ndr->flags = _flags_save_DATA_BLOB_REM;
520                 }
521                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
522         }
523         if (ndr_flags & NDR_BUFFERS) {
524                 {
525                         uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
526                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
527                         if (r->info) {
528                                 NDR_CHECK(ndr_push_relative_ptr2(ndr, r->info));
529                                 {
530                                         struct ndr_push *_ndr_info;
531                                         NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
532                                         NDR_CHECK(ndr_push_DATA_BLOB_REM(_ndr_info, NDR_SCALARS, r->info));
533                                         NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
534                                 }
535                         }
536                         ndr->flags = _flags_save_DATA_BLOB_REM;
537                 }
538         }
539         return NDR_ERR_SUCCESS;
540 }
541
542 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_BUFFER_RAW(struct ndr_pull *ndr, int ndr_flags, struct PAC_BUFFER_RAW *r)
543 {
544         uint32_t _ptr_info;
545         TALLOC_CTX *_mem_save_info_0;
546         if (ndr_flags & NDR_SCALARS) {
547                 NDR_CHECK(ndr_pull_align(ndr, 4));
548                 NDR_CHECK(ndr_pull_PAC_TYPE(ndr, NDR_SCALARS, &r->type));
549                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ndr_size));
550                 {
551                         uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
552                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
553                         NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_info));
554                         if (_ptr_info) {
555                                 NDR_PULL_ALLOC(ndr, r->info);
556                                 NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->info, _ptr_info));
557                         } else {
558                                 r->info = NULL;
559                         }
560                         ndr->flags = _flags_save_DATA_BLOB_REM;
561                 }
562                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->_pad));
563         }
564         if (ndr_flags & NDR_BUFFERS) {
565                 {
566                         uint32_t _flags_save_DATA_BLOB_REM = ndr->flags;
567                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_ALIGN8);
568                         if (r->info) {
569                                 uint32_t _relative_save_offset;
570                                 _relative_save_offset = ndr->offset;
571                                 NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->info));
572                                 _mem_save_info_0 = NDR_PULL_GET_MEM_CTX(ndr);
573                                 NDR_PULL_SET_MEM_CTX(ndr, r->info, 0);
574                                 {
575                                         struct ndr_pull *_ndr_info;
576                                         NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
577                                         NDR_CHECK(ndr_pull_DATA_BLOB_REM(_ndr_info, NDR_SCALARS, r->info));
578                                         NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_info, 0, NDR_ROUND(r->ndr_size, 8)));
579                                 }
580                                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_info_0, 0);
581                                 ndr->offset = _relative_save_offset;
582                         }
583                         ndr->flags = _flags_save_DATA_BLOB_REM;
584                 }
585         }
586         return NDR_ERR_SUCCESS;
587 }
588
589 _PUBLIC_ void ndr_print_PAC_BUFFER_RAW(struct ndr_print *ndr, const char *name, const struct PAC_BUFFER_RAW *r)
590 {
591         ndr_print_struct(ndr, name, "PAC_BUFFER_RAW");
592         ndr->depth++;
593         ndr_print_PAC_TYPE(ndr, "type", r->type);
594         ndr_print_uint32(ndr, "ndr_size", r->ndr_size);
595         ndr_print_ptr(ndr, "info", r->info);
596         ndr->depth++;
597         if (r->info) {
598                 ndr_print_DATA_BLOB_REM(ndr, "info", r->info);
599         }
600         ndr->depth--;
601         ndr_print_uint32(ndr, "_pad", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?0:r->_pad);
602         ndr->depth--;
603 }
604
605 _PUBLIC_ enum ndr_err_code ndr_push_PAC_DATA_RAW(struct ndr_push *ndr, int ndr_flags, const struct PAC_DATA_RAW *r)
606 {
607         uint32_t cntr_buffers_0;
608         if (ndr_flags & NDR_SCALARS) {
609                 NDR_CHECK(ndr_push_align(ndr, 4));
610                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_buffers));
611                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->version));
612                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
613                         NDR_CHECK(ndr_push_PAC_BUFFER_RAW(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
614                 }
615         }
616         if (ndr_flags & NDR_BUFFERS) {
617                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
618                         NDR_CHECK(ndr_push_PAC_BUFFER_RAW(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
619                 }
620         }
621         return NDR_ERR_SUCCESS;
622 }
623
624 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_DATA_RAW(struct ndr_pull *ndr, int ndr_flags, struct PAC_DATA_RAW *r)
625 {
626         uint32_t cntr_buffers_0;
627         TALLOC_CTX *_mem_save_buffers_0;
628         if (ndr_flags & NDR_SCALARS) {
629                 NDR_CHECK(ndr_pull_align(ndr, 4));
630                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_buffers));
631                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->version));
632                 NDR_PULL_ALLOC_N(ndr, r->buffers, r->num_buffers);
633                 _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
634                 NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
635                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
636                         NDR_CHECK(ndr_pull_PAC_BUFFER_RAW(ndr, NDR_SCALARS, &r->buffers[cntr_buffers_0]));
637                 }
638                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
639         }
640         if (ndr_flags & NDR_BUFFERS) {
641                 _mem_save_buffers_0 = NDR_PULL_GET_MEM_CTX(ndr);
642                 NDR_PULL_SET_MEM_CTX(ndr, r->buffers, 0);
643                 for (cntr_buffers_0 = 0; cntr_buffers_0 < r->num_buffers; cntr_buffers_0++) {
644                         NDR_CHECK(ndr_pull_PAC_BUFFER_RAW(ndr, NDR_BUFFERS, &r->buffers[cntr_buffers_0]));
645                 }
646                 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_buffers_0, 0);
647         }
648         return NDR_ERR_SUCCESS;
649 }
650
651 _PUBLIC_ void ndr_print_PAC_DATA_RAW(struct ndr_print *ndr, const char *name, const struct PAC_DATA_RAW *r)
652 {
653         uint32_t cntr_buffers_0;
654         ndr_print_struct(ndr, name, "PAC_DATA_RAW");
655         ndr->depth++;
656         ndr_print_uint32(ndr, "num_buffers", r->num_buffers);
657         ndr_print_uint32(ndr, "version", r->version);
658         ndr->print(ndr, "%s: ARRAY(%d)", "buffers", (int)r->num_buffers);
659         ndr->depth++;
660         for (cntr_buffers_0=0;cntr_buffers_0<r->num_buffers;cntr_buffers_0++) {
661                 char *idx_0=NULL;
662                 if (asprintf(&idx_0, "[%d]", cntr_buffers_0) != -1) {
663                         ndr_print_PAC_BUFFER_RAW(ndr, "buffers", &r->buffers[cntr_buffers_0]);
664                         free(idx_0);
665                 }
666         }
667         ndr->depth--;
668         ndr->depth--;
669 }
670
671 _PUBLIC_ enum ndr_err_code ndr_push_PAC_Validate(struct ndr_push *ndr, int ndr_flags, const struct PAC_Validate *r)
672 {
673         if (ndr_flags & NDR_SCALARS) {
674                 NDR_CHECK(ndr_push_align(ndr, 4));
675                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, NETLOGON_GENERIC_KRB5_PAC_VALIDATE));
676                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ChecksumLength));
677                 NDR_CHECK(ndr_push_int32(ndr, NDR_SCALARS, r->SignatureType));
678                 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->SignatureLength));
679                 {
680                         uint32_t _flags_save_DATA_BLOB = ndr->flags;
681                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
682                         NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->ChecksumAndSignature));
683                         ndr->flags = _flags_save_DATA_BLOB;
684                 }
685         }
686         if (ndr_flags & NDR_BUFFERS) {
687         }
688         return NDR_ERR_SUCCESS;
689 }
690
691 _PUBLIC_ enum ndr_err_code ndr_pull_PAC_Validate(struct ndr_pull *ndr, int ndr_flags, struct PAC_Validate *r)
692 {
693         if (ndr_flags & NDR_SCALARS) {
694                 NDR_CHECK(ndr_pull_align(ndr, 4));
695                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->MessageType));
696                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ChecksumLength));
697                 NDR_CHECK(ndr_pull_int32(ndr, NDR_SCALARS, &r->SignatureType));
698                 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->SignatureLength));
699                 {
700                         uint32_t _flags_save_DATA_BLOB = ndr->flags;
701                         ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
702                         NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->ChecksumAndSignature));
703                         ndr->flags = _flags_save_DATA_BLOB;
704                 }
705         }
706         if (ndr_flags & NDR_BUFFERS) {
707         }
708         return NDR_ERR_SUCCESS;
709 }
710
711 _PUBLIC_ void ndr_print_PAC_Validate(struct ndr_print *ndr, const char *name, const struct PAC_Validate *r)
712 {
713         ndr_print_struct(ndr, name, "PAC_Validate");
714         ndr->depth++;
715         ndr_print_uint32(ndr, "MessageType", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?NETLOGON_GENERIC_KRB5_PAC_VALIDATE:r->MessageType);
716         ndr_print_uint32(ndr, "ChecksumLength", r->ChecksumLength);
717         ndr_print_int32(ndr, "SignatureType", r->SignatureType);
718         ndr_print_uint32(ndr, "SignatureLength", r->SignatureLength);
719         ndr_print_DATA_BLOB(ndr, "ChecksumAndSignature", r->ChecksumAndSignature);
720         ndr->depth--;
721 }
722
723 _PUBLIC_ enum ndr_err_code ndr_push_netsamlogoncache_entry(struct ndr_push *ndr, int ndr_flags, const struct netsamlogoncache_entry *r)
724 {
725         if (ndr_flags & NDR_SCALARS) {
726                 NDR_CHECK(ndr_push_align(ndr, 4));
727                 NDR_CHECK(ndr_push_time_t(ndr, NDR_SCALARS, r->timestamp));
728                 NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
729         }
730         if (ndr_flags & NDR_BUFFERS) {
731                 NDR_CHECK(ndr_push_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
732         }
733         return NDR_ERR_SUCCESS;
734 }
735
736 _PUBLIC_ enum ndr_err_code ndr_pull_netsamlogoncache_entry(struct ndr_pull *ndr, int ndr_flags, struct netsamlogoncache_entry *r)
737 {
738         if (ndr_flags & NDR_SCALARS) {
739                 NDR_CHECK(ndr_pull_align(ndr, 4));
740                 NDR_CHECK(ndr_pull_time_t(ndr, NDR_SCALARS, &r->timestamp));
741                 NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_SCALARS, &r->info3));
742         }
743         if (ndr_flags & NDR_BUFFERS) {
744                 NDR_CHECK(ndr_pull_netr_SamInfo3(ndr, NDR_BUFFERS, &r->info3));
745         }
746         return NDR_ERR_SUCCESS;
747 }
748
749 _PUBLIC_ void ndr_print_netsamlogoncache_entry(struct ndr_print *ndr, const char *name, const struct netsamlogoncache_entry *r)
750 {
751         ndr_print_struct(ndr, name, "netsamlogoncache_entry");
752         ndr->depth++;
753         ndr_print_time_t(ndr, "timestamp", r->timestamp);
754         ndr_print_netr_SamInfo3(ndr, "info3", &r->info3);
755         ndr->depth--;
756 }
757
758 static enum ndr_err_code ndr_push_decode_pac(struct ndr_push *ndr, int flags, const struct decode_pac *r)
759 {
760         if (flags & NDR_IN) {
761                 NDR_CHECK(ndr_push_PAC_DATA(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
762         }
763         if (flags & NDR_OUT) {
764         }
765         return NDR_ERR_SUCCESS;
766 }
767
768 static enum ndr_err_code ndr_pull_decode_pac(struct ndr_pull *ndr, int flags, struct decode_pac *r)
769 {
770         if (flags & NDR_IN) {
771                 NDR_CHECK(ndr_pull_PAC_DATA(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
772         }
773         if (flags & NDR_OUT) {
774         }
775         return NDR_ERR_SUCCESS;
776 }
777
778 _PUBLIC_ void ndr_print_decode_pac(struct ndr_print *ndr, const char *name, int flags, const struct decode_pac *r)
779 {
780         ndr_print_struct(ndr, name, "decode_pac");
781         ndr->depth++;
782         if (flags & NDR_SET_VALUES) {
783                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
784         }
785         if (flags & NDR_IN) {
786                 ndr_print_struct(ndr, "in", "decode_pac");
787                 ndr->depth++;
788                 ndr_print_PAC_DATA(ndr, "pac", &r->in.pac);
789                 ndr->depth--;
790         }
791         if (flags & NDR_OUT) {
792                 ndr_print_struct(ndr, "out", "decode_pac");
793                 ndr->depth++;
794                 ndr->depth--;
795         }
796         ndr->depth--;
797 }
798
799 static enum ndr_err_code ndr_push_decode_pac_raw(struct ndr_push *ndr, int flags, const struct decode_pac_raw *r)
800 {
801         if (flags & NDR_IN) {
802                 NDR_CHECK(ndr_push_PAC_DATA_RAW(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
803         }
804         if (flags & NDR_OUT) {
805         }
806         return NDR_ERR_SUCCESS;
807 }
808
809 static enum ndr_err_code ndr_pull_decode_pac_raw(struct ndr_pull *ndr, int flags, struct decode_pac_raw *r)
810 {
811         if (flags & NDR_IN) {
812                 NDR_CHECK(ndr_pull_PAC_DATA_RAW(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.pac));
813         }
814         if (flags & NDR_OUT) {
815         }
816         return NDR_ERR_SUCCESS;
817 }
818
819 _PUBLIC_ void ndr_print_decode_pac_raw(struct ndr_print *ndr, const char *name, int flags, const struct decode_pac_raw *r)
820 {
821         ndr_print_struct(ndr, name, "decode_pac_raw");
822         ndr->depth++;
823         if (flags & NDR_SET_VALUES) {
824                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
825         }
826         if (flags & NDR_IN) {
827                 ndr_print_struct(ndr, "in", "decode_pac_raw");
828                 ndr->depth++;
829                 ndr_print_PAC_DATA_RAW(ndr, "pac", &r->in.pac);
830                 ndr->depth--;
831         }
832         if (flags & NDR_OUT) {
833                 ndr_print_struct(ndr, "out", "decode_pac_raw");
834                 ndr->depth++;
835                 ndr->depth--;
836         }
837         ndr->depth--;
838 }
839
840 static enum ndr_err_code ndr_push_decode_login_info(struct ndr_push *ndr, int flags, const struct decode_login_info *r)
841 {
842         if (flags & NDR_IN) {
843                 NDR_CHECK(ndr_push_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon_info));
844         }
845         if (flags & NDR_OUT) {
846         }
847         return NDR_ERR_SUCCESS;
848 }
849
850 static enum ndr_err_code ndr_pull_decode_login_info(struct ndr_pull *ndr, int flags, struct decode_login_info *r)
851 {
852         if (flags & NDR_IN) {
853                 NDR_CHECK(ndr_pull_PAC_LOGON_INFO(ndr, NDR_SCALARS|NDR_BUFFERS, &r->in.logon_info));
854         }
855         if (flags & NDR_OUT) {
856         }
857         return NDR_ERR_SUCCESS;
858 }
859
860 _PUBLIC_ void ndr_print_decode_login_info(struct ndr_print *ndr, const char *name, int flags, const struct decode_login_info *r)
861 {
862         ndr_print_struct(ndr, name, "decode_login_info");
863         ndr->depth++;
864         if (flags & NDR_SET_VALUES) {
865                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
866         }
867         if (flags & NDR_IN) {
868                 ndr_print_struct(ndr, "in", "decode_login_info");
869                 ndr->depth++;
870                 ndr_print_PAC_LOGON_INFO(ndr, "logon_info", &r->in.logon_info);
871                 ndr->depth--;
872         }
873         if (flags & NDR_OUT) {
874                 ndr_print_struct(ndr, "out", "decode_login_info");
875                 ndr->depth++;
876                 ndr->depth--;
877         }
878         ndr->depth--;
879 }
880
881 static enum ndr_err_code ndr_push_decode_pac_validate(struct ndr_push *ndr, int flags, const struct decode_pac_validate *r)
882 {
883         if (flags & NDR_IN) {
884                 NDR_CHECK(ndr_push_PAC_Validate(ndr, NDR_SCALARS, &r->in.pac_validate));
885         }
886         if (flags & NDR_OUT) {
887         }
888         return NDR_ERR_SUCCESS;
889 }
890
891 static enum ndr_err_code ndr_pull_decode_pac_validate(struct ndr_pull *ndr, int flags, struct decode_pac_validate *r)
892 {
893         if (flags & NDR_IN) {
894                 NDR_CHECK(ndr_pull_PAC_Validate(ndr, NDR_SCALARS, &r->in.pac_validate));
895         }
896         if (flags & NDR_OUT) {
897         }
898         return NDR_ERR_SUCCESS;
899 }
900
901 _PUBLIC_ void ndr_print_decode_pac_validate(struct ndr_print *ndr, const char *name, int flags, const struct decode_pac_validate *r)
902 {
903         ndr_print_struct(ndr, name, "decode_pac_validate");
904         ndr->depth++;
905         if (flags & NDR_SET_VALUES) {
906                 ndr->flags |= LIBNDR_PRINT_SET_VALUES;
907         }
908         if (flags & NDR_IN) {
909                 ndr_print_struct(ndr, "in", "decode_pac_validate");
910                 ndr->depth++;
911                 ndr_print_PAC_Validate(ndr, "pac_validate", &r->in.pac_validate);
912                 ndr->depth--;
913         }
914         if (flags & NDR_OUT) {
915                 ndr_print_struct(ndr, "out", "decode_pac_validate");
916                 ndr->depth++;
917                 ndr->depth--;
918         }
919         ndr->depth--;
920 }
921
922 static const struct ndr_interface_call krb5pac_calls[] = {
923         {
924                 "decode_pac",
925                 sizeof(struct decode_pac),
926                 (ndr_push_flags_fn_t) ndr_push_decode_pac,
927                 (ndr_pull_flags_fn_t) ndr_pull_decode_pac,
928                 (ndr_print_function_t) ndr_print_decode_pac,
929                 false,
930         },
931         {
932                 "decode_pac_raw",
933                 sizeof(struct decode_pac_raw),
934                 (ndr_push_flags_fn_t) ndr_push_decode_pac_raw,
935                 (ndr_pull_flags_fn_t) ndr_pull_decode_pac_raw,
936                 (ndr_print_function_t) ndr_print_decode_pac_raw,
937                 false,
938         },
939         {
940                 "decode_login_info",
941                 sizeof(struct decode_login_info),
942                 (ndr_push_flags_fn_t) ndr_push_decode_login_info,
943                 (ndr_pull_flags_fn_t) ndr_pull_decode_login_info,
944                 (ndr_print_function_t) ndr_print_decode_login_info,
945                 false,
946         },
947         {
948                 "decode_pac_validate",
949                 sizeof(struct decode_pac_validate),
950                 (ndr_push_flags_fn_t) ndr_push_decode_pac_validate,
951                 (ndr_pull_flags_fn_t) ndr_pull_decode_pac_validate,
952                 (ndr_print_function_t) ndr_print_decode_pac_validate,
953                 false,
954         },
955         { NULL, 0, NULL, NULL, NULL, false }
956 };
957
958 static const char * const krb5pac_endpoint_strings[] = {
959         "ncacn_np:[\\pipe\\krb5pac]", 
960 };
961
962 static const struct ndr_interface_string_array krb5pac_endpoints = {
963         .count  = 1,
964         .names  = krb5pac_endpoint_strings
965 };
966
967 static const char * const krb5pac_authservice_strings[] = {
968         "host", 
969 };
970
971 static const struct ndr_interface_string_array krb5pac_authservices = {
972         .count  = 1,
973         .names  = krb5pac_authservice_strings
974 };
975
976
977 const struct ndr_interface_table ndr_table_krb5pac = {
978         .name           = "krb5pac",
979         .syntax_id      = {
980                 {0x12345778,0x1234,0xabcd,{0x00,0x00},{0x00,0x00,0x00,0x00}},
981                 NDR_KRB5PAC_VERSION
982         },
983         .helpstring     = NDR_KRB5PAC_HELPSTRING,
984         .num_calls      = 4,
985         .calls          = krb5pac_calls,
986         .endpoints      = &krb5pac_endpoints,
987         .authservices   = &krb5pac_authservices
988 };
989