	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__hx509_query_match_cert        ## -- Begin function _hx509_query_match_cert
	.p2align	4, 0x90
__hx509_query_match_cert:               ## @_hx509_query_match_cert
	.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
	movl	%edx, %r15d
	movq	%rsi, %r13
	movl	%edi, %r14d
	movl	%edx, %edi
	callq	__hx509_get_cert
	movq	%rax, %r12
	movl	%r14d, %edi
	movl	$1, %esi
	movq	%r13, %rdx
	callq	__hx509_query_statistic
	movl	(%r13), %eax
	movq	_HX509_QUERY_FIND_ISSUER_CERT@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_3
## %bb.1:
	movl	80(%r13), %edi
	xorl	%ebx, %ebx
	movq	%r12, %rsi
	xorl	%edx, %edx
	callq	__hx509_cert_is_parent_cmp
	testq	%rax, %rax
	jne	LBB0_60
## %bb.2:
	movl	(%r13), %eax
LBB0_3:
	movq	_HX509_QUERY_MATCH_CERTIFICATE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_6
## %bb.4:
	movl	76(%r13), %edi
	movq	%r12, %rsi
	callq	__hx509_Certificate_cmp
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jne	LBB0_60
## %bb.5:
	movl	(%r13), %eax
LBB0_6:
	movq	_HX509_QUERY_MATCH_SERIALNUMBER@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_9
## %bb.7:
	leaq	24(%r12), %rdi
	movl	72(%r13), %esi
	callq	_der_heim_integer_cmp
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jne	LBB0_60
## %bb.8:
	movl	(%r13), %eax
LBB0_9:
	movq	_HX509_QUERY_MATCH_ISSUER_NAME@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_12
## %bb.10:
	leaq	20(%r12), %rdi
	movl	68(%r13), %esi
	leaq	-52(%rbp), %rdx
	callq	__hx509_name_cmp
	xorl	%ebx, %ebx
	orl	-52(%rbp), %eax
	jne	LBB0_60
## %bb.11:
	movl	(%r13), %eax
LBB0_12:
	movq	_HX509_QUERY_MATCH_SUBJECT_NAME@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_15
## %bb.13:
	leaq	16(%r12), %rdi
	movl	64(%r13), %esi
	leaq	-52(%rbp), %rdx
	callq	__hx509_name_cmp
	xorl	%ebx, %ebx
	orl	-52(%rbp), %eax
	jne	LBB0_60
## %bb.14:
	movl	(%r13), %eax
LBB0_15:
	movq	_HX509_QUERY_MATCH_SUBJECT_KEY_ID@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_19
## %bb.16:
	leaq	-48(%rbp), %rsi
	movq	%r12, %rdi
	callq	__hx509_find_extension_subject_key_id
	testl	%eax, %eax
	jne	LBB0_59
## %bb.17:
	movl	60(%r13), %esi
	leaq	-48(%rbp), %rdi
	callq	_der_heim_octet_string_cmp
	movq	%rax, %rbx
	leaq	-48(%rbp), %rdi
	callq	_free_SubjectKeyIdentifier
	testq	%rbx, %rbx
	jne	LBB0_59
## %bb.18:
	movl	(%r13), %eax
LBB0_19:
	movq	_HX509_QUERY_MATCH_ISSUER_ID@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_20
LBB0_59:
	xorl	%ebx, %ebx
LBB0_60:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_20:
	movq	_HX509_QUERY_PRIVATE_KEY@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_23
## %bb.21:
	movl	%r15d, %edi
	callq	__hx509_cert_private_key
	testq	%rax, %rax
	je	LBB0_59
## %bb.22:
	movl	(%r13), %eax
