Function at 0x472020
Capabilities:
Get file size
Read file on windows
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x168
mov eax, dword [0x589758]
xor eax, esp
mov dword [esp + 0x164], eax
mov eax, dword [esp + 0x174]
push ebx
mov ebx, dword [esp + 0x17c]
push ebp
mov ebp, dword [esp + 0x174]
push esi
push edi
xor edi, edi
push 0x3f
mov dword [esp + 0x18], ecx
lea ecx, [esp + 0x35]
push edi
push ecx
mov dword [esp + 0x38], ebp
mov dword [esp + 0x24], eax
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x34], edi
mov byte [esp + 0x3c], 0
call fcn.004f67e0
add esp, 0xc
push 0x104
lea edx, [esp + 0x74]
push edx
push edi
mov dword [esp + 0x28], 0xffffffff
mov dword [esp + 0x30], edi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [esp + 0x70]
push 0x5c
push eax
call fcn.004f6860
add esp, 8
cmp eax, edi
jne 0x4720e0
mov ecx, dword [str.usermonfile.dat]
mov edx, dword [0x5468cc]
mov eax, dword [0x5468d0]
mov dword [esp + 0x70], ecx
mov ecx, dword [0x5468d4]
mov dword [esp + 0x74], edx
mov dx, word [0x5468d8]
mov dword [esp + 0x78], eax
mov dword [esp + 0x7c], ecx
mov word [esp + 0x80], dx
jmp 0x47211e
mov byte [eax], 0
lea eax, [esp + 0x70]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x4720e8
mov ecx, dword [str.usermonfile.dat]
mov edx, dword [0x5468cc]
mov dword [eax], ecx
mov ecx, dword [0x5468d0]
mov dword [eax + 4], edx
mov edx, dword [0x5468d4]
mov dword [eax + 8], ecx
mov cx, word [0x5468d8]
mov dword [eax + 0xc], edx
mov word [eax + 0x10], cx
push edi
push 0x80
push 3
push edi
push 1
push SysReAllocStringLen
lea edx, [esp + 0x88]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4721b5
cmp ebx, edi
je 0x4721cb
cmp byte [ebp + 8], 0
mov esi, ebp
je 0x472164
mov eax, dword [esi + 4]
lea edi, [edi + eax + 9]
cmp byte [edi + ebp + 8], 0
lea esi, [edi + ebp]
jne 0x472153
mov ecx, dword [esp + 0x14]
push ebx
call fcn.00472000
test eax, eax
je 0x4721a1
mov eax, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x472177
mov ecx, dword [esp + 0x18c]
sub eax, edx
mov dword [esi], ecx
mov dword [esi + 4], eax
add esi, 8
mov ecx, ebx
sub esi, ebx
mov dl, byte [ecx]
mov byte [esi + ecx], dl
inc ecx
test dl, dl
jne 0x472193
lea edi, [edi + eax + 9]
cmp edi, dword [esp + 0x180]
ja 0x4721cb
mov edx, dword [esp + 0x18]
mov dword [edx], edi
jmp 0x472391
push edi
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp edi, 9
ja 0x4721d2
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x472396
lea ebp, [edi + 0x10000]
push ebp
call fcn.00496dbd
mov ebx, eax
add esp, 4
mov dword [esp + 0x10], ebx
test ebx, ebx
je 0x4721c4
push ebp
push 0
push ebx
call fcn.004f67e0
add esp, 0xc
push 0
lea eax, [esp + 0x2c]
push eax
push edi
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebp, ebp
jne 0x472224
push ebx
call fcn.00496dc8
add esp, 4
xor eax, eax
jmp 0x472396
lea ebp, [edi - 0x20]
push ebp
add ebx, 0x20
lea ecx, [esp + 0x34]
push ebx
push ecx
call fcn.0044c2a0
mov eax, dword [esp + 0x1c]
lea edx, [esp + 0x3c]
add esp, 0xc
mov ecx, 0x20
sub edx, eax
mov esi, dword [edx + eax]
cmp esi, dword [eax]
jne 0x472284
sub ecx, 4
add eax, 4
cmp ecx, 4
jae 0x472248
lea esi, [edi + edi + 0x10000]
push esi
call fcn.00496dbd
mov edi, eax
add esp, 4
test edi, edi
jne 0x472298
mov eax, dword [esp + 0x10]
push eax
call fcn.00496dc8
add esp, 4
xor eax, eax
jmp 0x472396
mov edx, dword [esp + 0x10]
push edx
call fcn.00496dc8
add esp, 4
xor eax, eax
jmp 0x472396
push esi
push 0
push edi
call fcn.004f67e0
push ebp
push ebx
lea ecx, [esp + 0x30]
push ecx
push edi
call fcn.00481120
add esp, 0x1c
cmp dword [esp + 0x1c], 0xffffffff
jne 0x4722d2
push edi
call fcn.00496dc8
mov edx, dword [esp + 0x14]
push edx
call fcn.00496dc8
add esp, 8
xor eax, eax
jmp 0x472396
lea eax, [edi + 8]
xor ebp, ebp
cmp byte [eax], 0
mov esi, edi
je 0x47231a
mov edi, edi
mov ebx, dword [esp + 0x20]
test ebx, ebx
je 0x4722fe
push eax
push ebx
call fcn.00509315
add esp, 8
test eax, eax
jne 0x4722fe
mov dword [esp + 0x24], 1
mov eax, dword [esi + 4]
lea ebp, [eax + ebp + 9]
lea esi, [edi + ebp]
cmp byte [esi + 8], 0
lea eax, [esi + 8]
jne 0x4722e0
cmp dword [esp + 0x24], 0
jne 0x47235f
jmp 0x47231e
mov ebx, dword [esp + 0x20]
test ebx, ebx
je 0x47235f
mov ecx, dword [esp + 0x14]
push ebx
call fcn.00472000
test eax, eax
je 0x47235f
mov eax, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x472335
mov ecx, dword [esp + 0x18c]
sub eax, edx
mov dword [esi], ecx
mov dword [esi + 4], eax
add esi, 8
mov ecx, ebx
sub esi, ebx
mov dl, byte [ecx]
mov byte [esi + ecx], dl
inc ecx
test dl, dl
jne 0x472351
lea ebp, [eax + ebp + 9]
cmp ebp, dword [esp + 0x180]
ja 0x4722b8
mov eax, dword [esp + 0x2c]
push ebp
push edi
push eax
call fcn.004f7b80
mov ecx, dword [esp + 0x24]
push edi
mov dword [ecx], ebp
call fcn.00496dc8
mov edx, dword [esp + 0x20]
push edx
call fcn.00496dc8
add esp, 0x14
mov eax, 1
mov ecx, dword [esp + 0x174]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004f6592
add esp, 0x168
ret 0x14