	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ssl_parse_new_session_ticket
_ssl_parse_new_session_ticket:          ## @ssl_parse_new_session_ticket
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	leaq	L_.str(%rip), %rsi
	movl	$2, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movq	%r14, %rdi
	callq	_mbedtls_ssl_read_record
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rsi
	movl	$1, %edi
	movl	%eax, %edx
	callq	_MBEDTLS_SSL_DEBUG_RET
	jmp	LBB0_12
LBB0_2:
	movq	(%r14), %rax
	movq	_MBEDTLS_SSL_MSG_HANDSHAKE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.3:
	movq	8(%r14), %rax
	movq	(%rax), %rax
	movq	_MBEDTLS_SSL_HS_NEW_SESSION_TICKET@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_10
## %bb.4:
	movq	16(%r14), %rbx
	movq	%r14, %rdi
	callq	_mbedtls_ssl_hs_hdr_len
	addq	$6, %rax
	cmpq	%rax, %rbx
	jl	LBB0_10
## %bb.5:
	movq	8(%r14), %r13
	movq	%r14, %rdi
	callq	_mbedtls_ssl_hs_hdr_len
	movq	%rax, %r12
	movb	3(%r13,%rax,8), %bl
	movzwl	4(%r13,%rax,8), %eax
	rolw	$8, %ax
	movzwl	%ax, %r15d
	movq	%r14, %rdi
	callq	_mbedtls_ssl_hs_hdr_len
	addq	%r15, %rax
	addq	$6, %rax
	cmpq	16(%r14), %rax
	jne	LBB0_10
## %bb.6:
	movb	%bl, -41(%rbp)                  ## 1-byte Spill
	movl	$3, %edi
	movq	%r15, %rsi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movq	40(%r14), %rax
	movq	$0, (%rax)
	movq	_MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%r14)
	xorl	%ebx, %ebx
	testq	%r15, %r15
	je	LBB0_12
## %bb.7:
	movq	24(%r14), %rax
	movq	(%rax), %rdi
	movq	8(%rax), %rsi
	callq	_mbedtls_zeroize
	movq	24(%r14), %rax
	movq	(%rax), %rdi
	callq	_mbedtls_free
	movq	24(%r14), %rax
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%rax)
	movl	$1, %edi
	movq	%r15, %rsi
	callq	_mbedtls_calloc
	testq	%rax, %rax
	je	LBB0_13
## %bb.8:
	leaq	(,%r12,8), %rsi
	addq	%r13, %rsi
	addq	$6, %rsi
	movq	%rax, %rdi
	movq	%r15, %rdx
	movq	%rax, %r12
	callq	_memcpy
	movq	24(%r14), %rax
	movq	%r12, (%rax)
	movq	%r15, 8(%rax)
	movb	-41(%rbp), %cl                  ## 1-byte Reload
	movb	%cl, 16(%rax)
	leaq	L_.str.5(%rip), %rsi
	movl	$3, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	movq	24(%r14), %rax
	movq	$0, 24(%rax)
	leaq	L_.str.6(%rip), %rsi
	movl	$2, %edi
	callq	_MBEDTLS_SSL_DEBUG_MSG
	jmp	LBB0_12
