Funktionierender Prototyp des Serious Games zur Vermittlung von Wissen zu Software-Engineering-Arbeitsmodellen.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 year ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371
  1. # Generated by h2py from \mssdk\include\winnt.h
  2. APPLICATION_ERROR_MASK = 536870912
  3. ERROR_SEVERITY_SUCCESS = 0
  4. ERROR_SEVERITY_INFORMATIONAL = 1073741824
  5. ERROR_SEVERITY_WARNING = -2147483648
  6. ERROR_SEVERITY_ERROR = -1073741824
  7. MINCHAR = 128
  8. MAXCHAR = 127
  9. MINSHORT = 32768
  10. MAXSHORT = 32767
  11. MINLONG = -2147483648
  12. MAXLONG = 2147483647
  13. MAXBYTE = 255
  14. MAXWORD = 65535
  15. MAXDWORD = -1
  16. LANG_NEUTRAL = 0
  17. LANG_AFRIKAANS = 54
  18. LANG_ALBANIAN = 28
  19. LANG_ARABIC = 1
  20. LANG_BASQUE = 45
  21. LANG_BELARUSIAN = 35
  22. LANG_BULGARIAN = 2
  23. LANG_CATALAN = 3
  24. LANG_CHINESE = 4
  25. LANG_CROATIAN = 26
  26. LANG_CZECH = 5
  27. LANG_DANISH = 6
  28. LANG_DUTCH = 19
  29. LANG_ENGLISH = 9
  30. LANG_ESTONIAN = 37
  31. LANG_FAEROESE = 56
  32. LANG_FARSI = 41
  33. LANG_FINNISH = 11
  34. LANG_FRENCH = 12
  35. LANG_GERMAN = 7
  36. LANG_GREEK = 8
  37. LANG_HEBREW = 13
  38. LANG_HINDI = 57
  39. LANG_HUNGARIAN = 14
  40. LANG_ICELANDIC = 15
  41. LANG_INDONESIAN = 33
  42. LANG_ITALIAN = 16
  43. LANG_JAPANESE = 17
  44. LANG_KOREAN = 18
  45. LANG_LATVIAN = 38
  46. LANG_LITHUANIAN = 39
  47. LANG_MACEDONIAN = 47
  48. LANG_MALAY = 62
  49. LANG_NORWEGIAN = 20
  50. LANG_POLISH = 21
  51. LANG_PORTUGUESE = 22
  52. LANG_ROMANIAN = 24
  53. LANG_RUSSIAN = 25
  54. LANG_SERBIAN = 26
  55. LANG_SLOVAK = 27
  56. LANG_SLOVENIAN = 36
  57. LANG_SPANISH = 10
  58. LANG_SWAHILI = 65
  59. LANG_SWEDISH = 29
  60. LANG_THAI = 30
  61. LANG_TURKISH = 31
  62. LANG_UKRAINIAN = 34
  63. LANG_VIETNAMESE = 42
  64. SUBLANG_NEUTRAL = 0
  65. SUBLANG_DEFAULT = 1
  66. SUBLANG_SYS_DEFAULT = 2
  67. SUBLANG_ARABIC_SAUDI_ARABIA = 1
  68. SUBLANG_ARABIC_IRAQ = 2
  69. SUBLANG_ARABIC_EGYPT = 3
  70. SUBLANG_ARABIC_LIBYA = 4
  71. SUBLANG_ARABIC_ALGERIA = 5
  72. SUBLANG_ARABIC_MOROCCO = 6
  73. SUBLANG_ARABIC_TUNISIA = 7
  74. SUBLANG_ARABIC_OMAN = 8
  75. SUBLANG_ARABIC_YEMEN = 9
  76. SUBLANG_ARABIC_SYRIA = 10
  77. SUBLANG_ARABIC_JORDAN = 11
  78. SUBLANG_ARABIC_LEBANON = 12
  79. SUBLANG_ARABIC_KUWAIT = 13
  80. SUBLANG_ARABIC_UAE = 14
  81. SUBLANG_ARABIC_BAHRAIN = 15
  82. SUBLANG_ARABIC_QATAR = 16
  83. SUBLANG_CHINESE_TRADITIONAL = 1
  84. SUBLANG_CHINESE_SIMPLIFIED = 2
  85. SUBLANG_CHINESE_HONGKONG = 3
  86. SUBLANG_CHINESE_SINGAPORE = 4
  87. SUBLANG_CHINESE_MACAU = 5
  88. SUBLANG_DUTCH = 1
  89. SUBLANG_DUTCH_BELGIAN = 2
  90. SUBLANG_ENGLISH_US = 1
  91. SUBLANG_ENGLISH_UK = 2
  92. SUBLANG_ENGLISH_AUS = 3
  93. SUBLANG_ENGLISH_CAN = 4
  94. SUBLANG_ENGLISH_NZ = 5
  95. SUBLANG_ENGLISH_EIRE = 6
  96. SUBLANG_ENGLISH_SOUTH_AFRICA = 7
  97. SUBLANG_ENGLISH_JAMAICA = 8
  98. SUBLANG_ENGLISH_CARIBBEAN = 9
  99. SUBLANG_ENGLISH_BELIZE = 10
  100. SUBLANG_ENGLISH_TRINIDAD = 11
  101. SUBLANG_ENGLISH_ZIMBABWE = 12
  102. SUBLANG_ENGLISH_PHILIPPINES = 13
  103. SUBLANG_FRENCH = 1
  104. SUBLANG_FRENCH_BELGIAN = 2
  105. SUBLANG_FRENCH_CANADIAN = 3
  106. SUBLANG_FRENCH_SWISS = 4
  107. SUBLANG_FRENCH_LUXEMBOURG = 5
  108. SUBLANG_FRENCH_MONACO = 6
  109. SUBLANG_GERMAN = 1
  110. SUBLANG_GERMAN_SWISS = 2
  111. SUBLANG_GERMAN_AUSTRIAN = 3
  112. SUBLANG_GERMAN_LUXEMBOURG = 4
  113. SUBLANG_GERMAN_LIECHTENSTEIN = 5
  114. SUBLANG_ITALIAN = 1
  115. SUBLANG_ITALIAN_SWISS = 2
  116. SUBLANG_KOREAN = 1
  117. SUBLANG_KOREAN_JOHAB = 2
  118. SUBLANG_LITHUANIAN = 1
  119. SUBLANG_LITHUANIAN_CLASSIC = 2
  120. SUBLANG_MALAY_MALAYSIA = 1
  121. SUBLANG_MALAY_BRUNEI_DARUSSALAM = 2
  122. SUBLANG_NORWEGIAN_BOKMAL = 1
  123. SUBLANG_NORWEGIAN_NYNORSK = 2
  124. SUBLANG_PORTUGUESE = 2
  125. SUBLANG_PORTUGUESE_BRAZILIAN = 1
  126. SUBLANG_SERBIAN_LATIN = 2
  127. SUBLANG_SERBIAN_CYRILLIC = 3
  128. SUBLANG_SPANISH = 1
  129. SUBLANG_SPANISH_MEXICAN = 2
  130. SUBLANG_SPANISH_MODERN = 3
  131. SUBLANG_SPANISH_GUATEMALA = 4
  132. SUBLANG_SPANISH_COSTA_RICA = 5
  133. SUBLANG_SPANISH_PANAMA = 6
  134. SUBLANG_SPANISH_DOMINICAN_REPUBLIC = 7
  135. SUBLANG_SPANISH_VENEZUELA = 8
  136. SUBLANG_SPANISH_COLOMBIA = 9
  137. SUBLANG_SPANISH_PERU = 10
  138. SUBLANG_SPANISH_ARGENTINA = 11
  139. SUBLANG_SPANISH_ECUADOR = 12
  140. SUBLANG_SPANISH_CHILE = 13
  141. SUBLANG_SPANISH_URUGUAY = 14
  142. SUBLANG_SPANISH_PARAGUAY = 15
  143. SUBLANG_SPANISH_BOLIVIA = 16
  144. SUBLANG_SPANISH_EL_SALVADOR = 17
  145. SUBLANG_SPANISH_HONDURAS = 18
  146. SUBLANG_SPANISH_NICARAGUA = 19
  147. SUBLANG_SPANISH_PUERTO_RICO = 20
  148. SUBLANG_SWEDISH = 1
  149. SUBLANG_SWEDISH_FINLAND = 2
  150. SORT_DEFAULT = 0
  151. SORT_JAPANESE_XJIS = 0
  152. SORT_JAPANESE_UNICODE = 1
  153. SORT_CHINESE_BIG5 = 0
  154. SORT_CHINESE_PRCP = 0
  155. SORT_CHINESE_UNICODE = 1
  156. SORT_CHINESE_PRC = 2
  157. SORT_KOREAN_KSC = 0
  158. SORT_KOREAN_UNICODE = 1
  159. SORT_GERMAN_PHONE_BOOK = 1
  160. def PRIMARYLANGID(lgid):
  161. return (WORD)(lgid) & 1023
  162. def SUBLANGID(lgid):
  163. return (WORD)(lgid) >> 10
  164. NLS_VALID_LOCALE_MASK = 1048575
  165. def LANGIDFROMLCID(lcid):
  166. return (WORD)(lcid)
  167. def SORTIDFROMLCID(lcid):
  168. return (WORD)((((DWORD)(lcid)) & NLS_VALID_LOCALE_MASK) >> 16)
  169. def UNREFERENCED_PARAMETER(P):
  170. return P
  171. def DBG_UNREFERENCED_PARAMETER(P):
  172. return P
  173. def DBG_UNREFERENCED_LOCAL_VARIABLE(V):
  174. return V
  175. def UNREFERENCED_PARAMETER(P):
  176. return
  177. def DBG_UNREFERENCED_PARAMETER(P):
  178. return
  179. def DBG_UNREFERENCED_LOCAL_VARIABLE(V):
  180. return
  181. MAXIMUM_WAIT_OBJECTS = 64
  182. MAXIMUM_SUSPEND_COUNT = MAXCHAR
  183. EXCEPTION_NONCONTINUABLE = 1
  184. EXCEPTION_MAXIMUM_PARAMETERS = 15
  185. PROCESS_TERMINATE = 1
  186. PROCESS_CREATE_THREAD = 2
  187. PROCESS_VM_OPERATION = 8
  188. PROCESS_VM_READ = 16
  189. PROCESS_VM_WRITE = 32
  190. PROCESS_DUP_HANDLE = 64
  191. PROCESS_CREATE_PROCESS = 128
  192. PROCESS_SET_QUOTA = 256
  193. PROCESS_SET_INFORMATION = 512
  194. PROCESS_QUERY_INFORMATION = 1024
  195. PROCESS_SUSPEND_RESUME = 2048
  196. PROCESS_QUERY_LIMITED_INFORMATION = 4096
  197. PROCESS_SET_LIMITED_INFORMATION = 8192
  198. MAXIMUM_PROCESSORS = 32
  199. THREAD_TERMINATE = 1
  200. THREAD_SUSPEND_RESUME = 2
  201. THREAD_GET_CONTEXT = 8
  202. THREAD_SET_CONTEXT = 16
  203. THREAD_SET_INFORMATION = 32
  204. THREAD_QUERY_INFORMATION = 64
  205. THREAD_SET_THREAD_TOKEN = 128
  206. THREAD_IMPERSONATE = 256
  207. THREAD_DIRECT_IMPERSONATION = 512
  208. THREAD_SET_LIMITED_INFORMATION = 1024
  209. THREAD_QUERY_LIMITED_INFORMATION = 2048
  210. THREAD_RESUME = 4096
  211. JOB_OBJECT_ASSIGN_PROCESS = 1
  212. JOB_OBJECT_SET_ATTRIBUTES = 2
  213. JOB_OBJECT_QUERY = 4
  214. JOB_OBJECT_TERMINATE = 8
  215. TLS_MINIMUM_AVAILABLE = 64
  216. THREAD_BASE_PRIORITY_LOWRT = 15
  217. THREAD_BASE_PRIORITY_MAX = 2
  218. THREAD_BASE_PRIORITY_MIN = -2
  219. THREAD_BASE_PRIORITY_IDLE = -15
  220. JOB_OBJECT_LIMIT_WORKINGSET = 1
  221. JOB_OBJECT_LIMIT_PROCESS_TIME = 2
  222. JOB_OBJECT_LIMIT_JOB_TIME = 4
  223. JOB_OBJECT_LIMIT_ACTIVE_PROCESS = 8
  224. JOB_OBJECT_LIMIT_AFFINITY = 16
  225. JOB_OBJECT_LIMIT_PRIORITY_CLASS = 32
  226. JOB_OBJECT_LIMIT_VALID_FLAGS = 63
  227. EVENT_MODIFY_STATE = 2
  228. MUTANT_QUERY_STATE = 1
  229. SEMAPHORE_MODIFY_STATE = 2
  230. TIME_ZONE_ID_UNKNOWN = 0
  231. TIME_ZONE_ID_STANDARD = 1
  232. TIME_ZONE_ID_DAYLIGHT = 2
  233. PROCESSOR_INTEL_386 = 386
  234. PROCESSOR_INTEL_486 = 486
  235. PROCESSOR_INTEL_PENTIUM = 586
  236. PROCESSOR_MIPS_R4000 = 4000
  237. PROCESSOR_ALPHA_21064 = 21064
  238. PROCESSOR_HITACHI_SH3 = 10003
  239. PROCESSOR_HITACHI_SH3E = 10004
  240. PROCESSOR_HITACHI_SH4 = 10005
  241. PROCESSOR_MOTOROLA_821 = 821
  242. PROCESSOR_ARM_7TDMI = 70001
  243. PROCESSOR_ARCHITECTURE_INTEL = 0
  244. PROCESSOR_ARCHITECTURE_MIPS = 1
  245. PROCESSOR_ARCHITECTURE_ALPHA = 2
  246. PROCESSOR_ARCHITECTURE_PPC = 3
  247. PROCESSOR_ARCHITECTURE_SH = 4
  248. PROCESSOR_ARCHITECTURE_ARM = 5
  249. PROCESSOR_ARCHITECTURE_IA64 = 6
  250. PROCESSOR_ARCHITECTURE_ALPHA64 = 7
  251. PROCESSOR_ARCHITECTURE_MSIL = 8
  252. PROCESSOR_ARCHITECTURE_AMD64 = 9
  253. PROCESSOR_ARCHITECTURE_IA32_ON_WIN64 = 10
  254. PROCESSOR_ARCHITECTURE_UNKNOWN = 65535
  255. PF_FLOATING_POINT_PRECISION_ERRATA = 0
  256. PF_FLOATING_POINT_EMULATED = 1
  257. PF_COMPARE_EXCHANGE_DOUBLE = 2
  258. PF_MMX_INSTRUCTIONS_AVAILABLE = 3
  259. PF_PPC_MOVEMEM_64BIT_OK = 4
  260. PF_ALPHA_BYTE_INSTRUCTIONS = 5
  261. SECTION_QUERY = 1
  262. SECTION_MAP_WRITE = 2
  263. SECTION_MAP_READ = 4
  264. SECTION_MAP_EXECUTE = 8
  265. SECTION_EXTEND_SIZE = 16
  266. PAGE_NOACCESS = 1
  267. PAGE_READONLY = 2
  268. PAGE_READWRITE = 4
  269. PAGE_WRITECOPY = 8
  270. PAGE_EXECUTE = 16
  271. PAGE_EXECUTE_READ = 32
  272. PAGE_EXECUTE_READWRITE = 64
  273. PAGE_EXECUTE_WRITECOPY = 128
  274. PAGE_GUARD = 256
  275. PAGE_NOCACHE = 512
  276. MEM_COMMIT = 4096
  277. MEM_RESERVE = 8192
  278. MEM_DECOMMIT = 16384
  279. MEM_RELEASE = 32768
  280. MEM_FREE = 65536
  281. MEM_PRIVATE = 131072
  282. MEM_MAPPED = 262144
  283. MEM_RESET = 524288
  284. MEM_TOP_DOWN = 1048576
  285. MEM_4MB_PAGES = -2147483648
  286. SEC_FILE = 8388608
  287. SEC_IMAGE = 16777216
  288. SEC_VLM = 33554432
  289. SEC_RESERVE = 67108864
  290. SEC_COMMIT = 134217728
  291. SEC_NOCACHE = 268435456
  292. MEM_IMAGE = SEC_IMAGE
  293. FILE_READ_DATA = 1
  294. FILE_LIST_DIRECTORY = 1
  295. FILE_WRITE_DATA = 2
  296. FILE_ADD_FILE = 2
  297. FILE_APPEND_DATA = 4
  298. FILE_ADD_SUBDIRECTORY = 4
  299. FILE_CREATE_PIPE_INSTANCE = 4
  300. FILE_READ_EA = 8
  301. FILE_WRITE_EA = 16
  302. FILE_EXECUTE = 32
  303. FILE_TRAVERSE = 32
  304. FILE_DELETE_CHILD = 64
  305. FILE_READ_ATTRIBUTES = 128
  306. FILE_WRITE_ATTRIBUTES = 256
  307. FILE_SHARE_READ = 1
  308. FILE_SHARE_WRITE = 2
  309. FILE_SHARE_DELETE = 4
  310. FILE_ATTRIBUTE_READONLY = 1
  311. FILE_ATTRIBUTE_HIDDEN = 2
  312. FILE_ATTRIBUTE_SYSTEM = 4
  313. FILE_ATTRIBUTE_DIRECTORY = 16
  314. FILE_ATTRIBUTE_ARCHIVE = 32
  315. FILE_ATTRIBUTE_DEVICE = 64
  316. FILE_ATTRIBUTE_NORMAL = 128
  317. FILE_ATTRIBUTE_TEMPORARY = 256
  318. FILE_ATTRIBUTE_SPARSE_FILE = 512
  319. FILE_ATTRIBUTE_REPARSE_POINT = 1024
  320. FILE_ATTRIBUTE_COMPRESSED = 2048
  321. FILE_ATTRIBUTE_OFFLINE = 4096
  322. FILE_ATTRIBUTE_NOT_CONTENT_INDEXED = 8192
  323. FILE_ATTRIBUTE_ENCRYPTED = 16384
  324. FILE_ATTRIBUTE_VIRTUAL = 65536
  325. FILE_NOTIFY_CHANGE_FILE_NAME = 1
  326. FILE_NOTIFY_CHANGE_DIR_NAME = 2
  327. FILE_NOTIFY_CHANGE_ATTRIBUTES = 4
  328. FILE_NOTIFY_CHANGE_SIZE = 8
  329. FILE_NOTIFY_CHANGE_LAST_WRITE = 16
  330. FILE_NOTIFY_CHANGE_LAST_ACCESS = 32
  331. FILE_NOTIFY_CHANGE_CREATION = 64
  332. FILE_NOTIFY_CHANGE_SECURITY = 256
  333. FILE_ACTION_ADDED = 1
  334. FILE_ACTION_REMOVED = 2
  335. FILE_ACTION_MODIFIED = 3
  336. FILE_ACTION_RENAMED_OLD_NAME = 4
  337. FILE_ACTION_RENAMED_NEW_NAME = 5
  338. FILE_CASE_SENSITIVE_SEARCH = 1
  339. FILE_CASE_PRESERVED_NAMES = 2
  340. FILE_UNICODE_ON_DISK = 4
  341. FILE_PERSISTENT_ACLS = 8
  342. FILE_FILE_COMPRESSION = 16
  343. FILE_VOLUME_QUOTAS = 32
  344. FILE_SUPPORTS_SPARSE_FILES = 64
  345. FILE_SUPPORTS_REPARSE_POINTS = 128
  346. FILE_SUPPORTS_REMOTE_STORAGE = 256
  347. FILE_VOLUME_IS_COMPRESSED = 32768
  348. FILE_SUPPORTS_OBJECT_IDS = 65536
  349. FILE_SUPPORTS_ENCRYPTION = 131072
  350. MAXIMUM_REPARSE_DATA_BUFFER_SIZE = 16 * 1024
  351. IO_REPARSE_TAG_RESERVED_ZERO = 0
  352. IO_REPARSE_TAG_RESERVED_ONE = 1
  353. IO_REPARSE_TAG_SYMBOLIC_LINK = 2
  354. IO_REPARSE_TAG_NSS = 5
  355. IO_REPARSE_TAG_FILTER_MANAGER = -2147483637
  356. IO_REPARSE_TAG_DFS = -2147483638
  357. IO_REPARSE_TAG_SIS = -2147483641
  358. IO_REPARSE_TAG_MOUNT_POINT = -1610612733
  359. IO_REPARSE_TAG_HSM = -1073741820
  360. IO_REPARSE_TAG_NSSRECOVER = 8
  361. IO_REPARSE_TAG_RESERVED_MS_RANGE = 256
  362. IO_REPARSE_TAG_RESERVED_RANGE = IO_REPARSE_TAG_RESERVED_ONE
  363. IO_COMPLETION_MODIFY_STATE = 2
  364. DUPLICATE_CLOSE_SOURCE = 1
  365. DUPLICATE_SAME_ACCESS = 2
  366. DELETE = 65536
  367. READ_CONTROL = 131072
  368. WRITE_DAC = 262144
  369. WRITE_OWNER = 524288
  370. SYNCHRONIZE = 1048576
  371. STANDARD_RIGHTS_REQUIRED = 983040
  372. STANDARD_RIGHTS_READ = READ_CONTROL
  373. STANDARD_RIGHTS_WRITE = READ_CONTROL
  374. STANDARD_RIGHTS_EXECUTE = READ_CONTROL
  375. STANDARD_RIGHTS_ALL = 2031616
  376. SPECIFIC_RIGHTS_ALL = 65535
  377. IO_COMPLETION_ALL_ACCESS = STANDARD_RIGHTS_REQUIRED | SYNCHRONIZE | 0x3
  378. ACCESS_SYSTEM_SECURITY = 16777216
  379. MAXIMUM_ALLOWED = 33554432
  380. GENERIC_READ = -2147483648
  381. GENERIC_WRITE = 1073741824
  382. GENERIC_EXECUTE = 536870912
  383. GENERIC_ALL = 268435456
  384. # Included from pshpack4.h
  385. # Included from poppack.h
  386. SID_REVISION = 1
  387. SID_MAX_SUB_AUTHORITIES = 15
  388. SID_RECOMMENDED_SUB_AUTHORITIES = 1
  389. SidTypeUser = 1
  390. SidTypeGroup = 2
  391. SidTypeDomain = 3
  392. SidTypeAlias = 4
  393. SidTypeWellKnownGroup = 5
  394. SidTypeDeletedAccount = 6
  395. SidTypeInvalid = 7
  396. SidTypeUnknown = 8
  397. SECURITY_NULL_RID = 0
  398. SECURITY_WORLD_RID = 0
  399. SECURITY_LOCAL_RID = 0x00000000
  400. SECURITY_CREATOR_OWNER_RID = 0
  401. SECURITY_CREATOR_GROUP_RID = 1
  402. SECURITY_CREATOR_OWNER_SERVER_RID = 2
  403. SECURITY_CREATOR_GROUP_SERVER_RID = 3
  404. SECURITY_DIALUP_RID = 1
  405. SECURITY_NETWORK_RID = 2
  406. SECURITY_BATCH_RID = 3
  407. SECURITY_INTERACTIVE_RID = 4
  408. SECURITY_SERVICE_RID = 6
  409. SECURITY_ANONYMOUS_LOGON_RID = 7
  410. SECURITY_PROXY_RID = 8
  411. SECURITY_SERVER_LOGON_RID = 9
  412. SECURITY_PRINCIPAL_SELF_RID = 10
  413. SECURITY_AUTHENTICATED_USER_RID = 11
  414. SECURITY_LOGON_IDS_RID = 5
  415. SECURITY_LOGON_IDS_RID_COUNT = 3
  416. SECURITY_LOCAL_SYSTEM_RID = 18
  417. SECURITY_NT_NON_UNIQUE = 21
  418. SECURITY_BUILTIN_DOMAIN_RID = 32
  419. DOMAIN_USER_RID_ADMIN = 500
  420. DOMAIN_USER_RID_GUEST = 501
  421. DOMAIN_GROUP_RID_ADMINS = 512
  422. DOMAIN_GROUP_RID_USERS = 513
  423. DOMAIN_GROUP_RID_GUESTS = 514
  424. DOMAIN_ALIAS_RID_ADMINS = 544
  425. DOMAIN_ALIAS_RID_USERS = 545
  426. DOMAIN_ALIAS_RID_GUESTS = 546
  427. DOMAIN_ALIAS_RID_POWER_USERS = 547
  428. DOMAIN_ALIAS_RID_ACCOUNT_OPS = 548
  429. DOMAIN_ALIAS_RID_SYSTEM_OPS = 549
  430. DOMAIN_ALIAS_RID_PRINT_OPS = 550
  431. DOMAIN_ALIAS_RID_BACKUP_OPS = 551
  432. DOMAIN_ALIAS_RID_REPLICATOR = 552
  433. SE_GROUP_MANDATORY = 1
  434. SE_GROUP_ENABLED_BY_DEFAULT = 2
  435. SE_GROUP_ENABLED = 4
  436. SE_GROUP_OWNER = 8
  437. SE_GROUP_LOGON_ID = -1073741824
  438. ACL_REVISION = 2
  439. ACL_REVISION_DS = 4
  440. ACL_REVISION1 = 1
  441. ACL_REVISION2 = 2
  442. ACL_REVISION3 = 3
  443. ACL_REVISION4 = 4
  444. MAX_ACL_REVISION = ACL_REVISION4
  445. ## ACE types
  446. ACCESS_MIN_MS_ACE_TYPE = 0
  447. ACCESS_ALLOWED_ACE_TYPE = 0
  448. ACCESS_DENIED_ACE_TYPE = 1
  449. SYSTEM_AUDIT_ACE_TYPE = 2
  450. SYSTEM_ALARM_ACE_TYPE = 3
  451. ACCESS_MAX_MS_V2_ACE_TYPE = 3
  452. ACCESS_ALLOWED_COMPOUND_ACE_TYPE = 4
  453. ACCESS_MAX_MS_V3_ACE_TYPE = 4
  454. ACCESS_MIN_MS_OBJECT_ACE_TYPE = 5
  455. ACCESS_ALLOWED_OBJECT_ACE_TYPE = 5
  456. ACCESS_DENIED_OBJECT_ACE_TYPE = 6
  457. SYSTEM_AUDIT_OBJECT_ACE_TYPE = 7
  458. SYSTEM_ALARM_OBJECT_ACE_TYPE = 8
  459. ACCESS_MAX_MS_OBJECT_ACE_TYPE = 8
  460. ACCESS_MAX_MS_V4_ACE_TYPE = 8
  461. ACCESS_MAX_MS_ACE_TYPE = 8
  462. ACCESS_ALLOWED_CALLBACK_ACE_TYPE = 9
  463. ACCESS_DENIED_CALLBACK_ACE_TYPE = 10
  464. ACCESS_ALLOWED_CALLBACK_OBJECT_ACE_TYPE = 11
  465. ACCESS_DENIED_CALLBACK_OBJECT_ACE_TYPE = 12
  466. SYSTEM_AUDIT_CALLBACK_ACE_TYPE = 13
  467. SYSTEM_ALARM_CALLBACK_ACE_TYPE = 14
  468. SYSTEM_AUDIT_CALLBACK_OBJECT_ACE_TYPE = 15
  469. SYSTEM_ALARM_CALLBACK_OBJECT_ACE_TYPE = 16
  470. SYSTEM_MANDATORY_LABEL_ACE_TYPE = 17
  471. ACCESS_MAX_MS_V5_ACE_TYPE = 17
  472. ## ACE inheritance flags
  473. OBJECT_INHERIT_ACE = 1
  474. CONTAINER_INHERIT_ACE = 2
  475. NO_PROPAGATE_INHERIT_ACE = 4
  476. INHERIT_ONLY_ACE = 8
  477. INHERITED_ACE = 16
  478. VALID_INHERIT_FLAGS = 31
  479. SUCCESSFUL_ACCESS_ACE_FLAG = 64
  480. FAILED_ACCESS_ACE_FLAG = 128
  481. ACE_OBJECT_TYPE_PRESENT = 1
  482. ACE_INHERITED_OBJECT_TYPE_PRESENT = 2
  483. SECURITY_DESCRIPTOR_REVISION = 1
  484. SECURITY_DESCRIPTOR_REVISION1 = 1
  485. SECURITY_DESCRIPTOR_MIN_LENGTH = 20
  486. SE_OWNER_DEFAULTED = 1
  487. SE_GROUP_DEFAULTED = 2
  488. SE_DACL_PRESENT = 4
  489. SE_DACL_DEFAULTED = 8
  490. SE_SACL_PRESENT = 16
  491. SE_SACL_DEFAULTED = 32
  492. SE_DACL_AUTO_INHERIT_REQ = 256
  493. SE_SACL_AUTO_INHERIT_REQ = 512
  494. SE_DACL_AUTO_INHERITED = 1024
  495. SE_SACL_AUTO_INHERITED = 2048
  496. SE_DACL_PROTECTED = 4096
  497. SE_SACL_PROTECTED = 8192
  498. SE_SELF_RELATIVE = 32768
  499. ACCESS_OBJECT_GUID = 0
  500. ACCESS_PROPERTY_SET_GUID = 1
  501. ACCESS_PROPERTY_GUID = 2
  502. ACCESS_MAX_LEVEL = 4
  503. AUDIT_ALLOW_NO_PRIVILEGE = 1
  504. ACCESS_DS_SOURCE_A = "Directory Service"
  505. ACCESS_DS_OBJECT_TYPE_NAME_A = "Directory Service Object"
  506. SE_PRIVILEGE_ENABLED_BY_DEFAULT = 1
  507. SE_PRIVILEGE_ENABLED = 2
  508. SE_PRIVILEGE_USED_FOR_ACCESS = -2147483648
  509. PRIVILEGE_SET_ALL_NECESSARY = 1
  510. SE_CREATE_TOKEN_NAME = "SeCreateTokenPrivilege"
  511. SE_ASSIGNPRIMARYTOKEN_NAME = "SeAssignPrimaryTokenPrivilege"
  512. SE_LOCK_MEMORY_NAME = "SeLockMemoryPrivilege"
  513. SE_INCREASE_QUOTA_NAME = "SeIncreaseQuotaPrivilege"
  514. SE_UNSOLICITED_INPUT_NAME = "SeUnsolicitedInputPrivilege"
  515. SE_MACHINE_ACCOUNT_NAME = "SeMachineAccountPrivilege"
  516. SE_TCB_NAME = "SeTcbPrivilege"
  517. SE_SECURITY_NAME = "SeSecurityPrivilege"
  518. SE_TAKE_OWNERSHIP_NAME = "SeTakeOwnershipPrivilege"
  519. SE_LOAD_DRIVER_NAME = "SeLoadDriverPrivilege"
  520. SE_SYSTEM_PROFILE_NAME = "SeSystemProfilePrivilege"
  521. SE_SYSTEMTIME_NAME = "SeSystemtimePrivilege"
  522. SE_PROF_SINGLE_PROCESS_NAME = "SeProfileSingleProcessPrivilege"
  523. SE_INC_BASE_PRIORITY_NAME = "SeIncreaseBasePriorityPrivilege"
  524. SE_CREATE_PAGEFILE_NAME = "SeCreatePagefilePrivilege"
  525. SE_CREATE_PERMANENT_NAME = "SeCreatePermanentPrivilege"
  526. SE_BACKUP_NAME = "SeBackupPrivilege"
  527. SE_RESTORE_NAME = "SeRestorePrivilege"
  528. SE_SHUTDOWN_NAME = "SeShutdownPrivilege"
  529. SE_DEBUG_NAME = "SeDebugPrivilege"
  530. SE_AUDIT_NAME = "SeAuditPrivilege"
  531. SE_SYSTEM_ENVIRONMENT_NAME = "SeSystemEnvironmentPrivilege"
  532. SE_CHANGE_NOTIFY_NAME = "SeChangeNotifyPrivilege"
  533. SE_REMOTE_SHUTDOWN_NAME = "SeRemoteShutdownPrivilege"
  534. TOKEN_ASSIGN_PRIMARY = 1
  535. TOKEN_DUPLICATE = 2
  536. TOKEN_IMPERSONATE = 4
  537. TOKEN_QUERY = 8
  538. TOKEN_QUERY_SOURCE = 16
  539. TOKEN_ADJUST_PRIVILEGES = 32
  540. TOKEN_ADJUST_GROUPS = 64
  541. TOKEN_ADJUST_DEFAULT = 128
  542. TOKEN_ALL_ACCESS = (
  543. STANDARD_RIGHTS_REQUIRED
  544. | TOKEN_ASSIGN_PRIMARY
  545. | TOKEN_DUPLICATE
  546. | TOKEN_IMPERSONATE
  547. | TOKEN_QUERY
  548. | TOKEN_QUERY_SOURCE
  549. | TOKEN_ADJUST_PRIVILEGES
  550. | TOKEN_ADJUST_GROUPS
  551. | TOKEN_ADJUST_DEFAULT
  552. )
  553. TOKEN_READ = STANDARD_RIGHTS_READ | TOKEN_QUERY
  554. TOKEN_WRITE = (
  555. STANDARD_RIGHTS_WRITE
  556. | TOKEN_ADJUST_PRIVILEGES
  557. | TOKEN_ADJUST_GROUPS
  558. | TOKEN_ADJUST_DEFAULT
  559. )
  560. TOKEN_EXECUTE = STANDARD_RIGHTS_EXECUTE
  561. TOKEN_SOURCE_LENGTH = 8
  562. # Token types
  563. TokenPrimary = 1
  564. TokenImpersonation = 2
  565. # TOKEN_INFORMATION_CLASS, used with Get/SetTokenInformation
  566. TokenUser = 1
  567. TokenGroups = 2
  568. TokenPrivileges = 3
  569. TokenOwner = 4
  570. TokenPrimaryGroup = 5
  571. TokenDefaultDacl = 6
  572. TokenSource = 7
  573. TokenType = 8
  574. TokenImpersonationLevel = 9
  575. TokenStatistics = 10
  576. TokenRestrictedSids = 11
  577. TokenSessionId = 12
  578. TokenGroupsAndPrivileges = 13
  579. TokenSessionReference = 14
  580. TokenSandBoxInert = 15
  581. TokenAuditPolicy = 16
  582. TokenOrigin = 17
  583. TokenElevationType = 18
  584. TokenLinkedToken = 19
  585. TokenElevation = 20
  586. TokenHasRestrictions = 21
  587. TokenAccessInformation = 22
  588. TokenVirtualizationAllowed = 23
  589. TokenVirtualizationEnabled = 24
  590. TokenIntegrityLevel = 25
  591. TokenUIAccess = 26
  592. TokenMandatoryPolicy = 27
  593. TokenLogonSid = 28
  594. OWNER_SECURITY_INFORMATION = 0x00000001
  595. GROUP_SECURITY_INFORMATION = 0x00000002
  596. DACL_SECURITY_INFORMATION = 0x00000004
  597. SACL_SECURITY_INFORMATION = 0x00000008
  598. LABEL_SECURITY_INFORMATION = 0x00000010
  599. IMAGE_DOS_SIGNATURE = 23117
  600. IMAGE_OS2_SIGNATURE = 17742
  601. IMAGE_OS2_SIGNATURE_LE = 17740
  602. IMAGE_VXD_SIGNATURE = 17740
  603. IMAGE_NT_SIGNATURE = 17744
  604. IMAGE_SIZEOF_FILE_HEADER = 20
  605. IMAGE_FILE_RELOCS_STRIPPED = 1
  606. IMAGE_FILE_EXECUTABLE_IMAGE = 2
  607. IMAGE_FILE_LINE_NUMS_STRIPPED = 4
  608. IMAGE_FILE_LOCAL_SYMS_STRIPPED = 8
  609. IMAGE_FILE_AGGRESIVE_WS_TRIM = 16
  610. IMAGE_FILE_LARGE_ADDRESS_AWARE = 32
  611. IMAGE_FILE_BYTES_REVERSED_LO = 128
  612. IMAGE_FILE_32BIT_MACHINE = 256
  613. IMAGE_FILE_DEBUG_STRIPPED = 512
  614. IMAGE_FILE_REMOVABLE_RUN_FROM_SWAP = 1024
  615. IMAGE_FILE_NET_RUN_FROM_SWAP = 2048
  616. IMAGE_FILE_SYSTEM = 4096
  617. IMAGE_FILE_DLL = 8192
  618. IMAGE_FILE_UP_SYSTEM_ONLY = 16384
  619. IMAGE_FILE_BYTES_REVERSED_HI = 32768
  620. IMAGE_FILE_MACHINE_UNKNOWN = 0
  621. IMAGE_FILE_MACHINE_I386 = 332
  622. IMAGE_FILE_MACHINE_R3000 = 354
  623. IMAGE_FILE_MACHINE_R4000 = 358
  624. IMAGE_FILE_MACHINE_R10000 = 360
  625. IMAGE_FILE_MACHINE_WCEMIPSV2 = 361
  626. IMAGE_FILE_MACHINE_ALPHA = 388
  627. IMAGE_FILE_MACHINE_POWERPC = 496
  628. IMAGE_FILE_MACHINE_SH3 = 418
  629. IMAGE_FILE_MACHINE_SH3E = 420
  630. IMAGE_FILE_MACHINE_SH4 = 422
  631. IMAGE_FILE_MACHINE_ARM = 448
  632. IMAGE_NUMBEROF_DIRECTORY_ENTRIES = 16
  633. IMAGE_SIZEOF_ROM_OPTIONAL_HEADER = 56
  634. IMAGE_SIZEOF_STD_OPTIONAL_HEADER = 28
  635. IMAGE_SIZEOF_NT_OPTIONAL_HEADER = 224
  636. IMAGE_NT_OPTIONAL_HDR_MAGIC = 267
  637. IMAGE_ROM_OPTIONAL_HDR_MAGIC = 263
  638. IMAGE_SUBSYSTEM_UNKNOWN = 0
  639. IMAGE_SUBSYSTEM_NATIVE = 1
  640. IMAGE_SUBSYSTEM_WINDOWS_GUI = 2
  641. IMAGE_SUBSYSTEM_WINDOWS_CUI = 3
  642. IMAGE_SUBSYSTEM_WINDOWS_CE_GUI = 4
  643. IMAGE_SUBSYSTEM_OS2_CUI = 5
  644. IMAGE_SUBSYSTEM_POSIX_CUI = 7
  645. IMAGE_SUBSYSTEM_RESERVED8 = 8
  646. IMAGE_DLLCHARACTERISTICS_WDM_DRIVER = 8192
  647. IMAGE_DIRECTORY_ENTRY_EXPORT = 0
  648. IMAGE_DIRECTORY_ENTRY_IMPORT = 1
  649. IMAGE_DIRECTORY_ENTRY_RESOURCE = 2
  650. IMAGE_DIRECTORY_ENTRY_EXCEPTION = 3
  651. IMAGE_DIRECTORY_ENTRY_SECURITY = 4
  652. IMAGE_DIRECTORY_ENTRY_BASERELOC = 5
  653. IMAGE_DIRECTORY_ENTRY_DEBUG = 6
  654. IMAGE_DIRECTORY_ENTRY_COPYRIGHT = 7
  655. IMAGE_DIRECTORY_ENTRY_GLOBALPTR = 8
  656. IMAGE_DIRECTORY_ENTRY_TLS = 9
  657. IMAGE_DIRECTORY_ENTRY_LOAD_CONFIG = 10
  658. IMAGE_DIRECTORY_ENTRY_BOUND_IMPORT = 11
  659. IMAGE_DIRECTORY_ENTRY_IAT = 12
  660. IMAGE_SIZEOF_SHORT_NAME = 8
  661. IMAGE_SIZEOF_SECTION_HEADER = 40
  662. IMAGE_SCN_TYPE_NO_PAD = 8
  663. IMAGE_SCN_CNT_CODE = 32
  664. IMAGE_SCN_CNT_INITIALIZED_DATA = 64
  665. IMAGE_SCN_CNT_UNINITIALIZED_DATA = 128
  666. IMAGE_SCN_LNK_OTHER = 256
  667. IMAGE_SCN_LNK_INFO = 512
  668. IMAGE_SCN_LNK_REMOVE = 2048
  669. IMAGE_SCN_LNK_COMDAT = 4096
  670. IMAGE_SCN_MEM_FARDATA = 32768
  671. IMAGE_SCN_MEM_PURGEABLE = 131072
  672. IMAGE_SCN_MEM_16BIT = 131072
  673. IMAGE_SCN_MEM_LOCKED = 262144
  674. IMAGE_SCN_MEM_PRELOAD = 524288
  675. IMAGE_SCN_ALIGN_1BYTES = 1048576
  676. IMAGE_SCN_ALIGN_2BYTES = 2097152
  677. IMAGE_SCN_ALIGN_4BYTES = 3145728
  678. IMAGE_SCN_ALIGN_8BYTES = 4194304
  679. IMAGE_SCN_ALIGN_16BYTES = 5242880
  680. IMAGE_SCN_ALIGN_32BYTES = 6291456
  681. IMAGE_SCN_ALIGN_64BYTES = 7340032
  682. IMAGE_SCN_LNK_NRELOC_OVFL = 16777216
  683. IMAGE_SCN_MEM_DISCARDABLE = 33554432
  684. IMAGE_SCN_MEM_NOT_CACHED = 67108864
  685. IMAGE_SCN_MEM_NOT_PAGED = 134217728
  686. IMAGE_SCN_MEM_SHARED = 268435456
  687. IMAGE_SCN_MEM_EXECUTE = 536870912
  688. IMAGE_SCN_MEM_READ = 1073741824
  689. IMAGE_SCN_MEM_WRITE = -2147483648
  690. IMAGE_SCN_SCALE_INDEX = 1
  691. IMAGE_SIZEOF_SYMBOL = 18
  692. IMAGE_SYM_TYPE_NULL = 0
  693. IMAGE_SYM_TYPE_VOID = 1
  694. IMAGE_SYM_TYPE_CHAR = 2
  695. IMAGE_SYM_TYPE_SHORT = 3
  696. IMAGE_SYM_TYPE_INT = 4
  697. IMAGE_SYM_TYPE_LONG = 5
  698. IMAGE_SYM_TYPE_FLOAT = 6
  699. IMAGE_SYM_TYPE_DOUBLE = 7
  700. IMAGE_SYM_TYPE_STRUCT = 8
  701. IMAGE_SYM_TYPE_UNION = 9
  702. IMAGE_SYM_TYPE_ENUM = 10
  703. IMAGE_SYM_TYPE_MOE = 11
  704. IMAGE_SYM_TYPE_BYTE = 12
  705. IMAGE_SYM_TYPE_WORD = 13
  706. IMAGE_SYM_TYPE_UINT = 14
  707. IMAGE_SYM_TYPE_DWORD = 15
  708. IMAGE_SYM_TYPE_PCODE = 32768
  709. IMAGE_SYM_DTYPE_NULL = 0
  710. IMAGE_SYM_DTYPE_POINTER = 1
  711. IMAGE_SYM_DTYPE_FUNCTION = 2
  712. IMAGE_SYM_DTYPE_ARRAY = 3
  713. IMAGE_SYM_CLASS_NULL = 0
  714. IMAGE_SYM_CLASS_AUTOMATIC = 1
  715. IMAGE_SYM_CLASS_EXTERNAL = 2
  716. IMAGE_SYM_CLASS_STATIC = 3
  717. IMAGE_SYM_CLASS_REGISTER = 4
  718. IMAGE_SYM_CLASS_EXTERNAL_DEF = 5
  719. IMAGE_SYM_CLASS_LABEL = 6
  720. IMAGE_SYM_CLASS_UNDEFINED_LABEL = 7
  721. IMAGE_SYM_CLASS_MEMBER_OF_STRUCT = 8
  722. IMAGE_SYM_CLASS_ARGUMENT = 9
  723. IMAGE_SYM_CLASS_STRUCT_TAG = 10
  724. IMAGE_SYM_CLASS_MEMBER_OF_UNION = 11
  725. IMAGE_SYM_CLASS_UNION_TAG = 12
  726. IMAGE_SYM_CLASS_TYPE_DEFINITION = 13
  727. IMAGE_SYM_CLASS_UNDEFINED_STATIC = 14
  728. IMAGE_SYM_CLASS_ENUM_TAG = 15
  729. IMAGE_SYM_CLASS_MEMBER_OF_ENUM = 16
  730. IMAGE_SYM_CLASS_REGISTER_PARAM = 17
  731. IMAGE_SYM_CLASS_BIT_FIELD = 18
  732. IMAGE_SYM_CLASS_FAR_EXTERNAL = 68
  733. IMAGE_SYM_CLASS_BLOCK = 100
  734. IMAGE_SYM_CLASS_FUNCTION = 101
  735. IMAGE_SYM_CLASS_END_OF_STRUCT = 102
  736. IMAGE_SYM_CLASS_FILE = 103
  737. IMAGE_SYM_CLASS_SECTION = 104
  738. IMAGE_SYM_CLASS_WEAK_EXTERNAL = 105
  739. N_BTMASK = 15
  740. N_TMASK = 48
  741. N_TMASK1 = 192
  742. N_TMASK2 = 240
  743. N_BTSHFT = 4
  744. N_TSHIFT = 2
  745. def BTYPE(x):
  746. return (x) & N_BTMASK
  747. def ISPTR(x):
  748. return ((x) & N_TMASK) == (IMAGE_SYM_DTYPE_POINTER << N_BTSHFT)
  749. def ISFCN(x):
  750. return ((x) & N_TMASK) == (IMAGE_SYM_DTYPE_FUNCTION << N_BTSHFT)
  751. def ISARY(x):
  752. return ((x) & N_TMASK) == (IMAGE_SYM_DTYPE_ARRAY << N_BTSHFT)
  753. def INCREF(x):
  754. return (
  755. (((x) & ~N_BTMASK) << N_TSHIFT)
  756. | (IMAGE_SYM_DTYPE_POINTER << N_BTSHFT)
  757. | ((x) & N_BTMASK)
  758. )
  759. def DECREF(x):
  760. return (((x) >> N_TSHIFT) & ~N_BTMASK) | ((x) & N_BTMASK)
  761. IMAGE_SIZEOF_AUX_SYMBOL = 18
  762. IMAGE_COMDAT_SELECT_NODUPLICATES = 1
  763. IMAGE_COMDAT_SELECT_ANY = 2
  764. IMAGE_COMDAT_SELECT_SAME_SIZE = 3
  765. IMAGE_COMDAT_SELECT_EXACT_MATCH = 4
  766. IMAGE_COMDAT_SELECT_ASSOCIATIVE = 5
  767. IMAGE_COMDAT_SELECT_LARGEST = 6
  768. IMAGE_COMDAT_SELECT_NEWEST = 7
  769. IMAGE_WEAK_EXTERN_SEARCH_NOLIBRARY = 1
  770. IMAGE_WEAK_EXTERN_SEARCH_LIBRARY = 2
  771. IMAGE_WEAK_EXTERN_SEARCH_ALIAS = 3
  772. IMAGE_SIZEOF_RELOCATION = 10
  773. IMAGE_REL_I386_ABSOLUTE = 0
  774. IMAGE_REL_I386_DIR16 = 1
  775. IMAGE_REL_I386_REL16 = 2
  776. IMAGE_REL_I386_DIR32 = 6
  777. IMAGE_REL_I386_DIR32NB = 7
  778. IMAGE_REL_I386_SEG12 = 9
  779. IMAGE_REL_I386_SECTION = 10
  780. IMAGE_REL_I386_SECREL = 11
  781. IMAGE_REL_I386_REL32 = 20
  782. IMAGE_REL_MIPS_ABSOLUTE = 0
  783. IMAGE_REL_MIPS_REFHALF = 1
  784. IMAGE_REL_MIPS_REFWORD = 2
  785. IMAGE_REL_MIPS_JMPADDR = 3
  786. IMAGE_REL_MIPS_REFHI = 4
  787. IMAGE_REL_MIPS_REFLO = 5
  788. IMAGE_REL_MIPS_GPREL = 6
  789. IMAGE_REL_MIPS_LITERAL = 7
  790. IMAGE_REL_MIPS_SECTION = 10
  791. IMAGE_REL_MIPS_SECREL = 11
  792. IMAGE_REL_MIPS_SECRELLO = 12
  793. IMAGE_REL_MIPS_SECRELHI = 13
  794. IMAGE_REL_MIPS_REFWORDNB = 34
  795. IMAGE_REL_MIPS_PAIR = 37
  796. IMAGE_REL_ALPHA_ABSOLUTE = 0
  797. IMAGE_REL_ALPHA_REFLONG = 1
  798. IMAGE_REL_ALPHA_REFQUAD = 2
  799. IMAGE_REL_ALPHA_GPREL32 = 3
  800. IMAGE_REL_ALPHA_LITERAL = 4
  801. IMAGE_REL_ALPHA_LITUSE = 5
  802. IMAGE_REL_ALPHA_GPDISP = 6
  803. IMAGE_REL_ALPHA_BRADDR = 7
  804. IMAGE_REL_ALPHA_HINT = 8
  805. IMAGE_REL_ALPHA_INLINE_REFLONG = 9
  806. IMAGE_REL_ALPHA_REFHI = 10
  807. IMAGE_REL_ALPHA_REFLO = 11
  808. IMAGE_REL_ALPHA_PAIR = 12
  809. IMAGE_REL_ALPHA_MATCH = 13
  810. IMAGE_REL_ALPHA_SECTION = 14
  811. IMAGE_REL_ALPHA_SECREL = 15
  812. IMAGE_REL_ALPHA_REFLONGNB = 16
  813. IMAGE_REL_ALPHA_SECRELLO = 17
  814. IMAGE_REL_ALPHA_SECRELHI = 18
  815. IMAGE_REL_PPC_ABSOLUTE = 0
  816. IMAGE_REL_PPC_ADDR64 = 1
  817. IMAGE_REL_PPC_ADDR32 = 2
  818. IMAGE_REL_PPC_ADDR24 = 3
  819. IMAGE_REL_PPC_ADDR16 = 4
  820. IMAGE_REL_PPC_ADDR14 = 5
  821. IMAGE_REL_PPC_REL24 = 6
  822. IMAGE_REL_PPC_REL14 = 7
  823. IMAGE_REL_PPC_TOCREL16 = 8
  824. IMAGE_REL_PPC_TOCREL14 = 9
  825. IMAGE_REL_PPC_ADDR32NB = 10
  826. IMAGE_REL_PPC_SECREL = 11
  827. IMAGE_REL_PPC_SECTION = 12
  828. IMAGE_REL_PPC_IFGLUE = 13
  829. IMAGE_REL_PPC_IMGLUE = 14
  830. IMAGE_REL_PPC_SECREL16 = 15
  831. IMAGE_REL_PPC_REFHI = 16
  832. IMAGE_REL_PPC_REFLO = 17
  833. IMAGE_REL_PPC_PAIR = 18
  834. IMAGE_REL_PPC_SECRELLO = 19
  835. IMAGE_REL_PPC_SECRELHI = 20
  836. IMAGE_REL_PPC_TYPEMASK = 255
  837. IMAGE_REL_PPC_NEG = 256
  838. IMAGE_REL_PPC_BRTAKEN = 512
  839. IMAGE_REL_PPC_BRNTAKEN = 1024
  840. IMAGE_REL_PPC_TOCDEFN = 2048
  841. IMAGE_REL_SH3_ABSOLUTE = 0
  842. IMAGE_REL_SH3_DIRECT16 = 1
  843. IMAGE_REL_SH3_DIRECT32 = 2
  844. IMAGE_REL_SH3_DIRECT8 = 3
  845. IMAGE_REL_SH3_DIRECT8_WORD = 4
  846. IMAGE_REL_SH3_DIRECT8_LONG = 5
  847. IMAGE_REL_SH3_DIRECT4 = 6
  848. IMAGE_REL_SH3_DIRECT4_WORD = 7
  849. IMAGE_REL_SH3_DIRECT4_LONG = 8
  850. IMAGE_REL_SH3_PCREL8_WORD = 9
  851. IMAGE_REL_SH3_PCREL8_LONG = 10
  852. IMAGE_REL_SH3_PCREL12_WORD = 11
  853. IMAGE_REL_SH3_STARTOF_SECTION = 12
  854. IMAGE_REL_SH3_SIZEOF_SECTION = 13
  855. IMAGE_REL_SH3_SECTION = 14
  856. IMAGE_REL_SH3_SECREL = 15
  857. IMAGE_REL_SH3_DIRECT32_NB = 16
  858. IMAGE_SIZEOF_LINENUMBER = 6
  859. IMAGE_SIZEOF_BASE_RELOCATION = 8
  860. IMAGE_REL_BASED_ABSOLUTE = 0
  861. IMAGE_REL_BASED_HIGH = 1
  862. IMAGE_REL_BASED_LOW = 2
  863. IMAGE_REL_BASED_HIGHLOW = 3
  864. IMAGE_REL_BASED_HIGHADJ = 4
  865. IMAGE_REL_BASED_MIPS_JMPADDR = 5
  866. IMAGE_REL_BASED_SECTION = 6
  867. IMAGE_REL_BASED_REL32 = 7
  868. IMAGE_ARCHIVE_START_SIZE = 8
  869. IMAGE_ARCHIVE_START = "!<arch>\n"
  870. IMAGE_ARCHIVE_END = "`\n"
  871. IMAGE_ARCHIVE_PAD = "\n"
  872. IMAGE_ARCHIVE_LINKER_MEMBER = "/ "
  873. IMAGE_SIZEOF_ARCHIVE_MEMBER_HDR = 60
  874. IMAGE_ORDINAL_FLAG = -2147483648
  875. def IMAGE_SNAP_BY_ORDINAL(Ordina):
  876. return (Ordinal & IMAGE_ORDINAL_FLAG) != 0
  877. def IMAGE_ORDINAL(Ordina):
  878. return Ordinal & 65535
  879. IMAGE_RESOURCE_NAME_IS_STRING = -2147483648
  880. IMAGE_RESOURCE_DATA_IS_DIRECTORY = -2147483648
  881. IMAGE_DEBUG_TYPE_UNKNOWN = 0
  882. IMAGE_DEBUG_TYPE_COFF = 1
  883. IMAGE_DEBUG_TYPE_CODEVIEW = 2
  884. IMAGE_DEBUG_TYPE_FPO = 3
  885. IMAGE_DEBUG_TYPE_MISC = 4
  886. IMAGE_DEBUG_TYPE_EXCEPTION = 5
  887. IMAGE_DEBUG_TYPE_FIXUP = 6
  888. IMAGE_DEBUG_TYPE_OMAP_TO_SRC = 7
  889. IMAGE_DEBUG_TYPE_OMAP_FROM_SRC = 8
  890. IMAGE_DEBUG_TYPE_BORLAND = 9
  891. FRAME_FPO = 0
  892. FRAME_TRAP = 1
  893. FRAME_TSS = 2
  894. FRAME_NONFPO = 3
  895. SIZEOF_RFPO_DATA = 16
  896. IMAGE_DEBUG_MISC_EXENAME = 1
  897. IMAGE_SEPARATE_DEBUG_SIGNATURE = 18756
  898. IMAGE_SEPARATE_DEBUG_FLAGS_MASK = 32768
  899. IMAGE_SEPARATE_DEBUG_MISMATCH = 32768
  900. # Included from string.h
  901. _NLSCMPERROR = 2147483647
  902. NULL = 0
  903. HEAP_NO_SERIALIZE = 1
  904. HEAP_GROWABLE = 2
  905. HEAP_GENERATE_EXCEPTIONS = 4
  906. HEAP_ZERO_MEMORY = 8
  907. HEAP_REALLOC_IN_PLACE_ONLY = 16
  908. HEAP_TAIL_CHECKING_ENABLED = 32
  909. HEAP_FREE_CHECKING_ENABLED = 64
  910. HEAP_DISABLE_COALESCE_ON_FREE = 128
  911. HEAP_CREATE_ALIGN_16 = 65536
  912. HEAP_CREATE_ENABLE_TRACING = 131072
  913. HEAP_MAXIMUM_TAG = 4095
  914. HEAP_PSEUDO_TAG_FLAG = 32768
  915. HEAP_TAG_SHIFT = 16
  916. IS_TEXT_UNICODE_ASCII16 = 1
  917. IS_TEXT_UNICODE_REVERSE_ASCII16 = 16
  918. IS_TEXT_UNICODE_STATISTICS = 2
  919. IS_TEXT_UNICODE_REVERSE_STATISTICS = 32
  920. IS_TEXT_UNICODE_CONTROLS = 4
  921. IS_TEXT_UNICODE_REVERSE_CONTROLS = 64
  922. IS_TEXT_UNICODE_SIGNATURE = 8
  923. IS_TEXT_UNICODE_REVERSE_SIGNATURE = 128
  924. IS_TEXT_UNICODE_ILLEGAL_CHARS = 256
  925. IS_TEXT_UNICODE_ODD_LENGTH = 512
  926. IS_TEXT_UNICODE_DBCS_LEADBYTE = 1024
  927. IS_TEXT_UNICODE_NULL_BYTES = 4096
  928. IS_TEXT_UNICODE_UNICODE_MASK = 15
  929. IS_TEXT_UNICODE_REVERSE_MASK = 240
  930. IS_TEXT_UNICODE_NOT_UNICODE_MASK = 3840
  931. IS_TEXT_UNICODE_NOT_ASCII_MASK = 61440
  932. COMPRESSION_FORMAT_NONE = 0
  933. COMPRESSION_FORMAT_DEFAULT = 1
  934. COMPRESSION_FORMAT_LZNT1 = 2
  935. COMPRESSION_ENGINE_STANDARD = 0
  936. COMPRESSION_ENGINE_MAXIMUM = 256
  937. MESSAGE_RESOURCE_UNICODE = 1
  938. RTL_CRITSECT_TYPE = 0
  939. RTL_RESOURCE_TYPE = 1
  940. SEF_DACL_AUTO_INHERIT = 1
  941. SEF_SACL_AUTO_INHERIT = 2
  942. SEF_DEFAULT_DESCRIPTOR_FOR_OBJECT = 4
  943. SEF_AVOID_PRIVILEGE_CHECK = 8
  944. DLL_PROCESS_ATTACH = 1
  945. DLL_THREAD_ATTACH = 2
  946. DLL_THREAD_DETACH = 3
  947. DLL_PROCESS_DETACH = 0
  948. EVENTLOG_SEQUENTIAL_READ = 0x0001
  949. EVENTLOG_SEEK_READ = 0x0002
  950. EVENTLOG_FORWARDS_READ = 0x0004
  951. EVENTLOG_BACKWARDS_READ = 0x0008
  952. EVENTLOG_SUCCESS = 0x0000
  953. EVENTLOG_ERROR_TYPE = 1
  954. EVENTLOG_WARNING_TYPE = 2
  955. EVENTLOG_INFORMATION_TYPE = 4
  956. EVENTLOG_AUDIT_SUCCESS = 8
  957. EVENTLOG_AUDIT_FAILURE = 16
  958. EVENTLOG_START_PAIRED_EVENT = 1
  959. EVENTLOG_END_PAIRED_EVENT = 2
  960. EVENTLOG_END_ALL_PAIRED_EVENTS = 4
  961. EVENTLOG_PAIRED_EVENT_ACTIVE = 8
  962. EVENTLOG_PAIRED_EVENT_INACTIVE = 16
  963. KEY_QUERY_VALUE = 1
  964. KEY_SET_VALUE = 2
  965. KEY_CREATE_SUB_KEY = 4
  966. KEY_ENUMERATE_SUB_KEYS = 8
  967. KEY_NOTIFY = 16
  968. KEY_CREATE_LINK = 32
  969. KEY_READ = (
  970. STANDARD_RIGHTS_READ | KEY_QUERY_VALUE | KEY_ENUMERATE_SUB_KEYS | KEY_NOTIFY
  971. ) & (~SYNCHRONIZE)
  972. KEY_WRITE = (STANDARD_RIGHTS_WRITE | KEY_SET_VALUE | KEY_CREATE_SUB_KEY) & (
  973. ~SYNCHRONIZE
  974. )
  975. KEY_EXECUTE = (KEY_READ) & (~SYNCHRONIZE)
  976. KEY_ALL_ACCESS = (
  977. STANDARD_RIGHTS_ALL
  978. | KEY_QUERY_VALUE
  979. | KEY_SET_VALUE
  980. | KEY_CREATE_SUB_KEY
  981. | KEY_ENUMERATE_SUB_KEYS
  982. | KEY_NOTIFY
  983. | KEY_CREATE_LINK
  984. ) & (~SYNCHRONIZE)
  985. REG_OPTION_RESERVED = 0
  986. REG_OPTION_NON_VOLATILE = 0
  987. REG_OPTION_VOLATILE = 1
  988. REG_OPTION_CREATE_LINK = 2
  989. REG_OPTION_BACKUP_RESTORE = 4
  990. REG_OPTION_OPEN_LINK = 8
  991. REG_LEGAL_OPTION = (
  992. REG_OPTION_RESERVED
  993. | REG_OPTION_NON_VOLATILE
  994. | REG_OPTION_VOLATILE
  995. | REG_OPTION_CREATE_LINK
  996. | REG_OPTION_BACKUP_RESTORE
  997. | REG_OPTION_OPEN_LINK
  998. )
  999. ## dispositions returned from RegCreateKeyEx
  1000. REG_CREATED_NEW_KEY = 1
  1001. REG_OPENED_EXISTING_KEY = 2
  1002. ## flags used with RegSaveKeyEx
  1003. REG_STANDARD_FORMAT = 1
  1004. REG_LATEST_FORMAT = 2
  1005. REG_NO_COMPRESSION = 4
  1006. ## flags used with RegRestoreKey
  1007. REG_WHOLE_HIVE_VOLATILE = 1
  1008. REG_REFRESH_HIVE = 2
  1009. REG_NO_LAZY_FLUSH = 4
  1010. REG_FORCE_RESTORE = 8
  1011. REG_NOTIFY_CHANGE_NAME = 1
  1012. REG_NOTIFY_CHANGE_ATTRIBUTES = 2
  1013. REG_NOTIFY_CHANGE_LAST_SET = 4
  1014. REG_NOTIFY_CHANGE_SECURITY = 8
  1015. REG_LEGAL_CHANGE_FILTER = (
  1016. REG_NOTIFY_CHANGE_NAME
  1017. | REG_NOTIFY_CHANGE_ATTRIBUTES
  1018. | REG_NOTIFY_CHANGE_LAST_SET
  1019. | REG_NOTIFY_CHANGE_SECURITY
  1020. )
  1021. REG_NONE = 0
  1022. REG_SZ = 1
  1023. REG_EXPAND_SZ = 2
  1024. REG_BINARY = 3
  1025. REG_DWORD = 4
  1026. REG_DWORD_LITTLE_ENDIAN = 4
  1027. REG_DWORD_BIG_ENDIAN = 5
  1028. REG_LINK = 6
  1029. REG_MULTI_SZ = 7
  1030. REG_RESOURCE_LIST = 8
  1031. REG_FULL_RESOURCE_DESCRIPTOR = 9
  1032. REG_RESOURCE_REQUIREMENTS_LIST = 10
  1033. SERVICE_KERNEL_DRIVER = 1
  1034. SERVICE_FILE_SYSTEM_DRIVER = 2
  1035. SERVICE_ADAPTER = 4
  1036. SERVICE_RECOGNIZER_DRIVER = 8
  1037. SERVICE_DRIVER = (
  1038. SERVICE_KERNEL_DRIVER | SERVICE_FILE_SYSTEM_DRIVER | SERVICE_RECOGNIZER_DRIVER
  1039. )
  1040. SERVICE_WIN32_OWN_PROCESS = 16
  1041. SERVICE_WIN32_SHARE_PROCESS = 32
  1042. SERVICE_WIN32 = SERVICE_WIN32_OWN_PROCESS | SERVICE_WIN32_SHARE_PROCESS
  1043. SERVICE_INTERACTIVE_PROCESS = 256
  1044. SERVICE_TYPE_ALL = (
  1045. SERVICE_WIN32 | SERVICE_ADAPTER | SERVICE_DRIVER | SERVICE_INTERACTIVE_PROCESS
  1046. )
  1047. SERVICE_BOOT_START = 0
  1048. SERVICE_SYSTEM_START = 1
  1049. SERVICE_AUTO_START = 2
  1050. SERVICE_DEMAND_START = 3
  1051. SERVICE_DISABLED = 4
  1052. SERVICE_ERROR_IGNORE = 0
  1053. SERVICE_ERROR_NORMAL = 1
  1054. SERVICE_ERROR_SEVERE = 2
  1055. SERVICE_ERROR_CRITICAL = 3
  1056. TAPE_ERASE_SHORT = 0
  1057. TAPE_ERASE_LONG = 1
  1058. TAPE_LOAD = 0
  1059. TAPE_UNLOAD = 1
  1060. TAPE_TENSION = 2
  1061. TAPE_LOCK = 3
  1062. TAPE_UNLOCK = 4
  1063. TAPE_FORMAT = 5
  1064. TAPE_SETMARKS = 0
  1065. TAPE_FILEMARKS = 1
  1066. TAPE_SHORT_FILEMARKS = 2
  1067. TAPE_LONG_FILEMARKS = 3
  1068. TAPE_ABSOLUTE_POSITION = 0
  1069. TAPE_LOGICAL_POSITION = 1
  1070. TAPE_PSEUDO_LOGICAL_POSITION = 2
  1071. TAPE_REWIND = 0
  1072. TAPE_ABSOLUTE_BLOCK = 1
  1073. TAPE_LOGICAL_BLOCK = 2
  1074. TAPE_PSEUDO_LOGICAL_BLOCK = 3
  1075. TAPE_SPACE_END_OF_DATA = 4
  1076. TAPE_SPACE_RELATIVE_BLOCKS = 5
  1077. TAPE_SPACE_FILEMARKS = 6
  1078. TAPE_SPACE_SEQUENTIAL_FMKS = 7
  1079. TAPE_SPACE_SETMARKS = 8
  1080. TAPE_SPACE_SEQUENTIAL_SMKS = 9
  1081. TAPE_DRIVE_FIXED = 1
  1082. TAPE_DRIVE_SELECT = 2
  1083. TAPE_DRIVE_INITIATOR = 4
  1084. TAPE_DRIVE_ERASE_SHORT = 16
  1085. TAPE_DRIVE_ERASE_LONG = 32
  1086. TAPE_DRIVE_ERASE_BOP_ONLY = 64
  1087. TAPE_DRIVE_ERASE_IMMEDIATE = 128
  1088. TAPE_DRIVE_TAPE_CAPACITY = 256
  1089. TAPE_DRIVE_TAPE_REMAINING = 512
  1090. TAPE_DRIVE_FIXED_BLOCK = 1024
  1091. TAPE_DRIVE_VARIABLE_BLOCK = 2048
  1092. TAPE_DRIVE_WRITE_PROTECT = 4096
  1093. TAPE_DRIVE_EOT_WZ_SIZE = 8192
  1094. TAPE_DRIVE_ECC = 65536
  1095. TAPE_DRIVE_COMPRESSION = 131072
  1096. TAPE_DRIVE_PADDING = 262144
  1097. TAPE_DRIVE_REPORT_SMKS = 524288
  1098. TAPE_DRIVE_GET_ABSOLUTE_BLK = 1048576
  1099. TAPE_DRIVE_GET_LOGICAL_BLK = 2097152
  1100. TAPE_DRIVE_SET_EOT_WZ_SIZE = 4194304
  1101. TAPE_DRIVE_EJECT_MEDIA = 16777216
  1102. TAPE_DRIVE_RESERVED_BIT = -2147483648
  1103. TAPE_DRIVE_LOAD_UNLOAD = -2147483647
  1104. TAPE_DRIVE_TENSION = -2147483646
  1105. TAPE_DRIVE_LOCK_UNLOCK = -2147483644
  1106. TAPE_DRIVE_REWIND_IMMEDIATE = -2147483640
  1107. TAPE_DRIVE_SET_BLOCK_SIZE = -2147483632
  1108. TAPE_DRIVE_LOAD_UNLD_IMMED = -2147483616
  1109. TAPE_DRIVE_TENSION_IMMED = -2147483584
  1110. TAPE_DRIVE_LOCK_UNLK_IMMED = -2147483520
  1111. TAPE_DRIVE_SET_ECC = -2147483392
  1112. TAPE_DRIVE_SET_COMPRESSION = -2147483136
  1113. TAPE_DRIVE_SET_PADDING = -2147482624
  1114. TAPE_DRIVE_SET_REPORT_SMKS = -2147481600
  1115. TAPE_DRIVE_ABSOLUTE_BLK = -2147479552
  1116. TAPE_DRIVE_ABS_BLK_IMMED = -2147475456
  1117. TAPE_DRIVE_LOGICAL_BLK = -2147467264
  1118. TAPE_DRIVE_LOG_BLK_IMMED = -2147450880
  1119. TAPE_DRIVE_END_OF_DATA = -2147418112
  1120. TAPE_DRIVE_RELATIVE_BLKS = -2147352576
  1121. TAPE_DRIVE_FILEMARKS = -2147221504
  1122. TAPE_DRIVE_SEQUENTIAL_FMKS = -2146959360
  1123. TAPE_DRIVE_SETMARKS = -2146435072
  1124. TAPE_DRIVE_SEQUENTIAL_SMKS = -2145386496
  1125. TAPE_DRIVE_REVERSE_POSITION = -2143289344
  1126. TAPE_DRIVE_SPACE_IMMEDIATE = -2139095040
  1127. TAPE_DRIVE_WRITE_SETMARKS = -2130706432
  1128. TAPE_DRIVE_WRITE_FILEMARKS = -2113929216
  1129. TAPE_DRIVE_WRITE_SHORT_FMKS = -2080374784
  1130. TAPE_DRIVE_WRITE_LONG_FMKS = -2013265920
  1131. TAPE_DRIVE_WRITE_MARK_IMMED = -1879048192
  1132. TAPE_DRIVE_FORMAT = -1610612736
  1133. TAPE_DRIVE_FORMAT_IMMEDIATE = -1073741824
  1134. TAPE_DRIVE_HIGH_FEATURES = -2147483648
  1135. TAPE_FIXED_PARTITIONS = 0
  1136. TAPE_SELECT_PARTITIONS = 1
  1137. TAPE_INITIATOR_PARTITIONS = 2
  1138. TRANSACTIONMANAGER_QUERY_INFORMATION = 0x0001
  1139. TRANSACTIONMANAGER_SET_INFORMATION = 0x0002
  1140. TRANSACTIONMANAGER_RECOVER = 0x0004
  1141. TRANSACTIONMANAGER_RENAME = 0x0008
  1142. TRANSACTIONMANAGER_CREATE_RM = 0x0010
  1143. TRANSACTIONMANAGER_BIND_TRANSACTION = 0x0020
  1144. TRANSACTIONMANAGER_GENERIC_READ = (
  1145. STANDARD_RIGHTS_READ | TRANSACTIONMANAGER_QUERY_INFORMATION
  1146. )
  1147. TRANSACTIONMANAGER_GENERIC_WRITE = (
  1148. STANDARD_RIGHTS_WRITE
  1149. | TRANSACTIONMANAGER_SET_INFORMATION
  1150. | TRANSACTIONMANAGER_RECOVER
  1151. | TRANSACTIONMANAGER_RENAME
  1152. | TRANSACTIONMANAGER_CREATE_RM
  1153. )
  1154. TRANSACTIONMANAGER_GENERIC_EXECUTE = STANDARD_RIGHTS_EXECUTE
  1155. TRANSACTIONMANAGER_ALL_ACCESS = (
  1156. STANDARD_RIGHTS_REQUIRED
  1157. | TRANSACTIONMANAGER_GENERIC_READ
  1158. | TRANSACTIONMANAGER_GENERIC_WRITE
  1159. | TRANSACTIONMANAGER_GENERIC_EXECUTE
  1160. | TRANSACTIONMANAGER_BIND_TRANSACTION
  1161. )
  1162. TRANSACTION_QUERY_INFORMATION = 0x0001
  1163. TRANSACTION_SET_INFORMATION = 0x0002
  1164. TRANSACTION_ENLIST = 0x0004
  1165. TRANSACTION_COMMIT = 0x0008
  1166. TRANSACTION_ROLLBACK = 0x0010
  1167. TRANSACTION_PROPAGATE = 0x0020
  1168. TRANSACTION_SAVEPOINT = 0x0040
  1169. TRANSACTION_MARSHALL = TRANSACTION_QUERY_INFORMATION
  1170. TRANSACTION_GENERIC_READ = (
  1171. STANDARD_RIGHTS_READ | TRANSACTION_QUERY_INFORMATION | SYNCHRONIZE
  1172. )
  1173. TRANSACTION_GENERIC_WRITE = (
  1174. STANDARD_RIGHTS_WRITE
  1175. | TRANSACTION_SET_INFORMATION
  1176. | TRANSACTION_COMMIT
  1177. | TRANSACTION_ENLIST
  1178. | TRANSACTION_ROLLBACK
  1179. | TRANSACTION_PROPAGATE
  1180. | TRANSACTION_SAVEPOINT
  1181. | SYNCHRONIZE
  1182. )
  1183. TRANSACTION_GENERIC_EXECUTE = (
  1184. STANDARD_RIGHTS_EXECUTE | TRANSACTION_COMMIT | TRANSACTION_ROLLBACK | SYNCHRONIZE
  1185. )
  1186. TRANSACTION_ALL_ACCESS = (
  1187. STANDARD_RIGHTS_REQUIRED
  1188. | TRANSACTION_GENERIC_READ
  1189. | TRANSACTION_GENERIC_WRITE
  1190. | TRANSACTION_GENERIC_EXECUTE
  1191. )
  1192. TRANSACTION_RESOURCE_MANAGER_RIGHTS = (
  1193. TRANSACTION_GENERIC_READ
  1194. | STANDARD_RIGHTS_WRITE
  1195. | TRANSACTION_SET_INFORMATION
  1196. | TRANSACTION_ENLIST
  1197. | TRANSACTION_ROLLBACK
  1198. | TRANSACTION_PROPAGATE
  1199. | SYNCHRONIZE
  1200. )
  1201. RESOURCEMANAGER_QUERY_INFORMATION = 0x0001
  1202. RESOURCEMANAGER_SET_INFORMATION = 0x0002
  1203. RESOURCEMANAGER_RECOVER = 0x0004
  1204. RESOURCEMANAGER_ENLIST = 0x0008
  1205. RESOURCEMANAGER_GET_NOTIFICATION = 0x0010
  1206. RESOURCEMANAGER_REGISTER_PROTOCOL = 0x0020
  1207. RESOURCEMANAGER_COMPLETE_PROPAGATION = 0x0040
  1208. RESOURCEMANAGER_GENERIC_READ = (
  1209. STANDARD_RIGHTS_READ | RESOURCEMANAGER_QUERY_INFORMATION | SYNCHRONIZE
  1210. )
  1211. RESOURCEMANAGER_GENERIC_WRITE = (
  1212. STANDARD_RIGHTS_WRITE
  1213. | RESOURCEMANAGER_SET_INFORMATION
  1214. | RESOURCEMANAGER_RECOVER
  1215. | RESOURCEMANAGER_ENLIST
  1216. | RESOURCEMANAGER_GET_NOTIFICATION
  1217. | RESOURCEMANAGER_REGISTER_PROTOCOL
  1218. | RESOURCEMANAGER_COMPLETE_PROPAGATION
  1219. | SYNCHRONIZE
  1220. )
  1221. RESOURCEMANAGER_GENERIC_EXECUTE = (
  1222. STANDARD_RIGHTS_EXECUTE
  1223. | RESOURCEMANAGER_RECOVER
  1224. | RESOURCEMANAGER_ENLIST
  1225. | RESOURCEMANAGER_GET_NOTIFICATION
  1226. | RESOURCEMANAGER_COMPLETE_PROPAGATION
  1227. | SYNCHRONIZE
  1228. )
  1229. RESOURCEMANAGER_ALL_ACCESS = (
  1230. STANDARD_RIGHTS_REQUIRED
  1231. | RESOURCEMANAGER_GENERIC_READ
  1232. | RESOURCEMANAGER_GENERIC_WRITE
  1233. | RESOURCEMANAGER_GENERIC_EXECUTE
  1234. )
  1235. ENLISTMENT_QUERY_INFORMATION = 0x0001
  1236. ENLISTMENT_SET_INFORMATION = 0x0002
  1237. ENLISTMENT_RECOVER = 0x0004
  1238. ENLISTMENT_SUBORDINATE_RIGHTS = 0x0008
  1239. ENLISTMENT_SUPERIOR_RIGHTS = 0x0010
  1240. ENLISTMENT_GENERIC_READ = STANDARD_RIGHTS_READ | ENLISTMENT_QUERY_INFORMATION
  1241. ENLISTMENT_GENERIC_WRITE = (
  1242. STANDARD_RIGHTS_WRITE
  1243. | ENLISTMENT_SET_INFORMATION
  1244. | ENLISTMENT_RECOVER
  1245. | ENLISTMENT_SUBORDINATE_RIGHTS
  1246. | ENLISTMENT_SUPERIOR_RIGHTS
  1247. )
  1248. ENLISTMENT_GENERIC_EXECUTE = (
  1249. STANDARD_RIGHTS_EXECUTE
  1250. | ENLISTMENT_RECOVER
  1251. | ENLISTMENT_SUBORDINATE_RIGHTS
  1252. | ENLISTMENT_SUPERIOR_RIGHTS
  1253. )
  1254. ENLISTMENT_ALL_ACCESS = (
  1255. STANDARD_RIGHTS_REQUIRED
  1256. | ENLISTMENT_GENERIC_READ
  1257. | ENLISTMENT_GENERIC_WRITE
  1258. | ENLISTMENT_GENERIC_EXECUTE
  1259. )
  1260. ## TRANSACTION_OUTCOME enum
  1261. TransactionOutcomeUndetermined = 1
  1262. TransactionOutcomeCommitted = 2
  1263. TransactionOutcomeAborted = 3
  1264. ## TRANSACTION_STATE enum
  1265. TransactionStateNormal = 1
  1266. TransactionStateIndoubt = 2
  1267. TransactionStateCommittedNotify = 3
  1268. ## TRANSACTION_INFORMATION_CLASS enum
  1269. TransactionBasicInformation = 0
  1270. TransactionPropertiesInformation = 1
  1271. TransactionEnlistmentInformation = 2
  1272. TransactionFullInformation = 3
  1273. ## TRANSACTIONMANAGER_INFORMATION_CLASS enum
  1274. TransactionManagerBasicInformation = 0
  1275. TransactionManagerLogInformation = 1
  1276. TransactionManagerLogPathInformation = 2
  1277. TransactionManagerOnlineProbeInformation = 3
  1278. ## RESOURCEMANAGER_INFORMATION_CLASS ENUM
  1279. ResourceManagerBasicInformation = 0
  1280. ResourceManagerCompletionInformation = 1
  1281. ResourceManagerFullInformation = 2
  1282. ResourceManagerNameInformation = 3
  1283. ## ENLISTMENT_INFORMATION_CLASS enum
  1284. EnlistmentBasicInformation = 0
  1285. EnlistmentRecoveryInformation = 1
  1286. EnlistmentFullInformation = 2
  1287. EnlistmentNameInformation = 3
  1288. ## KTMOBJECT_TYPE enum
  1289. KTMOBJECT_TRANSACTION = 0
  1290. KTMOBJECT_TRANSACTION_MANAGER = 1
  1291. KTMOBJECT_RESOURCE_MANAGER = 2
  1292. KTMOBJECT_ENLISTMENT = 3
  1293. KTMOBJECT_INVALID = 4