	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CreateNestedKey                ## -- Begin function CreateNestedKey
	.p2align	4, 0x90
_CreateNestedKey:                       ## @CreateNestedKey
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r9d
	movq	%rdx, %r14
	movq	%rdi, %r15
	movq	_KEY_ALL_ACCESS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-76(%rbp), %rax
	movq	%rax, (%rsp)
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	movl	%r9d, -84(%rbp)                 ## 4-byte Spill
	callq	_NtCreateKey
	movq	%rax, %rbx
	movq	(%r14), %rsi
	leaq	L_.str(%rip), %rdi
	movq	%rax, %rdx
	callq	_DPRINT
	movq	_STATUS_OBJECT_NAME_NOT_FOUND@GOTPCREL(%rip), %r12
	cmpq	(%r12), %rbx
	jne	LBB0_1
## %bb.3:
	movq	%r15, -96(%rbp)                 ## 8-byte Spill
	leaq	-72(%rbp), %rdi
	movq	%r14, %rsi
	movl	$8, %edx
	callq	_RtlCopyMemory
	movq	(%r14), %rax
	movq	(%rax), %rsi
	leaq	-64(%rbp), %r14
	movq	%r14, %rdi
	callq	_RtlCreateUnicodeString
	movq	%r14, -72(%rbp)
	movl	-56(%rbp), %eax
	movl	%eax, -80(%rbp)                 ## 4-byte Spill
	cmpq	(%r12), %rbx
	jne	LBB0_12
## %bb.4:
	leaq	-72(%rbp), %r13
	leaq	L_.str(%rip), %r14
	leaq	-64(%rbp), %r15
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_5 Depth=1
	cmpq	%rcx, %rbx
	jne	LBB0_12
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	-64(%rbp), %rdi
	movl	$92, %esi
	callq	_wcsrchr
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	-64(%rbp), %rdi
	cmpq	%rdi, %rax
	je	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	$0, (%rax)
	callq	_wcslen
	shll	$2, %eax
	movl	%eax, -56(%rbp)
	movq	_KEY_CREATE_SUB_KEY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_REG_OPTION_NON_VOLATILE@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	leaq	-76(%rbp), %rax
	movq	%rax, (%rsp)
	leaq	-44(%rbp), %rdi
	movq	%r13, %rdx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_NtCreateKey
	movq	%rax, %rbx
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rax, %rdx
	callq	_DPRINT
	movq	%rbx, %rdi
	callq	_NT_SUCCESS
	movq	(%r12), %rcx
	testl	%eax, %eax
	jne	LBB0_11
## %bb.9:                               ##   in Loop: Header=BB0_5 Depth=1
	cmpq	%rcx, %rbx
	je	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_5 Depth=1
	movq	-72(%rbp), %rsi
	leaq	L_.str.1(%rip), %rdi
	movq	%rbx, %rdx
	callq	_DPRINT1
	movq	(%r12), %rcx
	jmp	LBB0_11
LBB0_1:
	movq	%rbx, %rdi
	callq	_NT_SUCCESS
	testl	%eax, %eax
	jne	LBB0_21
## %bb.2:
	movq	(%r14), %rsi
	leaq	L_.str.1(%rip), %rdi
	movq	%rbx, %rdx
	callq	_DPRINT1
	jmp	LBB0_21
LBB0_7:
	movq	_STATUS_UNSUCCESSFUL@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
LBB0_12:
	movq	%rbx, %rdi
	callq	_NT_SUCCESS
	testl	%eax, %eax
	je	LBB0_20
## %bb.13:
	movq	_TRUE@GOTPCREL(%rip), %r14
	cmpq	$0, (%r14)
	je	LBB0_20
## %bb.14:
	leaq	-72(%rbp), %r15
	leaq	L_.str(%rip), %r12
	leaq	-64(%rbp), %r13
	.p2align	4, 0x90
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movl	-80(%rbp), %eax                 ## 4-byte Reload
	cmpl	%eax, -56(%rbp)
	je	LBB0_17
## %bb.18:                              ##   in Loop: Header=BB0_16 Depth=1
	movl	-44(%rbp), %edi
	callq	_NtClose
	movq	-64(%rbp), %rdi
	movslq	-56(%rbp), %rax
	andq	$-4, %rax
	movl	$92, (%rdi,%rax)
	callq	_wcslen
	shll	$2, %eax
	movl	%eax, -56(%rbp)
	movq	_KEY_ALL_ACCESS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-76(%rbp), %rax
	movq	%rax, (%rsp)
	leaq	-44(%rbp), %rdi
	movq	%r15, %rdx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	movl	-84(%rbp), %r9d                 ## 4-byte Reload
	callq	_NtCreateKey
	movq	%rax, %rbx
	movq	%r12, %rdi
	movq	%r13, %rsi
	movq	%rax, %rdx
	callq	_DPRINT
	movq	%rbx, %rdi
	callq	_NT_SUCCESS
	testl	%eax, %eax
	je	LBB0_19
