44#define SMSS_CHECKPOINT(x, y) \
46 SmpInitProgressByLine = __LINE__; \
47 SmpInitReturnStatus = (y); \
48 SmpInitLastCall = (x); \
76 NextEntry = ListAddress->
Flink;
77 while (NextEntry != ListAddress)
97 NextEntry = NextEntry->
Flink;
179 RtlInitEmptyAnsiString(&AnsiValueString,
201 while (NextEntry !=
List)
210 NextEntry = NextEntry->
Flink;
312 DPRINT(
"Creating: %wZ directory\n", &SearchString);
319 DPRINT1(
"SMSS: Unable to create %wZ object directory - Status == %lx\n",
400 DPRINT(
"Excluded DLL: %S\n", DllName);
407 DllName +=
wcslen(DllName) + 1;
502 DPRINT(
"Setting %wZ = %wZ\n", &ValueString, &DataString);
506 DPRINT1(
"SMSS: 'SET %wZ = %wZ' failed - Status == %lx\n",
507 &ValueString, &DataString,
Status);
564 while (*SubsystemName)
567 DPRINT(
"Found subsystem: %S\n", SubsystemName);
572 DPRINT1(
"SMSS: Invalid subsystem name - %ws\n", SubsystemName);
595 SubsystemName +=
wcslen(SubsystemName) + 1;
619 L"AllowProtectedRenames",
629 L"ObjectDirectories",
632 L"\\Windows\0\\RPC Control\0",
642 L"autocheck AutoChk.exe *\0",
659 L"PendingFileRenameOperations",
669 L"PendingFileRenameOperations2",
679 L"ExcludeFromKnownDlls",
689 L"Memory Management",
702 L"?:\\pagefile.sys\0",
835 DPRINT1(
"SMSS: Cannot open system setup key for reading: 0x%x\n",
Status);
851 DPRINT1(
"SMSS: Cannot query SystemPartition value (Type %lu, Status 0x%x)\n",
852 PartialInfo->Type,
Status);
858 (
PWCHAR)PartialInfo->Data,
859 PartialInfo->DataLength);
867 RtlInitEmptyUnicodeString(&
LinkTarget, LinkBuffer,
sizeof(LinkBuffer));
870 sizeof(DirInfoBuffer),
877 DPRINT1(
"SMSS: Cannot find drive letter for system partition\n");
886 (DirInfo->Name.Length == 2 *
sizeof(
WCHAR)) &&
887 (DirInfo->Name.Buffer[1] ==
L':'))
925 sizeof(DirInfoBuffer),
933 DPRINT1(
"SMSS: Cannot find drive letter for system partition\n");
939 L"\\Registry\\Machine\\Software\\Microsoft\\Windows\\CurrentVersion\\Setup");
948 DPRINT1(
"SMSS: Cannot open software setup key for writing: 0x%x\n",
954 wcsncpy(LinkBuffer, DirInfo->Name.Buffer, 2);
955 LinkBuffer[2] =
L'\\';
956 LinkBuffer[3] =
L'\0';
968 DPRINT1(
"SMSS: couldn't write BootDir value: 0x%x\n",
Status);
1045 0, 0, 0, 0, 0, 0, 0,
1068 0, 0, 0, 0, 0, 0, 0,
1079 0, 0, 0, 0, 0, 0, 0,
1083 RestrictedSid =
NULL;
1090 0, 0, 0, 0, 0, 0, 0,
1174 if (!ProtectionRequired)
goto Quickie;
1269 if (OwnerSid)
RtlFreeHeap(RtlGetProcessHeap(), 0, OwnerSid);
1272 if (SystemSid)
RtlFreeHeap(RtlGetProcessHeap(), 0, SystemSid);
1273 if (RestrictedSid)
RtlFreeHeap(RtlGetProcessHeap(), 0, RestrictedSid);
1301 DPRINT1(
"SMSS: Unable to open %wZ directory - Status == %lx\n",
1361 DPRINT1(
"SMSS: Unable to create %wZ => %wZ symbolic link object - Status == 0x%lx\n",
1388 PWCHAR DllName, DllValue;
1394 if (!
_stricmp(ImportName,
"ntdll.dll"))
return;
1398 RtlInitEmptyUnicodeString(&ImportUnicodeString,
Buffer,
sizeof(
Buffer));
1413 DllValue = ImportUnicodeString.
Buffer;
1438 USHORT ImageCharacteristics;
1441 DirFileHandle =
NULL;
1457 DPRINT1(
"SMSS: Unable to create %wZ directory - Status == %lx\n",
1466 DPRINT1(
"SMSS: Unable to to convert %wZ to an Nt path\n",
Path);
1486 DPRINT1(
"SMSS: Unable to open a handle to the KnownDll directory (%wZ)"
1487 "- Status == %lx\n",
1520 DPRINT1(
"SMSS: Unable to create %wZ symbolic link - Status == %lx\n",
1527 Status1 =
NtClose(LinkHandle);
1536 NextEntry = NextEntry->
Flink;
1569 &ImageCharacteristics);
1574 L"Verification of a KnownDLL failed.");
1575 ErrorParameters[0] = (
ULONG_PTR)&ErrorResponse;
1576 ErrorParameters[1] =
Status;
1584 L"Non-DLL file included in KnownDLL list.");
1585 ErrorParameters[0] = (
ULONG_PTR)&ErrorResponse;
1619 Status1 =
NtClose(SectionHandle);
1625 DPRINT1(
"SMSS: CreateSection for KnownDll %wZ failed - Status == %lx\n",
1643 Status1 =
NtClose(DirFileHandle);
1707 DPRINT1(
"SMSS: Unable to query system basic information - %x\n",
Status);
1714 sizeof(ProcessorInfo),
1719 DPRINT1(
"SMSS: Unable to query system processor information - %x\n",
Status);
1725 L"\\Registry\\Machine\\System\\CurrentControlSet\\"
1726 L"Control\\Session Manager\\Environment");
1752 DPRINT1(
"SMSS: Failed writing %wZ environment variable - %x\n",
1790 DPRINT1(
"SMSS: Failed writing %wZ environment variable - %x\n",
1808 DPRINT1(
"SMSS: Failed writing %wZ environment variable - %x\n",
1816 L"\\Registry\\Machine\\Hardware\\Description\\System\\"
1817 L"CentralProcessor\\0");
1837 sizeof(ValueBuffer),
1844 DPRINT1(
"SMSS: Unable to read %wZ\\%wZ (Type %lu, Status 0x%x)\n",
1852 (
PWCHAR)PartialInfo->Data,
1853 sizeof(ValueBuffer) -
1856 PartialInfo->DataLength,
1866 sizeof(ValueBuffer2),
1892 DPRINT1(
"SMSS: Failed writing %wZ environment variable - %x\n",
1934 DPRINT1(
"SMSS: Failed writing %wZ environment variable - %x\n",
1952 DPRINT1(
"SMSS: Failed writing %wZ environment variable - %x\n",
1960 L"\\Registry\\Machine\\System\\CurrentControlSet\\"
1961 L"Control\\Safeboot\\Option");
1976 sizeof(ValueBuffer),
1981 (PartialInfo->DataLength >=
sizeof(
ULONG)))
1985 switch (*(
PULONG)PartialInfo->Data)
1988 wcscpy(ValueBuffer,
L"MINIMAL");
1991 wcscpy(ValueBuffer,
L"NETWORK");
1994 wcscpy(ValueBuffer,
L"DSREPAIR");
2008 DPRINT1(
"SMSS: Failed writing %wZ environment variable - %x\n",
2016 DPRINT1(
"SMSS: Failed to query SAFEBOOT option (Type %lu, Status 0x%x)\n",
2017 PartialInfo->Type,
Status);
2051 DPRINT1(
"SMSS: FIXME: Handle SFC-protected file renames!\n");
2089 Length =
sizeof(DeleteInformation);
2143 DPRINT(
"\nSMSS: '%wZ' => '%wZ' failed - Status == %x, Possible readonly target\n",
2164 DPRINT1(
" SMSS: Open Existing file Failed - Status == %x\n",
2170 DPRINT(
" SMSS: Open Existing Success\n");
2182 DPRINT1(
" SMSS: Set To NORMAL Failed - Status == %x\n",
2188 DPRINT(
" SMSS: Set To NORMAL OK\n");
2197 DPRINT1(
" SMSS: Re-Rename Failed - Status == %x\n",
2203 DPRINT(
" SMSS: Re-Rename Worked OK\n");
2216 DPRINT1(
"SMSS: '%wZ' => '%wZ' failed - Status == %x\n",
2248 PVOID OriginalEnvironment;
2249 ULONG MuSessionId = 0;
2279 DPRINT1(
"SMSS: Unable to allocate default environment - Status == %X\n",
2287 L"\\Registry\\Machine\\System\\CurrentControlSet\\"
2288 L"Control\\MiniNT");
2307 L"\\Registry\\Machine\\System\\CurrentControlSet\\"
2308 L"Control\\Session Manager\\Environment");
2324 OriginalEnvironment =
NtCurrentPeb()->ProcessParameters->Environment;
2332 NtCurrentPeb()->ProcessParameters->Environment = OriginalEnvironment;
2336 DPRINT1(
"SMSS: RtlQueryRegistryValues failed - Status == %lx\n",
Status);
2346 DPRINT1(
"SMSS: Unable to initialize DosDevices configuration - Status == %lx\n",
2365 DPRINT1(
"SMSS: Unable to create %wZ object directory - Status == %lx\n",
2396 DPRINT1(
"SMSS: Unable to initialize KnownDll configuration - Status == %lx\n",
2442 ASSERT(MuSessionId == 0);
2456 ULONG HardErrorMode;
2463 SmpHeap = RtlGetProcessHeap();
2466 HardErrorMode =
TRUE;
2470 sizeof(HardErrorMode));
2550 DPRINT1(
"SMSS: Unable to create %wZ event - Status == %lx\n",
2551 &EventName, Status2);
NTSTATUS NTAPI NtCreateSection(OUT PHANDLE SectionHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL, IN PLARGE_INTEGER MaximumSize OPTIONAL, IN ULONG SectionPageProtection OPTIONAL, IN ULONG AllocationAttributes, IN HANDLE FileHandle OPTIONAL)
static UNICODE_STRING PortName
PRTL_UNICODE_STRING_BUFFER Path
#define FILE_DIRECTORY_FILE
#define FILE_NON_DIRECTORY_FILE
PPARTENTRY SystemPartition
VOID NTAPI SmpPagingFileInitialize(VOID)
NTSTATUS NTAPI SmpCreatePagingFiles(VOID)
NTSTATUS NTAPI SmpCreatePagingFileDescriptor(IN PUNICODE_STRING PageFileToken)
static SID_IDENTIFIER_AUTHORITY NtAuthority
PVOID NTAPI RtlAllocateHeap(IN PVOID HeapHandle, IN ULONG Flags, IN SIZE_T Size)
BOOLEAN NTAPI RtlFreeHeap(IN PVOID HeapHandle, IN ULONG Flags, IN PVOID HeapBase)
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES ObjectAttributes
#define NT_SUCCESS(StatCode)
#define FILE_ATTRIBUTE_NORMAL
static SID_IDENTIFIER_AUTHORITY WorldAuthority
#define RemoveEntryList(Entry)
#define InsertTailList(ListHead, Entry)
#define IsListEmpty(ListHead)
ULONG RtlCompareUnicodeString(PUNICODE_STRING s1, PUNICODE_STRING s2, BOOLEAN UpCase)
#define RemoveHeadList(ListHead)
#define InitializeListHead(ListHead)
struct _FileName FileName
@ SystemProcessorInformation
_Must_inspect_result_ _In_opt_ PFLT_INSTANCE _Out_ PHANDLE FileHandle
_In_ FILTER_INFORMATION_CLASS InformationClass
@ FileDispositionInformation
enum _FILE_INFORMATION_CLASS FILE_INFORMATION_CLASS
#define FILE_SYNCHRONOUS_IO_NONALERT
_In_ GUID _In_ PVOID ValueData
_CRTIMP size_t __cdecl wcslen(_In_z_ const wchar_t *_Str)
#define OBJ_CASE_INSENSITIVE
struct _FILE_RENAME_INFORMATION * PFILE_RENAME_INFORMATION
NTSYSAPI NTSTATUS WINAPI RtlAddAccessAllowedAce(PACL, DWORD, DWORD, PSID)
struct _FILE_RENAME_INFORMATION FILE_RENAME_INFORMATION
NTSYSAPI NTSTATUS WINAPI RtlQueryRegistryValues(ULONG, PCWSTR, PRTL_QUERY_REGISTRY_TABLE, PVOID, PVOID)
@ ProcessDefaultHardErrorMode
NTSYSAPI NTSTATUS WINAPI RtlSetDaclSecurityDescriptor(PSECURITY_DESCRIPTOR, BOOLEAN, PACL, BOOLEAN)
NTSTATUS NTAPI LdrVerifyImageMatchesChecksum(_In_ HANDLE FileHandle, _In_ PLDR_CALLBACK Callback, _In_ PVOID CallbackContext, _Out_ PUSHORT ImageCharacteristics)
WORD SECURITY_DESCRIPTOR_CONTROL
#define SE_RESTORE_PRIVILEGE
static const char const char * DllPath
static OUT PIO_STATUS_BLOCK IoStatusBlock
#define InitializeObjectAttributes(p, n, a, r, s)
_Must_inspect_result_ _Out_ PNDIS_STATUS _In_ NDIS_HANDLE _In_ ULONG _Out_ PNDIS_STRING _Out_ PNDIS_HANDLE KeyHandle
#define CM_BOOT_FLAG_SMSS
#define PROCESSOR_ARCHITECTURE_IA64
#define PROCESSOR_ARCHITECTURE_AMD64
#define PROCESSOR_ARCHITECTURE_INTEL
_In_ HANDLE ProcessHandle
struct _OBJECT_DIRECTORY_INFORMATION OBJECT_DIRECTORY_INFORMATION
_Out_ _Inout_ POEM_STRING _In_ PCUNICODE_STRING SourceString
NTSYSAPI NTSTATUS NTAPI RtlSetEnvironmentVariable(_In_z_ PWSTR *Environment, _In_ PUNICODE_STRING Name, _In_ PUNICODE_STRING Value)
NTSYSAPI NTSTATUS NTAPI RtlCreateAcl(PACL Acl, ULONG AclSize, ULONG AclRevision)
_In_ PCWSTR _Inout_ _At_ QueryTable EntryContext
NTSYSAPI NTSTATUS NTAPI RtlCreateEnvironment(_In_ BOOLEAN Inherit, _Out_ PWSTR *Environment)
NTSYSAPI NTSTATUS NTAPI RtlGetAce(PACL Acl, ULONG AceIndex, PVOID *Ace)
NTSYSAPI ULONG NTAPI RtlLengthSid(IN PSID Sid)
NTSYSAPI NTSTATUS NTAPI RtlCreateSecurityDescriptor(_Out_ PSECURITY_DESCRIPTOR SecurityDescriptor, _In_ ULONG Revision)
_Out_ _Inout_ POEM_STRING DestinationString
NTSYSAPI NTSTATUS NTAPI RtlCreateUserThread(_In_ PVOID ThreadContext, _Out_ HANDLE *OutThreadHandle, _Reserved_ PVOID Reserved1, _Reserved_ PVOID Reserved2, _Reserved_ PVOID Reserved3, _Reserved_ PVOID Reserved4, _Reserved_ PVOID Reserved5, _Reserved_ PVOID Reserved6, _Reserved_ PVOID Reserved7, _Reserved_ PVOID Reserved8)
NTSYSAPI NTSTATUS NTAPI RtlInitializeCriticalSection(_In_ PRTL_CRITICAL_SECTION CriticalSection)
NTSYSAPI NTSTATUS NTAPI RtlAdjustPrivilege(_In_ ULONG Privilege, _In_ BOOLEAN NewValue, _In_ BOOLEAN ForThread, _Out_ PBOOLEAN OldValue)
NTSYSAPI BOOLEAN NTAPI RtlDosPathNameToNtPathName_U(_In_opt_z_ PCWSTR DosPathName, _Out_ PUNICODE_STRING NtPathName, _Out_opt_ PCWSTR *NtFileNamePart, _Out_opt_ PRTL_RELATIVE_NAME_U DirectoryInfo)
#define SYMBOLIC_LINK_ALL_ACCESS
NTSYSAPI NTSTATUS NTAPI NtOpenFile(OUT PHANDLE phFile, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes, OUT PIO_STATUS_BLOCK pIoStatusBlock, IN ULONG ShareMode, IN ULONG OpenMode)
#define RTL_REGISTRY_CONTROL
NTSYSAPI NTSTATUS NTAPI RtlUnicodeStringToAnsiString(PANSI_STRING DestinationString, PUNICODE_STRING SourceString, BOOLEAN AllocateDestinationString)
NTSYSAPI NTSTATUS NTAPI NtOpenKey(OUT PHANDLE KeyHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes)
NTSYSAPI NTSTATUS NTAPI NtSetValueKey(IN HANDLE KeyHandle, IN PUNICODE_STRING ValueName, IN ULONG TitleIndex OPTIONAL, IN ULONG Type, IN PVOID Data, IN ULONG DataSize)
#define RTL_QUERY_REGISTRY_SUBKEY
@ KeyValuePartialInformation
#define SECTION_ALL_ACCESS
#define FILE_LIST_DIRECTORY
NTSYSAPI NTSTATUS NTAPI NtDeleteValueKey(IN HANDLE KeyHandle, IN PUNICODE_STRING ValueName)
NTSYSAPI NTSTATUS NTAPI RtlAnsiStringToUnicodeString(PUNICODE_STRING DestinationString, PANSI_STRING SourceString, BOOLEAN AllocateDestinationString)
NTSYSAPI VOID NTAPI RtlInitUnicodeString(PUNICODE_STRING DestinationString, PCWSTR SourceString)
#define RTL_QUERY_REGISTRY_NOEXPAND
NTSYSAPI BOOLEAN NTAPI RtlEqualUnicodeString(PUNICODE_STRING String1, PUNICODE_STRING String2, BOOLEAN CaseInSensitive)
#define NtCurrentProcess()
NTSYSAPI NTSTATUS NTAPI NtSetInformationFile(IN HANDLE hFile, OUT PIO_STATUS_BLOCK pIoStatusBlock, IN PVOID FileInformationBuffer, IN ULONG FileInformationBufferLength, IN FILE_INFORMATION_CLASS FileInfoClass)
NTSYSAPI NTSTATUS NTAPI NtQueryValueKey(IN HANDLE KeyHandle, IN PUNICODE_STRING ValueName, IN KEY_VALUE_INFORMATION_CLASS KeyValueInformationClass, IN PVOID KeyValueInformation, IN ULONG Length, IN PULONG ResultLength)
#define FILE_SHARE_DELETE
#define RTL_QUERY_REGISTRY_TOPKEY
struct _KEY_VALUE_PARTIAL_INFORMATION KEY_VALUE_PARTIAL_INFORMATION
#define FILE_WRITE_ATTRIBUTES
NTSTATUS NTAPI NtClose(IN HANDLE Handle)
NTSYSAPI BOOLEAN NTAPI RtlPrefixUnicodeString(IN PUNICODE_STRING String1, IN PUNICODE_STRING String2, IN BOOLEAN CaseInSensitive)
#define RTL_QUERY_REGISTRY_DELETE
#define DIRECTORY_ALL_ACCESS
NTSYSAPI VOID NTAPI RtlInitAnsiString(PANSI_STRING DestinationString, PCSZ SourceString)
NTSTATUS NTAPI NtInitializeRegistry(IN USHORT Flag)
_In_ ULONG _In_ ULONG _In_ ULONG Length
NTSYSAPI NTSTATUS NTAPI RtlAllocateAndInitializeSid(IN PSID_IDENTIFIER_AUTHORITY IdentifierAuthority, IN UCHAR SubAuthorityCount, IN ULONG SubAuthority0, IN ULONG SubAuthority1, IN ULONG SubAuthority2, IN ULONG SubAuthority3, IN ULONG SubAuthority4, IN ULONG SubAuthority5, IN ULONG SubAuthority6, IN ULONG SubAuthority7, OUT PSID *Sid)
NTSTATUS NTAPI NtSetEvent(IN HANDLE EventHandle, OUT PLONG PreviousState OPTIONAL)
NTSTATUS NTAPI NtCreateEvent(OUT PHANDLE EventHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL, IN EVENT_TYPE EventType, IN BOOLEAN InitialState)
NTSTATUS NTAPI NtCreatePort(OUT PHANDLE PortHandle, IN POBJECT_ATTRIBUTES ObjectAttributes, IN ULONG MaxConnectInfoLength, IN ULONG MaxDataLength, IN ULONG MaxPoolUsage)
NTSTATUS NTAPI NtSetInformationProcess(IN HANDLE ProcessHandle, IN PROCESSINFOCLASS ProcessInformationClass, IN PVOID ProcessInformation, IN ULONG ProcessInformationLength)
#define STATUS_OBJECT_NAME_EXISTS
#define STATUS_INVALID_IMPORT_OF_NON_DLL
_Must_inspect_result_ NTSTRSAFEAPI RtlStringCbLengthW(_In_reads_or_z_(cbMax/sizeof(wchar_t)) STRSAFE_LPCWSTR psz, _In_ _In_range_(1, NTSTRSAFE_MAX_CCH *sizeof(wchar_t)) size_t cbMax, _Out_opt_ _Deref_out_range_(<, cbMax - 1) size_t *pcbLength)
NTSTRSAFEVAPI RtlStringCbPrintfW(_Out_writes_bytes_(cbDest) _Always_(_Post_z_) NTSTRSAFE_PWSTR pszDest, _In_ size_t cbDest, _In_ _Printf_format_string_ NTSTRSAFE_PCWSTR pszFormat,...)
NTSTRSAFEAPI RtlStringCbCopyNW(_Out_writes_bytes_(cbDest) NTSTRSAFE_PWSTR pszDest, _In_ size_t cbDest, _In_reads_bytes_(cbToCopy) STRSAFE_LPCWSTR pszSrc, _In_ size_t cbToCopy)
NTSTATUS NTAPI NtOpenDirectoryObject(OUT PHANDLE DirectoryHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes)
NTSTATUS NTAPI NtCreateDirectoryObject(OUT PHANDLE DirectoryHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes)
NTSTATUS NTAPI NtQueryDirectoryObject(IN HANDLE DirectoryHandle, OUT PVOID Buffer, IN ULONG BufferLength, IN BOOLEAN ReturnSingleEntry, IN BOOLEAN RestartScan, IN OUT PULONG Context, OUT PULONG ReturnLength OPTIONAL)
NTSTATUS NTAPI NtMakeTemporaryObject(IN HANDLE ObjectHandle)
NTSTATUS NTAPI NtQuerySymbolicLinkObject(IN HANDLE LinkHandle, OUT PUNICODE_STRING LinkTarget, OUT PULONG ResultLength OPTIONAL)
NTSTATUS NTAPI NtCreateSymbolicLinkObject(OUT PHANDLE LinkHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes, IN PUNICODE_STRING LinkTarget)
NTSTATUS NTAPI NtOpenSymbolicLinkObject(OUT PHANDLE LinkHandle, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes)
_Check_return_ _CRTIMP int __cdecl _wcsicmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
_CRTIMP wchar_t *__cdecl wcsncpy(wchar_t *_Dest, const wchar_t *_Source, size_t _Count)
_CRTIMP wchar_t *__cdecl _wcsupr(_Inout_z_ wchar_t *_String)
ULONG NTAPI RtlCreateTagHeap(_In_ HANDLE HeapHandle, _In_ ULONG Flags, _In_opt_ PWSTR TagName, _In_ PWSTR TagSubName)
NTSTATUS NTAPI SmpConfigureProtectionMode(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
LIST_ENTRY SmpBootExecuteList
#define SMSS_CHECKPOINT(x, y)
LIST_ENTRY SmpSubSystemList
LIST_ENTRY SmpSubSystemsToLoad
PSMP_REGISTRY_VALUE NTAPI SmpFindRegistryValue(IN PLIST_ENTRY List, IN PWSTR ValueName)
ULONG SmpInitProgressByLine
NTSTATUS NTAPI SmpConfigureExcludeKnownDlls(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
UNICODE_STRING SmpKnownDllPath
PWCHAR SmpDefaultLibPathBuffer
NTSTATUS NTAPI SmpConfigureSubSystems(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
SECURITY_DESCRIPTOR SmpApiPortSDBody
NTSTATUS NTAPI SmpConfigureObjectDirectories(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
LIST_ENTRY SmpKnownDllsList
LIST_ENTRY SmpSubSystemsToDefer
NTSTATUS NTAPI SmpLoadDataFromRegistry(OUT PUNICODE_STRING InitialCommand)
LIST_ENTRY SmpPagingFileList
LIST_ENTRY SmpExecuteList
LIST_ENTRY SmpDosDevicesList
NTSTATUS NTAPI SmpConfigureMemoryMgmt(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
SECURITY_DESCRIPTOR SmpLiberalSDBody
NTSTATUS NTAPI SmpConfigureAllowProtectedRenames(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
NTSTATUS NTAPI SmpProcessFileRenames(VOID)
PISECURITY_DESCRIPTOR SmpLiberalSecurityDescriptor
LIST_ENTRY SmpFileRenameList
UNICODE_STRING SmpDefaultLibPath
NTSTATUS NTAPI SmpInitializeKnownDllsInternal(IN PUNICODE_STRING Directory, IN PUNICODE_STRING Path)
LIST_ENTRY SmpExcludeKnownDllsList
VOID NTAPI SmpTranslateSystemPartitionInformation(VOID)
PWCHAR SmpDefaultEnvironment
SECURITY_DESCRIPTOR SmpKnownDllsSDBody
PISECURITY_DESCRIPTOR SmpKnownDllsSecurityDescriptor
NTSTATUS NTAPI SmpConfigureEnvironment(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
NTSTATUS NTAPI SmpCreateDynamicEnvironmentVariables(VOID)
NTSTATUS NTAPI SmpInitializeDosDevices(VOID)
NTSTATUS SmpInitReturnStatus
PISECURITY_DESCRIPTOR SmpApiPortSecurityDescriptor
NTSTATUS NTAPI SmpInitializeKnownDlls(VOID)
SECURITY_DESCRIPTOR SmpPrimarySDBody
PISECURITY_DESCRIPTOR SmpPrimarySecurityDescriptor
LIST_ENTRY SmpSetupExecuteList
NTSTATUS NTAPI SmpInitializeKnownDllPath(IN PUNICODE_STRING DllPath, IN PWCHAR Buffer, IN ULONG Length)
NTSTATUS NTAPI SmpConfigureKnownDlls(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
NTSTATUS NTAPI SmpInit(IN PUNICODE_STRING InitialCommand, OUT PHANDLE ProcessHandle)
VOID NTAPI SmpProcessModuleImports(IN PVOID Unused, IN PCHAR ImportName)
ULONG SmpAllowProtectedRenames
UNICODE_STRING SmpSubsystemName
HANDLE SmpDosDevicesObjectDirectory
RTL_QUERY_REGISTRY_TABLE SmpRegistryConfigurationTable[]
NTSTATUS NTAPI SmpConfigureDosDevices(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
NTSTATUS NTAPI SmpConfigureFileRenames(IN PWSTR ValueName, IN ULONG ValueType, IN PVOID ValueData, IN ULONG ValueLength, IN PVOID Context, IN PVOID EntryContext)
LIST_ENTRY NativeProcessList
NTSTATUS NTAPI SmpSaveRegistryValue(IN PLIST_ENTRY ListAddress, IN PWSTR Name, IN PWCHAR Value, IN BOOLEAN Flags)
NTSTATUS NTAPI SmpCreateSecurityDescriptors(IN BOOLEAN InitialCall)
ULONG NTAPI SmpApiLoop(IN PVOID Parameter)
LIST_ENTRY SmpSessionListHead
RTL_CRITICAL_SECTION SmpSessionListLock
BOOLEAN SmpNextSessionIdScanMode
HANDLE SmpSessionsObjectDirectory
NTSTATUS NTAPI SmpTerminate(IN PULONG_PTR Parameters, IN ULONG ParameterMask, IN ULONG ParameterCount)
NTSTATUS NTAPI SmpExecuteCommand(IN PUNICODE_STRING CommandLine, IN ULONG MuSessionId, OUT PHANDLE ProcessId, IN ULONG Flags)
HANDLE SmpWindowsSubSysProcess
UNICODE_STRING SmpAutoChkKeyword
NTSTATUS NTAPI SmpLoadSubSystemsForMuSession(IN PULONG MuSessionId, OUT PHANDLE ProcessId, IN PUNICODE_STRING InitialCommand)
RTL_CRITICAL_SECTION SmpKnownSubSysLock
UNICODE_STRING SmpDebugKeyword
HANDLE SmpWindowsSubSysProcessId
UNICODE_STRING SmpASyncKeyword
BOOLEAN RegPosixSingleInstance
LIST_ENTRY SmpKnownSubSysHead
NTSYSAPI NTSTATUS NTAPI NtQuerySystemInformation(IN SYSTEM_INFORMATION_CLASS SystemInfoClass, OUT PVOID SystemInfoBuffer, IN ULONG SystemInfoBufferSize, OUT PULONG BytesReturned OPTIONAL)
base for all directory entries
base of all file and directory entries
struct _LIST_ENTRY * Flink
unsigned short MaximumLength
#define FIELD_OFFSET(t, f)
#define RtlCopyMemory(Destination, Source, Length)
#define RtlZeroMemory(Destination, Length)
#define CONTAINING_RECORD(address, type, field)
#define STATUS_OBJECT_NAME_COLLISION
#define STATUS_OBJECT_NAME_INVALID
_Must_inspect_result_ _In_ WDFDEVICE _In_ DEVICE_REGISTRY_PROPERTY _In_ ULONG _Out_ PULONG ResultLength
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _In_ ULONG _Out_opt_ PULONG _Out_opt_ PULONG ValueType
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING ValueName
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _In_ ULONG ValueLength
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _Out_opt_ PUSHORT _Inout_opt_ PUNICODE_STRING Value
_Must_inspect_result_ _In_ WDFCMRESLIST List
_Must_inspect_result_ _In_ ULONG Flags
_Out_ PHANDLE EventHandle
#define CONTAINER_INHERIT_ACE
#define SECURITY_BUILTIN_DOMAIN_RID
#define SE_DACL_DEFAULTED
#define SECURITY_WORLD_SID_AUTHORITY
#define SECURITY_WORLD_RID
#define SECURITY_LOCAL_SYSTEM_RID
#define SECURITY_RESTRICTED_CODE_RID
#define SECURITY_NT_AUTHORITY
#define OBJECT_INHERIT_ACE
#define SECURITY_DESCRIPTOR_REVISION
#define SECURITY_CREATOR_OWNER_RID
#define DOMAIN_ALIAS_RID_ADMINS
#define SECURITY_CREATOR_SID_AUTHORITY
_Inout_ PUNICODE_STRING LinkTarget