Function at 0x14002cd6c
Capabilities:
Create service

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1020]
mov eax, 0x1120
call fcn.14003d0d0
sub rsp, rax
mov rax, qword [0x1400502a8]
xor rax, rsp
mov qword [rbp + 0x1010], rax
xor edi, edi
mov qword [rbp - 0x68], r8
or r15, 0xffffffffffffffff
mov qword [rbp - 0x78], rcx
mov r14, rdx
mov rsi, rcx
mov ebx, edi
cmp rcx, r15
je 0x14002ce7e
test rdx, rdx
je 0x14002ce7e
lea rax, [rsp + 0x70]
mov dword [rsp + 0x70], edi
mov qword [rsp + 0x30], rax
xor r9d, r9d
mov dword [rsp + 0x28], edi
xor r8d, r8d
xor edx, edx
mov qword [rsp + 0x20], rdi
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupGetLineTextW]
test eax, eax
je 0x14002ce4b
mov eax, dword [rsp + 0x70]
inc eax
mov ecx, eax
mov dword [rsp + 0x70], eax
lea eax, [rdi + 2]
mul rcx
cmovo rax, r15
mov rcx, rax
call fcn.14003c460
mov r12, rax
test rax, rax
je 0x14002ce7e
mov ecx, dword [rsp + 0x70]
xor r9d, r9d
mov qword [rsp + 0x30], rdi
xor r8d, r8d
mov dword [rsp + 0x28], ecx
xor edx, edx
mov rcx, r14
mov qword [rsp + 0x20], rax
call qword [sym.imp.SETUPAPI.dll_SetupGetLineTextW]
mov rcx, r12
test eax, eax
jne 0x14002ceaa
call fcn.14003c408
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r13d, 0x57
lea rdx, str.Failed_to_get_information_from_inf_with_error_code_0x_x._r_n
test eax, eax
cmove eax, r13d
movzx ebx, ax
lea ecx, [r13 - 0x53]
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov r8d, ebx
call fcn.1400168a8
mov eax, ebx
mov rcx, qword [rbp + 0x1010]
xor rcx, rsp
call fcn.14003c810
mov rbx, qword [rsp + 0x1178]
add rsp, 0x1120
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
lea rdx, [0x140043808]
call qword [sym.imp.msvcrt.dll_wcstok]
mov rdi, rax
test rax, rax
je 0x14002d307
mov r13d, 0x57
mov r8, rdi
lea rdx, str._Parsing_CreateServices_section:_S._r_n
mov ecx, 4
call fcn.1400168a8
mov r9, r14
xor r8d, r8d
mov rdx, rdi
mov rcx, rsi
call qword [sym.imp.SETUPAPI.dll_SetupFindFirstLineW]
test eax, eax
je 0x14002d2ec
mov rdx, rdi
mov rcx, rsi
mov r15d, 1
call qword [sym.imp.SETUPAPI.dll_SetupGetLineCountW]
mov ecx, eax
mov dword [rsp + 0x78], eax
mov edi, eax
call fcn.140015a28
cmp edi, r15d
jb 0x14002d2ec
xor esi, esi
mov ecx, r15d
call fcn.140015b2c
inc r15d
mov qword [rsp + 0x20], rsi
mov r9d, 0x105
mov dword [rsp + 0x74], r15d
lea r8, [rbp - 0x60]
mov edx, 1
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupGetStringFieldW]
test eax, eax
je 0x14002d2cf
mov r9d, 0x105
mov qword [rsp + 0x20], rsi
lea r8, [rbp + 0x9f0]
mov edx, 2
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupGetStringFieldW]
test eax, eax
je 0x14002d2cf
mov r9d, 0x105
mov qword [rsp + 0x20], rsi
lea r8, [rbp + 0x7e0]
mov edx, 3
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupGetStringFieldW]
test eax, eax
je 0x14002d2cf
mov r9d, 0x105
mov qword [rsp + 0x20], rsi
lea r8, [rbp + 0x3c0]
mov edx, 4
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupGetStringFieldW]
test eax, eax
je 0x14002d2cf
mov r9d, 0x105
mov qword [rsp + 0x20], rsi
lea r8, [rbp + 0x5d0]
mov edx, 5
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupGetStringFieldW]
test eax, eax
je 0x14002d2cf
mov r9d, 0x105
mov qword [rsp + 0x20], rsi
lea r8, [rbp + 0x1b0]
mov edx, 6
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupGetStringFieldW]
test eax, eax
je 0x14002d2cf
lea r8, [rsp + 0x7c]
mov qword [rbp - 0x80], rsi
lea rdx, [rbp - 0x80]
mov dword [rsp + 0x7c], esi
lea rcx, [rbp + 0x1b0]
mov rdi, rsi
call fcn.14002c708
mov r9d, dword [rsp + 0x7c]
mov r11d, esi
mov r15, qword [rbp - 0x80]
test r9d, r9d
jle 0x14002d0e9
mov rdx, r15
or rbx, 0xffffffffffffffff
mov r8, qword [rdx]
mov r10d, esi
mov rax, rbx
inc rax
cmp word [r8 + rax*2], si
jne 0x14002d063
test eax, eax
jle 0x14002d0a9
mov rcx, rsi
cmp rdi, 0x208
jge 0x14002d0e2
movzx eax, word [r8 + rcx]
inc r10d
mov word [rbp + rdi*2 + 0xc00], ax
inc rdi
mov r8, qword [rdx]
add rcx, 2
mov rax, rbx
inc rax
cmp word [r8 + rax*2], si
jne 0x14002d09a
cmp r10d, eax
jl 0x14002d074
cmp rdi, 0x208
jge 0x14002d0e2
lea rax, [rdi + rdi]
inc rdi
cmp rax, 0x410
jae 0x14002d314
inc r11d
mov word [rbp + rax + 0xc00], si
add rdx, 8
cmp r11d, r9d
jl 0x14002d05a
cmp rdi, 0x208
jl 0x14002d0e9
mov ebx, 0x80004005
jmp 0x14002d103
add rdi, rdi
mov ebx, esi
cmp rdi, 0x410
jae 0x14002d314
mov word [rbp + rdi + 0xc00], si
test r9d, r9d
jle 0x14002d12c
mov rdi, r15
mov rsi, r9
xor eax, eax
mov rcx, qword [rdi]
test rcx, rcx
je 0x14002d122
call fcn.14003c408
xor eax, eax
mov qword [rdi], rax
add rdi, 8
sub rsi, 1
jne 0x14002d110
test r15, r15
je 0x14002d139
mov rcx, r15
call fcn.14003c408
test ebx, ebx
js 0x14002d2c6
mov ebx, 0x10
lea rdx, [rbp - 0x70]
mov r8d, ebx
lea rcx, [rbp + 0x3c0]
call qword [sym.imp.msvcrt.dll_wcstol]
mov r15d, dword [rbp + 0x1080]
mov esi, eax
cmp r15d, 0xffffffff
jne 0x14002d186
mov r8d, ebx
lea rdx, [rbp - 0x70]
lea rcx, [rbp + 0x5d0]
call qword [sym.imp.msvcrt.dll_wcstol]
mov r15d, eax
mov dword [rbp + 0x1080], eax
xor edx, edx
xor ecx, ecx
mov r8d, 0xf003f
mov edi, 1
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
xor ecx, ecx
mov rbx, rax
test rax, rax
je 0x14002d260
mov qword [rsp + 0x60], rcx
lea rax, str.NT_AUTHORITYLocalService
mov qword [rsp + 0x58], rax
lea r8, [rbp + 0x9f0]
lea rax, [rbp + 0xc00]
mov r9d, 0xf003f
mov qword [rsp + 0x50], rax
lea rdx, [rbp - 0x60]
mov qword [rsp + 0x48], rcx
lea rax, [rbp + 0x7e0]
mov qword [rsp + 0x40], rcx
mov rcx, rbx
mov qword [rsp + 0x38], rax
mov dword [rsp + 0x30], edi
mov dword [rsp + 0x28], r15d
mov dword [rsp + 0x20], esi
call qword [sym.imp.ADVAPI32.dll_CreateServiceW]
xor esi, esi
test rax, rax
je 0x14002d22f
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
lea r9, str.succeeded
lea r8, [rbp - 0x60]
lea rdx, str.Creating_service__S__S._r_n
lea ecx, [rdi + 3]
call fcn.1400168a8
jmp 0x14002d255
mov edi, esi
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea r8, [rbp - 0x60]
mov ecx, 2
test eax, eax
lea rdx, str.ERROR:_Failed_to_create_service:__S.__Result:_0x_x._r_n
cmove eax, r13d
mov r9d, eax
call fcn.1400168a8
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x14002d286
xor esi, esi
mov edi, esi
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
lea r8, [rbp - 0x60]
lea rdx, str.ERROR:_Failed_to_open_SCM:__S.__Result:_0x_x._r_n
cmove eax, r13d
lea ecx, [rsi + 2]
mov r9d, eax
call fcn.1400168a8
test edi, edi
je 0x14002d28e
mov ebx, esi
jmp 0x14002d2a8
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
cmove eax, r13d
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test edi, edi
jne 0x14002d2b4
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x14002d2c6
mov rcx, qword [rbp - 0x68]
lea r8, [rbp - 0x60]
mov edx, 0x104
call fcn.140001470
mov r15d, dword [rsp + 0x74]
mov edi, dword [rsp + 0x78]
mov rdx, r14
mov rcx, r14
call qword [sym.imp.SETUPAPI.dll_SetupFindNextLine]
test eax, eax
je 0x14002d2e8
cmp r15d, edi
jbe 0x14002cf21
mov rsi, qword [rbp - 0x78]
lea rdx, [0x140043808]
xor ecx, ecx
call qword [sym.imp.msvcrt.dll_wcstok]
mov rdi, rax
test rax, rax
jne 0x14002cec9
mov rcx, r12
call fcn.14003c408
jmp 0x14002ce7e
call fcn.14003c9e8
int3