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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x402710
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xa38
push ebx
push esi
push edi
lea eax, [ebp - 0x14]
mov dword [ebp - 0x10], esp
xor edi, edi
push eax
mov dword [ebp - 0x14], 0x80000002
mov ecx, dword [ebp - 0x14]
push 1
push edi
push 0x401218
push ecx
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x20], edi
mov dword [ebp - 4], edi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, edi
je 0x401c48
lea edx, [ebp - 0x2c]
push 0x402770
push edx
mov dword [ebp - 0x2c], 0x402828
call sub.MSVCRT.dll__CxxThrowException
lea eax, [ebp - 0x30]
lea ecx, [ebp - 0x540]
push eax
mov eax, dword [ebp - 0x14]
lea edx, [ebp - 0x38]
push ecx
push edx
push edi
push 0x40137c
push eax
mov dword [ebp - 0x30], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov ecx, dword [ebp - 0x14]
mov esi, eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
cmp esi, edi
je 0x401c9a
lea edx, [ebp - 0x28]
push 0x402770
push edx
mov dword [ebp - 0x28], 0x401358
call sub.MSVCRT.dll__CxxThrowException
push 0xf003f
push edi
push edi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebx, eax
cmp ebx, edi
mov dword [ebp - 0x18], ebx
jne 0x401cc5
lea eax, [ebp - 0x24]
push 0x402770
push eax
mov dword [ebp - 0x24], 0x401348
call sub.MSVCRT.dll__CxxThrowException
lea ecx, [ebp - 0x644]
push 0x104
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
call fcn.004018f0
mov edx, dword [ebp + 0x14]
mov esi, eax
mov ecx, 0x41
xor eax, eax
lea edi, [ebp - 0x140]
push edx
rep stosd dword es:[edi], eax
mov dword [ebp - 0x1c], esi
call fcn.004016a0
mov edi, dword [sym.imp.USER32.dll_wsprintfA]
push eax
lea eax, [ebp - 0x140]
push 0x401340
push eax
call edi
push esi
lea ecx, [ebp - 0xa44]
push 0x401310
push ecx
call edi
add esp, 0x1c
mov edx, dword [ebp + 8]
push 0
push 0
push 0
push 0
push 0
push 0x4012e0
push 1
push 2
push 0x10
push 0xf01ff
push edx
push esi
push ebx
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov edi, eax
test edi, edi
mov dword [ebp - 0x20], edi
jne 0x401d64
lea eax, [ebp - 0x34]
push 0x402770
push eax
mov dword [ebp - 0x34], 0x4012c4
call sub.MSVCRT.dll__CxxThrowException
mov ebx, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push edi
call ebx
mov ecx, dword [ebp - 0x18]
push ecx
call ebx
push esi
lea edx, [ebp - 0x540]
push 0x40129c
push edx
mov dword [ebp - 0x14], 0x80000002
call dword [sym.imp.USER32.dll_wsprintfA]
mov eax, dword [ebp + 0xc]
add esp, 0xc
push 0
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
push 1
lea edx, [ebp - 0x540]
push 0x401290
push edx
push 0x80000002
call fcn.00402370
add esp, 0x1c
lea eax, [ebp - 0x540]
push 0x401284
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea ecx, [ebp - 0x140]
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea edx, [ebp - 0x140]
push eax
push edx
push 2
lea eax, [ebp - 0x540]
push 0x401278
push eax
push 0x80000002
call fcn.00402370
add esp, 0x1c
jmp 0x401e26
mov ecx, dword [ebp - 0x14]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push edi
call ebx
mov edx, dword [ebp - 0x18]
push edx
call ebx
test esi, esi
je 0x401e6c
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp + 0x18]
mov edx, dword [ebp + 0x10]
push eax
push ecx
lea eax, [ebp - 0x140]
push edx
push eax
push 0x401274
push 0x401270
push 0
call fcn.00401730
add esp, 0x1c
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret