	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ssl_write_certificate_request
_ssl_write_certificate_request:         ## @ssl_write_certificate_request
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	48(%rdi), %rax
	movq	(%rax), %r14
	movq	_MBEDTLS_SSL_MAX_CONTENT_LEN@GOTPCREL(%rip), %rax
	movslq	(%rax), %r12
	addq	(%rdi), %r12
	leaq	L_.str(%rip), %rsi
	movl	$2, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	incl	40(%rbx)
	movq	(%r14), %rax
	movq	_MBEDTLS_KEY_EXCHANGE_PSK@GOTPCREL(%rip), %rcx
	xorl	%r14d, %r14d
	leaq	L_.str.1(%rip), %rsi
	cmpq	(%rcx), %rax
	je	LBB0_17
## %bb.1:
	movq	_MBEDTLS_KEY_EXCHANGE_RSA_PSK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_17
## %bb.2:
	movq	_MBEDTLS_KEY_EXCHANGE_DHE_PSK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_17
## %bb.3:
	movq	_MBEDTLS_KEY_EXCHANGE_ECDHE_PSK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_17
## %bb.4:
	movq	_MBEDTLS_KEY_EXCHANGE_ECJPAKE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_17
## %bb.5:
	movq	24(%rbx), %rax
	movq	_MBEDTLS_SSL_VERIFY_NONE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	cmpl	%ecx, (%rax)
	je	LBB0_17
## %bb.6:
	movq	(%rbx), %rcx
	movb	$0, 4(%rcx)
	movq	%rcx, %rax
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	leaq	7(%rcx), %r14
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	movq	24(%rbx), %rax
	movq	16(%rax), %rcx
	movq	_MBEDTLS_SSL_CERT_REQ_CA_LIST_ENABLED@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_7
## %bb.8:
	movq	24(%rax), %r13
	xorl	%edx, %edx
	testq	%r13, %r13
	je	LBB0_16
