13 #define NTAPI __stdcall
31 typedef LONG NTSTATUS;
32 typedef NTSTATUS *PNTSTATUS;
35 typedef CSHORT *PCSHORT;
37 typedef WCHAR * PWCHAR;
39 /* NT lowlevel Strings (handled by Rtl* functions in NTDLL)
40 * If they are zero terminated, Length does not include the terminating 0.
43 typedef struct _STRING {
47 } STRING,*PSTRING,ANSI_STRING,*PANSI_STRING;
49 typedef struct _CSTRING {
55 typedef struct _UNICODE_STRING {
56 USHORT Length; /* bytes */
57 USHORT MaximumLength; /* bytes */
59 } UNICODE_STRING,*PUNICODE_STRING;
65 #define OBJ_INHERIT 0x00000002L
66 #define OBJ_PERMANENT 0x00000010L
67 #define OBJ_EXCLUSIVE 0x00000020L
68 #define OBJ_CASE_INSENSITIVE 0x00000040L
69 #define OBJ_OPENIF 0x00000080L
70 #define OBJ_OPENLINK 0x00000100L
71 #define OBJ_KERNEL_HANDLE 0x00000200L
72 #define OBJ_VALID_ATTRIBUTES 0x000003F2L
74 typedef struct _OBJECT_ATTRIBUTES
77 PUNICODE_STRING ObjectName;
79 PVOID SecurityDescriptor; /* type SECURITY_DESCRIPTOR */
80 PVOID SecurityQualityOfService; /* type SECURITY_QUALITY_OF_SERVICE */
83 typedef OBJECT_ATTRIBUTES *POBJECT_ATTRIBUTES;
85 #define InitializeObjectAttributes(p,n,a,r,s) \
86 { (p)->Length = sizeof(OBJECT_ATTRIBUTES); \
87 (p)->RootDirectory = r; \
88 (p)->Attributes = a; \
89 (p)->ObjectName = n; \
90 (p)->SecurityDescriptor = s; \
91 (p)->SecurityQualityOfService = NULL; \