Function at 0x405130
Capabilities:
Create process on windows

Disassembly:
push 0xffffffffffffffff
push 0x4771eb
mov eax, dword fs:[0]
push eax
sub esp, 0x1ac
mov eax, dword [0x4a3f4c]
xor eax, esp
mov dword [esp + 0x1a8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4a3f4c]
xor eax, esp
push eax
lea eax, [esp + 0x1c0]
mov dword fs:[0], eax
mov ebx, dword [esp + 0x1d0]
call fcn.00404250
test eax, eax
je 0x4053e7
call fcn.004043d0
test eax, eax
jne 0x4053e7
push 0x21
push 0xea61
push 0xea66
call fcn.0041ede0
add esp, 0xc
cmp eax, 1
jne 0x4053e7
test ebx, ebx
je 0x4052cd
mov eax, dword [ebx + 0x20]
push eax
call dword [sym.imp.USER32.dll_GetParent]
push eax
call fcn.004351f7
mov edx, dword [eax + 0x20]
lea ecx, [esp + 0x18]
push ecx
push edx
call dword [sym.imp.USER32.dll_GetWindowRect]
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov edi, dword [esp + 0x24]
mov esi, dword [esp + 0x20]
push ecx
push 0x47e774
mov dword [esp + 0x1c], eax
sub edi, eax
lea eax, [esp + 0x6c]
push 0x51
push eax
sub esi, ecx
call fcn.0045a19e
mov ebp, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
add esp, 0x10
push 0x4a6238
lea ecx, [esp + 0x68]
push ecx
push str.posx
push str.window
call ebp
mov edx, dword [esp + 0x14]
push edx
push 0x47e774
lea eax, [esp + 0x6c]
push 0x51
push eax
call fcn.0045a19e
add esp, 0x10
push 0x4a6238
lea ecx, [esp + 0x68]
push ecx
push str.posy
push str.window
call ebp
push esi
push 0x47e774
lea edx, [esp + 0x6c]
push 0x51
push edx
call fcn.0045a19e
add esp, 0x10
push 0x4a6238
lea eax, [esp + 0x68]
push eax
push str.sizx
push str.window
call ebp
push edi
push 0x47e774
lea ecx, [esp + 0x6c]
push 0x51
push ecx
call fcn.0045a19e
add esp, 0x10
push 0x4a6238
lea edx, [esp + 0x68]
push edx
push str.sizy
push str.window
call ebp
cmp dword [ebx + 0x60], 0
je 0x4052cd
cmp dword [0x4a601c], 0
jne 0x4052cd
push 0x24
push 0xea61
push 0xea69
call fcn.0041ede0
add esp, 0xc
cmp eax, 6
jne 0x4052cd
mov ecx, ebx
call fcn.0040d360
mov eax, dword [0x4a65d8]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x104
lea ecx, [esp + 0xbc]
push ecx
xor ebx, ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0x4053e7
push 0x38
lea edx, [esp + 0x30]
push ebx
push edx
mov dword [esp + 0x34], 0x3c
call fcn.0045af40
add esp, 0xc
lea ecx, [esp + 0x14]
call fcn.00401bd0
lea eax, [esp + 0xb8]
mov ebp, 1
push 0x48d4b1
lea ecx, [esp + 0x18]
mov dword [esp + 0x1cc], ebx
mov dword [esp + 0x38], str.runas
mov dword [esp + 0x3c], eax
mov dword [esp + 0x44], 0x4a5e60
mov dword [esp + 0x34], ebx
mov dword [esp + 0x48], ebp
call fcn.00402090
cmp dword [0x4ab5fc], ebp
mov esi, ebp
jl 0x4053a3
nop
mov ecx, dword [0x4ab600]
mov edx, dword [ecx + esi*4]
cmp edx, ebx
jne 0x405371
xor eax, eax
jmp 0x40537f
mov eax, edx
lea edi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x405376
sub eax, edi
push eax
push edx
lea ecx, [esp + 0x1c]
call fcn.00404ff0
push ebp
push 0x47effc
lea ecx, [esp + 0x1c]
call fcn.00404ff0
add esi, ebp
cmp esi, dword [0x4ab5fc]
jle 0x405360
mov esi, dword [esp + 0x14]
lea edx, [esp + 0x28]
push edx
mov dword [esp + 0x40], esi
call dword [sym.imp.SHELL32.dll_ShellExecuteExA]
test eax, eax
jne 0x405414
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea eax, [esi - 0x10]
mov dword [esp + 0x1c8], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4053e7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
mov ecx, dword [esp + 0x1c0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x1a8]
xor ecx, esp
call fcn.0045a1dd
add esp, 0x1b8
ret
push ebx
call fcn.0045b615
int3