	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tls_crypt_v2_init_client_key   ## -- Begin function tls_crypt_v2_init_client_key
	.p2align	4, 0x90
_tls_crypt_v2_init_client_key:          ## @tls_crypt_v2_init_client_key
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r12
	movq	%rdx, %rbx
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	_TLS_CRYPT_V2_CLIENT_KEY_LEN@GOTPCREL(%rip), %rax
	movq	_TLS_CRYPT_V2_MAX_WKC_LEN@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdi
	addq	(%rax), %rdi
	callq	_alloc_buf
	movl	%eax, -40(%rbp)
	movq	_tls_crypt_v2_cli_pem_name@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-40(%rbp), %rdi
	movq	%rbx, %rdx
	movq	%r12, %rcx
	callq	_read_pem_key_file
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	movq	_M_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_msg
LBB0_2:
	leaq	-40(%rbp), %rdi
	leaq	-48(%rbp), %rsi
	movl	$4, %edx
	callq	_buf_read
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	movq	_M_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_msg
LBB0_4:
	leaq	-48(%rbp), %rbx
	movq	%r15, %rdi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_tls_crypt_v2_load_client_key
	movq	%rbx, %rdi
	movl	$4, %esi
	callq	_secure_memzero
	movl	-40(%rbp), %eax
	movl	%eax, (%r14)
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TLS_CRYPT_V2_CLIENT_KEY_LEN,8,3 ## @TLS_CRYPT_V2_CLIENT_KEY_LEN
	.comm	_TLS_CRYPT_V2_MAX_WKC_LEN,8,3   ## @TLS_CRYPT_V2_MAX_WKC_LEN
	.comm	_tls_crypt_v2_cli_pem_name,4,2  ## @tls_crypt_v2_cli_pem_name
	.comm	_M_FATAL,4,2                    ## @M_FATAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ERROR: invalid tls-crypt-v2 client key format"

L_.str.1:                               ## @.str.1
	.asciz	"ERROR: not enough data in tls-crypt-v2 client key"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tls_crypt_v2_init_client_key   ; -- Begin function tls_crypt_v2_init_client_key
	.p2align	2
_tls_crypt_v2_init_client_key:          ; @tls_crypt_v2_init_client_key
	.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, x3
	mov	x22, x2
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, _TLS_CRYPT_V2_CLIENT_KEY_LEN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TLS_CRYPT_V2_CLIENT_KEY_LEN@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
Lloh3:
	adrp	x9, _TLS_CRYPT_V2_MAX_WKC_LEN@GOTPAGE
Lloh4:
	ldr	x9, [x9, _TLS_CRYPT_V2_MAX_WKC_LEN@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_alloc_buf
	str	w0, [sp, #8]
Lloh6:
	adrp	x8, _tls_crypt_v2_cli_pem_name@GOTPAGE
Lloh7:
	ldr	x8, [x8, _tls_crypt_v2_cli_pem_name@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	add	x0, sp, #8
	mov	x2, x22
	mov	x3, x21
	bl	_read_pem_key_file
	cbnz	w0, LBB0_2
; %bb.1:
Lloh9:
	adrp	x8, _M_FATAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _M_FATAL@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_msg
LBB0_2:
	add	x0, sp, #8
	mov	x1, sp
	mov	w2, #4
	bl	_buf_read
	cbnz	w0, LBB0_4
; %bb.3:
Lloh14:
	adrp	x8, _M_FATAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _M_FATAL@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
Lloh17:
	adrp	x1, l_.str.1@PAGE
Lloh18:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_msg
LBB0_4:
	mov	x1, sp
	mov	x0, x20
	mov	w2, #0
	bl	_tls_crypt_v2_load_client_key
	mov	x0, sp
	mov	w1, #4
	bl	_secure_memzero
	ldr	w8, [sp, #8]
	str	w8, [x19]
	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	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_TLS_CRYPT_V2_CLIENT_KEY_LEN,8,3 ; @TLS_CRYPT_V2_CLIENT_KEY_LEN
	.comm	_TLS_CRYPT_V2_MAX_WKC_LEN,8,3   ; @TLS_CRYPT_V2_MAX_WKC_LEN
	.comm	_tls_crypt_v2_cli_pem_name,4,2  ; @tls_crypt_v2_cli_pem_name
	.comm	_M_FATAL,4,2                    ; @M_FATAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ERROR: invalid tls-crypt-v2 client key format"

l_.str.1:                               ; @.str.1
	.asciz	"ERROR: not enough data in tls-crypt-v2 client key"

.subsections_via_symbols
