	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function CRYPT_BuildCandidateChainFromCert
_CRYPT_BuildCandidateChainFromCert:     ## @CRYPT_BuildCandidateChainFromCert
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -64(%rbp)                  ## 8-byte Spill
	movl	%r8d, -52(%rbp)                 ## 4-byte Spill
	movl	%ecx, %r15d
	movl	%edx, %r12d
	movl	%esi, %r13d
	movq	%rdi, %rbx
	movq	$0, -48(%rbp)
	movq	_CERT_STORE_PROV_COLLECTION@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_CERT_STORE_CREATE_NEW_FLAG@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%esi, %esi
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	callq	_CertOpenStore
	movl	%eax, %r14d
	movl	(%rbx), %esi
	movl	%eax, %edi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_CertAddStoreToCollection
	testl	%r15d, %r15d
	je	LBB0_2
## %bb.1:
	movl	%r14d, %edi
	movl	%r15d, %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_CertAddStoreToCollection
LBB0_2:
	leaq	-48(%rbp), %r9
	movq	%rbx, %rdi
	movl	%r14d, %esi
	movl	%r13d, %edx
	movl	%r12d, %ecx
	movl	-52(%rbp), %r8d                 ## 4-byte Reload
	callq	_CRYPT_GetSimpleChainForCert
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %r15
	movl	$72, %edi
	callq	_CryptMemAlloc
	movq	%rax, %rbx
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movl	$1, (%rbx)
	movl	%r14d, 64(%rbx)
	movl	$4, 8(%rbx)
	movq	-48(%rbp), %rax
	movl	(%rax), %eax
	movl	%eax, 56(%rbx)
	movl	$1, 12(%rbx)
	movl	$8, %edi
	callq	_CryptMemAlloc
	movq	%rax, 48(%rbx)
	movq	-48(%rbp), %rcx
	movq	%rcx, (%rax)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 32(%rbx)
	movq	_FALSE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 24(%rbx)
	movq	$0, 16(%rbx)
	jmp	LBB0_7
LBB0_3:
	xorl	%r15d, %r15d
	jmp	LBB0_8
LBB0_6:
	movq	-48(%rbp), %rdi
	callq	_CRYPT_FreeSimpleChain
	movq	_FALSE@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
LBB0_7:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	%rbx, (%rax)
LBB0_8:
	movq	%r15, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CERT_STORE_PROV_COLLECTION,4,2 ## @CERT_STORE_PROV_COLLECTION
	.comm	_CERT_STORE_CREATE_NEW_FLAG,4,2 ## @CERT_STORE_CREATE_NEW_FLAG
	.comm	_FALSE,8,3                      ## @FALSE
	.no_dead_strip	_CRYPT_BuildCandidateChainFromCert
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function CRYPT_BuildCandidateChainFromCert
lCPI0_0:
	.long	4                               ; 0x4
	.long	1                               ; 0x1
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_CRYPT_BuildCandidateChainFromCert:     ; @CRYPT_BuildCandidateChainFromCert
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	mov	x19, x5
	mov	x20, x4
	mov	x25, x3
	mov	x21, x2
	mov	x23, x1
	mov	x24, x0
	str	xzr, [sp, #8]
Lloh0:
	adrp	x8, _CERT_STORE_PROV_COLLECTION@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CERT_STORE_PROV_COLLECTION@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x8, _CERT_STORE_CREATE_NEW_FLAG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _CERT_STORE_CREATE_NEW_FLAG@GOTPAGEOFF]
Lloh5:
	ldr	w3, [x8]
	mov	w1, #0
	mov	w2, #0
	mov	x4, #0
	bl	_CertOpenStore
	mov	x22, x0
	ldr	w1, [x24]
	mov	w2, #0
	mov	w3, #0
	bl	_CertAddStoreToCollection
	cbz	w25, LBB0_2
; %bb.1:
	mov	x0, x22
	mov	x1, x25
	mov	w2, #0
	mov	w3, #0
	bl	_CertAddStoreToCollection
LBB0_2:
	add	x5, sp, #8
	mov	x0, x24
	mov	x1, x22
	mov	x2, x23
	mov	x3, x21
	mov	x4, x20
	bl	_CRYPT_GetSimpleChainForCert
	mov	x20, x0
	cbz	x0, LBB0_7
; %bb.3:
	mov	w0, #72
	bl	_CryptMemAlloc
	mov	x21, x0
	cbz	x0, LBB0_5
; %bb.4:
	mov	w8, #1
	str	w8, [x21]
	str	w22, [x21, #64]
	ldr	x8, [sp, #8]
	ldr	w8, [x8]
	str	w8, [x21, #56]
Lloh6:
	adrp	x8, lCPI0_0@PAGE
Lloh7:
	ldr	d0, [x8, lCPI0_0@PAGEOFF]
	str	d0, [x21, #8]
	mov	w0, #8
	bl	_CryptMemAlloc
	str	x0, [x21, #48]
	ldr	x8, [sp, #8]
	str	x8, [x0]
	stp	xzr, xzr, [x21, #32]
Lloh8:
	adrp	x8, _FALSE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	stp	xzr, x8, [x21, #16]
	b	LBB0_6
LBB0_5:
	ldr	x0, [sp, #8]
	bl	_CRYPT_FreeSimpleChain
Lloh11:
	adrp	x8, _FALSE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh13:
	ldr	x20, [x8]
LBB0_6:
	str	x21, [x19]
LBB0_7:
	mov	x0, x20
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdr	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_CERT_STORE_PROV_COLLECTION,4,2 ; @CERT_STORE_PROV_COLLECTION
	.comm	_CERT_STORE_CREATE_NEW_FLAG,4,2 ; @CERT_STORE_CREATE_NEW_FLAG
	.comm	_FALSE,8,3                      ; @FALSE
	.no_dead_strip	_CRYPT_BuildCandidateChainFromCert
.subsections_via_symbols
