Function at 0x406545
Capabilities:
Get file size
Hash data with md5
Read file on windows
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x8c
mov eax, dword [0x45c4d0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x84], edx
push ebx
push ebx
push 3
push ebx
push 1
push 0x80000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
mov dword [ebp - 0x8c], edi
cmp edi, 0xffffffff
je 0x406731
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
test esi, esi
je 0x40672a
cmp esi, 0x400000
jae 0x406607
push esi
call fcn.0042af74
pop ecx
push ebx
lea ecx, [ebp - 0x74]
mov dword [ebp - 0x78], eax
push ecx
push esi
push eax
push edi
mov dword [ebp - 0x74], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4065f9
cmp dword [ebp - 0x74], esi
jne 0x4065f9
mov ecx, dword [ebp - 0x78]
lea eax, [ebp - 0x14]
push eax
mov edx, esi
call fcn.004064e8
mov esi, dword [ebp - 0x84]
pop ecx
movzx eax, byte [ebp + ebx - 0x14]
push eax
push 0x44fb10
push 3
push esi
call fcn.0042bfcb
add esp, 0x10
add esi, 4
inc ebx
cmp ebx, 0x10
jl 0x4065da
push dword [ebp - 0x78]
call fcn.0042c27a
pop ecx
jmp 0x40672a
push ebx
push ebx
push ebx
push 2
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov ecx, eax
mov dword [ebp - 0x80], ecx
cmp ecx, 0xffffffff
je 0x406731
mov eax, esi
mov dword [ebp - 0x5c], ebx
shr eax, 0x10
mov edx, ebx
mov dword [ebp - 0x7c], eax
mov dword [ebp - 0x74], edx
mov dword [ebp - 0x60], ebx
mov dword [ebp - 0x70], 0x67452301
mov dword [ebp - 0x6c], 0xefcdab89
mov dword [ebp - 0x68], 0x98badcfe
mov dword [ebp - 0x64], 0x10325476
mov dword [ebp - 0x78], ebx
test eax, eax
je 0x4066ad
push 0x10000
push edx
push ebx
push 4
push ecx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x88], eax
test eax, eax
je 0x406721
push 0x10000
mov edx, eax
lea ecx, [ebp - 0x70]
call fcn.00405c81
pop ecx
push dword [ebp - 0x88]
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov edx, dword [ebp - 0x74]
mov eax, dword [ebp - 0x78]
add edx, 0x10000
mov ecx, dword [ebp - 0x80]
inc eax
mov dword [ebp - 0x74], edx
mov dword [ebp - 0x78], eax
cmp eax, dword [ebp - 0x7c]
jb 0x406658
test si, si
je 0x4066dd
push ebx
push edx
push ebx
push 4
push ecx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x7c], eax
test eax, eax
je 0x406721
sub esi, dword [ebp - 0x74]
lea ecx, [ebp - 0x70]
push esi
mov edx, eax
call fcn.00405c81
pop ecx
push dword [ebp - 0x7c]
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov byte [ebp - 0x14], bl
lea edi, [ebp - 0x13]
xor eax, eax
lea edx, [ebp - 0x70]
stosd dword es:[edi], eax
lea ecx, [ebp - 0x14]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
call fcn.00405d3b
mov esi, dword [ebp - 0x84]
movzx eax, byte [ebp + ebx - 0x14]
push eax
push 0x44fb10
push 3
push esi
call fcn.0042bfcb
add esp, 0x10
add esi, 4
inc ebx
cmp ebx, 0x10
jl 0x4066fc
mov edi, dword [ebp - 0x8c]
push dword [ebp - 0x80]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042b782
mov esp, ebp
pop ebp
ret