Function at 0x100108a7
Capabilities:
Get file size
Get memory capacity

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [0x10052004]
xor eax, ebp
mov dword [ebp - 4], eax
and dword [ebp - 0x38], 0
push ebx
push esi
push edi
mov edi, ecx
mov eax, dword [edi + 0x18]
test dword [eax + 0xc], 0xa00
jne 0x10010a22
lea eax, [ebp - 0x3c]
push eax
push dword [edi + 0x20]
call dword [sym.imp.api_ms_win_core_file_l1_2_1.dll_GetFileSize]
mov esi, eax
mov dword [ebp - 0x30], esi
cmp esi, 0xffffffff
je 0x10030650
cmp dword [ebp - 0x3c], 0
ja 0x10030672
mov eax, dword [edi + 0x18]
mov eax, dword [eax + 8]
and eax, 0x280
cmp eax, 0x200
je 0x10010919
mov ecx, dword [edi + 0x20]
call fcn.10027659
test eax, eax
jne 0x10010a22
mov eax, dword [edi + 0x18]
test byte [eax + 8], 0x80
jne 0x10010a3c
mov dword [ebp - 0x28], 2
mov dword [ebp - 0x2c], esi
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.api_ms_win_core_kernel32_legacy_l1_1_1.dll_GlobalMemoryStatus]
mov eax, dword [ebp - 0x1c]
shr eax, 1
cmp esi, eax
ja 0x10010a7e
cmp dword [ebp - 8], 0x20000000
jb 0x10010a7e
mov eax, dword [edi + 0x18]
test byte [eax + 0x2c], 1
je 0x1003067c
lea ebx, [edi + 0x34]
cmp dword [ebx], 0
jne 0x100109e1
mov ecx, dword [eax]
test ecx, ecx
je 0x10030686
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0xf80]
mov esi, dword [eax]
add esi, ecx
test esi, esi
je 0x1003068d
add esi, 0xfffffff0
test esi, esi
jne 0x10010a0c
cmp dword [ebx], 0
mov esi, dword [ebp - 0x30]
jne 0x100109e1
push 0
push 0
push 0
push dword [ebp - 0x28]
push 0
push dword [edi + 0x20]
call dword [sym.imp.api_ms_win_core_memory_l1_1_2.dll_CreateFileMappingW]
mov dword [ebx], eax
test esi, esi
je 0x100109d8
lea eax, [ebp - 0x3c]
push eax
push dword [edi + 0x20]
call dword [sym.imp.api_ms_win_core_file_l1_2_1.dll_GetFileSize]
mov esi, eax
cmp esi, 0xffffffff
je 0x10030707
mov eax, dword [edi + 0x18]
mov dword [eax + 0x24], esi
mov eax, dword [edi + 0x18]
mov dword [eax + 0x28], esi
cmp dword [ebx], 0
je 0x10010a7e
push ecx
push dword [ebp - 0x28]
mov ecx, edi
push dword [ebp - 0x2c]
call fcn.1001082b
test eax, eax
js 0x1003073d
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.100281a0
mov esp, ebp
pop ebp
ret 4
cmp edi, esi
jne 0x10030694
mov ecx, esi
call fcn.100102d2
mov esi, eax
jmp 0x1001098e
mov esi, 0x80030001
mov eax, dword [edi + 0x18]
and dword [eax + 0x2c], 0xfffffffe
cmp dword [ebp - 0x38], 0
jne 0x10030752
mov eax, esi
jmp 0x100109f9
mov dword [ebp - 0x28], 4
test esi, esi
jne 0x10010a5f
test byte [eax + 0xc], 0xc4
je 0x10010a7e
mov ecx, edi
call fcn.100258f9
test eax, eax
js 0x10010a67
mov dword [ebp - 0x38], 1
cmp esi, 0x40000
jae 0x10010a73
mov dword [ebp - 0x2c], 0x80000
jmp 0x10010930
lea ebx, [esi + esi]
mov dword [ebp - 0x2c], ebx
jmp 0x10010930
mov esi, 0x8007000e
jmp 0x10010a27
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
test eax, eax
je 0x100108ed
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
mov ecx, eax
call fcn.10004c0d
mov esi, eax
jmp 0x10010a27
mov esi, 0x80030111
jmp 0x10010a27
mov esi, 0x80004005
jmp 0x10010a27
xor esi, esi
jmp 0x10010983
xor esi, esi
jmp 0x1001098e
cmp dword [esi + 0x34], 0
je 0x10010a14
cmp dword [esi + 0x10], 0
je 0x10010a14
push dword [esi + 0x10]
push 0
push 0x40
call dword [sym.imp.api_ms_win_core_processthreads_l1_1_2.dll_OpenProcess]
mov dword [ebp - 0x34], eax
test eax, eax
je 0x10010a14
push 2
push 0
push 0
push ebx
call dword [sym.imp.api_ms_win_core_processthreads_l1_1_2.dll_GetCurrentProcess]
push eax
push dword [esi + 0x34]
push dword [ebp - 0x34]
call dword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_DuplicateHandle]
test eax, eax
je 0x100306e2
xor esi, esi
jmp 0x100306f1
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
mov ecx, eax
call fcn.10004c0d
mov esi, eax
push dword [ebp - 0x34]
call dword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
test esi, esi
js 0x10010a27
jmp 0x10010992
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
test eax, eax
je 0x100109cc
call dword [sym.imp.api_ms_win_core_errorhandling_l1_1_1.dll_GetLastError]
mov ecx, eax
call fcn.10004c0d
cmp dword [ebx], 0
mov esi, eax
je 0x10010a27
push dword [ebx]
call dword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
and dword [ebx], 0
jmp 0x10010a27
push 0
mov ecx, edi
call fcn.100107a7
mov eax, dword [edi + 0x18]
and dword [eax + 0x2c], 0xfffffffe
jmp 0x10010a7e
push 0
push 0
push 0
push dword [edi + 0x20]
call dword [sym.imp.api_ms_win_core_file_l1_2_1.dll_SetFilePointer]
push dword [edi + 0x20]
call dword [sym.imp.api_ms_win_core_file_l1_2_1.dll_SetEndOfFile]
jmp 0x10010a38