Function at 0x4054d0
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40f970
mov eax, dword fs:[0]
push eax
sub esp, 0x480
mov eax, dword [0x417174]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edi, dword [sym.imp.KERNEL32.dll_SetErrorMode]
push 0x8001
call edi
cmp byte [0x417fad], 0
mov dword [ebp - 0x434], eax
mov dword [ebp - 0x430], 0
je 0x405685
push 2
push 0x208
call fcn.004063e5
mov ebx, eax
add esp, 8
test ebx, ebx
je 0x405685
mov ecx, 0x4108c4
mov edx, ebx
sub edx, ecx
lea ecx, [ecx]
movzx eax, word [ecx]
mov word [edx + ecx], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x405550
mov edx, dword [0x417ff0]
mov esi, edx
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x405567
sub edx, esi
lea edi, [ebx - 2]
jmp 0x405580
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x405580
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [ebx - 2]
lea ecx, [ecx]
mov ax, word [edi + 2]
lea edi, [edi + 2]
test ax, ax
jne 0x4055a0
mov eax, dword [0x4108e8]
mov dword [edi], eax
push 0x44
xorps xmm0, xmm0
lea eax, [ebp - 0x48c]
push 0
push eax
movq qword [ebp - 0x448], xmm0
movq qword [ebp - 0x440], xmm0
call fcn.00406ee0
add esp, 0xc
lea eax, [ebp - 0x448]
push eax
lea eax, [ebp - 0x48c]
push eax
push 0
push 0
push 0x20
push 1
push 0
push 0
push ebx
push 0
mov dword [ebp - 0x48c], 0x44
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x405669
mov eax, dword [ebp - 0x448]
test eax, eax
je 0x40565f
mov edi, dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
lea ecx, [ebp - 0x430]
push ecx
push eax
call edi
test eax, eax
je 0x405649
push 0xfa
call esi
cmp dword [ebp - 0x430], 0x103
jne 0x405649
mov eax, dword [ebp - 0x448]
jmp 0x405620
push dword [ebp - 0x444]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x448]
call esi
mov dword [ebp - 0x430], 1
push ebx
call fcn.00406423
mov edi, dword [sym.imp.KERNEL32.dll_SetErrorMode]
add esp, 4
cmp dword [ebp - 0x430], 0
jne 0x405774
push 0x8001
call edi
mov ebx, eax
xor eax, eax
mov word [ebp - 0x220], ax
lea eax, [ebp - 0x220]
push eax
mov dword [ebp - 0x430], ebx
call fcn.00401570
lea eax, [ebp - 0x220]
push eax
call fcn.00401fc0
mov ecx, dword [0x417ff0]
lea edx, [ebp - 0x42c]
add esp, 8
sub edx, ecx
movzx eax, word [ecx]
mov word [edx + ecx], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x4056c6
lea eax, [ebp - 0x42c]
push 0x5c
push eax
call fcn.0040614b
add esp, 8
test eax, eax
je 0x4056fe
xor ecx, ecx
mov word [eax], cx
lea eax, [ebp - 0x42c]
push eax
call fcn.00402000
add esp, 4
push dword [0x417ff0]
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
mov dword [ebp - 0x438], esi
cmp esi, 0x20
jb 0x405758
push str.DllUnregisterServer
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x405751
mov dword [ebp - 4], 0
call eax
jmp 0x40574a
mov dword [ebp - 4], 0xffffffff
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp word [ebp - 0x220], 0
je 0x405771
lea eax, [ebp - 0x220]
push eax
call fcn.00402000
add esp, 4
push ebx
call edi
push dword [ebp - 0x434]
call edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0040658e
mov esp, ebp
pop ebp
ret