Function at 0x405e60
Capabilities:
Create process on windows
Download url
Modify service
Print debug messages
Query service configuration
Query service status
Receive data
Start service

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x43594b
mov eax, dword fs:[0]
push eax
sub esp, 0x150
mov eax, dword [0x442c34]
xor eax, esp
mov dword [esp + 0x148], eax
push ebx
push esi
push edi
mov eax, dword [0x442c34]
xor eax, esp
push eax
lea eax, [esp + 0x160]
mov dword fs:[0], eax
mov edx, dword [0x446b8c]
mov ecx, dword [edx - 8]
mov eax, 1
sub eax, dword [edx - 4]
xor ebx, ebx
or ecx, eax
jge 0x405ec8
push ebx
mov ecx, 0x446b8c
call fcn.00404e40
mov edx, dword [0x446b8c]
push ebx
push edx
call fcn.00434ad1
add esp, 8
test eax, eax
je 0x405f0a
mov edx, dword [0x446b8c]
mov ecx, dword [edx - 8]
mov eax, 1
sub eax, dword [edx - 4]
or ecx, eax
jge 0x405efc
push ebx
mov ecx, 0x446b8c
call fcn.00404e40
mov edx, dword [0x446b8c]
push ebx
push ebx
push edx
push str.http:__update.xiaoxinrili.com_riliser.exe
push ebx
call sub.urlmon.dll_URLDownloadToFileA
mov edx, dword [0x446b8c]
mov ecx, dword [edx - 8]
mov eax, 1
sub eax, dword [edx - 4]
or ecx, eax
jge 0x405f30
push ebx
mov ecx, 0x446b8c
call fcn.00404e40
mov edx, dword [0x446b8c]
push ebx
push edx
call fcn.00434ad1
add esp, 8
test eax, eax
jne 0x406181
call fcn.00405df0
mov eax, dword [str.uriliSv]
mov ecx, dword [0x43aec4]
push 0x5c
lea edx, [esp + 0xf8]
push ebx
push edx
mov dword [esp + 0xf8], eax
mov dword [esp + 0xfc], ecx
call fcn.00421a10
add esp, 0xc
push 2
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
mov dword [esp + 0x14], edi
cmp edi, ebx
je 0x40621f
push 0xf01ff
lea eax, [esp + 0xf0]
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
cmp esi, ebx
je 0x4061a5
lea ecx, [esp + 0x40]
push ecx
push esi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
push 0x400
push 0x40
mov dword [esp + 0x24], ebx
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
lea edx, [esp + 0x1c]
push edx
push 0x400
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.00404ac0
mov dword [esp + 0x168], ebx
mov ecx, dword [esp + 0x18]
push ebx
push ecx
call fcn.00434ad1
add esp, 8
test eax, eax
je 0x4060e4
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.00421a10
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, 0x446b8c
call fcn.00404e90
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
mov eax, dword [esp + 0x14]
push eax
call esi
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x60]
push edx
push 0
push 0
push 0x80000
push 0
push 0
push 0
push str.__reg
push 0
mov ecx, 0x446b8c
call fcn.00404e90
push eax
call edi
mov eax, dword [esp + 0x20]
push 0xffffffffffffffff
push eax
call ebx
mov dword [esp + 0x168], 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 0x406181
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x406181
cmp dword [esp + 0x44], 1
jne 0x40610a
push ebx
push ebx
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
cmp eax, ebx
jne 0x4060ff
push 0x43aed8
jmp 0x406104
push 0x43aee8
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
cmp dword [edi + 4], 2
je 0x40613f
mov ecx, dword [esp + 0x14]
push ecx
call dword [sym.imp.ADVAPI32.dll_LockServiceDatabase]
push 0
push 0
push 0
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
push 2
push 0xffffffffffffffff
push esi
mov ebx, eax
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigA]
push ebx
call dword [sym.imp.ADVAPI32.dll_UnlockServiceDatabase]
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [esp + 0x168], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x406171
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edi, dword [esp + 0x14]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
mov ecx, dword [esp + 0x160]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x148]
xor ecx, esp
call fcn.0041dec5
mov esp, ebp
pop ebp
ret
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.00421a10
mov eax, dword [0x446b8c]
mov edx, 1
sub edx, dword [eax - 4]
add esp, 0xc
or edx, dword [eax - 8]
jge 0x4061f7
push ebx
mov ecx, 0x446b8c
call fcn.00404e40
mov eax, dword [0x446b8c]
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 0x406175
mov esi, dword [esp + 0x1c]
jmp 0x406175