subversion: tell configure that we're a Cygwin system
[msysgit.git] / include / lmaudit.h
blob1d944b2cb078f25d10aeb708b73553fcbae39839
1 #ifndef _LMAUDIT_H
2 #define _LMAUDIT_H
3 #ifdef __cplusplus
4 extern "C" {
5 #endif
6 #define REVISED_AUDIT_ENTRY_STRUCT
7 #define LOGFLAGS_FORWARD 0
8 #define LOGFLAGS_BACKWARD 1
9 #define LOGFLAGS_SEEK 2
10 #define ACTION_LOCKOUT 0
11 #define ACTION_ADMINUNLOCK 1
12 #define AE_GUEST 0
13 #define AE_USER 1
14 #define AE_ADMIN 2
15 #define AE_NORMAL 0
16 #define AE_USERLIMIT 0
17 #define AE_GENERAL 0
18 #define AE_ERROR 1
19 #define AE_SESSDIS 1
20 #define AE_BADPW 1
21 #define AE_AUTODIS 2
22 #define AE_UNSHARE 2
23 #define AE_ADMINPRIVREQD 2
24 #define AE_ADMINDIS 3
25 #define AE_NOACCESSPERM 3
26 #define AE_ACCRESTRICT 4
27 #define AE_NORMAL_CLOSE 0
28 #define AE_SES_CLOSE 1
29 #define AE_ADMIN_CLOSE 2
30 #define AE_LIM_UNKNOWN 0
31 #define AE_LIM_LOGONHOURS 1
32 #define AE_LIM_EXPIRED 2
33 #define AE_LIM_INVAL_WKSTA 3
34 #define AE_LIM_DISABLED 4
35 #define AE_LIM_DELETED 5
36 #define AE_MOD 0
37 #define AE_DELETE 1
38 #define AE_ADD 2
39 #define AE_UAS_USER 0
40 #define AE_UAS_GROUP 1
41 #define AE_UAS_MODALS 2
42 #define SVAUD_SERVICE 1
43 #define SVAUD_GOODSESSLOGON 6
44 #define SVAUD_BADSESSLOGON 24
45 #define SVAUD_SESSLOGON (SVAUD_GOODSESSLOGON|SVAUD_BADSESSLOGON)
46 #define SVAUD_GOODNETLOGON 96
47 #define SVAUD_BADNETLOGON 384
48 #define SVAUD_NETLOGON (SVAUD_GOODNETLOGON|SVAUD_BADNETLOGON)
49 #define SVAUD_LOGON (SVAUD_NETLOGON|SVAUD_SESSLOGON)
50 #define SVAUD_GOODUSE 0x600
51 #define SVAUD_BADUSE 0x1800
52 #define SVAUD_USE (SVAUD_GOODUSE|SVAUD_BADUSE)
53 #define SVAUD_USERLIST 8192
54 #define SVAUD_PERMISSIONS 16384
55 #define SVAUD_RESOURCE 32768
56 #define SVAUD_LOGONLIM 65536
57 #define AA_AUDIT_ALL 1
58 #define AA_A_OWNER 4
59 #define AA_CLOSE 8
60 #define AA_S_OPEN 16
61 #define AA_S_WRITE 32
62 #define AA_S_CREATE 32
63 #define AA_S_DELETE 64
64 #define AA_S_ACL 128
65 #define AA_S_ALL 253
66 #define AA_F_OPEN 256
67 #define AA_F_WRITE 512
68 #define AA_F_CREATE 512
69 #define AA_F_DELETE 1024
70 #define AA_F_ACL 2048
71 #define AA_F_ALL (AA_F_OPEN|AA_F_WRITE|AA_F_DELETE|AA_F_ACL)
72 #define AA_A_OPEN 2048
73 #define AA_A_WRITE 4096
74 #define AA_A_CREATE 8192
75 #define AA_A_DELETE 16384
76 #define AA_A_ACL 32768
77 #define AA_A_ALL (AA_F_OPEN|AA_F_WRITE|AA_F_DELETE|AA_F_ACL)
78 typedef struct _AUDIT_ENTRY {
79 DWORD ae_len;
80 DWORD ae_reserved;
81 DWORD ae_time;
82 DWORD ae_type;
83 DWORD ae_data_offset;
84 DWORD ae_data_size;
85 } AUDIT_ENTRY,*PAUDIT_ENTRY,*LPAUDIT_ENTRY;
86 typedef struct _HLOG {
87 DWORD time;
88 DWORD last_flags;
89 DWORD offset;
90 DWORD rec_offset;
91 } HLOG,*PHLOG,*LPHLOG;
92 typedef struct _AE_SRVSTATUS {
93 DWORD ae_sv_status;
94 } AE_SRVSTATUS,*PAE_SRVSTATUS,*LPAE_SRVSTATUS;
95 typedef struct _AE_SESSLOGON {
96 DWORD ae_so_compname;
97 DWORD ae_so_username;
98 DWORD ae_so_privilege;
99 } AE_SESSLOGON,*PAE_SESSLOGON,*LPAE_SESSLOGON;
100 typedef struct _AE_SESSLOGOFF {
101 DWORD ae_sf_compname;
102 DWORD ae_sf_username;
103 DWORD ae_sf_reason;
104 } AE_SESSLOGOFF,*PAE_SESSLOGOFF,*LPAE_SESSLOGOFF;
105 typedef struct _AE_SESSPWERR {
106 DWORD ae_sp_compname;
107 DWORD ae_sp_username;
108 } AE_SESSPWERR,*PAE_SESSPWERR,*LPAE_SESSPWERR;
109 typedef struct _AE_CONNSTART {
110 DWORD ae_ct_compname;
111 DWORD ae_ct_username;
112 DWORD ae_ct_netname;
113 DWORD ae_ct_connid;
114 } AE_CONNSTART,*PAE_CONNSTART,*LPAE_CONNSTART;
115 typedef struct _AE_CONNSTOP {
116 DWORD ae_cp_compname;
117 DWORD ae_cp_username;
118 DWORD ae_cp_netname;
119 DWORD ae_cp_connid;
120 DWORD ae_cp_reason;
121 } AE_CONNSTOP,*PAE_CONNSTOP,*LPAE_CONNSTOP;
122 typedef struct _AE_CONNREJ {
123 DWORD ae_cr_compname;
124 DWORD ae_cr_username;
125 DWORD ae_cr_netname;
126 DWORD ae_cr_reason;
127 } AE_CONNREJ,*PAE_CONNREJ,*LPAE_CONNREJ;
128 typedef struct _AE_RESACCESS {
129 DWORD ae_ra_compname;
130 DWORD ae_ra_username;
131 DWORD ae_ra_resname;
132 DWORD ae_ra_operation;
133 DWORD ae_ra_returncode;
134 DWORD ae_ra_restype;
135 DWORD ae_ra_fileid;
136 } AE_RESACCESS,*PAE_RESACCESS,*LPAE_RESACCESS;
137 typedef struct _AE_RESACCESSREJ {
138 DWORD ae_rr_compname;
139 DWORD ae_rr_username;
140 DWORD ae_rr_resname;
141 DWORD ae_rr_operation;
142 } AE_RESACCESSREJ,*PAE_RESACCESSREJ,*LPAE_RESACCESSREJ;
143 typedef struct _AE_CLOSEFILE {
144 DWORD ae_cf_compname;
145 DWORD ae_cf_username;
146 DWORD ae_cf_resname;
147 DWORD ae_cf_fileid;
148 DWORD ae_cf_duration;
149 DWORD ae_cf_reason;
150 } AE_CLOSEFILE,*PAE_CLOSEFILE,*LPAE_CLOSEFILE;
151 typedef struct _AE_SERVICESTAT {
152 DWORD ae_ss_compname;
153 DWORD ae_ss_username;
154 DWORD ae_ss_svcname;
155 DWORD ae_ss_status;
156 DWORD ae_ss_code;
157 DWORD ae_ss_text;
158 DWORD ae_ss_returnval;
159 } AE_SERVICESTAT,*PAE_SERVICESTAT,*LPAE_SERVICESTAT;
160 typedef struct _AE_ACLMOD {
161 DWORD ae_am_compname;
162 DWORD ae_am_username;
163 DWORD ae_am_resname;
164 DWORD ae_am_action;
165 DWORD ae_am_datalen;
166 } AE_ACLMOD,*PAE_ACLMOD,*LPAE_ACLMOD;
167 typedef struct _AE_UASMOD {
168 DWORD ae_um_compname;
169 DWORD ae_um_username;
170 DWORD ae_um_resname;
171 DWORD ae_um_rectype;
172 DWORD ae_um_action;
173 DWORD ae_um_datalen;
174 } AE_UASMOD,*PAE_UASMOD,*LPAE_UASMOD;
175 typedef struct _AE_NETLOGON {
176 DWORD ae_no_compname;
177 DWORD ae_no_username;
178 DWORD ae_no_privilege;
179 DWORD ae_no_authflags;
180 } AE_NETLOGON,*PAE_NETLOGON,*LPAE_NETLOGON;
181 typedef struct _AE_NETLOGOFF {
182 DWORD ae_nf_compname;
183 DWORD ae_nf_username;
184 DWORD ae_nf_reserved1;
185 DWORD ae_nf_reserved2;
186 } AE_NETLOGOFF,*PAE_NETLOGOFF,*LPAE_NETLOGOFF;
187 typedef struct _AE_ACCLIM {
188 DWORD ae_al_compname;
189 DWORD ae_al_username;
190 DWORD ae_al_resname;
191 DWORD ae_al_limit;
192 } AE_ACCLIM,*PAE_ACCLIM,*LPAE_ACCLIM;
193 typedef struct _AE_LOCKOUT {
194 DWORD ae_lk_compname;
195 DWORD ae_lk_username;
196 DWORD ae_lk_action;
197 DWORD ae_lk_bad_pw_count;
198 } AE_LOCKOUT,*PAE_LOCKOUT,*LPAE_LOCKOUT;
199 typedef struct _AE_GENERIC {
200 DWORD ae_ge_msgfile;
201 DWORD ae_ge_msgnum;
202 DWORD ae_ge_params;
203 DWORD ae_ge_param1;
204 DWORD ae_ge_param2;
205 DWORD ae_ge_param3;
206 DWORD ae_ge_param4;
207 DWORD ae_ge_param5;
208 DWORD ae_ge_param6;
209 DWORD ae_ge_param7;
210 DWORD ae_ge_param8;
211 DWORD ae_ge_param9;
212 } AE_GENERIC,*PAE_GENERIC,*LPAE_GENERIC;
213 NET_API_STATUS WINAPI NetAuditClear(LPCWSTR,LPCWSTR,LPCWSTR);
214 NET_API_STATUS WINAPI NetAuditRead(LPTSTR,LPTSTR,LPHLOG,DWORD,PDWORD,DWORD,DWORD,PBYTE*,DWORD,PDWORD,PDWORD);
215 NET_API_STATUS WINAPI NetAuditWrite(DWORD,PBYTE,DWORD,LPTSTR,PBYTE);
217 /* These conflict with struct typedefs, why? */
218 #define AE_SRVSTATUS 0
219 #define AE_SESSLOGON 1
220 #define AE_SESSLOGOFF 2
221 #define AE_SESSPWERR 3
222 #define AE_CONNSTART 4
223 #define AE_CONNSTOP 5
224 #define AE_CONNREJ 6
225 #define AE_RESACCESS 7
226 #define AE_RESACCESSREJ 8
227 #define AE_CLOSEFILE 9
228 #define AE_SERVICESTAT 11
229 #define AE_ACLMOD 12
230 #define AE_UASMOD 13
231 #define AE_NETLOGON 14
232 #define AE_NETLOGOFF 15
233 #define AE_NETLOGDENIED 16
234 #define AE_ACCLIMITEXCD 17
235 #define AE_RESACCESS2 18
236 #define AE_ACLMODFAIL 19
237 #define AE_LOCKOUT 20
238 #define AE_GENERIC_TYPE 21
239 #define AE_SRVSTART 0
240 #define AE_SRVPAUSED 1
241 #define AE_SRVCONT 2
242 #define AE_SRVSTOP 3
243 #ifdef __cplusplus
245 #endif
246 #endif