Function at 0x40e850
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x250
mov ecx, dword [0x55e300]
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x58]
push 0x104
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
mov edx, dword [0x546560]
mov ecx, 0xf
xor eax, eax
lea edi, [esp + 0x1c]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x58]
mov dword [esp + 0x1c], 0x3c
test eax, eax
mov dword [esp + 0x10], edx
je 0x40e8ee
lea ecx, [esp + 0x58]
shr ecx, 0x10
jne 0x40e8b6
xor edx, edx
lea eax, [esp + 0x58]
mov dx, ax
lea ecx, [esp + 0x10]
push edx
call fcn.00413c90
jmp 0x40e8ee
lea ecx, [esp + 0x58]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov esi, eax
test esi, esi
je 0x40e8ee
push esi
lea ecx, [esp + 0x14]
call fcn.00405530
test eax, eax
je 0x40e8ee
mov edi, dword [esp + 0x10]
lea ecx, [esi + esi]
mov edx, ecx
lea esi, [esp + 0x58]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x10]
xor eax, eax
mov dword [esp + 0x20], eax
mov edx, dword [ecx - 0xc]
lea ebx, [ecx - 0xc]
cmp edx, 1
jg 0x40e908
cmp dword [ecx - 4], eax
jge 0x40e968
mov ebp, dword [ecx - 8]
test ebp, ebp
jle 0x40e911
mov eax, ebp
push eax
lea ecx, [esp + 0x14]
call fcn.00405530
test eax, eax
jne 0x40e927
mov ebp, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
jmp 0x40e972
mov edi, dword [esp + 0x10]
lea ecx, [ebp + ebp + 2]
mov eax, ecx
lea esi, [ebx + 0xc]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x10]
mov dword [ecx - 8], ebp
mov eax, dword [0x546564]
cmp ebx, eax
je 0x40e968
mov ebp, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
push ebx
call ebp
test eax, eax
jg 0x40e96e
push ebx
call fcn.00531732
add esp, 4
jmp 0x40e96e
mov ebp, dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
mov eax, dword [esp + 0x10]
mov edx, dword [0x546560]
mov dword [esp + 0x2c], eax
mov ecx, str._install__runas
xor eax, eax
test ecx, ecx
mov dword [esp + 0x44], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x38], 1
mov dword [esp + 0x14], edx
je 0x40e9a2
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov esi, dword [esp + 0x264]
lea ecx, [esp + 0x14]
push esi
mov edx, dword [esi - 8]
push edx
push str._install__runas
push eax
call fcn.004059f0
lea eax, [esp + 0x14]
lea ecx, [esp + 0x18]
push eax
call fcn.00405440
mov eax, dword [esp + 0x14]
mov edx, dword [0x546564]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40e9f6
add eax, 0xfffffff4
push eax
call ebp
test eax, eax
jg 0x40e9f6
mov edx, dword [esp + 0x14]
add edx, 0xfffffff4
push edx
call fcn.00531732
add esp, 4
mov eax, dword [esp + 0x18]
lea ecx, [esp + 0x1c]
push ecx
mov dword [esp + 0x34], eax
mov dword [esp + 0x2c], 0x547140
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
mov ecx, dword [0x546564]
mov edi, eax
mov eax, dword [esp + 0x18]
lea edx, [eax - 0xc]
cmp edx, ecx
je 0x40ea3e
add eax, 0xfffffff4
push eax
call ebp
test eax, eax
jg 0x40ea3e
mov eax, dword [esp + 0x18]
add eax, 0xfffffff4
push eax
call fcn.00531732
add esp, 4
mov eax, dword [esp + 0x10]
mov edx, dword [0x546564]
lea ecx, [eax - 0xc]
cmp ecx, edx
je 0x40ea69
add eax, 0xfffffff4
push eax
call ebp
test eax, eax
jg 0x40ea69
mov edx, dword [esp + 0x10]
add edx, 0xfffffff4
push edx
call fcn.00531732
add esp, 4
mov ecx, dword [0x546564]
lea eax, [esi - 0xc]
cmp eax, ecx
je 0x40ea89
add esi, 0xfffffff4
push esi
call ebp
test eax, eax
jg 0x40ea89
push esi
call fcn.00531732
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x250
ret