From f90eb74f8d2e6bdee5bbe3d53ccd5a3e3aadbec2 Mon Sep 17 00:00:00 2001 From: Zebediah Figura Date: Thu, 23 Apr 2020 23:15:23 -0500 Subject: [PATCH] Rebase against 28bc1bb463eb4075c6a113ba5c279a0506c6daea. --- ...t-HashLinks-field-in-LDR-module-data.patch | 8 ++--- patches/ntdll-HashLinks/definition | 1 - ...DR_MODULE-to-more-recent-windows-ver.patch | 30 ------------------- patches/patchinstall.sh | 28 +---------------- 4 files changed, 5 insertions(+), 62 deletions(-) delete mode 100644 patches/ntdll-LDR_MODULE/0002-include-Update-LDR_MODULE-to-more-recent-windows-ver.patch diff --git a/patches/ntdll-HashLinks/0001-ntdll-Implement-HashLinks-field-in-LDR-module-data.patch b/patches/ntdll-HashLinks/0001-ntdll-Implement-HashLinks-field-in-LDR-module-data.patch index f1586e9d..72b94b63 100644 --- a/patches/ntdll-HashLinks/0001-ntdll-Implement-HashLinks-field-in-LDR-module-data.patch +++ b/patches/ntdll-HashLinks/0001-ntdll-Implement-HashLinks-field-in-LDR-module-data.patch @@ -1,4 +1,4 @@ -From 25bb10aa7f39e1586812802589a42c9cfa7d2513 Mon Sep 17 00:00:00 2001 +From 36780c821f4ea99a93920625a6f6106a84883eb9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20M=C3=BCller?= Date: Mon, 3 Apr 2017 05:30:27 +0200 Subject: [PATCH] ntdll: Implement HashLinks field in LDR module data. @@ -247,10 +247,10 @@ index 04ea7ea121a..2a8b4b3ad97 100644 server_init_process_done(); } diff --git a/include/winternl.h b/include/winternl.h -index b77ab8fe03a..3d4863d8b04 100644 +index f36419da782..20b267cd294 100644 --- a/include/winternl.h +++ b/include/winternl.h -@@ -2268,8 +2268,8 @@ typedef struct _LDR_MODULE +@@ -2330,8 +2330,8 @@ typedef struct _LDR_MODULE ULONG Flags; SHORT LoadCount; SHORT TlsIndex; @@ -259,7 +259,7 @@ index b77ab8fe03a..3d4863d8b04 100644 + LIST_ENTRY HashLinks; ULONG TimeDateStamp; HANDLE ActivationContext; - PVOID PatchInformation; + void* Lock; -- 2.26.0 diff --git a/patches/ntdll-HashLinks/definition b/patches/ntdll-HashLinks/definition index fd5de429..7da1398b 100644 --- a/patches/ntdll-HashLinks/definition +++ b/patches/ntdll-HashLinks/definition @@ -1,2 +1 @@ Fixes: Implement and use hash links when looking up LDR module -Depends: ntdll-LDR_MODULE \ No newline at end of file diff --git a/patches/ntdll-LDR_MODULE/0002-include-Update-LDR_MODULE-to-more-recent-windows-ver.patch b/patches/ntdll-LDR_MODULE/0002-include-Update-LDR_MODULE-to-more-recent-windows-ver.patch deleted file mode 100644 index 10331978..00000000 --- a/patches/ntdll-LDR_MODULE/0002-include-Update-LDR_MODULE-to-more-recent-windows-ver.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 85dae537010f21064aea63c24888609169cf249a Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Michael=20M=C3=BCller?= -Date: Tue, 7 Mar 2017 15:26:50 +0100 -Subject: [PATCH] include: Update LDR_MODULE to more recent windows versions. - ---- - include/winternl.h | 7 +++++++ - 1 file changed, 7 insertions(+) - -diff --git a/include/winternl.h b/include/winternl.h -index 7612f8a..3659db1 100644 ---- a/include/winternl.h -+++ b/include/winternl.h -@@ -2168,6 +2168,13 @@ typedef struct _LDR_MODULE - ULONG CheckSum; - ULONG TimeDateStamp; - HANDLE ActivationContext; -+ PVOID PatchInformation; -+ LIST_ENTRY ForwarderLinks; -+ LIST_ENTRY ServiceTagLinks; -+ LIST_ENTRY StaticLinks; -+ PVOID ContextInformation; -+ ULONG_PTR OriginalBase; -+ LARGE_INTEGER LoadTime; - } LDR_MODULE, *PLDR_MODULE; - - typedef struct _LDR_DLL_LOADED_NOTIFICATION_DATA --- -1.9.1 - diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index 7ad252a7..4bf21c87 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -52,7 +52,7 @@ usage() # Get the upstream commit sha upstream_commit() { - echo "f52b33c63064aa59f48a9c10d624e3508da55b88" + echo "28bc1bb463eb4075c6a113ba5c279a0506c6daea" } # Show version information @@ -185,7 +185,6 @@ patch_enable_all () enable_ntdll_Hide_Wine_Exports="$1" enable_ntdll_Interrupt_0x2e="$1" enable_ntdll_Junction_Points="$1" - enable_ntdll_LDR_MODULE="$1" enable_ntdll_Manifest_Range="$1" enable_ntdll_NtAccessCheck="$1" enable_ntdll_NtContinue="$1" @@ -663,9 +662,6 @@ patch_enable () ntdll-Junction_Points) enable_ntdll_Junction_Points="$2" ;; - ntdll-LDR_MODULE) - enable_ntdll_LDR_MODULE="$2" - ;; ntdll-Manifest_Range) enable_ntdll_Manifest_Range="$2" ;; @@ -1725,13 +1721,6 @@ if test "$enable_ntdll_NtContinue" -eq 1; then enable_winebuild_Fake_Dlls=1 fi -if test "$enable_ntdll_HashLinks" -eq 1; then - if test "$enable_ntdll_LDR_MODULE" -gt 1; then - abort "Patchset ntdll-LDR_MODULE disabled, but ntdll-HashLinks depends on that." - fi - enable_ntdll_LDR_MODULE=1 -fi - if test "$enable_ntdll_DOS_Attributes" -eq 1; then if test "$enable_ntdll_Junction_Points" -gt 1; then abort "Patchset ntdll-Junction_Points disabled, but ntdll-DOS_Attributes depends on that." @@ -4588,23 +4577,8 @@ if test "$enable_ntdll_ForceBottomUpAlloc" -eq 1; then ) >> "$patchlist" fi -# Patchset ntdll-LDR_MODULE -# | -# | Modified files: -# | * include/winternl.h -# | -if test "$enable_ntdll_LDR_MODULE" -eq 1; then - patch_apply ntdll-LDR_MODULE/0002-include-Update-LDR_MODULE-to-more-recent-windows-ver.patch - ( - printf '%s\n' '+ { "Michael Müller", "include: Update LDR_MODULE to more recent windows versions.", 1 },'; - ) >> "$patchlist" -fi - # Patchset ntdll-HashLinks # | -# | This patchset has the following (direct or indirect) dependencies: -# | * ntdll-LDR_MODULE -# | # | Modified files: # | * dlls/kernel32/tests/loader.c, dlls/ntdll/loader.c, include/winternl.h # |