Function at 0x404a50
Capabilities:
Create service
Persist via windows service
Set registry value

Disassembly:
sub esp, 0x218
push ebx
push ebp
push esi
push edi
push 0xf003f
mov ebx, ecx
push 0
push 0
mov dword [esp + 0x24], ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebp, eax
test ebp, ebp
mov dword [esp + 0x1c], ebp
jne 0x404a84
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x218
ret
lea eax, [esp + 0x124]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0
push 0
push 0
push 0
lea ecx, [esp + 0x134]
push 0
push ecx
push 1
push 3
add ebx, 4
push 0x10
push 0xf01ff
push ebx
push ebx
push ebp
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
test eax, eax
mov dword [esp + 0x14], eax
jne 0x404ade
push ebp
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x218
ret
mov edi, str.SYSTEMCurrentControlSetServicesEventLogApplication_
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov dword [esp + 0x10], 0
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x24]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x10]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x28]
push ecx
push reloc.WS2_32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
je 0x404b6d
mov edx, dword [esp + 0x14]
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push edx
call esi
push ebp
call esi
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x218
ret
lea edi, [esp + 0x124]
or ecx, 0xffffffff
xor eax, eax
mov ebp, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
repne scasb al, byte es:[edi]
not ecx
lea eax, [esp + 0x124]
push ecx
mov ecx, dword [esp + 0x14]
push eax
push 2
push 0
push str.EventMessageFile
push ecx
call ebp
mov eax, dword [esp + 0x10]
lea edx, [esp + 0x20]
push 4
push edx
push 4
push 0
push str.TypesSupported
push eax
mov dword [esp + 0x38], 7
call ebp
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edi, str.SYSTEMCurrentControlSetServices_
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x24]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
mov dword [esp + 0x10], eax
rep movsb byte es:[edi], byte [esi]
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x10]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
push 0x2001f
lea ecx, [esp + 0x2c]
push 0
push ecx
push reloc.WS2_32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x404c5c
mov edx, dword [esp + 0x10]
push 0x38
push 0x412734
push 1
push eax
push str.Description
push edx
call ebp
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [esp + 0x18]
push 0
push 0
push ebx
push 0x64
push 4
call fcn.00404930
mov ecx, dword [esp + 0x14]
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push ecx
call esi
mov edx, dword [esp + 0x1c]
push edx
call esi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x218
ret