	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function openpam_load_file
_openpam_load_file:                     ## @openpam_load_file
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, -52(%rbp)                 ## 4-byte Spill
	movq	%rcx, %r15
	movl	%edx, %r12d
	movq	%rsi, %r13
	movq	%rdi, %rbx
	leaq	L_.str(%rip), %rsi
	movq	%rcx, %rdi
	callq	_fopen
	movq	%rax, %r14
	testq	%rax, %rax
	je	LBB0_1
## %bb.5:
	movq	_PAM_LOG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdx
	callq	_openpam_log
	jmp	LBB0_6
LBB0_1:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%r13, %rbx
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	_ENOENT@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	jne	LBB0_2
## %bb.3:
	movq	_PAM_LOG_DEBUG@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_2:
	movq	_PAM_LOG_ERROR@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdx
	callq	_openpam_log
	movq	_errno@GOTPCREL(%rip), %rax
	movl	%r13d, (%rax)
	movl	$-1, %edi
	callq	_RETURNN
	movq	%rbx, %r13
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
LBB0_6:
	movq	_VERIFY_POLICY_FILE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_OPENPAM_FEATURE
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movq	%r14, %rdi
	callq	_fileno
	movq	%r15, %rdi
	movl	%eax, %esi
	callq	_openpam_check_desc_owner_perms
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movl	%r12d, %ebx
	movl	(%rax), %r12d
	movq	%r14, %rdi
	callq	_fclose
	movq	_errno@GOTPCREL(%rip), %rax
	movl	%r12d, (%rax)
	movl	%ebx, %r12d
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movl	$-1, %edi
	callq	_RETURNN
LBB0_9:
	movq	%rbx, %rdi
	movq	%r13, %rsi
	movl	%r12d, %edx
	movq	%r14, %rcx
	movq	%r15, %r8
	movl	-52(%rbp), %r9d                 ## 4-byte Reload
	callq	_openpam_parse_chain
	movl	%eax, %edi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_RETURNN                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"r"

	.comm	_errno,4,2                      ## @errno
	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_PAM_LOG_DEBUG,4,2              ## @PAM_LOG_DEBUG
	.comm	_PAM_LOG_ERROR,4,2              ## @PAM_LOG_ERROR
L_.str.1:                               ## @.str.1
	.asciz	"%s: %m"

L_.str.2:                               ## @.str.2
	.asciz	"found %s"

	.comm	_VERIFY_POLICY_FILE,4,2         ## @VERIFY_POLICY_FILE
	.no_dead_strip	_openpam_load_file
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function openpam_load_file
_openpam_load_file:                     ; @openpam_load_file
	.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	x19, x4
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
	mov	x23, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x3
	bl	_fopen
	mov	x24, x0
	cbz	x0, LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _PAM_LOG_DEBUG@GOTPAGE
Lloh3:
	ldr	x8, [x8, _PAM_LOG_DEBUG@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
Lloh5:
	adrp	x1, l_.str.2@PAGE
Lloh6:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x2, x20
	bl	_openpam_log
	b	LBB0_3
LBB0_2:
Lloh7:
	adrp	x25, _errno@GOTPAGE
Lloh8:
	ldr	x25, [x25, _errno@GOTPAGEOFF]
	ldr	w26, [x25]
Lloh9:
	adrp	x8, _ENOENT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh11:
	adrp	x9, _PAM_LOG_DEBUG@GOTPAGE
Lloh12:
	ldr	x9, [x9, _PAM_LOG_DEBUG@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
Lloh14:
	adrp	x10, _PAM_LOG_ERROR@GOTPAGE
Lloh15:
	ldr	x10, [x10, _PAM_LOG_ERROR@GOTPAGEOFF]
	cmp	w26, w8
	csel	x8, x9, x10, eq
	ldr	w0, [x8]
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x20
	bl	_openpam_log
	str	w26, [x25]
	mov	w0, #-1
	bl	_RETURNN
LBB0_3:
Lloh18:
	adrp	x8, _VERIFY_POLICY_FILE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _VERIFY_POLICY_FILE@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	bl	_OPENPAM_FEATURE
	cbz	x0, LBB0_6
; %bb.4:
	mov	x0, x24
	bl	_fileno
	mov	x1, x0
	mov	x0, x20
	bl	_openpam_check_desc_owner_perms
	cbz	x0, LBB0_6
; %bb.5:
Lloh21:
	adrp	x25, _errno@GOTPAGE
Lloh22:
	ldr	x25, [x25, _errno@GOTPAGEOFF]
	ldr	w26, [x25]
	mov	x0, x24
	bl	_fclose
	str	w26, [x25]
	mov	w0, #-1
	bl	_RETURNN
LBB0_6:
	mov	x0, x23
	mov	x1, x22
	mov	x2, x21
	mov	x3, x24
	mov	x4, x20
	mov	x5, x19
	bl	_openpam_parse_chain
	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
	b	_RETURNN
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh13
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"r"

	.comm	_errno,4,2                      ; @errno
	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_PAM_LOG_DEBUG,4,2              ; @PAM_LOG_DEBUG
	.comm	_PAM_LOG_ERROR,4,2              ; @PAM_LOG_ERROR
l_.str.1:                               ; @.str.1
	.asciz	"%s: %m"

l_.str.2:                               ; @.str.2
	.asciz	"found %s"

	.comm	_VERIFY_POLICY_FILE,4,2         ; @VERIFY_POLICY_FILE
	.no_dead_strip	_openpam_load_file
.subsections_via_symbols
