xref: /reactos/sdk/include/psdk/aclui.h (revision 8a978a17)
1 /*
2  * aclui.h
3  *
4  * Access Control List Editor definitions
5  *
6  * THIS SOFTWARE IS NOT COPYRIGHTED
7  *
8  * This source code is offered for use in the public domain. You may
9  * use, modify or distribute it freely.
10  *
11  * This code is distributed in the hope that it will be useful but
12  * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
13  * DISCLAIMED. This includes but is not limited to warranties of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15  *
16  */
17 
18 #ifndef __ACLUI_H
19 #define __ACLUI_H
20 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
25 #include <unknwn.h>
26 #include <accctrl.h>
27 #include <commctrl.h>
28 
29 DEFINE_GUID(IID_ISecurityInformation, 0x965fc360, 0x16ff, 0x11d0, 0x0091, 0xcb,0x00,0xaa,0x00,0xbb,0xb7,0x23);
30 DEFINE_GUID(IID_ISecurityInformation2, 0xc3ccfdb4, 0x6f88, 0x11d2, 0x00a3, 0xce,0x00,0xc0,0x4f,0xb1,0x78,0x2a);
31 DEFINE_GUID(IID_IEffectivePermission, 0x3853dc76, 0x9f35, 0x407c, 0x0088, 0xa1,0xd1,0x93,0x44,0x36,0x5f,0xbc);
32 DEFINE_GUID(IID_ISecurityObjectTypeInfo, 0xfc3066eb, 0x79ef, 0x444b, 0x0091, 0x11,0xd1,0x8a,0x75,0xeb,0xf2,0xfa);
33 
34 typedef interface ISecurityInformation *LPSECURITYINFO;
35 typedef interface ISecurityInformation2 *LPSECURITYINFO2;
36 typedef interface IEffectivePermission *LPEFFECTIVEPERMISSION;
37 typedef interface ISecurityObjectTypeInfo *LPSecurityObjectTypeInfo;
38 
39 #undef INTERFACE
40 EXTERN_C const IID IID_ISecurityInformation;
41 #define INTERFACE ISecurityInformation
42 DECLARE_INTERFACE_(ISecurityInformation,IUnknown)
43 {
44         /* IUnknown */
45         STDMETHOD(QueryInterface)(THIS_ REFIID,PVOID*) PURE;
46 	STDMETHOD_(ULONG,AddRef)(THIS) PURE;
47 	STDMETHOD_(ULONG,Release)(THIS) PURE;
48 
49 	/* ISecurityInformation */
50 	STDMETHOD(GetObjectInformation)(THIS_ PSI_OBJECT_INFO) PURE;
51 	STDMETHOD(GetSecurity)(THIS_ SECURITY_INFORMATION,PSECURITY_DESCRIPTOR*,BOOL) PURE;
52 	STDMETHOD(SetSecurity)(THIS_ SECURITY_INFORMATION,PSECURITY_DESCRIPTOR) PURE;
53 	STDMETHOD(GetAccessRights)(THIS_ GUID*,DWORD,PSI_ACCESS*,ULONG*,ULONG*) PURE;
54 	STDMETHOD(MapGeneric)(THIS_ GUID*,UCHAR*,PSI_ACCESS*) PURE;
55 	STDMETHOD(GetInheritTypes)(THIS_ PSI_INHERIT_TYPE*,ULONG*) PURE;
56 	STDMETHOD(PropertySheetPageCallback)(THIS_ HWND,UINT,SI_PAGE_TYPE) PURE;
57 };
58 #undef INTERFACE
59 
60 #undef INTERFACE
61 #define INTERFACE ISecurityInformation2
62 DECLARE_INTERFACE_(ISecurityInformation2,IUnknown)
63 {
64         /* IUnknown */
65         STDMETHOD(QueryInterface)(THIS_ REFIID,PVOID*) PURE;
66 	STDMETHOD_(ULONG,AddRef)(THIS) PURE;
67 	STDMETHOD_(ULONG,Release)(THIS) PURE;
68 
69 	/* ISecurityInformation2 */
70 	STDMETHOD(IsDaclCanonical)(THIS_ PACL) PURE;
71 	STDMETHOD(LookupSids)(THIS_ ULONG,PSID*,LPDATAOBJECT*) PURE;
72 };
73 #undef INTERFACE
74 
75 #undef INTERFACE
76 #define INTERFACE IEffectivePermission
77 DECLARE_INTERFACE_(IEffectivePermission,IUnknown)
78 {
79         /* IUnknown */
80         STDMETHOD(QueryInterface)(THIS_ REFIID,PVOID*) PURE;
81 	STDMETHOD_(ULONG,AddRef)(THIS) PURE;
82 	STDMETHOD_(ULONG,Release)(THIS) PURE;
83 
84 	/* IEffectivePermission */
85 	STDMETHOD(GetEffectivePermission)(THIS_ GUID*,PSID,LPCWSTR,PSECURITY_DESCRIPTOR,POBJECT_TYPE_LIST*,ULONG*,PACCESS_MASK*,ULONG*) PURE;
86 };
87 #undef INTERFACE
88 
89 #undef INTERFACE
90 #define INTERFACE ISecurityObjectTypeInfo
91 DECLARE_INTERFACE_(ISecurityObjectTypeInfo,IUnknown)
92 {
93         /* IUnknown */
94         STDMETHOD(QueryInterface)(THIS_ REFIID,PVOID*) PURE;
95 	STDMETHOD_(ULONG,AddRef)(THIS) PURE;
96 	STDMETHOD_(ULONG,Release)(THIS) PURE;
97 
98 	/* ISecurityObjectTypeInfo */
99 	STDMETHOD(GetInheritSource)(THIS_ SECURITY_INFORMATION,PACL,PINHERITED_FROM*) PURE;
100 };
101 #undef INTERFACE
102 
103 HPROPSHEETPAGE WINAPI
104 CreateSecurityPage(LPSECURITYINFO psi);
105 
106 BOOL WINAPI
107 EditSecurity(HWND hwndOwner, LPSECURITYINFO psi);
108 
109 #ifdef __cplusplus
110 }
111 #endif
112 #endif /* __ACLUI_H */
113 
114 /* EOF */
115