Function at 0x401097
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x7b4
mov eax, dword [0x415004]
xor eax, esp
mov dword [esp + 0x7b0], eax
push ebx
push esi
mov esi, dword [ebp + 0x10]
push edi
xor edi, edi
cmp word [esi], di
jne 0x4010d9
push 0x10
push 0x412ba8
push 0x412c38
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
or eax, 0xffffffff
jmp 0x4015c5
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push 0x208
lea ecx, [esp + 0x1a4]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x401164
lea ecx, [esp + 0x40]
call section..text
push 0x30
push 0x412d50
push ecx
mov ecx, eax
call fcn.004019d5
push eax
lea ecx, [esp + 0x14]
call fcn.00401602
push 0x412d08
lea edx, [esp + 0x14]
lea ecx, [esp + 0x2c]
call fcn.004017d1
pop ecx
cmp dword [eax + 0x14], 8
jb 0x401135
mov eax, dword [eax]
push 0x10
push 0x412ba8
push eax
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
lea ecx, [esp + 0x28]
call fcn.004015dc
lea ecx, [esp + 0x10]
call fcn.004015dc
lea ecx, [esp + 0x40]
call fcn.004015dc
jmp 0x4010d1
lea eax, [esp + 0x1a0]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
push eax
lea ecx, [esp + 0x18c]
call fcn.00401635
push 8
pop ebx
cmp dword [esp + 0x19c], ebx
lea eax, [esp + 0x188]
cmovae eax, dword [esp + 0x188]
push eax
lea eax, [esp + 0x3ac]
push 0x104
push eax
call fcn.0040565f
add esp, 0xc
lea eax, [esp + 0x3a8]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveExtensionW]
lea ecx, [esp + 0x3a8]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x4011c6
sub ecx, edx
mov dword [esp + 0x150], edi
xor eax, eax
sar ecx, 1
mov word [esp + 0x140], ax
lea eax, [esp + 0x3a8]
push ecx
push eax
lea ecx, [esp + 0x148]
mov dword [esp + 0x15c], 7
call fcn.00401675
mov ecx, dword [esp + 0x150]
lea eax, [esp + 0x140]
dec ecx
cmp dword [esp + 0x154], ebx
mov dword [esp + 0x150], ecx
cmovae eax, dword [esp + 0x140]
xor edx, edx
mov word [eax + ecx*2], dx
lea eax, [esp + 0x1a0]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
test eax, eax
jne 0x40125e
push 0x10
push 0x412ba8
push 0x412db8
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
or esi, 0xffffffff
jmp 0x4015ab
lea ecx, [esp + 0x1a0]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, di
jne 0x401268
sub ecx, edx
mov dword [esp + 0x168], edi
xor eax, eax
sar ecx, 1
mov word [esp + 0x158], ax
lea eax, [esp + 0x1a0]
push ecx
push eax
lea ecx, [esp + 0x160]
mov dword [esp + 0x174], 7
call fcn.00401675
push ecx
lea edx, [esp + 0x144]
lea ecx, [esp + 0x174]
call fcn.00401768
cmp dword [esp + 0x188], ebx
lea eax, [esp + 0x15c]
pop ecx
lea ecx, [esp + 0x170]
cmovae ecx, dword [esp + 0x170]
cmp dword [esp + 0x16c], ebx
push ecx
cmovae eax, dword [esp + 0x15c]
push eax
lea eax, [esp + 0x5b8]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
test eax, eax
jne 0x401318
push 0x10
push 0x412ba8
push 0x412e78
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
or esi, 0xffffffff
jmp 0x401593
lea ecx, [esp + 0x5b0]
push 2
lea edx, [ecx + 2]
pop ebx
mov ax, word [ecx]
add ecx, ebx
cmp ax, di
jne 0x401325
sub ecx, edx
mov dword [esp + 0x20], edi
xor eax, eax
sar ecx, 1
mov word [esp + 0x10], ax
lea eax, [esp + 0x5b0]
push ecx
push eax
lea ecx, [esp + 0x18]
mov dword [esp + 0x2c], 7
call fcn.00401675
push 1
push 0x412f40
push ecx
lea ecx, [esp + 0x1c]
call fcn.004019d5
push eax
lea ecx, [esp + 0x2c]
call fcn.00401602
push esi
lea ecx, [esp + 0x5c]
call fcn.00401635
push eax
push 0x412f38
lea edx, [esp + 0x30]
lea ecx, [esp + 0x48]
call fcn.004017d1
pop ecx
mov edx, eax
lea ecx, [esp + 0x12c]
call fcn.0040180a
pop ecx
lea ecx, [esp + 0x40]
call fcn.004015dc
lea ecx, [esp + 0x28]
call fcn.004015dc
lea ecx, [esp + 0x10]
call fcn.004015dc
lea ecx, [esp + 0x58]
call fcn.004015dc
mov eax, dword [esp + 0x138]
xor ecx, ecx
inc eax
mul ebx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00401ed7
cmp dword [esp + 0x140], 8
lea edx, [esp + 0x12c]
pop ecx
cmovae edx, dword [esp + 0x128]
mov ebx, eax
mov ecx, dword [esp + 0x138]
lea eax, [esp + 0x128]
cmovae eax, dword [esp + 0x128]
lea ecx, [edx + ecx*2]
sub ecx, eax
push ecx
push eax
push ebx
call fcn.004047d0
mov eax, dword [esp + 0x144]
add esp, 0xc
xor ecx, ecx
mov word [ebx + eax*2], cx
lea eax, [esp + 0xe0]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoW]
push 0x44
pop esi
push esi
lea eax, [esp + 0x9c]
push edi
push eax
call fcn.004032e0
add esp, 0xc
lea edi, [esp + 0x88]
xor eax, eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov eax, 0x800
test dword [esp + 0x10c], eax
je 0x401478
mov dword [esp + 0xc4], eax
mov eax, dword [esp + 0xec]
jmp 0x401498
test dword [esp + 0x10c], 0x1000
mov dword [esp + 0xc4], 0x3000
jne 0x40146f
push 0x3e
call fcn.00401ed7
pop ecx
mov dword [esp + 0xa4], eax
xor edi, edi
lea eax, [esp + 0x88]
mov dword [esp + 0x98], esi
push eax
lea eax, [esp + 0x9c]
or esi, 0xffffffff
push eax
push edi
push edi
push 0x8000400
push edi
push edi
push edi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x4014f0
push dword [esp + 0x88]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [esp + 0x8c]
call esi
mov esi, edi
jmp 0x401580
push 0x412d08
push ecx
lea ecx, [esp + 0x78]
call section..text
pop ecx
push eax
lea eax, [esp + 0x130]
push 0x412f44
push eax
lea ecx, [esp + 0x20]
call fcn.004016fe
pop ecx
mov edx, eax
lea ecx, [esp + 0x34]
call fcn.004017d1
pop ecx
mov edx, eax
lea ecx, [esp + 0x48]
call fcn.0040180a
pop ecx
mov edx, eax
lea ecx, [esp + 0x5c]
call fcn.004017d1
pop ecx
cmp dword [eax + 0x14], 8
jb 0x401544
mov eax, dword [eax]
push 0x10
push 0x412ba8
push eax
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
lea ecx, [esp + 0x58]
call fcn.004015dc
lea ecx, [esp + 0x40]
call fcn.004015dc
lea ecx, [esp + 0x28]
call fcn.004015dc
lea ecx, [esp + 0x10]
call fcn.004015dc
lea ecx, [esp + 0x70]
call fcn.004015dc
push ebx
call fcn.00401ed2
pop ecx
lea ecx, [esp + 0x128]
call fcn.004015dc
lea ecx, [esp + 0x170]
call fcn.004015dc
lea ecx, [esp + 0x158]
call fcn.004015dc
lea ecx, [esp + 0x140]
call fcn.004015dc
lea ecx, [esp + 0x188]
call fcn.004015dc
mov eax, esi
mov ecx, dword [esp + 0x7bc]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00401e83
mov esp, ebp
pop ebp
ret 0x10