	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ssl_srv_parse_truncated_hmac_ext
_ssl_srv_parse_truncated_hmac_ext:      ## @ssl_srv_parse_truncated_hmac_ext
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	testq	%rdx, %rdx
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movq	_MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_mbedtls_ssl_send_alert_message
	movq	_MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_4
LBB0_2:
	movq	8(%rbx), %rax
	movq	(%rax), %rcx
	movq	_MBEDTLS_SSL_TRUNC_HMAC_ENABLED@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	cmpq	(%rdx), %rcx
	jne	LBB0_4
## %bb.3:
	movq	(%rbx), %rdx
	movq	%rcx, (%rdx)
LBB0_4:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"bad client hello message"

	.comm	_MBEDTLS_SSL_ALERT_LEVEL_FATAL,4,2 ## @MBEDTLS_SSL_ALERT_LEVEL_FATAL
	.comm	_MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR,4,2 ## @MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR
	.comm	_MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO,4,2 ## @MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO
	.comm	_MBEDTLS_SSL_TRUNC_HMAC_ENABLED,8,3 ## @MBEDTLS_SSL_TRUNC_HMAC_ENABLED
	.no_dead_strip	_ssl_srv_parse_truncated_hmac_ext
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ssl_srv_parse_truncated_hmac_ext
_ssl_srv_parse_truncated_hmac_ext:      ; @ssl_srv_parse_truncated_hmac_ext
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	cbz	x2, LBB0_2
; %bb.1:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_MBEDTLS_SSL_DEBUG_MSG
Lloh2:
	adrp	x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x8, _MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_mbedtls_ssl_send_alert_message
Lloh8:
	adrp	x8, _MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	b	LBB0_5
LBB0_2:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
Lloh11:
	adrp	x9, _MBEDTLS_SSL_TRUNC_HMAC_ENABLED@GOTPAGE
Lloh12:
	ldr	x9, [x9, _MBEDTLS_SSL_TRUNC_HMAC_ENABLED@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.3:
	mov	w0, #0
	ldr	x9, [x19]
	str	x8, [x9]
	b	LBB0_5
LBB0_4:
	mov	w0, #0
LBB0_5:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"bad client hello message"

	.comm	_MBEDTLS_SSL_ALERT_LEVEL_FATAL,4,2 ; @MBEDTLS_SSL_ALERT_LEVEL_FATAL
	.comm	_MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR,4,2 ; @MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR
	.comm	_MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO,4,2 ; @MBEDTLS_ERR_SSL_BAD_HS_CLIENT_HELLO
	.comm	_MBEDTLS_SSL_TRUNC_HMAC_ENABLED,8,3 ; @MBEDTLS_SSL_TRUNC_HMAC_ENABLED
	.no_dead_strip	_ssl_srv_parse_truncated_hmac_ext
.subsections_via_symbols
