2003-11-21 16:14:17 +03:00
#include "idl_types.h"
2003-11-06 15:34:04 +03:00
/*
lsa interface definition
*/
2004-10-27 08:48:41 +04:00
[ uuid("12345778-1234-abcd-ef00-0123456789ab"),
2003-11-06 15:34:04 +03:00
version(0.0),
2004-10-24 18:57:16 +04:00
endpoint("ncacn_np:[\\pipe\\lsarpc]","ncacn_np:[\\pipe\\lsass]", "ncacn_ip_tcp:"),
2004-08-16 23:03:22 +04:00
pointer_default(unique),
2004-11-17 17:35:29 +03:00
helpstring("Local Server Authentication(?)"),
depends(security)
2003-11-06 15:34:04 +03:00
] interface lsarpc
{
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x00 */
NTSTATUS lsa_Close (
2003-11-09 14:01:39 +03:00
[in,out,ref] policy_handle *handle
2003-11-09 11:30:29 +03:00
);
2003-11-08 14:21:57 +03:00
2003-11-09 12:04:28 +03:00
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x01 */
2003-11-09 12:44:06 +03:00
NTSTATUS lsa_Delete (
[in,ref] policy_handle *handle
);
2003-11-09 11:30:29 +03:00
2003-11-10 14:37:19 +03:00
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x02 */
2003-11-09 12:44:06 +03:00
typedef struct {
2004-11-22 14:59:59 +03:00
[value(2*strlen_m(r->string))] uint16 length;
[value(r->length)] uint16 size;
unistr_noterm *string;
} lsa_String;
2003-11-09 12:44:06 +03:00
2004-12-14 08:32:51 +03:00
typedef struct {
uint32 low;
uint32 high;
} lsa_LUID;
2003-11-09 12:44:06 +03:00
typedef struct {
2004-11-22 14:59:59 +03:00
lsa_String name;
2004-12-14 08:32:51 +03:00
lsa_LUID luid;
2003-11-09 12:44:06 +03:00
} lsa_PrivEntry;
typedef struct {
uint32 count;
[size_is(count)] lsa_PrivEntry *privs;
} lsa_PrivArray;
NTSTATUS lsa_EnumPrivs (
[in,ref] policy_handle *handle,
[in,out,ref] uint32 *resume_handle,
[in] uint32 max_count,
[out,ref] lsa_PrivArray *privs
);
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x03 */
2003-11-16 09:00:15 +03:00
2004-11-22 11:47:47 +03:00
NTSTATUS lsa_QuerySecurity (
2003-11-15 07:42:48 +03:00
[in,ref] policy_handle *handle,
[in] uint32 sec_info,
2004-11-22 11:47:47 +03:00
[out] sec_desc_buf *sdbuf
2003-11-15 07:42:48 +03:00
);
2003-11-09 11:30:29 +03:00
2003-11-10 14:37:19 +03:00
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x04 */
NTSTATUS lsa_SetSecObj ();
2003-11-10 14:37:19 +03:00
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x05 */
NTSTATUS lsa_ChangePassword ();
/******************/
/* Function: 0x06 */
2003-11-08 14:21:57 +03:00
typedef struct {
2003-11-15 00:39:13 +03:00
uint32 len; /* ignored */
2003-11-08 14:21:57 +03:00
uint16 impersonation_level;
uint8 context_mode;
uint8 effective_only;
} lsa_QosInfo;
typedef struct {
2003-11-15 00:39:13 +03:00
uint32 len; /* ignored */
2003-11-08 14:21:57 +03:00
uint8 *root_dir;
unistr *object_name;
uint32 attributes;
security_descriptor *sec_desc;
lsa_QosInfo *sec_qos;
} lsa_ObjectAttribute;
2003-11-09 12:04:28 +03:00
/* notice the screwup with the system_name - thats why MS created
OpenPolicy2 */
2003-11-08 14:21:57 +03:00
NTSTATUS lsa_OpenPolicy (
[in] uint16 *system_name,
[in,ref] lsa_ObjectAttribute *attr,
2004-05-27 08:13:58 +04:00
[in] uint32 access_mask,
2003-11-08 16:23:20 +03:00
[out,ref] policy_handle *handle
2003-11-08 14:21:57 +03:00
);
2003-11-06 15:34:04 +03:00
2003-11-09 12:04:28 +03:00
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x07 */
2003-11-11 05:02:29 +03:00
typedef struct {
uint32 percent_full;
uint32 log_size;
NTTIME retention_time;
uint8 shutdown_in_progress;
NTTIME time_to_shutdown;
uint32 next_audit_record;
uint32 unknown;
} lsa_AuditLogInfo;
typedef struct {
uint32 auditing_mode;
2003-11-19 08:53:05 +03:00
[size_is(count)] uint32 *settings;
uint32 count;
2003-11-11 05:02:29 +03:00
} lsa_AuditEventsInfo;
2003-11-11 09:54:54 +03:00
typedef struct {
2004-11-22 14:59:59 +03:00
lsa_String name;
2003-11-11 09:54:54 +03:00
dom_sid2 *sid;
2003-11-11 10:57:08 +03:00
} lsa_DomainInfo;
typedef struct {
2004-11-22 14:59:59 +03:00
lsa_String name;
2003-11-11 10:57:08 +03:00
} lsa_PDAccountInfo;
typedef struct {
2003-11-19 10:31:17 +03:00
uint16 unknown; /* an midl padding bug? */
2003-11-11 10:57:08 +03:00
uint16 role;
} lsa_ServerRole;
typedef struct {
2004-11-22 14:59:59 +03:00
lsa_String source;
lsa_String account;
2003-11-11 10:57:08 +03:00
} lsa_ReplicaSourceInfo;
typedef struct {
uint32 paged_pool;
uint32 non_paged_pool;
uint32 min_wss;
uint32 max_wss;
uint32 pagefile;
HYPER_T unknown;
} lsa_DefaultQuotaInfo;
typedef struct {
HYPER_T modified_id;
NTTIME db_create_time;
} lsa_ModificationInfo;
typedef struct {
2003-11-19 10:31:17 +03:00
uint8 shutdown_on_full;
2003-11-11 10:57:08 +03:00
} lsa_AuditFullSetInfo;
typedef struct {
2003-11-19 10:31:17 +03:00
uint16 unknown; /* an midl padding bug? */
uint8 shutdown_on_full;
uint8 log_is_full;
2003-11-11 10:57:08 +03:00
} lsa_AuditFullQueryInfo;
typedef struct {
2004-11-22 14:59:59 +03:00
lsa_String name;
lsa_String dns_domain;
lsa_String dns_forest;
2003-11-11 10:57:08 +03:00
GUID domain_guid;
dom_sid2 *sid;
} lsa_DnsDomainInfo;
2003-11-11 09:54:54 +03:00
2004-03-31 16:52:21 +04:00
typedef enum {
LSA_POLICY_INFO_AUDIT_LOG=1,
LSA_POLICY_INFO_AUDIT_EVENTS=2,
LSA_POLICY_INFO_DOMAIN=3,
LSA_POLICY_INFO_PD=4,
LSA_POLICY_INFO_ACCOUNT_DOMAIN=5,
LSA_POLICY_INFO_ROLE=6,
LSA_POLICY_INFO_REPLICA=7,
LSA_POLICY_INFO_QUOTA=8,
LSA_POLICY_INFO_DB=9,
LSA_POLICY_INFO_AUDIT_FULL_SET=10,
LSA_POLICY_INFO_AUDIT_FULL_QUERY=11,
LSA_POLICY_INFO_DNS=12
} lsaPolicyInfo;
2003-11-11 05:02:29 +03:00
typedef union {
2004-05-27 08:13:58 +04:00
[case(LSA_POLICY_INFO_AUDIT_LOG)] lsa_AuditLogInfo audit_log;
[case(LSA_POLICY_INFO_AUDIT_EVENTS)] lsa_AuditEventsInfo audit_events;
[case(LSA_POLICY_INFO_DOMAIN)] lsa_DomainInfo domain;
[case(LSA_POLICY_INFO_PD)] lsa_PDAccountInfo pd;
[case(LSA_POLICY_INFO_ACCOUNT_DOMAIN)] lsa_DomainInfo account_domain;
[case(LSA_POLICY_INFO_ROLE)] lsa_ServerRole role;
[case(LSA_POLICY_INFO_REPLICA)] lsa_ReplicaSourceInfo replica;
[case(LSA_POLICY_INFO_QUOTA)] lsa_DefaultQuotaInfo quota;
[case(LSA_POLICY_INFO_DB)] lsa_ModificationInfo db;
[case(LSA_POLICY_INFO_AUDIT_FULL_SET)] lsa_AuditFullSetInfo auditfullset;
[case(LSA_POLICY_INFO_AUDIT_FULL_QUERY)] lsa_AuditFullQueryInfo auditfullquery;
[case(LSA_POLICY_INFO_DNS)] lsa_DnsDomainInfo dns;
2003-11-11 05:02:29 +03:00
} lsa_PolicyInformation;
NTSTATUS lsa_QueryInfoPolicy (
[in,ref] policy_handle *handle,
[in] uint16 level,
[out,switch_is(level)] lsa_PolicyInformation *info
);
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x08 */
NTSTATUS lsa_SetInfoPolicy ();
/******************/
/* Function: 0x09 */
NTSTATUS lsa_ClearAuditLog ();
/******************/
/* Function: 0x0a */
2004-03-31 16:52:21 +04:00
NTSTATUS lsa_CreateAccount (
[in,ref] policy_handle *handle,
[in,ref] dom_sid2 *sid,
2004-05-27 08:13:58 +04:00
[in] uint32 access_mask,
2004-03-31 16:52:21 +04:00
[out,ref] policy_handle *acct_handle
);
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x0b */
2003-11-08 14:21:57 +03:00
typedef struct {
dom_sid2 *sid;
} lsa_SidPtr;
2003-12-02 07:33:57 +03:00
typedef [public] struct {
2004-11-18 08:17:24 +03:00
[range(0,1000)] uint32 num_sids;
2003-11-08 14:21:57 +03:00
[size_is(num_sids)] lsa_SidPtr *sids;
} lsa_SidArray;
2003-11-06 15:34:04 +03:00
2003-11-09 11:30:29 +03:00
NTSTATUS lsa_EnumAccounts (
2003-11-08 14:21:57 +03:00
[in,ref] policy_handle *handle,
[in,out,ref] uint32 *resume_handle,
2004-11-18 08:17:24 +03:00
[in,range(0,1000)] uint32 num_entries,
2003-11-08 14:21:57 +03:00
[out,ref] lsa_SidArray *sids
);
2003-11-06 15:34:04 +03:00
2003-11-09 11:30:29 +03:00
/*************************************************/
/* Function: 0x0c */
2004-04-03 20:44:39 +04:00
typedef struct {
2004-11-22 14:59:59 +03:00
lsa_String name;
dom_sid2 *sid;
2004-04-03 20:44:39 +04:00
} lsa_TrustInformation;
NTSTATUS lsa_CreateTrustedDomain(
[in,ref] policy_handle *handle,
[in,ref] lsa_TrustInformation *info,
2004-05-27 08:13:58 +04:00
[in] uint32 access_mask,
2004-04-03 20:44:39 +04:00
[out,ref] policy_handle *dom_handle
);
2003-11-09 11:30:29 +03:00
2003-11-09 13:01:24 +03:00
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x0d */
2003-11-09 13:01:24 +03:00
typedef struct {
2004-11-22 14:59:59 +03:00
lsa_String name;
2003-11-09 13:01:24 +03:00
dom_sid2 *sid;
2003-11-09 14:01:39 +03:00
} lsa_DomainInformation;
2003-11-09 13:01:24 +03:00
typedef struct {
uint32 count;
2003-11-09 14:01:39 +03:00
[size_is(count)] lsa_DomainInformation *domains;
} lsa_DomainList;
2003-11-09 13:01:24 +03:00
NTSTATUS lsa_EnumTrustDom (
[in,ref] policy_handle *handle,
[in,out,ref] uint32 *resume_handle,
2004-11-18 08:17:24 +03:00
[in,range(0,1000)] uint32 num_entries,
2003-11-09 14:01:39 +03:00
[out,ref] lsa_DomainList *domains
2003-11-09 13:01:24 +03:00
);
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x0e */
2003-11-09 03:58:40 +03:00
typedef struct {
uint16 sid_type;
2003-11-09 11:30:29 +03:00
uint32 rid;
2003-11-09 03:58:40 +03:00
uint32 sid_index;
2003-11-09 11:30:29 +03:00
} lsa_TranslatedSid;
2003-11-09 03:58:40 +03:00
typedef struct {
2004-11-18 08:17:24 +03:00
[range(0,1000)] uint32 count;
2003-11-09 11:30:29 +03:00
[size_is(count)] lsa_TranslatedSid *sids;
} lsa_TransSidArray;
2003-11-09 03:58:40 +03:00
2003-11-09 14:01:39 +03:00
typedef struct {
2004-11-18 08:17:24 +03:00
[range(0,1000)] uint32 count;
2003-11-09 14:01:39 +03:00
[size_is(count)] lsa_TrustInformation *domains;
uint32 max_count;
} lsa_RefDomainList;
2003-11-09 11:30:29 +03:00
NTSTATUS lsa_LookupNames (
2003-11-09 03:58:40 +03:00
[in,ref] policy_handle *handle,
2004-11-18 08:17:24 +03:00
[in,range(0,1000)] uint32 num_names,
2004-11-22 14:59:59 +03:00
[in,ref,size_is(num_names)] lsa_String *names,
2003-11-09 03:58:40 +03:00
[out] lsa_RefDomainList *domains,
2003-11-09 11:30:29 +03:00
[in,out,ref] lsa_TransSidArray *sids,
2003-11-09 03:58:40 +03:00
[in] uint16 level,
[in,out,ref] uint32 *count
);
2003-11-09 05:21:24 +03:00
2003-11-09 11:30:29 +03:00
/******************/
/* Function: 0x0f */
2003-11-09 05:21:24 +03:00
typedef struct {
uint16 sid_type;
2004-11-22 14:59:59 +03:00
lsa_String name;
2003-11-09 05:21:24 +03:00
uint32 sid_index;
2003-11-09 11:30:29 +03:00
} lsa_TranslatedName;
2003-11-09 05:21:24 +03:00
typedef struct {
2004-11-18 08:17:24 +03:00
[range(0,1000)] uint32 count;
2003-11-09 11:30:29 +03:00
[size_is(count)] lsa_TranslatedName *names;
} lsa_TransNameArray;
2003-11-09 05:21:24 +03:00
2003-11-09 11:30:29 +03:00
NTSTATUS lsa_LookupSids (
2003-11-09 05:21:24 +03:00
[in,ref] policy_handle *handle,
2003-11-09 11:30:29 +03:00
[in,ref] lsa_SidArray *sids,
2003-11-09 05:21:24 +03:00
[out] lsa_RefDomainList *domains,
2003-11-09 11:30:29 +03:00
[in,out,ref] lsa_TransNameArray *names,
2003-11-09 05:21:24 +03:00
[in] uint16 level,
[in,out,ref] uint32 *count
);
2003-11-09 11:30:29 +03:00
/* Function: 0x10 */
2004-04-03 21:15:32 +04:00
NTSTATUS lsa_CreateSecret(
[in,ref] policy_handle *handle,
2004-11-22 14:59:59 +03:00
[in] lsa_String name,
2004-05-27 08:13:58 +04:00
[in] uint32 access_mask,
2004-04-03 21:15:32 +04:00
[out,ref] policy_handle *sec_handle
);
2003-11-09 14:01:39 +03:00
/*****************************************/
/* Function: 0x11 */
NTSTATUS lsa_OpenAccount (
[in,ref] policy_handle *handle,
[in,ref] dom_sid2 *sid,
2004-05-27 08:13:58 +04:00
[in] uint32 access_mask,
2003-11-09 14:01:39 +03:00
[out,ref] policy_handle *acct_handle
);
2003-11-10 14:37:19 +03:00
/****************************************/
/* Function: 0x12 */
typedef struct {
lsa_LUID luid;
uint32 attribute;
} lsa_LUIDAttribute;
typedef struct {
2004-12-19 10:20:55 +03:00
[range(0,1000)] uint32 count;
2003-11-13 12:26:53 +03:00
uint32 unknown;
2003-11-10 14:37:19 +03:00
[size_is(count)] lsa_LUIDAttribute set[*];
} lsa_PrivilegeSet;
NTSTATUS lsa_EnumPrivsAccount (
[in,ref] policy_handle *handle,
2003-11-12 08:34:21 +03:00
[out] lsa_PrivilegeSet *privs
2003-11-10 14:37:19 +03:00
);
2004-12-19 10:20:55 +03:00
/****************************************/
2003-11-09 11:30:29 +03:00
/* Function: 0x13 */
2004-12-19 10:20:55 +03:00
NTSTATUS lsa_AddPrivilegesToAccount(
[in,ref] policy_handle *handle,
[in,ref] lsa_PrivilegeSet *privs
);
2004-08-13 05:31:11 +04:00
2004-12-19 10:20:55 +03:00
/****************************************/
2003-11-09 11:30:29 +03:00
/* Function: 0x14 */
2004-12-19 10:20:55 +03:00
NTSTATUS lsa_RemovePrivilegesFromAccount(
[in,ref] policy_handle *handle,
[in] uint8 remove_all,
[in] lsa_PrivilegeSet *privs
);
2004-08-13 05:31:11 +04:00
2003-11-09 11:30:29 +03:00
/* Function: 0x15 */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_GetQuotasForAccount();
2003-11-09 11:30:29 +03:00
/* Function: 0x16 */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_SetQuotasForAccount();
2003-11-09 11:30:29 +03:00
/* Function: 0x17 */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_GetSystemAccessAccount();
2003-11-09 11:30:29 +03:00
/* Function: 0x18 */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_SetSystemAccessAccount();
2004-11-22 11:47:47 +03:00
2003-11-09 11:30:29 +03:00
/* Function: 0x19 */
2004-11-22 11:47:47 +03:00
NTSTATUS lsa_OpenTrustedDomain(
[in,ref] policy_handle *handle,
[in,ref] dom_sid2 *sid,
[in] uint32 access_mask,
[out,ref] policy_handle *trustdom_handle
);
2004-11-22 14:59:59 +03:00
typedef [flag(NDR_PAHEX)] struct {
uint32 length;
uint32 size;
[size_is(size),length_is(length)] uint8 *data;
} lsa_DATA_BUF;
2004-11-23 06:11:38 +03:00
typedef [flag(NDR_PAHEX)] struct {
uint32 size;
[size_is(size)] uint8 *data;
} lsa_DATA_BUF2;
typedef enum {
LSA_TRUSTED_DOMAIN_INFO_NAME=1,
LSA_TRUSTED_DOMAIN_INFO_2=2,
LSA_TRUSTED_DOMAIN_INFO_FLAGS=3,
LSA_TRUSTED_DOMAIN_INFO_PASSWORD=4,
LSA_TRUSTED_DOMAIN_INFO_5=5,
LSA_TRUSTED_DOMAIN_INFO_INFO_EX=6,
LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO=7,
LSA_TRUSTED_DOMAIN_INFO_FULL_INFO=8,
LSA_TRUSTED_DOMAIN_INFO_INFO_ALL=12
} lsa_TrustDomInfoEnum;
2004-11-22 14:59:59 +03:00
typedef struct {
2004-11-29 20:51:13 +03:00
lsa_String netbios_name;
2004-11-23 06:11:38 +03:00
} lsa_TrustDomainInfoName;
2004-11-22 14:59:59 +03:00
typedef struct {
uint32 flags;
2004-11-23 06:11:38 +03:00
} lsa_TrustDomainInfoFlags;
typedef struct {
lsa_DATA_BUF *password;
lsa_DATA_BUF *old_password;
} lsa_TrustDomainInfoPassword;
typedef struct {
2004-11-29 20:51:13 +03:00
lsa_String netbios_name;
2004-11-23 06:11:38 +03:00
dom_sid2 *sid;
} lsa_TrustDomainInfo5;
2004-11-22 14:59:59 +03:00
typedef struct {
2004-11-29 20:51:13 +03:00
lsa_String domain_name;
lsa_String netbios_name;
2004-11-22 14:59:59 +03:00
dom_sid2 *sid;
uint32 unknown1;
uint32 unknown2;
uint32 unknown3;
2004-11-23 06:11:38 +03:00
} lsa_TrustDomainInfoInfoEx;
typedef struct {
HYPER_T unknown1;
uint32 unknown2;
lsa_DATA_BUF2 data;
} lsa_TrustDomainInfoBuffer;
typedef struct {
uint32 unknown1;
lsa_TrustDomainInfoBuffer *buff1;
lsa_TrustDomainInfoBuffer *buff2;
uint32 unknown2;
lsa_TrustDomainInfoBuffer *buff3;
lsa_TrustDomainInfoBuffer *buff4;
} lsa_TrustDomainInfoAuthInfo;
typedef struct {
lsa_TrustDomainInfoInfoEx info_ex;
lsa_TrustDomainInfoFlags flags;
lsa_TrustDomainInfoAuthInfo auth_info;
} lsa_TrustDomainInfoFullInfo;
typedef struct {
lsa_TrustDomainInfoInfoEx info_ex;
lsa_DATA_BUF2 data1;
} lsa_TrustDomainInfo11;
typedef struct {
lsa_TrustDomainInfoInfoEx info_ex;
lsa_DATA_BUF2 data1;
lsa_TrustDomainInfoFlags flags;
lsa_TrustDomainInfoAuthInfo auth_info;
} lsa_TrustDomainInfoInfoAll;
2004-11-22 14:59:59 +03:00
typedef union {
2004-11-23 06:11:38 +03:00
[case(LSA_TRUSTED_DOMAIN_INFO_NAME)] lsa_TrustDomainInfoName name;
[case(LSA_TRUSTED_DOMAIN_INFO_FLAGS)] lsa_TrustDomainInfoFlags flags;
[case(LSA_TRUSTED_DOMAIN_INFO_PASSWORD)] lsa_TrustDomainInfoPassword password;
[case(LSA_TRUSTED_DOMAIN_INFO_5)] lsa_TrustDomainInfo5 info5;
[case(LSA_TRUSTED_DOMAIN_INFO_INFO_EX)] lsa_TrustDomainInfoInfoEx info_ex;
[case(LSA_TRUSTED_DOMAIN_INFO_AUTH_INFO)] lsa_TrustDomainInfoAuthInfo auth_info;
[case(LSA_TRUSTED_DOMAIN_INFO_FULL_INFO)] lsa_TrustDomainInfoFullInfo full_info;
[case(11)] lsa_TrustDomainInfo11 info11;
[case(LSA_TRUSTED_DOMAIN_INFO_INFO_ALL)] lsa_TrustDomainInfoInfoAll info_all;
2004-11-22 14:59:59 +03:00
} lsa_TrustedDomainInfo;
2003-11-09 11:30:29 +03:00
/* Function: 0x1a */
2004-11-23 03:31:00 +03:00
NTSTATUS lsa_QueryTrustedDomainInfo(
2004-11-22 14:59:59 +03:00
[in,ref] policy_handle *trustdom_handle,
[in] uint16 level,
[out,switch_is(level)] lsa_TrustedDomainInfo *info
);
2003-11-09 11:30:29 +03:00
/* Function: 0x1b */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_SetInformationTrustedDomain();
2004-04-03 21:21:26 +04:00
2003-11-09 11:30:29 +03:00
/* Function: 0x1c */
2004-04-03 21:21:26 +04:00
NTSTATUS lsa_OpenSecret(
[in,ref] policy_handle *handle,
2004-11-22 14:59:59 +03:00
[in] lsa_String name,
2004-05-27 08:13:58 +04:00
[in] uint32 access_mask,
2004-04-03 21:21:26 +04:00
[out,ref] policy_handle *sec_handle
);
2003-11-09 11:30:29 +03:00
/* Function: 0x1d */
2004-04-07 11:20:53 +04:00
NTSTATUS lsa_SetSecret(
[in,ref] policy_handle *handle,
[in] lsa_DATA_BUF *new_val,
[in] lsa_DATA_BUF *old_val
);
typedef struct {
lsa_DATA_BUF *buf;
} lsa_DATA_BUF_PTR;
2003-11-09 11:30:29 +03:00
/* Function: 0x1e */
2004-04-07 11:20:53 +04:00
NTSTATUS lsa_QuerySecret (
[in,ref] policy_handle *handle,
[in,out] lsa_DATA_BUF_PTR *new_val,
[in,out] NTTIME *new_mtime,
[in,out] lsa_DATA_BUF_PTR *old_val,
[in,out] NTTIME *old_mtime
);
2003-11-10 15:42:45 +03:00
2003-11-09 11:30:29 +03:00
/* Function: 0x1f */
2004-12-14 08:32:51 +03:00
NTSTATUS lsa_LookupPrivValue(
[in,ref] policy_handle *handle,
[in,ref] lsa_String *name,
[out,ref] lsa_LUID *luid
);
2003-11-10 15:42:45 +03:00
2003-11-09 11:30:29 +03:00
/* Function: 0x20 */
2003-11-10 15:42:45 +03:00
NTSTATUS lsa_LookupPrivName (
[in,ref] policy_handle *handle,
2003-11-14 10:56:43 +03:00
[in,ref] lsa_LUID *luid,
2004-11-22 14:59:59 +03:00
[out] lsa_String *name
2003-11-10 15:42:45 +03:00
);
2004-08-31 12:43:28 +04:00
/*******************/
2003-11-09 11:30:29 +03:00
/* Function: 0x21 */
2004-08-31 12:43:28 +04:00
NTSTATUS lsa_LookupPrivDisplayName (
[in,ref] policy_handle *handle,
2004-11-22 14:59:59 +03:00
[in,ref] lsa_String *name,
[out] lsa_String *disp_name,
2004-09-03 09:16:25 +04:00
/* see http://www.microsoft.com/globaldev/nlsweb/ for
language definitions */
[in,out,ref] uint16 *language_id,
[in] uint16 unknown
2004-08-31 12:43:28 +04:00
);
2003-11-09 11:30:29 +03:00
/* Function: 0x22 */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_DeleteObject();
2004-08-31 12:43:28 +04:00
/*******************/
/* Function: 0x23 */
NTSTATUS lsa_EnumAccountsWithUserRight (
[in,ref] policy_handle *handle,
2004-11-22 14:59:59 +03:00
[in] lsa_String *name,
2004-08-31 12:43:28 +04:00
[out,ref] lsa_SidArray *sids
);
2003-11-10 15:12:22 +03:00
2003-11-09 11:30:29 +03:00
/* Function: 0x24 */
2003-11-10 15:12:22 +03:00
typedef struct {
unistr *name;
} lsa_RightAttribute;
typedef struct {
uint32 count;
2004-11-22 14:59:59 +03:00
[size_is(count)] lsa_String *names;
2003-11-10 15:12:22 +03:00
} lsa_RightSet;
NTSTATUS lsa_EnumAccountRights (
[in,ref] policy_handle *handle,
[in,ref] dom_sid2 *sid,
[out,ref] lsa_RightSet *rights
);
2004-08-31 12:22:51 +04:00
/**********************/
2003-11-09 11:30:29 +03:00
/* Function: 0x25 */
2004-08-31 12:22:51 +04:00
NTSTATUS lsa_AddAccountRights (
[in,ref] policy_handle *handle,
[in,ref] dom_sid2 *sid,
[in,ref] lsa_RightSet *rights
);
/**********************/
/* Function: 0x26 */
NTSTATUS lsa_RemoveAccountRights (
[in,ref] policy_handle *handle,
[in,ref] dom_sid2 *sid,
[in] uint32 unknown,
[in,ref] lsa_RightSet *rights
);
2003-11-09 11:30:29 +03:00
/* Function: 0x27 */
2004-11-23 03:31:00 +03:00
NTSTATUS lsa_QueryTrustedDomainInfoBySid(
[in,ref] policy_handle *handle,
[in,ref] dom_sid2 *dom_sid,
[in] uint16 level,
[out,switch_is(level)] lsa_TrustedDomainInfo *info
);
2003-11-09 11:30:29 +03:00
/* Function: 0x28 */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_SetTrustDomainInfo();
2003-11-09 11:30:29 +03:00
/* Function: 0x29 */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_DeleteTrustDomain();
2003-11-09 11:30:29 +03:00
/* Function: 0x2a */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_StorePrivateData();
2003-11-09 11:30:29 +03:00
/* Function: 0x2b */
2004-08-13 05:31:11 +04:00
NTSTATUS lsa_RetrievePrivateData();
2003-11-09 11:30:29 +03:00
/**********************/
/* Function: 0x2c */
NTSTATUS lsa_OpenPolicy2 (
[in] unistr *system_name,
[in,ref] lsa_ObjectAttribute *attr,
2004-05-27 08:13:58 +04:00
[in] uint32 access_mask,
2003-11-09 11:30:29 +03:00
[out,ref] policy_handle *handle
);
2004-12-21 12:41:21 +03:00
/**********************/
/* Function: 0x2d */
typedef struct {
lsa_String *string;
} lsa_StringPointer;
2003-11-09 11:30:29 +03:00
2004-12-21 12:41:21 +03:00
NTSTATUS lsa_GetUserName(
[in] unistr *system_name,
[in,out] lsa_String *account_name,
2004-12-21 13:05:02 +03:00
[in,out] lsa_StringPointer *authority_name
2004-12-21 12:41:21 +03:00
);
2004-05-27 10:27:21 +04:00
/**********************/
2003-11-09 11:30:29 +03:00
/* Function: 0x2e */
2004-05-27 10:27:21 +04:00
NTSTATUS lsa_QueryInfoPolicy2(
[in,ref] policy_handle *handle,
[in] uint16 level,
[out,switch_is(level)] lsa_PolicyInformation *info
);
2004-08-13 05:31:11 +04:00
/* Function 0x2f */
NTSTATUS lsa_SetInfoPolicy2();
2004-11-26 09:33:38 +03:00
/**********************/
2004-08-13 05:31:11 +04:00
/* Function 0x30 */
2004-11-23 03:31:00 +03:00
NTSTATUS lsa_QueryTrustedDomainInfoByName(
[in,ref] policy_handle *handle,
[in] lsa_String trusted_domain,
[in] uint16 level,
[out,switch_is(level)] lsa_TrustedDomainInfo *info
);
2004-08-13 05:31:11 +04:00
/* Function 0x31 */
NTSTATUS lsa_SetTrustedDomainInfoByName();
/* Function 0x32 */
NTSTATUS lsa_EnumTrustedDomainsEx();
/* Function 0x33 */
NTSTATUS lsa_CreateTrustedDomainEx();
/* Function 0x34 */
NTSTATUS lsa_CloseTrustedDomainEx();
/* Function 0x35 */
NTSTATUS lsa_QueryDomainInformationPolicy();
/* Function 0x36 */
NTSTATUS lsa_SetDomInfoPolicy();
2004-11-26 09:33:38 +03:00
/**********************/
2004-08-13 05:31:11 +04:00
/* Function 0x37 */
2004-11-22 11:47:47 +03:00
NTSTATUS lsa_OpenTrustedDomainByName(
[in,ref] policy_handle *handle,
2004-11-22 14:59:59 +03:00
[in] lsa_String name,
2004-11-22 11:47:47 +03:00
[in] uint32 access_mask,
[out,ref] policy_handle *trustdom_handle
);
2004-08-13 05:31:11 +04:00
/* Function 0x38 */
NTSTATUS lsa_TestCall();
2004-11-26 09:33:38 +03:00
/**********************/
2004-08-13 05:31:11 +04:00
/* Function 0x39 */
2004-11-26 09:33:38 +03:00
typedef struct {
uint16 sid_type;
lsa_String name;
uint32 sid_index;
uint32 unknown;
} lsa_TranslatedName2;
typedef struct {
[range(0,1000)] uint32 count;
[size_is(count)] lsa_TranslatedName2 *names;
} lsa_TransNameArray2;
NTSTATUS lsa_LookupSids2(
[in,ref] policy_handle *handle,
[in,ref] lsa_SidArray *sids,
[out] lsa_RefDomainList *domains,
[in,out,ref] lsa_TransNameArray2 *names,
[in] uint16 level,
[in,out,ref] uint32 *count,
[in] uint32 unknown1,
[in] uint32 unknown2
);
/**********************/
2004-08-13 05:31:11 +04:00
/* Function 0x3a */
2004-11-26 09:33:38 +03:00
typedef struct {
uint16 sid_type;
uint32 rid;
uint32 sid_index;
uint32 unknown;
} lsa_TranslatedSid2;
typedef struct {
[range(0,1000)] uint32 count;
[size_is(count)] lsa_TranslatedSid2 *sids;
} lsa_TransSidArray2;
NTSTATUS lsa_LookupNames2 (
[in,ref] policy_handle *handle,
[in,range(0,1000)] uint32 num_names,
[in,ref,size_is(num_names)] lsa_String *names,
[out] lsa_RefDomainList *domains,
[in,out,ref] lsa_TransSidArray2 *sids,
[in] uint16 level,
[in,out,ref] uint32 *count,
[in] uint32 unknown1,
[in] uint32 unknown2
);
2004-08-13 05:31:11 +04:00
/* Function 0x3b */
NTSTATUS lsa_CreateTrustedDomainEx2();
2003-11-28 08:20:11 +03:00
}