8 typedef struct _CONTROLLER_OBJECT
12 PVOID ControllerExtension
;
13 KDEVICE_QUEUE DeviceWaitQueue
;
16 } CONTROLLER_OBJECT
, *PCONTROLLER_OBJECT
;
18 typedef struct _STRING
25 typedef struct _ANSI_STRING
28 * Length in bytes of the string stored in buffer
33 * Maximum length of the string
41 } ANSI_STRING
, *PANSI_STRING
;
43 typedef struct _TIME_FIELDS
53 } TIME_FIELDS
, *PTIME_FIELDS
;
56 * PURPOSE: Flags for RtlQueryRegistryValues
60 RTL_QUERY_REGISTRY_SUBKEY
,
61 RTL_QUERY_REGISTRY_TOPKEY
,
62 RTL_QUERY_REGISTRY_REQUIRED
,
63 RTL_QUERY_REGISTRY_NOVALUE
,
64 RTL_QUERY_REGISTRY_NOEXPAND
,
65 RTL_QUERY_REGISTRY_DIRECT
,
66 RTL_QUERY_REGISTRY_DELETE
,
69 typedef NTSTATUS (*PRTL_QUERY_REGISTRY_ROUTINE
)(PWSTR ValueName
,
76 typedef struct _RTL_QUERY_REGISTRY_TABLE
78 PRTL_QUERY_REGISTRY_ROUTINE QueryRoutine
;
85 } RTL_QUERY_REGISTRY_TABLE
, *PRTL_QUERY_REGISTRY_TABLE
;
88 * PURPOSE: Used with RtlCheckRegistryKey, RtlCreateRegistryKey,
89 * RtlDeleteRegistryKey
93 RTL_REGISTRY_ABSOLUTE
,
94 RTL_REGISTRY_SERVICES
,
96 RTL_REGISTRY_WINDOWS_NT
,
97 RTL_REGISTRY_DEVICEMAP
,
99 RTL_REGISTRY_OPTIONAL
,
104 * FUNCTION: Sets up a parameter of type OBJECT_ATTRIBUTES for a
105 * subsequent call to ZwCreateXXX or ZwOpenXXX
107 * InitializedAttributes (OUT) = Caller supplied storage for the
109 * ObjectName = Full path name for object
110 * Attributes = Attributes for the object
111 * RootDirectory = Where the object should be placed or NULL
112 * SecurityDescriptor = Ignored
115 InitializeObjectAttributes (
116 POBJECT_ATTRIBUTES InitializedAttributes
,
117 PUNICODE_STRING ObjectName
,
119 HANDLE RootDirectory
,
120 PSECURITY_DESCRIPTOR SecurityDescriptor
130 PLIST_ENTRY ListHead
,
136 PLIST_ENTRY ListHead
,
147 PSINGLE_LIST_ENTRY ListHead
152 PSINGLE_LIST_ENTRY ListHead
,
153 PSINGLE_LIST_ENTRY Entry
172 RtlAnsiStringToUnicodeSize (
173 PANSI_STRING AnsiString
177 RtlAnsiStringToUnicodeString (
178 PUNICODE_STRING DestinationString
,
179 PANSI_STRING SourceString
,
180 BOOLEAN AllocateDestinationString
184 RtlAppendUnicodeStringToString (
185 PUNICODE_STRING Destination
,
186 PUNICODE_STRING Source
190 RtlAppendUnicodeToString (
191 PUNICODE_STRING Destination
,
204 RtlCheckRegistryKey (
220 BOOLEAN CaseInsensitive
224 RtlCompareUnicodeString (
225 PUNICODE_STRING String1
,
226 PUNICODE_STRING String2
,
227 BOOLEAN BaseInsensitive
231 RtlConvertLongToLargeInteger (
236 RtlConvertUlongToLargeInteger (
237 ULONG UnsignedInteger
256 PSTRING DestinationString
,
261 RtlCopyUnicodeString (
262 PUNICODE_STRING DestinationString
,
263 PUNICODE_STRING SourceString
268 RtlCreateRegistryKey (
274 RtlCreateSecurityDescriptor (
275 PSECURITY_DESCRIPTOR SecurityDescriptor
,
281 RtlDeleteRegistryValue (
288 RtlEnlargedIntegerMultiply (
294 RtlEnlargedUnsignedDivide (
295 ULARGE_INTEGER Dividend
,
301 RtlEnlargedUnsignedMultiply (
310 BOOLEAN CaseInSensitive
314 RtlEqualUnicodeString (
315 PUNICODE_STRING String1
,
316 PUNICODE_STRING String2
,
317 BOOLEAN CaseInSensitive
321 RtlExtendedIntegerMultiply (
322 LARGE_INTEGER Multiplicand
,
327 RtlExtendedLargeIntegerDivide (
328 LARGE_INTEGER Dividend
,
334 RtlExtendedMagicDivide (
335 LARGE_INTEGER Dividend
,
336 LARGE_INTEGER MagicDivisor
,
349 PANSI_STRING AnsiString
353 RtlFreeUnicodeString (
354 PUNICODE_STRING UnicodeString
359 PANSI_STRING DestinationString
,
365 PSTRING DestinationString
,
370 RtlInitUnicodeString (
371 PUNICODE_STRING DestinationString
,
376 RtlIntegerToUnicodeString (
379 PUNICODE_STRING String
384 LARGE_INTEGER Addend1
,
385 LARGE_INTEGER Addend2
390 PLARGE_INTEGER Result
,
391 LARGE_INTEGER Source
,
395 /* MISSING FUNCTIONS GO HERE */
398 RtlConvertLongToLargeInteger (
403 RtlConvertUlongToLargeInteger (
404 ULONG UnsignedInteger
408 RtlEnlargedIntegerMultiply (
414 RtlEnlargedUnsignedDivide (
415 ULARGE_INTEGER Dividend
,
421 RtlEnlargedUnsignedMultiply (
427 RtlExtendedIntegerMultiply (
428 LARGE_INTEGER Multiplicand
,
433 RtlExtendedLargeIntegerDivide (
434 LARGE_INTEGER Dividend
,
440 RtlExtendedMagicDivide (
441 LARGE_INTEGER Dividend
,
442 LARGE_INTEGER MagicDivisor
,
447 ExInterlockedAddLargeInteger (
448 PLARGE_INTEGER Addend
,
449 LARGE_INTEGER Increment
,
455 LARGE_INTEGER Addend1
,
456 LARGE_INTEGER Addend2
461 PLARGE_INTEGER Result
,
462 LARGE_INTEGER Source
,
467 RtlLargeIntegerArithmeticShift (
468 LARGE_INTEGER LargeInteger
,
473 RtlLargeIntegerDivide (
474 LARGE_INTEGER Dividend
,
475 LARGE_INTEGER Divisor
,
476 PLARGE_INTEGER Remainder
480 RtlLargeIntegerEqualTo (
481 LARGE_INTEGER Operand1
,
482 LARGE_INTEGER Operand2
486 RtlLargeIntegerEqualToZero (
487 LARGE_INTEGER Operand
491 RtlLargeIntegerGreaterThan (
492 LARGE_INTEGER Operand1
,
493 LARGE_INTEGER Operand2
497 RtlLargeIntegerGreaterThanOrEqualTo (
498 LARGE_INTEGER Operand1
,
499 LARGE_INTEGER Operand2
503 RtlLargeIntegerGreaterThanOrEqualToZero (
504 LARGE_INTEGER Operand1
508 RtlLargeIntegerGreaterThanZero (
509 LARGE_INTEGER Operand1
513 RtlLargeIntegerLessThan (
514 LARGE_INTEGER Operand1
,
515 LARGE_INTEGER Operand2
519 RtlLargeIntegerLessThanOrEqualTo (
520 LARGE_INTEGER Operand1
,
521 LARGE_INTEGER Operand2
525 RtlLargeIntegerLessThanOrEqualToZero (
526 LARGE_INTEGER Operand
530 RtlLargeIntegerLessThanZero (
531 LARGE_INTEGER Operand
535 RtlLargeIntegerNegate (
536 LARGE_INTEGER Subtrahend
540 RtlLargeIntegerNotEqualTo (
541 LARGE_INTEGER Operand1
,
542 LARGE_INTEGER Operand2
546 RtlLargeIntegerNotEqualToZero (
547 LARGE_INTEGER Operand
551 RtlLargeIntegerShiftLeft (
552 LARGE_INTEGER LargeInteger
,
557 RtlLargeIntegerShiftRight (
558 LARGE_INTEGER LargeInteger
,
563 RtlLargeIntegerSubtract (
564 LARGE_INTEGER Minuend
,
565 LARGE_INTEGER Subtrahend
569 RtlLengthSecurityDescriptor (
570 PSECURITY_DESCRIPTOR SecurityDescriptor
582 RtlQueryRegistryValues (
585 PRTL_QUERY_REGISTRY_TABLE QueryTable
,
592 PULONG DestinationAddress
,
598 PUSHORT DestinationAddress
,
599 PUSHORT SourceAddress
603 RtlSetDaclSecurityDescriptor (
604 PSECURITY_DESCRIPTOR SecurityDescriptor
,
607 BOOLEAN DaclDefaulted
623 RtlTimeFieldsToTime (
624 PTIME_FIELDS TimeFields
,
629 RtlTimeToTimeFields (
631 PTIME_FIELDS TimeFields
636 PUNICODE_STRING _string
,
642 RtlGetCallersAddress (
643 PVOID
* CallersAddress
655 } RTL_HEAP_DEFINITION
, *PRTL_HEAP_DEFINITION
;
657 // Heap creation routine
667 PRTL_HEAP_DEFINITION Definition
688 RtlUnicodeStringToAnsiString (
689 IN OUT PANSI_STRING DestinationString
,
690 IN PUNICODE_STRING SourceString
,
691 IN BOOLEAN AllocateDestinationString
695 RtlUnicodeStringToInteger (
696 IN PUNICODE_STRING String
,
702 RtlUpcaseUnicodeString (
703 IN OUT PUNICODE_STRING DestinationString
,
704 IN PUNICODE_STRING SourceString
,
705 IN BOOLEAN AllocateDestinationString
710 PSTRING DestinationString
,
715 RtlValidSecurityDescriptor (
716 PSECURITY_DESCRIPTOR SecurityDescriptor
721 RtlWriteRegistryValue (
738 RtlNtStatusToDosError (
761 RtlGetProcessHeap (VOID
);
798 /* NtProcessStartup */
802 RtlDestroyProcessParameters(
803 IN OUT PSTARTUP_ARGUMENT pArgument
807 RtlDenormalizeProcessParams (
808 IN OUT PSTARTUP_ARGUMENT pArgument
811 #endif /* __DDK_RTL_H */