LBB0_23:
	movq	_HX509_QUERY_KU_DIGITALSIGNATURE@GOTPCREL(%rip), %rcx
	xorl	%edx, %edx
	testl	%eax, (%rcx)
	setne	%dl
	movq	_HX509_QUERY_KU_NONREPUDIATION@GOTPCREL(%rip), %rcx
	leal	2(%rdx), %esi
	testl	%eax, (%rcx)
	cmovel	%edx, %esi
	movq	_HX509_QUERY_KU_ENCIPHERMENT@GOTPCREL(%rip), %rcx
	leal	4(%rsi), %edx
	testl	%eax, (%rcx)
	cmovel	%esi, %edx
	movq	_HX509_QUERY_KU_DATAENCIPHERMENT@GOTPCREL(%rip), %rcx
	leal	8(%rdx), %esi
	testl	%eax, (%rcx)
	cmovel	%edx, %esi
	movq	_HX509_QUERY_KU_KEYAGREEMENT@GOTPCREL(%rip), %rcx
	movl	%esi, %edx
	orl	$16, %edx
	testl	%eax, (%rcx)
	cmovel	%esi, %edx
	movq	_HX509_QUERY_KU_KEYCERTSIGN@GOTPCREL(%rip), %rcx
	movl	%edx, %esi
	orl	$32, %esi
	testl	%eax, (%rcx)
	cmovel	%edx, %esi
	movq	_HX509_QUERY_KU_CRLSIGN@GOTPCREL(%rip), %rcx
	movl	%esi, %edx
	orl	$64, %edx
	testl	%eax, (%rcx)
	cmovel	%esi, %edx
	testl	%edx, %edx
	je	LBB0_26
## %bb.24:
	movq	_TRUE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%r14d, %edi
	movq	%r12, %rsi
	callq	_check_key_usage
	testq	%rax, %rax
	jne	LBB0_59
## %bb.25:
	movl	(%r13), %eax
LBB0_26:
	movq	_HX509_QUERY_ANCHOR@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_59
## %bb.27:
	movq	_HX509_QUERY_MATCH_LOCAL_KEY_ID@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_31
## %bb.28:
	movq	_asn1_oid_id_pkcs_9_at_localKeyId@GOTPCREL(%rip), %rsi
	movl	%r15d, %edi
	callq	_hx509_cert_get_attribute
	testq	%rax, %rax
	je	LBB0_59
## %bb.29:
	movl	56(%r13), %esi
	movq	%rax, %rdi
	callq	_der_heim_octet_string_cmp
	testq	%rax, %rax
	jne	LBB0_59
## %bb.30:
	movl	(%r13), %eax
LBB0_31:
	movq	_HX509_QUERY_NO_MATCH_PATH@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_37
## %bb.32:
	movq	48(%r13), %rcx
	cmpq	$0, (%rcx)
	je	LBB0_37
## %bb.33:
	xorl	%ebx, %ebx
	xorl	%edx, %edx
LBB0_35:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%rcx), %rax
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	movl	(%rax,%rdx,4), %edi
	movl	%r15d, %esi
	callq	_hx509_cert_cmp
	testq	%rax, %rax
	je	LBB0_60
## %bb.34:                              ##   in Loop: Header=BB0_35 Depth=1
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	incq	%rdx
	movq	48(%r13), %rcx
	cmpq	(%rcx), %rdx
	jb	LBB0_35
## %bb.36:
	movl	(%r13), %eax
LBB0_37:
	movq	_HX509_QUERY_MATCH_FRIENDLY_NAME@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_41
## %bb.38:
	movl	%r15d, %edi
	callq	_hx509_cert_get_friendly_name
	testq	%rax, %rax
	je	LBB0_59
## %bb.39:
	movl	40(%r13), %edi
	movq	%rax, %rsi
	callq	_strcasecmp
	testq	%rax, %rax
	jne	LBB0_59
## %bb.40:
	movl	(%r13), %eax
LBB0_41:
	movq	_HX509_QUERY_MATCH_FUNCTION@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_44
## %bb.42:
	movl	36(%r13), %edx
	movl	%r14d, %edi
	movl	%r15d, %esi
	callq	*8(%r13)
	testl	%eax, %eax
	jne	LBB0_59
## %bb.43:
	movl	(%r13), %eax
LBB0_44:
	movq	_HX509_QUERY_MATCH_KEY_HASH_SHA1@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_47
