Function at 0x170043cb0
Capabilities:
Check for peb beingdebugged flag

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x2a8
lea rbp, [rsp + 0x80]
and rsp, 0xfffffffffffffff0
mov rsi, r9
mov r15, r8
mov r13, rdx
mov rbx, rcx
test byte [0x17008d6c0], 8
je 0x170043d18
mov rcx, rbx
call fcn.170044180
mov qword [rsp + 0x38], rsi
mov qword [rsp + 0x30], r15
mov qword [rsp + 0x28], r13
mov qword [rsp + 0x20], rax
lea r8, [0x1700770ce]
lea r9, str.__s__p__p__p__n
mov ecx, 3
call fcn.170044100
test rsi, rsi
je 0x170043d49
test byte [0x17008d6c0], 1
je 0x170043d3b
lea r8, [0x1700770ce]
lea r9, str.Unsupported_parameter_n
xor ecx, ecx
call fcn.170044100
xorps xmm0, xmm0
movups xmmword [rsi], xmm0
mov qword [rsi + 0x10], 0
mov esi, 0xc0000033
test rbx, rbx
je 0x1700440e7
cmp word [rbx], 0
je 0x1700440e7
movabs rax, 0x5c003f003f005c
lea rcx, [rax + 0x1d0000]
cmp qword [rbx], rcx
je 0x170043e2a
cmp qword [rbx], rax
je 0x170043e1f
lea rdx, [0x1700770ae]
mov rcx, rbx
call sym.ntdll.dll__wcsicmp
test eax, eax
je 0x170043e2a
mov rcx, rbx
call sym.ntdll.dll_RtlIsDosDeviceName_U
cmp eax, 0x10000
jae 0x170043ec2
lea r14, [rsp + 0xa0]
mov rcx, rbx
mov edx, 0x208
mov r8, r14
mov r9, r15
call sym.ntdll.dll_RtlGetFullPathName_U
test eax, eax
je 0x1700440e7
mov r12d, eax
cmp eax, 0x209
jb 0x170043ff1
mov r8d, r12d
mov rax, qword gs:[0x30]
mov rax, qword [rax + 0x60]
mov rcx, qword [rax + 0x30]
xor edx, edx
call sym.ntdll.dll_RtlAllocateHeap
test rax, rax
je 0x170043ef5
mov r14, rax
mov rcx, rbx
mov edx, r12d
mov r8, rax
mov r9, r15
call sym.ntdll.dll_RtlGetFullPathName_U
mov r12d, eax
jmp 0x170043ff1
cmp word [rbx + 8], 0
je 0x170043d84
mov rcx, rbx
call sym.ntdll.dll_wcslen
lea ecx, [rax + rax]
mov word [r13], cx
add eax, eax
add eax, 2
mov word [r13 + 2], ax
mov rcx, qword gs:[0x30]
mov rcx, qword [rcx + 0x60]
mov rcx, qword [rcx + 0x30]
movzx r8d, ax
xor esi, esi
xor edx, edx
call sym.ntdll.dll_RtlAllocateHeap
mov qword [r13 + 8], rax
test rax, rax
je 0x170043ef5
mov rdi, rax
movzx r8d, word [r13 + 2]
mov rcx, rax
mov rdx, rbx
call sym.ntdll.dll_memcpy
mov dword [rdi + 2], 0x3f003f
test r15, r15
je 0x1700440e7
mov rcx, rdi
mov dx, 0x5c
call sym.ntdll.dll_wcsrchr
test rax, rax
je 0x170043eb6
cmp word [rax + 2], 0
je 0x170043eb6
add rax, 2
mov qword [r15], rax
jmp 0x1700440e7
mov qword [r15], 0
jmp 0x1700440e7
mov r12d, eax
mov esi, eax
shr esi, 0x10
cmp eax, 0x2070000
jb 0x170043eff
lea r8d, [rsi + 2]
mov rax, qword gs:[0x30]
mov rax, qword [rax + 0x60]
mov rcx, qword [rax + 0x30]
xor edx, edx
call sym.ntdll.dll_RtlAllocateHeap
mov r14, rax
test rax, rax
jne 0x170043f07
mov esi, 0xc0000017
jmp 0x1700440e7
lea r14, [rsp + 0xa0]
mov rcx, r14
mov rdx, rbx
mov r8, rsi
call sym.ntdll.dll_memcpy
shr rsi, 1
mov word [r14 + rsi*2], 0
lea rdi, [rsp + 0x90]
mov rcx, r14
mov rdx, rdi
xor r8d, r8d
xor r9d, r9d
call sym.ntdll.dll_RtlDosPathNameToNtPathName_U_WithStatus
test eax, eax
jne 0x170043f9c
mov dword [rsp + 0x50], 0x30
mov qword [rsp + 0x58], 0
mov dword [rsp + 0x68], 0x40
mov qword [rsp + 0x60], rdi
xorps xmm0, xmm0
movups xmmword [rsp + 0x70], xmm0
mov dword [rsp + 0x28], 0x21
mov dword [rsp + 0x20], 7
lea rcx, [rsp + 0x48]
lea r8, [rsp + 0x50]
lea r9, [rsp + 0x80]
mov edx, 0x100080
call sym.ntdll.dll_NtOpenFile
mov rcx, rdi
mov edi, eax
call sym.ntdll.dll_RtlFreeUnicodeString
test edi, edi
je 0x170043fa6
mov esi, 0xc0000033
jmp 0x1700440bf
mov rcx, qword [rsp + 0x48]
call sym.ntdll.dll_NtClose
test r15, r15
je 0x170043fbc
mov qword [r15], 0
movzx r12d, r12w
lea rdx, str.._
mov rcx, r14
call sym.ntdll.dll_wcscpy
lea rcx, [r14 + 8]
lea rdx, [rbx + rsi*2]
mov r8, r12
call sym.ntdll.dll_memcpy
mov eax, r12d
and eax, 0xfffffffe
mov word [rax + r14 + 8], 0
add r12d, 8
add r12d, 0x12
mov esi, 0xc0000033
cmp r12d, 0xffff
ja 0x1700440bf
mov word [r13 + 2], r12w
mov rax, qword gs:[0x30]
mov rax, qword [rax + 0x60]
mov rcx, qword [rax + 0x30]
mov r8d, r12d
xor edx, edx
call sym.ntdll.dll_RtlAllocateHeap
mov qword [r13 + 8], rax
test rax, rax
je 0x170044068
lea rdx, str.___
mov rcx, rax
call sym.ntdll.dll_wcscpy
mov rcx, r14
call sym.ntdll.dll_RtlDetermineDosPathNameType_U
cmp eax, 6
je 0x17004406f
cmp eax, 1
jne 0x170044076
mov rcx, qword [r13 + 8]
lea rdx, str.UNC_
call sym.ntdll.dll_wcscat
mov eax, 2
jmp 0x170044078
mov esi, 0xc0000017
jmp 0x1700440bf
mov eax, 4
jmp 0x170044078
xor eax, eax
mov rcx, qword [r13 + 8]
lea rdx, [r14 + rax*2]
call sym.ntdll.dll_wcscat
mov r12, qword [r13 + 8]
mov rcx, r12
call sym.ntdll.dll_wcslen
mov rbx, rax
add eax, eax
mov word [r13], ax
xor esi, esi
test r15, r15
je 0x1700440bf
mov rcx, qword [r15]
test rcx, rcx
je 0x1700440bf
and ebx, 0x7fff
call sym.ntdll.dll_wcslen
sub rbx, rax
lea rax, [r12 + rbx*2]
mov qword [r15], rax
lea rax, [rsp + 0xa0]
cmp r14, rax
je 0x1700440e7
mov rax, qword gs:[0x30]
mov rax, qword [rax + 0x60]
mov rcx, qword [rax + 0x30]
xor edx, edx
mov r8, r14
call sym.ntdll.dll_RtlFreeHeap
mov eax, esi
lea rsp, [rbp + 0x228]
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret