Function at 0x140010990
Capabilities:
Check if file exists
Get file size
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0xc0
mov rax, qword [0x14012a210]
xor rax, rsp
mov qword [rbp + 0x1f], rax
mov rsi, r8
mov rbx, rdx
test rdx, rdx
je 0x140010cdd
lea rdx, [rbp + 7]
lea rcx, str.Msxml2.DOMDocument.3.0
call qword [sym.imp.ole32.dll_CLSIDFromProgID]
test eax, eax
js 0x140010cca
mov qword [rsp + 0x20], rsi
lea r9, [0x1400ff4f0]
xor edx, edx
lea r8d, [rdx + 0x17]
lea rcx, [rbp + 7]
call qword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
js 0x140010cca
mov rcx, qword [rsi]
test rcx, rcx
je 0x140010cdd
mov rax, qword [rcx]
mov r13d, 1
mov edx, r13d
call qword [rax + 0x240]
xor edi, edi
mov word [rbp - 0x11], di
mov rcx, rbx
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x140010c89
mov qword [rbp - 0x59], rdi
mov qword [rbp - 0x49], rdi
mov qword [rbp - 0x41], 7
mov r14, 0xffffffffffffffff
mov r8, r14
inc r8
cmp word [rbx + r8*2], di
jne 0x140010a55
mov rdx, rbx
lea rcx, [rbp - 0x59]
call fcn.140011160
xor r15b, r15b
mov dword [rbp - 9], edi
lea rcx, [rbp - 0x59]
cmp qword [rbp - 0x41], 8
cmovae rcx, qword [rbp - 0x59]
mov qword [rsp + 0x30], rdi
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x20], 3
xor r9d, r9d
mov r8d, r13d
mov edx, 0xc0000000
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r12, rax
cmp rax, r14
je 0x140010af3
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 2
jb 0x140010aea
mov qword [rsp + 0x20], rdi
lea r9, [rbp - 9]
mov r8d, 2
lea rdx, [rbp - 0xd]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140010aea
movzx r15d, r15b
mov eax, 0xfeff
cmp word [rbp - 0xd], ax
cmove r15d, r13d
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rdx, qword [rbp - 0x41]
cmp rdx, 8
jb 0x140010b33
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x59]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140010b2e
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140010d21
call fcn.1400a59a4
test r15b, r15b
je 0x140010c1f
mov qword [rbp - 1], rdi
mov qword [rbp - 0x31], rdi
mov qword [rbp - 0x21], rdi
mov qword [rbp - 0x19], 7
mov r8, r14
inc r8
cmp word [rbx + r8*2], 0
jne 0x140010b53
mov rdx, rbx
lea rcx, [rbp - 0x31]
call fcn.140011160
lea r8, [rbp - 1]
lea rdx, [rbp - 0x31]
call fcn.1400107c0
mov r15, qword [rsi]
mov rbx, qword [rbp - 1]
test rbx, rbx
jne 0x140010bc0
lea ecx, [rbx + 0x18]
call fcn.1400a5718
mov rbx, rax
mov qword [rbp - 0x39], rax
test rax, rax
je 0x140010bb0
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rbx], xmm0
mov qword [rbx + 0x10], rax
mov qword [rbx + 8], rdi
mov dword [rbx + 0x10], r13d
mov qword [rbx], rdi
jmp 0x140010bb3
mov rbx, rdi
mov qword [rbp - 1], rbx
test rbx, rbx
je 0x140010d27
mov rax, qword [r15]
lea r8, [rbp - 0x11]
mov rdx, qword [rbx]
mov rcx, r15
call qword [rax + 0x208]
mov r15d, eax
lock xadd dword [rbx + 0x10], r14d
cmp r14d, 1
jne 0x140010c9f
mov rbx, qword [rbp - 1]
mov rcx, qword [rbx]
test rcx, rcx
je 0x140010bfb
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov qword [rbx], rdi
mov rcx, qword [rbx + 8]
test rcx, rcx
je 0x140010c0d
call fcn.1400a59a4
mov qword [rbx + 8], rdi
mov edx, 0x18
mov rcx, rbx
call fcn.1400a59a4
jmp 0x140010c9f
mov word [rbp + 7], di
lea rcx, [rbp + 7]
call qword [sym.imp.OLEAUT32.dll_VariantCopy]
test eax, eax
js 0x140010d32
mov eax, 8
mov word [rbp + 7], ax
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov qword [rbp + 0xf], rax
test rax, rax
je 0x140010d06
mov rcx, qword [rsi]
movups xmm0, xmmword [rbp + 7]
movaps xmmword [rbp - 0x59], xmm0
movsd xmm1, qword [rbp + 0x17]
movsd qword [rbp - 0x49], xmm1
mov rax, qword [rcx]
lea r8, [rbp - 0x11]
lea rdx, [rbp - 0x59]
call qword [rax + 0x1d0]
mov r15d, eax
lea rcx, [rbp + 7]
call qword [sym.imp.OLEAUT32.dll_VariantCopy]
jmp 0x140010c9f
mov rcx, qword [rsi]
mov rax, qword [rcx]
lea r8, [rbp - 0x11]
mov rdx, rbx
call qword [rax + 0x208]
mov r15d, eax
test r15d, r15d
js 0x140010caf
cmp word [rbp - 0x11], 0
je 0x140010caf
mov al, 1
jmp 0x140010cdf
mov rcx, qword [rsi]
test rcx, rcx
je 0x140010cdd
mov qword [rsi], rdi
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rsi]
test rcx, rcx
je 0x140010cdd
jmp 0x140010cd4
mov rcx, qword [rsi]
test rcx, rcx
je 0x140010cdd
xor edi, edi
mov qword [rsi], rdi
mov rax, qword [rcx]
call qword [rax + 0x10]
xor al, al
mov rcx, qword [rbp + 0x1f]
xor rcx, rsp
call fcn.1400a5460
mov rbx, qword [rsp + 0x100]
add rsp, 0xc0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
mov eax, 0xa
mov word [rbp + 7], ax
mov dword [rbp + 0xf], 0x8007000e
mov ecx, 0x8007000e
call fcn.140003f50
int3
call fcn.1400b4704
nop
mov ecx, 0x8007000e
call fcn.1400a5120
nop
mov ecx, eax
call fcn.140003f50
int3