Line data Source code
1 : /* parser auto-generated by pidl */
2 :
3 : #include "includes.h"
4 : #include "bin/default/librpc/gen_ndr/ndr_security.h"
5 :
6 : #include "librpc/gen_ndr/ndr_misc.h"
7 0 : static void ndr_print_flags_dom_sid(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct dom_sid *r)
8 : {
9 0 : ndr_print_dom_sid(ndr, name, r);
10 0 : }
11 :
12 7756493 : static enum ndr_err_code ndr_push_se_privilege(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint64_t r)
13 : {
14 7756493 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, r));
15 7742859 : return NDR_ERR_SUCCESS;
16 : }
17 :
18 7606760 : static enum ndr_err_code ndr_pull_se_privilege(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint64_t *r)
19 : {
20 11407 : uint64_t v;
21 7606760 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, &v));
22 7606760 : *r = v;
23 7606760 : return NDR_ERR_SUCCESS;
24 : }
25 :
26 0 : _PUBLIC_ void ndr_print_se_privilege(struct ndr_print *ndr, const char *name, uint64_t r)
27 : {
28 0 : ndr_print_hyper(ndr, name, r);
29 0 : ndr->depth++;
30 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_MACHINE_ACCOUNT_BIT", SEC_PRIV_MACHINE_ACCOUNT_BIT, r);
31 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_PRINT_OPERATOR_BIT", SEC_PRIV_PRINT_OPERATOR_BIT, r);
32 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_ADD_USERS_BIT", SEC_PRIV_ADD_USERS_BIT, r);
33 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_DISK_OPERATOR_BIT", SEC_PRIV_DISK_OPERATOR_BIT, r);
34 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_REMOTE_SHUTDOWN_BIT", SEC_PRIV_REMOTE_SHUTDOWN_BIT, r);
35 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_BACKUP_BIT", SEC_PRIV_BACKUP_BIT, r);
36 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_RESTORE_BIT", SEC_PRIV_RESTORE_BIT, r);
37 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_TAKE_OWNERSHIP_BIT", SEC_PRIV_TAKE_OWNERSHIP_BIT, r);
38 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_INCREASE_QUOTA_BIT", SEC_PRIV_INCREASE_QUOTA_BIT, r);
39 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_SECURITY_BIT", SEC_PRIV_SECURITY_BIT, r);
40 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_LOAD_DRIVER_BIT", SEC_PRIV_LOAD_DRIVER_BIT, r);
41 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_SYSTEM_PROFILE_BIT", SEC_PRIV_SYSTEM_PROFILE_BIT, r);
42 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_SYSTEMTIME_BIT", SEC_PRIV_SYSTEMTIME_BIT, r);
43 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_PROFILE_SINGLE_PROCESS_BIT", SEC_PRIV_PROFILE_SINGLE_PROCESS_BIT, r);
44 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_INCREASE_BASE_PRIORITY_BIT", SEC_PRIV_INCREASE_BASE_PRIORITY_BIT, r);
45 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_CREATE_PAGEFILE_BIT", SEC_PRIV_CREATE_PAGEFILE_BIT, r);
46 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_SHUTDOWN_BIT", SEC_PRIV_SHUTDOWN_BIT, r);
47 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_DEBUG_BIT", SEC_PRIV_DEBUG_BIT, r);
48 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_SYSTEM_ENVIRONMENT_BIT", SEC_PRIV_SYSTEM_ENVIRONMENT_BIT, r);
49 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_CHANGE_NOTIFY_BIT", SEC_PRIV_CHANGE_NOTIFY_BIT, r);
50 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_UNDOCK_BIT", SEC_PRIV_UNDOCK_BIT, r);
51 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_ENABLE_DELEGATION_BIT", SEC_PRIV_ENABLE_DELEGATION_BIT, r);
52 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_MANAGE_VOLUME_BIT", SEC_PRIV_MANAGE_VOLUME_BIT, r);
53 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_IMPERSONATE_BIT", SEC_PRIV_IMPERSONATE_BIT, r);
54 0 : ndr_print_bitmap_flag(ndr, sizeof(uint64_t), "SEC_PRIV_CREATE_GLOBAL_BIT", SEC_PRIV_CREATE_GLOBAL_BIT, r);
55 0 : ndr->depth--;
56 0 : }
57 :
58 7756493 : static enum ndr_err_code ndr_push_lsa_SystemAccessModeFlags(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
59 : {
60 7756493 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
61 7742859 : return NDR_ERR_SUCCESS;
62 : }
63 :
64 7606760 : static enum ndr_err_code ndr_pull_lsa_SystemAccessModeFlags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
65 : {
66 11407 : uint32_t v;
67 7606760 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
68 7606760 : *r = v;
69 7606760 : return NDR_ERR_SUCCESS;
70 : }
71 :
72 0 : _PUBLIC_ void ndr_print_lsa_SystemAccessModeFlags(struct ndr_print *ndr, const char *name, uint32_t r)
73 : {
74 0 : ndr_print_uint32(ndr, name, r);
75 0 : ndr->depth++;
76 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_INTERACTIVE", LSA_POLICY_MODE_INTERACTIVE, r);
77 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_NETWORK", LSA_POLICY_MODE_NETWORK, r);
78 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_BATCH", LSA_POLICY_MODE_BATCH, r);
79 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_SERVICE", LSA_POLICY_MODE_SERVICE, r);
80 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_PROXY", LSA_POLICY_MODE_PROXY, r);
81 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_DENY_INTERACTIVE", LSA_POLICY_MODE_DENY_INTERACTIVE, r);
82 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_DENY_NETWORK", LSA_POLICY_MODE_DENY_NETWORK, r);
83 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_DENY_BATCH", LSA_POLICY_MODE_DENY_BATCH, r);
84 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_DENY_SERVICE", LSA_POLICY_MODE_DENY_SERVICE, r);
85 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_REMOTE_INTERACTIVE", LSA_POLICY_MODE_REMOTE_INTERACTIVE, r);
86 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_DENY_REMOTE_INTERACTIVE", LSA_POLICY_MODE_DENY_REMOTE_INTERACTIVE, r);
87 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_ALL", LSA_POLICY_MODE_ALL, r);
88 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "LSA_POLICY_MODE_ALL_NT4", LSA_POLICY_MODE_ALL_NT4, r);
89 0 : ndr->depth--;
90 0 : }
91 :
92 38383742 : _PUBLIC_ enum ndr_err_code ndr_push_security_ace_flags(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint8_t r)
93 : {
94 38383742 : NDR_CHECK(ndr_push_uint8(ndr, NDR_SCALARS, r));
95 36840263 : return NDR_ERR_SUCCESS;
96 : }
97 :
98 180736709 : _PUBLIC_ enum ndr_err_code ndr_pull_security_ace_flags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint8_t *r)
99 : {
100 6468866 : uint8_t v;
101 180736709 : NDR_CHECK(ndr_pull_uint8(ndr, NDR_SCALARS, &v));
102 180736709 : *r = v;
103 180736709 : return NDR_ERR_SUCCESS;
104 : }
105 :
106 4458 : _PUBLIC_ void ndr_print_security_ace_flags(struct ndr_print *ndr, const char *name, uint8_t r)
107 : {
108 4458 : ndr_print_uint8(ndr, name, r);
109 4458 : ndr->depth++;
110 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_OBJECT_INHERIT", SEC_ACE_FLAG_OBJECT_INHERIT, r);
111 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_CONTAINER_INHERIT", SEC_ACE_FLAG_CONTAINER_INHERIT, r);
112 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_NO_PROPAGATE_INHERIT", SEC_ACE_FLAG_NO_PROPAGATE_INHERIT, r);
113 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_INHERIT_ONLY", SEC_ACE_FLAG_INHERIT_ONLY, r);
114 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_INHERITED_ACE", SEC_ACE_FLAG_INHERITED_ACE, r);
115 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_VALID_INHERIT", SEC_ACE_FLAG_VALID_INHERIT, r);
116 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_SUCCESSFUL_ACCESS", SEC_ACE_FLAG_SUCCESSFUL_ACCESS, r);
117 4458 : ndr_print_bitmap_flag(ndr, sizeof(uint8_t), "SEC_ACE_FLAG_FAILED_ACCESS", SEC_ACE_FLAG_FAILED_ACCESS, r);
118 4458 : ndr->depth--;
119 4458 : }
120 :
121 38383742 : _PUBLIC_ enum ndr_err_code ndr_push_security_ace_type(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum security_ace_type r)
122 : {
123 38383742 : NDR_CHECK(ndr_push_enum_uint8(ndr, NDR_SCALARS, r));
124 36840263 : return NDR_ERR_SUCCESS;
125 : }
126 :
127 180736709 : _PUBLIC_ enum ndr_err_code ndr_pull_security_ace_type(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum security_ace_type *r)
128 : {
129 6468866 : uint8_t v;
130 180736709 : NDR_CHECK(ndr_pull_enum_uint8(ndr, NDR_SCALARS, &v));
131 180736709 : *r = v;
132 180736709 : return NDR_ERR_SUCCESS;
133 : }
134 :
135 4458 : _PUBLIC_ void ndr_print_security_ace_type(struct ndr_print *ndr, const char *name, enum security_ace_type r)
136 : {
137 4458 : const char *val = NULL;
138 :
139 4458 : switch (r) {
140 4458 : case SEC_ACE_TYPE_ACCESS_ALLOWED: val = "SEC_ACE_TYPE_ACCESS_ALLOWED"; break;
141 0 : case SEC_ACE_TYPE_ACCESS_DENIED: val = "SEC_ACE_TYPE_ACCESS_DENIED"; break;
142 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT: val = "SEC_ACE_TYPE_SYSTEM_AUDIT"; break;
143 0 : case SEC_ACE_TYPE_SYSTEM_ALARM: val = "SEC_ACE_TYPE_SYSTEM_ALARM"; break;
144 0 : case SEC_ACE_TYPE_ALLOWED_COMPOUND: val = "SEC_ACE_TYPE_ALLOWED_COMPOUND"; break;
145 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_OBJECT: val = "SEC_ACE_TYPE_ACCESS_ALLOWED_OBJECT"; break;
146 0 : case SEC_ACE_TYPE_ACCESS_DENIED_OBJECT: val = "SEC_ACE_TYPE_ACCESS_DENIED_OBJECT"; break;
147 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_OBJECT: val = "SEC_ACE_TYPE_SYSTEM_AUDIT_OBJECT"; break;
148 0 : case SEC_ACE_TYPE_SYSTEM_ALARM_OBJECT: val = "SEC_ACE_TYPE_SYSTEM_ALARM_OBJECT"; break;
149 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK: val = "SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK"; break;
150 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK: val = "SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK"; break;
151 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK_OBJECT: val = "SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK_OBJECT"; break;
152 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK_OBJECT: val = "SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK_OBJECT"; break;
153 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK: val = "SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK"; break;
154 0 : case SEC_ACE_TYPE_SYSTEM_ALARM_CALLBACK: val = "SEC_ACE_TYPE_SYSTEM_ALARM_CALLBACK"; break;
155 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK_OBJECT: val = "SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK_OBJECT"; break;
156 0 : case SEC_ACE_TYPE_SYSTEM_ALARM_CALLBACK_OBJECT: val = "SEC_ACE_TYPE_SYSTEM_ALARM_CALLBACK_OBJECT"; break;
157 0 : case SEC_ACE_TYPE_SYSTEM_MANDATORY_LABEL: val = "SEC_ACE_TYPE_SYSTEM_MANDATORY_LABEL"; break;
158 0 : case SEC_ACE_TYPE_SYSTEM_RESOURCE_ATTRIBUTE: val = "SEC_ACE_TYPE_SYSTEM_RESOURCE_ATTRIBUTE"; break;
159 0 : case SEC_ACE_TYPE_SYSTEM_SCOPED_POLICY_ID: val = "SEC_ACE_TYPE_SYSTEM_SCOPED_POLICY_ID"; break;
160 : }
161 4458 : ndr_print_enum(ndr, name, "ENUM", val, r);
162 4458 : }
163 :
164 21739777 : static enum ndr_err_code ndr_push_security_ace_object_flags(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
165 : {
166 21739777 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
167 21200740 : return NDR_ERR_SUCCESS;
168 : }
169 :
170 122757998 : static enum ndr_err_code ndr_pull_security_ace_object_flags(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
171 : {
172 3429124 : uint32_t v;
173 122757998 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
174 122757998 : *r = v;
175 122757998 : return NDR_ERR_SUCCESS;
176 : }
177 :
178 0 : _PUBLIC_ void ndr_print_security_ace_object_flags(struct ndr_print *ndr, const char *name, uint32_t r)
179 : {
180 0 : ndr_print_uint32(ndr, name, r);
181 0 : ndr->depth++;
182 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SEC_ACE_OBJECT_TYPE_PRESENT", SEC_ACE_OBJECT_TYPE_PRESENT, r);
183 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT", SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT, r);
184 0 : ndr->depth--;
185 0 : }
186 :
187 42940517 : static enum ndr_err_code ndr_push_security_ace_object_type(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union security_ace_object_type *r)
188 : {
189 539037 : uint32_t level;
190 42940517 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
191 42940517 : if (ndr_flags & NDR_SCALARS) {
192 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
193 21739777 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
194 21739777 : NDR_CHECK(ndr_push_union_align(ndr, 4));
195 21739777 : switch (level) {
196 19715041 : case SEC_ACE_OBJECT_TYPE_PRESENT: {
197 19715041 : NDR_CHECK(ndr_push_GUID(ndr, NDR_SCALARS, &r->type));
198 19237860 : break; }
199 :
200 1962880 : default: {
201 1962880 : break; }
202 :
203 : }
204 : }
205 42401480 : return NDR_ERR_SUCCESS;
206 : }
207 :
208 245515996 : static enum ndr_err_code ndr_pull_security_ace_object_type(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union security_ace_object_type *r)
209 : {
210 6858248 : uint32_t level;
211 245515996 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
212 245515996 : if (ndr_flags & NDR_SCALARS) {
213 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
214 122757998 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
215 122757998 : NDR_CHECK(ndr_pull_union_align(ndr, 4));
216 122757998 : switch (level) {
217 113618948 : case SEC_ACE_OBJECT_TYPE_PRESENT: {
218 113618948 : NDR_CHECK(ndr_pull_GUID(ndr, NDR_SCALARS, &r->type));
219 110361796 : break; }
220 :
221 8967078 : default: {
222 8967078 : break; }
223 :
224 : }
225 : }
226 238657748 : return NDR_ERR_SUCCESS;
227 : }
228 :
229 0 : _PUBLIC_ void ndr_print_security_ace_object_type(struct ndr_print *ndr, const char *name, const union security_ace_object_type *r)
230 : {
231 0 : uint32_t level;
232 0 : level = ndr_print_steal_switch_value(ndr, r);
233 0 : ndr_print_union(ndr, name, level, "security_ace_object_type");
234 0 : switch (level) {
235 0 : case SEC_ACE_OBJECT_TYPE_PRESENT:
236 0 : ndr_print_GUID(ndr, "type", &r->type);
237 0 : break;
238 :
239 0 : default:
240 0 : break;
241 :
242 : }
243 0 : }
244 :
245 42940517 : static enum ndr_err_code ndr_push_security_ace_object_inherited_type(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union security_ace_object_inherited_type *r)
246 : {
247 539037 : uint32_t level;
248 42940517 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
249 42940517 : if (ndr_flags & NDR_SCALARS) {
250 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
251 21739777 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
252 21739777 : NDR_CHECK(ndr_push_union_align(ndr, 4));
253 21739777 : switch (level) {
254 14304982 : case SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT: {
255 14304982 : NDR_CHECK(ndr_push_GUID(ndr, NDR_SCALARS, &r->inherited_type));
256 13881408 : break; }
257 :
258 7319332 : default: {
259 7319332 : break; }
260 :
261 : }
262 : }
263 42401480 : return NDR_ERR_SUCCESS;
264 : }
265 :
266 245515996 : static enum ndr_err_code ndr_pull_security_ace_object_inherited_type(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union security_ace_object_inherited_type *r)
267 : {
268 6858248 : uint32_t level;
269 245515996 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
270 245515996 : if (ndr_flags & NDR_SCALARS) {
271 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
272 122757998 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
273 122757998 : NDR_CHECK(ndr_pull_union_align(ndr, 4));
274 122757998 : switch (level) {
275 64762574 : case SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT: {
276 64762574 : NDR_CHECK(ndr_pull_GUID(ndr, NDR_SCALARS, &r->inherited_type));
277 63587804 : break; }
278 :
279 55741070 : default: {
280 55741070 : break; }
281 :
282 : }
283 : }
284 238657748 : return NDR_ERR_SUCCESS;
285 : }
286 :
287 0 : _PUBLIC_ void ndr_print_security_ace_object_inherited_type(struct ndr_print *ndr, const char *name, const union security_ace_object_inherited_type *r)
288 : {
289 0 : uint32_t level;
290 0 : level = ndr_print_steal_switch_value(ndr, r);
291 0 : ndr_print_union(ndr, name, level, "security_ace_object_inherited_type");
292 0 : switch (level) {
293 0 : case SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT:
294 0 : ndr_print_GUID(ndr, "inherited_type", &r->inherited_type);
295 0 : break;
296 :
297 0 : default:
298 0 : break;
299 :
300 : }
301 0 : }
302 :
303 43479554 : static enum ndr_err_code ndr_push_security_ace_object(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_ace_object *r)
304 : {
305 43479554 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
306 43479554 : if (ndr_flags & NDR_SCALARS) {
307 21739777 : NDR_CHECK(ndr_push_align(ndr, 4));
308 22278814 : NDR_CHECK(ndr_push_security_ace_object_flags(ndr, NDR_SCALARS, r->flags));
309 21739777 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->type, r->flags & SEC_ACE_OBJECT_TYPE_PRESENT));
310 21739777 : NDR_CHECK(ndr_push_security_ace_object_type(ndr, NDR_SCALARS, &r->type));
311 21739777 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->inherited_type, r->flags & SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT));
312 21739777 : NDR_CHECK(ndr_push_security_ace_object_inherited_type(ndr, NDR_SCALARS, &r->inherited_type));
313 21739777 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
314 : }
315 43479554 : if (ndr_flags & NDR_BUFFERS) {
316 21739777 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->type, r->flags & SEC_ACE_OBJECT_TYPE_PRESENT));
317 21739777 : NDR_CHECK(ndr_push_security_ace_object_type(ndr, NDR_BUFFERS, &r->type));
318 21739777 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->inherited_type, r->flags & SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT));
319 21200740 : NDR_CHECK(ndr_push_security_ace_object_inherited_type(ndr, NDR_BUFFERS, &r->inherited_type));
320 : }
321 42401480 : return NDR_ERR_SUCCESS;
322 : }
323 :
324 245515996 : static enum ndr_err_code ndr_pull_security_ace_object(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_ace_object *r)
325 : {
326 245515996 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
327 245515996 : if (ndr_flags & NDR_SCALARS) {
328 122757998 : NDR_CHECK(ndr_pull_align(ndr, 4));
329 126187122 : NDR_CHECK(ndr_pull_security_ace_object_flags(ndr, NDR_SCALARS, &r->flags));
330 122757998 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->type, r->flags & SEC_ACE_OBJECT_TYPE_PRESENT));
331 122757998 : NDR_CHECK(ndr_pull_security_ace_object_type(ndr, NDR_SCALARS, &r->type));
332 122757998 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->inherited_type, r->flags & SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT));
333 122757998 : NDR_CHECK(ndr_pull_security_ace_object_inherited_type(ndr, NDR_SCALARS, &r->inherited_type));
334 122757998 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
335 : }
336 245515996 : if (ndr_flags & NDR_BUFFERS) {
337 122757998 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->type, r->flags & SEC_ACE_OBJECT_TYPE_PRESENT));
338 122757998 : NDR_CHECK(ndr_pull_security_ace_object_type(ndr, NDR_BUFFERS, &r->type));
339 122757998 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->inherited_type, r->flags & SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT));
340 122757998 : NDR_CHECK(ndr_pull_security_ace_object_inherited_type(ndr, NDR_BUFFERS, &r->inherited_type));
341 : }
342 238657748 : return NDR_ERR_SUCCESS;
343 : }
344 :
345 0 : _PUBLIC_ void ndr_print_security_ace_object(struct ndr_print *ndr, const char *name, const struct security_ace_object *r)
346 : {
347 0 : ndr_print_struct(ndr, name, "security_ace_object");
348 0 : if (r == NULL) { ndr_print_null(ndr); return; }
349 0 : ndr->depth++;
350 0 : ndr_print_security_ace_object_flags(ndr, "flags", r->flags);
351 0 : ndr_print_set_switch_value(ndr, &r->type, r->flags & SEC_ACE_OBJECT_TYPE_PRESENT);
352 0 : ndr_print_security_ace_object_type(ndr, "type", &r->type);
353 0 : ndr_print_set_switch_value(ndr, &r->inherited_type, r->flags & SEC_ACE_INHERITED_OBJECT_TYPE_PRESENT);
354 0 : ndr_print_security_ace_object_inherited_type(ndr, "inherited_type", &r->inherited_type);
355 0 : ndr->depth--;
356 : }
357 :
358 0 : _PUBLIC_ enum ndr_err_code ndr_push_security_claim_value_type(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum security_claim_value_type r)
359 : {
360 0 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
361 0 : return NDR_ERR_SUCCESS;
362 : }
363 :
364 0 : _PUBLIC_ enum ndr_err_code ndr_pull_security_claim_value_type(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum security_claim_value_type *r)
365 : {
366 0 : uint16_t v;
367 0 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
368 0 : *r = v;
369 0 : return NDR_ERR_SUCCESS;
370 : }
371 :
372 0 : _PUBLIC_ void ndr_print_security_claim_value_type(struct ndr_print *ndr, const char *name, enum security_claim_value_type r)
373 : {
374 0 : const char *val = NULL;
375 :
376 0 : switch (r) {
377 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_INT64: val = "CLAIM_SECURITY_ATTRIBUTE_TYPE_INT64"; break;
378 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_UINT64: val = "CLAIM_SECURITY_ATTRIBUTE_TYPE_UINT64"; break;
379 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_STRING: val = "CLAIM_SECURITY_ATTRIBUTE_TYPE_STRING"; break;
380 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_SID: val = "CLAIM_SECURITY_ATTRIBUTE_TYPE_SID"; break;
381 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_BOOLEAN: val = "CLAIM_SECURITY_ATTRIBUTE_TYPE_BOOLEAN"; break;
382 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_OCTET_STRING: val = "CLAIM_SECURITY_ATTRIBUTE_TYPE_OCTET_STRING"; break;
383 : }
384 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
385 0 : }
386 :
387 17362 : static enum ndr_err_code ndr_push_claim_values(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union claim_values *r)
388 : {
389 17362 : uint32_t level;
390 : {
391 17362 : libndr_flags _flags_save_UNION = ndr->flags;
392 17362 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_NOALIGN);
393 17362 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
394 17362 : if (ndr_flags & NDR_SCALARS) {
395 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
396 8681 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
397 8681 : NDR_CHECK(ndr_push_union_align(ndr, 5));
398 8681 : switch (level) {
399 512 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_INT64: {
400 512 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->int_value));
401 0 : break; }
402 :
403 1401 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_UINT64: {
404 1401 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->uint_value));
405 0 : break; }
406 :
407 4849 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_STRING: {
408 : {
409 4849 : libndr_flags _flags_save_string = ndr->flags;
410 4849 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
411 4849 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->string_value));
412 4849 : ndr->flags = _flags_save_string;
413 : }
414 4849 : break; }
415 :
416 11 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_SID: {
417 11 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->sid_value));
418 0 : break; }
419 :
420 1908 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_OCTET_STRING: {
421 1908 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->octet_value));
422 0 : break; }
423 :
424 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_BOOLEAN: {
425 0 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->uint_value));
426 0 : break; }
427 :
428 0 : default:
429 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
430 : }
431 : }
432 17362 : if (ndr_flags & NDR_BUFFERS) {
433 8681 : if (!(ndr_flags & NDR_SCALARS)) {
434 : /* We didn't get it above, and the token is not needed after this. */
435 8681 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
436 : }
437 8681 : switch (level) {
438 512 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_INT64:
439 512 : if (r->int_value) {
440 512 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->int_value));
441 512 : NDR_CHECK(ndr_push_int64(ndr, NDR_SCALARS, *r->int_value));
442 512 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->int_value));
443 : }
444 0 : break;
445 :
446 1401 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_UINT64:
447 1401 : if (r->uint_value) {
448 1401 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->uint_value));
449 1401 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, *r->uint_value));
450 1401 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->uint_value));
451 : }
452 0 : break;
453 :
454 4849 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_STRING:
455 : {
456 4849 : libndr_flags _flags_save_string = ndr->flags;
457 4849 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
458 4849 : if (r->string_value) {
459 4849 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->string_value));
460 4849 : NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->string_value));
461 4849 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->string_value));
462 : }
463 4849 : ndr->flags = _flags_save_string;
464 : }
465 4849 : break;
466 :
467 11 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_SID:
468 11 : if (r->sid_value) {
469 11 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->sid_value));
470 11 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, *r->sid_value));
471 11 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->sid_value));
472 : }
473 0 : break;
474 :
475 1908 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_OCTET_STRING:
476 1908 : if (r->octet_value) {
477 1908 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->octet_value));
478 1908 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, *r->octet_value));
479 1908 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->octet_value));
480 : }
481 0 : break;
482 :
483 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_BOOLEAN:
484 0 : if (r->uint_value) {
485 0 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->uint_value));
486 0 : NDR_CHECK(ndr_push_hyper(ndr, NDR_SCALARS, *r->uint_value));
487 0 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->uint_value));
488 : }
489 0 : break;
490 :
491 0 : default:
492 0 : return ndr_push_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32, level);
493 : }
494 : }
495 17362 : ndr->flags = _flags_save_UNION;
496 : }
497 17362 : return NDR_ERR_SUCCESS;
498 : }
499 :
500 11616 : static enum ndr_err_code ndr_pull_claim_values(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union claim_values *r)
501 : {
502 11616 : uint32_t level;
503 11616 : TALLOC_CTX *_mem_save_int_value_0 = NULL;
504 11616 : uint32_t _ptr_int_value;
505 11616 : TALLOC_CTX *_mem_save_uint_value_0 = NULL;
506 11616 : uint32_t _ptr_uint_value;
507 11616 : TALLOC_CTX *_mem_save_string_value_0 = NULL;
508 11616 : uint32_t _ptr_string_value;
509 11616 : TALLOC_CTX *_mem_save_sid_value_0 = NULL;
510 11616 : uint32_t _ptr_sid_value;
511 11616 : TALLOC_CTX *_mem_save_octet_value_0 = NULL;
512 11616 : uint32_t _ptr_octet_value;
513 : {
514 11616 : libndr_flags _flags_save_UNION = ndr->flags;
515 11616 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_NOALIGN);
516 11616 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
517 11616 : if (ndr_flags & NDR_SCALARS) {
518 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
519 5808 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
520 5808 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
521 5808 : switch (level) {
522 128 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_INT64: {
523 128 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_int_value));
524 128 : if (_ptr_int_value) {
525 128 : NDR_PULL_ALLOC(ndr, r->int_value);
526 128 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->int_value, _ptr_int_value));
527 : } else {
528 0 : r->int_value = NULL;
529 : }
530 0 : break; }
531 :
532 350 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_UINT64: {
533 350 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_uint_value));
534 350 : if (_ptr_uint_value) {
535 350 : NDR_PULL_ALLOC(ndr, r->uint_value);
536 350 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->uint_value, _ptr_uint_value));
537 : } else {
538 0 : r->uint_value = NULL;
539 : }
540 0 : break; }
541 :
542 4798 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_STRING: {
543 : {
544 4798 : libndr_flags _flags_save_string = ndr->flags;
545 4798 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
546 4798 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_string_value));
547 4798 : if (_ptr_string_value) {
548 4798 : NDR_PULL_ALLOC(ndr, r->string_value);
549 4798 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->string_value, _ptr_string_value));
550 : } else {
551 0 : r->string_value = NULL;
552 : }
553 4798 : ndr->flags = _flags_save_string;
554 : }
555 4798 : break; }
556 :
557 11 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_SID: {
558 11 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sid_value));
559 11 : if (_ptr_sid_value) {
560 11 : NDR_PULL_ALLOC(ndr, r->sid_value);
561 11 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->sid_value, _ptr_sid_value));
562 : } else {
563 0 : r->sid_value = NULL;
564 : }
565 0 : break; }
566 :
567 521 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_OCTET_STRING: {
568 521 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_octet_value));
569 521 : if (_ptr_octet_value) {
570 521 : NDR_PULL_ALLOC(ndr, r->octet_value);
571 521 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->octet_value, _ptr_octet_value));
572 : } else {
573 0 : r->octet_value = NULL;
574 : }
575 0 : break; }
576 :
577 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_BOOLEAN: {
578 0 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_uint_value));
579 0 : if (_ptr_uint_value) {
580 0 : NDR_PULL_ALLOC(ndr, r->uint_value);
581 0 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->uint_value, _ptr_uint_value));
582 : } else {
583 0 : r->uint_value = NULL;
584 : }
585 0 : break; }
586 :
587 0 : default:
588 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
589 : }
590 : }
591 11616 : if (ndr_flags & NDR_BUFFERS) {
592 5808 : if (!(ndr_flags & NDR_SCALARS)) {
593 : /* We didn't get it above, and the token is not needed after this. */
594 5808 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
595 : }
596 5808 : switch (level) {
597 128 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_INT64:
598 128 : if (r->int_value) {
599 128 : uint32_t _relative_save_offset;
600 128 : _relative_save_offset = ndr->offset;
601 128 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->int_value));
602 128 : _mem_save_int_value_0 = NDR_PULL_GET_MEM_CTX(ndr);
603 128 : NDR_PULL_SET_MEM_CTX(ndr, r->int_value, 0);
604 128 : NDR_CHECK(ndr_pull_int64(ndr, NDR_SCALARS, r->int_value));
605 128 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_int_value_0, 0);
606 128 : if (ndr->offset > ndr->relative_highest_offset) {
607 128 : ndr->relative_highest_offset = ndr->offset;
608 : }
609 128 : ndr->offset = _relative_save_offset;
610 : }
611 0 : break;
612 :
613 350 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_UINT64:
614 350 : if (r->uint_value) {
615 350 : uint32_t _relative_save_offset;
616 350 : _relative_save_offset = ndr->offset;
617 350 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->uint_value));
618 350 : _mem_save_uint_value_0 = NDR_PULL_GET_MEM_CTX(ndr);
619 350 : NDR_PULL_SET_MEM_CTX(ndr, r->uint_value, 0);
620 350 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, r->uint_value));
621 350 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_uint_value_0, 0);
622 350 : if (ndr->offset > ndr->relative_highest_offset) {
623 350 : ndr->relative_highest_offset = ndr->offset;
624 : }
625 350 : ndr->offset = _relative_save_offset;
626 : }
627 0 : break;
628 :
629 4798 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_STRING:
630 : {
631 4798 : libndr_flags _flags_save_string = ndr->flags;
632 4798 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
633 4798 : if (r->string_value) {
634 4798 : uint32_t _relative_save_offset;
635 4798 : _relative_save_offset = ndr->offset;
636 4798 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->string_value));
637 4798 : _mem_save_string_value_0 = NDR_PULL_GET_MEM_CTX(ndr);
638 4798 : NDR_PULL_SET_MEM_CTX(ndr, r->string_value, 0);
639 4798 : NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->string_value));
640 4798 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_string_value_0, 0);
641 4798 : if (ndr->offset > ndr->relative_highest_offset) {
642 4798 : ndr->relative_highest_offset = ndr->offset;
643 : }
644 4798 : ndr->offset = _relative_save_offset;
645 : }
646 4798 : ndr->flags = _flags_save_string;
647 : }
648 4798 : break;
649 :
650 11 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_SID:
651 11 : if (r->sid_value) {
652 11 : uint32_t _relative_save_offset;
653 11 : _relative_save_offset = ndr->offset;
654 11 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->sid_value));
655 11 : _mem_save_sid_value_0 = NDR_PULL_GET_MEM_CTX(ndr);
656 11 : NDR_PULL_SET_MEM_CTX(ndr, r->sid_value, 0);
657 11 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, r->sid_value));
658 11 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sid_value_0, 0);
659 11 : if (ndr->offset > ndr->relative_highest_offset) {
660 11 : ndr->relative_highest_offset = ndr->offset;
661 : }
662 11 : ndr->offset = _relative_save_offset;
663 : }
664 0 : break;
665 :
666 521 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_OCTET_STRING:
667 521 : if (r->octet_value) {
668 521 : uint32_t _relative_save_offset;
669 521 : _relative_save_offset = ndr->offset;
670 521 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->octet_value));
671 521 : _mem_save_octet_value_0 = NDR_PULL_GET_MEM_CTX(ndr);
672 521 : NDR_PULL_SET_MEM_CTX(ndr, r->octet_value, 0);
673 521 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, r->octet_value));
674 521 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_octet_value_0, 0);
675 521 : if (ndr->offset > ndr->relative_highest_offset) {
676 521 : ndr->relative_highest_offset = ndr->offset;
677 : }
678 521 : ndr->offset = _relative_save_offset;
679 : }
680 0 : break;
681 :
682 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_BOOLEAN:
683 0 : if (r->uint_value) {
684 0 : uint32_t _relative_save_offset;
685 0 : _relative_save_offset = ndr->offset;
686 0 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->uint_value));
687 0 : _mem_save_uint_value_0 = NDR_PULL_GET_MEM_CTX(ndr);
688 0 : NDR_PULL_SET_MEM_CTX(ndr, r->uint_value, 0);
689 0 : NDR_CHECK(ndr_pull_hyper(ndr, NDR_SCALARS, r->uint_value));
690 0 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_uint_value_0, 0);
691 0 : if (ndr->offset > ndr->relative_highest_offset) {
692 0 : ndr->relative_highest_offset = ndr->offset;
693 : }
694 0 : ndr->offset = _relative_save_offset;
695 : }
696 0 : break;
697 :
698 0 : default:
699 0 : return ndr_pull_error(ndr, NDR_ERR_BAD_SWITCH, "Bad switch value %"PRIu32" at %s", level, __location__);
700 : }
701 : }
702 11616 : ndr->flags = _flags_save_UNION;
703 : }
704 11616 : return NDR_ERR_SUCCESS;
705 : }
706 :
707 0 : _PUBLIC_ void ndr_print_claim_values(struct ndr_print *ndr, const char *name, const union claim_values *r)
708 : {
709 0 : uint32_t level;
710 : {
711 0 : libndr_flags _flags_save_UNION = ndr->flags;
712 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_NOALIGN);
713 0 : level = ndr_print_steal_switch_value(ndr, r);
714 0 : ndr_print_union(ndr, name, level, "claim_values");
715 0 : switch (level) {
716 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_INT64:
717 0 : ndr_print_ptr(ndr, "int_value", r->int_value);
718 0 : ndr->depth++;
719 0 : if (r->int_value) {
720 0 : ndr_print_int64(ndr, "int_value", *r->int_value);
721 : }
722 0 : ndr->depth--;
723 0 : break;
724 :
725 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_UINT64:
726 0 : ndr_print_ptr(ndr, "uint_value", r->uint_value);
727 0 : ndr->depth++;
728 0 : if (r->uint_value) {
729 0 : ndr_print_hyper(ndr, "uint_value", *r->uint_value);
730 : }
731 0 : ndr->depth--;
732 0 : break;
733 :
734 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_STRING:
735 : {
736 0 : libndr_flags _flags_save_string = ndr->flags;
737 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
738 0 : ndr_print_ptr(ndr, "string_value", r->string_value);
739 0 : ndr->depth++;
740 0 : if (r->string_value) {
741 0 : ndr_print_string(ndr, "string_value", r->string_value);
742 : }
743 0 : ndr->depth--;
744 0 : ndr->flags = _flags_save_string;
745 : }
746 0 : break;
747 :
748 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_SID:
749 0 : ndr_print_ptr(ndr, "sid_value", r->sid_value);
750 0 : ndr->depth++;
751 0 : if (r->sid_value) {
752 0 : ndr_print_DATA_BLOB(ndr, "sid_value", *r->sid_value);
753 : }
754 0 : ndr->depth--;
755 0 : break;
756 :
757 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_OCTET_STRING:
758 0 : ndr_print_ptr(ndr, "octet_value", r->octet_value);
759 0 : ndr->depth++;
760 0 : if (r->octet_value) {
761 0 : ndr_print_DATA_BLOB(ndr, "octet_value", *r->octet_value);
762 : }
763 0 : ndr->depth--;
764 0 : break;
765 :
766 0 : case CLAIM_SECURITY_ATTRIBUTE_TYPE_BOOLEAN:
767 0 : ndr_print_ptr(ndr, "uint_value", r->uint_value);
768 0 : ndr->depth++;
769 0 : if (r->uint_value) {
770 0 : ndr_print_hyper(ndr, "uint_value", *r->uint_value);
771 : }
772 0 : ndr->depth--;
773 0 : break;
774 :
775 0 : default:
776 0 : ndr_print_bad_level(ndr, name, level);
777 : }
778 0 : ndr->flags = _flags_save_UNION;
779 : }
780 0 : }
781 :
782 718 : _PUBLIC_ enum ndr_err_code ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1 *r)
783 : {
784 718 : uint32_t cntr_values_0;
785 718 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
786 718 : if (ndr_flags & NDR_SCALARS) {
787 410 : NDR_CHECK(ndr_push_align(ndr, 5));
788 : {
789 410 : libndr_flags _flags_save_string = ndr->flags;
790 410 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
791 410 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->name));
792 410 : ndr->flags = _flags_save_string;
793 : }
794 410 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->value_type));
795 410 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->flags));
796 410 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->value_count));
797 9091 : for (cntr_values_0 = 0; cntr_values_0 < (r->value_count); cntr_values_0++) {
798 8681 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->values[cntr_values_0], r->value_type));
799 8681 : NDR_CHECK(ndr_push_claim_values(ndr, NDR_SCALARS, &r->values[cntr_values_0]));
800 : }
801 410 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
802 : }
803 718 : if (ndr_flags & NDR_BUFFERS) {
804 : {
805 410 : libndr_flags _flags_save_string = ndr->flags;
806 410 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
807 410 : if (r->name) {
808 410 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->name));
809 410 : NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->name));
810 410 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->name));
811 : }
812 410 : ndr->flags = _flags_save_string;
813 : }
814 9091 : for (cntr_values_0 = 0; cntr_values_0 < (r->value_count); cntr_values_0++) {
815 8681 : NDR_CHECK(ndr_push_set_switch_value(ndr, &r->values[cntr_values_0], r->value_type));
816 8681 : NDR_CHECK(ndr_push_claim_values(ndr, NDR_BUFFERS, &r->values[cntr_values_0]));
817 : }
818 : }
819 0 : return NDR_ERR_SUCCESS;
820 : }
821 :
822 258 : _PUBLIC_ enum ndr_err_code ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1 *r)
823 : {
824 258 : uint32_t _ptr_name;
825 258 : TALLOC_CTX *_mem_save_name_0 = NULL;
826 258 : uint32_t size_values_0 = 0;
827 258 : uint32_t cntr_values_0;
828 258 : TALLOC_CTX *_mem_save_values_0 = NULL;
829 258 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
830 258 : if (ndr_flags & NDR_SCALARS) {
831 180 : NDR_CHECK(ndr_pull_align(ndr, 5));
832 : {
833 180 : libndr_flags _flags_save_string = ndr->flags;
834 180 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
835 180 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_name));
836 180 : if (_ptr_name) {
837 180 : NDR_PULL_ALLOC(ndr, r->name);
838 180 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->name, _ptr_name));
839 : } else {
840 0 : r->name = NULL;
841 : }
842 180 : ndr->flags = _flags_save_string;
843 : }
844 180 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->value_type));
845 180 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->flags));
846 180 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->value_count));
847 180 : size_values_0 = r->value_count;
848 180 : NDR_PULL_ALLOC_N(ndr, r->values, size_values_0);
849 180 : _mem_save_values_0 = NDR_PULL_GET_MEM_CTX(ndr);
850 180 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
851 5988 : for (cntr_values_0 = 0; cntr_values_0 < (size_values_0); cntr_values_0++) {
852 5808 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->values[cntr_values_0], r->value_type));
853 5808 : NDR_CHECK(ndr_pull_claim_values(ndr, NDR_SCALARS, &r->values[cntr_values_0]));
854 : }
855 180 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_0, 0);
856 180 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
857 : }
858 258 : if (ndr_flags & NDR_BUFFERS) {
859 : {
860 180 : libndr_flags _flags_save_string = ndr->flags;
861 180 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
862 180 : if (r->name) {
863 180 : uint32_t _relative_save_offset;
864 180 : _relative_save_offset = ndr->offset;
865 180 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->name));
866 180 : _mem_save_name_0 = NDR_PULL_GET_MEM_CTX(ndr);
867 180 : NDR_PULL_SET_MEM_CTX(ndr, r->name, 0);
868 180 : NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->name));
869 180 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_name_0, 0);
870 180 : if (ndr->offset > ndr->relative_highest_offset) {
871 180 : ndr->relative_highest_offset = ndr->offset;
872 : }
873 180 : ndr->offset = _relative_save_offset;
874 : }
875 180 : ndr->flags = _flags_save_string;
876 : }
877 180 : size_values_0 = r->value_count;
878 180 : _mem_save_values_0 = NDR_PULL_GET_MEM_CTX(ndr);
879 180 : NDR_PULL_SET_MEM_CTX(ndr, r->values, 0);
880 5988 : for (cntr_values_0 = 0; cntr_values_0 < (size_values_0); cntr_values_0++) {
881 5808 : NDR_CHECK(ndr_pull_set_switch_value(ndr, &r->values[cntr_values_0], r->value_type));
882 5808 : NDR_CHECK(ndr_pull_claim_values(ndr, NDR_BUFFERS, &r->values[cntr_values_0]));
883 : }
884 180 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_values_0, 0);
885 180 : for (cntr_values_0 = 0; cntr_values_0 < (size_values_0); cntr_values_0++) {
886 : }
887 : }
888 0 : return NDR_ERR_SUCCESS;
889 : }
890 :
891 0 : static void ndr_print_flags_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1 *r)
892 : {
893 0 : ndr_print_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, name, r);
894 0 : }
895 :
896 0 : _PUBLIC_ void ndr_print_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(struct ndr_print *ndr, const char *name, const struct CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1 *r)
897 : {
898 0 : uint32_t cntr_values_0;
899 0 : ndr_print_struct(ndr, name, "CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1");
900 0 : if (r == NULL) { ndr_print_null(ndr); return; }
901 0 : ndr->depth++;
902 : {
903 0 : libndr_flags _flags_save_string = ndr->flags;
904 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM|LIBNDR_FLAG_ALIGN2);
905 0 : ndr_print_ptr(ndr, "name", r->name);
906 0 : ndr->depth++;
907 0 : if (r->name) {
908 0 : ndr_print_string(ndr, "name", r->name);
909 : }
910 0 : ndr->depth--;
911 0 : ndr->flags = _flags_save_string;
912 : }
913 0 : ndr_print_uint16(ndr, "value_type", r->value_type);
914 0 : ndr_print_uint32(ndr, "flags", r->flags);
915 0 : ndr_print_uint32(ndr, "value_count", r->value_count);
916 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "values", (uint32_t)(r->value_count));
917 0 : ndr->depth++;
918 0 : for (cntr_values_0 = 0; cntr_values_0 < (r->value_count); cntr_values_0++) {
919 0 : ndr_print_set_switch_value(ndr, &r->values[cntr_values_0], r->value_type);
920 0 : ndr_print_claim_values(ndr, "values", &r->values[cntr_values_0]);
921 : }
922 0 : ndr->depth--;
923 0 : ndr->depth--;
924 : }
925 :
926 0 : _PUBLIC_ size_t ndr_size_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(const struct CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1 *r, libndr_flags flags)
927 : {
928 0 : return ndr_size_struct(r, flags, (ndr_push_flags_fn_t)ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1);
929 : }
930 :
931 43479554 : _PUBLIC_ enum ndr_err_code ndr_push_security_ace_object_ctr(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union security_ace_object_ctr *r)
932 : {
933 1078074 : uint32_t level;
934 43479554 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
935 43479554 : if (ndr_flags & NDR_SCALARS) {
936 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
937 21739777 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
938 21739777 : NDR_CHECK(ndr_push_union_align(ndr, 4));
939 21739777 : switch (level) {
940 21739777 : default: {
941 21739777 : NDR_CHECK(ndr_push_security_ace_object(ndr, NDR_SCALARS, &r->object));
942 21200740 : break; }
943 :
944 0 : case false: {
945 0 : break; }
946 :
947 : }
948 : }
949 43479554 : if (ndr_flags & NDR_BUFFERS) {
950 21739777 : if (!(ndr_flags & NDR_SCALARS)) {
951 : /* We didn't get it above, and the token is not needed after this. */
952 21739777 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
953 : }
954 21739777 : switch (level) {
955 21739777 : default:
956 21739777 : NDR_CHECK(ndr_push_security_ace_object(ndr, NDR_BUFFERS, &r->object));
957 21200740 : break;
958 :
959 0 : case false:
960 0 : break;
961 :
962 : }
963 : }
964 42401480 : return NDR_ERR_SUCCESS;
965 : }
966 :
967 245515996 : _PUBLIC_ enum ndr_err_code ndr_pull_security_ace_object_ctr(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union security_ace_object_ctr *r)
968 : {
969 6858248 : uint32_t level;
970 245515996 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
971 245515996 : if (ndr_flags & NDR_SCALARS) {
972 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
973 122757998 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
974 122757998 : NDR_CHECK(ndr_pull_union_align(ndr, 4));
975 122757998 : switch (level) {
976 122757998 : default: {
977 122757998 : NDR_CHECK(ndr_pull_security_ace_object(ndr, NDR_SCALARS, &r->object));
978 119328874 : break; }
979 :
980 0 : case false: {
981 0 : break; }
982 :
983 : }
984 : }
985 245515996 : if (ndr_flags & NDR_BUFFERS) {
986 122757998 : if (!(ndr_flags & NDR_SCALARS)) {
987 : /* We didn't get it above, and the token is not needed after this. */
988 122757998 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
989 : }
990 122757998 : switch (level) {
991 122757998 : default:
992 122757998 : NDR_CHECK(ndr_pull_security_ace_object(ndr, NDR_BUFFERS, &r->object));
993 119328874 : break;
994 :
995 0 : case false:
996 0 : break;
997 :
998 : }
999 : }
1000 238657748 : return NDR_ERR_SUCCESS;
1001 : }
1002 :
1003 4458 : _PUBLIC_ void ndr_print_security_ace_object_ctr(struct ndr_print *ndr, const char *name, const union security_ace_object_ctr *r)
1004 : {
1005 72 : uint32_t level;
1006 4458 : level = ndr_print_steal_switch_value(ndr, r);
1007 4458 : ndr_print_union(ndr, name, level, "security_ace_object_ctr");
1008 4458 : switch (level) {
1009 0 : default:
1010 0 : ndr_print_security_ace_object(ndr, "object", &r->object);
1011 0 : break;
1012 :
1013 4386 : case false:
1014 4386 : break;
1015 :
1016 : }
1017 4458 : }
1018 :
1019 1379 : _PUBLIC_ enum ndr_err_code ndr_push_security_ace_coda(struct ndr_push *ndr, ndr_flags_type ndr_flags, const union security_ace_coda *r)
1020 : {
1021 662 : uint32_t level;
1022 1379 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1023 1379 : if (ndr_flags & NDR_SCALARS) {
1024 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1025 1379 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1026 1379 : NDR_CHECK(ndr_push_union_align(ndr, 5));
1027 1379 : switch (level) {
1028 760 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK: {
1029 : {
1030 760 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1031 760 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1032 760 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->conditions));
1033 760 : ndr->flags = _flags_save_DATA_BLOB;
1034 : }
1035 760 : break; }
1036 :
1037 311 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK: {
1038 : {
1039 311 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1040 311 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1041 311 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->conditions));
1042 311 : ndr->flags = _flags_save_DATA_BLOB;
1043 : }
1044 311 : break; }
1045 :
1046 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK_OBJECT: {
1047 : {
1048 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1049 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1050 0 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->conditions));
1051 0 : ndr->flags = _flags_save_DATA_BLOB;
1052 : }
1053 0 : break; }
1054 :
1055 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK_OBJECT: {
1056 : {
1057 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1058 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1059 0 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->conditions));
1060 0 : ndr->flags = _flags_save_DATA_BLOB;
1061 : }
1062 0 : break; }
1063 :
1064 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK: {
1065 : {
1066 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1067 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1068 0 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->conditions));
1069 0 : ndr->flags = _flags_save_DATA_BLOB;
1070 : }
1071 0 : break; }
1072 :
1073 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK_OBJECT: {
1074 : {
1075 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1076 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1077 0 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->conditions));
1078 0 : ndr->flags = _flags_save_DATA_BLOB;
1079 : }
1080 0 : break; }
1081 :
1082 308 : case SEC_ACE_TYPE_SYSTEM_RESOURCE_ATTRIBUTE: {
1083 308 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->claim));
1084 0 : break; }
1085 :
1086 0 : default: {
1087 : {
1088 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1089 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1090 0 : NDR_CHECK(ndr_push_DATA_BLOB(ndr, NDR_SCALARS, r->ignored));
1091 0 : ndr->flags = _flags_save_DATA_BLOB;
1092 : }
1093 0 : break; }
1094 :
1095 : }
1096 : }
1097 1379 : if (ndr_flags & NDR_BUFFERS) {
1098 1379 : if (!(ndr_flags & NDR_SCALARS)) {
1099 : /* We didn't get it above, and the token is not needed after this. */
1100 0 : NDR_CHECK(ndr_push_steal_switch_value(ndr, r, &level));
1101 : }
1102 1379 : switch (level) {
1103 483 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK:
1104 483 : break;
1105 :
1106 234 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK:
1107 234 : break;
1108 :
1109 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK_OBJECT:
1110 0 : break;
1111 :
1112 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK_OBJECT:
1113 0 : break;
1114 :
1115 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK:
1116 0 : break;
1117 :
1118 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK_OBJECT:
1119 0 : break;
1120 :
1121 308 : case SEC_ACE_TYPE_SYSTEM_RESOURCE_ATTRIBUTE:
1122 308 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->claim));
1123 0 : break;
1124 :
1125 0 : default:
1126 0 : break;
1127 :
1128 : }
1129 : }
1130 717 : return NDR_ERR_SUCCESS;
1131 : }
1132 :
1133 1625 : _PUBLIC_ enum ndr_err_code ndr_pull_security_ace_coda(struct ndr_pull *ndr, ndr_flags_type ndr_flags, union security_ace_coda *r)
1134 : {
1135 433 : uint32_t level;
1136 1625 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1137 1625 : if (ndr_flags & NDR_SCALARS) {
1138 : /* This token is not used again (except perhaps below in the NDR_BUFFERS case) */
1139 1625 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1140 1625 : NDR_CHECK(ndr_pull_union_align(ndr, 5));
1141 1625 : switch (level) {
1142 1090 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK: {
1143 : {
1144 1090 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1145 1090 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1146 1090 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->conditions));
1147 1090 : ndr->flags = _flags_save_DATA_BLOB;
1148 : }
1149 1090 : break; }
1150 :
1151 457 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK: {
1152 : {
1153 457 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1154 457 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1155 457 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->conditions));
1156 457 : ndr->flags = _flags_save_DATA_BLOB;
1157 : }
1158 457 : break; }
1159 :
1160 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK_OBJECT: {
1161 : {
1162 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1163 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1164 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->conditions));
1165 0 : ndr->flags = _flags_save_DATA_BLOB;
1166 : }
1167 0 : break; }
1168 :
1169 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK_OBJECT: {
1170 : {
1171 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1172 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1173 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->conditions));
1174 0 : ndr->flags = _flags_save_DATA_BLOB;
1175 : }
1176 0 : break; }
1177 :
1178 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK: {
1179 : {
1180 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1181 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1182 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->conditions));
1183 0 : ndr->flags = _flags_save_DATA_BLOB;
1184 : }
1185 0 : break; }
1186 :
1187 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK_OBJECT: {
1188 : {
1189 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1190 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1191 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->conditions));
1192 0 : ndr->flags = _flags_save_DATA_BLOB;
1193 : }
1194 0 : break; }
1195 :
1196 78 : case SEC_ACE_TYPE_SYSTEM_RESOURCE_ATTRIBUTE: {
1197 78 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->claim));
1198 0 : break; }
1199 :
1200 0 : default: {
1201 : {
1202 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1203 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1204 0 : NDR_CHECK(ndr_pull_DATA_BLOB(ndr, NDR_SCALARS, &r->ignored));
1205 0 : ndr->flags = _flags_save_DATA_BLOB;
1206 : }
1207 0 : break; }
1208 :
1209 : }
1210 : }
1211 1625 : if (ndr_flags & NDR_BUFFERS) {
1212 1625 : if (!(ndr_flags & NDR_SCALARS)) {
1213 : /* We didn't get it above, and the token is not needed after this. */
1214 0 : NDR_CHECK(ndr_pull_steal_switch_value(ndr, r, &level));
1215 : }
1216 1625 : switch (level) {
1217 812 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK:
1218 812 : break;
1219 :
1220 380 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK:
1221 380 : break;
1222 :
1223 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK_OBJECT:
1224 0 : break;
1225 :
1226 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK_OBJECT:
1227 0 : break;
1228 :
1229 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK:
1230 0 : break;
1231 :
1232 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK_OBJECT:
1233 0 : break;
1234 :
1235 78 : case SEC_ACE_TYPE_SYSTEM_RESOURCE_ATTRIBUTE:
1236 78 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->claim));
1237 0 : break;
1238 :
1239 0 : default:
1240 0 : break;
1241 :
1242 : }
1243 : }
1244 1192 : return NDR_ERR_SUCCESS;
1245 : }
1246 :
1247 4458 : _PUBLIC_ void ndr_print_security_ace_coda(struct ndr_print *ndr, const char *name, const union security_ace_coda *r)
1248 : {
1249 72 : uint32_t level;
1250 4458 : level = ndr_print_steal_switch_value(ndr, r);
1251 4458 : ndr_print_union(ndr, name, level, "security_ace_coda");
1252 4458 : switch (level) {
1253 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK:
1254 : {
1255 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1256 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1257 0 : ndr_print_DATA_BLOB(ndr, "conditions", r->conditions);
1258 0 : ndr->flags = _flags_save_DATA_BLOB;
1259 : }
1260 0 : break;
1261 :
1262 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK:
1263 : {
1264 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1265 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1266 0 : ndr_print_DATA_BLOB(ndr, "conditions", r->conditions);
1267 0 : ndr->flags = _flags_save_DATA_BLOB;
1268 : }
1269 0 : break;
1270 :
1271 0 : case SEC_ACE_TYPE_ACCESS_ALLOWED_CALLBACK_OBJECT:
1272 : {
1273 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1274 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1275 0 : ndr_print_DATA_BLOB(ndr, "conditions", r->conditions);
1276 0 : ndr->flags = _flags_save_DATA_BLOB;
1277 : }
1278 0 : break;
1279 :
1280 0 : case SEC_ACE_TYPE_ACCESS_DENIED_CALLBACK_OBJECT:
1281 : {
1282 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1283 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1284 0 : ndr_print_DATA_BLOB(ndr, "conditions", r->conditions);
1285 0 : ndr->flags = _flags_save_DATA_BLOB;
1286 : }
1287 0 : break;
1288 :
1289 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK:
1290 : {
1291 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1292 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1293 0 : ndr_print_DATA_BLOB(ndr, "conditions", r->conditions);
1294 0 : ndr->flags = _flags_save_DATA_BLOB;
1295 : }
1296 0 : break;
1297 :
1298 0 : case SEC_ACE_TYPE_SYSTEM_AUDIT_CALLBACK_OBJECT:
1299 : {
1300 0 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1301 0 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1302 0 : ndr_print_DATA_BLOB(ndr, "conditions", r->conditions);
1303 0 : ndr->flags = _flags_save_DATA_BLOB;
1304 : }
1305 0 : break;
1306 :
1307 0 : case SEC_ACE_TYPE_SYSTEM_RESOURCE_ATTRIBUTE:
1308 0 : ndr_print_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, "claim", &r->claim);
1309 0 : break;
1310 :
1311 4458 : default:
1312 : {
1313 4458 : libndr_flags _flags_save_DATA_BLOB = ndr->flags;
1314 4458 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_REMAINING);
1315 4458 : ndr_print_DATA_BLOB(ndr, "ignored", r->ignored);
1316 4458 : ndr->flags = _flags_save_DATA_BLOB;
1317 : }
1318 4458 : break;
1319 :
1320 : }
1321 4458 : }
1322 :
1323 231 : _PUBLIC_ size_t ndr_size_security_ace_coda(const union security_ace_coda *r, uint32_t level, libndr_flags flags)
1324 : {
1325 231 : return ndr_size_union(r, flags, level, (ndr_push_flags_fn_t)ndr_push_security_ace_coda);
1326 : }
1327 :
1328 0 : static void ndr_print_flags_security_ace(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct security_ace *r)
1329 : {
1330 0 : ndr_print_security_ace(ndr, name, r);
1331 0 : }
1332 :
1333 4458 : _PUBLIC_ void ndr_print_security_ace(struct ndr_print *ndr, const char *name, const struct security_ace *r)
1334 : {
1335 4458 : ndr_print_struct(ndr, name, "security_ace");
1336 4458 : if (r == NULL) { ndr_print_null(ndr); return; }
1337 4458 : ndr->depth++;
1338 4458 : ndr_print_security_ace_type(ndr, "type", r->type);
1339 4458 : ndr_print_security_ace_flags(ndr, "flags", r->flags);
1340 4458 : ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?ndr_size_security_ace(r, ndr->flags):r->size);
1341 4458 : ndr_print_uint32(ndr, "access_mask", r->access_mask);
1342 4458 : ndr_print_set_switch_value(ndr, &r->object, sec_ace_object(r->type));
1343 4458 : ndr_print_security_ace_object_ctr(ndr, "object", &r->object);
1344 4458 : ndr_print_dom_sid(ndr, "trustee", &r->trustee);
1345 4458 : ndr_print_set_switch_value(ndr, &r->coda, r->type);
1346 4458 : ndr_print_security_ace_coda(ndr, "coda", &r->coda);
1347 4458 : ndr->depth--;
1348 : }
1349 :
1350 5238501 : static enum ndr_err_code ndr_push_security_acl_revision(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum security_acl_revision r)
1351 : {
1352 5238501 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
1353 4932423 : return NDR_ERR_SUCCESS;
1354 : }
1355 :
1356 16467806 : static enum ndr_err_code ndr_pull_security_acl_revision(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum security_acl_revision *r)
1357 : {
1358 805055 : uint16_t v;
1359 16467806 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
1360 16467806 : *r = v;
1361 16467806 : return NDR_ERR_SUCCESS;
1362 : }
1363 :
1364 3520 : _PUBLIC_ void ndr_print_security_acl_revision(struct ndr_print *ndr, const char *name, enum security_acl_revision r)
1365 : {
1366 3520 : const char *val = NULL;
1367 :
1368 3520 : switch (r) {
1369 3518 : case SECURITY_ACL_REVISION_NT4: val = "SECURITY_ACL_REVISION_NT4"; break;
1370 2 : case SECURITY_ACL_REVISION_ADS: val = "SECURITY_ACL_REVISION_ADS"; break;
1371 : }
1372 3520 : ndr_print_enum(ndr, name, "ENUM", val, r);
1373 3520 : }
1374 :
1375 5238501 : _PUBLIC_ enum ndr_err_code ndr_push_security_acl(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_acl *r)
1376 : {
1377 306078 : uint32_t cntr_aces_0;
1378 5238501 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1379 5238501 : if (ndr_flags & NDR_SCALARS) {
1380 5238501 : NDR_CHECK(ndr_push_align(ndr, 5));
1381 5544579 : NDR_CHECK(ndr_push_security_acl_revision(ndr, NDR_SCALARS, r->revision));
1382 5238501 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, ndr_size_security_acl(r, ndr->flags)));
1383 5238501 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_aces));
1384 43622243 : for (cntr_aces_0 = 0; cntr_aces_0 < (r->num_aces); cntr_aces_0++) {
1385 38383742 : NDR_CHECK(ndr_push_security_ace(ndr, NDR_SCALARS, &r->aces[cntr_aces_0]));
1386 : }
1387 5238501 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1388 : }
1389 5238501 : if (ndr_flags & NDR_BUFFERS) {
1390 43622243 : for (cntr_aces_0 = 0; cntr_aces_0 < (r->num_aces); cntr_aces_0++) {
1391 38383742 : NDR_CHECK(ndr_push_security_ace(ndr, NDR_BUFFERS, &r->aces[cntr_aces_0]));
1392 : }
1393 : }
1394 4932423 : return NDR_ERR_SUCCESS;
1395 : }
1396 :
1397 16467806 : _PUBLIC_ enum ndr_err_code ndr_pull_security_acl(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_acl *r)
1398 : {
1399 16467806 : uint32_t size_aces_0 = 0;
1400 805055 : uint32_t cntr_aces_0;
1401 16467806 : TALLOC_CTX *_mem_save_aces_0 = NULL;
1402 16467806 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1403 16467806 : if (ndr_flags & NDR_SCALARS) {
1404 16467806 : NDR_CHECK(ndr_pull_align(ndr, 5));
1405 17272861 : NDR_CHECK(ndr_pull_security_acl_revision(ndr, NDR_SCALARS, &r->revision));
1406 16467806 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &r->size));
1407 16467806 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_aces));
1408 16467806 : if (r->num_aces > 2000) {
1409 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->num_aces), (uint32_t)(0), (uint32_t)(2000));
1410 : }
1411 16467806 : size_aces_0 = r->num_aces;
1412 16467806 : NDR_PULL_ALLOC_N(ndr, r->aces, size_aces_0);
1413 16467806 : _mem_save_aces_0 = NDR_PULL_GET_MEM_CTX(ndr);
1414 16467806 : NDR_PULL_SET_MEM_CTX(ndr, r->aces, 0);
1415 197204515 : for (cntr_aces_0 = 0; cntr_aces_0 < (size_aces_0); cntr_aces_0++) {
1416 180736709 : NDR_CHECK(ndr_pull_security_ace(ndr, NDR_SCALARS, &r->aces[cntr_aces_0]));
1417 : }
1418 16467806 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_aces_0, 0);
1419 16467806 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1420 : }
1421 16467806 : if (ndr_flags & NDR_BUFFERS) {
1422 16467806 : size_aces_0 = r->num_aces;
1423 16467806 : _mem_save_aces_0 = NDR_PULL_GET_MEM_CTX(ndr);
1424 16467806 : NDR_PULL_SET_MEM_CTX(ndr, r->aces, 0);
1425 197204515 : for (cntr_aces_0 = 0; cntr_aces_0 < (size_aces_0); cntr_aces_0++) {
1426 180736709 : NDR_CHECK(ndr_pull_security_ace(ndr, NDR_BUFFERS, &r->aces[cntr_aces_0]));
1427 : }
1428 16467806 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_aces_0, 0);
1429 190735649 : for (cntr_aces_0 = 0; cntr_aces_0 < (size_aces_0); cntr_aces_0++) {
1430 : }
1431 : }
1432 15662751 : return NDR_ERR_SUCCESS;
1433 : }
1434 :
1435 0 : static void ndr_print_flags_security_acl(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct security_acl *r)
1436 : {
1437 0 : ndr_print_security_acl(ndr, name, r);
1438 0 : }
1439 :
1440 3520 : _PUBLIC_ void ndr_print_security_acl(struct ndr_print *ndr, const char *name, const struct security_acl *r)
1441 : {
1442 17 : uint32_t cntr_aces_0;
1443 3520 : ndr_print_struct(ndr, name, "security_acl");
1444 3520 : if (r == NULL) { ndr_print_null(ndr); return; }
1445 3520 : ndr->depth++;
1446 3520 : ndr_print_security_acl_revision(ndr, "revision", r->revision);
1447 3520 : ndr_print_uint16(ndr, "size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?ndr_size_security_acl(r, ndr->flags):r->size);
1448 3520 : ndr_print_uint32(ndr, "num_aces", r->num_aces);
1449 3520 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "aces", (uint32_t)(r->num_aces));
1450 3520 : ndr->depth++;
1451 7978 : for (cntr_aces_0 = 0; cntr_aces_0 < (r->num_aces); cntr_aces_0++) {
1452 4458 : ndr_print_security_ace(ndr, "aces", &r->aces[cntr_aces_0]);
1453 : }
1454 3520 : ndr->depth--;
1455 3520 : ndr->depth--;
1456 : }
1457 :
1458 3295890 : _PUBLIC_ enum ndr_err_code ndr_push_security_descriptor_revision(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum security_descriptor_revision r)
1459 : {
1460 3295890 : NDR_CHECK(ndr_push_enum_uint8(ndr, NDR_SCALARS, r));
1461 3087388 : return NDR_ERR_SUCCESS;
1462 : }
1463 :
1464 9937222 : _PUBLIC_ enum ndr_err_code ndr_pull_security_descriptor_revision(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum security_descriptor_revision *r)
1465 : {
1466 549807 : uint8_t v;
1467 9937222 : NDR_CHECK(ndr_pull_enum_uint8(ndr, NDR_SCALARS, &v));
1468 9937222 : *r = v;
1469 9937222 : return NDR_ERR_SUCCESS;
1470 : }
1471 :
1472 3552 : _PUBLIC_ void ndr_print_security_descriptor_revision(struct ndr_print *ndr, const char *name, enum security_descriptor_revision r)
1473 : {
1474 3552 : const char *val = NULL;
1475 :
1476 3552 : switch (r) {
1477 3552 : case SECURITY_DESCRIPTOR_REVISION_1: val = "SECURITY_DESCRIPTOR_REVISION_1"; break;
1478 : }
1479 3552 : ndr_print_enum(ndr, name, "ENUM", val, r);
1480 3552 : }
1481 :
1482 3295890 : _PUBLIC_ enum ndr_err_code ndr_push_security_descriptor_type(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint16_t r)
1483 : {
1484 3295890 : NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r));
1485 3087388 : return NDR_ERR_SUCCESS;
1486 : }
1487 :
1488 9937222 : _PUBLIC_ enum ndr_err_code ndr_pull_security_descriptor_type(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint16_t *r)
1489 : {
1490 549807 : uint16_t v;
1491 9937222 : NDR_CHECK(ndr_pull_uint16(ndr, NDR_SCALARS, &v));
1492 9937222 : *r = v;
1493 9937222 : return NDR_ERR_SUCCESS;
1494 : }
1495 :
1496 3552 : _PUBLIC_ void ndr_print_security_descriptor_type(struct ndr_print *ndr, const char *name, uint16_t r)
1497 : {
1498 3552 : ndr_print_uint16(ndr, name, r);
1499 3552 : ndr->depth++;
1500 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_OWNER_DEFAULTED", SEC_DESC_OWNER_DEFAULTED, r);
1501 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_GROUP_DEFAULTED", SEC_DESC_GROUP_DEFAULTED, r);
1502 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_DACL_PRESENT", SEC_DESC_DACL_PRESENT, r);
1503 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_DACL_DEFAULTED", SEC_DESC_DACL_DEFAULTED, r);
1504 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_SACL_PRESENT", SEC_DESC_SACL_PRESENT, r);
1505 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_SACL_DEFAULTED", SEC_DESC_SACL_DEFAULTED, r);
1506 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_DACL_TRUSTED", SEC_DESC_DACL_TRUSTED, r);
1507 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_SERVER_SECURITY", SEC_DESC_SERVER_SECURITY, r);
1508 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_DACL_AUTO_INHERIT_REQ", SEC_DESC_DACL_AUTO_INHERIT_REQ, r);
1509 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_SACL_AUTO_INHERIT_REQ", SEC_DESC_SACL_AUTO_INHERIT_REQ, r);
1510 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_DACL_AUTO_INHERITED", SEC_DESC_DACL_AUTO_INHERITED, r);
1511 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_SACL_AUTO_INHERITED", SEC_DESC_SACL_AUTO_INHERITED, r);
1512 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_DACL_PROTECTED", SEC_DESC_DACL_PROTECTED, r);
1513 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_SACL_PROTECTED", SEC_DESC_SACL_PROTECTED, r);
1514 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_RM_CONTROL_VALID", SEC_DESC_RM_CONTROL_VALID, r);
1515 3552 : ndr_print_bitmap_flag(ndr, sizeof(uint16_t), "SEC_DESC_SELF_RELATIVE", SEC_DESC_SELF_RELATIVE, r);
1516 3552 : ndr->depth--;
1517 3552 : }
1518 :
1519 3293730 : _PUBLIC_ enum ndr_err_code ndr_push_security_descriptor(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_descriptor *r)
1520 : {
1521 : {
1522 3293730 : libndr_flags _flags_save_STRUCT = ndr->flags;
1523 3293730 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_LITTLE_ENDIAN);
1524 3293730 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1525 3293730 : if (ndr_flags & NDR_SCALARS) {
1526 3293730 : NDR_CHECK(ndr_push_align(ndr, 5));
1527 3293730 : NDR_CHECK(ndr_push_security_descriptor_revision(ndr, NDR_SCALARS, r->revision));
1528 3293730 : NDR_CHECK(ndr_push_security_descriptor_type(ndr, NDR_SCALARS, r->type));
1529 3293730 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->owner_sid));
1530 3293730 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->group_sid));
1531 3293730 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->sacl));
1532 3293730 : NDR_CHECK(ndr_push_relative_ptr1(ndr, r->dacl));
1533 3293730 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1534 : }
1535 3293730 : if (ndr_flags & NDR_BUFFERS) {
1536 3293730 : if (r->owner_sid) {
1537 3253484 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->owner_sid));
1538 3253484 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->owner_sid));
1539 3253484 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->owner_sid));
1540 : }
1541 3293730 : if (r->group_sid) {
1542 3232587 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->group_sid));
1543 3232587 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->group_sid));
1544 3232587 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->group_sid));
1545 : }
1546 3293730 : if (r->sacl) {
1547 1946595 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->sacl));
1548 1946595 : NDR_CHECK(ndr_push_security_acl(ndr, NDR_SCALARS|NDR_BUFFERS, r->sacl));
1549 1946595 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->sacl));
1550 : }
1551 3293730 : if (r->dacl) {
1552 3283548 : NDR_CHECK(ndr_push_relative_ptr2_start(ndr, r->dacl));
1553 3283548 : NDR_CHECK(ndr_push_security_acl(ndr, NDR_SCALARS|NDR_BUFFERS, r->dacl));
1554 3283548 : NDR_CHECK(ndr_push_relative_ptr2_end(ndr, r->dacl));
1555 : }
1556 : }
1557 3293730 : ndr->flags = _flags_save_STRUCT;
1558 : }
1559 3293730 : return NDR_ERR_SUCCESS;
1560 : }
1561 :
1562 9937222 : _PUBLIC_ enum ndr_err_code ndr_pull_security_descriptor(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_descriptor *r)
1563 : {
1564 549807 : uint32_t _ptr_owner_sid;
1565 9937222 : TALLOC_CTX *_mem_save_owner_sid_0 = NULL;
1566 549807 : uint32_t _ptr_group_sid;
1567 9937222 : TALLOC_CTX *_mem_save_group_sid_0 = NULL;
1568 549807 : uint32_t _ptr_sacl;
1569 9937222 : TALLOC_CTX *_mem_save_sacl_0 = NULL;
1570 549807 : uint32_t _ptr_dacl;
1571 9937222 : TALLOC_CTX *_mem_save_dacl_0 = NULL;
1572 : {
1573 9937222 : libndr_flags _flags_save_STRUCT = ndr->flags;
1574 9937222 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_LITTLE_ENDIAN);
1575 9937222 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1576 9937222 : if (ndr_flags & NDR_SCALARS) {
1577 9937222 : NDR_CHECK(ndr_pull_align(ndr, 5));
1578 9937222 : NDR_CHECK(ndr_pull_security_descriptor_revision(ndr, NDR_SCALARS, &r->revision));
1579 9937222 : NDR_CHECK(ndr_pull_security_descriptor_type(ndr, NDR_SCALARS, &r->type));
1580 9937222 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_owner_sid));
1581 9937222 : if (_ptr_owner_sid) {
1582 9880211 : NDR_PULL_ALLOC(ndr, r->owner_sid);
1583 9880211 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->owner_sid, _ptr_owner_sid));
1584 : } else {
1585 57011 : r->owner_sid = NULL;
1586 : }
1587 9937222 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_group_sid));
1588 9937222 : if (_ptr_group_sid) {
1589 9858283 : NDR_PULL_ALLOC(ndr, r->group_sid);
1590 9858283 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->group_sid, _ptr_group_sid));
1591 : } else {
1592 78939 : r->group_sid = NULL;
1593 : }
1594 9937222 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sacl));
1595 9937222 : if (_ptr_sacl) {
1596 6541800 : NDR_PULL_ALLOC(ndr, r->sacl);
1597 6541800 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->sacl, _ptr_sacl));
1598 : } else {
1599 3395422 : r->sacl = NULL;
1600 : }
1601 9937222 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_dacl));
1602 9937222 : if (_ptr_dacl) {
1603 9919808 : NDR_PULL_ALLOC(ndr, r->dacl);
1604 9919808 : NDR_CHECK(ndr_pull_relative_ptr1(ndr, r->dacl, _ptr_dacl));
1605 : } else {
1606 17414 : r->dacl = NULL;
1607 : }
1608 9937222 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1609 : }
1610 9937222 : if (ndr_flags & NDR_BUFFERS) {
1611 9937222 : if (r->owner_sid) {
1612 544964 : uint32_t _relative_save_offset;
1613 9880211 : _relative_save_offset = ndr->offset;
1614 9880211 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->owner_sid));
1615 9880211 : _mem_save_owner_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1616 9880211 : NDR_PULL_SET_MEM_CTX(ndr, r->owner_sid, 0);
1617 9880211 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->owner_sid));
1618 9880211 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_owner_sid_0, 0);
1619 9880211 : if (ndr->offset > ndr->relative_highest_offset) {
1620 9880211 : ndr->relative_highest_offset = ndr->offset;
1621 : }
1622 9880211 : ndr->offset = _relative_save_offset;
1623 : }
1624 9937222 : if (r->group_sid) {
1625 544829 : uint32_t _relative_save_offset;
1626 9858283 : _relative_save_offset = ndr->offset;
1627 9858283 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->group_sid));
1628 9858283 : _mem_save_group_sid_0 = NDR_PULL_GET_MEM_CTX(ndr);
1629 9858283 : NDR_PULL_SET_MEM_CTX(ndr, r->group_sid, 0);
1630 9858283 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->group_sid));
1631 9858283 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_group_sid_0, 0);
1632 9858283 : if (ndr->offset > ndr->relative_highest_offset) {
1633 9858283 : ndr->relative_highest_offset = ndr->offset;
1634 : }
1635 9858283 : ndr->offset = _relative_save_offset;
1636 : }
1637 9937222 : if (r->sacl) {
1638 255268 : uint32_t _relative_save_offset;
1639 6541800 : _relative_save_offset = ndr->offset;
1640 6541800 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->sacl));
1641 6541800 : _mem_save_sacl_0 = NDR_PULL_GET_MEM_CTX(ndr);
1642 6541800 : NDR_PULL_SET_MEM_CTX(ndr, r->sacl, 0);
1643 6541800 : NDR_CHECK(ndr_pull_security_acl(ndr, NDR_SCALARS|NDR_BUFFERS, r->sacl));
1644 6541800 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sacl_0, 0);
1645 6541800 : if (ndr->offset > ndr->relative_highest_offset) {
1646 6537754 : ndr->relative_highest_offset = ndr->offset;
1647 : }
1648 6541800 : ndr->offset = _relative_save_offset;
1649 : }
1650 9937222 : if (r->dacl) {
1651 549611 : uint32_t _relative_save_offset;
1652 9919808 : _relative_save_offset = ndr->offset;
1653 9919808 : NDR_CHECK(ndr_pull_relative_ptr2(ndr, r->dacl));
1654 9919808 : _mem_save_dacl_0 = NDR_PULL_GET_MEM_CTX(ndr);
1655 9919808 : NDR_PULL_SET_MEM_CTX(ndr, r->dacl, 0);
1656 9919808 : NDR_CHECK(ndr_pull_security_acl(ndr, NDR_SCALARS|NDR_BUFFERS, r->dacl));
1657 9919808 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_dacl_0, 0);
1658 9919808 : if (ndr->offset > ndr->relative_highest_offset) {
1659 9912505 : ndr->relative_highest_offset = ndr->offset;
1660 : }
1661 9919808 : ndr->offset = _relative_save_offset;
1662 : }
1663 : }
1664 9937222 : ndr->flags = _flags_save_STRUCT;
1665 : }
1666 9937222 : return NDR_ERR_SUCCESS;
1667 : }
1668 :
1669 0 : static void ndr_print_flags_security_descriptor(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct security_descriptor *r)
1670 : {
1671 0 : ndr_print_security_descriptor(ndr, name, r);
1672 0 : }
1673 :
1674 3552 : _PUBLIC_ void ndr_print_security_descriptor(struct ndr_print *ndr, const char *name, const struct security_descriptor *r)
1675 : {
1676 3552 : ndr_print_struct(ndr, name, "security_descriptor");
1677 3552 : if (r == NULL) { ndr_print_null(ndr); return; }
1678 : {
1679 3552 : libndr_flags _flags_save_STRUCT = ndr->flags;
1680 3552 : ndr_set_flags(&ndr->flags, LIBNDR_FLAG_LITTLE_ENDIAN);
1681 3552 : ndr->depth++;
1682 3552 : ndr_print_security_descriptor_revision(ndr, "revision", r->revision);
1683 3552 : ndr_print_security_descriptor_type(ndr, "type", r->type);
1684 3552 : ndr_print_ptr(ndr, "owner_sid", r->owner_sid);
1685 3552 : ndr->depth++;
1686 3552 : if (r->owner_sid) {
1687 3342 : ndr_print_dom_sid(ndr, "owner_sid", r->owner_sid);
1688 : }
1689 3552 : ndr->depth--;
1690 3552 : ndr_print_ptr(ndr, "group_sid", r->group_sid);
1691 3552 : ndr->depth++;
1692 3552 : if (r->group_sid) {
1693 80 : ndr_print_dom_sid(ndr, "group_sid", r->group_sid);
1694 : }
1695 3552 : ndr->depth--;
1696 3552 : ndr_print_ptr(ndr, "sacl", r->sacl);
1697 3552 : ndr->depth++;
1698 3552 : if (r->sacl) {
1699 0 : ndr_print_security_acl(ndr, "sacl", r->sacl);
1700 : }
1701 3552 : ndr->depth--;
1702 3552 : ndr_print_ptr(ndr, "dacl", r->dacl);
1703 3552 : ndr->depth++;
1704 3552 : if (r->dacl) {
1705 3520 : ndr_print_security_acl(ndr, "dacl", r->dacl);
1706 : }
1707 3552 : ndr->depth--;
1708 3552 : ndr->depth--;
1709 3552 : ndr->flags = _flags_save_STRUCT;
1710 : }
1711 : }
1712 :
1713 2514 : _PUBLIC_ enum ndr_err_code ndr_push_sec_desc_buf(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct sec_desc_buf *r)
1714 : {
1715 2514 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1716 2514 : if (ndr_flags & NDR_SCALARS) {
1717 1814 : NDR_CHECK(ndr_push_align(ndr, 5));
1718 1814 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, ndr_size_security_descriptor(r->sd, ndr->flags)));
1719 1814 : NDR_CHECK(ndr_push_unique_ptr(ndr, r->sd));
1720 1814 : NDR_CHECK(ndr_push_trailer_align(ndr, 5));
1721 : }
1722 2514 : if (ndr_flags & NDR_BUFFERS) {
1723 1814 : if (r->sd) {
1724 : {
1725 20 : struct ndr_push *_ndr_sd;
1726 1056 : NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_sd, 4, -1));
1727 1056 : NDR_CHECK(ndr_push_security_descriptor(_ndr_sd, NDR_SCALARS|NDR_BUFFERS, r->sd));
1728 1056 : NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_sd, 4, -1));
1729 : }
1730 : }
1731 : }
1732 2494 : return NDR_ERR_SUCCESS;
1733 : }
1734 :
1735 4874 : _PUBLIC_ enum ndr_err_code ndr_pull_sec_desc_buf(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct sec_desc_buf *r)
1736 : {
1737 24 : uint32_t _ptr_sd;
1738 4874 : TALLOC_CTX *_mem_save_sd_0 = NULL;
1739 4874 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1740 4874 : if (ndr_flags & NDR_SCALARS) {
1741 2998 : NDR_CHECK(ndr_pull_align(ndr, 5));
1742 2998 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->sd_size));
1743 2998 : if (r->sd_size > 262144) {
1744 0 : return ndr_pull_error(ndr, NDR_ERR_RANGE, "value (%"PRIu32") out of range (%"PRIu32" - %"PRIu32")", (uint32_t)(r->sd_size), (uint32_t)(0), (uint32_t)(262144));
1745 : }
1746 2998 : NDR_CHECK(ndr_pull_generic_ptr(ndr, &_ptr_sd));
1747 2998 : if (_ptr_sd) {
1748 2276 : NDR_PULL_ALLOC(ndr, r->sd);
1749 : } else {
1750 722 : r->sd = NULL;
1751 : }
1752 2998 : NDR_CHECK(ndr_pull_trailer_align(ndr, 5));
1753 : }
1754 4874 : if (ndr_flags & NDR_BUFFERS) {
1755 2998 : if (r->sd) {
1756 2276 : _mem_save_sd_0 = NDR_PULL_GET_MEM_CTX(ndr);
1757 2276 : NDR_PULL_SET_MEM_CTX(ndr, r->sd, 0);
1758 : {
1759 20 : struct ndr_pull *_ndr_sd;
1760 2276 : ssize_t sub_size = -1;
1761 2276 : NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_sd, 4, sub_size));
1762 2276 : NDR_CHECK(ndr_pull_security_descriptor(_ndr_sd, NDR_SCALARS|NDR_BUFFERS, r->sd));
1763 2276 : NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_sd, 4, sub_size));
1764 : }
1765 2276 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sd_0, 0);
1766 : }
1767 : }
1768 4850 : return NDR_ERR_SUCCESS;
1769 : }
1770 :
1771 0 : static void ndr_print_flags_sec_desc_buf(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct sec_desc_buf *r)
1772 : {
1773 0 : ndr_print_sec_desc_buf(ndr, name, r);
1774 0 : }
1775 :
1776 118 : _PUBLIC_ void ndr_print_sec_desc_buf(struct ndr_print *ndr, const char *name, const struct sec_desc_buf *r)
1777 : {
1778 118 : ndr_print_struct(ndr, name, "sec_desc_buf");
1779 118 : if (r == NULL) { ndr_print_null(ndr); return; }
1780 118 : ndr->depth++;
1781 118 : ndr_print_uint32(ndr, "sd_size", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?ndr_size_security_descriptor(r->sd, ndr->flags):r->sd_size);
1782 118 : ndr_print_ptr(ndr, "sd", r->sd);
1783 118 : ndr->depth++;
1784 118 : if (r->sd) {
1785 36 : ndr_print_security_descriptor(ndr, "sd", r->sd);
1786 : }
1787 118 : ndr->depth--;
1788 118 : ndr->depth--;
1789 : }
1790 :
1791 608013 : _PUBLIC_ enum ndr_err_code ndr_push_security_GroupAttrs(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
1792 : {
1793 608013 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
1794 578758 : return NDR_ERR_SUCCESS;
1795 : }
1796 :
1797 708675 : _PUBLIC_ enum ndr_err_code ndr_pull_security_GroupAttrs(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
1798 : {
1799 25285 : uint32_t v;
1800 708675 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
1801 708675 : *r = v;
1802 708675 : return NDR_ERR_SUCCESS;
1803 : }
1804 :
1805 21484 : _PUBLIC_ void ndr_print_security_GroupAttrs(struct ndr_print *ndr, const char *name, uint32_t r)
1806 : {
1807 21484 : ndr_print_uint32(ndr, name, r);
1808 21484 : ndr->depth++;
1809 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_MANDATORY", SE_GROUP_MANDATORY, r);
1810 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_ENABLED_BY_DEFAULT", SE_GROUP_ENABLED_BY_DEFAULT, r);
1811 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_ENABLED", SE_GROUP_ENABLED, r);
1812 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_OWNER", SE_GROUP_OWNER, r);
1813 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_USE_FOR_DENY_ONLY", SE_GROUP_USE_FOR_DENY_ONLY, r);
1814 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_INTEGRITY", SE_GROUP_INTEGRITY, r);
1815 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_INTEGRITY_ENABLED", SE_GROUP_INTEGRITY_ENABLED, r);
1816 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_RESOURCE", SE_GROUP_RESOURCE, r);
1817 21484 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SE_GROUP_LOGON_ID", SE_GROUP_LOGON_ID, r);
1818 21484 : ndr->depth--;
1819 21484 : }
1820 :
1821 7756493 : static enum ndr_err_code ndr_push_claims_evaluation_control(struct ndr_push *ndr, ndr_flags_type ndr_flags, enum claims_evaluation_control r)
1822 : {
1823 7756493 : NDR_CHECK(ndr_push_enum_uint1632(ndr, NDR_SCALARS, r));
1824 7742859 : return NDR_ERR_SUCCESS;
1825 : }
1826 :
1827 7606760 : static enum ndr_err_code ndr_pull_claims_evaluation_control(struct ndr_pull *ndr, ndr_flags_type ndr_flags, enum claims_evaluation_control *r)
1828 : {
1829 11407 : uint16_t v;
1830 7606760 : NDR_CHECK(ndr_pull_enum_uint1632(ndr, NDR_SCALARS, &v));
1831 7606760 : *r = v;
1832 7606760 : return NDR_ERR_SUCCESS;
1833 : }
1834 :
1835 0 : _PUBLIC_ void ndr_print_claims_evaluation_control(struct ndr_print *ndr, const char *name, enum claims_evaluation_control r)
1836 : {
1837 0 : const char *val = NULL;
1838 :
1839 0 : switch (r) {
1840 0 : case CLAIMS_EVALUATION_INVALID_STATE: val = "CLAIMS_EVALUATION_INVALID_STATE"; break;
1841 0 : case CLAIMS_EVALUATION_NEVER: val = "CLAIMS_EVALUATION_NEVER"; break;
1842 0 : case CLAIMS_EVALUATION_ALWAYS: val = "CLAIMS_EVALUATION_ALWAYS"; break;
1843 : }
1844 0 : ndr_print_enum(ndr, name, "ENUM", val, r);
1845 0 : }
1846 :
1847 7756493 : _PUBLIC_ enum ndr_err_code ndr_push_security_token(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_token *r)
1848 : {
1849 13634 : uint32_t cntr_sids_0;
1850 13634 : uint32_t cntr_local_claims_0;
1851 13634 : uint32_t cntr_user_claims_0;
1852 13634 : uint32_t cntr_device_claims_0;
1853 13634 : uint32_t cntr_device_sids_0;
1854 7756493 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
1855 7756493 : if (ndr_flags & NDR_SCALARS) {
1856 7756493 : NDR_CHECK(ndr_push_align(ndr, 8));
1857 7756493 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_sids));
1858 7756493 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_sids));
1859 60777056 : for (cntr_sids_0 = 0; cntr_sids_0 < (r->num_sids); cntr_sids_0++) {
1860 53020563 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->sids[cntr_sids_0]));
1861 : }
1862 7770127 : NDR_CHECK(ndr_push_se_privilege(ndr, NDR_SCALARS, r->privilege_mask));
1863 7770127 : NDR_CHECK(ndr_push_lsa_SystemAccessModeFlags(ndr, NDR_SCALARS, r->rights_mask));
1864 7756493 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_local_claims));
1865 7756493 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_user_claims));
1866 7756493 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_device_claims));
1867 7756493 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_device_sids));
1868 7756493 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_local_claims));
1869 7756493 : for (cntr_local_claims_0 = 0; cntr_local_claims_0 < (r->num_local_claims); cntr_local_claims_0++) {
1870 0 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->local_claims[cntr_local_claims_0]));
1871 : }
1872 7756493 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_user_claims));
1873 7756493 : for (cntr_user_claims_0 = 0; cntr_user_claims_0 < (r->num_user_claims); cntr_user_claims_0++) {
1874 0 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->user_claims[cntr_user_claims_0]));
1875 : }
1876 7756493 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_device_claims));
1877 7756493 : for (cntr_device_claims_0 = 0; cntr_device_claims_0 < (r->num_device_claims); cntr_device_claims_0++) {
1878 0 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->device_claims[cntr_device_claims_0]));
1879 : }
1880 7756493 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->num_device_sids));
1881 7756493 : for (cntr_device_sids_0 = 0; cntr_device_sids_0 < (r->num_device_sids); cntr_device_sids_0++) {
1882 0 : NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, &r->device_sids[cntr_device_sids_0]));
1883 : }
1884 7770127 : NDR_CHECK(ndr_push_claims_evaluation_control(ndr, NDR_SCALARS, r->evaluate_claims));
1885 7756493 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
1886 : }
1887 7756493 : if (ndr_flags & NDR_BUFFERS) {
1888 7756493 : for (cntr_local_claims_0 = 0; cntr_local_claims_0 < (r->num_local_claims); cntr_local_claims_0++) {
1889 0 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->local_claims[cntr_local_claims_0]));
1890 : }
1891 7756493 : for (cntr_user_claims_0 = 0; cntr_user_claims_0 < (r->num_user_claims); cntr_user_claims_0++) {
1892 0 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->user_claims[cntr_user_claims_0]));
1893 : }
1894 7756493 : for (cntr_device_claims_0 = 0; cntr_device_claims_0 < (r->num_device_claims); cntr_device_claims_0++) {
1895 0 : NDR_CHECK(ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->device_claims[cntr_device_claims_0]));
1896 : }
1897 : }
1898 7742859 : return NDR_ERR_SUCCESS;
1899 : }
1900 :
1901 7606760 : _PUBLIC_ enum ndr_err_code ndr_pull_security_token(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_token *r)
1902 : {
1903 7606760 : uint32_t size_sids_0 = 0;
1904 11407 : uint32_t cntr_sids_0;
1905 7606760 : TALLOC_CTX *_mem_save_sids_0 = NULL;
1906 7606760 : uint32_t size_local_claims_0 = 0;
1907 11407 : uint32_t cntr_local_claims_0;
1908 7606760 : TALLOC_CTX *_mem_save_local_claims_0 = NULL;
1909 7606760 : uint32_t size_user_claims_0 = 0;
1910 11407 : uint32_t cntr_user_claims_0;
1911 7606760 : TALLOC_CTX *_mem_save_user_claims_0 = NULL;
1912 7606760 : uint32_t size_device_claims_0 = 0;
1913 11407 : uint32_t cntr_device_claims_0;
1914 7606760 : TALLOC_CTX *_mem_save_device_claims_0 = NULL;
1915 7606760 : uint32_t size_device_sids_0 = 0;
1916 11407 : uint32_t cntr_device_sids_0;
1917 7606760 : TALLOC_CTX *_mem_save_device_sids_0 = NULL;
1918 7606760 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
1919 7606760 : if (ndr_flags & NDR_SCALARS) {
1920 7606760 : NDR_CHECK(ndr_pull_align(ndr, 8));
1921 7606760 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_sids));
1922 7606760 : NDR_CHECK(ndr_pull_array_size(ndr, &r->sids));
1923 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->sids, &size_sids_0));
1924 7606760 : NDR_PULL_ALLOC_N(ndr, r->sids, size_sids_0);
1925 7606760 : _mem_save_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1926 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->sids, 0);
1927 59067026 : for (cntr_sids_0 = 0; cntr_sids_0 < (size_sids_0); cntr_sids_0++) {
1928 51460266 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->sids[cntr_sids_0]));
1929 : }
1930 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_sids_0, 0);
1931 7618167 : NDR_CHECK(ndr_pull_se_privilege(ndr, NDR_SCALARS, &r->privilege_mask));
1932 7618167 : NDR_CHECK(ndr_pull_lsa_SystemAccessModeFlags(ndr, NDR_SCALARS, &r->rights_mask));
1933 7606760 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_local_claims));
1934 7606760 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_user_claims));
1935 7606760 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_device_claims));
1936 7606760 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_device_sids));
1937 7606760 : NDR_CHECK(ndr_pull_array_size(ndr, &r->local_claims));
1938 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->local_claims, &size_local_claims_0));
1939 7606760 : NDR_PULL_ALLOC_N(ndr, r->local_claims, size_local_claims_0);
1940 7606760 : _mem_save_local_claims_0 = NDR_PULL_GET_MEM_CTX(ndr);
1941 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->local_claims, 0);
1942 7606760 : for (cntr_local_claims_0 = 0; cntr_local_claims_0 < (size_local_claims_0); cntr_local_claims_0++) {
1943 0 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->local_claims[cntr_local_claims_0]));
1944 : }
1945 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_local_claims_0, 0);
1946 7606760 : NDR_CHECK(ndr_pull_array_size(ndr, &r->user_claims));
1947 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->user_claims, &size_user_claims_0));
1948 7606760 : NDR_PULL_ALLOC_N(ndr, r->user_claims, size_user_claims_0);
1949 7606760 : _mem_save_user_claims_0 = NDR_PULL_GET_MEM_CTX(ndr);
1950 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->user_claims, 0);
1951 7606760 : for (cntr_user_claims_0 = 0; cntr_user_claims_0 < (size_user_claims_0); cntr_user_claims_0++) {
1952 0 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->user_claims[cntr_user_claims_0]));
1953 : }
1954 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_claims_0, 0);
1955 7606760 : NDR_CHECK(ndr_pull_array_size(ndr, &r->device_claims));
1956 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->device_claims, &size_device_claims_0));
1957 7606760 : NDR_PULL_ALLOC_N(ndr, r->device_claims, size_device_claims_0);
1958 7606760 : _mem_save_device_claims_0 = NDR_PULL_GET_MEM_CTX(ndr);
1959 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->device_claims, 0);
1960 7606760 : for (cntr_device_claims_0 = 0; cntr_device_claims_0 < (size_device_claims_0); cntr_device_claims_0++) {
1961 0 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_SCALARS, &r->device_claims[cntr_device_claims_0]));
1962 : }
1963 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_device_claims_0, 0);
1964 7606760 : NDR_CHECK(ndr_pull_array_size(ndr, &r->device_sids));
1965 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->device_sids, &size_device_sids_0));
1966 7606760 : NDR_PULL_ALLOC_N(ndr, r->device_sids, size_device_sids_0);
1967 7606760 : _mem_save_device_sids_0 = NDR_PULL_GET_MEM_CTX(ndr);
1968 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->device_sids, 0);
1969 7606760 : for (cntr_device_sids_0 = 0; cntr_device_sids_0 < (size_device_sids_0); cntr_device_sids_0++) {
1970 0 : NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, &r->device_sids[cntr_device_sids_0]));
1971 : }
1972 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_device_sids_0, 0);
1973 7618167 : NDR_CHECK(ndr_pull_claims_evaluation_control(ndr, NDR_SCALARS, &r->evaluate_claims));
1974 7606760 : if (r->sids) {
1975 7606760 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->sids, r->num_sids));
1976 : }
1977 7606760 : if (r->local_claims) {
1978 7606760 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->local_claims, r->num_local_claims));
1979 : }
1980 7606760 : if (r->user_claims) {
1981 7606760 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->user_claims, r->num_user_claims));
1982 : }
1983 7606760 : if (r->device_claims) {
1984 7606760 : NDR_CHECK(ndr_check_array_size(ndr, (void*)&r->device_claims, r->num_device_claims));
1985 : }
1986 7606760 : if (r->device_sids) {
1987 7606760 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->device_sids, r->num_device_sids));
1988 : }
1989 7606760 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
1990 : }
1991 7606760 : if (ndr_flags & NDR_BUFFERS) {
1992 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->local_claims, &size_local_claims_0));
1993 7606760 : _mem_save_local_claims_0 = NDR_PULL_GET_MEM_CTX(ndr);
1994 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->local_claims, 0);
1995 7606760 : for (cntr_local_claims_0 = 0; cntr_local_claims_0 < (size_local_claims_0); cntr_local_claims_0++) {
1996 0 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->local_claims[cntr_local_claims_0]));
1997 : }
1998 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_local_claims_0, 0);
1999 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->user_claims, &size_user_claims_0));
2000 7606760 : _mem_save_user_claims_0 = NDR_PULL_GET_MEM_CTX(ndr);
2001 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->user_claims, 0);
2002 7606760 : for (cntr_user_claims_0 = 0; cntr_user_claims_0 < (size_user_claims_0); cntr_user_claims_0++) {
2003 0 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->user_claims[cntr_user_claims_0]));
2004 : }
2005 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_user_claims_0, 0);
2006 7606760 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->device_claims, &size_device_claims_0));
2007 7606760 : _mem_save_device_claims_0 = NDR_PULL_GET_MEM_CTX(ndr);
2008 7606760 : NDR_PULL_SET_MEM_CTX(ndr, r->device_claims, 0);
2009 7606760 : for (cntr_device_claims_0 = 0; cntr_device_claims_0 < (size_device_claims_0); cntr_device_claims_0++) {
2010 0 : NDR_CHECK(ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, NDR_BUFFERS, &r->device_claims[cntr_device_claims_0]));
2011 : }
2012 7606760 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_device_claims_0, 0);
2013 7606760 : for (cntr_local_claims_0 = 0; cntr_local_claims_0 < (size_local_claims_0); cntr_local_claims_0++) {
2014 0 : }
2015 7606760 : for (cntr_user_claims_0 = 0; cntr_user_claims_0 < (size_user_claims_0); cntr_user_claims_0++) {
2016 0 : }
2017 7595353 : for (cntr_device_claims_0 = 0; cntr_device_claims_0 < (size_device_claims_0); cntr_device_claims_0++) {
2018 : }
2019 : }
2020 7595353 : return NDR_ERR_SUCCESS;
2021 : }
2022 :
2023 0 : static void ndr_print_flags_security_token(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct security_token *r)
2024 : {
2025 0 : ndr_print_security_token(ndr, name, r);
2026 0 : }
2027 :
2028 0 : _PUBLIC_ void ndr_print_security_token(struct ndr_print *ndr, const char *name, const struct security_token *r)
2029 : {
2030 0 : uint32_t cntr_sids_0;
2031 0 : uint32_t cntr_local_claims_0;
2032 0 : uint32_t cntr_user_claims_0;
2033 0 : uint32_t cntr_device_claims_0;
2034 0 : uint32_t cntr_device_sids_0;
2035 0 : ndr_print_struct(ndr, name, "security_token");
2036 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2037 0 : ndr->depth++;
2038 0 : ndr_print_uint32(ndr, "num_sids", r->num_sids);
2039 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "sids", (uint32_t)(r->num_sids));
2040 0 : ndr->depth++;
2041 0 : for (cntr_sids_0 = 0; cntr_sids_0 < (r->num_sids); cntr_sids_0++) {
2042 0 : ndr_print_dom_sid(ndr, "sids", &r->sids[cntr_sids_0]);
2043 : }
2044 0 : ndr->depth--;
2045 0 : ndr_print_se_privilege(ndr, "privilege_mask", r->privilege_mask);
2046 0 : ndr_print_lsa_SystemAccessModeFlags(ndr, "rights_mask", r->rights_mask);
2047 0 : ndr_print_uint32(ndr, "num_local_claims", r->num_local_claims);
2048 0 : ndr_print_uint32(ndr, "num_user_claims", r->num_user_claims);
2049 0 : ndr_print_uint32(ndr, "num_device_claims", r->num_device_claims);
2050 0 : ndr_print_uint32(ndr, "num_device_sids", r->num_device_sids);
2051 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "local_claims", (uint32_t)(r->num_local_claims));
2052 0 : ndr->depth++;
2053 0 : for (cntr_local_claims_0 = 0; cntr_local_claims_0 < (r->num_local_claims); cntr_local_claims_0++) {
2054 0 : ndr_print_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, "local_claims", &r->local_claims[cntr_local_claims_0]);
2055 : }
2056 0 : ndr->depth--;
2057 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "user_claims", (uint32_t)(r->num_user_claims));
2058 0 : ndr->depth++;
2059 0 : for (cntr_user_claims_0 = 0; cntr_user_claims_0 < (r->num_user_claims); cntr_user_claims_0++) {
2060 0 : ndr_print_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, "user_claims", &r->user_claims[cntr_user_claims_0]);
2061 : }
2062 0 : ndr->depth--;
2063 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "device_claims", (uint32_t)(r->num_device_claims));
2064 0 : ndr->depth++;
2065 0 : for (cntr_device_claims_0 = 0; cntr_device_claims_0 < (r->num_device_claims); cntr_device_claims_0++) {
2066 0 : ndr_print_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1(ndr, "device_claims", &r->device_claims[cntr_device_claims_0]);
2067 : }
2068 0 : ndr->depth--;
2069 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "device_sids", (uint32_t)(r->num_device_sids));
2070 0 : ndr->depth++;
2071 0 : for (cntr_device_sids_0 = 0; cntr_device_sids_0 < (r->num_device_sids); cntr_device_sids_0++) {
2072 0 : ndr_print_dom_sid(ndr, "device_sids", &r->device_sids[cntr_device_sids_0]);
2073 : }
2074 0 : ndr->depth--;
2075 0 : ndr_print_claims_evaluation_control(ndr, "evaluate_claims", r->evaluate_claims);
2076 0 : ndr->depth--;
2077 : }
2078 :
2079 0 : _PUBLIC_ enum ndr_err_code ndr_push_security_token_descriptor_fuzzing_pair(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_token_descriptor_fuzzing_pair *r)
2080 : {
2081 0 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2082 0 : if (ndr_flags & NDR_SCALARS) {
2083 0 : NDR_CHECK(ndr_push_align(ndr, 8));
2084 0 : NDR_CHECK(ndr_push_security_token(ndr, NDR_SCALARS, &r->token));
2085 0 : NDR_CHECK(ndr_push_security_descriptor(ndr, NDR_SCALARS, &r->sd));
2086 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->access_desired));
2087 0 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
2088 : }
2089 0 : if (ndr_flags & NDR_BUFFERS) {
2090 0 : NDR_CHECK(ndr_push_security_token(ndr, NDR_BUFFERS, &r->token));
2091 0 : NDR_CHECK(ndr_push_security_descriptor(ndr, NDR_BUFFERS, &r->sd));
2092 : }
2093 0 : return NDR_ERR_SUCCESS;
2094 : }
2095 :
2096 0 : _PUBLIC_ enum ndr_err_code ndr_pull_security_token_descriptor_fuzzing_pair(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_token_descriptor_fuzzing_pair *r)
2097 : {
2098 0 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2099 0 : if (ndr_flags & NDR_SCALARS) {
2100 0 : NDR_CHECK(ndr_pull_align(ndr, 8));
2101 0 : NDR_CHECK(ndr_pull_security_token(ndr, NDR_SCALARS, &r->token));
2102 0 : NDR_CHECK(ndr_pull_security_descriptor(ndr, NDR_SCALARS, &r->sd));
2103 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->access_desired));
2104 0 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
2105 : }
2106 0 : if (ndr_flags & NDR_BUFFERS) {
2107 0 : NDR_CHECK(ndr_pull_security_token(ndr, NDR_BUFFERS, &r->token));
2108 0 : NDR_CHECK(ndr_pull_security_descriptor(ndr, NDR_BUFFERS, &r->sd));
2109 : }
2110 0 : return NDR_ERR_SUCCESS;
2111 : }
2112 :
2113 0 : static void ndr_print_flags_security_token_descriptor_fuzzing_pair(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct security_token_descriptor_fuzzing_pair *r)
2114 : {
2115 0 : ndr_print_security_token_descriptor_fuzzing_pair(ndr, name, r);
2116 0 : }
2117 :
2118 0 : _PUBLIC_ void ndr_print_security_token_descriptor_fuzzing_pair(struct ndr_print *ndr, const char *name, const struct security_token_descriptor_fuzzing_pair *r)
2119 : {
2120 0 : ndr_print_struct(ndr, name, "security_token_descriptor_fuzzing_pair");
2121 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2122 0 : ndr->depth++;
2123 0 : ndr_print_security_token(ndr, "token", &r->token);
2124 0 : ndr_print_security_descriptor(ndr, "sd", &r->sd);
2125 0 : ndr_print_uint32(ndr, "access_desired", r->access_desired);
2126 0 : ndr->depth--;
2127 : }
2128 :
2129 425097 : _PUBLIC_ enum ndr_err_code ndr_push_security_unix_token(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct security_unix_token *r)
2130 : {
2131 5812 : uint32_t cntr_groups_0;
2132 425097 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2133 425097 : if (ndr_flags & NDR_SCALARS) {
2134 425097 : NDR_CHECK(ndr_push_uint3264(ndr, NDR_SCALARS, r->ngroups));
2135 425097 : NDR_CHECK(ndr_push_align(ndr, 8));
2136 425097 : NDR_CHECK(ndr_push_uid_t(ndr, NDR_SCALARS, r->uid));
2137 425097 : NDR_CHECK(ndr_push_gid_t(ndr, NDR_SCALARS, r->gid));
2138 425097 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->ngroups));
2139 2507249 : for (cntr_groups_0 = 0; cntr_groups_0 < (r->ngroups); cntr_groups_0++) {
2140 2082152 : NDR_CHECK(ndr_push_gid_t(ndr, NDR_SCALARS, r->groups[cntr_groups_0]));
2141 : }
2142 425097 : NDR_CHECK(ndr_push_trailer_align(ndr, 8));
2143 : }
2144 425097 : if (ndr_flags & NDR_BUFFERS) {
2145 5812 : }
2146 425097 : return NDR_ERR_SUCCESS;
2147 : }
2148 :
2149 275557 : _PUBLIC_ enum ndr_err_code ndr_pull_security_unix_token(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct security_unix_token *r)
2150 : {
2151 275557 : uint32_t size_groups_0 = 0;
2152 3585 : uint32_t cntr_groups_0;
2153 275557 : TALLOC_CTX *_mem_save_groups_0 = NULL;
2154 275557 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2155 275557 : if (ndr_flags & NDR_SCALARS) {
2156 275557 : NDR_CHECK(ndr_pull_array_size(ndr, &r->groups));
2157 275557 : NDR_CHECK(ndr_pull_align(ndr, 8));
2158 275557 : NDR_CHECK(ndr_pull_uid_t(ndr, NDR_SCALARS, &r->uid));
2159 275557 : NDR_CHECK(ndr_pull_gid_t(ndr, NDR_SCALARS, &r->gid));
2160 275557 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->ngroups));
2161 275557 : NDR_CHECK(ndr_get_array_size(ndr, (void*)&r->groups, &size_groups_0));
2162 275557 : NDR_PULL_ALLOC_N(ndr, r->groups, size_groups_0);
2163 275557 : _mem_save_groups_0 = NDR_PULL_GET_MEM_CTX(ndr);
2164 275557 : NDR_PULL_SET_MEM_CTX(ndr, r->groups, 0);
2165 1419772 : for (cntr_groups_0 = 0; cntr_groups_0 < (size_groups_0); cntr_groups_0++) {
2166 1144215 : NDR_CHECK(ndr_pull_gid_t(ndr, NDR_SCALARS, &r->groups[cntr_groups_0]));
2167 : }
2168 275557 : NDR_PULL_SET_MEM_CTX(ndr, _mem_save_groups_0, 0);
2169 275557 : if (r->groups) {
2170 275557 : NDR_CHECK(ndr_check_steal_array_size(ndr, (void*)&r->groups, r->ngroups));
2171 : }
2172 275557 : NDR_CHECK(ndr_pull_trailer_align(ndr, 8));
2173 : }
2174 275557 : if (ndr_flags & NDR_BUFFERS) {
2175 3585 : }
2176 275557 : return NDR_ERR_SUCCESS;
2177 : }
2178 :
2179 0 : static void ndr_print_flags_security_unix_token(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct security_unix_token *r)
2180 : {
2181 0 : ndr_print_security_unix_token(ndr, name, r);
2182 0 : }
2183 :
2184 0 : _PUBLIC_ void ndr_print_security_unix_token(struct ndr_print *ndr, const char *name, const struct security_unix_token *r)
2185 : {
2186 0 : uint32_t cntr_groups_0;
2187 0 : ndr_print_struct(ndr, name, "security_unix_token");
2188 0 : if (r == NULL) { ndr_print_null(ndr); return; }
2189 0 : ndr->depth++;
2190 0 : ndr_print_uid_t(ndr, "uid", r->uid);
2191 0 : ndr_print_gid_t(ndr, "gid", r->gid);
2192 0 : ndr_print_uint32(ndr, "ngroups", r->ngroups);
2193 0 : ndr->print(ndr, "%s: ARRAY(%"PRIu32")", "groups", (uint32_t)(r->ngroups));
2194 0 : ndr->depth++;
2195 0 : for (cntr_groups_0 = 0; cntr_groups_0 < (r->ngroups); cntr_groups_0++) {
2196 0 : ndr_print_gid_t(ndr, "groups", r->groups[cntr_groups_0]);
2197 : }
2198 0 : ndr->depth--;
2199 0 : ndr->depth--;
2200 : }
2201 :
2202 434 : _PUBLIC_ enum ndr_err_code ndr_push_security_secinfo(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
2203 : {
2204 434 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
2205 418 : return NDR_ERR_SUCCESS;
2206 : }
2207 :
2208 410 : _PUBLIC_ enum ndr_err_code ndr_pull_security_secinfo(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
2209 : {
2210 16 : uint32_t v;
2211 410 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
2212 410 : *r = v;
2213 410 : return NDR_ERR_SUCCESS;
2214 : }
2215 :
2216 0 : _PUBLIC_ void ndr_print_security_secinfo(struct ndr_print *ndr, const char *name, uint32_t r)
2217 : {
2218 0 : ndr_print_uint32(ndr, name, r);
2219 0 : ndr->depth++;
2220 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_OWNER", SECINFO_OWNER, r);
2221 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_GROUP", SECINFO_GROUP, r);
2222 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_DACL", SECINFO_DACL, r);
2223 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_SACL", SECINFO_SACL, r);
2224 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_LABEL", SECINFO_LABEL, r);
2225 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_ATTRIBUTE", SECINFO_ATTRIBUTE, r);
2226 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_SCOPE", SECINFO_SCOPE, r);
2227 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_BACKUP", SECINFO_BACKUP, r);
2228 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_UNPROTECTED_SACL", SECINFO_UNPROTECTED_SACL, r);
2229 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_UNPROTECTED_DACL", SECINFO_UNPROTECTED_DACL, r);
2230 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_PROTECTED_SACL", SECINFO_PROTECTED_SACL, r);
2231 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SECINFO_PROTECTED_DACL", SECINFO_PROTECTED_DACL, r);
2232 0 : ndr->depth--;
2233 0 : }
2234 :
2235 292400 : _PUBLIC_ enum ndr_err_code ndr_push_LSAP_TOKEN_INFO_INTEGRITY(struct ndr_push *ndr, ndr_flags_type ndr_flags, const struct LSAP_TOKEN_INFO_INTEGRITY *r)
2236 : {
2237 : {
2238 292400 : libndr_flags _flags_save_STRUCT = ndr->flags;
2239 292400 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2240 292400 : NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags);
2241 292400 : if (ndr_flags & NDR_SCALARS) {
2242 292400 : NDR_CHECK(ndr_push_align(ndr, 4));
2243 292400 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->Flags));
2244 292400 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->TokenIL));
2245 292400 : NDR_CHECK(ndr_push_array_uint8(ndr, NDR_SCALARS, r->MachineId, 32));
2246 292400 : NDR_CHECK(ndr_push_trailer_align(ndr, 4));
2247 : }
2248 292400 : if (ndr_flags & NDR_BUFFERS) {
2249 1104 : }
2250 292400 : ndr->flags = _flags_save_STRUCT;
2251 : }
2252 292400 : return NDR_ERR_SUCCESS;
2253 : }
2254 :
2255 35976 : _PUBLIC_ enum ndr_err_code ndr_pull_LSAP_TOKEN_INFO_INTEGRITY(struct ndr_pull *ndr, ndr_flags_type ndr_flags, struct LSAP_TOKEN_INFO_INTEGRITY *r)
2256 : {
2257 35976 : uint32_t size_MachineId_0 = 0;
2258 : {
2259 35976 : libndr_flags _flags_save_STRUCT = ndr->flags;
2260 35976 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2261 35976 : NDR_PULL_CHECK_FLAGS(ndr, ndr_flags);
2262 35976 : if (ndr_flags & NDR_SCALARS) {
2263 35976 : NDR_CHECK(ndr_pull_align(ndr, 4));
2264 35976 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->Flags));
2265 35976 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->TokenIL));
2266 35976 : size_MachineId_0 = 32;
2267 35976 : NDR_CHECK(ndr_pull_array_uint8(ndr, NDR_SCALARS, r->MachineId, size_MachineId_0));
2268 35976 : NDR_CHECK(ndr_pull_trailer_align(ndr, 4));
2269 : }
2270 35976 : if (ndr_flags & NDR_BUFFERS) {
2271 138 : }
2272 35976 : ndr->flags = _flags_save_STRUCT;
2273 : }
2274 35976 : return NDR_ERR_SUCCESS;
2275 : }
2276 :
2277 0 : static void ndr_print_flags_LSAP_TOKEN_INFO_INTEGRITY(struct ndr_print *ndr, const char *name, ndr_flags_type unused, const struct LSAP_TOKEN_INFO_INTEGRITY *r)
2278 : {
2279 0 : ndr_print_LSAP_TOKEN_INFO_INTEGRITY(ndr, name, r);
2280 0 : }
2281 :
2282 4 : _PUBLIC_ void ndr_print_LSAP_TOKEN_INFO_INTEGRITY(struct ndr_print *ndr, const char *name, const struct LSAP_TOKEN_INFO_INTEGRITY *r)
2283 : {
2284 4 : ndr_print_struct(ndr, name, "LSAP_TOKEN_INFO_INTEGRITY");
2285 4 : if (r == NULL) { ndr_print_null(ndr); return; }
2286 : {
2287 4 : libndr_flags _flags_save_STRUCT = ndr->flags;
2288 4 : ndr_set_flags(&ndr->flags, LIBNDR_PRINT_ARRAY_HEX);
2289 4 : ndr->depth++;
2290 4 : ndr_print_uint32(ndr, "Flags", r->Flags);
2291 4 : ndr_print_uint32(ndr, "TokenIL", r->TokenIL);
2292 4 : ndr_print_array_uint8(ndr, "MachineId", r->MachineId, 32);
2293 4 : ndr->depth--;
2294 4 : ndr->flags = _flags_save_STRUCT;
2295 : }
2296 : }
2297 :
2298 146200 : _PUBLIC_ size_t ndr_size_LSAP_TOKEN_INFO_INTEGRITY(const struct LSAP_TOKEN_INFO_INTEGRITY *r, libndr_flags flags)
2299 : {
2300 146200 : flags |= LIBNDR_PRINT_ARRAY_HEX;
2301 146200 : return ndr_size_struct(r, flags, (ndr_push_flags_fn_t)ndr_push_LSAP_TOKEN_INFO_INTEGRITY);
2302 : }
2303 :
2304 1545 : _PUBLIC_ enum ndr_err_code ndr_push_kerb_EncTypes(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
2305 : {
2306 1545 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
2307 1482 : return NDR_ERR_SUCCESS;
2308 : }
2309 :
2310 5655 : _PUBLIC_ enum ndr_err_code ndr_pull_kerb_EncTypes(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
2311 : {
2312 70 : uint32_t v;
2313 5655 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
2314 5655 : *r = v;
2315 5655 : return NDR_ERR_SUCCESS;
2316 : }
2317 :
2318 487 : _PUBLIC_ void ndr_print_kerb_EncTypes(struct ndr_print *ndr, const char *name, uint32_t r)
2319 : {
2320 487 : ndr_print_uint32(ndr, name, r);
2321 487 : ndr->depth++;
2322 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_DES_CBC_CRC", KERB_ENCTYPE_DES_CBC_CRC, r);
2323 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_DES_CBC_MD5", KERB_ENCTYPE_DES_CBC_MD5, r);
2324 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_RC4_HMAC_MD5", KERB_ENCTYPE_RC4_HMAC_MD5, r);
2325 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_AES128_CTS_HMAC_SHA1_96", KERB_ENCTYPE_AES128_CTS_HMAC_SHA1_96, r);
2326 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_AES256_CTS_HMAC_SHA1_96", KERB_ENCTYPE_AES256_CTS_HMAC_SHA1_96, r);
2327 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_AES256_CTS_HMAC_SHA1_96_SK", KERB_ENCTYPE_AES256_CTS_HMAC_SHA1_96_SK, r);
2328 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_FAST_SUPPORTED", KERB_ENCTYPE_FAST_SUPPORTED, r);
2329 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_COMPOUND_IDENTITY_SUPPORTED", KERB_ENCTYPE_COMPOUND_IDENTITY_SUPPORTED, r);
2330 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_CLAIMS_SUPPORTED", KERB_ENCTYPE_CLAIMS_SUPPORTED, r);
2331 487 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "KERB_ENCTYPE_RESOURCE_SID_COMPRESSION_DISABLED", KERB_ENCTYPE_RESOURCE_SID_COMPRESSION_DISABLED, r);
2332 487 : ndr->depth--;
2333 487 : }
2334 :
2335 0 : _PUBLIC_ enum ndr_err_code ndr_push_security_autoinherit(struct ndr_push *ndr, ndr_flags_type ndr_flags, uint32_t r)
2336 : {
2337 0 : NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r));
2338 0 : return NDR_ERR_SUCCESS;
2339 : }
2340 :
2341 0 : _PUBLIC_ enum ndr_err_code ndr_pull_security_autoinherit(struct ndr_pull *ndr, ndr_flags_type ndr_flags, uint32_t *r)
2342 : {
2343 0 : uint32_t v;
2344 0 : NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &v));
2345 0 : *r = v;
2346 0 : return NDR_ERR_SUCCESS;
2347 : }
2348 :
2349 0 : _PUBLIC_ void ndr_print_security_autoinherit(struct ndr_print *ndr, const char *name, uint32_t r)
2350 : {
2351 0 : ndr_print_uint32(ndr, name, r);
2352 0 : ndr->depth++;
2353 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SEC_DACL_AUTO_INHERIT", SEC_DACL_AUTO_INHERIT, r);
2354 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SEC_SACL_AUTO_INHERIT", SEC_SACL_AUTO_INHERIT, r);
2355 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SEC_DEFAULT_DESCRIPTOR", SEC_DEFAULT_DESCRIPTOR, r);
2356 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SEC_OWNER_FROM_PARENT", SEC_OWNER_FROM_PARENT, r);
2357 0 : ndr_print_bitmap_flag(ndr, sizeof(uint32_t), "SEC_GROUP_FROM_PARENT", SEC_GROUP_FROM_PARENT, r);
2358 0 : ndr->depth--;
2359 0 : }
2360 :
2361 : #ifndef SKIP_NDR_TABLE_security
2362 : static const struct ndr_interface_public_struct security_public_structs[] = {
2363 : {
2364 : .name = "dom_sid",
2365 : .struct_size = sizeof(struct dom_sid ),
2366 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_dom_sid,
2367 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_dom_sid,
2368 : .ndr_print = (ndr_print_function_t) ndr_print_flags_dom_sid,
2369 : },
2370 : {
2371 : .name = "CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1",
2372 : .struct_size = sizeof(struct CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1 ),
2373 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1,
2374 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1,
2375 : .ndr_print = (ndr_print_function_t) ndr_print_flags_CLAIM_SECURITY_ATTRIBUTE_RELATIVE_V1,
2376 : },
2377 : {
2378 : .name = "security_ace",
2379 : .struct_size = sizeof(struct security_ace ),
2380 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_security_ace,
2381 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_security_ace,
2382 : .ndr_print = (ndr_print_function_t) ndr_print_flags_security_ace,
2383 : },
2384 : {
2385 : .name = "security_acl",
2386 : .struct_size = sizeof(struct security_acl ),
2387 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_security_acl,
2388 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_security_acl,
2389 : .ndr_print = (ndr_print_function_t) ndr_print_flags_security_acl,
2390 : },
2391 : {
2392 : .name = "security_descriptor",
2393 : .struct_size = sizeof(struct security_descriptor ),
2394 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_security_descriptor,
2395 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_security_descriptor,
2396 : .ndr_print = (ndr_print_function_t) ndr_print_flags_security_descriptor,
2397 : },
2398 : {
2399 : .name = "sec_desc_buf",
2400 : .struct_size = sizeof(struct sec_desc_buf ),
2401 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_sec_desc_buf,
2402 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_sec_desc_buf,
2403 : .ndr_print = (ndr_print_function_t) ndr_print_flags_sec_desc_buf,
2404 : },
2405 : {
2406 : .name = "security_token",
2407 : .struct_size = sizeof(struct security_token ),
2408 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_security_token,
2409 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_security_token,
2410 : .ndr_print = (ndr_print_function_t) ndr_print_flags_security_token,
2411 : },
2412 : {
2413 : .name = "security_token_descriptor_fuzzing_pair",
2414 : .struct_size = sizeof(struct security_token_descriptor_fuzzing_pair ),
2415 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_security_token_descriptor_fuzzing_pair,
2416 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_security_token_descriptor_fuzzing_pair,
2417 : .ndr_print = (ndr_print_function_t) ndr_print_flags_security_token_descriptor_fuzzing_pair,
2418 : },
2419 : {
2420 : .name = "security_unix_token",
2421 : .struct_size = sizeof(struct security_unix_token ),
2422 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_security_unix_token,
2423 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_security_unix_token,
2424 : .ndr_print = (ndr_print_function_t) ndr_print_flags_security_unix_token,
2425 : },
2426 : {
2427 : .name = "LSAP_TOKEN_INFO_INTEGRITY",
2428 : .struct_size = sizeof(struct LSAP_TOKEN_INFO_INTEGRITY ),
2429 : .ndr_push = (ndr_push_flags_fn_t) ndr_push_LSAP_TOKEN_INFO_INTEGRITY,
2430 : .ndr_pull = (ndr_pull_flags_fn_t) ndr_pull_LSAP_TOKEN_INFO_INTEGRITY,
2431 : .ndr_print = (ndr_print_function_t) ndr_print_flags_LSAP_TOKEN_INFO_INTEGRITY,
2432 : },
2433 : { .name = NULL }
2434 : };
2435 :
2436 : static const struct ndr_interface_call security_calls[] = {
2437 : { .name = NULL }
2438 : };
2439 :
2440 : static const char * const security_endpoint_strings[] = {
2441 : "ncacn_np:[\\pipe\\security]",
2442 : };
2443 :
2444 : static const struct ndr_interface_string_array security_endpoints = {
2445 : .count = 1,
2446 : .names = security_endpoint_strings
2447 : };
2448 :
2449 : static const char * const security_authservice_strings[] = {
2450 : "host",
2451 : };
2452 :
2453 : static const struct ndr_interface_string_array security_authservices = {
2454 : .count = 1,
2455 : .names = security_authservice_strings
2456 : };
2457 :
2458 :
2459 : const struct ndr_interface_table ndr_table_security = {
2460 : .name = "security",
2461 : .syntax_id = {
2462 : {0xcbf7d408,0x2d6c,0x11e2,{0xae,0x5b},{0x0b,0x56,0x92,0x79,0x0e,0x18}},
2463 : NDR_SECURITY_VERSION
2464 : },
2465 : .helpstring = NDR_SECURITY_HELPSTRING,
2466 : .num_calls = 0,
2467 : .calls = security_calls,
2468 : .num_public_structs = 10,
2469 : .public_structs = security_public_structs,
2470 : .endpoints = &security_endpoints,
2471 : .authservices = &security_authservices
2472 : };
2473 :
2474 : #endif /* SKIP_NDR_TABLE_security */
|