	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_HPDF_Encrypt_CreateEncryptionKey ## -- Begin function HPDF_Encrypt_CreateEncryptionKey
	.p2align	4, 0x90
_HPDF_Encrypt_CreateEncryptionKey:      ## @HPDF_Encrypt_CreateEncryptionKey
	.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	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	leaq	L_.str(%rip), %rdi
	callq	_HPDF_PTRACE
	leaq	-68(%rbp), %r14
	movq	%r14, %rdi
	callq	_HPDF_MD5Init
	movq	48(%r15), %rsi
	movq	_HPDF_PASSWD_LEN@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	movq	%r14, %rdi
	callq	_HPDF_MD5Update
	movq	40(%r15), %rsi
	movl	(%rbx), %edx
	movq	%r14, %rdi
	callq	_HPDF_MD5Update
	movslq	(%r15), %rdi
	callq	_HPDF_PTRACE
	movslq	(%r15), %rax
	movq	%rax, -64(%rbp)
	movl	%eax, %ecx
	sarl	$8, %ecx
	movslq	%ecx, %rcx
	movq	%rcx, -56(%rbp)
	movl	%eax, %ecx
	sarl	$16, %ecx
	movslq	%ecx, %rcx
	movq	%rcx, -48(%rbp)
	sarl	$24, %eax
	cltq
	movq	%rax, -40(%rbp)
	leaq	-64(%rbp), %rsi
	movq	%r14, %rdi
	movl	$4, %edx
	callq	_HPDF_MD5Update
	leaq	L_.str.2(%rip), %rdi
	callq	_HPDF_PTRACE
	movq	32(%r15), %rsi
	movq	_HPDF_ID_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_HPDF_MD5Update
	movq	24(%r15), %rdi
	movq	%r14, %rsi
	callq	_HPDF_MD5Final
	movq	8(%r15), %rax
	movq	_HPDF_ENCRYPT_R3@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.1:
	xorl	%ebx, %ebx
	leaq	-68(%rbp), %r14
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_HPDF_PTRACE
	movq	%r14, %rdi
	callq	_HPDF_MD5Init
	movq	24(%r15), %rsi
	movl	16(%r15), %edx
	movq	%r14, %rdi
	callq	_HPDF_MD5Update
	movq	24(%r15), %rdi
	movq	%r14, %rsi
	callq	_HPDF_MD5Final
	incq	%rbx
	cmpq	$50, %rbx
	jne	LBB0_2
LBB0_3:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_5
## %bb.4:
	addq	$56, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	" HPDF_Encrypt_CreateEncryptionKey\n"

	.comm	_HPDF_PASSWD_LEN,4,2            ## @HPDF_PASSWD_LEN
L_.str.2:                               ## @.str.2
	.asciz	"@ Algorithm 3.2 step 5\n"

	.comm	_HPDF_ID_LEN,4,2                ## @HPDF_ID_LEN
	.comm	_HPDF_ENCRYPT_R3,8,3            ## @HPDF_ENCRYPT_R3
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function HPDF_Encrypt_CreateEncryptionKey
lCPI0_0:
	.long	4294967288                      ; 0xfffffff8
	.long	4294967280                      ; 0xfffffff0
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_HPDF_Encrypt_CreateEncryptionKey
	.p2align	2
_HPDF_Encrypt_CreateEncryptionKey:      ; @HPDF_Encrypt_CreateEncryptionKey
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	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, #-24]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_HPDF_PTRACE
	add	x0, sp, #4
	bl	_HPDF_MD5Init
	ldr	x1, [x19, #48]
Lloh5:
	adrp	x20, _HPDF_PASSWD_LEN@GOTPAGE
Lloh6:
	ldr	x20, [x20, _HPDF_PASSWD_LEN@GOTPAGEOFF]
	ldr	w2, [x20]
	add	x0, sp, #4
	bl	_HPDF_MD5Update
	ldr	x1, [x19, #40]
	ldr	w2, [x20]
	add	x0, sp, #4
	bl	_HPDF_MD5Update
	ldrsw	x0, [x19]
	bl	_HPDF_PTRACE
	ldrsw	x8, [x19]
	str	x8, [sp, #8]
	dup.2s	v0, w8
                                        ; kill: def $w8 killed $w8 killed $x8 def $x8
Lloh7:
	adrp	x9, lCPI0_0@PAGE
Lloh8:
	ldr	d1, [x9, lCPI0_0@PAGEOFF]
	sshl.2s	v0, v0, v1
	sshll.2d	v0, v0, #0
	stur	q0, [sp, #16]
	sbfx	x8, x8, #24, #8
	str	x8, [sp, #32]
	add	x0, sp, #4
	add	x1, sp, #8
	mov	w2, #4
	bl	_HPDF_MD5Update
Lloh9:
	adrp	x0, l_.str.2@PAGE
Lloh10:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_HPDF_PTRACE
	ldr	x1, [x19, #32]
Lloh11:
	adrp	x8, _HPDF_ID_LEN@GOTPAGE
Lloh12:
	ldr	x8, [x8, _HPDF_ID_LEN@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	add	x0, sp, #4
	bl	_HPDF_MD5Update
	ldr	x0, [x19, #24]
	add	x1, sp, #4
	bl	_HPDF_MD5Final
	ldr	x8, [x19, #8]
Lloh14:
	adrp	x9, _HPDF_ENCRYPT_R3@GOTPAGE
Lloh15:
	ldr	x9, [x9, _HPDF_ENCRYPT_R3@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_3
; %bb.1:
	mov	x20, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_HPDF_PTRACE
	add	x0, sp, #4
	bl	_HPDF_MD5Init
	ldr	x1, [x19, #24]
	ldr	w2, [x19, #16]
	add	x0, sp, #4
	bl	_HPDF_MD5Update
	ldr	x0, [x19, #24]
	add	x1, sp, #4
	bl	_HPDF_MD5Final
	add	x20, x20, #1
	cmp	x20, #50
	b.ne	LBB0_2
LBB0_3:
	ldur	x8, [x29, #-24]
Lloh17:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh18:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh19:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_5
; %bb.4:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_5:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdr	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	" HPDF_Encrypt_CreateEncryptionKey\n"

	.comm	_HPDF_PASSWD_LEN,4,2            ; @HPDF_PASSWD_LEN
l_.str.2:                               ; @.str.2
	.asciz	"@ Algorithm 3.2 step 5\n"

	.comm	_HPDF_ID_LEN,4,2                ; @HPDF_ID_LEN
	.comm	_HPDF_ENCRYPT_R3,8,3            ; @HPDF_ENCRYPT_R3
.subsections_via_symbols
