	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function CmdRemoveServices
_CmdRemoveServices:                     ## @CmdRemoveServices
	.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
	movq	__service_max@GOTPCREL(%rip), %r15
	movl	(%r15), %r14d
	movq	_SC_MANAGER_CONNECT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%edi, %edi
	xorl	%esi, %esi
	callq	_OpenSCManager
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	testq	%rax, %rax
	je	LBB0_17
## %bb.1:
	cmpl	$0, (%r15)
	jle	LBB0_15
## %bb.2:
	xorl	%r13d, %r13d
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_3 Depth=1
	leaq	L_.str.7(%rip), %rdi
	callq	_TEXT
	movl	%r14d, %ebx
	movl	%eax, %r14d
	xorl	%eax, %eax
	callq	_GetLastErrorText
	movl	%r14d, %edi
	movl	%ebx, %r14d
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	__tprintf
LBB0_14:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	%r12, %rdi
	callq	_CloseServiceHandle
	incq	%r13
	movslq	(%r15), %rax
	cmpq	%rax, %r13
	jge	LBB0_15
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_6 Depth 2
	movq	_openvpn_service@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	movl	4(%rbx,%r13,8), %esi
	movq	_SERVICE_STOP@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_DELETE@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	_SERVICE_QUERY_STATUS@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_OpenService
	testq	%rax, %rax
	je	LBB0_12
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	%rax, %r12
	movq	_SERVICE_CONTROL_STOP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	leaq	-48(%rbp), %rdx
	callq	_ControlService
	testq	%rax, %rax
	je	LBB0_10
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	leaq	L_.str.2(%rip), %rdi
	callq	_TEXT
	movl	(%rbx,%r13,8), %esi
	movl	%eax, %edi
	xorl	%eax, %eax
	callq	__tprintf
	.p2align	4, 0x90
LBB0_6:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	$1000, %edi                     ## imm = 0x3E8
	callq	_Sleep
	movq	%r12, %rdi
	leaq	-48(%rbp), %rsi
	callq	_QueryServiceStatus
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=2
	movq	-48(%rbp), %rax
	movq	_SERVICE_STOP_PENDING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=2
	leaq	L_.str.3(%rip), %rdi
	callq	_TEXT
	movl	%eax, %edi
	xorl	%eax, %eax
	callq	__tprintf
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	-48(%rbp), %rax
	movq	_SERVICE_STOPPED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	leaq	L_.str.5(%rip), %rdi
	leaq	L_.str.4(%rip), %rax
	cmoveq	%rax, %rdi
	callq	_TEXT
	movl	(%rbx,%r13,8), %esi
	movl	%eax, %edi
	xorl	%eax, %eax
	callq	__tprintf
LBB0_10:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	%r12, %rdi
	callq	_DeleteService
	testq	%rax, %rax
	je	LBB0_13
## %bb.11:                              ##   in Loop: Header=BB0_3 Depth=1
	leaq	L_.str.6(%rip), %rdi
	callq	_TEXT
	movl	(%rbx,%r13,8), %esi
	movl	%eax, %edi
	xorl	%eax, %eax
	callq	__tprintf
	decl	%r14d
	jmp	LBB0_14
LBB0_17:
	leaq	L_.str(%rip), %rdi
	callq	_TEXT
	movl	%eax, %ebx
	xorl	%eax, %eax
	callq	_GetLastErrorText
	movl	%ebx, %edi
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	__tprintf
	movl	$1, %r14d
	jmp	LBB0_16
LBB0_12:
	leaq	L_.str.1(%rip), %rdi
	callq	_TEXT
	movl	%eax, %ebx
	xorl	%eax, %eax
	callq	_GetLastErrorText
	movl	%ebx, %edi
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	__tprintf
LBB0_15:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_CloseServiceHandle
LBB0_16:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	__service_max,4,2               ## @_service_max
	.comm	_SC_MANAGER_CONNECT,4,2         ## @SC_MANAGER_CONNECT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"OpenSCManager failed - %s\n"

	.comm	_openvpn_service,8,3            ## @openvpn_service
	.comm	_DELETE,4,2                     ## @DELETE
	.comm	_SERVICE_STOP,4,2               ## @SERVICE_STOP
	.comm	_SERVICE_QUERY_STATUS,4,2       ## @SERVICE_QUERY_STATUS
