Function at 0x4c5654
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff21c
push ebx
xor ecx, ecx
mov dword [ebp - 0xde4], ecx
mov dword [ebp - 0xdb0], ecx
mov dword [ebp - 4], ecx
mov dword [ebp - 8], ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0x14], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x4c5a55
push dword fs:[eax]
mov dword fs:[eax], esp
cmp dword [0x663654], 1
jne 0x4c56fd
push 0x4c5a64
call fcn.0040e070
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x663654], eax
push 0x4c5a80
call fcn.0040e84c
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x77a6d4], eax
push 0x4c5a90
call fcn.0040e84c
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x77a6d8], eax
push 0x4c5aa0
call fcn.0040e84c
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x77a6dc], eax
push 0x4c5ab4
call fcn.0040e84c
push eax
call sub.kernel32.dll_GetProcAddress_1
mov dword [0x77a6e0], eax
mov eax, dword [ebp - 0x14]
call fcn.00405dd0
cmp dword [0x77a6d4], 0
je 0x4c5a24
lea eax, [ebp - 0x9e]
xor ecx, ecx
mov edx, 0x42
call fcn.0040d87c
lea eax, [ebp - 0x9e]
push eax
push 0
lea eax, [ebp - 0x18]
push eax
call dword [0x77a6d4]
push eax
call sub.kernel32.dll_SetLastError
call sub.kernel32.dll_GetLastError_1
test eax, eax
jne 0x4c5a24
xor eax, eax
push ebp
push 0x4c5a1d
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, ebx
call fcn.004067b8
mov dword [ebp - 0x1c], eax
lea ebx, [ebp - 0x1c]
push 0
push 0
push 0
push 0
push ebx
push 1
mov eax, dword [ebp - 0x18]
push eax
call dword [0x77a6dc]
push eax
call sub.kernel32.dll_SetLastError
call sub.kernel32.dll_GetLastError_1
test eax, eax
je 0x4c5793
call fcn.004057d4
jmp 0x4c5a24
mov dword [ebp - 0x2c], 5
lea eax, [ebp - 0xdac]
xor ecx, ecx
mov edx, 0xd0c
call fcn.0040d87c
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0xdac]
push eax
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x28]
push eax
mov eax, dword [ebp - 0x18]
push eax
call dword [0x77a6e0]
push eax
call sub.kernel32.dll_SetLastError
call sub.kernel32.dll_GetLastError_1
test eax, eax
jne 0x4c57de
cmp dword [ebp - 0x2c], 0
jne 0x4c57e8
call fcn.004057d4
jmp 0x4c5a24
mov eax, dword [ebp - 0x2c]
dec eax
test eax, eax
jl 0x4c5a05
inc eax
mov dword [ebp - 0x58], eax
lea eax, [ebp - 0xdac]
mov dword [ebp - 0x5c], eax
call sub.kernel32.dll_GetCurrentProcessId
mov edx, dword [ebp - 0x5c]
cmp eax, dword [edx]
jne 0x4c581f
mov eax, dword [ebp - 0x14]
mov edx, 0x4c5ac8
call fcn.00405e24
jmp 0x4c5a05
lea eax, [ebp - 8]
call fcn.00405dd0
mov eax, dword [ebp - 0x5c]
mov eax, dword [eax]
push eax
push 0
push 0x1000
call sub.kernel32.dll_OpenProcess
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
je 0x4c58f1
xor eax, eax
push ebp
push 0x4c58ea
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x50]
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x38]
push eax
mov eax, dword [ebp - 0x30]
push eax
call sub.kernel32.dll_GetProcessTimes
test eax, eax
je 0x4c58d3
lea eax, [ebp - 0x38]
push eax
mov eax, dword [ebp - 0x5c]
add eax, 4
push eax
call sub.kernel32.dll_CompareFileTime
test eax, eax
jne 0x4c58d3
mov dword [ebp - 0x54], 0x104
lea eax, [ebp - 4]
mov edx, dword [ebp - 0x54]
call fcn.0040650c
lea eax, [ebp - 0x54]
push eax
mov eax, dword [ebp - 4]
call fcn.0040627c
push eax
push 0
mov eax, dword [ebp - 0x30]
push eax
call dword [0x663654]
test eax, eax
je 0x4c58d3
cmp dword [ebp - 0x54], 0x104
jg 0x4c58d3
lea eax, [ebp - 4]
mov edx, dword [ebp - 0x54]
call fcn.0040650c
lea eax, [ebp - 8]
mov edx, dword [ebp - 4]
call fcn.00405e68
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4c58f1
mov eax, dword [ebp - 0x30]
push eax
call sub.kernel32.dll_CloseHandle_1
ret
lea eax, [ebp - 0xc]
mov edx, dword [ebp - 0x5c]
add edx, 0xc
mov ecx, pe_nt_image_headers32
call fcn.00406058
lea eax, [ebp - 0x10]
mov edx, dword [ebp - 0x5c]
add edx, 0x20c
mov ecx, 0x40
call fcn.00406058
cmp dword [ebp - 0x10], 0
je 0x4c5977
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp - 0x10]
call fcn.00406214
je 0x4c5977
lea eax, [ebp - 0xdb0]
push eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0xdc0], eax
mov byte [ebp - 0xdbc], 0xb
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0xdb8], eax
mov byte [ebp - 0xdb4], 0xb
lea edx, [ebp - 0xdc0]
mov ecx, 1
mov eax, 0x4c5af4
call fcn.0044b944
mov edx, dword [ebp - 0xdb0]
lea eax, [ebp - 0xc]
call fcn.00405e68
mov eax, dword [ebp - 0x14]
push eax
lea edx, [ebp - 0xde4]
mov eax, dword [ebp - 0x5c]
mov eax, dword [eax + 0x28c]
call fcn.004c5530
mov eax, dword [ebp - 0xde4]
mov dword [ebp - 0xde0], eax
mov byte [ebp - 0xddc], 0xb
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0xdd8], eax
mov byte [ebp - 0xdd4], 0xb
mov eax, dword [ebp - 0x5c]
mov eax, dword [eax]
mov dword [ebp - 0xdd0], eax
mov byte [ebp - 0xdcc], 0
mov eax, dword [ebp - 8]
mov dword [ebp - 0xdc8], eax
mov byte [ebp - 0xdc4], 0xb
lea edx, [ebp - 0xde0]
mov ecx, 3
mov eax, 0x4c5b04
call fcn.0044b944
mov eax, dword [ebp - 0x5c]
cmp dword [eax + 0x28c], 1
je 0x4c5a05
add dword [ebp - 0x5c], 0x29c
dec dword [ebp - 0x58]
jne 0x4c5801
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4c5a24
mov eax, dword [ebp - 0x18]
push eax
call dword [0x77a6d8]
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4c5a5c
lea eax, [ebp - 0xde4]
call fcn.00405dd0
lea eax, [ebp - 0xdb0]
call fcn.00405dd0
lea eax, [ebp - 0x10]
mov edx, 4
call fcn.00405df4
ret