MCPcopy Create free account
hub / github.com/Kudaes/Split / nt_query_information_process

Function nt_query_information_process

dinvoke/src/lib.rs:732–746  ·  view source on GitHub ↗

Dynamically calls NtQueryInformationProcess. It will return the NTSTATUS value returned by the call.

(handle: HANDLE, process_information_class: u32, process_information: PVOID, length: u32, return_length: *mut u32)

Source from the content-addressed store, hash-verified

730///
731/// It will return the NTSTATUS value returned by the call.
732pub fn nt_query_information_process (handle: HANDLE, process_information_class: u32, process_information: PVOID, length: u32, return_length: *mut u32) -> i32 {
733
734 unsafe
735 {
736 let ret;
737 let func_ptr: data::NtQueryInformationProcess;
738 let ntdll = get_module_base_address(&lc!("ntdll.dll"));
739 dynamic_invoke!(ntdll,&lc!("NtQueryInformationProcess"),func_ptr,ret,handle,process_information_class,process_information,length,return_length);
740
741 match ret {
742 Some(x) => return x,
743 None => return -1,
744 }
745 }
746}
747
748/// Dynamically calls RtlAdjustPrivilege.
749///

Callers 1

get_api_mappingFunction · 0.85

Calls 1

get_module_base_addressFunction · 0.85

Tested by

no test coverage detected