Function at 0x1003fec3
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10050a20
mov eax, dword fs:[0]
push eax
push ecx
sub esp, 0x530
mov eax, dword [0x1005b030]
xor eax, ebp
mov dword [ebp - 0x74], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x520], ecx
mov dword [ebp - 0x14], 0
push 0x38
push 0
lea eax, [ebp - 0x54]
push eax
call fcn.1001c860
add esp, 0xc
cmp dword [ebp + 0xc], 0
je 0x1003fac3
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x524], ecx
mov edx, dword [ebp - 0x524]
add edx, 1
mov dword [ebp - 0x528], edx
mov eax, dword [ebp - 0x524]
mov cl, byte [eax]
mov byte [ebp - 0x529], cl
add dword [ebp - 0x524], 1
cmp byte [ebp - 0x529], 0
jne 0x1003fa8d
mov edx, dword [ebp - 0x524]
sub edx, dword [ebp - 0x528]
mov dword [ebp - 0x530], edx
jne 0x1003fb59
jmp 0x10040276
push 0
push 0
push 3
push 0
push 1
push closesocket
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0xffffffff
jne 0x1003fb80
jmp 0x10040276
push 0
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jbe 0x1004025e
cmp dword [ebp - 0x1c], 0xa00000
jae 0x1004025e
mov edx, dword [ebp - 0x1c]
push edx
call fcn.1001a524
add esp, 4
mov dword [ebp - 0x2c8], eax
mov eax, dword [ebp - 0x2c8]
mov dword [ebp - 0x58], eax
cmp dword [ebp - 0x58], 0
jne 0x1003fbcc
jmp 0x10040216
push 0
push 0
push 0
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea edx, [ebp - 0x60]
push edx
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x58]
push ecx
mov edx, dword [ebp - 0x18]
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [ebp - 0x60]
cmp eax, dword [ebp - 0x1c]
je 0x1003fc01
jmp 0x10040216
mov ecx, dword [ebp - 0x58]
mov edx, dword [ecx]
mov dword [ebp - 0x54], edx
mov ax, word [ecx + 4]
mov word [ebp - 0x50], ax
mov ecx, dword [ebp - 0x1c]
sub ecx, 4
push ecx
mov edx, dword [ebp - 0x58]
add edx, 4
push edx
call fcn.100319e0
add esp, 8
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x5c]
cmp eax, dword [ebp - 0x54]
je 0x1003fc37
jmp 0x10040216
movzx ecx, byte [ebp - 0x50]
shl ecx, 8
mov word [0x10073e48], cx
movzx edx, byte [ebp - 0x4f]
shl edx, 8
mov word [0x10073e44], dx
mov eax, dword [ebp - 0x1c]
sub eax, 6
push eax
mov ecx, dword [ebp - 0x58]
add ecx, 6
push ecx
call fcn.10031980
mov ecx, 0xe
mov esi, dword [ebp - 0x58]
lea edi, [ebp - 0x54]
rep movsd dword es:[edi], dword [esi]
cmp dword [ebp - 0x20], 0
jbe 0x1003ff5c
cmp dword [ebp - 0x20], 0xff
jae 0x1003ff5c
xor ecx, ecx
mov eax, dword [ebp - 0x20]
mov edx, 0x108
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.1001a524
add esp, 4
mov dword [ebp - 0x2cc], eax
mov eax, dword [ebp - 0x2cc]
mov dword [ebp - 0x64], eax
cmp dword [ebp - 0x64], 0
je 0x1003ff55
mov ecx, dword [ebp - 0x20]
imul ecx, ecx, 0x108
push ecx
mov edx, dword [ebp - 0x58]
add edx, 0x38
push edx
mov eax, dword [ebp - 0x64]
push eax
call fcn.1001cef0
add esp, 0xc
mov ecx, dword [ebp - 0x520]
add ecx, 0xd0
call fcn.10035e30
mov ecx, dword [ebp - 0x520]
add ecx, 0xa0
call fcn.10035db0
mov dword [ebp - 0x68], 0
jmp 0x1003fd10
mov ecx, dword [ebp - 0x68]
add ecx, 1
mov dword [ebp - 0x68], ecx
mov edx, dword [ebp - 0x68]
cmp edx, dword [ebp - 0x20]
jae 0x1003ff11
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ax, word [0x100530cc]
mov word [ebp - 0x188], ax
mov byte [ebp - 0x69], 0x23
mov ecx, dword [ebp - 0x68]
imul ecx, ecx, 0x108
mov edx, dword [ebp - 0x64]
mov al, byte [edx + ecx]
mov byte [ebp - 0x181], al
lea ecx, [ebp - 0x188]
push ecx
mov edx, dword [ebp - 0x68]
imul edx, edx, 0x108
add edx, dword [ebp - 0x64]
push edx
call fcn.10029080
add esp, 8
mov dword [ebp - 0x70], eax
cmp dword [ebp - 0x70], 0
je 0x1003fe45
mov byte [ebp - 0x1b0], 0
xor eax, eax
mov dword [ebp - 0x1af], eax
mov dword [ebp - 0x1ab], eax
mov dword [ebp - 0x1a7], eax
mov dword [ebp - 0x1a3], eax
mov dword [ebp - 0x19f], eax
mov dword [ebp - 0x19b], eax
mov dword [ebp - 0x197], eax
mov dword [ebp - 0x193], eax
mov ecx, dword [ebp - 0x70]
add ecx, 1
mov dword [ebp - 0x534], ecx
lea edx, [ebp - 0x1b0]
mov dword [ebp - 0x538], edx
mov eax, dword [ebp - 0x538]
mov dword [ebp - 0x53c], eax
mov ecx, dword [ebp - 0x534]
mov dl, byte [ecx]
mov byte [ebp - 0x53d], dl
mov eax, dword [ebp - 0x538]
mov cl, byte [ebp - 0x53d]
mov byte [eax], cl
mov edx, dword [ebp - 0x534]
add edx, 1
mov dword [ebp - 0x534], edx
mov eax, dword [ebp - 0x538]
add eax, 1
mov dword [ebp - 0x538], eax
cmp byte [ebp - 0x53d], 0
jne 0x1003fdd0
lea ecx, [ebp - 0x1b0]
push ecx
call fcn.1001ae19
add esp, 4
mov dword [ebp - 0x18c], eax
lea edx, [ebp - 0x18c]
push edx
mov ecx, dword [ebp - 0x520]
add ecx, 0xd0
call fcn.1003ee50
jmp 0x1003ff0c
movsx eax, byte [ebp - 0x181]
movsx ecx, byte [ebp - 0x69]
cmp eax, ecx
jne 0x1003fec5
mov dword [ebp - 4], 0
mov byte [ebp - 0x1b8], 0
xor edx, edx
mov dword [ebp - 0x1b7], edx
mov byte [ebp - 0x1b3], dl
push 5
mov eax, dword [ebp - 0x68]
imul eax, eax, 0x108
mov ecx, dword [ebp - 0x64]
lea edx, [ecx + eax + 1]
push edx
lea eax, [ebp - 0x1b8]
push eax
call fcn.1002ff50
add esp, 0xc
lea ecx, [ebp - 0x1b8]
push ecx
call fcn.1001ae19
add esp, 4
mov edx, dword [ebp - 0x520]
mov dword [edx + 0xe8], eax
jmp 0x1003febc
mov dword [ebp - 4], 0xffffffff
jmp 0x1003ff0c
mov esi, dword [ebp - 0x68]
imul esi, esi, 0x108
add esi, dword [ebp - 0x64]
mov ecx, 0x41
lea edi, [ebp - 0x180]
rep movsd dword es:[edi], dword [esi]
mov eax, dword [ebp - 0x68]
imul eax, eax, 0x108
mov ecx, dword [ebp - 0x64]
mov edx, dword [ecx + eax + 0x104]
mov dword [ebp - 0x7c], edx
lea eax, [ebp - 0x180]
push eax
mov ecx, dword [ebp - 0x520]
add ecx, 0xa0
call fcn.1003ed00
jmp 0x1003fd07
mov dword [ebp - 4], 2
cmp dword [ebp - 0x64], 0
je 0x1003ff36
mov ecx, dword [ebp - 0x64]
mov dword [ebp - 0x2d0], ecx
mov edx, dword [ebp - 0x2d0]
push edx
call fcn.1001b03f
add esp, 4
jmp 0x1003ff45
mov dword [ebp - 4], 0xffffffff
mov dword [ebp - 0x64], 0
jmp 0x1003ff5c
mov dword [ebp - 0x20], 0
cmp dword [ebp - 0x24], 0
jbe 0x100401fa
cmp dword [ebp - 0x24], 0xff
jae 0x100401fa
xor ecx, ecx
mov eax, dword [ebp - 0x24]
mov edx, 0x28
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.1001a524
add esp, 4
mov dword [ebp - 0x2d4], eax
mov eax, dword [ebp - 0x2d4]
mov dword [ebp - 0x1bc], eax
cmp dword [ebp - 0x1bc], 0
je 0x100401f3
mov ecx, dword [ebp - 0x24]
imul ecx, ecx, 0x28
push ecx
mov edx, dword [ebp - 0x20]
imul edx, edx, 0x108
mov eax, dword [ebp - 0x58]
lea ecx, [eax + edx + 0x38]
push ecx
mov edx, dword [ebp - 0x1bc]
push edx
call fcn.1001cef0
add esp, 0xc
mov ecx, dword [ebp - 0x520]
add ecx, 0xb8
call fcn.10035df0
mov ecx, dword [ebp - 0x520]
add ecx, 0x70
call fcn.10035d70
mov ecx, dword [ebp - 0x520]
add ecx, 0x88
call fcn.10035d70
mov dword [ebp - 0x1c0], 0
jmp 0x10040020
mov eax, dword [ebp - 0x1c0]
add eax, 1
mov dword [ebp - 0x1c0], eax
mov ecx, dword [ebp - 0x1c0]
cmp ecx, dword [ebp - 0x24]
jae 0x100401a6
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
mov edx, dword [ebp - 0x1c0]
imul edx, edx, 0x28
mov eax, dword [ebp - 0x1bc]
mov cl, byte [eax + edx]
mov byte [ebp - 0x1c1], cl
mov byte [ebp - 0x1c2], 0x2a
mov byte [ebp - 0x1c3], 0x23
movsx edx, byte [ebp - 0x1c1]
movsx eax, byte [ebp - 0x1c2]
cmp edx, eax
jne 0x100400c7
push 0x64
mov ecx, dword [ebp - 0x1c0]
imul ecx, ecx, 0x28
mov edx, dword [ebp - 0x1bc]
lea eax, [edx + ecx + 1]
push eax
lea ecx, [ebp - 0x230]
push ecx
call fcn.1002ff50
add esp, 0xc
mov edx, dword [ebp - 0x1c0]
imul edx, edx, 0x28
mov eax, dword [ebp - 0x1bc]
mov ecx, dword [eax + edx + 0x24]
mov dword [ebp - 0x1cc], ecx
lea edx, [ebp - 0x230]
push edx
mov ecx, dword [ebp - 0x520]
add ecx, 0x70
call fcn.1003ec60
jmp 0x100401a1
movsx eax, byte [ebp - 0x1c1]
movsx ecx, byte [ebp - 0x1c3]
cmp eax, ecx
jne 0x10040131
push 0x64
mov edx, dword [ebp - 0x1c0]
imul edx, edx, 0x28
mov eax, dword [ebp - 0x1bc]
lea ecx, [eax + edx + 1]
push ecx
lea edx, [ebp - 0x298]
push edx
call fcn.1002ff50
add esp, 0xc
mov eax, dword [ebp - 0x1c0]
imul eax, eax, 0x28
mov ecx, dword [ebp - 0x1bc]
mov edx, dword [ecx + eax + 0x24]
mov dword [ebp - 0x234], edx
lea eax, [ebp - 0x298]
push eax
mov ecx, dword [ebp - 0x520]
add ecx, 0x88
call fcn.1003ec60
jmp 0x100401a1
mov esi, dword [ebp - 0x1c0]
imul esi, esi, 0x28
add esi, dword [ebp - 0x1bc]
mov ecx, 8
lea edi, [ebp - 0x2c4]
rep movsd dword es:[edi], dword [esi]
movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp - 0x1c0]
imul ecx, ecx, 0x28
mov edx, dword [ebp - 0x1bc]
mov eax, dword [edx + ecx + 0x24]
mov dword [ebp - 0x2a0], eax
mov ecx, dword [ebp - 0x1c0]
imul ecx, ecx, 0x28
mov edx, dword [ebp - 0x1bc]
mov eax, dword [edx + ecx + 0x24]
push eax
call fcn.10031de0
add esp, 4
mov dword [ebp - 0x29c], eax
lea ecx, [ebp - 0x2c4]
push ecx
mov ecx, dword [ebp - 0x520]
add ecx, 0xb8
call fcn.1003edb0
jmp 0x10040011
mov dword [ebp - 4], 4
cmp dword [ebp - 0x1bc], 0
je 0x100401d1
mov edx, dword [ebp - 0x1bc]
mov dword [ebp - 0x2d8], edx
mov eax, dword [ebp - 0x2d8]
push eax
call fcn.1001b03f
add esp, 4
jmp 0x100401e0
mov dword [ebp - 4], 0xffffffff
mov dword [ebp - 0x1bc], 0
jmp 0x100401fa
mov dword [ebp - 0x24], 0
mov ecx, 0xa
lea esi, [ebp - 0x4c]
mov edi, dword [ebp + 8]
rep movsd dword es:[edi], dword [esi]
mov dword [ebp - 0x14], 1
xor ecx, ecx
jne 0x1003fbc1
cmp dword [ebp - 0x58], 0
je 0x1004025e
mov dword [ebp - 4], 6
cmp dword [ebp - 0x58], 0
je 0x10040241
mov edx, dword [ebp - 0x58]
mov dword [ebp - 0x2dc], edx
mov eax, dword [ebp - 0x2dc]
push eax
call fcn.1001b03f
add esp, 4
jmp 0x10040250
mov dword [ebp - 4], 0xffffffff
mov dword [ebp - 0x58], 0
cmp dword [ebp - 0x18], 0xffffffff
je 0x1004026e
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
jne 0x1003fa5f
cmp dword [ebp - 0x14], 0
jne 0x100402dc
mov eax, dword [ebp + 8]
mov dword [eax + 0x20], 1
mov ecx, dword [ebp + 8]
mov dword [ecx + 8], 1
mov edx, dword [ebp + 8]
mov dword [edx + 4], 1
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 1
mov ecx, dword [ebp + 8]
mov dword [ecx + 0xc], 0x5a
mov edx, dword [ebp + 8]
mov dword [edx + 0x10], 0x3c
mov eax, dword [ebp + 8]
mov dword [eax], 1
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x24], 1
mov edx, dword [ebp + 8]
mov dword [edx + 0x14], 0
xor eax, eax
jmp 0x1004039d
mov eax, dword [ebp + 8]
cmp dword [eax + 0xc], 0
jne 0x100402ef
mov ecx, dword [ebp + 8]
mov dword [ecx + 0xc], 0xa
mov edx, dword [ebp + 8]
cmp dword [edx + 0x10], 0
jne 0x10040302
mov eax, dword [ebp + 8]
mov dword [eax + 0xc], 0xa
mov eax, 1
jmp 0x1004039d
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x74]
xor ecx, ebp
call fcn.1001a52f
mov esp, ebp
pop ebp
ret 8