	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tls_write_server_change_cipher_spec
_tls_write_server_change_cipher_spec:   ## @tls_write_server_change_cipher_spec
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	%rsi, %r14
	movq	%rdi, %r15
	leaq	L_.str(%rip), %rsi
	callq	_tlsv1_server_log
	movq	_TLS_CHANGE_CIPHER_SPEC@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -28(%rbp)
	movq	_TLS_CONTENT_TYPE_CHANGE_CIPHER_SPEC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	(%r14), %rdx
	subq	%rdx, %rbx
	shrq	$2, %rbx
	leaq	-40(%rbp), %rax
	movq	%rax, (%rsp)
	leaq	-28(%rbp), %r8
	movq	%r15, %rdi
	movl	%ebx, %ecx
	movl	$4, %r9d
	callq	_tlsv1_record_send
	testq	%rax, %rax
	js	LBB0_1
## %bb.3:
	movq	%r15, %rdi
	callq	_tlsv1_record_change_write_cipher
	testq	%rax, %rax
	js	LBB0_4
## %bb.5:
	movq	-40(%rbp), %rax
	shlq	$2, %rax
	addq	%rax, (%r14)
	xorl	%eax, %eax
	jmp	LBB0_6
LBB0_1:
	movq	_MSG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_2
LBB0_4:
	movq	_MSG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
LBB0_2:
	callq	_wpa_printf
	movq	_TLS_ALERT_LEVEL_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_TLS_ALERT_INTERNAL_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	callq	_tlsv1_server_alert
	movl	$-1, %eax
LBB0_6:
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Send ChangeCipherSpec"

	.comm	_TLS_CHANGE_CIPHER_SPEC,4,2     ## @TLS_CHANGE_CIPHER_SPEC
	.comm	_TLS_CONTENT_TYPE_CHANGE_CIPHER_SPEC,4,2 ## @TLS_CONTENT_TYPE_CHANGE_CIPHER_SPEC
	.comm	_MSG_DEBUG,4,2                  ## @MSG_DEBUG
L_.str.1:                               ## @.str.1
	.asciz	"TLSv1: Failed to create a record"

	.comm	_TLS_ALERT_LEVEL_FATAL,4,2      ## @TLS_ALERT_LEVEL_FATAL
	.comm	_TLS_ALERT_INTERNAL_ERROR,4,2   ## @TLS_ALERT_INTERNAL_ERROR
L_.str.2:                               ## @.str.2
	.asciz	"TLSv1: Failed to set write cipher for record layer"

	.no_dead_strip	_tls_write_server_change_cipher_spec
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tls_write_server_change_cipher_spec
_tls_write_server_change_cipher_spec:   ; @tls_write_server_change_cipher_spec
	.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	x21, x2
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_tlsv1_server_log
Lloh2:
	adrp	x8, _TLS_CHANGE_CIPHER_SPEC@GOTPAGE
Lloh3:
	ldr	x8, [x8, _TLS_CHANGE_CIPHER_SPEC@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [sp, #4]
Lloh5:
	adrp	x8, _TLS_CONTENT_TYPE_CHANGE_CIPHER_SPEC@GOTPAGE
Lloh6:
	ldr	x8, [x8, _TLS_CONTENT_TYPE_CHANGE_CIPHER_SPEC@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	ldr	x2, [x20]
	sub	x8, x21, x2
	lsr	x3, x8, #2
	add	x4, sp, #4
	add	x6, sp, #8
	mov	x0, x19
                                        ; kill: def $w3 killed $w3 killed $x3
	mov	w5, #4
	bl	_tlsv1_record_send
	tbnz	x0, #63, LBB0_3
; %bb.1:
	mov	x0, x19
	bl	_tlsv1_record_change_write_cipher
	tbnz	x0, #63, LBB0_4
; %bb.2:
	mov	w0, #0
	ldr	x8, [sp, #8]
	ldr	x9, [x20]
	add	x8, x9, x8, lsl #2
	str	x8, [x20]
	b	LBB0_6
LBB0_3:
Lloh8:
	adrp	x8, _MSG_DEBUG@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MSG_DEBUG@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_5
LBB0_4:
Lloh13:
	adrp	x8, _MSG_DEBUG@GOTPAGE
Lloh14:
	ldr	x8, [x8, _MSG_DEBUG@GOTPAGEOFF]
Lloh15:
	ldr	w0, [x8]
Lloh16:
	adrp	x1, l_.str.2@PAGE
Lloh17:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_5:
	bl	_wpa_printf
Lloh18:
	adrp	x8, _TLS_ALERT_LEVEL_FATAL@GOTPAGE
Lloh19:
	ldr	x8, [x8, _TLS_ALERT_LEVEL_FATAL@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
Lloh21:
	adrp	x8, _TLS_ALERT_INTERNAL_ERROR@GOTPAGE
Lloh22:
	ldr	x8, [x8, _TLS_ALERT_INTERNAL_ERROR@GOTPAGEOFF]
Lloh23:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_tlsv1_server_alert
	mov	w0, #-1
LBB0_6:
	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	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Send ChangeCipherSpec"

	.comm	_TLS_CHANGE_CIPHER_SPEC,4,2     ; @TLS_CHANGE_CIPHER_SPEC
	.comm	_TLS_CONTENT_TYPE_CHANGE_CIPHER_SPEC,4,2 ; @TLS_CONTENT_TYPE_CHANGE_CIPHER_SPEC
	.comm	_MSG_DEBUG,4,2                  ; @MSG_DEBUG
l_.str.1:                               ; @.str.1
	.asciz	"TLSv1: Failed to create a record"

	.comm	_TLS_ALERT_LEVEL_FATAL,4,2      ; @TLS_ALERT_LEVEL_FATAL
	.comm	_TLS_ALERT_INTERNAL_ERROR,4,2   ; @TLS_ALERT_INTERNAL_ERROR
l_.str.2:                               ; @.str.2
	.asciz	"TLSv1: Failed to set write cipher for record layer"

	.no_dead_strip	_tls_write_server_change_cipher_spec
.subsections_via_symbols
