Function at 0x497180
Capabilities:
Get number of processors
Modify service
Persist via windows service
Query or enumerate registry value
Resolve function by parsing pe exports
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x581b28
mov eax, dword fs:[0]
push eax
sub esp, 0x64
push ebx
push ebp
push esi
push edi
mov eax, dword [0x5f4760]
xor eax, esp
push eax
lea eax, [esp + 0x78]
mov dword fs:[0], eax
xor ebx, ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x80], ebx
push ebx
lea eax, [esp + 0x34]
push eax
push ebx
push 0xf003f
push ebx
push ebx
push ebx
push str.SYSTEMCurrentControlSetServices360EntPublishSrv
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x50], 1
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov ebp, eax
cmp ebp, ebx
jne 0x497319
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea ecx, [esp + 0x1c]
push ecx
mov ecx, dword [esp + 0x34]
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x20]
push eax
push ebx
push str.ErrorControl
mov ebp, 4
push ecx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebp
call esi
lea edi, [ebx + 0x2c]
test eax, eax
jne 0x4972d4
cmp dword [esp + 0x18], ebp
jne 0x4972d4
cmp dword [esp + 0x24], 1
jne 0x4972d4
push edi
lea edx, [esp + 0x50]
push ebx
push edx
call fcn.004add60
add esp, 0xc
lea eax, [esp + 0x1c]
push eax
mov eax, dword [esp + 0x34]
lea ecx, [esp + 0x50]
push ecx
lea edx, [esp + 0x20]
push edx
push ebx
push str.FailureActions
push eax
mov dword [esp + 0x30], 3
mov dword [esp + 0x34], edi
call esi
cmp eax, ebx
jne 0x4972d4
cmp dword [esp + 0x18], 3
jne 0x4972d4
cmp dword [esp + 0x1c], edi
jne 0x4972d4
mov ecx, dword [0x5e01b0]
mov dword [esp + 0x5c], ecx
mov eax, edi
xor ecx, ecx
mov edi, edi
mov edx, dword [ecx + 0x5e01a0]
cmp edx, dword [esp + ecx + 0x4c]
jne 0x4972d4
sub eax, ebp
add ecx, ebp
cmp eax, ebp
jae 0x497290
mov dword [esp + 0x80], 0xffffffff
mov eax, dword [esp + 0x30]
cmp eax, ebx
je 0x4972be
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
mov ecx, dword [esp + 0x78]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x70
ret
mov ecx, dword [esp + 0x30]
mov esi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push ebp
lea eax, [esp + 0x30]
push eax
push ebp
push ebx
push str.ErrorControl
push ecx
mov dword [esp + 0x30], ebp
mov dword [esp + 0x34], ebp
call esi
mov edx, dword [esp + 0x30]
push edi
push 0x5e01a0
push 3
push ebx
push str.FailureActions
push edx
mov dword [esp + 0x30], 3
mov dword [esp + 0x34], edi
call esi
mov ebp, eax
push 0xf003f
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov edi, eax
mov dword [esp + 0x24], edi
mov byte [esp + 0x80], 1
cmp edi, ebx
jne 0x497344
mov byte [esp + 0x80], bl
jmp 0x4973f4
push 0xf01ff
push str.360EntPublishSrv
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov esi, eax
mov dword [esp + 0x1c], esi
mov byte [esp + 0x80], 2
cmp esi, ebx
jne 0x497377
mov byte [esp + 0x80], bl
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x4973f4
xor eax, eax
mov ecx, 1
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x54], ecx
mov dword [esp + 0x5c], ecx
mov eax, 0xea60
lea ecx, [esp + 0x38]
push ecx
mov dword [esp + 0x54], eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x64], eax
push 2
lea eax, [esp + 0x54]
push esi
mov dword [esp + 0x48], ebx
mov dword [esp + 0x44], 0x15180
mov dword [esp + 0x50], 3
mov dword [esp + 0x54], eax
mov dword [esp + 0x4c], ebx
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2W]
mov byte [esp + 0x80], 1
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
mov byte [esp + 0x80], bl
push edi
call esi
mov dword [esp + 0x80], 0xffffffff
mov eax, dword [esp + 0x30]
cmp eax, ebx
je 0x49740e
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebp
mov ecx, dword [esp + 0x78]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x70
ret