Function at 0x40cfb0
Capabilities:
Create process on windows
Modify service
Print debug messages
Query service configuration
Query service status
Start service

Disassembly:
push 0xffffffffffffffff
push 0x43342b
mov eax, dword fs:[0]
push eax
sub esp, 0x144
mov eax, dword [0x43fc34]
xor eax, esp
mov dword [esp + 0x140], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x43fc34]
xor eax, esp
push eax
lea eax, [esp + 0x158]
mov dword fs:[0], eax
mov edx, dword [0x443c08]
mov ecx, dword [edx - 8]
mov eax, 1
sub eax, dword [edx - 4]
xor ebx, ebx
or ecx, eax
jge 0x40d013
push ebx
mov ecx, 0x443c08
call fcn.00404e30
mov edx, dword [0x443c08]
push ebx
push edx
call fcn.004325ed
add esp, 8
test eax, eax
jne 0x40d2c7
call fcn.0040cf40
mov eax, dword [str.KantuSv]
mov ecx, dword [0x439330]
push 0x5c
lea edx, [esp + 0xf8]
push ebx
push edx
mov dword [esp + 0xf8], eax
mov dword [esp + 0xfc], ecx
call fcn.00420f90
add esp, 0xc
push 2
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebp, eax
cmp ebp, ebx
je 0x40d2b7
push 0xf01ff
lea eax, [esp + 0xf0]
push eax
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
cmp esi, ebx
je 0x40d240
lea ecx, [esp + 0x40]
push ecx
push esi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
push 0x1000
push 0x40
mov dword [esp + 0x24], ebx
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
lea edx, [esp + 0x1c]
push edx
push 0x1000
mov edi, eax
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_QueryServiceConfigA]
mov eax, dword [edi + 0xc]
push eax
lea ecx, [esp + 0x1c]
call fcn.00404a80
mov dword [esp + 0x160], ebx
mov ecx, dword [esp + 0x18]
push ebx
push ecx
call fcn.004325ed
add esp, 8
test eax, eax
je 0x40d1bf
push 0x44
xor eax, eax
lea edx, [esp + 0x64]
push ebx
push edx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x68], 0x48
call fcn.00420f90
add esp, 0xc
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x60]
push ecx
push ebx
push ebx
push 0x80000
push ebx
push ebx
push ebx
push str.__unreg
push ebx
mov ecx, 0x443c08
call fcn.00404e80
mov edi, dword [sym.imp.KERNEL32.dll_CreateProcessA]
push eax
call edi
mov edx, dword [esp + 0x20]
mov ebx, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0xffffffffffffffff
push edx
call ebx
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push ebp
call esi
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x60]
push ecx
push 0
push 0
push 0x80000
push 0
push 0
push 0
push str.__reg
push 0
mov ecx, 0x443c08
call fcn.00404e80
push eax
call edi
mov edx, dword [esp + 0x20]
push 0xffffffffffffffff
push edx
call ebx
mov dword [esp + 0x160], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d2c7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x40d2c7
cmp dword [esp + 0x44], 1
jne 0x40d1e5
push ebx
push ebx
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
cmp eax, ebx
jne 0x40d1da
push 0x439344
jmp 0x40d1df
push 0x439354
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
cmp dword [edi + 4], 2
je 0x40d20f
push ebp
call dword [sym.imp.ADVAPI32.dll_LockServiceDatabase]
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0xffffffffffffffff
push 2
push 0xffffffffffffffff
push esi
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigA]
push edi
call dword [sym.imp.ADVAPI32.dll_UnlockServiceDatabase]
mov dword [esp + 0x160], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d2bb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x40d2bb
push 0x44
xor eax, eax
lea ecx, [esp + 0xac]
push ebx
push ecx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0xb0], 0x48
call fcn.00420f90
mov eax, dword [0x443c08]
mov edx, 1
sub edx, dword [eax - 4]
add esp, 0xc
or edx, dword [eax - 8]
jge 0x40d292
push ebx
mov ecx, 0x443c08
call fcn.00404e30
mov eax, dword [0x443c08]
lea ecx, [esp + 0x30]
push ecx
lea edx, [esp + 0xa8]
push edx
push ebx
push ebx
push 0x80000
push ebx
push ebx
push ebx
push str.__reg
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
jmp 0x40d2bb
mov esi, dword [esp + 0x1c]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push ebp
call esi
mov ecx, dword [esp + 0x158]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x140]
xor ecx, esp
call fcn.0041d795
add esp, 0x150
ret