	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function setup_cipher
_setup_cipher:                          ## @setup_cipher
	.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
	movl	%ecx, %r14d
	movq	%rdx, %r13
	movl	%esi, %r12d
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_crypto_tfm_ctx
	leaq	16(%rax), %r15
	movl	%r12d, -60(%rbp)                ## 4-byte Spill
	testl	%r12d, %r12d
	cmoveq	%rax, %r15
	movq	8(%r15), %r12
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	je	LBB0_2
## %bb.1:
	callq	_cipher_cfg_enc
	movl	%eax, %ebx
	movq	_NPE_OP_CRYPT_ENCRYPT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 4(%r15)
	jmp	LBB0_3
LBB0_2:
	callq	_cipher_cfg_dec
	movl	%eax, %ebx
LBB0_3:
	movq	_MOD_AES@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_13
## %bb.4:
	cmpl	$16, %r14d
	je	LBB0_5
## %bb.6:
	cmpl	$32, %r14d
	je	LBB0_11
## %bb.7:
	cmpl	$24, %r14d
	jne	LBB0_9
## %bb.8:
	movq	_KEYLEN_192@GOTPCREL(%rip), %rax
	movq	_MOD_AES192@GOTPCREL(%rip), %rcx
	jmp	LBB0_12
LBB0_13:
	movq	_MOD_3DES@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_19
## %bb.14:
	movl	8(%r13), %eax
	movl	12(%r13), %ecx
	cmpl	%eax, (%r13)
	jne	LBB0_16
## %bb.15:
	movl	$1, %edi
	cmpl	%ecx, 4(%r13)
	je	LBB0_17
LBB0_16:
	xorl	16(%r13), %eax
	xorl	20(%r13), %ecx
	xorl	%edi, %edi
	orl	%eax, %ecx
	sete	%dil
LBB0_17:
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_22
## %bb.18:
	movq	_CRYPTO_TFM_RES_BAD_KEY_SCHED@GOTPCREL(%rip), %rax
	jmp	LBB0_10
LBB0_5:
	movq	_KEYLEN_128@GOTPCREL(%rip), %rax
	movq	_MOD_AES128@GOTPCREL(%rip), %rcx
	jmp	LBB0_12
LBB0_11:
	movq	_KEYLEN_256@GOTPCREL(%rip), %rax
	movq	_MOD_AES256@GOTPCREL(%rip), %rcx
LBB0_12:
	movl	(%rax), %eax
	orl	(%rcx), %eax
	orl	%eax, %ebx
	jmp	LBB0_22
LBB0_9:
	movq	_CRYPTO_TFM_RES_BAD_KEY_LEN@GOTPCREL(%rip), %rax
LBB0_10:
	movl	(%rax), %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	orl	%eax, (%rcx)
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_28
LBB0_19:
	movq	%rsp, -72(%rbp)                 ## 8-byte Spill
	movq	_DES_EXPKEY_WORDS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shlq	$2, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rdi
	movq	%r13, %rsi
	callq	_des_ekey
	testq	%rax, %rax
	jne	LBB0_21
## %bb.20:
	movq	_CRYPTO_TFM_RES_WEAK_KEY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	orl	%eax, (%rcx)
LBB0_21:
	movq	-72(%rbp), %rsp                 ## 8-byte Reload
LBB0_22:
	movl	%ebx, %edi
	callq	_cpu_to_be32
	movl	%eax, (%r12)
	addq	$16, %r12
	movq	%r12, %rdi
	movq	%r13, %rsi
	movl	%r14d, %edx
	callq	_memcpy
	movq	_DES3_EDE_KEY_SIZE@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	movq	_MOD_AES@GOTPCREL(%rip), %rcx
	subl	%r14d, %edx
	jle	LBB0_25
## %bb.23:
	testl	%ebx, (%rcx)
	jne	LBB0_25
## %bb.24:
	movslq	%r14d, %rax
	leaq	(%r12,%rax,4), %rdi
	xorl	%esi, %esi
	movq	%rcx, %r14
	callq	_memset
	movq	%r14, %rcx
	movl	(%r13), %r14d