## %bb.9:
	movq	%r12, -72(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	cmpq	$0, (%r13)
	je	LBB0_16
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	movq	%r12, %rax
	subq	%r14, %rax
	jb	LBB0_14
## %bb.12:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	16(%r13), %rbx
	cmpq	%rbx, %rax
	jb	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_10 Depth=1
	leaq	2(%rbx), %r15
	cmpq	%r15, %rax
	jb	LBB0_14
## %bb.15:                              ##   in Loop: Header=BB0_10 Depth=1
	leaq	2(%r14), %r12
	movl	%ebx, %eax
	rolw	$8, %ax
	movw	%ax, (%r14)
	movl	24(%r13), %esi
	movq	%r12, %rdi
	movq	%rbx, %rdx
	callq	_memcpy
	addq	%rbx, %r14
	addq	$2, %r14
	movl	$3, %edi
	leaq	L_.str.3(%rip), %rsi
	movq	%r12, %rdx
	movq	-72(%rbp), %r12                 ## 8-byte Reload
	movq	%rbx, %rcx
	callq	_MBEDTLS_SSL_DEBUG_BUF
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	addq	%r15, %rdx
	movq	8(%r13), %r13
	testq	%r13, %r13
	jne	LBB0_10
	jmp	LBB0_16
LBB0_7:
	xorl	%edx, %edx
	jmp	LBB0_16
LBB0_14:
	leaq	L_.str.2(%rip), %rsi
	movl	$1, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
LBB0_16:
	subl	-56(%rbp), %r14d                ## 4-byte Folded Reload
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movl	%r14d, 16(%rdi)
	movq	_MBEDTLS_SSL_MSG_HANDSHAKE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 20(%rdi)
	movq	_MBEDTLS_SSL_HS_CERTIFICATE_REQUEST@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movq	(%rdi), %rcx
	movb	%al, (%rcx)
	movq	(%rdi), %rax
	movb	%dh, 5(%rax)
	movq	(%rdi), %rax
	movb	%dl, 6(%rax)
	callq	_mbedtls_ssl_write_record
	movl	%eax, %r14d
	leaq	L_.str.4(%rip), %rsi
LBB0_17:
	movl	$2, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movl	%r14d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MBEDTLS_ERR_SSL_FEATURE_UNAVAILABLE,4,2 ## @MBEDTLS_ERR_SSL_FEATURE_UNAVAILABLE
	.comm	_MBEDTLS_SSL_MAX_CONTENT_LEN,4,2 ## @MBEDTLS_SSL_MAX_CONTENT_LEN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"=> write certificate request"

	.comm	_MBEDTLS_KEY_EXCHANGE_PSK,8,3   ## @MBEDTLS_KEY_EXCHANGE_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_RSA_PSK,8,3 ## @MBEDTLS_KEY_EXCHANGE_RSA_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_DHE_PSK,8,3 ## @MBEDTLS_KEY_EXCHANGE_DHE_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_ECDHE_PSK,8,3 ## @MBEDTLS_KEY_EXCHANGE_ECDHE_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_ECJPAKE,8,3 ## @MBEDTLS_KEY_EXCHANGE_ECJPAKE
	.comm	_MBEDTLS_SSL_VERIFY_NONE,4,2    ## @MBEDTLS_SSL_VERIFY_NONE
L_.str.1:                               ## @.str.1
	.asciz	"<= skip write certificate request"

	.comm	_MBEDTLS_SSL_CERT_REQ_CA_LIST_ENABLED,8,3 ## @MBEDTLS_SSL_CERT_REQ_CA_LIST_ENABLED
L_.str.2:                               ## @.str.2
	.asciz	"skipping CAs: buffer too short"

L_.str.3:                               ## @.str.3
	.asciz	"requested DN"

	.comm	_MBEDTLS_SSL_MSG_HANDSHAKE,4,2  ## @MBEDTLS_SSL_MSG_HANDSHAKE
	.comm	_MBEDTLS_SSL_HS_CERTIFICATE_REQUEST,1,0 ## @MBEDTLS_SSL_HS_CERTIFICATE_REQUEST
L_.str.4:                               ## @.str.4
	.asciz	"<= write certificate request"

	.comm	_MBEDTLS_MD_NONE,4,2            ## @MBEDTLS_MD_NONE
	.comm	_MBEDTLS_SSL_CERT_TYPE_ECDSA_SIGN,1,0 ## @MBEDTLS_SSL_CERT_TYPE_ECDSA_SIGN
	.comm	_MBEDTLS_SSL_CERT_TYPE_RSA_SIGN,1,0 ## @MBEDTLS_SSL_CERT_TYPE_RSA_SIGN
	.comm	_MBEDTLS_SSL_HASH_NONE,1,0      ## @MBEDTLS_SSL_HASH_NONE
	.comm	_MBEDTLS_SSL_MINOR_VERSION_3,8,3 ## @MBEDTLS_SSL_MINOR_VERSION_3
	.comm	_MBEDTLS_SSL_SIG_ECDSA,1,0      ## @MBEDTLS_SSL_SIG_ECDSA
	.comm	_MBEDTLS_SSL_SIG_RSA,1,0        ## @MBEDTLS_SSL_SIG_RSA
	.comm	_MBEDTLS_SSL_VERIFY_UNSET,4,2   ## @MBEDTLS_SSL_VERIFY_UNSET
	.no_dead_strip	_ssl_write_certificate_request
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ssl_write_certificate_request
_ssl_write_certificate_request:         ; @ssl_write_certificate_request
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
	ldr	x8, [x0, #48]
	ldr	x22, [x8]
	ldr	x20, [x0]
Lloh0:
	adrp	x8, _MBEDTLS_SSL_MAX_CONTENT_LEN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MBEDTLS_SSL_MAX_CONTENT_LEN@GOTPAGEOFF]
Lloh2:
	ldrsw	x21, [x8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #2
	bl	_MBEDTLS_SSL_DEBUG_MSG
	ldr	w8, [x19, #40]
	add	w8, w8, #1
	str	w8, [x19, #40]
	ldr	x8, [x19, #24]
	ldr	w8, [x8]
	ldr	x9, [x22]
Lloh5:
	adrp	x10, _MBEDTLS_KEY_EXCHANGE_PSK@GOTPAGE
Lloh6:
	ldr	x10, [x10, _MBEDTLS_KEY_EXCHANGE_PSK@GOTPAGEOFF]
Lloh7:
	ldr	x10, [x10]
Lloh8:
	adrp	x11, _MBEDTLS_KEY_EXCHANGE_RSA_PSK@GOTPAGE
Lloh9:
	ldr	x11, [x11, _MBEDTLS_KEY_EXCHANGE_RSA_PSK@GOTPAGEOFF]
Lloh10:
	ldr	x11, [x11]
Lloh11:
	adrp	x12, _MBEDTLS_KEY_EXCHANGE_DHE_PSK@GOTPAGE
Lloh12:
	ldr	x12, [x12, _MBEDTLS_KEY_EXCHANGE_DHE_PSK@GOTPAGEOFF]
Lloh13:
	ldr	x12, [x12]
Lloh14:
	adrp	x13, _MBEDTLS_KEY_EXCHANGE_ECDHE_PSK@GOTPAGE
Lloh15:
	ldr	x13, [x13, _MBEDTLS_KEY_EXCHANGE_ECDHE_PSK@GOTPAGEOFF]
Lloh16:
	ldr	x13, [x13]
Lloh17:
	adrp	x14, _MBEDTLS_KEY_EXCHANGE_ECJPAKE@GOTPAGE
Lloh18:
	ldr	x14, [x14, _MBEDTLS_KEY_EXCHANGE_ECJPAKE@GOTPAGEOFF]
Lloh19:
	ldr	x14, [x14]
Lloh20:
	adrp	x15, _MBEDTLS_SSL_VERIFY_NONE@GOTPAGE
Lloh21:
	ldr	x15, [x15, _MBEDTLS_SSL_VERIFY_NONE@GOTPAGEOFF]
Lloh22:
	ldr	w15, [x15]
	cmp	x9, x10
	ccmp	x9, x11, #4, ne
	ccmp	x9, x12, #4, ne
	ccmp	x9, x13, #4, ne
	ccmp	x9, x14, #4, ne
	ccmp	w8, w15, #4, ne
	b.ne	LBB0_2
; %bb.1:
	mov	w19, #0
Lloh23:
	adrp	x1, l_.str.1@PAGE
Lloh24:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_13
LBB0_2:
	ldr	x23, [x19]
	strb	wzr, [x23, #4]
	add	x26, x23, #7
	ldr	x8, [x19, #24]
	ldr	x9, [x8, #16]
Lloh25:
	adrp	x10, _MBEDTLS_SSL_CERT_REQ_CA_LIST_ENABLED@GOTPAGE
Lloh26:
	ldr	x10, [x10, _MBEDTLS_SSL_CERT_REQ_CA_LIST_ENABLED@GOTPAGEOFF]
Lloh27:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_9
; %bb.3:
	ldr	x25, [x8, #24]
	cbz	x25, LBB0_9
; %bb.4:
	mov	x24, #0
	add	x27, x20, x21
	mov	x20, x26
Lloh28:
	adrp	x21, l_.str.3@PAGE
Lloh29:
	add	x21, x21, l_.str.3@PAGEOFF
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x25]
	cbz	x8, LBB0_11
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	subs	x8, x27, x20
	b.lo	LBB0_10
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x22, [x25, #16]
	cmp	x8, x22
	add	x28, x22, #2
	ccmp	x8, x28, #0, hs
	b.lo	LBB0_10
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	rev	w8, w22
	lsr	w8, w8, #16
	strh	w8, [x20], #2
	ldr	w1, [x25, #24]
	mov	x0, x20
	mov	x2, x22
	bl	_memcpy
	add	x26, x20, x22
	mov	w0, #3
	mov	x1, x21
	mov	x2, x20
	mov	x3, x22
	bl	_MBEDTLS_SSL_DEBUG_BUF
	add	x24, x28, x24
	ldr	x25, [x25, #8]
	mov	x20, x26
	cbnz	x25, LBB0_5
	b	LBB0_12
LBB0_9:
	mov	x24, #0
	b	LBB0_12
LBB0_10:
Lloh30:
	adrp	x1, l_.str.2@PAGE
Lloh31:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	bl	_MBEDTLS_SSL_DEBUG_MSG
LBB0_11:
	mov	x26, x20
LBB0_12:
	sub	w8, w26, w23
Lloh32:
	adrp	x9, _MBEDTLS_SSL_MSG_HANDSHAKE@GOTPAGE
Lloh33:
	ldr	x9, [x9, _MBEDTLS_SSL_MSG_HANDSHAKE@GOTPAGEOFF]
Lloh34:
	ldr	w9, [x9]
	stp	w8, w9, [x19, #16]
Lloh35:
	adrp	x8, _MBEDTLS_SSL_HS_CERTIFICATE_REQUEST@GOTPAGE
Lloh36:
	ldr	x8, [x8, _MBEDTLS_SSL_HS_CERTIFICATE_REQUEST@GOTPAGEOFF]
	ldrb	w8, [x8]
	ldr	x9, [x19]
	strb	w8, [x9]
	lsr	x8, x24, #8
	ldr	x9, [x19]
	strb	w8, [x9, #5]
	ldr	x8, [x19]
	strb	w24, [x8, #6]
	mov	x0, x19
	bl	_mbedtls_ssl_write_record
	mov	x19, x0
Lloh37:
	adrp	x1, l_.str.4@PAGE
Lloh38:
	add	x1, x1, l_.str.4@PAGEOFF
LBB0_13:
	mov	w0, #2
	bl	_MBEDTLS_SSL_DEBUG_MSG
	mov	x0, x19
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_MBEDTLS_ERR_SSL_FEATURE_UNAVAILABLE,4,2 ; @MBEDTLS_ERR_SSL_FEATURE_UNAVAILABLE
	.comm	_MBEDTLS_SSL_MAX_CONTENT_LEN,4,2 ; @MBEDTLS_SSL_MAX_CONTENT_LEN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"=> write certificate request"

	.comm	_MBEDTLS_KEY_EXCHANGE_PSK,8,3   ; @MBEDTLS_KEY_EXCHANGE_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_RSA_PSK,8,3 ; @MBEDTLS_KEY_EXCHANGE_RSA_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_DHE_PSK,8,3 ; @MBEDTLS_KEY_EXCHANGE_DHE_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_ECDHE_PSK,8,3 ; @MBEDTLS_KEY_EXCHANGE_ECDHE_PSK
	.comm	_MBEDTLS_KEY_EXCHANGE_ECJPAKE,8,3 ; @MBEDTLS_KEY_EXCHANGE_ECJPAKE
	.comm	_MBEDTLS_SSL_VERIFY_NONE,4,2    ; @MBEDTLS_SSL_VERIFY_NONE
l_.str.1:                               ; @.str.1
	.asciz	"<= skip write certificate request"

	.comm	_MBEDTLS_SSL_CERT_REQ_CA_LIST_ENABLED,8,3 ; @MBEDTLS_SSL_CERT_REQ_CA_LIST_ENABLED
l_.str.2:                               ; @.str.2
	.asciz	"skipping CAs: buffer too short"

l_.str.3:                               ; @.str.3
	.asciz	"requested DN"

	.comm	_MBEDTLS_SSL_MSG_HANDSHAKE,4,2  ; @MBEDTLS_SSL_MSG_HANDSHAKE
	.comm	_MBEDTLS_SSL_HS_CERTIFICATE_REQUEST,1,0 ; @MBEDTLS_SSL_HS_CERTIFICATE_REQUEST
l_.str.4:                               ; @.str.4
	.asciz	"<= write certificate request"

	.comm	_MBEDTLS_MD_NONE,4,2            ; @MBEDTLS_MD_NONE
	.comm	_MBEDTLS_SSL_CERT_TYPE_ECDSA_SIGN,1,0 ; @MBEDTLS_SSL_CERT_TYPE_ECDSA_SIGN
	.comm	_MBEDTLS_SSL_CERT_TYPE_RSA_SIGN,1,0 ; @MBEDTLS_SSL_CERT_TYPE_RSA_SIGN
	.comm	_MBEDTLS_SSL_HASH_NONE,1,0      ; @MBEDTLS_SSL_HASH_NONE
	.comm	_MBEDTLS_SSL_MINOR_VERSION_3,8,3 ; @MBEDTLS_SSL_MINOR_VERSION_3
	.comm	_MBEDTLS_SSL_SIG_ECDSA,1,0      ; @MBEDTLS_SSL_SIG_ECDSA
	.comm	_MBEDTLS_SSL_SIG_RSA,1,0        ; @MBEDTLS_SSL_SIG_RSA
	.comm	_MBEDTLS_SSL_VERIFY_UNSET,4,2   ; @MBEDTLS_SSL_VERIFY_UNSET
	.no_dead_strip	_ssl_write_certificate_request
.subsections_via_symbols
