Function at 0x4014d0
Capabilities:
Delete registry key
Persist via windows service
Set registry value

Disassembly:
sub esp, 0x530
push ebx
push esi
mov esi, dword [esp + 0x544]
push edi
mov edi, dword [esp + 0x540]
push esi
push edi
call fcn.00401430
add esp, 8
test eax, eax
je 0x401504
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x530
ret
mov dword [esi], 0xffffffff
call fcn.004012a0
test eax, eax
jne 0x401526
push 0x10
push str.debugview
push str.enable_privilege_failed
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
push edi
lea eax, [esp + 0x2c]
push str.SystemCurrentControlSetServices_s
push eax
call fcn.004093c5
add esp, 0xc
lea ecx, [esp + 0xc]
lea edx, [esp + 0x28]
push ecx
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
je 0x40155e
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x530
ret
mov ecx, dword [esp + 0xc]
mov esi, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push ebp
lea eax, [esp + 0x14]
push 4
push eax
push 4
push 0
mov ebx, 1
push str.Type
push ecx
mov dword [esp + 0x2c], ebx
call esi
mov eax, dword [esp + 0x10]
lea edx, [esp + 0x14]
push 4
push edx
push 4
push 0
push str.ErrorControl
push eax
mov dword [esp + 0x2c], ebx
call esi
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push 4
push ecx
push 4
push 0
push str.Start
push edx
mov dword [esp + 0x2c], 3
call esi
mov eax, dword [esp + 0x548]
lea ecx, [esp + 0x338]
push eax
push str.___s
push ecx
call fcn.004093c5
lea edi, [esp + 0x344]
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea edx, [esp + 0x338]
push ecx
push edx
push ebx
push eax
mov eax, dword [esp + 0x20]
push str.ImagePath
push eax
call esi
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push str.RtlNtStatusToDosError
push str.ntdll.dll
call esi
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call edi
push str.RtlAnsiStringToUnicodeString
push str.ntdll.dll
mov dword [esp + 0x20], eax
call esi
push eax
call edi
push str.NtLoadDriver
push str.ntdll.dll
mov ebx, eax
call esi
push eax
call edi
push str.RtlFreeUnicodeString
push str.ntdll.dll
mov ebp, eax
call esi
push eax
call edi
mov edx, dword [esp + 0x544]
mov esi, eax
push edx
lea eax, [esp + 0x440]
push str.RegistryMachineSystemCurrentControlSetServices_s
push eax
call fcn.004093c5
lea ecx, [esp + 0x448]
lea edi, [esp + 0x448]
mov dword [esp + 0x34], ecx
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
repne scasb al, byte es:[edi]
not ecx
lea edx, [esp + 0x24]
push 1
lea eax, [esp + 0x20]
dec ecx
push edx
push eax
mov word [esp + 0x30], cx
call ebx
lea ecx, [esp + 0x1c]
push ecx
call ebp
lea edx, [esp + 0x1c]
mov edi, eax
push edx
call esi
lea eax, [esp + 0x2c]
lea ecx, [esp + 0x130]
push eax
push str._sEnum
push ecx
call fcn.004093c5
mov esi, dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
add esp, 0xc
lea edx, [esp + 0x130]
push edx
push 0x80000002
call esi
lea eax, [esp + 0x2c]
lea ecx, [esp + 0x130]
push eax
push str._sSecurity
push ecx
call fcn.004093c5
add esp, 0xc
lea edx, [esp + 0x130]
push edx
push 0x80000002
call esi
lea eax, [esp + 0x2c]
push eax
push 0x80000002
call esi
test edi, edi
pop ebp
je 0x40174e
cmp edi, 0xc000010e
je 0x40174e
cmp edi, 0xc0000035
je 0x40174e
push edi
call dword [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x530
ret
mov ebx, dword [esp + 0x540]
lea ecx, [esp + 0x230]
push ebx
push str.._s
push ecx
call fcn.004093c5
add esp, 0xc
mov edi, dword [sym.imp.KERNEL32.dll_CreateFileA]
lea edx, [esp + 0x230]
push 0
push 0x80
push 3
push 0
push 0
push 0xc0000000
push edx
call edi
mov esi, dword [esp + 0x548]
cmp eax, 0xffffffff
mov dword [esi], eax
jne 0x4017cf
push ebx
lea eax, [esp + 0x234]
push str..Global_s
push eax
call fcn.004093c5
add esp, 0xc
lea ecx, [esp + 0x230]
push 0
push 0x80
push 3
push 0
push 0
push 0xc0000000
push ecx
call edi
mov dword [esi], eax
mov ecx, dword [esi]
xor eax, eax
cmp ecx, 0xffffffff
pop edi
pop esi
pop ebx
setne al
add esp, 0x530
ret