## %bb.45:
	movl	12(%r12), %eax
	movl	%eax, -44(%rbp)
	movl	8(%r12), %eax
	leal	7(%rax), %ecx
	testl	%eax, %eax
	cmovnsl	%eax, %ecx
	sarl	$3, %ecx
	movl	%ecx, -48(%rbp)
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_hx509_signature_sha1
	movl	32(%r13), %r8d
	leaq	-48(%rbp), %rcx
	movl	%r14d, %edi
	xorl	%esi, %esi
	movl	%eax, %edx
	callq	__hx509_verify_signature
	testl	%eax, %eax
	jne	LBB0_60
## %bb.46:
	movl	(%r13), %eax
LBB0_47:
	movq	_HX509_QUERY_MATCH_TIME@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_51
## %bb.48:
	movq	%r12, %rdi
	addq	$4, %rdi
	callq	__hx509_Time2time_t
	cmpq	16(%r13), %rax
	jg	LBB0_59
## %bb.49:
	movq	%r12, %rdi
	callq	__hx509_Time2time_t
	cmpq	16(%r13), %rax
	jl	LBB0_59
## %bb.50:
	movl	(%r13), %eax
LBB0_51:
	movq	_HX509_QUERY_MATCH_EKU@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_54
## %bb.52:
	movl	28(%r13), %edx
	xorl	%ebx, %ebx
	movl	%r14d, %edi
	movl	%r15d, %esi
	xorl	%ecx, %ecx
	callq	_hx509_cert_check_eku
	testq	%rax, %rax
	jne	LBB0_60
## %bb.53:
	movl	(%r13), %eax
LBB0_54:
	movq	_HX509_QUERY_MATCH_EXPR@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_58
## %bb.55:
	movq	$0, -48(%rbp)
	leaq	-48(%rbp), %rdx
	movl	%r14d, %edi
	movl	%r15d, %esi
	callq	__hx509_cert_to_env
	testl	%eax, %eax
	jne	LBB0_59
## %bb.56:
	movq	-48(%rbp), %rsi
	movl	24(%r13), %edx
	movl	%r14d, %edi
	callq	__hx509_expr_eval
	movl	%eax, %r14d
	leaq	-48(%rbp), %rdi
	callq	_hx509_env_free
	movl	$0, %ebx
	testl	%r14d, %r14d
	je	LBB0_60
## %bb.57:
	movl	(%r13), %eax
