Function at 0x1000a2798
Capabilities:
Enumerate services
Query service status
Stop service

Disassembly:
mov rax, rsp
mov qword [rax + 0x18], rbx
mov dword [rax + 0x20], r9d
mov dword [rax + 0x10], edx
mov qword [rax + 8], rcx
push rbp
push rsi
push rdi
sub rsp, 0xb0
mov ebp, r9d
mov rsi, rcx
mov rcx, qword [0x1001653b8]
lea rax, [0x1001653b8]
cmp rcx, rax
je 0x1000a27f5
test byte [rcx + 0x1c], 1
je 0x1000a27f5
cmp byte [rcx + 0x19], 4
jb 0x1000a27f5
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x63
call fcn.10001c854
mov rcx, qword [0x1001653b8]
xor eax, eax
mov ebx, eax
mov qword [rsp + 0x48], rax
mov rdi, rax
mov qword [rsp + 0x50], rax
mov dword [rsp + 0x3c], eax
mov dword [rsp + 0x38], eax
cmp rsi, rax
jne 0x1000a2832
lea r8, [0x10000a540]
lea rcx, [0x10000a238]
mov edx, 0x7e7
call fcn.10009a050
mov rcx, qword [0x1001653b8]
lea rax, [0x1001653b8]
cmp rcx, rax
je 0x1000a2870
test byte [rcx + 0x1c], 1
je 0x1000a2870
cmp byte [rcx + 0x19], 4
jb 0x1000a2870
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x64
mov r9, rsi
call fcn.10001db08
mov rcx, qword [0x1001653b8]
lea rax, [0x1001653b8]
cmp ebp, 0xa
jb 0x1000a28af
cmp rcx, rax
je 0x1000a28a5
test byte [rcx + 0x1c], 1
je 0x1000a28a5
cmp byte [rcx + 0x19], 2
jb 0x1000a28a5
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x65
mov r9, rsi
call fcn.10001db08
mov rcx, qword [0x1001653b8]
mov ebx, 0x8000ffff
jmp 0x1000a2db6
xor edx, edx
xor ecx, ecx
lea r8d, [rdx + 1]
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov qword [rsp + 0x48], rax
test rax, rax
jne 0x1000a292a
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov rcx, qword [0x1001653b8]
lea rbp, [0x1001653b8]
cmp rcx, rbp
je 0x1000a2f5e
test byte [rcx + 0x1c], 1
je 0x1000a2dbd
cmp byte [rcx + 0x19], 2
jb 0x1000a2dbd
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x66
mov r9d, ebx
call fcn.10001c878
mov rcx, qword [0x1001653b8]
jmp 0x1000a2dbd
mov r8d, 0x2c
mov rdx, rsi
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rdi, rax
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x40], rax
test rax, rax
jne 0x1000a2995
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov rcx, qword [0x1001653b8]
lea rbp, [0x1001653b8]
cmp rcx, rbp
je 0x1000a2f5e
test byte [rcx + 0x1c], 1
je 0x1000a2f4b
cmp byte [rcx + 0x19], 2
jb 0x1000a2f4b
lea edx, [rdi + 0x67]
jmp 0x1000a2f2d
lea rdx, [rsp + 0x58]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
jne 0x1000a29c7
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov rcx, qword [0x1001653b8]
jmp 0x1000a2db6
cmp dword [rsp + 0x5c], 1
jne 0x1000a2a16
mov rcx, qword [0x1001653b8]
lea rbp, [0x1001653b8]
cmp rcx, rbp
je 0x1000a2f4b
test byte [rcx + 0x1c], 1
je 0x1000a2f4b
cmp byte [rcx + 0x19], 4
jb 0x1000a2f4b
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x68
mov r9, rsi
call fcn.10001db08
jmp 0x1000a2f44
cmp dword [rsp + 0x5c], 3
jne 0x1000a2ad9
mov rcx, qword [0x1001653b8]
lea rdi, [0x1001653b8]
cmp rcx, rdi
je 0x1000a2a5f
test byte [rcx + 0x1c], 1
je 0x1000a2a5f
cmp byte [rcx + 0x19], 4
jb 0x1000a2a5f
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x69
mov r9, rsi
call fcn.10001db08
mov rcx, qword [0x1001653b8]
cmp dword [rsp + 0xd8], ebx
je 0x1000a2db1
lea rcx, [rsp + 0x40]
xor edx, edx
mov r8d, 0xea60
call fcn.1000a2534
mov ebx, eax
test eax, eax
jns 0x1000a2ab4
mov rcx, qword [0x1001653b8]
cmp rcx, rdi
je 0x1000a2acf
test byte [rcx + 0x1c], 1
je 0x1000a2ac5
cmp byte [rcx + 0x19], 2
jb 0x1000a2ac5
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x6a
mov r9d, eax
call fcn.10001c878
mov rdi, qword [rsp + 0x40]
mov rcx, qword [0x1001653b8]
jmp 0x1000a2db6
mov rdi, qword [rsp + 0x40]
jmp 0x1000a2db6
mov rdi, qword [rsp + 0x40]
jmp 0x1000a2f5e
lea r8, [rsp + 0x58]
mov edx, 1
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
jne 0x1000a2ecd
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x41b
jne 0x1000a2efb
mov rcx, qword [0x1001653b8]
lea rax, [0x1001653b8]
cmp rcx, rax
je 0x1000a2b3c
test byte [rcx + 0x1c], 1
je 0x1000a2b3c
cmp byte [rcx + 0x19], 4
jb 0x1000a2b3c
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x6b
mov r9, rsi
call fcn.10001db08
lea rax, [rsp + 0x38]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x3c]
lea edx, [r9 + 1]
mov rcx, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_EnumDependentServicesW]
test eax, eax
je 0x1000a2b71
mov ebx, 0x8000ffff
jmp 0x1000a29bb
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xea
je 0x1000a2bd4
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov rcx, qword [0x1001653b8]
lea rbp, [0x1001653b8]
cmp rcx, rbp
je 0x1000a2f5e
test byte [rcx + 0x1c], 1
je 0x1000a2f4b
cmp byte [rcx + 0x19], 2
jb 0x1000a2f4b
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x6c
mov r9d, ebx
call fcn.10001c878
jmp 0x1000a2f44
mov ebx, dword [rsp + 0x3c]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rbx
mov rcx, rax
mov edx, 8
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rbx, rax
mov qword [rsp + 0x50], rax
test rax, rax
jne 0x1000a2c06
mov ebx, 0x8007000e
jmp 0x1000a29bb
mov r9d, dword [rsp + 0x3c]
lea rax, [rsp + 0x38]
mov r8, rbx
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x3c]
mov edx, 1
mov rcx, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_EnumDependentServicesW]
test eax, eax
jne 0x1000a2c7d
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov rcx, qword [0x1001653b8]
lea rbp, [0x1001653b8]
cmp rcx, rbp
je 0x1000a2f5e
test byte [rcx + 0x1c], 1
je 0x1000a2f4b
cmp byte [rcx + 0x19], 2
jb 0x1000a2f4b
mov edx, 0x6d
jmp 0x1000a2f2d
xor edi, edi
cmp dword [rsp + 0x38], edi
jbe 0x1000a2dfb
mov rsi, rbx
mov rbx, qword [0x1001653b8]
lea rcx, [rsp + 0x78]
mov rdx, rsi
mov r8d, 0x30
call sub.msvcrt.dll_memcpy
mov rbp, qword [rsp + 0x78]
lea rax, [0x1001653b8]
cmp rbx, rax
je 0x1000a2cdb
test byte [rbx + 0x1c], 1
je 0x1000a2cdb
cmp byte [rbx + 0x19], 4
jb 0x1000a2cdb
mov rcx, qword [rbx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x6e
mov r9, rbp
call fcn.10001db08
mov r9d, dword [rsp + 0xe8]
mov edx, dword [rsp + 0xd8]
mov r8d, 0xea60
inc r9d
mov rcx, rbp
call fcn.1000a2798
mov ebx, eax
test eax, eax
js 0x1000a2d63
mov rbx, qword [0x1001653b8]
lea rax, [0x1001653b8]
cmp rbx, rax
je 0x1000a2d3f
test byte [rbx + 0x1c], 1
je 0x1000a2d3f
cmp byte [rbx + 0x19], 4
jb 0x1000a2d3f
mov rcx, qword [rbx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x70
mov r9, rbp
call fcn.10001db08
mov rbx, qword [0x1001653b8]
inc edi
add rsi, 0x30
cmp edi, dword [rsp + 0x38]
jb 0x1000a2c93
mov rsi, qword [rsp + 0xd0]
mov ebp, dword [rsp + 0xe8]
jmp 0x1000a2e02
mov rcx, qword [0x1001653b8]
lea rsi, [0x1001653b8]
cmp rcx, rsi
je 0x1000a2f50
test byte [rcx + 0x1c], 1
je 0x1000a2da9
cmp byte [rcx + 0x19], 2
jb 0x1000a2da9
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x6f
mov r9, rbp
mov dword [rsp + 0x20], eax
call fcn.10001ddb0
mov rcx, qword [0x1001653b8]
mov rsi, qword [rsp + 0xd0]
mov rdi, qword [rsp + 0x30]
lea rbp, [0x1001653b8]
cmp rcx, rbp
je 0x1000a2f5e
test byte [rcx + 0x1c], 1
je 0x1000a2f5e
cmp byte [rcx + 0x19], 4
jb 0x1000a2f5e
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x75
mov r9, rsi
mov dword [rsp + 0x20], ebx
call fcn.10001ddb0
jmp 0x1000a2f5e
mov rbx, qword [0x1001653b8]
lea rdi, [0x1001653b8]
cmp rbx, rdi
je 0x1000a2e32
test byte [rbx + 0x1c], 1
je 0x1000a2e32
cmp byte [rbx + 0x19], 4
jb 0x1000a2e32
mov rcx, qword [rbx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x71
mov r9, rsi
call fcn.10001db08
mov edx, dword [rsp + 0xd8]
lea r9d, [rbp + 1]
mov r8d, 0xea60
mov rcx, rsi
call fcn.1000a2798
mov ebx, eax
test eax, eax
jns 0x1000a2e9d
mov rcx, qword [0x1001653b8]
cmp rcx, rdi
je 0x1000a2f57
test byte [rcx + 0x1c], 1
je 0x1000a2db1
cmp byte [rcx + 0x19], 2
jb 0x1000a2db1
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x72
mov r9, rsi
mov dword [rsp + 0x20], eax
call fcn.10001ddb0
mov rcx, qword [0x1001653b8]
jmp 0x1000a2db1
mov rcx, qword [0x1001653b8]
cmp rcx, rdi
je 0x1000a2ed4
test byte [rcx + 0x1c], 1
je 0x1000a2ed4
cmp byte [rcx + 0x19], 4
jb 0x1000a2ed4
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x73
mov r9, rsi
call fcn.10001db08
mov rcx, qword [0x1001653b8]
cmp dword [rsp + 0xd8], 0
je 0x1000a2db1
lea rcx, [rsp + 0x40]
xor edx, edx
mov r8d, 0xea60
call fcn.1000a2534
mov ebx, eax
jmp 0x1000a2ab4
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov rcx, qword [0x1001653b8]
lea rbp, [0x1001653b8]
cmp rcx, rbp
je 0x1000a2f5e
test byte [rcx + 0x1c], 1
je 0x1000a2f4b
cmp byte [rcx + 0x19], 2
jb 0x1000a2f4b
mov edx, 0x74
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov r9, rsi
mov dword [rsp + 0x20], ebx
call fcn.10001ddb0
mov rcx, qword [0x1001653b8]
jmp 0x1000a2dbd
mov rdi, qword [rsp + 0x30]
jmp 0x1000a2f65
mov rdi, qword [rsp + 0x30]
jmp 0x1000a2f5e
lea rsi, [0x1001653b8]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, qword [rsp + 0x50]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
test rdi, rdi
je 0x1000a2f89
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rax, qword [rsp + 0x48]
test rax, rax
je 0x1000a2f9c
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, qword [0x1001653b8]
cmp rcx, rsi
je 0x1000a2fc9
test byte [rcx + 0x1c], 1
je 0x1000a2fc9
cmp byte [rcx + 0x19], 4
jb 0x1000a2fc9
mov rcx, qword [rcx + 0x10]
lea r8, [0x1000039a8]
mov edx, 0x76
call fcn.10001c854
mov eax, ebx
mov rbx, qword [rsp + 0xe0]
add rsp, 0xb0
pop rdi
pop rsi
pop rbp
ret