Fix symbol retrieval logic in injected kext, still needs dysymtab correction

This commit is contained in:
vit9696 2019-03-23 15:04:56 +03:00
parent 43ecade607
commit fc6fbed67c
2 changed files with 13 additions and 0 deletions

View File

@ -105,8 +105,17 @@ struct PRELINKED_KEXT_ {
// Sorted symbol table used only for dependencies.
//
PRELINKED_KEXT_SYMBOL *LinkedSymbolTable;
//
// A flag set during dependency walk BFS to avoid going through the same path.
//
BOOLEAN Processed;
//
// Number of vtables in this kext.
//
UINT32 NumberOfVtables;
//
// Scanned vtable buffer. Iterated with GET_NEXT_PRELINKED_VTABLE.
//
PRELINKED_VTABLE *LinkedVtables;
};

View File

@ -764,5 +764,9 @@ InternalLinkPrelinkedKext (
*AlignedLoadSize = RealLoadSize;
Kext->SymbolTable = NULL;
Kext->StringTable = NULL;
Kext->NumberOfSymbols = 0;
return Kext;
}