MCPcopy Create free account
hub / github.com/HoShiMin/Kernel-Bridge / KbAllocKernelMemory

Function KbAllocKernelMemory

User-Bridge/API/User-Bridge.cpp:424–434  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

422namespace VirtualMemory
423{
424 BOOL WINAPI KbAllocKernelMemory(ULONG Size, BOOLEAN Executable, OUT WdkTypes::PVOID* KernelAddress)
425 {
426 if (!Size || !KernelAddress) return FALSE;
427 KB_ALLOC_KERNEL_MEMORY_IN Input = {};
428 KB_ALLOC_KERNEL_MEMORY_OUT Output = {};
429 Input.Size = Size;
430 Input.Executable = Executable;
431 BOOL Status = KbSendRequest(Ctls::KbAllocKernelMemory, &Input, sizeof(Input), &Output, sizeof(Output));
432 *KernelAddress = Output.KernelAddress;
433 return Status;
434 }
435
436 BOOL WINAPI KbFreeKernelMemory(IN WdkTypes::PVOID KernelAddress)
437 {

Callers 2

KbRtlMapDriverMemoryFunction · 0.70
KbRtlLoadModuleMemoryFunction · 0.70

Calls 1

KbSendRequestFunction · 0.85

Tested by

no test coverage detected