Function at 0x4127a0
Capabilities:
Delete registry value
Delete service
Persist via run registry key
Query service status
Stop service

Disassembly:
mov eax, dword [0x41e1c0]
sub esp, 0x24
dec eax
push ebx
push ebp
push esi
je 0x412943
dec eax
jne 0x4129f6
lea eax, [esp + 0xc]
push eax
push str.SoftwareMicrosoftWindowsCurrentVersionRun
push reloc.WSOCK32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov ebp, dword [sym.imp.USER32.dll_MessageBoxA]
test eax, eax
jne 0x41280a
mov ecx, dword [str.WinVNC]
mov edx, dword [esp + 0xc]
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
test eax, eax
je 0x4127ff
mov eax, dword [str.WinVNC]
push 0x30
push eax
push str.WARNING:The_ServiceHelper_hook_entry_could_not_be_removed_from_the_registry
push 0
call ebp
mov ecx, dword [esp + 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x10], ebx
je 0x412929
push 0xf01ff
push str.winvnc
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
je 0x412907
lea edx, [esp + 0x14]
push edx
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x4128a7
lea eax, [esp + 0x14]
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
push eax
push esi
call edi
test eax, eax
je 0x41288b
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [esp + 0x1c], 3
jne 0x412887
push 0x3e8
call ebx
lea ecx, [esp + 0x18]
push ecx
push esi
call edi
test eax, eax
jne 0x41286d
mov ebx, dword [esp + 0x14]
mov eax, dword [esp + 0x1c]
pop edi
cmp eax, 1
je 0x4128a7
mov edx, dword [str.WinVNC]
push 0x30
push edx
push str.The_WinVNC_service_could_not_be_stopped
push 0
call ebp
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
je 0x4128de
mov eax, dword [str.WinVNC]
push 0x40
push eax
push str.The_WinVNC_service_has_been_removed
call fcn.00412df0
add esp, 0xc
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret
mov ecx, dword [str.WinVNC]
push 0x30
push ecx
push str.The_WinVNC_service_could_not_be_removed
push 0
call ebp
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret
mov edx, dword [str.WinVNC]
push 0x30
push edx
push str.The_WinVNC_service_could_not_be_found
push 0
call ebp
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret
mov eax, dword [str.WinVNC]
push 0x30
push eax
push str.The_SCM_could_not_be_contacted___the_WinVNC_service_was_not_removed
push 0
call ebp
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret
lea ecx, [esp + 0xc]
push ecx
push str.SoftwareMicrosoftWindowsCurrentVersionRunServices
push reloc.WSOCK32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
je 0x4129b6
mov edx, dword [str.WinVNC]
mov esi, dword [sym.imp.USER32.dll_MessageBoxA]
push 0x30
push edx
push str.The_SCM_could_not_be_contacted___the_WinVNC_service_was_not_removed
push 0
call esi
call fcn.004120d0
test eax, eax
jne 0x412997
mov eax, dword [str.WinVNC]
push 0x30
push eax
push str.The_WinVNC_service_could_not_be_contacted
push 0
call esi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret
mov ecx, dword [str.WinVNC]
push 0x40
push ecx
push str.The_WinVNC_service_has_been_removed
call fcn.00412df0
add esp, 0xc
xor eax, eax
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov edx, dword [str.WinVNC]
mov eax, dword [esp + 0xc]
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
je 0x4129ef
mov ecx, dword [esp + 0xc]
push ecx
call esi
mov edx, dword [str.WinVNC]
push 0x30
push edx
push str.The_WinVNC_service_could_not_be_removed
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
mov eax, dword [esp + 0xc]
push eax
call esi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret