	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hdb_entry_set_password         ## -- Begin function hdb_entry_set_password
	.p2align	4, 0x90
_hdb_entry_set_password:                ## @hdb_entry_set_password
	.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
	movq	%rcx, %rbx
	movq	%rdx, %r14
	movl	%edi, %r15d
	movq	_FALSE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)
	movq	_choice_HDB_extension_data_password@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -56(%rbp)
	cmpq	$0, 8(%rsi)
	je	LBB0_7
## %bb.1:
	movl	(%rsi), %esi
	xorl	%edi, %edi
	callq	__hdb_find_master_key
	testq	%rax, %rax
	je	LBB0_2
## %bb.4:
	movq	%rax, %r12
	movq	_HDB_KU_MKEY@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	%rbx, %rdi
	callq	_strlen
	leaq	1(%rax), %r8
	leaq	-72(%rbp), %r9
	movl	%r15d, %edi
	movq	%r12, %rsi
	movl	%r13d, %edx
	movq	%rbx, %rcx
	callq	__hdb_mkey_encrypt
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_12
## %bb.5:
	movl	$4, %edi
	callq	_malloc
	movq	%rax, -64(%rbp)
	testq	%rax, %rax
	je	LBB0_6
## %bb.9:
	movq	%r12, %rdi
	callq	__hdb_mkey_version
	movq	-64(%rbp), %rcx
	movl	%eax, (%rcx)
	jmp	LBB0_10
LBB0_7:
	movq	$0, -64(%rbp)
	movq	%rbx, %rdi
	callq	_strlen
	leaq	1(%rax), %rdx
	leaq	-72(%rbp), %rdi
	movq	%rbx, %rsi
	callq	_krb5_data_copy
	testl	%eax, %eax
	je	LBB0_10
## %bb.8:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rdx
	movl	%r15d, %edi
	movl	%eax, %esi
	callq	_krb5_set_error_message
	leaq	-72(%rbp), %rdi
	jmp	LBB0_11
LBB0_2:
	movq	_HDB_ERR_NO_MKEY@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	leaq	L_.str(%rip), %rdx
	jmp	LBB0_3
LBB0_10:
	leaq	-72(%rbp), %r12
	movl	%r15d, %edi
	movq	%r14, %rsi
	movq	%r12, %rdx
	callq	_hdb_replace_extension
	movl	%eax, %ebx
	movq	%r12, %rdi
LBB0_11:
	callq	_free_HDB_extension
	jmp	LBB0_12
LBB0_6:
	leaq	-72(%rbp), %rdi
	callq	_free_HDB_extension
	movq	_ENOMEM@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	leaq	L_.str.1(%rip), %rdx
LBB0_3:
	movl	%r15d, %edi
	callq	_krb5_set_error_message
	movl	(%rbx), %ebx
LBB0_12:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FALSE,4,2                      ## @FALSE
	.comm	_choice_HDB_extension_data_password,4,2 ## @choice_HDB_extension_data_password
	.comm	_HDB_ERR_NO_MKEY,4,2            ## @HDB_ERR_NO_MKEY
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"hdb_entry_set_password: failed to find masterkey"

	.comm	_HDB_KU_MKEY,4,2                ## @HDB_KU_MKEY
	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"malloc: out of memory"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hdb_entry_set_password         ; -- Begin function hdb_entry_set_password
	.p2align	2
_hdb_entry_set_password:                ; @hdb_entry_set_password
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x21, x3
	mov	x20, x2
	mov	x19, x0
Lloh0:
	adrp	x8, _FALSE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _choice_HDB_extension_data_password@GOTPAGE
Lloh4:
	ldr	x9, [x9, _choice_HDB_extension_data_password@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	str	w8, [sp, #24]
	str	w9, [sp, #16]
	ldr	x8, [x1, #8]
	cbz	x8, LBB0_5
; %bb.1:
	ldr	w1, [x1]
	mov	x0, #0
	bl	__hdb_find_master_key
	cbz	x0, LBB0_7
; %bb.2:
	mov	x22, x0
Lloh6:
	adrp	x8, _HDB_KU_MKEY@GOTPAGE
Lloh7:
	ldr	x8, [x8, _HDB_KU_MKEY@GOTPAGEOFF]
Lloh8:
	ldr	w23, [x8]
	mov	x0, x21
	bl	_strlen
	add	x4, x0, #1
	mov	x5, sp
	mov	x0, x19
	mov	x1, x22
	mov	x2, x23
	mov	x3, x21
	bl	__hdb_mkey_encrypt
	mov	x21, x0
	cbnz	w0, LBB0_12
; %bb.3:
	mov	w0, #4
	bl	_malloc
	str	x0, [sp, #8]
	cbz	x0, LBB0_10
; %bb.4:
	mov	x0, x22
	bl	__hdb_mkey_version
	ldr	x8, [sp, #8]
	str	w0, [x8]
	b	LBB0_8
LBB0_5:
	str	xzr, [sp, #8]
	mov	x0, x21
	bl	_strlen
	add	x2, x0, #1
	mov	x0, sp
	mov	x1, x21
	bl	_krb5_data_copy
	cbz	w0, LBB0_8
; %bb.6:
	mov	x21, x0
Lloh9:
	adrp	x2, l_.str.1@PAGE
Lloh10:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x1, x21
	bl	_krb5_set_error_message
	b	LBB0_9
LBB0_7:
Lloh11:
	adrp	x20, _HDB_ERR_NO_MKEY@GOTPAGE
Lloh12:
	ldr	x20, [x20, _HDB_ERR_NO_MKEY@GOTPAGEOFF]
	ldr	w1, [x20]
Lloh13:
	adrp	x2, l_.str@PAGE
Lloh14:
	add	x2, x2, l_.str@PAGEOFF
	b	LBB0_11
LBB0_8:
	mov	x2, sp
	mov	x0, x19
	mov	x1, x20
	bl	_hdb_replace_extension
	mov	x21, x0
LBB0_9:
	mov	x0, sp
	bl	_free_HDB_extension
	b	LBB0_12
LBB0_10:
	mov	x0, sp
	bl	_free_HDB_extension
Lloh15:
	adrp	x20, _ENOMEM@GOTPAGE
Lloh16:
	ldr	x20, [x20, _ENOMEM@GOTPAGEOFF]
	ldr	w1, [x20]
Lloh17:
	adrp	x2, l_.str.1@PAGE
Lloh18:
	add	x2, x2, l_.str.1@PAGEOFF
LBB0_11:
	mov	x0, x19
	bl	_krb5_set_error_message
	ldr	w21, [x20]
LBB0_12:
	mov	x0, x21
	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
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_FALSE,4,2                      ; @FALSE
	.comm	_choice_HDB_extension_data_password,4,2 ; @choice_HDB_extension_data_password
	.comm	_HDB_ERR_NO_MKEY,4,2            ; @HDB_ERR_NO_MKEY
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"hdb_entry_set_password: failed to find masterkey"

	.comm	_HDB_KU_MKEY,4,2                ; @HDB_KU_MKEY
	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"malloc: out of memory"

.subsections_via_symbols