LBB0_25:
	addl	$4, %r14d
	movl	%r14d, (%r15)
	movq	_NPE_OP_CRYPT_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 4(%r15)
	xorl	%eax, %eax
	cmpl	$0, -60(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_28
## %bb.26:
	andl	(%rcx), %ebx
	je	LBB0_28
## %bb.27:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_gen_rev_aes_key
LBB0_28:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_30
## %bb.29:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_30:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_NPE_OP_CRYPT_ENCRYPT,4,2       ## @NPE_OP_CRYPT_ENCRYPT
	.comm	_MOD_AES,4,2                    ## @MOD_AES
	.comm	_MOD_AES128,4,2                 ## @MOD_AES128
	.comm	_KEYLEN_128,4,2                 ## @KEYLEN_128
	.comm	_MOD_AES192,4,2                 ## @MOD_AES192
	.comm	_KEYLEN_192,4,2                 ## @KEYLEN_192
	.comm	_MOD_AES256,4,2                 ## @MOD_AES256
	.comm	_KEYLEN_256,4,2                 ## @KEYLEN_256
	.comm	_CRYPTO_TFM_RES_BAD_KEY_LEN,4,2 ## @CRYPTO_TFM_RES_BAD_KEY_LEN
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_MOD_3DES,4,2                   ## @MOD_3DES
	.comm	_CRYPTO_TFM_RES_BAD_KEY_SCHED,4,2 ## @CRYPTO_TFM_RES_BAD_KEY_SCHED
	.comm	_DES_EXPKEY_WORDS,4,2           ## @DES_EXPKEY_WORDS
	.comm	_CRYPTO_TFM_RES_WEAK_KEY,4,2    ## @CRYPTO_TFM_RES_WEAK_KEY
	.comm	_DES3_EDE_KEY_SIZE,4,2          ## @DES3_EDE_KEY_SIZE
	.comm	_NPE_OP_CRYPT_ENABLE,4,2        ## @NPE_OP_CRYPT_ENABLE
	.no_dead_strip	_setup_cipher
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function setup_cipher
_setup_cipher:                          ; @setup_cipher
	.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
	sub	sp, sp, #16
	mov	x21, x3
	mov	x23, x2
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
	bl	_crypto_tfm_ctx
	add	x8, x0, #16
	cmp	w20, #0
	csel	x25, x8, x0, ne
	ldr	x24, [x25, #8]
	mov	x0, x19
	cbz	w20, LBB0_2
; %bb.1:
	bl	_cipher_cfg_enc
	mov	x22, x0
Lloh3:
	adrp	x8, _NPE_OP_CRYPT_ENCRYPT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _NPE_OP_CRYPT_ENCRYPT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	ldr	w9, [x25, #4]
	orr	w8, w9, w8
	str	w8, [x25, #4]
	b	LBB0_3
LBB0_2:
	bl	_cipher_cfg_dec
	mov	x22, x0
LBB0_3:
Lloh6:
	adrp	x26, _MOD_AES@GOTPAGE
Lloh7:
	ldr	x26, [x26, _MOD_AES@GOTPAGEOFF]
	ldr	w8, [x26]
	tst	w8, w22
	b.eq	LBB0_8
; %bb.4:
	cmp	w21, #16
	b.eq	LBB0_12
; %bb.5:
	cmp	w21, #32
	b.eq	LBB0_13
; %bb.6:
	cmp	w21, #24
	b.ne	LBB0_15
; %bb.7:
Lloh8:
	adrp	x8, _KEYLEN_192@GOTPAGE
Lloh9:
	ldr	x8, [x8, _KEYLEN_192@GOTPAGEOFF]
Lloh10:
	adrp	x9, _MOD_AES192@GOTPAGE
Lloh11:
	ldr	x9, [x9, _MOD_AES192@GOTPAGEOFF]
	b	LBB0_14
LBB0_8:
Lloh12:
	adrp	x8, _MOD_3DES@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MOD_3DES@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_16
; %bb.9:
	ldr	w10, [x23]
	ldp	w8, w9, [x23, #8]
	cmp	w10, w8
	b.ne	LBB0_19
; %bb.10:
	ldr	w10, [x23, #4]
	cmp	w10, w9
	b.ne	LBB0_19
; %bb.11:
	mov	w0, #1
	bl	_unlikely
	cbnz	x0, LBB0_20
	b	LBB0_22
LBB0_12:
Lloh15:
	adrp	x8, _KEYLEN_128@GOTPAGE
Lloh16:
	ldr	x8, [x8, _KEYLEN_128@GOTPAGEOFF]
Lloh17:
	adrp	x9, _MOD_AES128@GOTPAGE
Lloh18:
	ldr	x9, [x9, _MOD_AES128@GOTPAGEOFF]
	b	LBB0_14
LBB0_13:
Lloh19:
	adrp	x8, _KEYLEN_256@GOTPAGE
Lloh20:
	ldr	x8, [x8, _KEYLEN_256@GOTPAGEOFF]
Lloh21:
	adrp	x9, _MOD_AES256@GOTPAGE
Lloh22:
	ldr	x9, [x9, _MOD_AES256@GOTPAGEOFF]
LBB0_14:
	ldr	w9, [x9]
	ldr	w8, [x8]
	orr	w8, w8, w9
	orr	w22, w8, w22
	b	LBB0_22
LBB0_15:
Lloh23:
	adrp	x8, _CRYPTO_TFM_RES_BAD_KEY_LEN@GOTPAGE
Lloh24:
	ldr	x8, [x8, _CRYPTO_TFM_RES_BAD_KEY_LEN@GOTPAGEOFF]
	b	LBB0_21
LBB0_16:
	mov	x27, sp
Lloh25:
	adrp	x8, _DES_EXPKEY_WORDS@GOTPAGE
Lloh26:
	ldr	x8, [x8, _DES_EXPKEY_WORDS@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	lsl	x8, x8, #2
	mov	x9, x8
Lloh28:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh29:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x7fffffff0
	sub	x0, x9, x8
	mov	sp, x0
	mov	x1, x23
	bl	_des_ekey
	cbnz	x0, LBB0_18
; %bb.17:
Lloh30:
	adrp	x8, _CRYPTO_TFM_RES_WEAK_KEY@GOTPAGE
Lloh31:
	ldr	x8, [x8, _CRYPTO_TFM_RES_WEAK_KEY@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	ldr	w9, [x19]
	orr	w8, w9, w8
	str	w8, [x19]
LBB0_18:
	mov	sp, x27
	b	LBB0_22
LBB0_19:
	ldp	w10, w11, [x23, #16]
	cmp	w8, w10
	ccmp	w9, w11, #0, eq
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_22
LBB0_20:
Lloh33:
	adrp	x8, _CRYPTO_TFM_RES_BAD_KEY_SCHED@GOTPAGE
Lloh34:
	ldr	x8, [x8, _CRYPTO_TFM_RES_BAD_KEY_SCHED@GOTPAGEOFF]
LBB0_21:
	ldr	w8, [x8]
	ldr	w9, [x19]
	orr	w8, w9, w8
	str	w8, [x19]
Lloh35:
	adrp	x8, _EINVAL@GOTPAGE
Lloh36:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh37:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_28
LBB0_22:
	mov	x0, x22
	bl	_cpu_to_be32
	str	w0, [x24], #16
	mov	x0, x24
	mov	x1, x23
	mov	x2, x21
	bl	_memcpy
Lloh38:
	adrp	x23, _DES3_EDE_KEY_SIZE@GOTPAGE
Lloh39:
	ldr	x23, [x23, _DES3_EDE_KEY_SIZE@GOTPAGEOFF]
	ldr	w8, [x23]
	subs	w2, w8, w21
	b.le	LBB0_25
; %bb.23:
	ldr	w8, [x26]
	tst	w8, w22
	b.ne	LBB0_25
; %bb.24:
	add	x0, x24, w21, sxtw #2
	mov	w1, #0
	bl	_memset
	ldr	w21, [x23]
LBB0_25:
	mov	w0, #0
	add	w8, w21, #4
	str	w8, [x25]
Lloh40:
	adrp	x8, _NPE_OP_CRYPT_ENABLE@GOTPAGE
Lloh41:
	ldr	x8, [x8, _NPE_OP_CRYPT_ENABLE@GOTPAGEOFF]
Lloh42:
	ldr	w8, [x8]
	ldr	w9, [x25, #4]
	orr	w8, w9, w8
	str	w8, [x25, #4]
	cbnz	w20, LBB0_28
; %bb.26:
	ldr	w8, [x26]
	and	w8, w8, w22
	cbz	w8, LBB0_28
; %bb.27:
	mov	x0, x19
	bl	_gen_rev_aes_key
LBB0_28:
	ldur	x8, [x29, #-88]
Lloh43:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh44:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh45:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_30
; %bb.29:
	sub	sp, x29, #80
	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
LBB0_30:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.cfi_endproc
                                        ; -- End function
	.comm	_NPE_OP_CRYPT_ENCRYPT,4,2       ; @NPE_OP_CRYPT_ENCRYPT
	.comm	_MOD_AES,4,2                    ; @MOD_AES
	.comm	_MOD_AES128,4,2                 ; @MOD_AES128
	.comm	_KEYLEN_128,4,2                 ; @KEYLEN_128
	.comm	_MOD_AES192,4,2                 ; @MOD_AES192
	.comm	_KEYLEN_192,4,2                 ; @KEYLEN_192
	.comm	_MOD_AES256,4,2                 ; @MOD_AES256
	.comm	_KEYLEN_256,4,2                 ; @KEYLEN_256
	.comm	_CRYPTO_TFM_RES_BAD_KEY_LEN,4,2 ; @CRYPTO_TFM_RES_BAD_KEY_LEN
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_MOD_3DES,4,2                   ; @MOD_3DES
	.comm	_CRYPTO_TFM_RES_BAD_KEY_SCHED,4,2 ; @CRYPTO_TFM_RES_BAD_KEY_SCHED
	.comm	_DES_EXPKEY_WORDS,4,2           ; @DES_EXPKEY_WORDS
	.comm	_CRYPTO_TFM_RES_WEAK_KEY,4,2    ; @CRYPTO_TFM_RES_WEAK_KEY
	.comm	_DES3_EDE_KEY_SIZE,4,2          ; @DES3_EDE_KEY_SIZE
	.comm	_NPE_OP_CRYPT_ENABLE,4,2        ; @NPE_OP_CRYPT_ENABLE
	.no_dead_strip	_setup_cipher
.subsections_via_symbols
