xref: /reactos/sdk/include/reactos/subsys/win/base.h (revision d8cc88ca)
1 /*
2  * COPYRIGHT:       See COPYING in the top level directory
3  * PROJECT:         ReactOS Base API Server DLL
4  * FILE:            include/reactos/subsys/win/base.h
5  * PURPOSE:         Public definitions for Base API Clients
6  * PROGRAMMERS:     Hermes Belusca-Maito (hermes.belusca@sfr.fr)
7  */
8 
9 #ifndef _BASE_H
10 #define _BASE_H
11 
12 #pragma once
13 
14 typedef
15 BOOL
16 (NTAPI *BASE_PROCESS_CREATE_NOTIFY_ROUTINE)(
17     HANDLE NewProcessId,
18     HANDLE ParentThreadId,
19     ULONG  dwUnknown,
20     ULONG  CreateFlags);
21 
22 VOID
23 NTAPI
24 BaseSetProcessCreateNotify(IN BASE_PROCESS_CREATE_NOTIFY_ROUTINE ProcessCreateNotifyProc);
25 
26 #define NLS_SIZEOF_ACE_AND_SIDS(n) \
27     (FIELD_OFFSET(ACCESS_ALLOWED_ACE, SidStart) + \
28      FIELD_OFFSET(SID, SubAuthority) + (n)*RTL_FIELD_SIZE(SID, SubAuthority))
29 
30 /* Minimal size for the security descriptors of the "\NLS\NlsSection*" sections */
31 #define NLS_SECTION_SECURITY_DESCRIPTOR_SIZE \
32     (sizeof(SECURITY_DESCRIPTOR) + sizeof(ACL) + NLS_SIZEOF_ACE_AND_SIDS(1))
33 
34 typedef struct _NLS_USER_INFO
35 {
36     WCHAR sLanguage[80];
37     WCHAR iCountry[80];
38     WCHAR sCountry[80];
39     WCHAR sList[80];
40     WCHAR iMeasure[80];
41     WCHAR iPaperSize[80];
42     WCHAR sDecimal[80];
43     WCHAR sThousand[80];
44     WCHAR sGrouping[80];
45     WCHAR iDigits[80];
46     WCHAR iLZero[80];
47     WCHAR iNegNumber[80];
48     WCHAR sNativeDigits[80];
49     WCHAR NumShape[80];
50     WCHAR sCurrency[80];
51     WCHAR sMonDecSep[80];
52     WCHAR sMonThouSep[80];
53     WCHAR sMonGrouping[80];
54     WCHAR iCurrDigits[80];
55     WCHAR iCurrency[80];
56     WCHAR iNegCurr[80];
57     WCHAR sPositiveSign[80];
58     WCHAR sNegativeSign[80];
59     WCHAR sTimeFormat[80];
60     WCHAR sTime[80];
61     WCHAR iTime[80];
62     WCHAR iTLZero[80];
63     WCHAR iTimePrefix[80];
64     WCHAR s1159[80];
65     WCHAR s2359[80];
66     WCHAR sShortDate[80];
67     WCHAR sDate[80];
68     WCHAR iDate[80];
69     WCHAR sYearMonth[80];
70     WCHAR sLongDate[80];
71     WCHAR iCalType[80];
72     WCHAR iFirstDayOfWeek[80];
73     WCHAR iFirstWeekOfYear[80];
74     WCHAR Locale[80];
75     LCID UserLocaleId;
76     LUID InteractiveUserLuid;
77     ULONG ulCacheUpdateCount;
78 } NLS_USER_INFO, *PNLS_USER_INFO;
79 C_ASSERT(sizeof(NLS_USER_INFO) == 0x1870);
80 
81 typedef struct _INIFILE_MAPPING_TARGET
82 {
83     struct _INIFILE_MAPPING_TARGET *Next;
84     UNICODE_STRING RegistryPath;
85 } INIFILE_MAPPING_TARGET, *PINIFILE_MAPPING_TARGET;
86 
87 typedef struct _INIFILE_MAPPING_VARNAME
88 {
89     struct _INIFILE_MAPPING_VARNAME *Next;
90     UNICODE_STRING Name;
91     ULONG MappingFlags;
92     PINIFILE_MAPPING_TARGET MappingTarget;
93 } INIFILE_MAPPING_VARNAME, *PINIFILE_MAPPING_VARNAME;
94 
95 typedef struct _INIFILE_MAPPING_APPNAME
96 {
97     struct _INIFILE_MAPPING_APPNAME *Next;
98     UNICODE_STRING Name;
99     PINIFILE_MAPPING_VARNAME VariableNames;
100     PINIFILE_MAPPING_VARNAME DefaultVarNameMapping;
101 } INIFILE_MAPPING_APPNAME, *PINIFILE_MAPPING_APPNAME;
102 
103 typedef struct _INIFILE_MAPPING_FILENAME
104 {
105     struct _INIFILE_MAPPING_FILENAME *Next;
106     UNICODE_STRING Name;
107     PINIFILE_MAPPING_APPNAME ApplicationNames;
108     PINIFILE_MAPPING_APPNAME DefaultAppNameMapping;
109 } INIFILE_MAPPING_FILENAME, *PINIFILE_MAPPING_FILENAME;
110 
111 typedef struct _INIFILE_MAPPING
112 {
113     PINIFILE_MAPPING_FILENAME FileNames;
114     PINIFILE_MAPPING_FILENAME DefaultFileNameMapping;
115     PINIFILE_MAPPING_FILENAME WinIniFileMapping;
116     ULONG Reserved;
117 } INIFILE_MAPPING, *PINIFILE_MAPPING;
118 
119 typedef struct _BASE_STATIC_SERVER_DATA
120 {
121     UNICODE_STRING WindowsDirectory;
122     UNICODE_STRING WindowsSystemDirectory;
123     UNICODE_STRING NamedObjectDirectory;
124     USHORT WindowsMajorVersion;
125     USHORT WindowsMinorVersion;
126     USHORT BuildNumber;
127     USHORT CSDNumber;
128     USHORT RCNumber;
129     WCHAR CSDVersion[128];
130     SYSTEM_BASIC_INFORMATION SysInfo;
131     SYSTEM_TIMEOFDAY_INFORMATION TimeOfDay;
132     PVOID IniFileMapping;
133     NLS_USER_INFO NlsUserInfo;
134     BOOLEAN DefaultSeparateVDM;
135     BOOLEAN IsWowTaskReady;
136     UNICODE_STRING WindowsSys32x86Directory;
137     BOOLEAN fTermsrvAppInstallMode;
138     TIME_ZONE_INFORMATION tziTermsrvClientTimeZone;
139     KSYSTEM_TIME ktTermsrvClientBias;
140     ULONG TermsrvClientTimeZoneId;
141     BOOLEAN LUIDDeviceMapsEnabled;
142     ULONG TermsrvClientTimeZoneChangeNum;
143 } BASE_STATIC_SERVER_DATA, *PBASE_STATIC_SERVER_DATA;
144 
145 #if defined(_M_IX86)
146 C_ASSERT(sizeof(BASE_STATIC_SERVER_DATA) == 0x1AC8);
147 #endif
148 
149 #endif // _BASE_H
150 
151 /* EOF */
152