	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CRYPT_IsCertificateSelfSigned  ## -- Begin function CRYPT_IsCertificateSelfSigned
	.p2align	4, 0x90
_CRYPT_IsCertificateSelfSigned:         ## @CRYPT_IsCertificateSelfSigned
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	_szOID_AUTHORITY_KEY_IDENTIFIER2@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	(%r14), %rax
	movl	20(%rax), %edx
	movl	24(%rax), %esi
	callq	_CertFindExtension
	testq	%rax, %rax
	je	LBB0_10
## %bb.1:
	movl	8(%r14), %edi
	movq	_X509_AUTHORITY_KEY_ID2@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	(%rax), %ecx
	movl	4(%rax), %edx
	movq	_CRYPT_DECODE_ALLOC_FLAG@GOTPCREL(%rip), %rax
	movq	_CRYPT_DECODE_NOCOPY_FLAG@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r8d
	orl	(%rax), %r8d
	leaq	-48(%rbp), %rax
	leaq	-40(%rbp), %r10
	xorl	%ebx, %ebx
	xorl	%r9d, %r9d
	pushq	%rax
	pushq	%r10
	callq	_CryptDecodeObjectEx
	addq	$16, %rsp
	testl	%eax, %eax
	je	LBB0_33
## %bb.2:
	movq	-40(%rbp), %rcx
	movq	40(%rcx), %rax
	testq	%rax, %rax
	je	LBB0_18
## %bb.3:
	cmpq	$0, 32(%rcx)
	je	LBB0_18
## %bb.4:
	movq	48(%rcx), %rcx
	movq	_CERT_ALT_NAME_DIRECTORY_NAME@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	leaq	-8(%rcx), %rdi
	incq	%rax
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	decq	%rax
	je	LBB0_30
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	leaq	16(%rdi), %rsi
	cmpq	%rdx, 8(%rdi)
	movq	%rsi, %rdi
	jne	LBB0_5
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	%rsi, %rdi
	testq	%rcx, %rcx
	je	LBB0_5
## %bb.8:
	movl	8(%r14), %edi
	movq	(%r14), %rdx
	callq	_CertCompareCertificateName
	testq	%rax, %rax
	je	LBB0_31
## %bb.9:
	movq	-40(%rbp), %rdi
	addq	$32, %rdi
	jmp	LBB0_16
LBB0_10:
	movq	_szOID_AUTHORITY_KEY_IDENTIFIER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	(%r14), %rax
	movl	20(%rax), %edx
	movl	24(%rax), %esi
	callq	_CertFindExtension
	testq	%rax, %rax
	je	LBB0_24
## %bb.11:
	movl	8(%r14), %edi
	movq	_X509_AUTHORITY_KEY_ID@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	(%rax), %ecx
	movl	4(%rax), %edx
	movq	_CRYPT_DECODE_ALLOC_FLAG@GOTPCREL(%rip), %rax
	movq	_CRYPT_DECODE_NOCOPY_FLAG@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r8d
	orl	(%rax), %r8d
	leaq	-48(%rbp), %rax
	leaq	-40(%rbp), %r10
	xorl	%ebx, %ebx
	xorl	%r9d, %r9d
	pushq	%rax
	pushq	%r10
	callq	_CryptDecodeObjectEx
	addq	$16, %rsp
	testl	%eax, %eax
	je	LBB0_33
## %bb.12:
	movq	-40(%rbp), %rsi
	cmpq	$0, 24(%rsi)
	je	LBB0_26
## %bb.13:
	cmpq	$0, 16(%rsi)
	je	LBB0_26
## %bb.14:
	addq	$24, %rsi
	movl	8(%r14), %edi
	movq	(%r14), %rdx
	callq	_CertCompareCertificateName
	testq	%rax, %rax
	je	LBB0_31
## %bb.15:
	movq	-40(%rbp), %rdi
	addq	$16, %rdi
LBB0_16:
	movq	(%r14), %rsi
	addq	$16, %rsi
	callq	_CertCompareIntegerBlob
	movq	%rax, %rbx
	testq	%rax, %rax
	je	LBB0_32
## %bb.17:
	movq	_CERT_TRUST_HAS_NAME_MATCH_ISSUER@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	jmp	LBB0_32
LBB0_18:
	cmpq	$0, (%rcx)
	jne	LBB0_19
	jmp	LBB0_31
LBB0_24:
	movl	8(%r14), %edi
	movq	(%r14), %rdx
	leaq	8(%rdx), %rsi
	callq	_CertCompareCertificateName
	movq	%rax, %rbx
	testq	%rax, %rax
	je	LBB0_33
## %bb.25:
	movq	_CERT_TRUST_HAS_NAME_MATCH_ISSUER@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	jmp	LBB0_33
