	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rtmp_calc_swfhash
_rtmp_calc_swfhash:                     ## @rtmp_calc_swfhash
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	16(%rdi), %r14
	movq	$0, -96(%rbp)
	movq	$0, -104(%rbp)
	movl	4(%r14), %esi
	movq	_AVIO_FLAG_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	8(%rdi), %rcx
	movl	(%rdi), %eax
	movl	4(%rdi), %r9d
	leaq	-88(%rbp), %rdi
	xorl	%r8d, %r8d
	pushq	%rbx
	pushq	%rax
	callq	_ffurl_open_whitelist
	addq	$16, %rsp
	testl	%eax, %eax
	js	LBB0_6
## %bb.1:
	movq	-88(%rbp), %rdi
	movq	_AVSEEK_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%esi, %esi
	callq	_ffurl_seek
	testl	%eax, %eax
	js	LBB0_7
## %bb.2:
	movl	%eax, %r12d
	movl	%eax, %edi
	callq	_av_malloc
	movq	%rax, -96(%rbp)
	testq	%rax, %rax
	je	LBB0_8
## %bb.3:
	movq	%rax, %r13
	movq	-88(%rbp), %rdi
	movq	%rax, %rsi
	movl	%r12d, %edx
	callq	_ffurl_read_complete
	testl	%eax, %eax
	js	LBB0_10
## %bb.4:
	cmpl	$2, %r12d
	ja	LBB0_14
## %bb.5:
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	jmp	LBB0_11
LBB0_6:
	movl	%eax, %r15d
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	4(%r14), %ecx
	leaq	L_.str(%rip), %rdx
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_11
LBB0_7:
	movq	_EIO@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_8:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %edi
	callq	_AVERROR
LBB0_10:
	movl	%eax, %r15d
LBB0_11:
	leaq	-96(%rbp), %rdi
	callq	_av_freep
	leaq	-104(%rbp), %rdi
	callq	_av_freep
	movq	-88(%rbp), %rdi
	callq	_ffurl_close
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_18
## %bb.12:
	movl	%r15d, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	leaq	L_.str.1(%rip), %rsi
	movq	%r13, %rdi
	movl	$3, %edx
	callq	_memcmp
	testl	%eax, %eax
	je	LBB0_17
## %bb.15:
	leaq	L_.str.3(%rip), %rcx
	leaq	-80(%rbp), %r9
	movq	%r13, %rdi
	movl	%r12d, %esi
	xorl	%edx, %edx
	movl	$30, %r8d
	callq	_ff_rtmp_calc_digest
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_11
## %bb.16:
	leaq	L_.str.4(%rip), %rsi
	leaq	-80(%rbp), %rdx
	movq	%r14, %rdi
	movl	$32, %ecx
	xorl	%r8d, %r8d
	callq	_av_opt_set_bin
	movl	%r12d, (%r14)
	jmp	LBB0_11
LBB0_17:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_av_log
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_18:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_AVIO_FLAG_READ,4,2             ## @AVIO_FLAG_READ
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Cannot open connection %s.\n"

	.comm	_AVSEEK_SIZE,4,2                ## @AVSEEK_SIZE
	.comm	_EIO,4,2                        ## @EIO
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
L_.str.1:                               ## @.str.1
	.asciz	"CWS"

L_.str.2:                               ## @.str.2
	.asciz	"Zlib is required for decompressing the SWF player file.\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.3:                               ## @.str.3
	.asciz	"Genuine Adobe Flash Player 001"

