Dynamically calls NtAllocateVirtualMemory. It will return the NTSTATUS value returned by the call.
(handle: HANDLE, base_address: *mut PVOID, zero_bits: usize, size: *mut usize, allocation_type: u32, protection: u32)
| 638 | /// |
| 639 | /// It will return the NTSTATUS value returned by the call. |
| 640 | pub fn nt_allocate_virtual_memory (handle: HANDLE, base_address: *mut PVOID, zero_bits: usize, size: *mut usize, allocation_type: u32, protection: u32) -> i32 { |
| 641 | |
| 642 | unsafe |
| 643 | { |
| 644 | let ret; |
| 645 | let func_ptr: data::NtAllocateVirtualMemory; |
| 646 | let ntdll = get_module_base_address(&lc!("ntdll.dll")); |
| 647 | dynamic_invoke!(ntdll,&lc!("NtAllocateVirtualMemory"),func_ptr,ret,handle,base_address,zero_bits,size,allocation_type,protection); |
| 648 | |
| 649 | match ret { |
| 650 | Some(x) => return x, |
| 651 | None => return -1, |
| 652 | } |
| 653 | } |
| 654 | } |
| 655 | |
| 656 | /// Dynamically calls NtProtectVirtualMemory. |
| 657 | /// |
nothing calls this directly
no test coverage detected