Function at 0x402eba
Capabilities:
Enumerate processes
Terminate process
Terminate process by name

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4bffbd
mov eax, dword fs:[0]
push eax
sub esp, 0x2a0
mov eax, dword [0x50e7dc]
xor eax, esp
mov dword [esp + 0x298], eax
push ebx
push esi
push edi
mov eax, dword [0x50e7dc]
xor eax, esp
push eax
lea eax, [esp + 0x2b0]
mov dword fs:[0], eax
mov ebx, dword [ebp + 8]
xor edi, edi
mov dword [esp + 0x18], ebx
cmp ebx, edi
je 0x40315d
mov ecx, 0x4d51f0
mov eax, ebx
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x402f38
cmp dx, di
je 0x402f34
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x402f38
add eax, 4
add ecx, 4
cmp dx, di
jne 0x402f12
xor eax, eax
jmp 0x402f3d
sbb eax, eax
sbb eax, 0xffffffff
cmp eax, edi
je 0x40315d
push str.CSystemCommands::KillAllProcesses__process_name
lea ecx, [esp + 0x20]
call fcn.00404bd0
xor esi, esi
inc esi
push ebx
lea ecx, [esp + 0x5c]
mov dword [esp + 0x2bc], esi
call fcn.00404bd0
push eax
lea eax, [esp + 0x20]
push eax
mov byte [esp + 0x2c0], 2
call fcn.00401985
pop ecx
pop ecx
push edi
push esi
lea ecx, [esp + 0x60]
call fcn.004058b3
or dword [esp + 0x2b8], 0xffffffff
push edi
push esi
lea ecx, [esp + 0x24]
call fcn.004058b3
push str.CSystemCommands::KillAllProcesses__timeout
lea ecx, [esp + 0x20]
call fcn.00404bd0
push dword [ebp + 0xc]
lea eax, [esp + 0x20]
push eax
mov dword [esp + 0x2c0], 3
call fcn.004018c5
or dword [esp + 0x2c0], 0xffffffff
pop ecx
pop ecx
push edi
push esi
lea ecx, [esp + 0x24]
call fcn.004058b3
push edi
call fcn.004a02ed
pop ecx
push edi
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
push 0x228
mov dword [esp + 0x18], eax
lea eax, [esp + 0x7c]
push edi
push eax
call fcn.0049f650
add esp, 0xc
lea eax, [esp + 0x74]
push eax
push dword [esp + 0x18]
mov dword [esp + 0x7c], 0x22c
call sub.KERNEL32.dll_Process32FirstW
jmp 0x403017
mov ebx, dword [esp + 0x18]
lea eax, [esp + 0x98]
push ebx
push eax
call fcn.004a1037
pop ecx
pop ecx
test eax, eax
jne 0x40310d
push str.CSystemCommands::KillAllProcesses__about_to_kill...
lea ecx, [esp + 0x20]
call fcn.00404bd0
lea eax, [esp + 0x1c]
push eax
mov dword [esp + 0x2bc], 4
call fcn.004017f5
or dword [esp + 0x2bc], 0xffffffff
pop ecx
push edi
push esi
lea ecx, [esp + 0x24]
call fcn.004058b3
push dword [esp + 0x7c]
push edi
push 0x100001
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov ebx, eax
cmp ebx, edi
je 0x40310d
push str.CSystemCommands::KillAllProcesses__open_process_succeeded.
lea ecx, [esp + 0x20]
call fcn.00404bd0
lea eax, [esp + 0x1c]
push eax
mov dword [esp + 0x2bc], 5
call fcn.004017f5
or dword [esp + 0x2bc], 0xffffffff
pop ecx
push edi
push esi
lea ecx, [esp + 0x24]
call fcn.004058b3
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push str.CSystemCommands::KillAllProcesses__Terminated_result
lea ecx, [esp + 0x20]
mov dword [esp + 0x3c], eax
call fcn.00404bd0
cmp dword [esp + 0x38], esi
mov dword [esp + 0x2b8], 6
sete al
movzx eax, al
push eax
lea eax, [esp + 0x20]
push eax
call fcn.00401927
or dword [esp + 0x2c0], 0xffffffff
pop ecx
pop ecx
push edi
push esi
lea ecx, [esp + 0x24]
call fcn.004058b3
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [esp + 0x74]
push eax
push dword [esp + 0x18]
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x403013
push dword [ebp + 0xc]
mov ecx, dword [esp + 0x1c]
call fcn.00402cce
lea ecx, [esp + 0x40]
mov dword [esp], str.CSystemCommands::KillAllProcesses__end.
call fcn.00404bd0
lea eax, [esp + 0x3c]
push eax
mov dword [esp + 0x2bc], 7
call fcn.004017f5
pop ecx
push edi
push esi
lea ecx, [esp + 0x44]
jmp 0x403184
push str.CSystemCommands::KillAllProcesses__not_valid_process_name.
lea ecx, [esp + 0x20]
call fcn.00404bd0
lea eax, [esp + 0x1c]
push eax
mov dword [esp + 0x2bc], edi
call fcn.004017f5
pop ecx
push edi
push 1
lea ecx, [esp + 0x24]
call fcn.004058b3
mov ecx, dword [esp + 0x2b0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x298]
xor ecx, esp
call fcn.0049f533
mov esp, ebp
pop ebp
ret