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

Disassembly:
push 0xffffffffffffffff
push 0x4a5f21
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x244
mov eax, dword [0x4d1788]
push ebx
push ebp
push esi
mov dword [esp + 0x24c], eax
push edi
lea ecx, [esp + 0x264]
mov dword [esp + 0x25c], 1
call fcn.0040a8f0
lea ecx, [esp + 0x268]
call fcn.0040a8f0
lea ecx, [esp + 0x18]
call fcn.0044ea70
mov edi, eax
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], 0
push 0
push 2
mov byte [esp + 0x264], 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov ebp, eax
test ebp, ebp
je 0x40ab48
lea eax, [esp + 0x24]
push eax
push ebp
mov dword [esp + 0x2c], 0x22c
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
je 0x40ab41
mov bl, 3
lea ecx, [ecx]
lea ecx, [esp + 0x48]
push ecx
lea ecx, [esp + 0x18]
call fcn.00404200
mov ecx, dword [esp + 0x268]
test ecx, ecx
mov byte [esp + 0x25c], bl
je 0x40ab06
mov eax, dword [esp + 0x14]
mov edx, dword [eax - 0xc]
test edx, edx
jl 0x40ab06
push ecx
push eax
call fcn.0047e729
add esp, 8
test eax, eax
je 0x40ab06
sub eax, dword [esp + 0x14]
sar eax, 1
cmp eax, 0xffffffff
je 0x40ab06
mov eax, dword [edi + 4]
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x2c]
add edi, 4
push edx
push eax
push ecx
lea ecx, [esp + 0x24]
call fcn.0040be70
push 1
lea ecx, [esp + 0x1c]
mov esi, eax
call fcn.0040a950
mov dword [edi], esi
mov eax, dword [esi + 4]
mov edi, dword [esp + 0x1c]
mov dword [eax], esi
lea edx, [esp + 0x24]
push edx
push ebp
call sub.KERNEL32.dll_Process32NextW
mov esi, eax
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x25c], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40ab39
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
test esi, esi
jne 0x40aa90
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call fcn.004951e5
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
lea esi, [eax + 0x10]
mov dword [esp + 0x10], esi
mov ebx, dword [edi]
cmp ebx, edi
mov byte [esp + 0x25c], 4
je 0x40ac82
lea ecx, [ecx]
mov eax, dword [ebx + 8]
push eax
push 0
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov ebp, eax
test ebp, ebp
je 0x40ac78
mov eax, dword [esi - 4]
mov ecx, 1
sub ecx, eax
mov eax, dword [esi - 8]
sub eax, 0x104
or eax, ecx
jge 0x40abb3
push 0x104
lea ecx, [esp + 0x14]
call fcn.00401590
mov esi, dword [esp + 0x10]
push 0x104
push esi
push 0
push ebp
call sub.PSAPI.DLL_GetModuleFileNameExW
test eax, eax
je 0x40ad44
test esi, esi
jne 0x40abd1
xor eax, eax
jmp 0x40abe2
push esi
call fcn.0047e9ef
add esp, 4
test eax, eax
jl 0x40ad6c
cmp eax, dword [esi - 8]
jg 0x40ad6c
mov dword [esi - 0xc], eax
mov word [esi + eax*2], 0
mov eax, dword [esi - 4]
mov edi, dword [esi - 0xc]
mov ecx, 1
sub ecx, eax
mov eax, dword [esi - 8]
sub eax, edi
or eax, ecx
jge 0x40ac18
push edi
lea ecx, [esp + 0x14]
call fcn.00401590
mov esi, dword [esp + 0x10]
push esi
call fcn.0047f957
add esp, 4
test edi, edi
jl 0x40ad6c
cmp edi, dword [esi - 8]
jg 0x40ad6c
mov eax, dword [esp + 0x264]
test eax, eax
mov dword [esi - 0xc], edi
mov word [esi + edi*2], 0
je 0x40ac6d
mov ecx, dword [esi - 0xc]
test ecx, ecx
jl 0x40ac6d
push eax
push esi
call fcn.0047e729
add esp, 8
test eax, eax
je 0x40ac6d
sub eax, esi
sar eax, 1
cmp eax, 0xffffffff
je 0x40ac6d
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov edi, dword [esp + 0x1c]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [ebx]
cmp ebx, edi
jne 0x40ab70
lea eax, [esi - 0x10]
mov byte [esp + 0x25c], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40aca4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [edi]
cmp eax, edi
mov dword [edi], edi
mov dword [edi + 4], edi
je 0x40acc1
nop
mov esi, dword [eax]
push eax
call fcn.004955bc
add esp, 4
cmp esi, edi
mov eax, esi
jne 0x40acb0
push edi
call fcn.004955bc
mov eax, dword [esp + 0x268]
add eax, 0xfffffff0
add esp, 4
mov byte [esp + 0x25c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40acf3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x268]
add eax, 0xfffffff0
mov dword [esp + 0x25c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40ad1f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ecx, dword [esp + 0x254]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x244]
pop ebx
call fcn.0047e6cd
add esp, 0x250
ret
test esi, esi
jne 0x40ad4c
xor eax, eax
jmp 0x40ad59
push esi
call fcn.0047e9ef
add esp, 4
test eax, eax
jl 0x40ad6c
cmp eax, dword [esi - 8]
jg 0x40ad6c
mov dword [esi - 0xc], eax
mov word [esi + eax*2], 0
jmp 0x40ac71
push 0x80070057
call fcn.00401100
int3