4 lsa interface definition
7 [ uuid("12345778-1234-abcd-ef00-0123456789ab"),
9 endpoint("ncacn_np:[\\pipe\\lsarpc]","ncacn_np:[\\pipe\\lsass]", "ncacn_ip_tcp:"),
10 pointer_default(unique),
11 helpstring("Local Server Authentication(?)")
17 [in,out,ref] policy_handle *handle
24 [in,ref] policy_handle *handle
32 [value(2*strlen_m(r->name))] uint16 name_len;
33 [value(r->name_len)] uint16 name_size;
45 [size_is(count)] lsa_PrivEntry *privs;
48 NTSTATUS lsa_EnumPrivs (
49 [in,ref] policy_handle *handle,
50 [in,out,ref] uint32 *resume_handle,
51 [in] uint32 max_count,
52 [out,ref] lsa_PrivArray *privs
58 typedef [public] struct {
60 [subcontext(4)] security_descriptor *sd;
63 NTSTATUS lsa_QuerySecObj (
64 [in,ref] policy_handle *handle,
66 [out] sec_desc_buf *sd
72 NTSTATUS lsa_SetSecObj ();
77 NTSTATUS lsa_ChangePassword ();
83 uint32 len; /* ignored */
84 uint16 impersonation_level;
90 uint32 len; /* ignored */
94 security_descriptor *sec_desc;
96 } lsa_ObjectAttribute;
98 /* notice the screwup with the system_name - thats why MS created
100 NTSTATUS lsa_OpenPolicy (
101 [in] uint16 *system_name,
102 [in,ref] lsa_ObjectAttribute *attr,
103 [in] uint32 access_mask,
104 [out,ref] policy_handle *handle
115 NTTIME retention_time;
116 uint8 shutdown_in_progress;
117 NTTIME time_to_shutdown;
118 uint32 next_audit_record;
123 uint32 auditing_mode;
124 [size_is(count)] uint32 *settings;
126 } lsa_AuditEventsInfo;
138 uint16 unknown; /* an midl padding bug? */
145 } lsa_ReplicaSourceInfo;
149 uint32 non_paged_pool;
154 } lsa_DefaultQuotaInfo;
158 NTTIME db_create_time;
159 } lsa_ModificationInfo;
162 uint8 shutdown_on_full;
163 } lsa_AuditFullSetInfo;
166 uint16 unknown; /* an midl padding bug? */
167 uint8 shutdown_on_full;
169 } lsa_AuditFullQueryInfo;
180 LSA_POLICY_INFO_AUDIT_LOG=1,
181 LSA_POLICY_INFO_AUDIT_EVENTS=2,
182 LSA_POLICY_INFO_DOMAIN=3,
183 LSA_POLICY_INFO_PD=4,
184 LSA_POLICY_INFO_ACCOUNT_DOMAIN=5,
185 LSA_POLICY_INFO_ROLE=6,
186 LSA_POLICY_INFO_REPLICA=7,
187 LSA_POLICY_INFO_QUOTA=8,
188 LSA_POLICY_INFO_DB=9,
189 LSA_POLICY_INFO_AUDIT_FULL_SET=10,
190 LSA_POLICY_INFO_AUDIT_FULL_QUERY=11,
191 LSA_POLICY_INFO_DNS=12
195 [case(LSA_POLICY_INFO_AUDIT_LOG)] lsa_AuditLogInfo audit_log;
196 [case(LSA_POLICY_INFO_AUDIT_EVENTS)] lsa_AuditEventsInfo audit_events;
197 [case(LSA_POLICY_INFO_DOMAIN)] lsa_DomainInfo domain;
198 [case(LSA_POLICY_INFO_PD)] lsa_PDAccountInfo pd;
199 [case(LSA_POLICY_INFO_ACCOUNT_DOMAIN)] lsa_DomainInfo account_domain;
200 [case(LSA_POLICY_INFO_ROLE)] lsa_ServerRole role;
201 [case(LSA_POLICY_INFO_REPLICA)] lsa_ReplicaSourceInfo replica;
202 [case(LSA_POLICY_INFO_QUOTA)] lsa_DefaultQuotaInfo quota;
203 [case(LSA_POLICY_INFO_DB)] lsa_ModificationInfo db;
204 [case(LSA_POLICY_INFO_AUDIT_FULL_SET)] lsa_AuditFullSetInfo auditfullset;
205 [case(LSA_POLICY_INFO_AUDIT_FULL_QUERY)] lsa_AuditFullQueryInfo auditfullquery;
206 [case(LSA_POLICY_INFO_DNS)] lsa_DnsDomainInfo dns;
207 } lsa_PolicyInformation;
209 NTSTATUS lsa_QueryInfoPolicy (
210 [in,ref] policy_handle *handle,
212 [out,switch_is(level)] lsa_PolicyInformation *info
217 NTSTATUS lsa_SetInfoPolicy ();
221 NTSTATUS lsa_ClearAuditLog ();
225 NTSTATUS lsa_CreateAccount (
226 [in,ref] policy_handle *handle,
227 [in,ref] dom_sid2 *sid,
228 [in] uint32 access_mask,
229 [out,ref] policy_handle *acct_handle
238 typedef [public] struct {
240 [size_is(num_sids)] lsa_SidPtr *sids;
243 NTSTATUS lsa_EnumAccounts (
244 [in,ref] policy_handle *handle,
245 [in,out,ref] uint32 *resume_handle,
246 [in] uint32 num_entries,
247 [out,ref] lsa_SidArray *sids
251 /*************************************************/
257 } lsa_TrustInformation;
259 NTSTATUS lsa_CreateTrustedDomain(
260 [in,ref] policy_handle *handle,
261 [in,ref] lsa_TrustInformation *info,
262 [in] uint32 access_mask,
263 [out,ref] policy_handle *dom_handle
273 } lsa_DomainInformation;
277 [size_is(count)] lsa_DomainInformation *domains;
280 NTSTATUS lsa_EnumTrustDom (
281 [in,ref] policy_handle *handle,
282 [in,out,ref] uint32 *resume_handle,
283 [in] uint32 num_entries,
284 [out,ref] lsa_DomainList *domains
299 [size_is(count)] lsa_TranslatedSid *sids;
304 [size_is(count)] lsa_TrustInformation *domains;
308 NTSTATUS lsa_LookupNames (
309 [in,ref] policy_handle *handle,
310 [in] uint32 num_names,
311 [in,ref,size_is(num_names)] lsa_Name *names,
312 [out] lsa_RefDomainList *domains,
313 [in,out,ref] lsa_TransSidArray *sids,
315 [in,out,ref] uint32 *count
326 } lsa_TranslatedName;
330 [size_is(count)] lsa_TranslatedName *names;
331 } lsa_TransNameArray;
333 NTSTATUS lsa_LookupSids (
334 [in,ref] policy_handle *handle,
335 [in,ref] lsa_SidArray *sids,
336 [out] lsa_RefDomainList *domains,
337 [in,out,ref] lsa_TransNameArray *names,
339 [in,out,ref] uint32 *count
344 NTSTATUS lsa_CreateSecret(
345 [in,ref] policy_handle *handle,
347 [in] uint32 access_mask,
348 [out,ref] policy_handle *sec_handle
352 /*****************************************/
354 NTSTATUS lsa_OpenAccount (
355 [in,ref] policy_handle *handle,
356 [in,ref] dom_sid2 *sid,
357 [in] uint32 access_mask,
358 [out,ref] policy_handle *acct_handle
362 /****************************************/
378 [size_is(count)] lsa_LUIDAttribute set[*];
381 NTSTATUS lsa_EnumPrivsAccount (
382 [in,ref] policy_handle *handle,
383 [out] lsa_PrivilegeSet *privs
388 NTSTATUS lsa_AddPrivilegesToAccount();
391 NTSTATUS lsa_RemovePrivilegesFromAccount();
394 NTSTATUS lsa_GetQuotasForAccount();
397 NTSTATUS lsa_SetQuotasForAccount();
400 NTSTATUS lsa_GetSystemAccessAccount();
402 NTSTATUS lsa_SetSystemAccessAccount();
404 NTSTATUS lsa_OpenTrustedDomain();
406 NTSTATUS lsa_QueryInfoTrustedDomain();
408 NTSTATUS lsa_SetInformationTrustedDomain();
411 NTSTATUS lsa_OpenSecret(
412 [in,ref] policy_handle *handle,
414 [in] uint32 access_mask,
415 [out,ref] policy_handle *sec_handle
419 typedef [flag(NDR_PAHEX)] struct {
422 [size_is(size),length_is(length)] uint8 *data;
425 NTSTATUS lsa_SetSecret(
426 [in,ref] policy_handle *handle,
427 [in] lsa_DATA_BUF *new_val,
428 [in] lsa_DATA_BUF *old_val
436 NTSTATUS lsa_QuerySecret (
437 [in,ref] policy_handle *handle,
438 [in,out] lsa_DATA_BUF_PTR *new_val,
439 [in,out] NTTIME *new_mtime,
440 [in,out] lsa_DATA_BUF_PTR *old_val,
441 [in,out] NTTIME *old_mtime
445 NTSTATUS lsa_LookupPrivValue();
449 NTSTATUS lsa_LookupPrivName (
450 [in,ref] policy_handle *handle,
451 [in,ref] lsa_LUID *luid,
456 /*******************/
458 NTSTATUS lsa_LookupPrivDisplayName (
459 [in,ref] policy_handle *handle,
460 [in,ref] lsa_Name *name,
461 [out] lsa_Name *disp_name,
462 /* see http://www.microsoft.com/globaldev/nlsweb/ for
463 language definitions */
464 [in,out,ref] uint16 *language_id,
469 NTSTATUS lsa_DeleteObject();
472 /*******************/
474 NTSTATUS lsa_EnumAccountsWithUserRight (
475 [in,ref] policy_handle *handle,
477 [out,ref] lsa_SidArray *sids
483 } lsa_RightAttribute;
487 [size_is(count)] lsa_Name *names;
490 NTSTATUS lsa_EnumAccountRights (
491 [in,ref] policy_handle *handle,
492 [in,ref] dom_sid2 *sid,
493 [out,ref] lsa_RightSet *rights
497 /**********************/
499 NTSTATUS lsa_AddAccountRights (
500 [in,ref] policy_handle *handle,
501 [in,ref] dom_sid2 *sid,
502 [in,ref] lsa_RightSet *rights
505 /**********************/
507 NTSTATUS lsa_RemoveAccountRights (
508 [in,ref] policy_handle *handle,
509 [in,ref] dom_sid2 *sid,
511 [in,ref] lsa_RightSet *rights
515 NTSTATUS lsa_QueryTrustDomainInfo();
517 NTSTATUS lsa_SetTrustDomainInfo();
519 NTSTATUS lsa_DeleteTrustDomain();
521 NTSTATUS lsa_StorePrivateData();
523 NTSTATUS lsa_RetrievePrivateData();
526 /**********************/
528 NTSTATUS lsa_OpenPolicy2 (
529 [in] unistr *system_name,
530 [in,ref] lsa_ObjectAttribute *attr,
531 [in] uint32 access_mask,
532 [out,ref] policy_handle *handle
537 NTSTATUS lsa_GetUserName();
539 /**********************/
542 NTSTATUS lsa_QueryInfoPolicy2(
543 [in,ref] policy_handle *handle,
545 [out,switch_is(level)] lsa_PolicyInformation *info
549 NTSTATUS lsa_SetInfoPolicy2();
552 NTSTATUS lsa_QueryTrustedDomainInfoByName();
555 NTSTATUS lsa_SetTrustedDomainInfoByName();
558 NTSTATUS lsa_EnumTrustedDomainsEx();
561 NTSTATUS lsa_CreateTrustedDomainEx();
564 NTSTATUS lsa_CloseTrustedDomainEx();
567 NTSTATUS lsa_QueryDomainInformationPolicy();
570 NTSTATUS lsa_SetDomInfoPolicy();
573 NTSTATUS lsa_OpenTrustedDomainByName();
576 NTSTATUS lsa_TestCall();
579 NTSTATUS lsa_LookupSids2();
582 NTSTATUS lsa_LookupNames2();
585 NTSTATUS lsa_CreateTrustedDomainEx2();