Function at 0x405ccf
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50c
push ebx
push esi
push edi
push str.EnumProcs_start
call fcn.00403cd9
pop ecx
lea eax, [ebp - 0xbc]
push eax
mov dword [ebp - 0xbc], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x405d0b
push str.GetVersionEx_failed__EnumProcs_end
jmp 0x405ffd
cmp dword [ebp - 0xac], 2
jne 0x405e2b
xor ebx, ebx
push str.Using_NT_method
mov dword [ebp - 4], ebx
mov dword [ebp - 0x10], 0xc800
call fcn.00403cd9
mov dword [esp], str.Process
call fcn.00405ab8
mov esi, eax
lea eax, [ebp - 0x28]
push esi
push 0x41993c
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x28]
push ebx
push eax
push 0x80000004
call fcn.004057eb
push esi
push eax
mov dword [ebp - 8], eax
call fcn.0040568e
mov esi, eax
add esp, 0x28
cmp esi, ebx
mov dword [ebp - 0x14], esi
je 0x405e0f
push str.ID_Process
call fcn.00405ab8
push eax
push esi
call fcn.00405bb7
add esp, 0xc
cmp eax, ebx
mov dword [ebp - 0xc], eax
je 0x405e0f
push esi
call fcn.00405c3a
mov edi, eax
pop ecx
cmp edi, ebx
je 0x405e0f
jmp 0x405da6
mov esi, dword [ebp - 0x14]
mov eax, dword [ebp - 4]
cmp eax, dword [esi + 0x28]
jge 0x405e0f
push dword [ebp - 0xc]
push edi
call fcn.00405c7f
mov esi, eax
pop ecx
pop ecx
cmp dword [esi], ebx
je 0x405dff
push edi
call fcn.00405cae
push eax
lea eax, [ebp - 0x2e8]
push str._S.exe
push eax
call fcn.0040c81c
lea eax, [ebp - 0x2e8]
push eax
push str.procname_s
call fcn.00403cd9
add esp, 0x18
lea eax, [ebp - 0x2e8]
push dword [ebp + 0xc]
push eax
push ebx
push dword [esi]
call dword [ebp + 8]
test eax, eax
je 0x405e1d
push edi
call fcn.00405c5b
inc dword [ebp - 4]
mov edi, eax
cmp edi, ebx
pop ecx
jne 0x405da3
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x405fd8
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x405ff1
cmp dword [ebp - 0xac], 1
jne 0x405ff8
push str.Using_Win9x_method
call fcn.00403cd9
xor ebx, ebx
pop ecx
cmp dword [0x41f320], ebx
jne 0x405f0a
push str.Kernel32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
cmp eax, ebx
mov dword [0x41f320], eax
je 0x406003
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.CreateToolhelp32Snapshot
push eax
call esi
push str.Process32First
mov dword [0x41f874], eax
push dword [0x41f320]
call esi
push str.Process32Next
mov dword [0x41f878], eax
push dword [0x41f320]
call esi
push str.Module32First
mov dword [0x41f86c], eax
push dword [0x41f320]
call esi
push str.Module32Next
mov dword [0x41f87c], eax
push dword [0x41f320]
call esi
cmp dword [0x41f86c], ebx
mov dword [0x41f870], eax
je 0x405ee8
cmp dword [0x41f878], ebx
je 0x405ee8
cmp eax, ebx
je 0x405ee8
cmp dword [0x41f87c], ebx
je 0x405ee8
cmp dword [0x41f874], ebx
jne 0x405f0a
push str.Error_loading_libraries
call fcn.00403cd9
pop ecx
push dword [0x41f320]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x41f320], ebx
jmp 0x406003
push ebx
push 2
call dword [0x41f874]
cmp eax, 0xffffffff
mov dword [ebp - 4], eax
jne 0x405f25
push str.CreateToolhelp32Snapshot_failed
jmp 0x405ffd
lea ecx, [ebp - 0x1e4]
mov esi, 0x128
push ecx
push eax
mov dword [ebp - 0x1e4], esi
call dword [0x41f878]
cmp eax, ebx
mov dword [ebp - 8], eax
je 0x405fcf
mov ecx, 0x88
xor eax, eax
lea edi, [ebp - 0x508]
mov dword [ebp - 0x50c], ebx
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x50c]
push 0x224
push eax
push dword [ebp - 0x1d4]
push dword [ebp - 0x1dc]
call fcn.0040558a
add esp, 0x10
test eax, eax
je 0x405fc6
lea eax, [ebp - 0x4ec]
push eax
push str.szModule_s
call fcn.00403cd9
pop ecx
lea eax, [ebp - 0x4ec]
pop ecx
push dword [ebp + 0xc]
push eax
push ebx
push dword [ebp - 0x1dc]
call dword [ebp + 8]
test eax, eax
je 0x405fe8
lea eax, [ebp - 0x1e4]
mov dword [ebp - 0x1e4], esi
push eax
push dword [ebp - 4]
call dword [0x41f86c]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], ebx
jne 0x405f49
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push str.EnumProcs_end
call fcn.00403cd9
pop ecx
push 1
pop eax
jmp 0x406005
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push str.EnumProcs_end
jmp 0x405ffd
push str.EnumProcs_end__Unknown_OS_
call fcn.00403cd9
pop ecx
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret 8