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

Disassembly:
push 0x44
mov eax, 0x10026461
call fcn.1002489d
mov eax, dword [ebp + 0x2c]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp + 0x30]
mov dword [ebp - 0x30], eax
xor ebx, ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x3c], ebx
mov eax, dword [ebp + 0x28]
mov byte [ebp - 4], 1
mov esi, dword [eax]
jmp 0x100221c2
push esi
lea ecx, [ebp - 0x2c]
call fcn.100112da
mov byte [ebp - 4], 2
cmp dword [ebp - 0x18], 0x10
mov ecx, dword [ebp - 0x2c]
mov eax, ecx
jae 0x1002212a
lea eax, [ebp - 0x2c]
mov edi, dword [ebp - 0x1c]
cmp byte [eax + edi - 1], 0x5c
je 0x1002216e
cmp dword [ebp + 0x24], 0x10
mov eax, dword [ebp + 0x10]
mov edx, eax
jae 0x10022142
lea edx, [ebp + 0x10]
cmp byte [edx], 0x5c
je 0x1002216e
cmp dword [ebp - 0x18], 0x10
jae 0x10022150
lea ecx, [ebp - 0x2c]
cmp byte [ecx + edi - 1], 0x2f
je 0x1002216e
cmp dword [ebp + 0x24], 0x10
jae 0x10022160
lea eax, [ebp + 0x10]
cmp byte [eax], 0x2f
je 0x1002216e
push ecx
lea ecx, [ebp - 0x2c]
call fcn.1002280f
push ecx
push ecx
lea eax, [ebp + 0x10]
push eax
lea ecx, [ebp - 0x2c]
call fcn.10022d12
cmp dword [ebp - 0x18], 0x10
mov eax, dword [ebp - 0x2c]
jae 0x10022188
lea eax, [ebp - 0x2c]
push ebx
push 0x80
push 3
push ebx
push 1
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
push ebx
mov edi, eax
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x38], edi
push 1
call fcn.100049cb
cmp edi, 0xffffffff
jne 0x1002224a
mov eax, dword [ebp + 0x28]
add esi, 0x18
cmp esi, dword [eax + 4]
jne 0x1002210f
cmp dword [ebp + 0x24], 0x10
mov eax, dword [ebp + 0x10]
jae 0x100221d7
lea eax, [ebp + 0x10]
push ebx
push 0x80
push 3
push ebx
push 1
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
mov dword [ebp - 0x38], eax
cmp edi, 0xffffffff
jne 0x1002224a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x1002220d
movzx esi, si
or esi, 0x80070000
mov eax, dword [section..data]
cmp eax, section..data
je 0x10022410
test byte [eax + 0x1c], 4
je 0x10022410
cmp byte [eax + 0x19], 2
jb 0x10022410
push esi
push dword [eax + 0x14]
mov edx, 0x10003878
push dword [eax + 0x10]
push 0x16
pop ecx
call fcn.10004dbb
jmp 0x10022410
mov eax, dword [section..data]
cmp eax, section..data
je 0x10022275
test byte [eax + 0x1c], 4
je 0x10022275
cmp byte [eax + 0x19], 5
jb 0x10022275
push dword [eax + 0x14]
mov edx, 0x10003878
push dword [eax + 0x10]
push 0x17
pop ecx
call fcn.10004d9d
lea eax, [ebp - 0x4c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x100222d6
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x10022299
movzx esi, si
or esi, 0x80070000
mov eax, dword [section..data]
cmp eax, section..data
je 0x10022404
test byte [eax + 0x1c], 4
je 0x10022404
cmp byte [eax + 0x19], 2
jb 0x10022404
push esi
push dword [eax + 0x14]
push dword [eax + 0x10]
push 0x18
mov edx, 0x10003878
pop ecx
call fcn.10004dbb
jmp 0x10022404
mov eax, dword [ebp - 0x4c]
lea esi, [eax + 1]
mov dword [ebp - 0x34], esi
cmp esi, eax
jb 0x100222e7
mov esi, ebx
jmp 0x1002231c
or dword [ebp - 0x34], 0xffffffff
mov esi, 0x80070216
mov eax, dword [section..data]
cmp eax, section..data
je 0x1002231c
test byte [eax + 0x1c], 4
je 0x1002231c
cmp byte [eax + 0x19], 2
jb 0x1002231c
push esi
push dword [eax + 0x14]
mov edx, 0x10003878
push dword [eax + 0x10]
push 0x19
pop ecx
call fcn.10004dbb
push dword [ebp - 0x34]
lea ecx, [ebp - 0x44]
mov byte [ebp - 4], 3
call fcn.1000b07d
push ebx
push ebx
mov dword [ebp - 4], 1
push dword [ebp - 0x4c]
push dword [ebp - 0x44]
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1002238c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x1002235a
movzx esi, si
or esi, 0x80070000
mov eax, dword [section..data]
cmp eax, section..data
je 0x10022404
test byte [eax + 0x1c], 4
je 0x10022404
cmp byte [eax + 0x19], 2
jb 0x10022404
push esi
push dword [eax + 0x14]
push dword [eax + 0x10]
push 0x1b
jmp 0x100222c6
mov ecx, dword [ebp - 0x44]
mov eax, dword [ebp - 0x4c]
push ecx
mov byte [ecx + eax], bl
call fcn.100047a1
pop ecx
mov ecx, dword [ebp - 0x50]
push eax
push dword [ebp - 0x44]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.10022867
mov eax, dword [ebp - 0x4c]
xor ecx, ecx
sub eax, dword [ebp + 0xc]
mov edx, dword [ebp - 0x30]
sbb ecx, ebx
add dword [edx], eax
adc dword [edx + 4], ecx
jmp 0x10022404
cmp edi, 0xffffffff
je 0x10022410
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x44]
call fcn.10007fe8
push ebx
push 1
lea ecx, [ebp + 0x10]
call fcn.100049cb
mov eax, esi
call fcn.100247ef
ret 0x2c