LBB0_58:
	movq	_HX509_QUERY_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	xorl	%ebx, %ebx
	testl	%ecx, %eax
	sete	%bl
	jmp	LBB0_60
	.cfi_endproc
                                        ## -- End function
	.comm	_HX509_QUERY_FIND_ISSUER_CERT,4,2 ## @HX509_QUERY_FIND_ISSUER_CERT
	.comm	_HX509_QUERY_MATCH_CERTIFICATE,4,2 ## @HX509_QUERY_MATCH_CERTIFICATE
	.comm	_HX509_QUERY_MATCH_SERIALNUMBER,4,2 ## @HX509_QUERY_MATCH_SERIALNUMBER
	.comm	_HX509_QUERY_MATCH_ISSUER_NAME,4,2 ## @HX509_QUERY_MATCH_ISSUER_NAME
	.comm	_HX509_QUERY_MATCH_SUBJECT_NAME,4,2 ## @HX509_QUERY_MATCH_SUBJECT_NAME
	.comm	_HX509_QUERY_MATCH_SUBJECT_KEY_ID,4,2 ## @HX509_QUERY_MATCH_SUBJECT_KEY_ID
	.comm	_HX509_QUERY_MATCH_ISSUER_ID,4,2 ## @HX509_QUERY_MATCH_ISSUER_ID
	.comm	_HX509_QUERY_PRIVATE_KEY,4,2    ## @HX509_QUERY_PRIVATE_KEY
	.comm	_HX509_QUERY_KU_DIGITALSIGNATURE,4,2 ## @HX509_QUERY_KU_DIGITALSIGNATURE
	.comm	_HX509_QUERY_KU_NONREPUDIATION,4,2 ## @HX509_QUERY_KU_NONREPUDIATION
	.comm	_HX509_QUERY_KU_ENCIPHERMENT,4,2 ## @HX509_QUERY_KU_ENCIPHERMENT
	.comm	_HX509_QUERY_KU_DATAENCIPHERMENT,4,2 ## @HX509_QUERY_KU_DATAENCIPHERMENT
	.comm	_HX509_QUERY_KU_KEYAGREEMENT,4,2 ## @HX509_QUERY_KU_KEYAGREEMENT
	.comm	_HX509_QUERY_KU_KEYCERTSIGN,4,2 ## @HX509_QUERY_KU_KEYCERTSIGN
	.comm	_HX509_QUERY_KU_CRLSIGN,4,2     ## @HX509_QUERY_KU_CRLSIGN
	.comm	_TRUE,4,2                       ## @TRUE
	.comm	_HX509_QUERY_ANCHOR,4,2         ## @HX509_QUERY_ANCHOR
	.comm	_HX509_QUERY_MATCH_LOCAL_KEY_ID,4,2 ## @HX509_QUERY_MATCH_LOCAL_KEY_ID
	.comm	_asn1_oid_id_pkcs_9_at_localKeyId,4,2 ## @asn1_oid_id_pkcs_9_at_localKeyId
	.comm	_HX509_QUERY_NO_MATCH_PATH,4,2  ## @HX509_QUERY_NO_MATCH_PATH
	.comm	_HX509_QUERY_MATCH_FRIENDLY_NAME,4,2 ## @HX509_QUERY_MATCH_FRIENDLY_NAME
	.comm	_HX509_QUERY_MATCH_FUNCTION,4,2 ## @HX509_QUERY_MATCH_FUNCTION
	.comm	_HX509_QUERY_MATCH_KEY_HASH_SHA1,4,2 ## @HX509_QUERY_MATCH_KEY_HASH_SHA1
	.comm	_HX509_QUERY_MATCH_TIME,4,2     ## @HX509_QUERY_MATCH_TIME
	.comm	_HX509_QUERY_MATCH_EKU,4,2      ## @HX509_QUERY_MATCH_EKU
	.comm	_HX509_QUERY_MATCH_EXPR,4,2     ## @HX509_QUERY_MATCH_EXPR
	.comm	_HX509_QUERY_MASK,4,2           ## @HX509_QUERY_MASK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__hx509_query_match_cert        ; -- Begin function _hx509_query_match_cert
	.p2align	2
__hx509_query_match_cert:               ; @_hx509_query_match_cert
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	mov	x0, x2
	bl	__hx509_get_cert
	mov	x22, x0
	mov	x0, x20
	mov	w1, #1
	mov	x2, x19
	bl	__hx509_query_statistic
	ldr	w8, [x19]
