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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffeb4
push esi
push edi
push ebx
push 0x10052332
push 0x1005232e
call fcn.1000492b
push 0x1005233a
push 0x10052336
call fcn.1000492b
push 0x10052342
push 0x1005233e
call fcn.1000492b
push 0x1005234a
push 0x10052346
call fcn.1000492b
push 0x10052352
push 0x1005234e
call fcn.1000492b
push 0xc82
push dword [ebp + 8]
call fcn.1001517d
or eax, eax
je 0x100167d4
mov dword [ebp - 0x13c], eax
push 0
push 0
push 0x14b
push dword [ebp - 0x13c]
call fcn.10050f6c
lea eax, [ebp - 0x104]
push eax
call fcn.10015a95
or eax, eax
jne 0x100167d4
lea eax, [ebp - 0x104]
push eax
call fcn.1002fd52
push dword [ebp + 0xc]
push dword [ebp + 0x10]
lea eax, [ebp - 0x136]
push eax
call fcn.10050e22
add esp, 0xc
lea eax, [ebp - 0x136]
push eax
lea eax, [ebp - 0x104]
push eax
call fcn.100510f8
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
lea eax, [ebp - 0x104]
push eax
call fcn.10050fc0
cmp eax, 0xffffffff
je 0x100167d4
mov dword [ebp - 0x140], eax
push 0
push dword [ebp - 0x140]
call fcn.10050ff6
mov dword [ebp - 0x144], eax
cmp dword [ebp - 0x144], 0
je 0x100167c9
add eax, 0xa
push eax
push pe_nt_image_headers32
call fcn.1003d03c
or eax, eax
je 0x100167c9
mov dword [ebp - 0x148], eax
push 0
lea eax, [ebp - 0x144]
push eax
push dword [ebp - 0x144]
push dword [ebp - 0x148]
push dword [ebp - 0x140]
call fcn.1005109e
cmp dword [ebp - 0x144], 0
je 0x100167bd
mov dword [ebp - 0x144], 0
mov esi, dword [ebp - 0x148]
lodsb al, byte [esi]
cmp al, 0xa
jne 0x100165fb
inc dword [ebp - 0x144]
jmp 0x10016607
or al, al
jne 0x10016607
inc dword [ebp - 0x144]
jmp 0x10016609
jmp 0x100165ee
mov eax, dword [ebp - 0x144]
add eax, 0xa
push eax
push 0
call fcn.1003d03c
mov dword [ebp - 0x14c], eax
mov dword [eax], 0
mov esi, dword [ebp - 0x148]
lea edi, [ebp - 0x104]
lodsb al, byte [esi]
cmp al, 0xa
je 0x10016643
cmp al, 0xd
je 0x10016643
or al, al
jne 0x10016799
xor al, al
stosb byte es:[edi], al
mov ebx, esi
lea esi, [ebp - 0x104]
lea edi, [ebp - 0x136]
lodsb al, byte [esi]
stosb byte es:[edi], al
or al, al
je 0x1001665e
cmp al, 0x3d
jne 0x10016654
mov byte [edi - 1], 0
cmp byte [ebp - 0x136], 0
je 0x10016772
lea eax, [ebp - 0x136]
push eax
call fcn.10045c78
or eax, eax
je 0x10016772
lea eax, [ebp - 0x136]
push eax
push 0xffffffffffffffff
push 0x14a
push dword [ebp - 0x13c]
call fcn.10050f6c
xor dl, dl
cmp byte [esi], 0x31
jne 0x100166a6
or dl, 1
cmp byte [esi + 1], 0x31
jne 0x100166af
or dl, 2
cmp byte [esi + 2], 0x31
jne 0x100166b8
or dl, 4
cmp byte [esi + 3], 0x31
jne 0x100166c1
or dl, 8
cmp byte [esi + 4], 0x31
jne 0x100166ca
or dl, 0x10
mov eax, dword [ebp - 0x14c]
mov ecx, dword [eax]
mov byte [eax + ecx + 4], dl
inc ecx
mov dword [eax], ecx
movzx esi, dl
test esi, 1
je 0x100166fa
lea eax, [ebp - 0x136]
push eax
push 0x10052332
push 0x1005232e
call fcn.10045a2c
test esi, 2
je 0x10016718
lea eax, [ebp - 0x136]
push eax
push 0x10052342
push 0x1005233e
call fcn.10045a2c
test esi, 4
je 0x10016736
lea eax, [ebp - 0x136]
push eax
push 0x1005233a
push 0x10052336
call fcn.10045a2c
test esi, 8
je 0x10016754
lea eax, [ebp - 0x136]
push eax
push 0x1005234a
push 0x10052346
call fcn.10045a2c
test esi, 0x10
je 0x10016772
lea eax, [ebp - 0x136]
push eax
push 0x10052352
push 0x1005234e
call fcn.10045a2c
mov esi, ebx
cmp byte [esi - 1], 0
je 0x1001677f
cmp byte [esi], 0
jne 0x10016781
jmp 0x1001679f
jmp 0x10016784
inc esi
cmp byte [esi], 0xd
je 0x10016783
cmp byte [esi], 0xa
je 0x10016783
lea edi, [ebp - 0x104]
jmp 0x10016632
stosb byte es:[edi], al
jmp 0x10016632
mov eax, dword [ebp - 0x14c]
xchg dword [0x10052356], eax
mov dword [ebp - 0x14c], eax
lea eax, [ebp - 0x14c]
push eax
call fcn.1003d00f
lea eax, [ebp - 0x148]
push eax
call fcn.1003d00f
push dword [ebp - 0x140]
call fcn.10050fb4
pop ebx
pop edi
pop esi
leave
ret 0xc