	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_update_pps_file                ## -- Begin function update_pps_file
	.p2align	4, 0x90
_update_pps_file:                       ## @update_pps_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	$312, %rsp                      ## imm = 0x138
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	cmpq	$0, 8(%rdi)
	je	LBB0_4
## %bb.1:
	movl	(%rbx), %edi
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rsi
	callq	_get_child_node
	testq	%rax, %rax
	je	LBB0_4
## %bb.2:
	movq	%rax, %r12
	leaq	L_.str.1(%rip), %rdi
	callq	_os_file_exists
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movl	4(%rbx), %edx
	movq	%rbx, %rdi
	movq	%r12, %rsi
	callq	_process_est_cert
	testq	%rax, %rax
	js	LBB0_9
LBB0_4:
	movq	_MSG_INFO@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	leaq	L_.str.3(%rip), %rsi
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_wpa_printf
	movl	(%rbx), %edi
	movq	%r15, %rsi
	callq	_xml_node_to_str
	testq	%rax, %rax
	je	LBB0_7
## %bb.5:
	movq	%rax, %r12
	movq	_MSG_MSGDUMP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.5(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r12, %rdx
	xorl	%eax, %eax
	callq	_wpa_printf
	leaq	L_.str.6(%rip), %rdx
	leaq	-352(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$300, %esi                      ## imm = 0x12C
	movq	%r14, %rcx
	callq	_snprintf
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_rename
	leaq	L_.str.7(%rip), %rsi
	movq	%r14, %rdi
	callq	_fopen
	testq	%rax, %rax
	je	LBB0_8
## %bb.6:
	movq	%rax, %rbx
	leaq	L_.str.9(%rip), %rsi
	movq	%rax, %rdi
	movq	%r12, %rdx
	callq	_fprintf
	movq	%rbx, %rdi
	callq	_fclose
	movq	%r12, %rdi
	callq	_free
	jmp	LBB0_12
LBB0_7:
	movq	_MSG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_10
LBB0_8:
	movl	(%r13), %edi
	leaq	L_.str.8(%rip), %rsi
	xorl	%eax, %eax
	callq	_wpa_printf
	leaq	-352(%rbp), %rdi
	movq	%r14, %rsi
	callq	_rename
	movq	%r12, %rdi
	callq	_free
	jmp	LBB0_11
LBB0_9:
	movq	_MSG_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
LBB0_10:
	xorl	%eax, %eax
	callq	_wpa_printf
LBB0_11:
	movl	$-1, %r15d
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	movl	%r15d, %eax
	addq	$312, %rsp                      ## imm = 0x138
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Credential/DigitalCertificate/CertSHA256Fingerprint"

L_.str.1:                               ## @.str.1
	.asciz	"Cert/est_cert.der"

	.comm	_MSG_INFO,4,2                   ## @MSG_INFO
L_.str.2:                               ## @.str.2
	.asciz	"EST certificate update processing failed on PPS MO update"

L_.str.3:                               ## @.str.3
	.asciz	"Updating PPS MO %s"

	.comm	_MSG_ERROR,4,2                  ## @MSG_ERROR
L_.str.4:                               ## @.str.4
	.asciz	"No node found"

	.comm	_MSG_MSGDUMP,4,2                ## @MSG_MSGDUMP
L_.str.5:                               ## @.str.5
	.asciz	"[hs20] Updated PPS: '%s'"

L_.str.6:                               ## @.str.6
	.asciz	"%s.bak"

L_.str.7:                               ## @.str.7
	.asciz	"w"

L_.str.8:                               ## @.str.8
	.asciz	"Could not write PPS"

L_.str.9:                               ## @.str.9
	.asciz	"%s\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_update_pps_file                ; -- Begin function update_pps_file
	.p2align	2
_update_pps_file:                       ; @update_pps_file
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #384
	.cfi_def_cfa_offset 384
	stp	x28, x27, [sp, #320]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #336]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #352]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #368]            ; 16-byte Folded Spill
	add	x29, sp, #368
	.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 w27, -56
	.cfi_offset w28, -64
	mov	x20, x2
	mov	x19, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_4
; %bb.1:
	ldr	w0, [x21]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	mov	x1, x20
	bl	_get_child_node
	cbz	x0, LBB0_4
; %bb.2:
	mov	x22, x0
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_os_file_exists
	cbz	x0, LBB0_4
; %bb.3:
	ldr	w2, [x21, #4]
	mov	x0, x21
	mov	x1, x22
	bl	_process_est_cert
	tbnz	x0, #63, LBB0_9
LBB0_4:
Lloh7:
	adrp	x22, _MSG_INFO@GOTPAGE
Lloh8:
	ldr	x22, [x22, _MSG_INFO@GOTPAGEOFF]
	ldr	w0, [x22]
	str	x19, [sp]
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_wpa_printf
	ldr	w0, [x21]
	mov	x1, x20
	bl	_xml_node_to_str
	cbz	x0, LBB0_7
; %bb.5:
	mov	x20, x0
Lloh11:
	adrp	x8, _MSG_MSGDUMP@GOTPAGE
Lloh12:
	ldr	x8, [x8, _MSG_MSGDUMP@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	str	x20, [sp]
Lloh14:
	adrp	x1, l_.str.5@PAGE
Lloh15:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_wpa_printf
Lloh16:
	adrp	x2, l_.str.6@PAGE
Lloh17:
	add	x2, x2, l_.str.6@PAGEOFF
	add	x0, sp, #12
	mov	w1, #300
	mov	x3, x19
	bl	_snprintf
	add	x1, sp, #12
	mov	x0, x19
	bl	_rename
Lloh18:
	adrp	x1, l_.str.7@PAGE
Lloh19:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x0, x19
	bl	_fopen
	cbz	x0, LBB0_8
; %bb.6:
	mov	x21, x0
Lloh20:
	adrp	x1, l_.str.9@PAGE
Lloh21:
	add	x1, x1, l_.str.9@PAGEOFF
	mov	x2, x20
	bl	_fprintf
	mov	x0, x21
	bl	_fclose
	mov	x0, x20
	bl	_free
	mov	w0, #0
	b	LBB0_12
LBB0_7:
Lloh22:
	adrp	x8, _MSG_ERROR@GOTPAGE
Lloh23:
	ldr	x8, [x8, _MSG_ERROR@GOTPAGEOFF]
Lloh24:
	ldr	w0, [x8]
Lloh25:
	adrp	x1, l_.str.4@PAGE
Lloh26:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_10
LBB0_8:
	ldr	w0, [x22]
Lloh27:
	adrp	x1, l_.str.8@PAGE
Lloh28:
	add	x1, x1, l_.str.8@PAGEOFF
	bl	_wpa_printf
	add	x0, sp, #12
	mov	x1, x19
	bl	_rename
	mov	x0, x20
	bl	_free
	b	LBB0_11
LBB0_9:
Lloh29:
	adrp	x8, _MSG_INFO@GOTPAGE
Lloh30:
	ldr	x8, [x8, _MSG_INFO@GOTPAGEOFF]
Lloh31:
	ldr	w0, [x8]
Lloh32:
	adrp	x1, l_.str.2@PAGE
Lloh33:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_10:
	bl	_wpa_printf
LBB0_11:
	mov	w0, #-1
LBB0_12:
	ldur	x8, [x29, #-56]
Lloh34:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh35:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh36:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.13:
	ldp	x29, x30, [sp, #368]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #352]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #336]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #320]            ; 16-byte Folded Reload
	add	sp, sp, #384
	ret
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Credential/DigitalCertificate/CertSHA256Fingerprint"

l_.str.1:                               ; @.str.1
	.asciz	"Cert/est_cert.der"

	.comm	_MSG_INFO,4,2                   ; @MSG_INFO
l_.str.2:                               ; @.str.2
	.asciz	"EST certificate update processing failed on PPS MO update"

l_.str.3:                               ; @.str.3
	.asciz	"Updating PPS MO %s"

	.comm	_MSG_ERROR,4,2                  ; @MSG_ERROR
l_.str.4:                               ; @.str.4
	.asciz	"No node found"

	.comm	_MSG_MSGDUMP,4,2                ; @MSG_MSGDUMP
l_.str.5:                               ; @.str.5
	.asciz	"[hs20] Updated PPS: '%s'"

l_.str.6:                               ; @.str.6
	.asciz	"%s.bak"

l_.str.7:                               ; @.str.7
	.asciz	"w"

l_.str.8:                               ; @.str.8
	.asciz	"Could not write PPS"

l_.str.9:                               ; @.str.9
	.asciz	"%s\n"

.subsections_via_symbols
