Function at 0x51f9f0
Capabilities:
Get file size

Disassembly:
push 0xffffffffffffffff
push 0x58ed28
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x5c
push ebx
mov eax, dword [esp + 0x70]
push ebp
push esi
push edi
push 0
push 0x8000080
push 4
push 0
push 0
push 0xc0000000
mov dword [esp + 0x34], ecx
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x14], ebp
je 0x51fb7e
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
test ebx, ebx
jne 0x51fa57
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x51fc37
push 0
push ebx
push 0
push 4
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov esi, eax
test esi, esi
jne 0x51fa8b
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor al, al
pop ebx
mov ecx, dword [esp + 0x5c]
mov dword fs:[0], ecx
add esp, 0x68
ret 4
push 0
push 0
push 0
push 2
push esi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov edi, eax
test edi, edi
jne 0x51fac3
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push ebp
call esi
pop edi
pop esi
pop ebp
xor al, al
pop ebx
mov ecx, dword [esp + 0x5c]
mov dword fs:[0], ecx
add esp, 0x68
ret 4
lea ecx, [esp + 0x28]
call fcn.004f7380
lea ecx, [esp + 0x7c]
lea edx, [esp + 0x20]
push ecx
push 1
push edx
lea ecx, [esp + 0x34]
mov dword [esp + 0x80], 0
mov dword [esp + 0x30], edi
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x88], ebx
call fcn.004f7e50
push edi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
test ebx, ebx
jne 0x51fb1c
lea ecx, [esp + 0x28]
call fcn.004f7bf0
jmp 0x51fb6a
mov eax, dword [esp + 0x7c]
push 0
push eax
push 0
push 4
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x18], ebx
jne 0x51fb45
lea ecx, [esp + 0x28]
call fcn.004f7bf0
jmp 0x51fb6a
push 0
push 0
push 0
push 2
push ebx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov edi, eax
test edi, edi
mov dword [esp + 0x10], edi
jne 0x51fb95
lea ecx, [esp + 0x28]
call fcn.004f7bf0
push ebx
call esi
push ebp
call esi
lea ecx, [esp + 0x28]
mov dword [esp + 0x74], 0xffffffff
call fcn.004f73c0
pop edi
pop esi
pop ebp
xor al, al
pop ebx
mov ecx, dword [esp + 0x5c]
mov dword fs:[0], ecx
add esp, 0x68
ret 4
mov ecx, dword [esp + 0x30]
xor edx, edx
xor eax, eax
test ecx, ecx
jbe 0x51fbf8
mov ecx, dword [esp + 0x7c]
jmp 0x51fbab
mov edi, dword [esp + 0x10]
mov esi, dword [esp + 0x2c]
mov ebx, dword [esi + eax*8]
lea ebp, [ebx + edx]
cmp ebp, ecx
jbe 0x51fbbd
sub ecx, edx
mov ebx, ecx
mov esi, dword [esi + eax*8 + 4]
mov ecx, ebx
mov ebp, ecx
add edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
add edx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x7c]
cmp ecx, edx
jbe 0x51fbe6
mov esi, dword [esp + 0x30]
inc eax
cmp eax, esi
jb 0x51fba7
mov ebp, dword [esp + 0x14]
mov ebx, dword [esp + 0x18]
mov edi, dword [esp + 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push ebx
call esi
lea ecx, [esp + 0x28]
call fcn.004f7bf0
push ebp
call esi
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x7c]
mov dword [esp + 0x74], 0xffffffff
mov dword [eax + 0x398], ecx
lea ecx, [esp + 0x28]
mov dword [eax + 0x39c], 0
call fcn.004f73c0
mov ecx, dword [esp + 0x6c]
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
mov dword fs:[0], ecx
add esp, 0x68
ret 4