L_.str.1:                               ## @.str.1
	.asciz	"OpenService failed - %s\n"

	.comm	_SERVICE_CONTROL_STOP,4,2       ## @SERVICE_CONTROL_STOP
L_.str.2:                               ## @.str.2
	.asciz	"Stopping %s."

	.comm	_SERVICE_STOP_PENDING,8,3       ## @SERVICE_STOP_PENDING
L_.str.3:                               ## @.str.3
	.asciz	"."

	.comm	_SERVICE_STOPPED,8,3            ## @SERVICE_STOPPED
L_.str.4:                               ## @.str.4
	.asciz	"\n%s stopped.\n"

L_.str.5:                               ## @.str.5
	.asciz	"\n%s failed to stop.\n"

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

L_.str.7:                               ## @.str.7
	.asciz	"DeleteService failed - %s\n"

	.no_dead_strip	_CmdRemoveServices
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function CmdRemoveServices
_CmdRemoveServices:                     ; @CmdRemoveServices
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
Lloh0:
	adrp	x27, __service_max@GOTPAGE
Lloh1:
	ldr	x27, [x27, __service_max@GOTPAGEOFF]
	ldr	w19, [x27]
Lloh2:
	adrp	x8, _SC_MANAGER_CONNECT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _SC_MANAGER_CONNECT@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
	mov	x0, #0
	mov	x1, #0
	bl	_OpenSCManager
	cbz	x0, LBB0_14
; %bb.1:
	mov	x20, x0
	ldr	w8, [x27]
	cmp	w8, #1
	b.lt	LBB0_16
; %bb.2:
	mov	x28, #0
Lloh5:
	adrp	x23, _SERVICE_STOP@GOTPAGE
Lloh6:
	ldr	x23, [x23, _SERVICE_STOP@GOTPAGEOFF]
Lloh7:
	adrp	x21, _SERVICE_QUERY_STATUS@GOTPAGE
Lloh8:
	ldr	x21, [x21, _SERVICE_QUERY_STATUS@GOTPAGEOFF]
Lloh9:
	adrp	x22, _SERVICE_STOP_PENDING@GOTPAGE
Lloh10:
	ldr	x22, [x22, _SERVICE_STOP_PENDING@GOTPAGEOFF]
Lloh11:
	adrp	x24, l_.str.3@PAGE
Lloh12:
	add	x24, x24, l_.str.3@PAGEOFF
	b	LBB0_5
LBB0_3:                                 ;   in Loop: Header=BB0_5 Depth=1
Lloh13:
	adrp	x0, l_.str.7@PAGE
Lloh14:
	add	x0, x0, l_.str.7@PAGEOFF
	bl	_TEXT
	mov	x26, x0
	bl	_GetLastErrorText
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
	mov	x0, x26
	bl	__tprintf
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x25
	bl	_CloseServiceHandle
	add	x28, x28, #1
	ldrsw	x8, [x27]
	cmp	x28, x8
	b.ge	LBB0_16
LBB0_5:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_8 Depth 2
Lloh15:
	adrp	x8, _openvpn_service@GOTPAGE
Lloh16:
	ldr	x8, [x8, _openvpn_service@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	add	x26, x8, x28, lsl #3
	ldr	w1, [x26, #4]
Lloh18:
	adrp	x8, _DELETE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _DELETE@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	ldr	w9, [x23]
	orr	w8, w9, w8
	ldr	w9, [x21]
	orr	w2, w8, w9
	mov	x0, x20
	bl	_OpenService
	cbz	x0, LBB0_15
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x25, x0
Lloh21:
	adrp	x8, _SERVICE_CONTROL_STOP@GOTPAGE
Lloh22:
	ldr	x8, [x8, _SERVICE_CONTROL_STOP@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	add	x2, sp, #8
	bl	_ControlService
	cbz	x0, LBB0_12
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
Lloh24:
	adrp	x0, l_.str.2@PAGE
Lloh25:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_TEXT
	ldr	w8, [x26]
	str	x8, [sp]
LBB0_8:                                 ;   Parent Loop BB0_5 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	bl	__tprintf
	mov	w0, #1000
	bl	_Sleep
	add	x1, sp, #8
	mov	x0, x25
	bl	_QueryServiceStatus
	cbz	x0, LBB0_11
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=2
	ldr	x8, [sp, #8]
	ldr	x9, [x22]
	cmp	x8, x9
	b.ne	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=2
	mov	x0, x24
	bl	_TEXT
	b	LBB0_8
LBB0_11:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [sp, #8]
Lloh26:
	adrp	x9, _SERVICE_STOPPED@GOTPAGE
Lloh27:
	ldr	x9, [x9, _SERVICE_STOPPED@GOTPAGEOFF]
Lloh28:
	ldr	x9, [x9]
	cmp	x8, x9
Lloh29:
	adrp	x8, l_.str.5@PAGE
Lloh30:
	add	x8, x8, l_.str.5@PAGEOFF
Lloh31:
	adrp	x9, l_.str.4@PAGE
Lloh32:
	add	x9, x9, l_.str.4@PAGEOFF
	csel	x0, x9, x8, eq
	bl	_TEXT
	ldr	w8, [x26]
	str	x8, [sp]
	bl	__tprintf
LBB0_12:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x25
	bl	_DeleteService
	cbz	x0, LBB0_3
; %bb.13:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh33:
	adrp	x0, l_.str.6@PAGE
Lloh34:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_TEXT
	ldr	w8, [x26]
	str	x8, [sp]
	bl	__tprintf
	sub	w19, w19, #1
	b	LBB0_4
LBB0_14:
Lloh35:
	adrp	x0, l_.str@PAGE
Lloh36:
	add	x0, x0, l_.str@PAGEOFF
	bl	_TEXT
	mov	x19, x0
	bl	_GetLastErrorText
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
	mov	x0, x19
	bl	__tprintf
	mov	w19, #1
	b	LBB0_17
LBB0_15:
Lloh37:
	adrp	x0, l_.str.1@PAGE
Lloh38:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_TEXT
	mov	x21, x0
	bl	_GetLastErrorText
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
	mov	x0, x21
	bl	__tprintf
LBB0_16:
	mov	x0, x20
	bl	_CloseServiceHandle
LBB0_17:
	mov	x0, x19
	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
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpAdd	Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	__service_max,4,2               ; @_service_max
	.comm	_SC_MANAGER_CONNECT,4,2         ; @SC_MANAGER_CONNECT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"OpenSCManager failed - %s\n"

	.comm	_openvpn_service,8,3            ; @openvpn_service
	.comm	_DELETE,4,2                     ; @DELETE
	.comm	_SERVICE_STOP,4,2               ; @SERVICE_STOP
	.comm	_SERVICE_QUERY_STATUS,4,2       ; @SERVICE_QUERY_STATUS
l_.str.1:                               ; @.str.1
	.asciz	"OpenService failed - %s\n"

	.comm	_SERVICE_CONTROL_STOP,4,2       ; @SERVICE_CONTROL_STOP
l_.str.2:                               ; @.str.2
	.asciz	"Stopping %s."

	.comm	_SERVICE_STOP_PENDING,8,3       ; @SERVICE_STOP_PENDING
l_.str.3:                               ; @.str.3
	.asciz	"."

	.comm	_SERVICE_STOPPED,8,3            ; @SERVICE_STOPPED
l_.str.4:                               ; @.str.4
	.asciz	"\n%s stopped.\n"

l_.str.5:                               ; @.str.5
	.asciz	"\n%s failed to stop.\n"

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

l_.str.7:                               ; @.str.7
	.asciz	"DeleteService failed - %s\n"

	.no_dead_strip	_CmdRemoveServices
.subsections_via_symbols
