	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__kadm5_set_keys2               ## -- Begin function _kadm5_set_keys2
	.p2align	4, 0x90
__kadm5_set_keys2:                      ## @_kadm5_set_keys2
	.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
	movl	%edx, %r15d
	movq	%rsi, %r12
	movq	%rdi, %r14
	leal	(,%r15,8), %eax
	leal	(%rax,%rax,2), %edi
	callq	_malloc
	testl	%r15d, %r15d
	je	LBB0_3
## %bb.1:
	testq	%rax, %rax
	jne	LBB0_3
## %bb.2:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	jmp	LBB0_15
LBB0_3:
	movq	%r12, -72(%rbp)                 ## 8-byte Spill
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	%rax, %rdi
	movl	%r15d, %esi
	callq	__kadm5_init_keys
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	testl	%r15d, %r15d
	jle	LBB0_12
## %bb.4:
	movl	-56(%rbp), %r14d                ## 4-byte Reload
	movq	-48(%rbp), %r12                 ## 8-byte Reload
	addq	$8, %r12
	shlq	$5, %r14
	xorl	%r13d, %r13d
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	$0, -8(%r12)
LBB0_11:                                ##   in Loop: Header=BB0_5 Depth=1
	addq	$24, %r12
	addq	$32, %r13
	cmpq	%r13, %r14
	je	LBB0_12
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	$0, 8(%r12)
	movq	24(%rbx,%r13), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%r12)
	movq	8(%rbx,%r13), %rax
	movq	16(%rbx,%r13), %rcx
	movl	(%rcx), %esi
	movl	(%rax), %edx
	movq	%r12, %rdi
	callq	_krb5_data_copy
	testq	%rax, %rax
	jne	LBB0_6
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	cmpl	$2, (%rbx,%r13)
	jne	LBB0_10
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	$1, %edi
	movl	$8, %esi
	callq	_calloc
	testq	%rax, %rax
	je	LBB0_13
## %bb.9:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	%rax, -8(%r12)
	movq	24(%rbx,%r13), %rcx
	movl	4(%rcx), %ecx
	movl	%ecx, 4(%rax)
	movq	8(%rbx,%r13), %rcx
	movq	16(%rbx,%r13), %rdx
	movl	4(%rdx), %esi
	movl	4(%rcx), %edx
	movq	%rax, %rdi
	callq	_krb5_data_copy
	jmp	LBB0_11
LBB0_12:
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	movl	(%r14), %edi
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movl	(%rbx), %esi
	movq	8(%rbx), %rdx
	callq	__kadm5_free_keys
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	%eax, (%rbx)
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, 8(%rbx)
	movl	(%r14), %edi
	xorl	%r15d, %r15d
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_hdb_entry_set_pw_change_time
	movl	(%r14), %edi
	movq	%rbx, %rsi
	callq	_hdb_entry_clear_password
	jmp	LBB0_15
LBB0_6:
	movq	%rax, %r15
	jmp	LBB0_14
LBB0_13:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
LBB0_14:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	callq	__kadm5_free_keys
LBB0_15:
	movq	%r15, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,8,3                     ## @ENOMEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__kadm5_set_keys2               ; -- Begin function _kadm5_set_keys2
	.p2align	2
__kadm5_set_keys2:                      ; @_kadm5_set_keys2
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	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
	.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	x23, x3
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	add	w8, w2, w2, lsl #1
	lsl	w0, w8, #3
	bl	_malloc
	mov	x22, x0
	cbz	w20, LBB0_3
; %bb.1:
	cbnz	x22, LBB0_3
; %bb.2:
Lloh0:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh2:
	ldr	x23, [x8]
	b	LBB0_15
LBB0_3:
	mov	x0, x22
	mov	x1, x20
	bl	__kadm5_init_keys
	cmp	w20, #1
	b.lt	LBB0_11
; %bb.4:
	mov	x24, #0
	add	x25, x23, #16
	mov	w8, #24
	umull	x26, w20, w8
	b	LBB0_7
LBB0_5:                                 ;   in Loop: Header=BB0_7 Depth=1
	str	xzr, [x22, x24]
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	x24, x24, #24
	add	x25, x25, #32
	cmp	x26, x24
	b.eq	LBB0_11
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	add	x8, x22, x24
	str	xzr, [x8, #16]
	ldp	x10, x9, [x25]
	ldr	w9, [x9]
	str	w9, [x8, #12]
	add	x0, x8, #8
	ldr	w1, [x10]
	ldur	x8, [x25, #-8]
	ldr	w2, [x8]
	bl	_krb5_data_copy
	cbnz	x0, LBB0_12
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldur	w8, [x25, #-16]
	cmp	w8, #2
	b.ne	LBB0_5
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	w0, #1
	mov	w1, #8
	bl	_calloc
	cbz	x0, LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	str	x0, [x22, x24]
	ldp	x9, x8, [x25]
	ldr	w8, [x8, #4]
	str	w8, [x0, #4]
	ldr	w1, [x9, #4]
	ldur	x8, [x25, #-8]
	ldr	w2, [x8, #4]
	bl	_krb5_data_copy
	b	LBB0_6
LBB0_11:
	ldr	w0, [x19]
	ldr	w1, [x21]
	ldr	x2, [x21, #8]
	bl	__kadm5_free_keys
	str	w20, [x21]
	str	x22, [x21, #8]
	ldr	w0, [x19]
	mov	x1, x21
	mov	w2, #0
	bl	_hdb_entry_set_pw_change_time
	ldr	w0, [x19]
	mov	x1, x21
	bl	_hdb_entry_clear_password
	mov	x23, #0
	b	LBB0_15
LBB0_12:
	mov	x23, x0
	b	LBB0_14
LBB0_13:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	x23, [x8]
LBB0_14:
	ldr	w0, [x19]
	mov	x1, x20
	mov	x2, x22
	bl	__kadm5_free_keys
LBB0_15:
	mov	x0, x23
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,8,3                     ; @ENOMEM
.subsections_via_symbols
