Function at 0x517040
Capabilities:
Enumerate process modules

Disassembly:
push 0xffffffffffffffff
push 0x5d0e27
mov eax, dword fs:[0]
push eax
sub esp, 0x2d0
mov eax, dword [0x65b4e4]
xor eax, esp
mov dword [esp + 0x2cc], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x65b4e4]
xor eax, esp
push eax
lea eax, [esp + 0x2e4]
mov dword fs:[0], eax
mov esi, dword [esp + 0x2f4]
push esi
push 8
mov dword [esp + 0x24], ecx
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov edi, eax
mov dword [esp + 0x14], edi
xor ebx, ebx
cmp edi, 0xffffffff
mov dword [esp + 0x2ec], ebx
jne 0x517187
push 1
push 2
lea ecx, [esp + 0x44]
call fcn.0040b160
mov byte [esp + 0x2ec], 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str._of_module_
push esi
lea eax, [esp + 0x48]
push str.CreateToolhelp32Snapshot__
push eax
call fcn.00409c80
add esp, 8
mov ecx, eax
call fcn.004024e0
push eax
call fcn.00409c80
add esp, 8
mov ecx, eax
call fcn.004024e0
lea ecx, [esp + 0x20]
push ecx
lea ecx, [esp + 0x40]
call fcn.00409610
mov esi, 0x10
cmp dword [eax + 0x18], esi
mov byte [esp + 0x2ec], 2
jb 0x517116
mov eax, dword [eax + 4]
jmp 0x517119
add eax, 4
push eax
push str.BaseLib::CModlesManage::Enumerate
push 0x22
push str..ywSMPpubProcessManage.cpp
push 0x5001
call fcn.00409980
mov ecx, eax
call fcn.004fa910
cmp dword [esp + 0x38], esi
jb 0x51714a
mov edx, dword [esp + 0x24]
push edx
call fcn.00594e98
add esp, 4
lea ecx, [esp + 0x88]
mov byte [esp + 0x2ec], bl
call fcn.00409f20
lea eax, [esp + 0x88]
push eax
mov dword [esp + 0x8c], vtable.std::ios_base.0
call fcn.005cccbe
add esp, 4
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x517396
lea ecx, [esp + 0xbc]
push ecx
push edi
mov dword [esp + 0xc4], 0x224
call sub.KERNEL32.dll_Module32First
test eax, eax
jne 0x517272
push 1
push 2
lea ecx, [esp + 0x44]
call fcn.0040b160
mov byte [esp + 0x2ec], 3
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [esp + 0x40]
push str.Module32First__
push edx
call fcn.00409c80
add esp, 8
mov ecx, eax
call fcn.004024e0
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x40]
call fcn.00409610
mov esi, 0x10
cmp dword [eax + 0x18], esi
mov byte [esp + 0x2ec], 4
jb 0x517202
mov eax, dword [eax + 4]
jmp 0x517205
add eax, 4
push eax
push str.BaseLib::CModlesManage::Enumerate
push 0x2b
push str..ywSMPpubProcessManage.cpp
push 0x5001
call fcn.00409980
mov ecx, eax
call fcn.004fa910
cmp dword [esp + 0x38], esi
jb 0x517236
mov ecx, dword [esp + 0x24]
push ecx
call fcn.00594e98
add esp, 4
lea ecx, [esp + 0x88]
mov byte [esp + 0x2ec], bl
call fcn.00409f20
lea edx, [esp + 0x88]
push edx
mov dword [esp + 0x8c], vtable.std::ios_base.0
call fcn.005cccbe
add esp, 4
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x517396
push 0x50
call fcn.00594e6d
add esp, 4
cmp eax, ebx
je 0x5172ad
mov ecx, 0xf
mov dword [eax + 0x18], ecx
mov dword [eax + 0x14], ebx
mov byte [eax + 4], bl
mov dword [eax + 0x34], ecx
mov dword [eax + 0x30], ebx
mov byte [eax + 0x20], bl
mov dword [eax + 0x38], ebx
mov dword [eax + 0x3c], ebx
mov dword [eax + 0x40], ebx
mov dword [eax + 0x44], ebx
mov dword [eax + 0x48], ebx
mov dword [eax + 0x4c], ebx
mov esi, eax
jmp 0x5172af
xor esi, esi
cmp esi, ebx
mov dword [esp + 0x18], esi
je 0x517374
lea eax, [esp + 0xdc]
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
cmp cl, bl
jne 0x5172c5
sub eax, edx
push eax
lea eax, [esp + 0xe0]
push eax
mov ecx, esi
call fcn.004098b0
mov ecx, dword [esp + 0xc8]
mov dword [esi + 0x3c], ecx
mov edx, dword [esp + 0xd0]
mov dword [esi + 0x44], edx
mov eax, dword [esp + 0xd4]
mov dword [esi + 0x48], eax
mov ecx, dword [esp + 0xcc]
mov dword [esi + 0x40], ecx
mov edx, dword [esp + 0xc4]
mov dword [esi + 0x38], edx
mov eax, dword [esp + 0xd8]
mov dword [esi + 0x4c], eax
lea eax, [esp + 0x1dc]
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
cmp cl, bl
jne 0x517326
sub eax, edx
push eax
lea ecx, [esp + 0x1e0]
push ecx
lea ecx, [esi + 0x1c]
call fcn.004098b0
mov esi, dword [esp + 0x1c]
mov edi, dword [esi + 8]
mov eax, dword [edi + 4]
add esi, 4
lea edx, [esp + 0x18]
push edx
push eax
push edi
mov ecx, esi
call fcn.0050b950
push 1
mov ecx, esi
mov ebp, eax
call fcn.00516950
mov dword [edi + 4], ebp
mov ecx, dword [ebp + 4]
mov edi, dword [esp + 0x14]
mov dword [ecx], ebp
lea edx, [esp + 0xbc]
push edx
push edi
call sub.KERNEL32.dll_Module32Next
test eax, eax
jne 0x517272
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
mov ecx, dword [esp + 0x2e4]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x2cc]
xor ecx, esp
call fcn.005b0968
add esp, 0x2dc
ret 4