LBB0_26:
	cmpq	$0, (%rsi)
	je	LBB0_31
LBB0_19:
	movq	_CERT_KEY_IDENTIFIER_PROP_ID@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	xorl	%ebx, %ebx
	leaq	-48(%rbp), %rcx
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_CertGetCertificateContextProperty
	testl	%eax, %eax
	je	LBB0_32
## %bb.20:
	movq	-48(%rbp), %rdi
	movq	-40(%rbp), %rax
	cmpq	(%rax), %rdi
	jne	LBB0_31
## %bb.21:
	callq	_CryptMemAlloc
	testq	%rax, %rax
	je	LBB0_31
## %bb.22:
	movq	%rax, %r15
	movl	(%r12), %esi
	leaq	-48(%rbp), %rcx
	movq	%r14, %rdi
	movq	%rax, %rdx
	callq	_CertGetCertificateContextProperty
	movq	-40(%rbp), %rax
	movl	8(%rax), %esi
	movq	-48(%rbp), %rdx
	movq	%r15, %rdi
	callq	_memcmp
	testl	%eax, %eax
	jne	LBB0_23
## %bb.28:
	movq	_CERT_TRUST_HAS_KEY_MATCH_ISSUER@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	jmp	LBB0_29
LBB0_30:
	leaq	L_.str(%rip), %rdi
	callq	_FIXME
LBB0_31:
	xorl	%ebx, %ebx
LBB0_32:
	movq	-40(%rbp), %rdi
	callq	_LocalFree
LBB0_33:
	movq	_CERT_TRUST_IS_SELF_SIGNED@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	orq	%rbx, %rax
	testq	%rbx, %rbx
	cmoveq	%rbx, %rax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_23:
	xorl	%ebx, %ebx
LBB0_29:
	movq	%r15, %rdi
	callq	_CryptMemFree
	jmp	LBB0_32
	.cfi_endproc
                                        ## -- End function
	.comm	_szOID_AUTHORITY_KEY_IDENTIFIER2,4,2 ## @szOID_AUTHORITY_KEY_IDENTIFIER2
	.comm	_X509_AUTHORITY_KEY_ID2,4,2     ## @X509_AUTHORITY_KEY_ID2
	.comm	_CRYPT_DECODE_ALLOC_FLAG,4,2    ## @CRYPT_DECODE_ALLOC_FLAG
	.comm	_CRYPT_DECODE_NOCOPY_FLAG,4,2   ## @CRYPT_DECODE_NOCOPY_FLAG
	.comm	_CERT_ALT_NAME_DIRECTORY_NAME,8,3 ## @CERT_ALT_NAME_DIRECTORY_NAME
	.comm	_CERT_TRUST_HAS_NAME_MATCH_ISSUER,8,3 ## @CERT_TRUST_HAS_NAME_MATCH_ISSUER
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"no supported name type in authority key id2\n"

	.comm	_FALSE,4,2                      ## @FALSE
	.comm	_CERT_KEY_IDENTIFIER_PROP_ID,4,2 ## @CERT_KEY_IDENTIFIER_PROP_ID
	.comm	_CERT_TRUST_HAS_KEY_MATCH_ISSUER,8,3 ## @CERT_TRUST_HAS_KEY_MATCH_ISSUER
	.comm	_szOID_AUTHORITY_KEY_IDENTIFIER,4,2 ## @szOID_AUTHORITY_KEY_IDENTIFIER
	.comm	_X509_AUTHORITY_KEY_ID,4,2      ## @X509_AUTHORITY_KEY_ID
	.comm	_CERT_TRUST_IS_SELF_SIGNED,8,3  ## @CERT_TRUST_IS_SELF_SIGNED
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CRYPT_IsCertificateSelfSigned  ; -- Begin function CRYPT_IsCertificateSelfSigned
	.p2align	2
