Function at 0x140003790
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x80
mov r13, rcx
mov r15, qword [0x1400f6380]
mov rax, qword [r15]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov rbx, qword [r8 + 0x18]
cmp dword [rbx + 0x84], 1
jbe 0x1400038b4
mov rdi, r8
mov rsi, qword [r8 + 0x10]
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
mov rcx, rdx
mov edx, 0x80000000
mov r8d, 1
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r14, rax
cmp rax, 0xffffffffffffffff
je 0x1400038d7
add rbx, 0x90
mov eax, ebx
sub eax, esi
xorps xmm0, xmm0
movaps xmmword [rsp + 0x50], xmm0
movaps xmmword [rsp + 0x40], xmm0
mov dword [rsp + 0x50], eax
mov qword [rsp + 0x60], 0
lea rax, [rsp + 0x40]
mov qword [rsp + 0x20], rax
lea rdx, [rsp + 0x60]
lea r9, [rsp + 0x38]
mov rcx, r14
mov r8d, 8
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14000390c
cmp dword [rsp + 0x38], 8
jne 0x14000390c
mov rax, qword [rsp + 0x60]
mov qword [rsp + 0x38], rax
lea rcx, [rsp + 0x40]
mov rdx, rdi
call fcn.14000a810
mov rax, qword [rdi + 0x30]
test rax, rax
je 0x140003941
cmp qword [rdi + 0x10], rbx
ja 0x140003941
mov rdx, rbx
cmp qword [rdi + 0x20], rbx
jb 0x140003944
mov rcx, rbx
sub rcx, qword [rdi + 8]
add rax, rcx
mov rdx, rax
jmp 0x140003944
mov byte [r13 + 0x10], 1
lea rax, str._var_tmp_build_firefox_cc4c8eaff833_obj_mingw_dist_include_mozilla_ImportDir.h
mov qword [r13], rax
movabs rax, 0x800700c100000035
mov qword [r13 + 8], rax
jmp 0x140003a3f
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
mov byte [r13 + 0x10], 1
lea rax, str._var_tmp_build_firefox_cc4c8eaff833_obj_mingw_dist_include_mozilla_ImportDir.h
mov qword [r13], rax
mov dword [r13 + 8], 0x3c
mov dword [r13 + 0xc], ecx
jmp 0x140003a29
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
mov byte [r13 + 0x10], 1
lea rax, str._var_tmp_build_firefox_cc4c8eaff833_obj_mingw_dist_include_mozilla_ImportDir.h
mov qword [r13], rax
mov dword [r13 + 8], 0x16
mov dword [r13 + 0xc], ecx
jmp 0x140003a29
mov rdx, rbx
mov rcx, qword [rdi]
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x48], 8
mov qword [rsp + 0x50], rcx
lea r12, [rsp + 0x58]
mov qword [rsp + 0x58], 0
mov qword [rsp + 0x20], r12
mov r8d, 8
mov r9d, 4
call qword [sym.imp.KERNEL32.dll_VirtualProtectEx]
test eax, eax
je 0x1400039bf
mov ecx, dword [rsp + 0x5c]
test ecx, ecx
js 0x1400039db
lea rcx, [rsp + 0x60]
mov rdx, rdi
call fcn.14000a810
cmp byte [rsp + 0x70], 0
je 0x140003a69
mov rax, qword [rsp + 0x60]
mov edx, dword [rsp + 0x68]
mov ecx, dword [rsp + 0x6c]
mov byte [r13 + 0x10], 1
mov qword [r13], rax
mov dword [r13 + 8], edx
jmp 0x1400039f3
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
mov dword [rsp + 0x5c], ecx
test ecx, ecx
jns 0x14000398b
mov byte [r13 + 0x10], 1
lea rax, str._var_tmp_build_firefox_cc4c8eaff833_obj_mingw_dist_include_mozilla_ImportDir.h
mov qword [r13], rax
mov dword [r13 + 8], 0x51
mov dword [r13 + 0xc], ecx
xor edi, edi
cmp dword [rsp + 0x5c], 0
js 0x140003a1f
mov rcx, qword [rsp + 0x50]
mov rdx, qword [rsp + 0x40]
mov r8, qword [rsp + 0x48]
mov r9d, dword [rsp + 0x58]
mov qword [rsp + 0x20], r12
call qword [sym.imp.KERNEL32.dll_VirtualProtectEx]
test dil, dil
je 0x140003a29
mov byte [r13 + 0x10], 0
mov rax, r14
add rax, 1
cmp rax, 2
jb 0x140003a3f
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, qword [rsp + 0x78]
xor rax, rsp
mov rcx, qword [r15]
cmp rcx, rax
jne 0x140003ae1
mov rax, r13
add rsp, 0x80
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov rcx, qword [rdi]
mov rax, qword [rdi + 0x30]
test rax, rax
je 0x140003a88
cmp qword [rdi + 0x10], rbx
ja 0x140003a88
cmp qword [rdi + 0x20], rbx
jb 0x140003a88
sub rbx, qword [rdi + 8]
add rbx, rax
mov qword [rsp + 0x20], 0
lea r8, [rsp + 0x38]
mov r9d, 8
mov rdx, rbx
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x140003abc
mov dil, 1
cmp dword [rsp + 0x5c], 0
jns 0x140003a00
jmp 0x140003a1f
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ecx, ax
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
lea rax, [0x1400f6821]
mov edx, 0x5cf
jmp 0x1400039b0
call fcn.140072349
int3