## %bb.15:                              ##   in Loop: Header=BB0_16 Depth=1
	cmpq	$0, (%r14)
	jne	LBB0_16
	jmp	LBB0_20
LBB0_17:
	movq	_STATUS_SUCCESS@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	movl	-44(%rbp), %eax
	movq	-96(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, (%rcx)
	jmp	LBB0_20
LBB0_19:
	movq	-72(%rbp), %rsi
	leaq	L_.str.1(%rip), %rdi
	movq	%rbx, %rdx
	callq	_DPRINT1
LBB0_20:
	leaq	-64(%rbp), %rdi
	callq	_RtlFreeUnicodeString
LBB0_21:
	movq	%rbx, %rax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_KEY_ALL_ACCESS,4,2             ## @KEY_ALL_ACCESS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"NtCreateKey(%wZ) called (Status %lx)\n"

	.comm	_STATUS_OBJECT_NAME_NOT_FOUND,8,3 ## @STATUS_OBJECT_NAME_NOT_FOUND
L_.str.1:                               ## @.str.1
	.asciz	"CreateNestedKey: NtCreateKey(%wZ) failed (Status %lx)\n"

	.comm	_STATUS_UNSUCCESSFUL,8,3        ## @STATUS_UNSUCCESSFUL
	.comm	_KEY_CREATE_SUB_KEY,4,2         ## @KEY_CREATE_SUB_KEY
	.comm	_REG_OPTION_NON_VOLATILE,4,2    ## @REG_OPTION_NON_VOLATILE
	.comm	_TRUE,8,3                       ## @TRUE
	.comm	_STATUS_SUCCESS,8,3             ## @STATUS_SUCCESS
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CreateNestedKey                ; -- Begin function CreateNestedKey
	.p2align	2
_CreateNestedKey:                       ; @CreateNestedKey
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x3
	mov	x22, x2
	mov	x19, x0
Lloh0:
	adrp	x24, _KEY_ALL_ACCESS@GOTPAGE
Lloh1:
	ldr	x24, [x24, _KEY_ALL_ACCESS@GOTPAGEOFF]
	ldr	w1, [x24]
	add	x6, sp, #4
	mov	w3, #0
	mov	x4, #0
	mov	x5, x20
	bl	_NtCreateKey
	mov	x21, x0
	ldr	x1, [x22]
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
	mov	x2, x21
	bl	_DPRINT
Lloh4:
	adrp	x26, _STATUS_OBJECT_NAME_NOT_FOUND@GOTPAGE
Lloh5:
	ldr	x26, [x26, _STATUS_OBJECT_NAME_NOT_FOUND@GOTPAGEOFF]
	ldr	x8, [x26]
	cmp	x21, x8
	b.ne	LBB0_7
; %bb.1:
	add	x0, sp, #24
	mov	x1, x22
	mov	w2, #8
	bl	_RtlCopyMemory
	ldr	x8, [x22]
	ldr	x1, [x8]
	add	x22, sp, #8
	add	x0, sp, #8
	bl	_RtlCreateUnicodeString
	str	x22, [sp, #24]
	ldr	w25, [sp, #16]
	ldr	x8, [x26]
	cmp	x21, x8
	b.ne	LBB0_10
; %bb.2:
Lloh6:
	adrp	x27, _KEY_CREATE_SUB_KEY@GOTPAGE
Lloh7:
	ldr	x27, [x27, _KEY_CREATE_SUB_KEY@GOTPAGEOFF]
Lloh8:
	adrp	x28, _REG_OPTION_NON_VOLATILE@GOTPAGE
Lloh9:
	ldr	x28, [x28, _REG_OPTION_NON_VOLATILE@GOTPAGEOFF]
Lloh10:
	adrp	x22, l_.str@PAGE
Lloh11:
	add	x22, x22, l_.str@PAGEOFF
Lloh12:
	adrp	x23, l_.str.1@PAGE
Lloh13:
	add	x23, x23, l_.str.1@PAGEOFF
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	cmp	x21, x8
	b.ne	LBB0_10
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [sp, #8]
	mov	w1, #92
	bl	_wcsrchr
	mov	x8, x0
	ldr	x0, [sp, #8]
	cmp	x8, #0
	ccmp	x8, x0, #4, ne
	b.eq	LBB0_9
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	str	wzr, [x8]
	bl	_wcslen
	lsl	w8, w0, #2
	str	w8, [sp, #16]
	ldr	w1, [x27]
	ldr	w5, [x28]
	mov	x0, sp
	add	x2, sp, #24
	add	x6, sp, #4
	mov	w3, #0
	mov	x4, #0
	bl	_NtCreateKey
	mov	x21, x0
	add	x1, sp, #8
	mov	x0, x22
	mov	x2, x21
	bl	_DPRINT
	mov	x0, x21
	bl	_NT_SUCCESS
	ldr	x8, [x26]
	cmp	w0, #0
	ccmp	x21, x8, #4, eq
	b.eq	LBB0_3
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x1, [sp, #24]
	mov	x0, x23
	mov	x2, x21
	bl	_DPRINT1
	ldr	x8, [x26]
	b	LBB0_3
LBB0_7:
	mov	x0, x21
	bl	_NT_SUCCESS
	cbnz	w0, LBB0_19
; %bb.8:
	ldr	x1, [x22]
Lloh14:
	adrp	x0, l_.str.1@PAGE
Lloh15:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x2, x21
	bl	_DPRINT1
	b	LBB0_19
LBB0_9:
Lloh16:
	adrp	x8, _STATUS_UNSUCCESSFUL@GOTPAGE
Lloh17:
	ldr	x8, [x8, _STATUS_UNSUCCESSFUL@GOTPAGEOFF]
Lloh18:
	ldr	x21, [x8]
LBB0_10:
	mov	x0, x21
	bl	_NT_SUCCESS
	cbz	w0, LBB0_18
; %bb.11:
Lloh19:
	adrp	x23, _TRUE@GOTPAGE
Lloh20:
	ldr	x23, [x23, _TRUE@GOTPAGEOFF]
	ldr	x8, [x23]
	cbz	x8, LBB0_18
; %bb.12:
	mov	w26, #92
Lloh21:
	adrp	x22, l_.str@PAGE
Lloh22:
	add	x22, x22, l_.str@PAGEOFF
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	w8, [sp, #16]
	cmp	w8, w25
	b.eq	LBB0_16
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	w0, [sp]
	bl	_NtClose
	ldr	x0, [sp, #8]
	ldrsw	x8, [sp, #16]
	and	x8, x8, #0xfffffffffffffffc
	str	w26, [x0, x8]
	bl	_wcslen
	lsl	w8, w0, #2
	str	w8, [sp, #16]
	ldr	w1, [x24]
	mov	x0, sp
	add	x2, sp, #24
	add	x6, sp, #4
	mov	w3, #0
	mov	x4, #0
	mov	x5, x20
	bl	_NtCreateKey
	mov	x21, x0
	add	x1, sp, #8
	mov	x0, x22
	mov	x2, x21
	bl	_DPRINT
	mov	x0, x21
	bl	_NT_SUCCESS
	cbz	w0, LBB0_17
; %bb.15:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x8, [x23]
	cbnz	x8, LBB0_13
	b	LBB0_18
LBB0_16:
Lloh23:
	adrp	x8, _STATUS_SUCCESS@GOTPAGE
Lloh24:
	ldr	x8, [x8, _STATUS_SUCCESS@GOTPAGEOFF]
Lloh25:
	ldr	x21, [x8]
	ldr	w8, [sp]
	str	w8, [x19]
	b	LBB0_18
LBB0_17:
	ldr	x1, [sp, #24]
Lloh26:
	adrp	x0, l_.str.1@PAGE
Lloh27:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x2, x21
	bl	_DPRINT1
LBB0_18:
	add	x0, sp, #8
	bl	_RtlFreeUnicodeString
LBB0_19:
	mov	x0, x21
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_KEY_ALL_ACCESS,4,2             ; @KEY_ALL_ACCESS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"NtCreateKey(%wZ) called (Status %lx)\n"

	.comm	_STATUS_OBJECT_NAME_NOT_FOUND,8,3 ; @STATUS_OBJECT_NAME_NOT_FOUND
l_.str.1:                               ; @.str.1
	.asciz	"CreateNestedKey: NtCreateKey(%wZ) failed (Status %lx)\n"

	.comm	_STATUS_UNSUCCESSFUL,8,3        ; @STATUS_UNSUCCESSFUL
	.comm	_KEY_CREATE_SUB_KEY,4,2         ; @KEY_CREATE_SUB_KEY
	.comm	_REG_OPTION_NON_VOLATILE,4,2    ; @REG_OPTION_NON_VOLATILE
	.comm	_TRUE,8,3                       ; @TRUE
	.comm	_STATUS_SUCCESS,8,3             ; @STATUS_SUCCESS
.subsections_via_symbols
