MCPcopy Create free account
hub / github.com/Meowmycks/LetMeowIn / GetModuleBaseAddress

Function GetModuleBaseAddress

src/main.cpp:173–184  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

171}
172
173PVOID GetModuleBaseAddress(const wchar_t* moduleName) {
174 PPEB peb = GetPEB();
175 PLIST_ENTRY moduleList = &peb->Ldr->InLoadOrderModuleList;
176
177 for (PLIST_ENTRY entry = moduleList->Flink; entry != moduleList; entry = entry->Flink) {
178 PLDR_DATA_TABLE_ENTRY module = CONTAINING_RECORD(entry, LDR_DATA_TABLE_ENTRY, InLoadOrderLinks);
179 if (wcscmp(module->BaseDllName.Buffer, moduleName) == 0) {
180 return module->DllBase;
181 }
182 }
183 return nullptr;
184}
185
186int Partition(std::vector<SYSCALL_ENTRY>& arr, int low, int high) {
187 auto pivot = arr[high];

Callers 1

ParseEATFunction · 0.85

Calls 1

GetPEBFunction · 0.85

Tested by

no test coverage detected