Function at 0x1000d29c4
Capabilities:
Check for peb beingdebugged flag

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x120
mov rax, qword [0x100165138]
xor rax, rsp
mov qword [rsp + 0x110], rax
mov rbp, qword [rsp + 0x188]
mov rbx, qword [rsp + 0x190]
xor edi, edi
mov r14, rdi
mov dword [rsp + 0x50], edi
mov byte [rsp + 0x40], dil
mov r12, r9
mov dword [rsp + 0x54], r8d
mov r13, rcx
mov rcx, qword [0x1001653b8]
lea r15, [0x1001653b8]
cmp rcx, r15
je 0x1000d2a7a
test byte [rcx + 0x1c], 4
je 0x1000d2a51
cmp byte [rcx + 0x19], 4
jb 0x1000d2a51
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003158]
mov edx, 0x1cb
call fcn.10001c854
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d2a7a
test byte [rcx + 0x1c], 4
je 0x1000d2a7a
cmp byte [rcx + 0x19], 5
jb 0x1000d2a7a
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003158]
mov edx, 0x1cc
mov r9, r13
call fcn.10001db08
xor r9d, r9d
mov qword [rsp + 0x30], rdi
lea rcx, [0x10000d400]
lea r8d, [r9 + 7]
mov edx, 0xc0000000
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rsp + 0x48], rax
cmp rax, 0xffffffffffffffff
jne 0x1000d2b6c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, 0x10
mov dword [rbx], eax
mov rcx, qword [0x1001653b8]
cmp rcx, r15
je 0x1000d2af4
test byte [rcx + 0x1c], 4
je 0x1000d2af4
cmp byte [rcx + 0x19], 2
jb 0x1000d2af4
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003158]
mov edx, 0x1cd
mov r9d, eax
call fcn.10001c878
mov r15, qword [rsp + 0x48]
lea rbx, [0x1001653b8]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [0x1001653b8]
cmp rcx, rbx
je 0x1000d2b3f
test byte [rcx + 0x1c], 4
je 0x1000d2b3f
cmp byte [rcx + 0x19], 4
jb 0x1000d2b3f
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003158]
mov edx, 0x1cf
call fcn.10001c854
mov eax, edi
mov rcx, qword [rsp + 0x110]
xor rcx, rsp
call fcn.10014e600
mov rbx, qword [rsp + 0x168]
add rsp, 0x120
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
lea rdx, [rsp + 0x58]
xor r9d, r9d
xor r8d, r8d
mov rcx, r13
call qword [sym.imp.ntdll.dll_RtlDosPathNameToNtPathName_U]
cmp al, dil
jne 0x1000d2b95
mov dword [rbx], 0x7b
mov edi, 2
jmp 0x1000d2af4
movzx esi, word [rsp + 0x58]
xor ecx, ecx
add esi, 0xc
mov edx, esi
mov r15d, esi
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov r14, rax
cmp rax, rdi
jne 0x1000d2be2
call qword [sym.imp.KERNEL32.dll_GetLastError]
xor edx, edx
mov dword [rbx], eax
mov rax, qword gs:[0x30]
mov r8, qword [rsp + 0x60]
mov rcx, qword [rax + 0x60]
mov rcx, qword [rcx + 0x30]
call qword [sym.imp.ntdll.dll_RtlFreeHeap]
mov edi, 3
jmp 0x1000d2af4
cmp rbp, 0xffffffffffffffff
je 0x1000d2c0c
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_ImpersonateLoggedOnUser]
cmp eax, edi
jne 0x1000d2c07
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, 0x13
mov dword [rbx], eax
jmp 0x1000d2af4
mov byte [rsp + 0x40], 1
mov r8, r15
xor edx, edx
mov rcx, r14
call sub.msvcrt.dll_memset
movzx r11d, word [rsp + 0x58]
mov eax, dword [rsp + 0x54]
mov word [r14], r11w
mov dword [r14 + 4], eax
mov byte [r14 + 2], 1
mov rdx, qword [rsp + 0x60]
lea rcx, [r14 + 0xa]
movzx r8d, r11w
call sub.msvcrt.dll_memcpy
mov r11, qword gs:[0x30]
mov r8, qword [rsp + 0x60]
mov rcx, qword [r11 + 0x60]
xor edx, edx
mov rcx, qword [rcx + 0x30]
call qword [sym.imp.ntdll.dll_RtlFreeHeap]
mov r15, qword [rsp + 0x48]
mov qword [rsp + 0x38], rdi
lea rax, [rsp + 0x50]
mov r9d, esi
mov r8, r14
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x80]
mov edx, 0x42c000
mov rcx, r15
mov dword [rsp + 0x28], 0x84
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov esi, eax
cmp byte [rsp + 0x40], dil
je 0x1000d2d02
cmp rbp, 0xffffffffffffffff
jne 0x1000d2cc4
lea r8, [0x10000d448]
lea rcx, [0x10000d020]
mov edx, 0x26a6
call fcn.10009a050
call qword [sym.imp.ADVAPI32.dll_RevertToSelf]
cmp eax, edi
jne 0x1000d2d02
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ecx, ax
mov dword [rbx], eax
or ecx, 0x80070000
cmp eax, edi
cmovle ecx, eax
cmp ecx, edi
jge 0x1000d2cf8
xor r9d, r9d
xor r8d, r8d
lea edx, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_RaiseException]
mov edi, 0x13
jmp 0x1000d2af9
cmp esi, edi
jne 0x1000d2d18
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, 0x11
mov dword [rbx], eax
jmp 0x1000d2af9
lea rdx, [0x100006030]
lea rcx, [rsp + 0x68]
call qword [sym.imp.ntdll.dll_RtlInitUnicodeString]
movzx ecx, word [rsp + 0x68]
movzx eax, word [rsp + 0x80]
add ecx, eax
cmp ecx, 0x208
jae 0x1000d2d8e
movzx ebx, word [rsp + 0x68]
mov rdx, qword [rsp + 0x70]
mov rcx, r12
mov r8, rbx
call sub.msvcrt.dll_memcpy
movzx r8d, word [rsp + 0x80]
shr rbx, 1
lea rcx, [r12 + rbx*2]
lea rdx, [rsp + 0x84]
call sub.msvcrt.dll_memcpy
movzx eax, word [rsp + 0x80]
movzx r11d, word [rsp + 0x68]
add eax, r11d
cdqe
shr rax, 1
mov word [r12 + rax*2], di
mov rcx, qword [0x1001653b8]
lea rbx, [0x1001653b8]
cmp rcx, rbx
je 0x1000d2b00
test byte [rcx + 0x1c], 4
je 0x1000d2b00
cmp byte [rcx + 0x19], 4
jb 0x1000d2b00
mov rcx, qword [rcx + 0x10]
lea r8, [0x100003158]
mov edx, 0x1ce
mov r9, r12
mov qword [rsp + 0x20], r13
call fcn.10001df74
jmp 0x1000d2b00