Function at 0x486800
Capabilities:
Accept command line arguments
Parse pe header
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x24
mov eax, dword [0x5ac004]
xor eax, esp
mov dword [esp + 0x20], eax
push ebx
push esi
push edi
xor eax, eax
mov byte [esp + 0x18], 0
push str.wdc.dll
mov esi, edx
mov dword [esp + 0x14], eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
test edi, edi
je 0x486ab0
mov eax, 0x5a4d
cmp word [edi], ax
jne 0x486aa9
mov eax, dword [edi + 0x3c]
test eax, eax
je 0x486aa9
cmp eax, 0x7fffffff
jae 0x486aa9
cmp dword [eax + edi], 0x4550
jne 0x486aa9
lea ecx, [eax + 0x78]
mov eax, dword [ecx + edi]
add ecx, edi
test eax, eax
je 0x486aa9
cmp dword [ecx + 4], 0
je 0x486aa9
push 0
push str.WdcRunTaskAsInteractiveUser
add eax, edi
push eax
push ecx
mov ecx, edi
call fcn.004b2920
mov dword ds:[esp + 0x20], eax
test eax, eax
je 0x486aa9
lea eax, [esp + 0x28]
push eax
push dword [esi + 4]
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov dword ds:[esp + 0x14], eax
test eax, eax
je 0x486a88
push dword [eax]
call sym.ProcessHacker.exe_PhCreateString
mov esi, eax
or ebx, 0xffffffff
test esi, esi
je 0x486a12
push dword ds:[esi + 4]
call sym.ProcessHacker.exe_PhDoesFileExistsWin32
test al, al
jne 0x486911
mov ecx, dword [esi + 4]
call fcn.004b1320
mov ecx, eax
test ecx, ecx
je 0x4869c2
mov eax, esi
mov esi, ecx
lea ecx, [eax - 8]
mov eax, ebx
lock xadd dword [ecx + 4], eax
dec eax
jne 0x486911
call fcn.004b3960
push 0x56afa0
push dword [esi + 4]
push 0x56afa0
push 3
call sym.ProcessHacker.exe_PhConcatStrings
mov ecx, eax
mov dword [esp + 0x20], eax
add esp, 0x10
mov dword [esp + 0x1c], ecx
mov eax, ebx
lock xadd dword [esi - 4], eax
dec eax
jne 0x486949
lea ecx, ds:[esi - 8]
call fcn.004b3960
mov ecx, dword [esp + 0x1c]
cmp dword [esp + 0x28], 2
jne 0x4869fc
mov eax, dword ds:[esp + 0x14]
push dword [eax + 4]
call sym.ProcessHacker.exe_PhCreateString
mov esi, eax
push 0x56afa0
push dword [esi + 4]
push 0x56afa0
push 3
call sym.ProcessHacker.exe_PhConcatStrings
mov dword [esp + 0x1c], eax
lea ecx, [esi - 8]
add esp, 0x10
mov eax, ebx
lock xadd dword [ecx + 4], eax
dec eax
jne 0x486994
call fcn.004b3960
mov esi, dword [esp + 0xc]
mov eax, dword [esp + 0x10]
push dword [esi + 4]
push 0x56afa4
push dword [eax + 4]
push 3
call sym.ProcessHacker.exe_PhConcatStrings
add esp, 0x10
mov dword [esp + 0x10], eax
push esi
call sym.ProcessHacker.exe_PhDereferenceObject
mov ecx, dword ds:[esp + 0x1c]
jmp 0x486a00
lea ecx, [esi - 8]
mov eax, ebx
lock xadd dword [ecx + 4], eax
dec eax
jne 0x486a12
call fcn.004b3960
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov al, byte [esp + 0x18]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x20]
xor ecx, esp
call fcn.0051e068
mov esp, ebp
pop ebp
ret
lock inc dword [ecx - 4]
add ecx, 0xfffffff8
mov eax, ebx
lock xadd dword [ecx + 4], eax
dec eax
jne 0x486a12
call fcn.004b3960
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov esi, dword [esp + 0x10]
test esi, esi
je 0x486a88
cmp dword [esi], 0
je 0x486a76
xor cl, cl
call fcn.00486660
mov dword [esp + 0xc], eax
test eax, eax
je 0x486a3d
mov eax, dword [eax + 4]
jmp 0x486a3f
xor eax, eax
mov ecx, dword [esp + 0x20]
push 0
push eax
push dword [esi + 4]
call dword [0x5404bc]
call dword [esp + 0x2c]
mov ecx, dword [esp + 0x18]
test eax, eax
mov eax, dword [esp + 0xc]
mov edx, 1
movzx ecx, cl
cmove ecx, edx
mov dword [esp + 0x18], ecx
test eax, eax
je 0x486a76
push eax
call sym.ProcessHacker.exe_PhDereferenceObject
lea ecx, ds:[esi - 8]
lock xadd dword [ecx + 4], ebx
dec ebx
jne 0x486a88
call fcn.004b3960
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov al, byte ds:[esp + 0x18]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x20]
xor ecx, esp
call fcn.0051e068
mov esp, ebp
pop ebp
ret
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov ecx, dword ds:[esp + 0x2c]
xor al, al
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0051e068
mov esp, ebp
pop ebp
ret