Function at 0x4ca530
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x58f778
mov eax, dword fs:[0]
push eax
sub esp, 0xc8
mov eax, dword [0x62f018]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 0x10]
mov ecx, 0x6355a1
mov ebx, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0xd4], edi
call fcn.00561ea5
mov ecx, esi
call fcn.004cb480
mov byte [edi], 0
mov ecx, ebx
cmp dword [ebx + 0x14], 8
jb 0x4ca58b
mov ecx, dword [ebx]
push ecx
push 0x80
push 3
push ecx
push 0
mov edx, SysReAllocString
call fcn.004901f0
mov edi, eax
add esp, 0x14
cmp edi, 0xffffffff
je 0x4caa23
test edi, edi
je 0x4caa23
push 0
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
xorps xmm0, xmm0
mov dword [ebp - 0x20], 0
movq qword [ebp - 0x28], xmm0
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 4], 0
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x38]
movlpd qword [ebp - 0xd0], xmm0
push eax
lea eax, [ebp - 0xd0]
movlpd qword [ebp - 0x38], xmm0
push eax
push ebx
movlpd qword [ebp - 0x30], xmm0
call fcn.004cabe0
test al, al
je 0x4ca694
mov ebx, dword [ebp - 0xd0]
mov ecx, ebx
mov eax, dword [ebp - 0xcc]
add ecx, 0xffffffff
adc eax, 0xffffffff
test eax, eax
ja 0x4ca694
jb 0x4ca63b
cmp ecx, 0x4ffffe
ja 0x4ca694
lea eax, [ebp - 0xc5]
mov byte [ebp - 0xc5], 0
push eax
lea ecx, [ebp - 0x28]
push ecx
push ebx
call fcn.00428c10
push 0
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 0
push eax
push ebx
push dword [ebp - 0x28]
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [ebp - 0x2c]
xor ecx, ecx
cmp ecx, dword [ebp - 0xcc]
ja 0x4ca694
jb 0x4ca67e
cmp eax, ebx
jae 0x4ca694
mov byte [ebp - 0xc5], cl
lea ecx, [ebp - 0xc5]
push ecx
push eax
lea ecx, [ebp - 0x28]
call fcn.00427bb0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x28]
cmp eax, dword [ebp - 0x24]
jne 0x4ca6aa
xor bl, bl
jmp 0x4caa10
xorps xmm0, xmm0
mov dword [ebp - 0x34], 0
movq qword [ebp - 0x3c], xmm0
mov dword [ebp - 0x3c], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0xc4]
call fcn.0051b340
mov byte [ebp - 4], 2
lea edx, [ebp - 0x3c]
mov ecx, dword [ebp - 0x24]
mov eax, dword [ebp - 0x28]
sub ecx, eax
push edx
push ecx
push eax
lea ecx, [ebp - 0xc4]
call fcn.0051b5d0
test al, al
je 0x4ca71b
mov eax, dword [ebp - 0x38]
xor edx, edx
mov ebx, dword [ebp - 0x3c]
mov ecx, 0x3e8
sub eax, ebx
div ecx
mov edi, eax
mov dword [ebp - 0xcc], edi
test edx, edx
je 0x4ca72b
mov eax, dword [ebp - 0xd4]
xor bl, bl
mov byte [eax], 1
jmp 0x4caa04
test edi, edi
jne 0x4ca736
mov bl, 1
jmp 0x4caa04
xorps xmm0, xmm0
mov dword [ebp - 0x14], 0
movq qword [ebp - 0x1c], xmm0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
mov byte [ebp - 4], 3
lea eax, [ebp - 0x1c]
push eax
push edi
mov ecx, eax
call fcn.004cced0
imul eax, edi, 0x3e8
push eax
push ebx
push dword [ebp - 0x1c]
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
lea ecx, [ebp - 0x1c]
xor ebx, ebx
call fcn.004caf40
test eax, eax
je 0x4ca7cf
xor edi, edi
nop dword [eax]
mov eax, dword [ebp - 0x1c]
cmp dword [eax + edi], 0x23ab45db
jne 0x4ca7f7
xor ecx, ecx
inc ebx
mov word [eax + edi + 0x282], cx
mov word [eax + edi + 0x382], cx
mov word [eax + edi + 0x3ca], cx
lea ecx, [ebp - 0x1c]
add edi, 0x3e8
call fcn.004caf40
cmp ebx, eax
jb 0x4ca790
mov edi, dword [ebp - 0xcc]
mov ecx, dword [esi + 8]
mov eax, 0x4ec4ec4f
sub ecx, dword [esi]
imul ecx
sar edx, 5
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp edi, eax
jbe 0x4ca80f
cmp edi, 0x2762762
ja 0x4caa43
jmp 0x4ca807
mov eax, dword [ebp - 0xd4]
xor bl, bl
mov byte [eax], 1
jmp 0x4ca99e
push edi
mov ecx, esi
call fcn.004cc040
lea ecx, [ebp - 0xa4]
call fcn.004c8790
mov byte [ebp - 4], 4
xor ecx, ecx
mov edi, dword [ebp - 0x1c]
mov eax, 0x10624dd3
mov dword [ebp - 0x2c], ecx
mov ecx, dword [ebp - 0x18]
sub ecx, edi
imul ecx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x4ca984
xor ebx, ebx
mov dword [ebp - 0xcc], ebx
nop word [eax + eax]
lea edx, [ebx + 4]
add edx, edi
mov ecx, edx
lea ebx, [ecx + 2]
nop word [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4ca860
sub ecx, ebx
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0xa4]
call fcn.00404640
mov ebx, dword [ebp - 0xcc]
lea edx, [ebx + 0x284]
add edx, edi
mov ecx, edx
lea eax, [ecx + 2]
mov dword [ebp - 0xcc], eax
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4ca895
sub ecx, dword [ebp - 0xcc]
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x8c]
call fcn.00404640
mov eax, dword [edi + ebx + 0x3cc]
lea edx, [ebx + 0x384]
mov dword [ebp - 0x5c], eax
add edx, edi
mov eax, dword [edi + ebx + 0x3d0]
mov dword [ebp - 0x58], eax
mov eax, dword [edi + ebx + 0x3d4]
mov dword [ebp - 0x54], eax
mov eax, dword [edi + ebx + 0x3d8]
mov dword [ebp - 0x50], eax
mov eax, dword [edi + ebx + 0x3dc]
mov dword [ebp - 0x4c], eax
mov eax, dword [edi + ebx + 0x3e0]
mov dword [ebp - 0x48], eax
mov eax, edx
lea ecx, [eax + 2]
mov dword [ebp - 0xcc], ecx
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4ca904
sub eax, dword [ebp - 0xcc]
lea ecx, [ebp - 0x74]
sar eax, 1
push eax
push edx
call fcn.00404640
mov eax, dword [edi + ebx + 0x3e4]
lea ecx, [ebp - 0xa4]
mov dword [ebp - 0x44], eax
mov eax, dword [esi + 4]
mov byte [ebp - 0x40], 0
push ecx
cmp dword [esi + 8], eax
je 0x4ca94b
mov ecx, eax
call fcn.004c9490
add dword [esi + 4], 0x68
jmp 0x4ca953
push eax
mov ecx, esi
call fcn.004cd3f0
mov ecx, dword [ebp - 0x18]
mov eax, 0x10624dd3
mov edi, dword [ebp - 0x1c]
add ebx, 0x3e8
inc dword [ebp - 0x2c]
sub ecx, edi
imul ecx
mov dword [ebp - 0xcc], ebx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp dword [ebp - 0x2c], eax
jb 0x4ca850
mov eax, dword [ebp - 0xd4]
mov bl, 1
mov byte [eax], 0
mov byte [ebp - 4], 3
lea ecx, [ebp - 0xa4]
call fcn.004c93e0
mov byte [ebp - 4], 2
mov esi, dword [ebp - 0x1c]
test esi, esi
je 0x4caa04
mov ecx, dword [ebp - 0x14]
mov eax, 0x10624dd3
sub ecx, esi
imul ecx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add eax, edx
imul ecx, eax, 0x3e8
mov eax, esi
cmp ecx, 0x1000
jb 0x4ca9e5
mov esi, dword [esi - 4]
add ecx, 0x23
sub eax, esi
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x4ca9e5
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push esi
call fcn.0052f594
add esp, 8
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x3c]
call fcn.00428280
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.00428280
mov al, bl
jmp 0x4caa25
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0052f553
mov esp, ebp
pop ebp
ret 0xc
call fcn.004cbe70
int3