Function at 0x140012ca0
Capabilities:
Check if file exists
Read file via mapping

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x58
mov rbx, r9
mov r14, r8
mov r15, rdx
mov rsi, rcx
mov rax, qword [0x1402cb038]
xor rax, rsp
mov qword [rsp + 0x50], rax
cmp dword [rcx + 0x10], 0
mov rcx, qword [rcx]
je 0x1400132ee
movabs r13, 0xaaaaaaaaaaaaaaaa
lea r8, [rsp + 0x40]
mov dword [r8], 0
lea rdi, [rsp + 0x48]
mov qword [rdi], r13
mov qword [rsp + 0x20], rdi
lea rdx, str.DNASYXOB
mov r9d, 4
call qword [sym.imp.KERNEL32.dll_ReadProcessMemory]
mov r12d, 0x42
test eax, eax
je 0x14001316f
cmp qword [rsp + 0x48], 4
jne 0x1400131bb
mov eax, dword [rsp + 0x40]
cmp eax, dword [str.DNASYXOB]
jne 0x1400131b3
mov rcx, qword [rsi]
mov qword [rsp + 0x20], rdi
lea rdx, [0x1402dabf0]
lea r8, [rsp + 0x40]
mov r9d, 4
call qword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
je 0x14001316f
cmp qword [rsp + 0x48], 4
mov r12d, 0x43
jne 0x14001316f
mov eax, dword [rsp + 0x40]
mov r12d, 0x44
cmp eax, dword [0x1402dabf0]
jne 0x14001316f
mov ebp, dword [rsp + 0xc0]
cmp byte [r14 + 0x10], 0
mov rdi, rbp
je 0x140012d9f
mov rdi, qword [r14]
add rdi, rbp
cmp byte [rbx + 0x10], 0
je 0x140012da8
add rdi, qword [rbx]
mov qword [rsp + 0x38], r15
mov rax, rdi
shr rax, 0x20
jne 0x140013392
mov dword [rsp + 0x20], edi
mov qword [rsp + 0x28], 0
mov rcx, 0xffffffffffffffff
xor edx, edx
mov r8d, 0x8000004
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov r15, rax
cmp qword [rsi + 0x28], rax
je 0x140012e24
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r12d, eax
mov rax, qword [rsi + 0x28]
inc rax
cmp rax, 2
jae 0x140013190
mov rax, r15
inc rax
cmp rax, 2
jb 0x140012e17
mov qword [rsi + 0x28], r15
call fcn.14017a3f0
mov ecx, r12d
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov r15, qword [rsi + 0x28]
mov r12, qword [rsp + 0xc8]
lea rax, [r15 + 1]
cmp rax, 1
jbe 0x14001323c
mov qword [rsp + 0x20], 0
mov rcx, r15
mov edx, 6
xor r8d, r8d
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
test rax, rax
je 0x14001326c
mov r15, rax
cmp byte [r14 + 0x10], 0
mov r12, rbp
je 0x140012f11
mov r8, qword [r14]
test r8, r8
je 0x140013398
lea r12, [r15 + rbp]
mov r13, qword [r14 + 8]
mov rcx, r12
mov rdx, r13
call fcn.1401d0030
xor eax, eax
pxor xmm0, xmm0
pcmpeqd xmm1, xmm1
jmp 0x140012eb8
pshufd xmm2, xmm2, 0xee
movq rcx, xmm2
sub rcx, r13
mov qword [r12 + rax*8 + 8], rcx
add rax, 2
cmp rax, 0x40
je 0x140012ef6
movdqu xmm2, xmmword [r12 + rax*8]
movdqa xmm4, xmm2
pcmpeqd xmm4, xmm0
pshufd xmm3, xmm4, 0xb1
pand xmm3, xmm4
movd ecx, xmm3
not ecx
test cl, 1
je 0x140012ee6
movq rcx, xmm2
sub rcx, r13
mov qword [r12 + rax*8], rcx
pxor xmm3, xmm1
pextrw ecx, xmm3, 4
test cl, 1
je 0x140012eae
jmp 0x140012e9c
cmp byte [r14 + 0x10], 0
je 0x1400133a0
mov r12, qword [r14]
movabs r13, 0xaaaaaaaaaaaaaaaa
add r12, rbp
cmp byte [rbx + 0x10], 0
je 0x140012f34
lea rcx, [r15 + r12]
mov r8, qword [rbx]
mov rdx, qword [rbx + 8]
call fcn.1401d0030
cmp byte [rbx + 0x10], 0
je 0x1400133a0
add r12, qword [rbx]
cmp r12, rdi
jne 0x140013395
mov qword [0x1402e6180], rbp
cmp dword [rsi + 0x10], 0
mov rcx, qword [rsi]
je 0x140013340
mov qword [rsp + 0x48], r13
lea rbp, [rsp + 0x48]
mov qword [rsp + 0x20], rbp
lea rdx, [0x1402e6180]
mov r9d, 8
mov r8, rdx
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x1400131c3
cmp qword [rsp + 0x48], 8
jne 0x1400131cb
mov qword [0x1402e6180], 0
cmp byte [r14 + 0x10], 0
je 0x140012ff2
mov rax, qword [r14]
mov qword [0x1402e6188], rax
cmp dword [rsi + 0x10], 0
mov rcx, qword [rsi]
je 0x140013317
mov qword [rsp + 0x48], r13
mov qword [rsp + 0x20], rbp
lea rdx, [0x1402e6188]
mov r9d, 8
mov r8, rdx
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x14001321a
cmp qword [rsp + 0x48], 8
jne 0x140013222
mov qword [0x1402e6188], 0
cmp byte [rbx + 0x10], 0
je 0x14001304e
mov rax, qword [rbx]
mov qword [0x1402e6190], rax
cmp dword [rsi + 0x10], 0
mov rcx, qword [rsi]
je 0x140013369
mov qword [rsp + 0x48], r13
mov qword [rsp + 0x20], rbp
lea rdx, [0x1402e6190]
mov r9d, 8
mov r8, rdx
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x1400132a0
cmp qword [rsp + 0x48], 8
jne 0x1400132a8
mov qword [0x1402e6190], 0
mov r14d, dword [rsi + 0x10]
mov r12, qword [rsi]
mov ecx, 0x40
call fcn.1401cbbc4
mov rbx, rax
mov r9, qword [rsi + 0x40]
mov rax, qword [rsp + 0x38]
mov qword [rsp + 0x20], rax
mov rcx, rbx
mov rdx, r12
mov r8d, r14d
call fcn.1400133d0
mov rdi, qword [rsi + 0x38]
mov qword [rsi + 0x38], rbx
test rdi, rdi
jne 0x140013287
mov rcx, rbx
mov rdx, r15
mov r8d, dword [rsp + 0xc0]
mov r9d, 0x400
call fcn.140013480
test al, al
je 0x1400131ab
lea rdi, [rsp + 0x40]
mov qword [rdi], r13
mov rbx, qword [rsi]
mov r14, qword [rsi + 0x28]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
xor ecx, ecx
mov dword [rsp + 0x30], ecx
mov dword [rsp + 0x28], ecx
mov dword [rsp + 0x20], 7
mov rcx, rax
mov rdx, r14
mov r8, rbx
mov r9, rdi
call qword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
je 0x140013251
mov rax, qword [rsp + 0x40]
mov qword [0x1402e5e78], rax
cmp dword [rsi + 0x10], 0
mov rcx, qword [rsi]
je 0x1400132c5
mov qword [rsp + 0x48], r13
mov qword [rsp + 0x20], rbp
lea rdx, [0x1402e5e78]
mov r9d, 8
mov r8, rdx
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x1400131f8
cmp qword [rsp + 0x48], 8
jne 0x140013200
xor r12d, r12d
mov qword [0x1402e5e78], r12
mov dword [rsi + 0x14], 0
mov rdi, qword [rsi + 8]
mov qword [rsi + 8], r12
lea rax, [rdi + 1]
cmp rax, 2
jb 0x140013166
call fcn.14017a3f0
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x50]
xor rcx, rsp
call fcn.1401ce5b0
mov eax, r12d
add rsp, 0x58
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
call fcn.14017a3f0
mov rcx, qword [rsi + 0x28]
call fcn.14017b060
mov qword [rsi + 0x28], 0
jmp 0x140012e02
mov r12d, 4
jmp 0x14001316f
mov r12d, 0x44
jmp 0x14001316f
mov r12d, 0x43
jmp 0x14001316f
mov r12d, 0x39
jmp 0x1400131d1
mov r12d, 0x3a
xor ecx, ecx
call fcn.14025ecb0
mov qword [0x1402e6180], 0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0xc8]
mov dword [rcx], eax
jmp 0x14001316f
mov r12d, 0x39
jmp 0x140013206
mov r12d, 0x3a
xor ecx, ecx
call fcn.14025ecb0
mov qword [0x1402e5e78], 0
jmp 0x1400131e3
mov r12d, 0x39
jmp 0x140013228
mov r12d, 0x3a
xor ecx, ecx
call fcn.14025ecb0
mov qword [0x1402e6188], 0
jmp 0x1400131e3
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [r12], eax
mov r12d, 0x19
jmp 0x14001316f
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0xc8]
mov dword [rcx], eax
mov r12d, 0x1a
jmp 0x14001316f
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0xc8]
mov dword [rcx], eax
mov r12d, 0x1b
jmp 0x14001316f
mov rcx, rdi
call fcn.14006a550
mov rcx, rdi
call fcn.1401cbbbc
mov rbx, qword [rsi + 0x38]
jmp 0x14001308f
mov r12d, 0x39
jmp 0x1400132ae
mov r12d, 0x3a
xor ecx, ecx
call fcn.14025ecb0
mov qword [0x1402e6190], 0
jmp 0x1400131e3
test rcx, rcx
jne 0x14001310a
cmp dword [rsi + 0x14], 0
jne 0x14001310a
mov r12d, 8
cmp qword [rsi + 8], 0
jne 0x14001310a
jmp 0x14001320d
test rcx, rcx
jne 0x140012cd8
cmp dword [rsi + 0x14], 0
jne 0x140012cd8
mov r12d, 8
cmp qword [rsi + 8], 0
jne 0x140012cd8
jmp 0x14001316f
test rcx, rcx
jne 0x140012fb3
cmp dword [rsi + 0x14], 0
jne 0x140012fb3
mov r12d, 8
cmp qword [rsi + 8], 0
jne 0x140012fb3
jmp 0x14001322f
test rcx, rcx
jne 0x140012f51
cmp dword [rsi + 0x14], 0
jne 0x140012f51
mov r12d, 8
cmp qword [rsi + 8], 0
jne 0x140012f51
jmp 0x1400131d8
test rcx, rcx
jne 0x14001300f
cmp dword [rsi + 0x14], 0
jne 0x14001300f
mov r12d, 8
cmp qword [rsi + 8], 0
jne 0x14001300f
jmp 0x1400132b5
int3
int3
xor r12d, r12d
jmp 0x140012f04
lea rax, str.optional_operator___called_on_a_disengaged_value
mov qword [rsp + 0x20], rax
lea rcx, str._s:_d:_assertion__s_failed:__s_n
lea rdx, str....._third_partylibc_srcincludeoptional
lea r9, str.this__has_value__
mov r8d, 0x3f4
call fcn.140207060
int3