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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4a0764
mov eax, dword fs:[0]
push eax
sub esp, 0x2a0
mov eax, dword [0x4de270]
xor eax, esp
mov dword [esp + 0x298], eax
push ebx
push esi
push edi
mov eax, dword [0x4de270]
xor eax, esp
push eax
lea eax, [esp + 0x2b0]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [esp + 0x14], ebx
test ebx, ebx
je 0x40a403
mov ecx, 0x4aec58
mov eax, ebx
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40a207
test dx, dx
je 0x40a203
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40a207
add eax, 4
add ecx, 4
test dx, dx
jne 0x40a1e1
xor eax, eax
jmp 0x40a20c
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x40a403
push str.CSystemCommands::KillAllProcesses__process_name
lea esi, [esp + 0x20]
call fcn.00404db2
xor edi, edi
inc edi
push ebx
lea esi, [esp + 0x5c]
mov dword [esp + 0x2bc], edi
call fcn.00404db2
lea ecx, [esp + 0x1c]
push ecx
mov ebx, eax
mov byte [esp + 0x2bc], 2
call fcn.00404975
pop ecx
xor ebx, ebx
push ebx
push edi
call fcn.00404f5a
or dword [esp + 0x2b8], 0xffffffff
push ebx
push edi
lea esi, [esp + 0x24]
call fcn.00404f5a
push str.CSystemCommands::KillAllProcesses__timeout
lea esi, [esp + 0x20]
call fcn.00404db2
push dword [ebp + 8]
mov ecx, esi
mov dword [esp + 0x2bc], 3
call fcn.00408b56
or dword [esp + 0x2bc], 0xffffffff
pop ecx
push ebx
push edi
call fcn.00404f5a
push ebx
call fcn.00481d95
pop ecx
push ebx
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
push 0x228
mov dword [esp + 0x14], eax
lea eax, [esp + 0x7c]
push ebx
push eax
call fcn.004864e0
add esp, 0xc
lea eax, [esp + 0x74]
push eax
push dword [esp + 0x14]
mov dword [esp + 0x7c], 0x22c
call sub.KERNEL32.dll_Process32FirstW
push dword [esp + 0x14]
lea eax, [esp + 0x9c]
push eax
call fcn.00482643
pop ecx
pop ecx
test eax, eax
jne 0x40a3bd
push str.CSystemCommands::KillAllProcesses__about_to_kill...
lea esi, [esp + 0x20]
call fcn.00404db2
mov dword [esp + 0x2b8], 4
call fcn.00404e64
or dword [esp + 0x2b8], 0xffffffff
push ebx
push edi
call fcn.00404f5a
push dword [esp + 0x7c]
push ebx
push 0x100001
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov dword [esp + 0x18], eax
cmp eax, ebx
je 0x40a3bd
push str.CSystemCommands::KillAllProcesses__open_process_succeeded.
lea esi, [esp + 0x20]
call fcn.00404db2
mov dword [esp + 0x2b8], 5
call fcn.00404e64
or dword [esp + 0x2b8], 0xffffffff
push ebx
push edi
call fcn.00404f5a
push ebx
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push str.CSystemCommands::KillAllProcesses__Terminated_result
lea esi, [esp + 0x20]
mov dword [esp + 0x3c], eax
call fcn.00404db2
cmp dword [esp + 0x38], edi
mov dword [esp + 0x2b8], 6
sete al
movzx eax, al
push eax
mov eax, esi
push eax
call fcn.00406bc9
or dword [esp + 0x2c0], 0xffffffff
pop ecx
pop ecx
push ebx
push edi
call fcn.00404f5a
push dword [esp + 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [esp + 0x74]
push eax
push dword [esp + 0x14]
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x40a2d6
push dword [ebp + 8]
mov ecx, dword [esp + 0x18]
call fcn.00409fd7
lea esi, [esp + 0x40]
mov dword [esp], str.CSystemCommands::KillAllProcesses__end.
call fcn.00404db2
mov dword [esp + 0x2b8], 7
call fcn.00404e64
push ebx
push edi
jmp 0x40a422
push str.CSystemCommands::KillAllProcesses__not_valid_process_name.
lea esi, [esp + 0x20]
call fcn.00404db2
and dword [esp + 0x2b8], 0
call fcn.00404e64
push 0
push 1
call fcn.00404f5a
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.004812cc
mov esp, ebp
pop ebp
ret