Function at 0x4baf10
Capabilities:
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x531bce
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x20
mov eax, dword [esp + 0x30]
push ebx
push ebp
push esi
push edi
mov esi, ecx
push eax
mov dword [esp + 0x20], esi
call fcn.004ba0e0
push fcn.004b9430
push 0x4bb180
push 0x20
lea ecx, [esi + 0x14]
xor ebx, ebx
push 8
push ecx
mov dword [esp + 0x4c], ebx
call fcn.0051c73f
lea edi, [esi + 0x114]
mov byte [esp + 0x38], 1
mov eax, edi
mov ecx, 0x20
mov dword [eax], ebx
add eax, 8
dec ecx
jne 0x4baf6b
mov ebp, dword [sym.imp.MSVCRT.dll_fread]
mov dword [esi], 0x54bd10
mov edx, dword [0x659a18]
lea eax, [esp + 0x18]
push edx
push 1
push 4
push eax
call ebp
mov eax, dword [0x659958]
add esp, 0x10
cmp eax, 0x19
mov dword [esp + 0x40], ebx
mov dword [esp + 0x10], ebx
jl 0x4bafcc
mov ecx, dword [0x659a18]
lea edx, [esp + 0x10]
push ecx
push 1
push 4
push edx
call ebp
mov eax, dword [0x659a18]
lea ecx, [esp + 0x50]
push eax
push 1
push 4
push ecx
call ebp
add esp, 0x20
mov edx, dword [0x659a18]
push edx
call dword [sym.imp.MSVCRT.dll_ftell]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x44]
add esp, 4
cmp eax, ebx
mov ebx, dword [sym.imp.MSVCRT.dll_fseek]
je 0x4bb012
push 0
push eax
mov eax, dword [0x659a18]
push eax
call ebx
movsx edx, word [0x675ac6]
mov ecx, dword [0x659a18]
push ecx
push edx
push 8
push edi
call ebp
add esp, 0x1c
jmp 0x4bb039
xor ecx, ecx
cmp word [0x675ac6], cx
jle 0x4bb039
mov eax, edi
mov edx, dword [esi + 0xc]
inc ecx
mov dword [eax], edx
mov edx, dword [esi + 0x10]
mov dword [eax + 4], edx
add eax, 8
movsx edx, word [0x675ac6]
cmp ecx, edx
jl 0x4bb01f
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x28]
mov dword [esp + 0x2c], ecx
push edx
mov ecx, esi
mov dword [esp + 0x2c], eax
call fcn.004bb220
mov eax, dword [esp + 0x14]
mov ecx, dword [0x659a18]
push 0
push eax
push ecx
call ebx
lea edi, [esi + 0x218]
mov ecx, 0x20
xor eax, eax
xor edx, edx
rep stosd dword es:[edi], eax
mov byte [esp + 0x2c], al
mov eax, dword [0x659a18]
mov dword [esp + 0x2d], edx
push eax
push 4
lea ecx, [esp + 0x34]
mov word [esp + 0x39], dx
push 1
push ecx
mov byte [esp + 0x43], dl
call ebp
add esp, 0x1c
mov edi, str.tflg
lea eax, [esp + 0x20]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [edi]
jne 0x4bb0c8
test cl, cl
je 0x4bb0c4
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [edi + 1]
jne 0x4bb0c8
add eax, 2
add edi, 2
test cl, cl
jne 0x4bb0a4
xor eax, eax
jmp 0x4bb0cd
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x4bb159
mov eax, dword [0x659a18]
lea edi, [esi + 0x214]
push eax
push 1
push 4
push edi
call ebp
mov ecx, dword [0x659a34]
mov eax, dword [edi]
add esp, 0x10
test ecx, eax
je 0x4bb169
mov edx, dword [0x659a18]
lea eax, [esp + 0x14]
push edx
push 1
push 4
push eax
mov dword [esp + 0x24], 0
call ebp
mov ecx, dword [0x659a18]
push ecx
call dword [sym.imp.MSVCRT.dll_ftell]
mov edx, dword [esp + 0x28]
mov edi, eax
mov eax, dword [0x659a18]
push 0
push edx
push eax
call ebx
movsx edx, word [0x675ac6]
mov ecx, dword [0x659a18]
lea eax, [esi + 0x218]
push ecx
push edx
push 4
push eax
call ebp
mov eax, dword [0x659a18]
push 0
push edi
push eax
call ebx
add esp, 0x3c
jmp 0x4bb169
mov ecx, dword [0x659a18]
push 1
push 0xfffffffffffffffc
push ecx
call ebx
add esp, 0xc
mov ecx, dword [esp + 0x30]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x2c
ret 4