Function at 0x4c5523
Capabilities:
Get common file path
Print debug messages

Disassembly:
push 0x58
mov eax, 0x562ec5
call fcn.00505228
mov ebx, dword [ebp + 8]
mov ecx, ebx
mov dword [ebp - 0x64], ebx
push 0x576489
mov dword [ebp - 0x60], 1
call fcn.00452f2e
push 6
pop ecx
mov esi, str.Shell32.dll
and dword [ebp - 4], 0
lea edi, [ebp - 0x2c]
and dword [ebp - 0x5c], 0
rep movsd dword es:[edi], dword [esi]
push 0x58bd62
push 0x224
mov dword [ebp - 0x60], 1
movsw word es:[edi], word [esi]
mov dword [ebp - 0x3c], 0xa520a1a4
mov edi, 0x112
mov dword [ebp - 0x38], 0x4ff61780
mov dword [ebp - 0x34], 0x731618bd
mov dword [ebp - 0x30], 0x16afc543
call fcn.00505cd7
mov esi, eax
pop ecx
pop ecx
test esi, esi
je 0x4c5749
push 0x224
push 0
push esi
call fcn.005083f0
add esp, 0xc
push 0x104
push esi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
mov dword [ebp - 0x58], eax
test eax, eax
jne 0x4c55d0
push esi
call fcn.0050578f
jmp 0x4c5748
cmp eax, 0x104
jbe 0x4c5627
push esi
call fcn.0050578f
mov edi, dword [ebp - 0x58]
xor ecx, ecx
mov dword [esp], 0x58bd62
add edi, 0xe
push 2
pop edx
mov eax, edi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00505cd7
mov esi, eax
pop ecx
pop ecx
test esi, esi
je 0x4c5749
lea eax, [edi + edi]
push eax
push 0
push esi
call fcn.005083f0
add esp, 0xc
push edi
push esi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x4c55c5
xor eax, eax
mov dword [ebp - 0x58], eax
lea eax, [ebp - 0x2c]
push eax
push edi
push esi
call fcn.004c6eb3
test eax, eax
jne 0x4c5644
push esi
call fcn.004599c5
mov dword [ebp - 0x58], eax
push esi
call fcn.0050578f
xor eax, eax
lea edi, [ebp - 0x54]
stosd dword es:[edi], eax
pop ecx
push 7
xor ecx, ecx
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
and dword [ebp - 0x44], 0
pop eax
mov dword [ebp - 0x40], eax
mov word [ebp - 0x54], cx
mov esi, dword [ebp - 0x58]
mov dword [ebp - 4], 1
test esi, esi
je 0x4c5700
push 0x584ae4
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edi, eax
xor ecx, ecx
mov dword [ebp - 0x58], ecx
test edi, edi
je 0x4c56a4
lea eax, [ebp - 0x58]
push eax
push ecx
push ecx
lea eax, [ebp - 0x3c]
mov ecx, edi
push eax
call dword [0x57244c]
call edi
mov dword [ebp - 0x5c], eax
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp dword [ebp - 0x5c], 0
jne 0x4c56fd
push dword [ebp - 0x58]
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov eax, dword [ebp - 0x58]
test eax, eax
je 0x4c56f6
push eax
lea ecx, [ebp - 0x54]
call fcn.004ab2ee
lea eax, [ebp - 0x54]
push eax
lea eax, [ebp - 0x2c]
push eax
call fcn.004ccc9c
pop ecx
pop ecx
push 2
pop ecx
mov byte [ebp - 4], cl
mov ecx, ebx
push eax
call fcn.00461d44
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 1
call fcn.00456855
mov eax, dword [ebp - 0x58]
push eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
mov eax, dword [ebp - 0x40]
and dword [ebp - 0x60], 0
mov byte [ebp - 4], 0
cmp eax, 7
jbe 0x4c5749
mov ecx, dword [ebp - 0x54]
lea eax, [eax*2 + 2]
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x58], ecx
mov dword [ebp - 4], 3
cmp eax, 0x1000
jb 0x4c5740
lea eax, [ebp - 0x5c]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.00455e65
mov eax, dword [ebp - 0x5c]
pop ecx
pop ecx
mov ecx, dword [ebp - 0x58]
push eax
push ecx
call fcn.00504e76
pop ecx
pop ecx
mov eax, ebx
call fcn.005051d7
ret 4