_CRYPT_IsCertificateSelfSigned:         ; @CRYPT_IsCertificateSelfSigned
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _szOID_AUTHORITY_KEY_IDENTIFIER2@GOTPAGE
Lloh1:
	ldr	x8, [x8, _szOID_AUTHORITY_KEY_IDENTIFIER2@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	ldr	x8, [x19]
	ldp	w2, w1, [x8, #20]
	bl	_CertFindExtension
	cbz	x0, LBB0_9
; %bb.1:
	ldr	w8, [x19, #8]
Lloh3:
	adrp	x9, _X509_AUTHORITY_KEY_ID2@GOTPAGE
Lloh4:
	ldr	x9, [x9, _X509_AUTHORITY_KEY_ID2@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x9]
Lloh6:
	adrp	x9, _CRYPT_DECODE_ALLOC_FLAG@GOTPAGE
Lloh7:
	ldr	x9, [x9, _CRYPT_DECODE_ALLOC_FLAG@GOTPAGEOFF]
	ldp	w3, w2, [x0]
Lloh8:
	ldr	w9, [x9]
Lloh9:
	adrp	x10, _CRYPT_DECODE_NOCOPY_FLAG@GOTPAGE
Lloh10:
	ldr	x10, [x10, _CRYPT_DECODE_NOCOPY_FLAG@GOTPAGEOFF]
Lloh11:
	ldr	w10, [x10]
	orr	w4, w10, w9
	mov	x6, sp
	add	x7, sp, #8
	mov	x0, x8
	mov	x5, #0
	bl	_CryptDecodeObjectEx
	cbz	w0, LBB0_21
; %bb.2:
	ldr	x8, [sp]
	ldr	x10, [x8, #40]
	cbz	x10, LBB0_16
; %bb.3:
	ldr	x9, [x8, #32]
	cbz	x9, LBB0_16
; %bb.4:
	ldr	x8, [x8, #48]
Lloh12:
	adrp	x9, _CERT_ALT_NAME_DIRECTORY_NAME@GOTPAGE
Lloh13:
	ldr	x9, [x9, _CERT_ALT_NAME_DIRECTORY_NAME@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	sub	x11, x8, #8
	add	x10, x10, #1
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	subs	x10, x10, #1
	b.eq	LBB0_23
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	add	x1, x11, #16
	ldr	x11, [x11, #8]
	cmp	x11, x9
	ccmp	x8, #0, #4, eq
	mov	x11, x1
	b.eq	LBB0_5
; %bb.7:
	ldr	w0, [x19, #8]
	ldr	x2, [x19]
	bl	_CertCompareCertificateName
	cbz	x0, LBB0_24
; %bb.8:
	ldr	x8, [sp]
	add	x0, x8, #32
	b	LBB0_15
LBB0_9:
Lloh15:
	adrp	x8, _szOID_AUTHORITY_KEY_IDENTIFIER@GOTPAGE
Lloh16:
	ldr	x8, [x8, _szOID_AUTHORITY_KEY_IDENTIFIER@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	ldr	x8, [x19]
	ldp	w2, w1, [x8, #20]
	bl	_CertFindExtension
	cbz	x0, LBB0_22
; %bb.10:
	ldr	w8, [x19, #8]
Lloh18:
	adrp	x9, _X509_AUTHORITY_KEY_ID@GOTPAGE
Lloh19:
	ldr	x9, [x9, _X509_AUTHORITY_KEY_ID@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x9]
Lloh21:
	adrp	x9, _CRYPT_DECODE_ALLOC_FLAG@GOTPAGE
Lloh22:
	ldr	x9, [x9, _CRYPT_DECODE_ALLOC_FLAG@GOTPAGEOFF]
	ldp	w3, w2, [x0]
Lloh23:
	ldr	w9, [x9]
Lloh24:
	adrp	x10, _CRYPT_DECODE_NOCOPY_FLAG@GOTPAGE
Lloh25:
	ldr	x10, [x10, _CRYPT_DECODE_NOCOPY_FLAG@GOTPAGEOFF]
Lloh26:
	ldr	w10, [x10]
	orr	w4, w10, w9
	mov	x6, sp
	add	x7, sp, #8
	mov	x0, x8
	mov	x5, #0
	bl	_CryptDecodeObjectEx
	cbz	w0, LBB0_21
; %bb.11:
	ldr	x8, [sp]
	mov	x1, x8
	ldr	x9, [x1, #24]!
	cbz	x9, LBB0_16
; %bb.12:
	ldr	x9, [x8, #16]
	cbz	x9, LBB0_16
; %bb.13:
	ldr	w0, [x19, #8]
	ldr	x2, [x19]
	bl	_CertCompareCertificateName
	cbz	x0, LBB0_24
; %bb.14:
	ldr	x8, [sp]
	add	x0, x8, #16
LBB0_15:
	ldr	x8, [x19]
	add	x1, x8, #16
	bl	_CertCompareIntegerBlob
Lloh27:
	adrp	x8, _CERT_TRUST_HAS_NAME_MATCH_ISSUER@GOTPAGE
Lloh28:
	ldr	x8, [x8, _CERT_TRUST_HAS_NAME_MATCH_ISSUER@GOTPAGEOFF]
Lloh29:
	ldr	x8, [x8]
	cmp	x0, #0
	csel	x19, xzr, x8, eq
	b	LBB0_25
LBB0_16:
	ldr	x8, [x8]
	cbz	x8, LBB0_24
; %bb.17:
Lloh30:
	adrp	x21, _CERT_KEY_IDENTIFIER_PROP_ID@GOTPAGE
Lloh31:
	ldr	x21, [x21, _CERT_KEY_IDENTIFIER_PROP_ID@GOTPAGEOFF]
	ldr	w1, [x21]
	add	x3, sp, #8
	mov	x0, x19
	mov	x2, #0
	bl	_CertGetCertificateContextProperty
	cbz	w0, LBB0_24
; %bb.18:
	ldp	x8, x0, [sp]
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_24
; %bb.19:
	bl	_CryptMemAlloc
	cbz	x0, LBB0_24
; %bb.20:
	mov	x20, x0
	ldr	w1, [x21]
	add	x3, sp, #8
	mov	x0, x19
	mov	x2, x20
	bl	_CertGetCertificateContextProperty
	ldp	x8, x2, [sp]
	ldr	w1, [x8, #8]
	mov	x0, x20
	bl	_memcmp
Lloh32:
	adrp	x8, _CERT_TRUST_HAS_KEY_MATCH_ISSUER@GOTPAGE
Lloh33:
	ldr	x8, [x8, _CERT_TRUST_HAS_KEY_MATCH_ISSUER@GOTPAGEOFF]
Lloh34:
	ldr	x8, [x8]
	cmp	w0, #0
	csel	x19, x8, xzr, eq
	mov	x0, x20
	bl	_CryptMemFree
	b	LBB0_25
LBB0_21:
	mov	x19, #0
	b	LBB0_26
LBB0_22:
	ldr	w0, [x19, #8]
	ldr	x2, [x19]
	add	x1, x2, #8
	bl	_CertCompareCertificateName
Lloh35:
	adrp	x8, _CERT_TRUST_HAS_NAME_MATCH_ISSUER@GOTPAGE
Lloh36:
	ldr	x8, [x8, _CERT_TRUST_HAS_NAME_MATCH_ISSUER@GOTPAGEOFF]
Lloh37:
	ldr	x8, [x8]
	cmp	x0, #0
	csel	x19, xzr, x8, eq
	b	LBB0_26
LBB0_23:
Lloh38:
	adrp	x0, l_.str@PAGE
Lloh39:
	add	x0, x0, l_.str@PAGEOFF
	bl	_FIXME
LBB0_24:
	mov	x19, #0
LBB0_25:
	ldr	x0, [sp]
	bl	_LocalFree
LBB0_26:
Lloh40:
	adrp	x8, _CERT_TRUST_IS_SELF_SIGNED@GOTPAGE
Lloh41:
	ldr	x8, [x8, _CERT_TRUST_IS_SELF_SIGNED@GOTPAGEOFF]
Lloh42:
	ldr	x8, [x8]
	orr	x8, x8, x19
	cmp	x19, #0
	csel	x0, xzr, x8, eq
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpAdd	Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.cfi_endproc
                                        ; -- End function
	.comm	_szOID_AUTHORITY_KEY_IDENTIFIER2,4,2 ; @szOID_AUTHORITY_KEY_IDENTIFIER2
	.comm	_X509_AUTHORITY_KEY_ID2,4,2     ; @X509_AUTHORITY_KEY_ID2
	.comm	_CRYPT_DECODE_ALLOC_FLAG,4,2    ; @CRYPT_DECODE_ALLOC_FLAG
	.comm	_CRYPT_DECODE_NOCOPY_FLAG,4,2   ; @CRYPT_DECODE_NOCOPY_FLAG
	.comm	_CERT_ALT_NAME_DIRECTORY_NAME,8,3 ; @CERT_ALT_NAME_DIRECTORY_NAME
	.comm	_CERT_TRUST_HAS_NAME_MATCH_ISSUER,8,3 ; @CERT_TRUST_HAS_NAME_MATCH_ISSUER
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"no supported name type in authority key id2\n"

	.comm	_FALSE,4,2                      ; @FALSE
	.comm	_CERT_KEY_IDENTIFIER_PROP_ID,4,2 ; @CERT_KEY_IDENTIFIER_PROP_ID
	.comm	_CERT_TRUST_HAS_KEY_MATCH_ISSUER,8,3 ; @CERT_TRUST_HAS_KEY_MATCH_ISSUER
	.comm	_szOID_AUTHORITY_KEY_IDENTIFIER,4,2 ; @szOID_AUTHORITY_KEY_IDENTIFIER
	.comm	_X509_AUTHORITY_KEY_ID,4,2      ; @X509_AUTHORITY_KEY_ID
	.comm	_CERT_TRUST_IS_SELF_SIGNED,8,3  ; @CERT_TRUST_IS_SELF_SIGNED
.subsections_via_symbols
