	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hkt_fetch_kvno
_hkt_fetch_kvno:                        ## @hkt_fetch_kvno
	.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	%r9, %r12
	movl	%r8d, %r13d
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movl	%edx, -48(%rbp)                 ## 4-byte Spill
	movl	%edi, %r14d
	movslq	(%rsi), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	_HDB_F_KVNO_SPECIFIED@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	leaq	-80(%rbp), %rdi
	xorl	%esi, %esi
	movl	$20, %edx
	callq	_memset
	movabsq	$4294967297, %rax               ## imm = 0x100000001
	movq	%rax, 8(%r12)
	movl	$1, 16(%r12)
	leaq	4(%r12), %rdx
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	callq	_krb5_parse_name
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_7
## %bb.1:
	andl	-44(%rbp), %r15d                ## 4-byte Folded Reload
	cmovel	%r15d, %r13d
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %esi
	leaq	-80(%rbp), %r9
	movl	%r14d, %edi
	movl	-48(%rbp), %ebx                 ## 4-byte Reload
	movl	%ebx, %edx
	movl	%r13d, %ecx
	xorl	%r8d, %r8d
	callq	_krb5_kt_get_entry
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_HDB_ERR_NOENTRY@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	testq	%rbx, %rbx
	jne	LBB0_7
	jmp	LBB0_6
LBB0_3:
	movl	%r14d, %edi
	movl	%ebx, %esi
	movq	%r12, %rdx
	callq	_krb5_copy_principal
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_7
## %bb.4:
	leaq	-80(%rbp), %rsi
	movl	%r14d, %edi
	movq	%r12, %rdx
	callq	__hdb_keytab2hdb_entry
	movq	%rax, %rbx
	testq	%rbx, %rbx
	je	LBB0_6
LBB0_7:
	movq	%r12, %rdi
	callq	_free_hdb_entry
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$20, %edx
	callq	_memset
LBB0_8:
	leaq	-80(%rbp), %rsi
	movl	%r14d, %edi
	callq	_krb5_kt_free_entry
	movq	%rbx, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	xorl	%ebx, %ebx
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_HDB_F_KVNO_SPECIFIED,4,2       ## @HDB_F_KVNO_SPECIFIED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"hdb/keytab@WELL-KNOWN:KEYTAB-BACKEND"

	.comm	_HDB_ERR_NOENTRY,8,3            ## @HDB_ERR_NOENTRY
	.no_dead_strip	_hkt_fetch_kvno
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hkt_fetch_kvno
_hkt_fetch_kvno:                        ; @hkt_fetch_kvno
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x20, x5
	mov	x23, x4
	mov	x24, x3
	mov	x21, x2
	mov	x19, x0
	ldrsw	x25, [x1]
Lloh0:
	adrp	x8, _HDB_F_KVNO_SPECIFIED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _HDB_F_KVNO_SPECIFIED@GOTPAGEOFF]
Lloh2:
	ldr	w26, [x8]
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #20
	bl	_memset
	movi.2s	v0, #1
	str	d0, [x20, #8]
	mov	w8, #1
	str	w8, [x20, #16]
	add	x2, x20, #4
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_krb5_parse_name
	mov	x22, x0
	cbnz	x0, LBB0_5
; %bb.1:
	tst	w26, w24
	csel	w3, wzr, w23, eq
	ldr	w1, [x25]
	add	x5, sp, #8
	mov	x0, x19
	mov	x2, x21
	mov	w4, #0
	bl	_krb5_kt_get_entry
	cbz	x0, LBB0_3
; %bb.2:
Lloh5:
	adrp	x8, _HDB_ERR_NOENTRY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _HDB_ERR_NOENTRY@GOTPAGEOFF]
Lloh7:
	ldr	x22, [x8]
	cbnz	x22, LBB0_5
	b	LBB0_6
LBB0_3:
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	bl	_krb5_copy_principal
	mov	x22, x0
	cbnz	x0, LBB0_5
; %bb.4:
	add	x1, sp, #8
	mov	x0, x19
	mov	x2, x20
	bl	__hdb_keytab2hdb_entry
	mov	x22, x0
	cbz	x22, LBB0_6
LBB0_5:
	mov	x0, x20
	bl	_free_hdb_entry
	mov	x0, x20
	mov	w1, #0
	mov	w2, #20
	bl	_memset
LBB0_6:
	add	x1, sp, #8
	mov	x0, x19
	bl	_krb5_kt_free_entry
	mov	x0, x22
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_HDB_F_KVNO_SPECIFIED,4,2       ; @HDB_F_KVNO_SPECIFIED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"hdb/keytab@WELL-KNOWN:KEYTAB-BACKEND"

	.comm	_HDB_ERR_NOENTRY,8,3            ; @HDB_ERR_NOENTRY
	.no_dead_strip	_hkt_fetch_kvno
.subsections_via_symbols
