2 * PROJECT: ReactOS Native Headers
3 * FILE: include/ndk/rtlfuncs.h
4 * PURPOSE: Prototypes for Runtime Library Functions not defined in DDK/IFS
5 * PROGRAMMER: Alex Ionescu (alex@relsoft.net)
12 /* DEPENDENCIES **************************************************************/
15 /* PROTOTYPES ****************************************************************/
18 * Error and Exception Functions
23 RtlAddVectoredExceptionHandler(
24 IN ULONG FirstHandler
,
25 IN PVECTORED_EXCEPTION_HANDLER VectoredHandler
32 PVOID FailedAssertion
,
41 RtlEncodePointer(IN PVOID Pointer
);
46 RtlDecodePointer(IN PVOID Pointer
);
51 RtlNtStatusToDosError(IN NTSTATUS Status
);
56 RtlRaiseException(IN PEXCEPTION_RECORD ExceptionRecord
);
61 RtlRaiseStatus(NTSTATUS Status
);
66 RtlUnhandledExceptionFilter(struct _EXCEPTION_POINTERS
* ExceptionInfo
);
72 PEXCEPTION_REGISTRATION RegistrationFrame
,
74 PEXCEPTION_RECORD ExceptionRecord
,
96 IN PVOID BaseAddress OPTIONAL
,
97 IN SIZE_T SizeToReserve OPTIONAL
,
98 IN SIZE_T SizeToCommit OPTIONAL
,
99 IN PVOID Lock OPTIONAL
,
100 IN PRTL_HEAP_PARAMETERS Parameters OPTIONAL
113 RtlDestroyHeap(HANDLE hheap
);
119 IN HANDLE HeapHandle
,
142 RtlLockHeap(IN HANDLE Heap
);
146 RtlUnlockHeap(IN HANDLE Heap
);
153 IN PVOID MemoryPointer
164 #define RtlGetProcessHeap() (NtCurrentPeb()->ProcessHeap)
173 RtlAbsoluteToSelfRelativeSD(
174 IN PSECURITY_DESCRIPTOR AbsoluteSecurityDescriptor
,
175 IN OUT PSECURITY_DESCRIPTOR SelfRelativeSecurityDescriptor
,
176 IN PULONG BufferLength
182 RtlAddAccessAllowedAce(
185 ACCESS_MASK AccessMask
,
191 RtlAddAccessAllowedAceEx(
193 IN ULONG dwAceRevision
,
201 RtlAddAccessDeniedAce(
204 ACCESS_MASK AccessMask
,
210 RtlAddAccessDeniedAceEx(
214 IN ACCESS_MASK AccessMask
,
220 RtlAddAuditAccessAceEx(
224 IN ACCESS_MASK AccessMask
,
236 ULONG StartingAceIndex
,
243 RtlAddAuditAccessAce(
246 ACCESS_MASK AccessMask
,
257 IN BOOLEAN ForThread
,
258 OUT PBOOLEAN OldValue
264 RtlAllocateAndInitializeSid(
265 IN PSID_IDENTIFIER_AUTHORITY IdentifierAuthority
,
266 IN UCHAR SubAuthorityCount
,
267 IN ULONG SubAuthority0
,
268 IN ULONG SubAuthority1
,
269 IN ULONG SubAuthority2
,
270 IN ULONG SubAuthority3
,
271 IN ULONG SubAuthority4
,
272 IN ULONG SubAuthority5
,
273 IN ULONG SubAuthority6
,
274 IN ULONG SubAuthority7
,
280 RtlAreAllAccessesGranted(
281 ACCESS_MASK GrantedAccess
,
282 ACCESS_MASK DesiredAccess
287 RtlAreAnyAccessesGranted(
288 ACCESS_MASK GrantedAccess
,
289 ACCESS_MASK DesiredAccess
302 RtlCopyLuidAndAttributesArray(
304 PLUID_AND_ATTRIBUTES Src
,
305 PLUID_AND_ATTRIBUTES Dest
310 RtlCopySidAndAttributesArray(
312 PSID_AND_ATTRIBUTES Src
,
314 PSID_AND_ATTRIBUTES Dest
,
316 PVOID
* RemainingSidArea
,
317 PULONG RemainingSidAreaSize
322 RtlConvertSidToUnicodeString(
323 OUT PUNICODE_STRING DestinationString
,
325 IN BOOLEAN AllocateDestinationString
349 RtlCreateSecurityDescriptor(
350 PSECURITY_DESCRIPTOR SecurityDescriptor
,
357 RtlCreateSecurityDescriptorRelative(
358 PISECURITY_DESCRIPTOR_RELATIVE SecurityDescriptor
,
411 RtlGetControlSecurityDescriptor(
412 PSECURITY_DESCRIPTOR SecurityDescriptor
,
413 PSECURITY_DESCRIPTOR_CONTROL Control
,
420 RtlGetDaclSecurityDescriptor(
421 IN PSECURITY_DESCRIPTOR SecurityDescriptor
,
422 OUT PBOOLEAN DaclPresent
,
424 OUT PBOOLEAN DaclDefaulted
430 RtlGetSaclSecurityDescriptor(
431 PSECURITY_DESCRIPTOR SecurityDescriptor
,
432 PBOOLEAN SaclPresent
,
434 PBOOLEAN SaclDefaulted
440 RtlGetGroupSecurityDescriptor(
441 IN PSECURITY_DESCRIPTOR SecurityDescriptor
,
443 OUT PBOOLEAN GroupDefaulted
449 RtlGetOwnerSecurityDescriptor(
450 IN PSECURITY_DESCRIPTOR SecurityDescriptor
,
452 OUT PBOOLEAN OwnerDefaulted
458 RtlGetSecurityDescriptorRMControl(
459 PSECURITY_DESCRIPTOR SecurityDescriptor
,
464 PSID_IDENTIFIER_AUTHORITY
466 RtlIdentifierAuthoritySid(PSID Sid
);
471 RtlImpersonateSelf(IN SECURITY_IMPERSONATION_LEVEL ImpersonationLevel
);
478 IN PSID_IDENTIFIER_AUTHORITY IdentifierAuthority
,
479 IN UCHAR SubAuthorityCount
485 RtlLengthRequiredSid(IN ULONG SubAuthorityCount
);
490 RtlLengthSid(IN PSID Sid
);
496 PACCESS_MASK AccessMask
,
497 PGENERIC_MAPPING GenericMapping
503 RtlQueryInformationAcl(
506 ULONG InformationLength
,
507 ACL_INFORMATION_CLASS InformationClass
513 RtlSelfRelativeToAbsoluteSD(
514 IN PSECURITY_DESCRIPTOR SelfRelativeSD
,
515 OUT PSECURITY_DESCRIPTOR AbsoluteSD
,
516 IN PULONG AbsoluteSDSize
,
523 IN PSID PrimaryGroup
,
524 IN PULONG PrimaryGroupSize
530 RtlSetControlSecurityDescriptor(
531 IN PSECURITY_DESCRIPTOR SecurityDescriptor
,
532 IN SECURITY_DESCRIPTOR_CONTROL ControlBitsOfInterest
,
533 IN SECURITY_DESCRIPTOR_CONTROL ControlBitsToSet
539 RtlSetDaclSecurityDescriptor (
540 PSECURITY_DESCRIPTOR SecurityDescriptor
,
543 BOOLEAN DaclDefaulted
549 RtlSetGroupSecurityDescriptor(
550 IN OUT PSECURITY_DESCRIPTOR SecurityDescriptor
,
552 IN BOOLEAN GroupDefaulted
558 RtlSetInformationAcl(
561 ULONG InformationLength
,
562 ACL_INFORMATION_CLASS InformationClass
568 RtlSetOwnerSecurityDescriptor(
569 IN OUT PSECURITY_DESCRIPTOR SecurityDescriptor
,
571 IN BOOLEAN OwnerDefaulted
577 RtlSetSaclSecurityDescriptor(
578 IN OUT PSECURITY_DESCRIPTOR SecurityDescriptor
,
579 IN BOOLEAN SaclPresent
,
581 IN BOOLEAN SaclDefaulted
587 RtlSetSecurityDescriptorRMControl(
588 PSECURITY_DESCRIPTOR SecurityDescriptor
,
595 RtlSubAuthorityCountSid(
604 IN ULONG SubAuthority
610 RtlValidRelativeSecurityDescriptor(
611 IN PSECURITY_DESCRIPTOR SecurityDescriptorInput
,
612 IN ULONG SecurityDescriptorLength
,
613 IN SECURITY_INFORMATION RequiredInformation
619 RtlValidSecurityDescriptor(IN PSECURITY_DESCRIPTOR SecurityDescriptor
);
624 RtlValidSid(IN PSID Sid
);
629 RtlValidAcl(PACL Acl
);
634 RtlDeleteSecurityObject(
635 IN PSECURITY_DESCRIPTOR
*ObjectDescriptor
641 RtlNewSecurityObject(
642 IN PSECURITY_DESCRIPTOR ParentDescriptor
,
643 IN PSECURITY_DESCRIPTOR CreatorDescriptor
,
644 OUT PSECURITY_DESCRIPTOR
*NewDescriptor
,
645 IN BOOLEAN IsDirectoryObject
,
647 IN PGENERIC_MAPPING GenericMapping
653 RtlQuerySecurityObject(
654 IN PSECURITY_DESCRIPTOR ObjectDescriptor
,
655 IN SECURITY_INFORMATION SecurityInformation
,
656 OUT PSECURITY_DESCRIPTOR ResultantDescriptor
,
657 IN ULONG DescriptorLength
,
658 OUT PULONG ReturnLength
664 RtlSetSecurityObject(
665 IN SECURITY_INFORMATION SecurityInformation
,
666 IN PSECURITY_DESCRIPTOR ModificationDescriptor
,
667 OUT PSECURITY_DESCRIPTOR
*ObjectsSecurityDescriptor
,
668 IN PGENERIC_MAPPING GenericMapping
,
673 * Single-Character Functions
678 RtlLargeIntegerToChar(
679 IN PLARGE_INTEGER Value
,
688 RtlUpperChar(CHAR Source
);
693 RtlUpcaseUnicodeChar(WCHAR Source
);
698 RtlDowncaseUnicodeChar(IN WCHAR Source
);
715 IN ULONG Base OPTIONAL
,
716 IN ULONG Length OPTIONAL
,
723 RtlIntegerToUnicodeString(
726 IN OUT PUNICODE_STRING String
738 #if (defined(_M_IX86) && (_MSC_FULL_VER > 13009037)) || ((defined(_M_AMD64) || defined(_M_IA64)) && (_MSC_FULL_VER > 13009175))
739 unsigned short __cdecl
_byteswap_ushort(unsigned short);
740 unsigned long __cdecl
_byteswap_ulong (unsigned long);
741 unsigned __int64 __cdecl
_byteswap_uint64(unsigned __int64
);
742 #pragma intrinsic(_byteswap_ushort)
743 #pragma intrinsic(_byteswap_ulong)
744 #pragma intrinsic(_byteswap_uint64)
745 #define RtlUshortByteSwap(_x) _byteswap_ushort((USHORT)(_x))
746 #define RtlUlongByteSwap(_x) _byteswap_ulong((_x))
747 #define RtlUlonglongByteSwap(_x) _byteswap_uint64((_x))
752 RtlUshortByteSwap(IN USHORT Source
);
756 RtlUlongByteSwap(IN ULONG Source
);
760 RtlUlonglongByteSwap(IN ULONGLONG Source
);
765 * Unicode->Ansi String Functions
767 /* FIXME: Use macro */
768 #undef RtlUnicodeStringToAnsiSize
772 RtlUnicodeStringToAnsiSize(IN PUNICODE_STRING UnicodeString
);
777 RtlUnicodeStringToAnsiString(
778 PANSI_STRING DestinationString
,
779 PCUNICODE_STRING SourceString
,
780 BOOLEAN AllocateDestinationString
784 * Unicode->OEM String Functions
789 RtlUpcaseUnicodeStringToOemString(
790 POEM_STRING DestinationString
,
791 PCUNICODE_STRING SourceString
,
792 BOOLEAN AllocateDestinationString
798 RtlUpcaseUnicodeStringToCountedOemString(
799 IN OUT POEM_STRING DestinationString
,
800 IN PCUNICODE_STRING SourceString
,
801 IN BOOLEAN AllocateDestinationString
807 RtlUnicodeStringToOemString(
808 POEM_STRING DestinationString
,
809 PCUNICODE_STRING SourceString
,
810 BOOLEAN AllocateDestinationString
816 RtlUpcaseUnicodeToOemN(
820 PWCHAR UnicodeString
,
824 /* FIXME: Use macro */
825 #undef RtlUnicodeStringToOemSize
829 RtlUnicodeStringToOemSize(IN PUNICODE_STRING UnicodeString
);
838 PWCHAR UnicodeString
,
843 * Unicode->MultiByte String Functions
848 RtlUnicodeToMultiByteN(
852 PWCHAR UnicodeString
,
859 RtlUpcaseUnicodeToMultiByteN(
863 PWCHAR UnicodeString
,
870 RtlUnicodeToMultiByteSize(
872 PWCHAR UnicodeString
,
877 * OEM to Unicode Functions
879 /* FIXME: Use macro */
880 #undef RtlOemStringToUnicodeSize
884 RtlOemStringToUnicodeSize(POEM_STRING AnsiString
);
889 RtlOemStringToUnicodeString(
890 PUNICODE_STRING DestinationString
,
891 PCOEM_STRING SourceString
,
892 BOOLEAN AllocateDestinationString
900 ULONG MaxBytesInUnicodeString
,
901 PULONG BytesInUnicodeString
,
903 ULONG BytesInOemString
907 * Ansi->Unicode String Functions
911 RtlAnsiStringToUnicodeString(
912 PUNICODE_STRING DestinationString
,
913 PCANSI_STRING SourceString
,
914 BOOLEAN AllocateDestinationString
917 /* FIXME: Use macro */
918 #undef RtlAnsiStringToUnicodeSize
922 RtlAnsiStringToUnicodeSize(
923 PANSI_STRING AnsiString
929 RtlCreateUnicodeStringFromAsciiz(
930 OUT PUNICODE_STRING Destination
,
935 * Unicode String Functions
940 RtlAppendUnicodeToString(
941 PUNICODE_STRING Destination
,
948 RtlAppendUnicodeStringToString(
949 PUNICODE_STRING Destination
,
950 PCUNICODE_STRING Source
956 RtlCompareUnicodeString(
957 PCUNICODE_STRING String1
,
958 PCUNICODE_STRING String2
,
959 BOOLEAN CaseInsensitive
965 RtlCopyUnicodeString(
966 PUNICODE_STRING DestinationString
,
967 PCUNICODE_STRING SourceString
973 RtlCreateUnicodeString(
974 PUNICODE_STRING DestinationString
,
981 RtlDowncaseUnicodeString(
982 IN OUT PUNICODE_STRING UniDest
,
983 IN PCUNICODE_STRING UniSource
,
984 IN BOOLEAN AllocateDestinationString
990 RtlDuplicateUnicodeString(
992 IN PCUNICODE_STRING SourceString
,
993 OUT PUNICODE_STRING DestinationString
999 RtlEqualUnicodeString(
1000 PCUNICODE_STRING String1
,
1001 PCUNICODE_STRING String2
,
1002 BOOLEAN CaseInsensitive
1008 RtlFreeUnicodeString(IN PUNICODE_STRING UnicodeString
);
1013 RtlHashUnicodeString(
1014 IN CONST UNICODE_STRING
*String
,
1015 IN BOOLEAN CaseInSensitive
,
1016 IN ULONG HashAlgorithm
,
1017 OUT PULONG HashValue
1023 RtlInitUnicodeString(
1024 IN OUT PUNICODE_STRING DestinationString
,
1025 IN PCWSTR SourceString
);
1039 RtlPrefixUnicodeString(
1040 PCUNICODE_STRING String1
,
1041 PCUNICODE_STRING String2
,
1042 BOOLEAN CaseInsensitive
1048 RtlUpcaseUnicodeString(
1049 PUNICODE_STRING DestinationString
,
1050 PCUNICODE_STRING SourceString
,
1051 BOOLEAN AllocateDestinationString
1057 RtlUnicodeStringToInteger(
1058 PCUNICODE_STRING String
,
1064 * Ansi String Functions
1069 RtlFreeAnsiString(IN PANSI_STRING AnsiString
);
1075 PANSI_STRING DestinationString
,
1080 * OEM String Functions
1085 RtlFreeOemString(IN POEM_STRING OemString
);
1088 * MultiByte->Unicode String Functions
1093 RtlMultiByteToUnicodeN(
1094 PWCHAR UnicodeString
,
1104 RtlMultiByteToUnicodeSize(
1116 RtlAddAtomToAtomTable(
1117 IN PRTL_ATOM_TABLE AtomTable
,
1127 IN OUT PRTL_ATOM_TABLE
*AtomTable
1133 RtlDeleteAtomFromAtomTable(
1134 IN PRTL_ATOM_TABLE AtomTable
,
1141 RtlDestroyAtomTable(IN PRTL_ATOM_TABLE AtomTable
);
1146 RtlQueryAtomInAtomTable(
1147 IN PRTL_ATOM_TABLE AtomTable
,
1149 IN OUT PULONG RefCount OPTIONAL
,
1150 IN OUT PULONG PinCount OPTIONAL
,
1151 IN OUT PWSTR AtomName OPTIONAL
,
1152 IN OUT PULONG NameLength OPTIONAL
1158 RtlLookupAtomInAtomTable(
1159 IN PRTL_ATOM_TABLE AtomTable
,
1171 IN PVOID Destination
,
1177 * Process Management Functions
1182 RtlAcquirePebLock(VOID
);
1187 RtlCreateProcessParameters (
1188 OUT PRTL_USER_PROCESS_PARAMETERS
*ProcessParameters
,
1189 IN PUNICODE_STRING ImagePathName OPTIONAL
,
1190 IN PUNICODE_STRING DllPath OPTIONAL
,
1191 IN PUNICODE_STRING CurrentDirectory OPTIONAL
,
1192 IN PUNICODE_STRING CommandLine OPTIONAL
,
1193 IN PWSTR Environment OPTIONAL
,
1194 IN PUNICODE_STRING WindowTitle OPTIONAL
,
1195 IN PUNICODE_STRING DesktopInfo OPTIONAL
,
1196 IN PUNICODE_STRING ShellInfo OPTIONAL
,
1197 IN PUNICODE_STRING RuntimeInfo OPTIONAL
1203 RtlCreateUserProcess(
1204 IN PUNICODE_STRING ImageFileName
,
1205 IN ULONG Attributes
,
1206 IN PRTL_USER_PROCESS_PARAMETERS ProcessParameters
,
1207 IN PSECURITY_DESCRIPTOR ProcessSecutityDescriptor OPTIONAL
,
1208 IN PSECURITY_DESCRIPTOR ThreadSecurityDescriptor OPTIONAL
,
1209 IN HANDLE ParentProcess OPTIONAL
,
1210 IN BOOLEAN CurrentDirectory
,
1211 IN HANDLE DebugPort OPTIONAL
,
1212 IN HANDLE ExceptionPort OPTIONAL
,
1213 OUT PRTL_USER_PROCESS_INFORMATION ProcessInfo
1219 RtlCreateUserThread(
1220 IN HANDLE ProcessHandle
,
1221 IN PSECURITY_DESCRIPTOR SecurityDescriptor
,
1222 IN BOOLEAN CreateSuspended
,
1223 IN LONG StackZeroBits
,
1224 IN ULONG StackReserve
,
1225 IN ULONG StackCommit
,
1226 IN PTHREAD_START_ROUTINE StartAddress
,
1228 IN OUT PHANDLE ThreadHandle
,
1229 IN OUT PCLIENT_ID ClientId
1233 PRTL_USER_PROCESS_PARAMETERS
1235 RtlDeNormalizeProcessParams(IN PRTL_USER_PROCESS_PARAMETERS ProcessParameters
);
1240 RtlDestroyProcessParameters(IN PRTL_USER_PROCESS_PARAMETERS ProcessParameters
);
1245 RtlExitUserThread(NTSTATUS Status
);
1250 RtlInitializeContext(
1251 IN HANDLE ProcessHandle
,
1252 OUT PCONTEXT ThreadContext
,
1253 IN PVOID ThreadStartParam OPTIONAL
,
1254 IN PTHREAD_START_ROUTINE ThreadStartAddress
,
1255 IN PINITIAL_TEB InitialTeb
1259 PRTL_USER_PROCESS_PARAMETERS
1261 RtlNormalizeProcessParams(IN PRTL_USER_PROCESS_PARAMETERS ProcessParameters
);
1266 RtlReleasePebLock(VOID
);
1269 * Environment/Path Functions
1274 RtlCreateEnvironment(
1282 RtlDestroyEnvironment(PWSTR Environment
);
1287 RtlDoesFileExists_U(PWSTR FileName
);
1292 RtlDetermineDosPathNameType_U(PCWSTR Path
);
1309 RtlDosPathNameToNtPathName_U(
1311 PUNICODE_STRING NtName
,
1313 PCURDIR CurrentDirectory
1319 RtlExpandEnvironmentStrings_U(
1321 PUNICODE_STRING Source
,
1322 PUNICODE_STRING Destination
,
1329 RtlGetCurrentDirectory_U(
1330 ULONG MaximumLength
,
1337 RtlGetFullPathName_U(
1338 const WCHAR
*dosname
,
1347 RtlIsNameLegalDOS8Dot3(
1348 IN PUNICODE_STRING UnicodeName
,
1349 IN PANSI_STRING AnsiName
,
1356 RtlQueryEnvironmentVariable_U(
1358 PUNICODE_STRING Name
,
1359 PUNICODE_STRING Value
1365 RtlSetCurrentDirectory_U(PUNICODE_STRING name
);
1370 RtlSetEnvironmentVariable(
1372 PUNICODE_STRING Name
,
1373 PUNICODE_STRING Value
1377 * Critical Section/Resource Functions
1382 RtlDeleteCriticalSection (
1383 IN PRTL_CRITICAL_SECTION CriticalSection
1389 RtlEnterCriticalSection(
1390 IN PRTL_CRITICAL_SECTION CriticalSection
1396 RtlInitializeCriticalSection(
1397 IN PRTL_CRITICAL_SECTION CriticalSection
1403 RtlInitializeCriticalSectionAndSpinCount(
1404 IN PRTL_CRITICAL_SECTION CriticalSection
,
1411 RtlLeaveCriticalSection(
1412 IN PRTL_CRITICAL_SECTION CriticalSection
1418 RtlpUnWaitCriticalSection(
1419 IN PRTL_CRITICAL_SECTION CriticalSection
1425 RtlpWaitForCriticalSection(
1426 IN PRTL_CRITICAL_SECTION CriticalSection
1432 RtlAcquireResourceExclusive(
1433 IN PRTL_RESOURCE Resource
,
1440 RtlAcquireResourceShared(
1441 IN PRTL_RESOURCE Resource
,
1448 RtlConvertExclusiveToShared(
1449 IN PRTL_RESOURCE Resource
1455 RtlConvertSharedToExclusive(
1456 IN PRTL_RESOURCE Resource
1463 IN PRTL_RESOURCE Resource
1470 IN PRTL_RESOURCE Resource
1476 RtlInitializeResource(
1477 IN PRTL_RESOURCE Resource
1484 IN PRTL_RESOURCE Resource
1488 * Compression Functions
1494 IN USHORT CompressionFormatAndEngine
,
1495 IN PUCHAR UncompressedBuffer
,
1496 IN ULONG UncompressedBufferSize
,
1497 OUT PUCHAR CompressedBuffer
,
1498 IN ULONG CompressedBufferSize
,
1499 IN ULONG UncompressedChunkSize
,
1500 OUT PULONG FinalCompressedSize
,
1507 RtlDecompressBuffer(
1508 IN USHORT CompressionFormat
,
1509 OUT PUCHAR UncompressedBuffer
,
1510 IN ULONG UncompressedBufferSize
,
1511 IN PUCHAR CompressedBuffer
,
1512 IN ULONG CompressedBufferSize
,
1513 OUT PULONG FinalUncompressedSize
1519 RtlGetCompressionWorkSpaceSize(
1520 IN USHORT CompressionFormatAndEngine
,
1521 OUT PULONG CompressBufferWorkSpaceSize
,
1522 OUT PULONG CompressFragmentWorkSpaceSize
1526 * Debug Info Functions
1531 RtlCreateQueryDebugBuffer(
1533 IN BOOLEAN EventPair
1539 RtlDestroyQueryDebugBuffer(IN PDEBUG_BUFFER DebugBuffer
);
1544 RtlQueryProcessDebugInformation(
1546 IN ULONG DebugInfoClassMask
,
1547 IN OUT PDEBUG_BUFFER DebugBuffer
1557 IN PRTL_BITMAP BitMapHeader
,
1558 IN ULONG StartingIndex
,
1566 IN PRTL_BITMAP BitMapHeader
,
1567 IN ULONG StartingIndex
,
1575 IN PRTL_BITMAP BitMapHeader
,
1576 IN ULONG StartingIndex
,
1577 IN ULONG NumberToClear
1584 IN PRTL_BITMAP BitMapHeader
,
1585 IN ULONG NumberToFind
,
1592 RtlFindClearBitsAndSet(
1593 IN PRTL_BITMAP BitMapHeader
,
1594 IN ULONG NumberToFind
,
1601 RtlInitializeBitMap(
1602 IN PRTL_BITMAP BitMapHeader
,
1603 IN PULONG BitMapBuffer
,
1604 IN ULONG SizeOfBitMap
1611 IN PRTL_BITMAP BitMapHeader
,
1612 IN ULONG StartingIndex
,
1613 IN ULONG NumberToSet
1625 WAITORTIMERCALLBACKFUNC Callback
,
1635 RtlCreateTimerQueue(PHANDLE TimerQueue
);
1643 HANDLE CompletionEvent
1659 RtlDeleteTimerQueueEx(
1661 HANDLE CompletionEvent
1667 RtlDeleteTimerQueue(HANDLE TimerQueue
);
1681 DbgBreakPoint(VOID
);
1684 * Handle Table Functions
1687 PRTL_HANDLE_TABLE_ENTRY
1690 IN PRTL_HANDLE_TABLE HandleTable
,
1697 RtlDestroyHandleTable(IN PRTL_HANDLE_TABLE HandleTable
);
1703 IN PRTL_HANDLE_TABLE HandleTable
,
1704 IN PRTL_HANDLE_TABLE_ENTRY Handle
1710 RtlInitializeHandleTable(
1712 IN ULONG HandleSize
,
1713 IN PRTL_HANDLE_TABLE HandleTable
1720 IN PRTL_HANDLE_TABLE HandleTable
,
1721 IN PRTL_HANDLE_TABLE_ENTRY Handle
1727 RtlIsValidIndexHandle(
1728 IN PRTL_HANDLE_TABLE HandleTable
,
1730 OUT PRTL_HANDLE_TABLE_ENTRY
*Handle
1740 IN PVOID BaseAddress
,
1744 OUT PRTL_MESSAGE_RESOURCE_ENTRY
*MessageResourceEntry
1750 RtlGetNtGlobalFlags(VOID
);
1755 RtlImageDirectoryEntryToData(
1766 PIMAGE_NT_HEADERS NtHeader
,
1769 PIMAGE_SECTION_HEADER
*SectionHeader
1775 RtlImageNtHeader(IN PVOID BaseAddress
);
1778 PIMAGE_SECTION_HEADER
1780 RtlImageRvaToSection(
1781 PIMAGE_NT_HEADERS NtHeader
,
1787 * Registry Functions
1792 RtlCheckRegistryKey(
1800 RtlFormatCurrentUserKeyPath(IN OUT PUNICODE_STRING KeyPath
);
1806 OUT HANDLE KeyHandle
,
1807 IN ACCESS_MASK DesiredAccess
,
1808 IN POBJECT_ATTRIBUTES ObjectAttributes
,
1816 IN ACCESS_MASK DesiredAccess
,
1817 OUT PHANDLE KeyHandle
1823 RtlQueryRegistryValues(
1824 IN ULONG RelativeTo
,
1826 IN PRTL_QUERY_REGISTRY_TABLE QueryTable
,
1828 IN PVOID Environment
1834 RtlWriteRegistryValue(
1850 IN PUSHORT AnsiTableBase
,
1851 IN PUSHORT OemTableBase
,
1852 IN PUSHORT CaseTableBase
,
1853 OUT PNLSTABLEINFO NlsTable
1859 RtlInitCodePageTable(
1860 IN PUSHORT TableBase
,
1861 OUT PCPTABLEINFO CodePageTable
1867 RtlResetRtlTranslations(IN PNLSTABLEINFO NlsTable
);
1870 * Misc conversion functions
1872 /* FIXME: Use inline */
1876 RtlConvertLongToLargeInteger(IN LONG SignedInteger
);
1878 /* FIXME: Use inline */
1882 RtlEnlargedIntegerMultiply(
1887 /* FIXME: Use inline */
1891 RtlEnlargedUnsignedDivide(
1892 ULARGE_INTEGER Dividend
,
1897 /* FIXME: Use inline */
1901 RtlEnlargedUnsignedMultiply(
1909 RtlUniform(PULONG Seed
);
1917 RtlQueryTimeZoneInformation(LPTIME_ZONE_INFORMATION TimeZoneInformation
);
1922 RtlSecondsSince1970ToTime(
1923 IN ULONG SecondsSince1970
,
1924 OUT PLARGE_INTEGER Time
1930 RtlSetTimeZoneInformation(LPTIME_ZONE_INFORMATION TimeZoneInformation
);
1935 RtlTimeFieldsToTime(
1936 PTIME_FIELDS TimeFields
,
1943 RtlTimeToTimeFields(
1944 PLARGE_INTEGER Time
,
1945 PTIME_FIELDS TimeFields
1954 RtlVerifyVersionInfo(
1955 IN PRTL_OSVERSIONINFOEXW VersionInfo
,
1957 IN ULONGLONG ConditionMask
1963 RtlGetVersion(IN OUT PRTL_OSVERSIONINFOW lpVersionInformation
);