Skip to content

Commit

Permalink
fixup win7 pooltable.
Browse files Browse the repository at this point in the history
  • Loading branch information
9176324 committed Mar 7, 2021
1 parent 80df328 commit 3cf8774
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
# Compiled binaries.
#
Build/**
Debug/**

#
# Visual Studio files.
Expand Down
7 changes: 4 additions & 3 deletions Projects/Shark/AMD64/PatchGuardAMD64.c
Original file line number Diff line number Diff line change
Expand Up @@ -806,6 +806,8 @@ InitializePgBlock(

if (NULL != ControlPc) {
PgBlock->Pool.PoolBigPageTable =
GetGpBlock(PgBlock)->BuildNumber < 9200 ?
__rva_to_va_ex(ControlPc + 3, 1) :
__rva_to_va(ControlPc
+ (GetGpBlock(PgBlock)->BuildNumber >= 9200 ? 8 : 3));

Expand Down Expand Up @@ -1683,9 +1685,8 @@ PgClearPoolEncryptedContext(
Index++) {
if (POOL_BIG_TABLE_ENTRY_FREE !=
((u64)POOL_TABLE[Index].Va & POOL_BIG_TABLE_ENTRY_FREE)) {
if (FALSE !=
PgBlock->Pool.MmIsNonPagedSystemAddressValid(POOL_TABLE[Index].Va)) {
if (POOL_TABLE[Index].NumberOfPages > PgBlock->SizeINITKDBG) {
if (POOL_TABLE[Index].NumberOfPages >= PgBlock->SizeINITKDBG) {
if (0 != PgBlock->Pool.MmIsNonPagedSystemAddressValid(POOL_TABLE[Index].Va)) {
PgCompareFields(
PgBlock,
PgPoolBigPage,
Expand Down

0 comments on commit 3cf8774

Please sign in to comment.