Function at 0x180058bd0
Capabilities:
Modify service

Disassembly:
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbx
push rbp
push rsi
push rdi
push r13
push r14
push r15
sub rsp, 0xd0
mov rdi, qword [rsp + 0x68]
xor ebx, ebx
imul r15d, r8d, 0x36c
mov r10, r9
mov r13d, r8d
mov r11, rcx
mov ebp, r8d
cmp r8d, r15d
ja 0x180058fbf
movzx eax, byte [rsp + 0x120]
mov r14, qword [rsp + 0x68]
mov byte [rsp + 0x120], al
mov rax, qword [rsp + 0x68]
mov ecx, dword [rsp + 0x120]
mov qword [rsp + 0x80], rax
mov eax, dword [rsp + 0x120]
mov dword [rsp + 0x60], eax
mov dword [rsp + 0x64], ecx
nop word [rax + rax]
cmp ebp, 0x1419
ja 0x180058e19
je 0x180058dd3
cmp ebp, 0x127
ja 0x180058d9b
je 0x180058eb2
cmp ebp, 0x23
je 0x180058d8e
cmp ebp, 0x47
je 0x180058c9d
movzx esi, byte [rsp + 0x120]
cmp ebp, 0xf3
jne 0x180058ce8
mov ecx, 0x80
mov dword [rsp + 0x60], ecx
jmp 0x180058cec
mov qword [rsp + 0x28], rbx
mov r9d, 5
xor r8d, r8d
mov qword [rsp + 0x20], rbx
mov rdx, r11
xor ecx, ecx
call fcn.1800ab8e0
mov rcx, qword [rsp + 0x128]
xor r9d, r9d
xor edx, edx
lea r8d, [r9 + 5]
call fcn.180107c90
mov r10, qword [rsp + 0x128]
mov r11, qword [rsp + 0x110]
movzx esi, byte [rsp + 0x120]
mov ecx, dword [rsp + 0x60]
mov rdx, qword [rsp + 0x118]
imul eax, r13d, 0x49
add ebp, eax
cmp ebp, r15d
jbe 0x180058c50
mov eax, dword [rsp + 0x64]
mov qword [rsp + 0xc8], r12
lea r12d, [r13 + 0x90c]
cmp r13d, r12d
jae 0x1800590ee
mov ebp, dword [rsp + 0x120]
mov r14d, dword [rsp + 0x120]
mov r15d, dword [rsp + 0x120]
lea r8, [0x18001b5c0]
cmp r13d, 0x1a5
ja 0x18005914b
je 0x180059140
cmp r13d, 0xf3
ja 0x1800590db
je 0x18005905c
cmp r13d, 0x23
je 0x180059055
cmp r13d, 0x47
je 0x180058ff7
cmp r13d, 0xe4
jne 0x180059034
mov qword [rsp + 0x68], rbx
jmp 0x180059034
mov qword [rsp + 0x80], rbx
jmp 0x180058ce0
cmp ebp, 0x12a
je 0x180058dcb
mov ecx, dword [rsp + 0x60]
cmp ebp, 0xa1e
jne 0x180058fb2
mov sil, 1
mov dword [rsp + 0x64], 0xffffffff
mov byte [rsp + 0x120], sil
jmp 0x180058cec
mov dword [r11], ebx
jmp 0x180058ce0
movzx eax, word [rdx]
mov r9, r10
mov word [rsp + 0x70], ax
xor edx, edx
lea rax, [rsp + 0x70]
xor ecx, ecx
mov r8d, 0xea
mov qword [rsp + 0x20], rax
call fcn.18003fd00
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rsp + 0x90], xmm0
mov qword [rsp + 0xb0], rax
movups xmmword [rsp + 0xa0], xmm0
jmp 0x180058cd0
cmp ebp, 0x5546
je 0x180058f64
cmp ebp, 0x5624
je 0x180058f1e
cmp ebp, 0xa965
je 0x180058ef8
cmp ebp, 0xab1e
je 0x180058ebd
cmp ebp, 0x10018
jne 0x180058ce0
mov esi, 0x62
cmp esi, 0x62
je 0x180058e6b
cmp esi, 0x106
jne 0x180058ea4
mov rax, rdi
jmp 0x1800590f9
mov eax, dword [r10]
lea rcx, [rsp + 0x70]
mov qword [rsp + 0x28], rbx
mov r9, r11
xor r8d, r8d
mov dword [rsp + 0x70], eax
xor edx, edx
mov dword [rsp + 0x20], 0xc2
call fcn.1800bebe0
mov r10, qword [rsp + 0x128]
mov rdi, rax
mov r11, qword [rsp + 0x110]
add esi, 0xa4
cmp esi, 0x1aa
jb 0x180058e56
movsxd r14, dword [r11]
add r14, r10
jmp 0x180058ce0
cmp dword [r10], 0xf
jbe 0x180058ce0
mov esi, 0x57
nop dword [rax]
cmp esi, 0x57
je 0x180058edc
cmp esi, 0x67
je 0x180058e63
jmp 0x180058eeb
xor edx, edx
mov ecx, 0x10003
call fcn.180025af0
mov rdi, rbx
add esi, 0x10
cmp esi, 0x77
jb 0x180058ed0
jmp 0x180058cd0
mov r9d, 0x2f
xor r8d, r8d
xor edx, edx
mov rcx, r14
call fcn.1800aa6a0
cmp al, 0xa
jne 0x180058f16
mov r14, qword [r14]
add r14, 8
mov rdi, r14
jmp 0x180058cd0
cmp byte [0x180183d71], bl
jne 0x180058ce0
mov esi, 0x6c
nop
cmp esi, 0x6c
je 0x180058f45
cmp esi, 0x180c
jne 0x180058f51
mov rax, rbx
jmp 0x1800590f9
xor edx, edx
mov ecx, 0x10001
call fcn.180025af0
add esi, 0x17a0
cmp esi, 0x2f40
jbe 0x180058f30
jmp 0x180058cd0
mov r9d, 0x2f
xor r8d, r8d
xor edx, edx
mov rcx, r14
call fcn.1800aa6a0
test al, al
jne 0x180058cd0
mov rdx, qword [rsp + 0x110]
mov r9, r14
mov r8, qword [rsp + 0x128]
mov ecx, 0x75
mov eax, dword [rdx]
lea rdx, [rsp + 0x120]
mov dword [rsp + 0x120], eax
call fcn.18012ddd0
jmp 0x1800590f9
movzx esi, byte [rsp + 0x120]
jmp 0x180058cec
mov rcx, qword [rsp + 0x68]
movzx esi, byte [rsp + 0x120]
mov byte [rsp + 0x120], sil
mov eax, dword [rsp + 0x120]
mov qword [rsp + 0x80], rcx
mov ecx, dword [rsp + 0x120]
mov dword [rsp + 0x64], eax
mov dword [rsp + 0x60], ecx
jmp 0x180058d07
mov rax, qword [rdx]
mov r9, r11
mov qword [rsp + 0x70], rax
xor r8d, r8d
lea rax, [rsp + 0x70]
xor edx, edx
mov qword [rsp + 0x28], rax
mov ecx, 0x83
mov qword [rsp + 0x20], r10
call fcn.18006ff20
mov r11, qword [rsp + 0x110]
mov r10, qword [rsp + 0x128]
mov ecx, dword [rsp + 0x60]
add r13d, 0xc1
cmp r13d, r12d
jae 0x1800590ee
mov rdx, qword [rsp + 0x118]
mov eax, dword [rsp + 0x64]
jmp 0x180058d36
mov ebp, 0xffffffff
jmp 0x180059034
mov rsi, rbx
nop
test dword [r11], ecx
je 0x1800590b7
xor r9d, r9d
mov qword [rsp + 0x20], rbx
mov r8, r10
mov edx, 0xc9
xor ecx, ecx
call fcn.1800966f0
xor edx, edx
xor ecx, ecx
test eax, eax
jne 0x180059261
mov r8, qword [rsp + 0x128]
mov r9d, 0xdd
mov qword [rsp + 0x20], rbx
call fcn.180141cf0
mov rdx, qword [rsp + 0x118]
mov r11, qword [rsp + 0x110]
mov ecx, dword [rsp + 0x60]
mov byte [rsi + rdx], al
mov r10, qword [rsp + 0x128]
inc rsi
sar ecx, 1
mov dword [rsp + 0x60], ecx
cmp rsi, 4
jl 0x180059060
movzx esi, byte [rsp + 0x120]
jmp 0x180059034
mov eax, r13d
sub eax, 0x108
je 0x18005910b
cmp eax, 0x1f
jne 0x180059034
mov rax, rdi
mov r12, qword [rsp + 0xc8]
add rsp, 0xd0
pop r15
pop r14
pop r13
pop rdi
pop rsi
pop rbp
pop rbx
ret
xor r9d, r9d
mov qword [rsp + 0x28], rbx
mov r8, r10
mov qword [rsp + 0x20], rbx
xor ecx, ecx
lea edx, [r9 + 6]
call fcn.1800d1460
mov rdx, qword [rsp + 0x110]
mov r8d, 1
xor ecx, ecx
call fcn.18004bee0
jmp 0x180059020
mov r14d, 0xffffffff
jmp 0x180059034
cmp r13d, 0x1b4
je 0x180059294
cmp r13d, 0x266
je 0x180059259
cmp r13d, 0x327
je 0x180059239
cmp r13d, 0x3e8
je 0x1800591dd
cmp r13d, 0x4a9
jne 0x180059034
test sil, sil
je 0x1800591b5
mov r8d, dword [rsp + 0x78]
lea rcx, [rsp + 0x90]
mov rdx, qword [rsp + 0x68]
call qword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorOwner]
mov r10, qword [rsp + 0x128]
mov r11, qword [rsp + 0x110]
lea rcx, [r10 + 0xa]
cmp rcx, r11
je 0x180059030
cmp qword [r11 + 0x18], 0x10
mov rdx, r11
jb 0x1800591cf
mov rdx, qword [r11]
mov r8, qword [r11 + 0x10]
call fcn.180041080
jmp 0x180059020
mov qword [rsp + 0x50], rbx
lea rcx, [rsp + 0x88]
mov qword [rsp + 0x48], rbx
mov r9d, r14d
mov qword [rsp + 0x40], rbx
mov r8d, ebp
mov qword [rsp + 0x38], rbx
mov edx, eax
mov qword [rsp + 0x30], rcx
mov rcx, qword [rsp + 0x80]
mov qword [rsp + 0x28], rbx
mov qword [rsp + 0x20], rbx
call qword [sym.imp.ADVAPI32.dll_ChangeServiceConfigA]
movzx eax, sil
test r15d, r15d
mov ecx, ebx
cmovne ecx, eax
movzx esi, cl
mov byte [rsp + 0x120], cl
jmp 0x180059020
lea r8, [rsp + 0x78]
lea rdx, [rsp + 0x68]
lea rcx, [rsp + 0x90]
call qword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorOwner]
mov r15d, eax
jmp 0x180059020
mov qword [r10], r8
jmp 0x180059034
mov dword [rsp + 0x40], 0x12a
lea r9, str.bad_file
mov qword [rsp + 0x38], rbx
xor r8d, r8d
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x28], rbx
mov qword [rsp + 0x20], rbx
call fcn.180113e50
mov rax, rbx
jmp 0x1800590f1
mov eax, 0xe7
nop dword [rax]
cmp eax, 0xe7
je 0x1800592b6
add eax, 0x45
cmp eax, 0x12c
jb 0x1800592a0
jmp 0x1800590ee
mov rax, rdx
jmp 0x1800590f1