Function at 0x401d20
Capabilities:
Acquire debug privileges
Check if file exists
Execute command
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4046a8
mov eax, dword fs:[0]
push eax
sub esp, 0x110
mov eax, dword [0x408040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
or edi, 0xffffffff
mov ecx, dword [ebp + 0xc]
cmp eax, 3
jne 0x401d73
mov edi, dword [ecx + 4]
mov ecx, dword [ecx + 8]
mov dword [ebp - 0x11c], edi
call fcn.00401c60
mov esi, eax
jmp 0x401e96
cmp eax, 2
jne 0x40222d
mov eax, dword [ecx + 4]
xorps xmm0, xmm0
movups xmmword [ebp - 0x34], xmm0
mov dword [ebp - 0x11c], eax
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0xf
mov byte [ebp - 0x34], 0
push str.Process_Name:_n
mov dword [ebp - 4], 0
call fcn.00401020
mov esi, dword [sym.imp.MSVCP140.dll_class_std::basic_istream_char__struct_std::char_traits_char___std::cin]
add esp, 4
mov eax, dword [esi]
push 0xa
mov ecx, dword [eax + 4]
add ecx, esi
call dword [sym.imp.MSVCP140.dll_public:_char___thiscall_std::basic_ios_char__struct_std::char_traits_char__::widen_char_const]
movzx eax, al
lea edx, [ebp - 0x34]
push eax
mov ecx, esi
call fcn.004035a0
add esp, 4
lea esi, [ebp - 0x34]
cmp dword [ebp - 0x20], 0xf
cmova esi, dword [ebp - 0x34]
mov ecx, esi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401de8
sub ecx, edx
lea eax, [ecx + 1]
mov ecx, 2
mul ecx
cmovb eax, edi
push eax
call fcn.0040382b
mov edx, esi
mov dword [ebp - 0x18], eax
add esp, 4
lea eax, [edx + 1]
nop
mov cl, byte [edx]
inc edx
test cl, cl
jne 0x401e10
mov ecx, esi
sub edx, eax
lea edi, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401e20
sub ecx, edi
push edx
push esi
mov esi, dword [ebp - 0x18]
lea eax, [ecx + 1]
push eax
push esi
push 0
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_mbstowcs_s]
add esp, 0x14
mov ecx, esi
call fcn.00401c60
mov dword [ebp - 4], 0xffffffff
mov esi, eax
mov ecx, dword [ebp - 0x20]
cmp ecx, 0xf
jbe 0x401e84
mov edx, dword [ebp - 0x34]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x401e7a
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x401e7a
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0040381d
add esp, 8
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0xf
mov byte [ebp - 0x34], 0
test esi, esi
jne 0x401eba
push str.Process_not_found_n
call fcn.00401020
push str.pause
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 8
or eax, 0xffffffff
jmp 0x402251
push esi
push str.Process_pid:__d_n
call fcn.00401020
add esp, 8
mov dword [ebp - 0x60], 0
lea eax, [ebp - 0x60]
xorps xmm0, xmm0
movups xmmword [ebp - 0x5c], xmm0
push eax
push 0x28
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x401f30
lea eax, [ebp - 0x58]
mov dword [ebp - 0x5c], 1
push eax
push str.SeDebugPrivilege
push 0
mov dword [ebp - 0x50], 2
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
je 0x401f2b
push 0
push 0
push 0
lea eax, [ebp - 0x5c]
push eax
push 0
push dword [ebp - 0x60]
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
push dword [ebp - 0x60]
call edi
push esi
push 0
push 0x1fffff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
jne 0x401f6b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.OpenProcess_failed:_0x_X_n
call fcn.00401020
push str.PAUSE
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 0xc
lea eax, [esi - 2]
jmp 0x402251
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], 0
push eax
push esi
call dword [sym.imp.KERNEL32.dll_IsWow64Process]
test eax, eax
jne 0x401f97
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Cant_confirm_target_process_architecture:_0x_X_n
call fcn.00401020
add esp, 8
jmp 0x401fb7
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_IsWow64Process]
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp - 0x18]
je 0x401fdf
push str.Invalid_Process_Architecture._n
call fcn.00401020
add esp, 4
push esi
call edi
push str.PAUSE
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 4
mov eax, 0xfffffffd
jmp 0x402251
push dword [ebp - 0x11c]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x402018
push str.Dll_file_doesnt_exist_n
call fcn.00401020
add esp, 4
push esi
call edi
push str.PAUSE
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 4
mov eax, 0xfffffffc
jmp 0x402251
push 0xb8
lea eax, [ebp - 0x118]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
push dword [ebp - 0x11c]
lea ecx, [ebp - 0x118]
call fcn.00402e30
mov dword [ebp - 4], 1
mov eax, dword [ebp - 0x118]
mov eax, dword [eax + 4]
test byte [ebp + eax - 0x10c], 6
je 0x4020b9
push dword [ebp + eax - 0x10c]
push str.Opening_the_file_failed:__X_n
call fcn.00401020
add esp, 8
lea ecx, [ebp - 0x108]
call fcn.004032c0
test eax, eax
jne 0x402091
push eax
mov eax, dword [ebp - 0x118]
lea ecx, [ebp - 0x118]
push 2
add ecx, dword [eax + 4]
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
push esi
call edi
push str.PAUSE
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 4
lea ecx, [ebp - 0x118]
mov esi, 0xfffffffb
call fcn.00402270
mov eax, esi
jmp 0x402251
lea eax, [ebp - 0x4c]
push eax
lea ecx, [ebp - 0x118]
call dword [sym.imp.MSVCP140.dll_public:_class_std::fpos_struct__Mbstatet____thiscall_std::basic_istream_char__struct_std::char_traits_char__::tellg_void_]
mov eax, dword [ebp - 0x44]
add eax, dword [ebp - 0x4c]
mov ecx, dword [ebp - 0x40]
adc ecx, dword [ebp - 0x48]
test ecx, ecx
jg 0x40213e
jl 0x4020e2
cmp eax, 0x1000
jae 0x40213e
push str.Filesize_invalid._n
call fcn.00401020
add esp, 4
lea ecx, [ebp - 0x108]
call fcn.004032c0
test eax, eax
jne 0x402116
push eax
mov eax, dword [ebp - 0x118]
lea ecx, [ebp - 0x118]
push 2
add ecx, dword [eax + 4]
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
push esi
call edi
push str.PAUSE
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 4
lea ecx, [ebp - 0x118]
mov esi, 0xfffffffa
call fcn.00402270
mov eax, esi
jmp 0x402251
push eax
call fcn.0040382b
add esp, 4
mov dword [ebp - 0x11c], eax
lea ecx, [ebp - 0x118]
push 0
push 0
push 0
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_istream_char__struct_std::char_traits_char______thiscall_std::basic_istream_char__struct_std::char_traits_char__::seekg_long_long___int64___int_]
mov edx, dword [ebp - 0x44]
add edx, dword [ebp - 0x4c]
mov ecx, dword [ebp - 0x40]
adc ecx, dword [ebp - 0x48]
push ecx
push edx
push dword [ebp - 0x11c]
lea ecx, [ebp - 0x118]
call dword [sym.imp.MSVCP140.dll_public:_class_std::basic_istream_char__struct_std::char_traits_char______thiscall_std::basic_istream_char__struct_std::char_traits_char__::read_char___long_long___int64__]
lea ecx, [ebp - 0x108]
call fcn.004032c0
test eax, eax
jne 0x4021a6
push eax
mov eax, dword [ebp - 0x118]
lea ecx, [ebp - 0x118]
push 2
add ecx, dword [eax + 4]
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
push str.Mapping..._n
call fcn.00401020
mov edx, dword [ebp - 0x11c]
sub esp, 0x18
mov ecx, esi
call fcn.00401050
add esp, 0x1c
push dword [ebp - 0x11c]
test al, al
jne 0x402204
call fcn.004037e8
add esp, 4
push esi
call edi
push str.Error_while_mapping._n
call fcn.00401020
push str.PAUSE
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 8
lea ecx, [ebp - 0x118]
mov esi, 0xfffffff8
call fcn.00402270
mov eax, esi
jmp 0x402251
call fcn.004037e8
add esp, 4
push esi
call edi
push 0x4057d0
call fcn.00401020
add esp, 4
lea ecx, [ebp - 0x118]
xor esi, esi
call fcn.00402270
mov eax, esi
jmp 0x402251
push str.Invalid_Params_n
call fcn.00401020
push str.Usage:_dll_path__process_name__n
call fcn.00401020
push str.pause
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
add esp, 0xc
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004037da
mov esp, ebp
pop ebp
ret