LBB0_9:
	leaq	L_.str.2(%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_UNEXPECTED_MESSAGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_mbedtls_ssl_send_alert_message
	movq	_MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_10:
	leaq	L_.str.2(%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	%r14, %rdi
	callq	_mbedtls_ssl_send_alert_message
	movq	_MBEDTLS_ERR_SSL_BAD_HS_NEW_SESSION_TICKET@GOTPCREL(%rip), %rax
LBB0_11:
	movl	(%rax), %ebx
LBB0_12:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	leaq	L_.str.4(%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_INTERNAL_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_mbedtls_ssl_send_alert_message
	movq	_MBEDTLS_ERR_SSL_ALLOC_FAILED@GOTPCREL(%rip), %rax
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"=> parse new session ticket"

L_.str.1:                               ## @.str.1
	.asciz	"mbedtls_ssl_read_record"

	.comm	_MBEDTLS_SSL_MSG_HANDSHAKE,8,3  ## @MBEDTLS_SSL_MSG_HANDSHAKE
L_.str.2:                               ## @.str.2
	.asciz	"bad new session ticket message"

	.comm	_MBEDTLS_SSL_ALERT_LEVEL_FATAL,4,2 ## @MBEDTLS_SSL_ALERT_LEVEL_FATAL
	.comm	_MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE,4,2 ## @MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE
	.comm	_MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE,4,2 ## @MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE
	.comm	_MBEDTLS_SSL_HS_NEW_SESSION_TICKET,8,3 ## @MBEDTLS_SSL_HS_NEW_SESSION_TICKET
	.comm	_MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR,4,2 ## @MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR
	.comm	_MBEDTLS_ERR_SSL_BAD_HS_NEW_SESSION_TICKET,4,2 ## @MBEDTLS_ERR_SSL_BAD_HS_NEW_SESSION_TICKET
	.comm	_MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC,4,2 ## @MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC
L_.str.4:                               ## @.str.4
	.asciz	"ticket alloc failed"

	.comm	_MBEDTLS_SSL_ALERT_MSG_INTERNAL_ERROR,4,2 ## @MBEDTLS_SSL_ALERT_MSG_INTERNAL_ERROR
	.comm	_MBEDTLS_ERR_SSL_ALLOC_FAILED,4,2 ## @MBEDTLS_ERR_SSL_ALLOC_FAILED
L_.str.5:                               ## @.str.5
	.asciz	"ticket in use, discarding session id"

L_.str.6:                               ## @.str.6
	.asciz	"<= parse new session ticket"

	.no_dead_strip	_ssl_parse_new_session_ticket
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ssl_parse_new_session_ticket
_ssl_parse_new_session_ticket:          ; @ssl_parse_new_session_ticket
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #2
	bl	_MBEDTLS_SSL_DEBUG_MSG
	mov	x0, x19
	bl	_mbedtls_ssl_read_record
	cbz	w0, LBB0_2
; %bb.1:
	mov	x20, x0
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w0, #1
	mov	x2, x20
	bl	_MBEDTLS_SSL_DEBUG_RET
	b	LBB0_12
LBB0_2:
	ldr	x8, [x19]
Lloh4:
	adrp	x9, _MBEDTLS_SSL_MSG_HANDSHAKE@GOTPAGE
Lloh5:
	ldr	x9, [x9, _MBEDTLS_SSL_MSG_HANDSHAKE@GOTPAGEOFF]
Lloh6:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_9
; %bb.3:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
Lloh7:
	adrp	x9, _MBEDTLS_SSL_HS_NEW_SESSION_TICKET@GOTPAGE
Lloh8:
	ldr	x9, [x9, _MBEDTLS_SSL_HS_NEW_SESSION_TICKET@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_10
; %bb.4:
	ldr	x20, [x19, #16]
	mov	x0, x19
	bl	_mbedtls_ssl_hs_hdr_len
	add	x8, x0, #6
	cmp	x20, x8
	b.lt	LBB0_10
; %bb.5:
	ldr	x20, [x19, #8]
	mov	x0, x19
	bl	_mbedtls_ssl_hs_hdr_len
	add	x23, x20, x0, lsl #3
	ldrb	w22, [x23, #3]
	ldrh	w8, [x23, #4]
	rev16	w20, w8
	mov	x0, x19
	bl	_mbedtls_ssl_hs_hdr_len
	add	x8, x0, x20
	add	x8, x8, #6
	ldr	x9, [x19, #16]
	cmp	x8, x9
	b.ne	LBB0_10
; %bb.6:
	mov	w0, #3
	mov	x1, x20
	bl	_MBEDTLS_SSL_DEBUG_MSG
	ldr	x8, [x19, #40]
	str	xzr, [x8]
Lloh10:
	adrp	x8, _MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	str	w8, [x19, #32]
	cbz	x20, LBB0_12
; %bb.7:
	ldr	x8, [x19, #24]
	ldp	x0, x1, [x8]
	bl	_mbedtls_zeroize
	ldr	x8, [x19, #24]
	ldr	x0, [x8]
	bl	_mbedtls_free
	ldr	x8, [x19, #24]
	stp	xzr, xzr, [x8]
	mov	w0, #1
	mov	x1, x20
	bl	_mbedtls_calloc
	cbz	x0, LBB0_13
; %bb.8:
	mov	x21, x0
	add	x1, x23, #6
	mov	x2, x20
	bl	_memcpy
	ldr	x8, [x19, #24]
	stp	x21, x20, [x8]
	strb	w22, [x8, #16]
Lloh13:
	adrp	x1, l_.str.5@PAGE
Lloh14:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	w0, #3
	bl	_MBEDTLS_SSL_DEBUG_MSG
	ldr	x8, [x19, #24]
	str	xzr, [x8, #24]
Lloh15:
	adrp	x1, l_.str.6@PAGE
Lloh16:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	w0, #2
	bl	_MBEDTLS_SSL_DEBUG_MSG
	mov	w20, #0
	b	LBB0_12
LBB0_9:
Lloh17:
	adrp	x1, l_.str.2@PAGE
Lloh18:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	bl	_MBEDTLS_SSL_DEBUG_MSG
Lloh19:
	adrp	x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGE
Lloh20:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGEOFF]
Lloh21:
	ldr	w1, [x8]
Lloh22:
	adrp	x8, _MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE@GOTPAGE
Lloh23:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE@GOTPAGEOFF]
Lloh24:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_mbedtls_ssl_send_alert_message
Lloh25:
	adrp	x8, _MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE@GOTPAGE
Lloh26:
	ldr	x8, [x8, _MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE@GOTPAGEOFF]
	b	LBB0_11
LBB0_10:
Lloh27:
	adrp	x1, l_.str.2@PAGE
Lloh28:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	bl	_MBEDTLS_SSL_DEBUG_MSG
Lloh29:
	adrp	x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGE
Lloh30:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGEOFF]
Lloh31:
	ldr	w1, [x8]
Lloh32:
	adrp	x8, _MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR@GOTPAGE
Lloh33:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR@GOTPAGEOFF]
Lloh34:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_mbedtls_ssl_send_alert_message
Lloh35:
	adrp	x8, _MBEDTLS_ERR_SSL_BAD_HS_NEW_SESSION_TICKET@GOTPAGE
Lloh36:
	ldr	x8, [x8, _MBEDTLS_ERR_SSL_BAD_HS_NEW_SESSION_TICKET@GOTPAGEOFF]
LBB0_11:
	ldr	w20, [x8]
LBB0_12:
	mov	x0, x20
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_13:
Lloh37:
	adrp	x1, l_.str.4@PAGE
Lloh38:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	w0, #1
	bl	_MBEDTLS_SSL_DEBUG_MSG
Lloh39:
	adrp	x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGE
Lloh40:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_LEVEL_FATAL@GOTPAGEOFF]
Lloh41:
	ldr	w1, [x8]
Lloh42:
	adrp	x8, _MBEDTLS_SSL_ALERT_MSG_INTERNAL_ERROR@GOTPAGE
Lloh43:
	ldr	x8, [x8, _MBEDTLS_SSL_ALERT_MSG_INTERNAL_ERROR@GOTPAGEOFF]
Lloh44:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_mbedtls_ssl_send_alert_message
Lloh45:
	adrp	x8, _MBEDTLS_ERR_SSL_ALLOC_FAILED@GOTPAGE
Lloh46:
	ldr	x8, [x8, _MBEDTLS_ERR_SSL_ALLOC_FAILED@GOTPAGEOFF]
	b	LBB0_11
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"=> parse new session ticket"

l_.str.1:                               ; @.str.1
	.asciz	"mbedtls_ssl_read_record"

	.comm	_MBEDTLS_SSL_MSG_HANDSHAKE,8,3  ; @MBEDTLS_SSL_MSG_HANDSHAKE
l_.str.2:                               ; @.str.2
	.asciz	"bad new session ticket message"

	.comm	_MBEDTLS_SSL_ALERT_LEVEL_FATAL,4,2 ; @MBEDTLS_SSL_ALERT_LEVEL_FATAL
	.comm	_MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE,4,2 ; @MBEDTLS_SSL_ALERT_MSG_UNEXPECTED_MESSAGE
	.comm	_MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE,4,2 ; @MBEDTLS_ERR_SSL_UNEXPECTED_MESSAGE
	.comm	_MBEDTLS_SSL_HS_NEW_SESSION_TICKET,8,3 ; @MBEDTLS_SSL_HS_NEW_SESSION_TICKET
	.comm	_MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR,4,2 ; @MBEDTLS_SSL_ALERT_MSG_DECODE_ERROR
	.comm	_MBEDTLS_ERR_SSL_BAD_HS_NEW_SESSION_TICKET,4,2 ; @MBEDTLS_ERR_SSL_BAD_HS_NEW_SESSION_TICKET
	.comm	_MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC,4,2 ; @MBEDTLS_SSL_SERVER_CHANGE_CIPHER_SPEC
l_.str.4:                               ; @.str.4
	.asciz	"ticket alloc failed"

	.comm	_MBEDTLS_SSL_ALERT_MSG_INTERNAL_ERROR,4,2 ; @MBEDTLS_SSL_ALERT_MSG_INTERNAL_ERROR
	.comm	_MBEDTLS_ERR_SSL_ALLOC_FAILED,4,2 ; @MBEDTLS_ERR_SSL_ALLOC_FAILED
l_.str.5:                               ; @.str.5
	.asciz	"ticket in use, discarding session id"

l_.str.6:                               ; @.str.6
	.asciz	"<= parse new session ticket"

	.no_dead_strip	_ssl_parse_new_session_ticket
.subsections_via_symbols