L_.str.4:                               ## @.str.4
	.asciz	"rtmp_swfhash"

	.no_dead_strip	_rtmp_calc_swfhash
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rtmp_calc_swfhash
_rtmp_calc_swfhash:                     ; @rtmp_calc_swfhash
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	ldr	x19, [x0, #16]
	stp	xzr, xzr, [sp, #24]
	ldr	w1, [x19, #4]
Lloh3:
	adrp	x8, _AVIO_FLAG_READ@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AVIO_FLAG_READ@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	add	x3, x0, #8
	ldp	w6, w5, [x0]
	add	x0, sp, #16
	mov	x4, #0
	mov	x7, x20
	bl	_ffurl_open_whitelist
	tbnz	w0, #31, LBB0_6
; %bb.1:
	ldr	x0, [sp, #16]
Lloh6:
	adrp	x8, _AVSEEK_SIZE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _AVSEEK_SIZE@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	mov	w1, #0
	bl	_ffurl_seek
	tbnz	w0, #31, LBB0_7
; %bb.2:
	mov	x22, x0
	bl	_av_malloc
	str	x0, [sp, #32]
	cbz	x0, LBB0_8
; %bb.3:
	mov	x23, x0
	ldr	x0, [sp, #16]
	mov	x1, x23
	mov	x2, x22
	bl	_ffurl_read_complete
	tbnz	w0, #31, LBB0_10
; %bb.4:
	cmp	w22, #2
	b.hi	LBB0_13
; %bb.5:
Lloh9:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh11:
	ldr	w21, [x8]
	b	LBB0_11
LBB0_6:
	mov	x21, x0
Lloh12:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh13:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	ldr	w8, [x19, #4]
	str	x8, [sp]
Lloh15:
	adrp	x2, l_.str@PAGE
Lloh16:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	bl	_av_log
	b	LBB0_11
LBB0_7:
Lloh17:
	adrp	x8, _EIO@GOTPAGE
Lloh18:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh19:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_9:
	ldr	w0, [x8]
	bl	_AVERROR
LBB0_10:
	mov	x21, x0
LBB0_11:
	add	x0, sp, #32
	bl	_av_freep
	add	x0, sp, #24
	bl	_av_freep
	ldr	x0, [sp, #16]
	bl	_ffurl_close
	ldur	x8, [x29, #-56]
Lloh21:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh22:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh23:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_17
; %bb.12:
	mov	x0, x21
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_13:
Lloh24:
	adrp	x1, l_.str.1@PAGE
Lloh25:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x23
	mov	w2, #3
	bl	_memcmp
	cbz	w0, LBB0_16
; %bb.14:
Lloh26:
	adrp	x3, l_.str.3@PAGE
Lloh27:
	add	x3, x3, l_.str.3@PAGEOFF
	add	x5, sp, #40
	mov	x0, x23
	mov	x1, x22
	mov	w2, #0
	mov	w4, #30
	bl	_ff_rtmp_calc_digest
	mov	x21, x0
	tbnz	w0, #31, LBB0_11
; %bb.15:
Lloh28:
	adrp	x1, l_.str.4@PAGE
Lloh29:
	add	x1, x1, l_.str.4@PAGEOFF
	add	x2, sp, #40
	mov	x0, x19
	mov	w3, #32
	mov	w4, #0
	bl	_av_opt_set_bin
	str	w22, [x19]
	b	LBB0_11
LBB0_16:
Lloh30:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh31:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh32:
	ldr	w1, [x8]
Lloh33:
	adrp	x2, l_.str.2@PAGE
Lloh34:
	add	x2, x2, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_av_log
Lloh35:
	adrp	x8, _EINVAL@GOTPAGE
Lloh36:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_9
LBB0_17:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	_AVIO_FLAG_READ,4,2             ; @AVIO_FLAG_READ
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Cannot open connection %s.\n"

	.comm	_AVSEEK_SIZE,4,2                ; @AVSEEK_SIZE
	.comm	_EIO,4,2                        ; @EIO
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
l_.str.1:                               ; @.str.1
	.asciz	"CWS"

l_.str.2:                               ; @.str.2
	.asciz	"Zlib is required for decompressing the SWF player file.\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.3:                               ; @.str.3
	.asciz	"Genuine Adobe Flash Player 001"

l_.str.4:                               ; @.str.4
	.asciz	"rtmp_swfhash"

	.no_dead_strip	_rtmp_calc_swfhash
.subsections_via_symbols
