Function at 0x409790
Capabilities:
Enumerate processes
Print debug messages
Terminate process
Terminate process by name

Disassembly:
push 0xffffffffffffffff
push 0x5451e9
mov eax, dword fs:[0]
push eax
sub esp, 0x13c
mov eax, dword [0x591d64]
xor eax, esp
mov dword [esp + 0x138], eax
push esi
push edi
mov eax, dword [0x591d64]
xor eax, esp
push eax
lea eax, [esp + 0x148]
mov dword fs:[0], eax
push 0
push 2
mov dword [esp + 0x158], 0
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
lea eax, [esp + 0x1c]
push eax
push esi
mov dword [esp + 0x24], 0x128
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x4098ba
call fcn.00415458
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x409814
push 0x80004005
call fcn.0040e230
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea edi, [eax + 0x10]
mov dword [esp + 0x18], edi
lea ecx, [esp + 0x1c]
push ecx
push esi
mov byte [esp + 0x158], 1
call sub.KERNEL32.dll_Process32Next
test eax, eax
je 0x409896
jmp 0x409840
lea eax, [esp + 0x40]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x409847
sub eax, edx
push eax
lea edx, [esp + 0x44]
push edx
lea ecx, [esp + 0x20]
call fcn.0040e1a0
mov ecx, dword [esp + 0x158]
xor eax, eax
test ecx, ecx
setne al
test eax, eax
je 0x40980a
mov edi, dword [esp + 0x18]
push ecx
push edi
call fcn.00506154
add esp, 8
test eax, eax
je 0x409912
lea eax, [esp + 0x1c]
push eax
push esi
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x409840
lea eax, [edi - 0x10]
mov byte [esp + 0x150], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4098ba
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x150], 0xffffffff
mov eax, dword [esp + 0x158]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4098e8
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
mov ecx, dword [esp + 0x148]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [esp + 0x138]
xor ecx, esp
call fcn.005043e7
add esp, 0x148
ret 8
cmp dword [esp + 0x15c], 0
je 0x4099aa
mov ecx, dword [esp + 0x24]
push ecx
push 0
push 1
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea edx, [esp + 0x158]
push edx
lea eax, [esp + 0x18]
push str.Msg:kill
push eax
call fcn.0040d960
push str._process_succeed._n
push eax
lea ecx, [esp + 0x24]
push ecx
mov byte [esp + 0x168], 2
call fcn.0040db20
mov eax, dword [eax]
add esp, 0x18
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40999c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x150], 1
mov eax, dword [esp + 0x14]
jmp 0x409a11
lea ecx, [esp + 0x158]
push ecx
lea edx, [esp + 0x14]
push str.Msg:find
push edx
call fcn.0040d960
push str._process_succeed._n
push eax
lea eax, [esp + 0x28]
push eax
mov byte [esp + 0x168], 3
call fcn.0040db20
mov eax, dword [eax]
add esp, 0x18
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x409a05
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x150], 1
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x409a2d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [edi - 0x10]
mov byte [esp + 0x150], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x409a51
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x150], 0xffffffff
mov eax, dword [esp + 0x158]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x409a7f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
jmp 0x4098ea