	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function crypto_open2
_crypto_open2:                          ## @crypto_open2
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r15
	movl	%edx, %r14d
	movq	%rsi, %rbx
	movq	%rdi, %r12
	movq	16(%rdi), %r13
	movl	%edx, (%r13)
	leaq	L_.str(%rip), %rsi
	leaq	-48(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_av_strstart
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	leaq	L_.str.1(%rip), %rsi
	leaq	-48(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_av_strstart
	testl	%eax, %eax
	je	LBB0_19
LBB0_2:
	movq	_AVIO_FLAG_READ@GOTPCREL(%rip), %rax
	testl	%r14d, (%rax)
	je	LBB0_5
## %bb.3:
	leaq	24(%r13), %rsi
	leaq	76(%r13), %rdx
	movl	56(%r13), %r8d
	movl	60(%r13), %ecx
	leaq	L_.str.3(%rip), %r9
	movq	%r12, %rdi
	callq	_set_aes_arg
	testl	%eax, %eax
	js	LBB0_26
## %bb.4:
	leaq	72(%r13), %rsi
	leaq	68(%r13), %rdx
	movl	40(%r13), %r8d
	movl	44(%r13), %ecx
	leaq	L_.str.4(%rip), %r9
	movq	%r12, %rdi
	callq	_set_aes_arg
	testl	%eax, %eax
	js	LBB0_26
LBB0_5:
	movq	_AVIO_FLAG_WRITE@GOTPCREL(%rip), %rax
	testl	%r14d, (%rax)
	je	LBB0_8
## %bb.6:
	leaq	4(%r13), %rsi
	leaq	64(%r13), %rdx
	movl	56(%r13), %r8d
	movl	60(%r13), %ecx
	leaq	L_.str.5(%rip), %r9
	movq	%r12, %rdi
	callq	_set_aes_arg
	testl	%eax, %eax
	js	LBB0_26
## %bb.7:
	leaq	52(%r13), %rsi
	leaq	48(%r13), %rdx
	movl	40(%r13), %r8d
	movl	44(%r13), %ecx
	leaq	L_.str.6(%rip), %r9
	movq	%r12, %rdi
	callq	_set_aes_arg
	testl	%eax, %eax
	js	LBB0_26
LBB0_8:
	leaq	16(%r13), %rdi
	movq	-48(%rbp), %rsi
	leaq	12(%r12), %rcx
	movl	4(%r12), %eax
	movl	8(%r12), %r9d
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movl	%r14d, %edx
	movq	%r15, %r8
	pushq	%r12
	pushq	%rax
	callq	_ffurl_open_whitelist
	addq	$16, %rsp
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_22
## %bb.9:
	movq	_AVIO_FLAG_READ@GOTPCREL(%rip), %rax
	testl	%r14d, (%rax)
	je	LBB0_14
## %bb.10:
	xorl	%eax, %eax
	callq	_av_aes_alloc
	movq	%rax, 32(%r13)
	testq	%rax, %rax
	je	LBB0_24
## %bb.11:
	movl	24(%r13), %esi
	movq	_BLOCKSIZE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	shll	$3, %edx
	movq	%rax, %rdi
	movl	$1, %ecx
	callq	_av_aes_init
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_27
## %bb.12:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movl	(%rax), %eax
	testl	%eax, %eax
	je	LBB0_14
## %bb.13:
	movl	%eax, (%r12)
LBB0_14:
	movq	_AVIO_FLAG_WRITE@GOTPCREL(%rip), %rax
	testl	%r14d, (%rax)
	je	LBB0_27
## %bb.15:
	xorl	%eax, %eax
	callq	_av_aes_alloc
	movq	%rax, 8(%r13)
	testq	%rax, %rax
	je	LBB0_24
## %bb.16:
	movl	4(%r13), %esi
	movq	_BLOCKSIZE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	shll	$3, %edx
	movq	%rax, %rdi
	xorl	%ecx, %ecx
	callq	_av_aes_init
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_27
## %bb.17:
	movl	$1, (%r12)
	jmp	LBB0_27
LBB0_19:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	movq	%r12, %rdi
	movq	%rbx, %rcx
	callq	_av_log
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_25
LBB0_22:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %rcx
	leaq	L_.str.7(%rip), %rdx
	movq	%r12, %rdi
	callq	_av_log
	jmp	LBB0_27
LBB0_24:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_25:
	movl	(%rax), %edi
	callq	_AVERROR
LBB0_26:
	movl	%eax, %ebx
LBB0_27:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"crypto+"

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

	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
L_.str.2:                               ## @.str.2
	.asciz	"Unsupported url %s\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_AVIO_FLAG_READ,4,2             ## @AVIO_FLAG_READ
L_.str.3:                               ## @.str.3
	.asciz	"decryption key"

L_.str.4:                               ## @.str.4
	.asciz	"decryption IV"

	.comm	_AVIO_FLAG_WRITE,4,2            ## @AVIO_FLAG_WRITE
L_.str.5:                               ## @.str.5
	.asciz	"encryption key"

L_.str.6:                               ## @.str.6
	.asciz	"encryption IV"

L_.str.7:                               ## @.str.7
	.asciz	"Unable to open resource: %s\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_BLOCKSIZE,4,2                  ## @BLOCKSIZE
	.no_dead_strip	_crypto_open2
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function crypto_open2
_crypto_open2:                          ; @crypto_open2
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.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
	mov	x21, x3
	mov	x20, x2
	mov	x22, x1
	mov	x19, x0
	ldr	x24, [x0, #16]
	str	w2, [x24]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	add	x2, sp, #8
	mov	x0, x22
	bl	_av_strstart
	cbnz	w0, LBB0_2
; %bb.1:
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x2, sp, #8
	mov	x0, x22
	bl	_av_strstart
	cbz	w0, LBB0_18
LBB0_2:
Lloh4:
	adrp	x26, _AVIO_FLAG_READ@GOTPAGE
Lloh5:
	ldr	x26, [x26, _AVIO_FLAG_READ@GOTPAGEOFF]
	ldr	w8, [x26]
	tst	w8, w20
	b.eq	LBB0_5
; %bb.3:
	add	x1, x24, #24
	add	x2, x24, #76
	ldp	w4, w3, [x24, #56]
Lloh6:
	adrp	x5, l_.str.3@PAGE
Lloh7:
	add	x5, x5, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_set_aes_arg
	tbnz	w0, #31, LBB0_22
; %bb.4:
	add	x1, x24, #72
	add	x2, x24, #68
	ldp	w4, w3, [x24, #40]
Lloh8:
	adrp	x5, l_.str.4@PAGE
Lloh9:
	add	x5, x5, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_set_aes_arg
	tbnz	w0, #31, LBB0_22
LBB0_5:
Lloh10:
	adrp	x25, _AVIO_FLAG_WRITE@GOTPAGE
Lloh11:
	ldr	x25, [x25, _AVIO_FLAG_WRITE@GOTPAGEOFF]
	ldr	w8, [x25]
	tst	w8, w20
	b.eq	LBB0_8
; %bb.6:
	add	x1, x24, #4
	add	x2, x24, #64
	ldp	w4, w3, [x24, #56]
Lloh12:
	adrp	x5, l_.str.5@PAGE
Lloh13:
	add	x5, x5, l_.str.5@PAGEOFF
	mov	x0, x19
	bl	_set_aes_arg
	tbnz	w0, #31, LBB0_22
; %bb.7:
	add	x1, x24, #52
	add	x2, x24, #48
	ldp	w4, w3, [x24, #40]
Lloh14:
	adrp	x5, l_.str.6@PAGE
Lloh15:
	add	x5, x5, l_.str.6@PAGEOFF
	mov	x0, x19
	bl	_set_aes_arg
	tbnz	w0, #31, LBB0_22
LBB0_8:
	add	x23, x24, #16
	ldr	x1, [sp, #8]
	add	x3, x19, #12
	ldp	w6, w5, [x19, #4]
	mov	x0, x23
	mov	x2, x20
	mov	x4, x21
	mov	x7, x19
	bl	_ffurl_open_whitelist
	mov	x22, x0
	tbnz	w0, #31, LBB0_19
; %bb.9:
	ldr	w8, [x26]
	tst	w8, w20
	b.eq	LBB0_14
; %bb.10:
	bl	_av_aes_alloc
	str	x0, [x24, #32]
	cbz	x0, LBB0_20
; %bb.11:
	ldr	w1, [x24, #24]
Lloh16:
	adrp	x8, _BLOCKSIZE@GOTPAGE
Lloh17:
	ldr	x8, [x8, _BLOCKSIZE@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	lsl	w2, w8, #3
	mov	w3, #1
	bl	_av_aes_init
	mov	x22, x0
	tbnz	w0, #31, LBB0_23
; %bb.12:
	ldr	x8, [x23]
	ldr	w8, [x8]
	cbz	w8, LBB0_14
; %bb.13:
	str	w8, [x19]
LBB0_14:
	ldr	w8, [x25]
	tst	w8, w20
	b.eq	LBB0_23
; %bb.15:
	bl	_av_aes_alloc
	str	x0, [x24, #8]
	cbz	x0, LBB0_20
; %bb.16:
	ldr	w1, [x24, #4]
Lloh19:
	adrp	x8, _BLOCKSIZE@GOTPAGE
Lloh20:
	ldr	x8, [x8, _BLOCKSIZE@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	lsl	w2, w8, #3
	mov	w3, #0
	bl	_av_aes_init
	mov	x22, x0
	tbnz	w0, #31, LBB0_23
; %bb.17:
	mov	w8, #1
	str	w8, [x19]
	b	LBB0_23
LBB0_18:
Lloh22:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh23:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
Lloh25:
	adrp	x2, l_.str.2@PAGE
Lloh26:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x0, x19
	mov	x3, x22
	bl	_av_log
Lloh27:
	adrp	x8, _EINVAL@GOTPAGE
Lloh28:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_21
LBB0_19:
Lloh29:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh30:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh31:
	ldr	w1, [x8]
	ldr	x3, [sp, #8]
Lloh32:
	adrp	x2, l_.str.7@PAGE
Lloh33:
	add	x2, x2, l_.str.7@PAGEOFF
	mov	x0, x19
	bl	_av_log
	b	LBB0_23
LBB0_20:
Lloh34:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh35:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_21:
	ldr	w0, [x8]
	bl	_AVERROR
LBB0_22:
	mov	x22, x0
LBB0_23:
	mov	x0, x22
	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
	add	sp, sp, #96
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"crypto+"

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

	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
l_.str.2:                               ; @.str.2
	.asciz	"Unsupported url %s\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_AVIO_FLAG_READ,4,2             ; @AVIO_FLAG_READ
l_.str.3:                               ; @.str.3
	.asciz	"decryption key"

l_.str.4:                               ; @.str.4
	.asciz	"decryption IV"

	.comm	_AVIO_FLAG_WRITE,4,2            ; @AVIO_FLAG_WRITE
l_.str.5:                               ; @.str.5
	.asciz	"encryption key"

l_.str.6:                               ; @.str.6
	.asciz	"encryption IV"

l_.str.7:                               ; @.str.7
	.asciz	"Unable to open resource: %s\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_BLOCKSIZE,4,2                  ; @BLOCKSIZE
	.no_dead_strip	_crypto_open2
.subsections_via_symbols
