Function at 0x46eb10
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4f6c58
mov eax, dword fs:[0]
push eax
sub esp, 0x40
mov eax, dword [0x52278c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x4c], ecx
mov eax, dword [ebp - 0x4c]
cmp dword [eax + 0xc], 0
je 0x46eb46
jmp 0x46edd5
mov ecx, dword [ebp - 0x4c]
movzx edx, byte [ecx + 0x1f]
cmp edx, 1
jne 0x46ebaf
mov eax, dword [ebp - 0x4c]
cmp dword [eax + 8], 0xffff
jae 0x46eb8a
push 0x2000
push 0
push 0
push 0
mov ecx, dword [ebp - 0x4c]
movzx edx, word [ecx + 8]
push edx
mov ecx, 0x52bbbc
call fcn.0043cbb0
push eax
call dword [0x4fc4ac]
mov ecx, dword [ebp - 0x4c]
mov dword [ecx + 0xc], eax
jmp 0x46ebaa
push 0x2010
push 0
push 0
push 0
mov edx, dword [ebp - 0x4c]
mov eax, dword [edx + 8]
push eax
push 0
call dword [0x4fc4ac]
mov ecx, dword [ebp - 0x4c]
mov dword [ecx + 0xc], eax
jmp 0x46ed14
mov edx, dword [ebp - 0x4c]
cmp dword [edx + 8], 0xffff
jae 0x46ec41
lea ecx, [ebp - 0x14]
call fcn.0046ee10
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x4c]
movzx ecx, byte [eax + 0x1f]
cmp ecx, 2
jne 0x46ec2d
push ecx
mov ecx, esp
mov dword [ebp - 0x3c], esp
mov edx, dword [ebp - 0x4c]
mov eax, dword [edx + 8]
push eax
call fcn.0046edf0
push ecx
mov ecx, esp
mov dword [ebp - 0x40], esp
push 0x50003c
call fcn.004698d0
lea ecx, [ebp - 0x14]
call fcn.0046ee60
movzx ecx, al
test ecx, ecx
je 0x46ec2d
push 1
lea ecx, [ebp - 0x14]
call fcn.0046eed0
push eax
lea ecx, [ebp - 0x14]
call fcn.0046eef0
push eax
call fcn.0046d550
add esp, 0xc
mov edx, dword [ebp - 0x4c]
mov dword [edx + 0xc], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.0046ee40
jmp 0x46ed14
mov dword [ebp - 0x18], 0
push 0x500034
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax + 8]
push ecx
lea edx, [ebp - 0x18]
push edx
call fcn.004c4429
add esp, 0xc
test eax, eax
jne 0x46ed14
cmp dword [ebp - 0x18], 0
je 0x46ed14
push 2
push 0
mov eax, dword [ebp - 0x18]
push eax
call fcn.004c42c7
add esp, 0xc
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.004c41cf
add esp, 4
mov dword [ebp - 0x20], eax
push 0
push 0
mov edx, dword [ebp - 0x18]
push edx
call fcn.004c42c7
add esp, 0xc
mov eax, dword [ebp - 0x20]
push eax
call fcn.004bf734
add esp, 4
mov dword [ebp - 0x44], eax
mov ecx, dword [ebp - 0x44]
mov dword [ebp - 0x1c], ecx
cmp dword [ebp - 0x1c], 0
je 0x46ed08
mov edx, dword [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x20]
push eax
push 1
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.004c3e82
add esp, 0x10
mov edx, dword [ebp - 0x4c]
movzx eax, byte [edx + 0x1f]
cmp eax, 2
jne 0x46ecf6
push 1
mov ecx, dword [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call fcn.0046d550
add esp, 0xc
mov ecx, dword [ebp - 0x4c]
mov dword [ecx + 0xc], eax
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x48], edx
mov eax, dword [ebp - 0x48]
push eax
call fcn.004c4975
add esp, 4
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.004c3abb
add esp, 4
mov edx, dword [ebp - 0x4c]
cmp dword [edx + 0xc], 0
jne 0x46ed50
mov eax, dword [ebp - 0x4c]
mov dword [eax + 0x18], 0
xor ecx, ecx
mov edx, dword [ebp - 0x4c]
mov word [edx + 0x1c], cx
mov eax, dword [ebp - 0x4c]
mov dword [eax + 0x10], 0
mov ecx, dword [ebp - 0x4c]
mov dword [ecx + 0x14], 0
mov edx, dword [ebp - 0x4c]
mov byte [edx + 0x1e], 0
jmp 0x46edd5
lea eax, [ebp - 0x38]
push eax
push 0x18
mov ecx, dword [ebp - 0x4c]
mov edx, dword [ecx + 0xc]
push edx
call dword [0x4fc0ac]
mov eax, dword [ebp - 0x4c]
mov ecx, dword [ebp - 0x34]
mov dword [eax + 0x18], ecx
mov edx, dword [ebp - 0x4c]
movzx eax, word [edx + 0x1c]
test eax, eax
je 0x46ed8c
mov ecx, dword [ebp - 0x4c]
movzx ecx, word [ecx + 0x1c]
mov eax, dword [ebp - 0x34]
cdq
idiv ecx
mov edx, dword [ebp - 0x4c]
mov dword [edx + 0x10], eax
jmp 0x46ed96
mov eax, dword [ebp - 0x4c]
mov dword [eax + 0x10], 0
mov ecx, dword [ebp - 0x4c]
mov edx, dword [ebp - 0x30]
mov dword [ecx + 0x14], edx
movzx eax, word [ebp - 0x26]
cmp eax, 0x20
sete cl
mov edx, dword [ebp - 0x4c]
mov byte [edx + 0x1e], cl
mov eax, dword [ebp - 0x4c]
mov dword [eax + 4], 1
mov ecx, dword [ebp - 0x4c]
movzx edx, word [ecx + 0x1c]
mov eax, dword [ebp - 0x4c]
imul edx, dword [eax + 0x10]
xor ecx, ecx
cmp edx, dword [ebp - 0x34]
sete cl
mov edx, dword [ebp - 0x4c]
mov dword [edx + 4], ecx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov esp, ebp
pop ebp
ret