Function at 0x401790
Capabilities:
Link many functions at runtime
Terminate process

Disassembly:
sub esp, 0x2dc
mov eax, dword [esp + 0x2e4]
push ebx
push ebp
push esi
lea ecx, [esp + 0x12c]
push edi
push ecx
mov dword [eax], 0
mov dword [esp + 0x134], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x401ada
mov eax, dword [esp + 0x140]
cmp eax, 2
jne 0x4019ba
push str.PSAPI.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA_1]
mov edi, eax
test edi, edi
mov dword [esp + 0x10], edi
je 0x401ada
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress_1]
push str.EnumProcesses
push edi
call esi
push str.EnumProcessModules
push edi
mov ebx, eax
call esi
mov ebp, eax
push str.GetModuleFileNameExA
push edi
mov dword [esp + 0x28], ebp
call esi
test ebx, ebx
mov dword [esp + 0x24], eax
je 0x401898
test ebp, ebp
je 0x401898
test eax, eax
je 0x401898
mov esi, dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov eax, 0x400
mov dword [esp + 0x14], eax
xor ebp, ebp
test ebp, ebp
je 0x401857
push ebp
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov edx, dword [esp + 0x14]
lea eax, [edx + edx]
mov dword [esp + 0x14], eax
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call esi
mov ebp, eax
test ebp, ebp
je 0x401898
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x1c]
push eax
push ecx
push ebp
call ebx
test eax, eax
je 0x401888
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x1c]
cmp ecx, eax
jne 0x40189e
jmp 0x401838
push ebp
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
push edi
jmp 0x401ad4
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x18], 0
shr eax, 2
mov dword [esp + 0x1c], eax
je 0x401991
mov ebx, ebp
mov byte [esp + 0x2c], 0
mov edx, dword [ebx]
push edx
push 1
push 0x410
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x401924
lea eax, [esp + 0x14]
lea ecx, [esp + 0x28]
push eax
push 4
push ecx
push esi
call dword [esp + 0x30]
test eax, eax
je 0x401905
mov eax, dword [esp + 0x28]
lea edx, [esp + 0x2c]
push 0x104
push edx
push eax
push esi
call dword [esp + 0x34]
test eax, eax
jne 0x401905
mov byte [esp + 0x2c], al
mov ecx, dword [esp + 0x2f8]
lea edx, [esp + 0x2c]
push ecx
push edx
call dword [esp + 0x2f8]
test eax, eax
jne 0x401967
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea edi, [esp + 0x2c]
or ecx, 0xffffffff
xor eax, eax
push str.NTVDM.EXE
repne scasb al, byte es:[edi]
not ecx
lea eax, [esp + 0x30]
dec ecx
sub eax, 9
add ecx, eax
push ecx
call fcn.00411990
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
mov edi, dword [esp + 0x18]
add esp, 8
inc eax
add ebx, 4
cmp eax, ecx
mov dword [esp + 0x18], eax
jb 0x4018b9
jmp 0x401991
mov ecx, dword [esp + 0x2f4]
mov eax, dword [esp + 0x2fc]
test eax, eax
mov dword [ecx], 1
je 0x40198a
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
jmp 0x401991
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebp
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x2dc
ret 0x10
cmp eax, 1
jne 0x401ada
push str.Kernel32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA_1]
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x10], ebx
je 0x401ada
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress_1]
push str.CreateToolhelp32Snapshot
push ebx
call esi
push str.Process32First
push ebx
mov edi, eax
call esi
push str.Process32Next
push ebx
mov dword [esp + 0x20], eax
call esi
mov ebp, eax
test ebp, ebp
je 0x401ad3
mov eax, dword [esp + 0x18]
test eax, eax
je 0x401ad3
test edi, edi
je 0x401ad3
push 0
push 2
call edi
mov esi, eax
cmp esi, 0xffffffff
je 0x401ad3
lea edx, [esp + 0x1c4]
mov edi, 0x128
push edx
push esi
mov dword [esp + 0x1cc], edi
call dword [esp + 0x20]
test eax, eax
je 0x401ab6
mov ebx, dword [esp + 0x2f8]
lea eax, [esp + 0x1e8]
push ebx
push eax
call dword [esp + 0x2f8]
test eax, eax
jne 0x401a7f
lea ecx, [esp + 0x1c4]
mov dword [esp + 0x1c4], edi
push ecx
push esi
call ebp
test eax, eax
jne 0x401a53
jmp 0x401ab6
mov edx, dword [esp + 0x2f4]
mov eax, dword [esp + 0x2fc]
test eax, eax
mov dword [edx], 1
je 0x401ab6
mov eax, dword [esp + 0x1cc]
push eax
push 1
push 1
call dword [sym.imp.KERNEL32.dll_OpenProcess]
test eax, eax
je 0x401ab6
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov edi, dword [esp + 0x10]
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x2dc
ret 0x10
push ebx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x2dc
ret 0x10