Lloh0:
	adrp	x9, _HX509_QUERY_FIND_ISSUER_CERT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _HX509_QUERY_FIND_ISSUER_CERT@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.1:
	ldr	w0, [x19, #80]
	mov	x1, x22
	mov	w2, #0
	bl	__hx509_cert_is_parent_cmp
	mov	x8, x0
	mov	w0, #0
	cbnz	x8, LBB0_21
; %bb.2:
	ldr	w8, [x19]
LBB0_3:
Lloh3:
	adrp	x9, _HX509_QUERY_MATCH_CERTIFICATE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _HX509_QUERY_MATCH_CERTIFICATE@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.4:
	ldr	w0, [x19, #76]
	mov	x1, x22
	bl	__hx509_Certificate_cmp
	cbnz	x0, LBB0_20
; %bb.5:
	ldr	w8, [x19]
LBB0_6:
Lloh6:
	adrp	x9, _HX509_QUERY_MATCH_SERIALNUMBER@GOTPAGE
Lloh7:
	ldr	x9, [x9, _HX509_QUERY_MATCH_SERIALNUMBER@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_9
; %bb.7:
	add	x0, x22, #24
	ldr	w1, [x19, #72]
	bl	_der_heim_integer_cmp
	cbnz	x0, LBB0_20
; %bb.8:
	ldr	w8, [x19]
LBB0_9:
Lloh9:
	adrp	x9, _HX509_QUERY_MATCH_ISSUER_NAME@GOTPAGE
Lloh10:
	ldr	x9, [x9, _HX509_QUERY_MATCH_ISSUER_NAME@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_12
; %bb.10:
	add	x0, x22, #20
	ldr	w1, [x19, #68]
	add	x2, sp, #12
	bl	__hx509_name_cmp
	ldr	w8, [sp, #12]
	orr	w8, w0, w8
	cbnz	w8, LBB0_20
; %bb.11:
	ldr	w8, [x19]
LBB0_12:
Lloh12:
	adrp	x9, _HX509_QUERY_MATCH_SUBJECT_NAME@GOTPAGE
Lloh13:
	ldr	x9, [x9, _HX509_QUERY_MATCH_SUBJECT_NAME@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_15
; %bb.13:
	add	x0, x22, #16
	ldr	w1, [x19, #64]
	add	x2, sp, #12
	bl	__hx509_name_cmp
	ldr	w8, [sp, #12]
	orr	w8, w0, w8
	cbnz	w8, LBB0_20
; %bb.14:
	ldr	w8, [x19]
LBB0_15:
Lloh15:
	adrp	x9, _HX509_QUERY_MATCH_SUBJECT_KEY_ID@GOTPAGE
Lloh16:
	ldr	x9, [x9, _HX509_QUERY_MATCH_SUBJECT_KEY_ID@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_19
; %bb.16:
	mov	x1, sp
	mov	x0, x22
	bl	__hx509_find_extension_subject_key_id
	cbnz	w0, LBB0_20
; %bb.17:
	ldr	w1, [x19, #60]
	mov	x0, sp
	bl	_der_heim_octet_string_cmp
	mov	x23, x0
	mov	x0, sp
	bl	_free_SubjectKeyIdentifier
	cbnz	x23, LBB0_20
; %bb.18:
	ldr	w8, [x19]
LBB0_19:
Lloh18:
	adrp	x9, _HX509_QUERY_MATCH_ISSUER_ID@GOTPAGE
Lloh19:
	ldr	x9, [x9, _HX509_QUERY_MATCH_ISSUER_ID@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_22
LBB0_20:
	mov	w0, #0
LBB0_21:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_22:
Lloh21:
	adrp	x9, _HX509_QUERY_PRIVATE_KEY@GOTPAGE
Lloh22:
	ldr	x9, [x9, _HX509_QUERY_PRIVATE_KEY@GOTPAGEOFF]
Lloh23:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_25
; %bb.23:
	mov	x0, x21
	bl	__hx509_cert_private_key
	cbz	x0, LBB0_21
; %bb.24:
	ldr	w8, [x19]
LBB0_25:
Lloh24:
	adrp	x9, _HX509_QUERY_KU_DIGITALSIGNATURE@GOTPAGE
Lloh25:
	ldr	x9, [x9, _HX509_QUERY_KU_DIGITALSIGNATURE@GOTPAGEOFF]
Lloh26:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w9, ne
Lloh27:
	adrp	x10, _HX509_QUERY_KU_NONREPUDIATION@GOTPAGE
Lloh28:
	ldr	x10, [x10, _HX509_QUERY_KU_NONREPUDIATION@GOTPAGEOFF]
Lloh29:
	ldr	w10, [x10]
	orr	w11, w9, #0x2
	tst	w10, w8
	csel	w9, w9, w11, eq
Lloh30:
	adrp	x10, _HX509_QUERY_KU_ENCIPHERMENT@GOTPAGE
Lloh31:
	ldr	x10, [x10, _HX509_QUERY_KU_ENCIPHERMENT@GOTPAGEOFF]
Lloh32:
	ldr	w10, [x10]
	orr	w11, w9, #0x4
	tst	w10, w8
	csel	w9, w9, w11, eq
Lloh33:
	adrp	x10, _HX509_QUERY_KU_DATAENCIPHERMENT@GOTPAGE
Lloh34:
	ldr	x10, [x10, _HX509_QUERY_KU_DATAENCIPHERMENT@GOTPAGEOFF]
Lloh35:
	ldr	w10, [x10]
	orr	w11, w9, #0x8
	tst	w10, w8
	csel	w9, w9, w11, eq
Lloh36:
	adrp	x10, _HX509_QUERY_KU_KEYAGREEMENT@GOTPAGE
Lloh37:
	ldr	x10, [x10, _HX509_QUERY_KU_KEYAGREEMENT@GOTPAGEOFF]
Lloh38:
	ldr	w10, [x10]
	orr	w11, w9, #0x10
	tst	w10, w8
	csel	w9, w9, w11, eq
Lloh39:
	adrp	x10, _HX509_QUERY_KU_KEYCERTSIGN@GOTPAGE
Lloh40:
	ldr	x10, [x10, _HX509_QUERY_KU_KEYCERTSIGN@GOTPAGEOFF]
Lloh41:
	ldr	w10, [x10]
	orr	w11, w9, #0x20
	tst	w10, w8
	csel	w9, w9, w11, eq
Lloh42:
	adrp	x10, _HX509_QUERY_KU_CRLSIGN@GOTPAGE
Lloh43:
	ldr	x10, [x10, _HX509_QUERY_KU_CRLSIGN@GOTPAGEOFF]
Lloh44:
	ldr	w10, [x10]
	orr	w11, w9, #0x40
	tst	w10, w8
	csel	w2, w9, w11, eq
	cbz	w2, LBB0_28
; %bb.26:
Lloh45:
	adrp	x8, _TRUE@GOTPAGE
Lloh46:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
Lloh47:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x22
	bl	_check_key_usage
	cbnz	x0, LBB0_20
; %bb.27:
	ldr	w8, [x19]
LBB0_28:
Lloh48:
	adrp	x9, _HX509_QUERY_ANCHOR@GOTPAGE
Lloh49:
	ldr	x9, [x9, _HX509_QUERY_ANCHOR@GOTPAGEOFF]
Lloh50:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_20
; %bb.29:
Lloh51:
	adrp	x9, _HX509_QUERY_MATCH_LOCAL_KEY_ID@GOTPAGE
Lloh52:
	ldr	x9, [x9, _HX509_QUERY_MATCH_LOCAL_KEY_ID@GOTPAGEOFF]
Lloh53:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_33
; %bb.30:
Lloh54:
	adrp	x1, _asn1_oid_id_pkcs_9_at_localKeyId@GOTPAGE
Lloh55:
	ldr	x1, [x1, _asn1_oid_id_pkcs_9_at_localKeyId@GOTPAGEOFF]
	mov	x0, x21
	bl	_hx509_cert_get_attribute
	cbz	x0, LBB0_21
; %bb.31:
	ldr	w1, [x19, #56]
	bl	_der_heim_octet_string_cmp
	cbnz	x0, LBB0_20
; %bb.32:
	ldr	w8, [x19]
LBB0_33:
Lloh56:
	adrp	x9, _HX509_QUERY_NO_MATCH_PATH@GOTPAGE
Lloh57:
	ldr	x9, [x9, _HX509_QUERY_NO_MATCH_PATH@GOTPAGEOFF]
Lloh58:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_39
; %bb.34:
	ldr	x9, [x19, #48]
	ldr	x10, [x9]
	cbz	x10, LBB0_39
; %bb.35:
	mov	x23, #0
LBB0_36:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x9, #8]
	ldr	w0, [x8, x23, lsl #2]
	mov	x1, x21
	bl	_hx509_cert_cmp
	cbz	x0, LBB0_21
; %bb.37:                               ;   in Loop: Header=BB0_36 Depth=1
	add	x23, x23, #1
	ldr	x9, [x19, #48]
	ldr	x8, [x9]
	cmp	x23, x8
	b.lo	LBB0_36
; %bb.38:
	ldr	w8, [x19]
LBB0_39:
Lloh59:
	adrp	x9, _HX509_QUERY_MATCH_FRIENDLY_NAME@GOTPAGE
Lloh60:
	ldr	x9, [x9, _HX509_QUERY_MATCH_FRIENDLY_NAME@GOTPAGEOFF]
Lloh61:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_43
; %bb.40:
	mov	x0, x21
	bl	_hx509_cert_get_friendly_name
	cbz	x0, LBB0_21
; %bb.41:
	mov	x1, x0
	ldr	w0, [x19, #40]
	bl	_strcasecmp
	cbnz	x0, LBB0_20
; %bb.42:
	ldr	w8, [x19]
LBB0_43:
Lloh62:
	adrp	x9, _HX509_QUERY_MATCH_FUNCTION@GOTPAGE
Lloh63:
	ldr	x9, [x9, _HX509_QUERY_MATCH_FUNCTION@GOTPAGEOFF]
Lloh64:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_46
; %bb.44:
	ldr	x8, [x19, #8]
	ldr	w2, [x19, #36]
	mov	x0, x20
	mov	x1, x21
	blr	x8
	cbnz	w0, LBB0_20
; %bb.45:
	ldr	w8, [x19]
LBB0_46:
Lloh65:
	adrp	x9, _HX509_QUERY_MATCH_KEY_HASH_SHA1@GOTPAGE
Lloh66:
	ldr	x9, [x9, _HX509_QUERY_MATCH_KEY_HASH_SHA1@GOTPAGEOFF]
Lloh67:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_49
; %bb.47:
	ldp	w9, w8, [x22, #8]
	add	w10, w9, #7
	cmp	w9, #0
	csel	w9, w10, w9, lt
	asr	w9, w9, #3
	stp	w9, w8, [sp]
	bl	_hx509_signature_sha1
	mov	x2, x0
	ldr	w4, [x19, #32]
	mov	x3, sp
	mov	x0, x20
	mov	x1, #0
	bl	__hx509_verify_signature
	cbnz	w0, LBB0_20
; %bb.48:
	ldr	w8, [x19]
LBB0_49:
Lloh68:
	adrp	x9, _HX509_QUERY_MATCH_TIME@GOTPAGE
Lloh69:
	ldr	x9, [x9, _HX509_QUERY_MATCH_TIME@GOTPAGEOFF]
Lloh70:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_53
; %bb.50:
	add	x0, x22, #4
	bl	__hx509_Time2time_t
	ldr	x8, [x19, #16]
	cmp	x0, x8
	b.gt	LBB0_20
; %bb.51:
	mov	x0, x22
	bl	__hx509_Time2time_t
	ldr	x8, [x19, #16]
	cmp	x0, x8
	b.lt	LBB0_20
; %bb.52:
	ldr	w8, [x19]
LBB0_53:
Lloh71:
	adrp	x9, _HX509_QUERY_MATCH_EKU@GOTPAGE
Lloh72:
	ldr	x9, [x9, _HX509_QUERY_MATCH_EKU@GOTPAGEOFF]
Lloh73:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_56
; %bb.54:
	ldr	w2, [x19, #28]
	mov	x0, x20
	mov	x1, x21
	mov	w3, #0
	bl	_hx509_cert_check_eku
	mov	x8, x0
	mov	w0, #0
	cbnz	x8, LBB0_21
; %bb.55:
	ldr	w8, [x19]
LBB0_56:
Lloh74:
	adrp	x9, _HX509_QUERY_MATCH_EXPR@GOTPAGE
Lloh75:
	ldr	x9, [x9, _HX509_QUERY_MATCH_EXPR@GOTPAGEOFF]
Lloh76:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_60
; %bb.57:
	str	xzr, [sp]
	mov	x2, sp
	mov	x0, x20
	mov	x1, x21
	bl	__hx509_cert_to_env
	cbnz	w0, LBB0_20
; %bb.58:
	ldr	x1, [sp]
	ldr	w2, [x19, #24]
	mov	x0, x20
	bl	__hx509_expr_eval
	mov	x20, x0
	mov	x0, sp
	bl	_hx509_env_free
	cbz	w20, LBB0_20
; %bb.59:
	ldr	w8, [x19]
LBB0_60:
Lloh77:
	adrp	x9, _HX509_QUERY_MASK@GOTPAGE
Lloh78:
	ldr	x9, [x9, _HX509_QUERY_MASK@GOTPAGEOFF]
Lloh79:
	ldr	w9, [x9]
	bics	wzr, w8, w9
	cset	w0, eq
	b	LBB0_21
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpLdrGot	Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGotLdr	Lloh62, Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh65, Lloh66, Lloh67
	.loh AdrpLdrGotLdr	Lloh68, Lloh69, Lloh70
	.loh AdrpLdrGotLdr	Lloh71, Lloh72, Lloh73
	.loh AdrpLdrGotLdr	Lloh74, Lloh75, Lloh76
	.loh AdrpLdrGotLdr	Lloh77, Lloh78, Lloh79
	.cfi_endproc
                                        ; -- End function
	.comm	_HX509_QUERY_FIND_ISSUER_CERT,4,2 ; @HX509_QUERY_FIND_ISSUER_CERT
	.comm	_HX509_QUERY_MATCH_CERTIFICATE,4,2 ; @HX509_QUERY_MATCH_CERTIFICATE
	.comm	_HX509_QUERY_MATCH_SERIALNUMBER,4,2 ; @HX509_QUERY_MATCH_SERIALNUMBER
	.comm	_HX509_QUERY_MATCH_ISSUER_NAME,4,2 ; @HX509_QUERY_MATCH_ISSUER_NAME
	.comm	_HX509_QUERY_MATCH_SUBJECT_NAME,4,2 ; @HX509_QUERY_MATCH_SUBJECT_NAME
	.comm	_HX509_QUERY_MATCH_SUBJECT_KEY_ID,4,2 ; @HX509_QUERY_MATCH_SUBJECT_KEY_ID
	.comm	_HX509_QUERY_MATCH_ISSUER_ID,4,2 ; @HX509_QUERY_MATCH_ISSUER_ID
	.comm	_HX509_QUERY_PRIVATE_KEY,4,2    ; @HX509_QUERY_PRIVATE_KEY
	.comm	_HX509_QUERY_KU_DIGITALSIGNATURE,4,2 ; @HX509_QUERY_KU_DIGITALSIGNATURE
	.comm	_HX509_QUERY_KU_NONREPUDIATION,4,2 ; @HX509_QUERY_KU_NONREPUDIATION
	.comm	_HX509_QUERY_KU_ENCIPHERMENT,4,2 ; @HX509_QUERY_KU_ENCIPHERMENT
	.comm	_HX509_QUERY_KU_DATAENCIPHERMENT,4,2 ; @HX509_QUERY_KU_DATAENCIPHERMENT
	.comm	_HX509_QUERY_KU_KEYAGREEMENT,4,2 ; @HX509_QUERY_KU_KEYAGREEMENT
	.comm	_HX509_QUERY_KU_KEYCERTSIGN,4,2 ; @HX509_QUERY_KU_KEYCERTSIGN
	.comm	_HX509_QUERY_KU_CRLSIGN,4,2     ; @HX509_QUERY_KU_CRLSIGN
	.comm	_TRUE,4,2                       ; @TRUE
	.comm	_HX509_QUERY_ANCHOR,4,2         ; @HX509_QUERY_ANCHOR
	.comm	_HX509_QUERY_MATCH_LOCAL_KEY_ID,4,2 ; @HX509_QUERY_MATCH_LOCAL_KEY_ID
	.comm	_asn1_oid_id_pkcs_9_at_localKeyId,4,2 ; @asn1_oid_id_pkcs_9_at_localKeyId
	.comm	_HX509_QUERY_NO_MATCH_PATH,4,2  ; @HX509_QUERY_NO_MATCH_PATH
	.comm	_HX509_QUERY_MATCH_FRIENDLY_NAME,4,2 ; @HX509_QUERY_MATCH_FRIENDLY_NAME
	.comm	_HX509_QUERY_MATCH_FUNCTION,4,2 ; @HX509_QUERY_MATCH_FUNCTION
	.comm	_HX509_QUERY_MATCH_KEY_HASH_SHA1,4,2 ; @HX509_QUERY_MATCH_KEY_HASH_SHA1
	.comm	_HX509_QUERY_MATCH_TIME,4,2     ; @HX509_QUERY_MATCH_TIME
	.comm	_HX509_QUERY_MATCH_EKU,4,2      ; @HX509_QUERY_MATCH_EKU
	.comm	_HX509_QUERY_MATCH_EXPR,4,2     ; @HX509_QUERY_MATCH_EXPR
	.comm	_HX509_QUERY_MASK,4,2           ; @HX509_QUERY_MASK
.subsections_via_symbols
