Function at 0x10022810
Capabilities:
Get common file path
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x470
mov eax, dword [0x1004fa70]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov ecx, 8
mov esi, str.SYSTEMCurrentControlSetServices
lea edi, [ebp - 0x358]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
mov dword [ebp - 0x21c], 0
mov dword [ebp - 0x22c], 0
mov byte [ebp - 0x218], 0
push 0x103
push 0
lea eax, [ebp - 0x217]
push eax
call fcn.1002aa10
add esp, 0xc
mov byte [ebp - 0x110], 0
push 0x103
push 0
lea ecx, [ebp - 0x10f]
push ecx
call fcn.1002aa10
add esp, 0xc
lea edx, [ebp - 0x228]
push edx
push 0x20019
push 0
lea eax, [ebp - 0x358]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x10022bcd
mov dword [ebp - 0x224], 0
mov ecx, 1
test ecx, ecx
je 0x10022bc0
mov dword [ebp - 0x220], 0x100
push 0x100
push 0
lea edx, [ebp - 0x330]
push edx
call fcn.1002aa10
add esp, 0xc
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x220]
push eax
lea ecx, [ebp - 0x330]
push ecx
mov edx, dword [ebp - 0x224]
push edx
mov eax, dword [ebp - 0x228]
push eax
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
mov dword [ebp - 0x334], eax
cmp dword [ebp - 0x334], 0
jne 0x10022bb9
mov dword [ebp - 0x35c], 0
mov ecx, dword [ebp + 8]
push ecx
lea edx, [ebp - 0x330]
push edx
call fcn.1002c5b5
add esp, 8
test eax, eax
je 0x10022958
mov eax, dword [ebp - 0x224]
add eax, 1
mov dword [ebp - 0x224], eax
jmp 0x100228b9
lea ecx, [ebp - 0x358]
push ecx
call fcn.1002ae60
add esp, 4
add eax, 0x100
push eax
call fcn.1002b1c7
add esp, 4
mov dword [ebp - 0x35c], eax
lea edx, [ebp - 0x358]
push edx
call fcn.1002ae60
add esp, 4
add eax, 0x100
push eax
push 0
mov eax, dword [ebp - 0x35c]
push eax
call fcn.1002aa10
add esp, 0xc
lea ecx, [ebp - 0x358]
push ecx
mov edx, dword [ebp - 0x35c]
push edx
call fcn.1002b3f0
add esp, 8
push 0x1004172c
mov eax, dword [ebp - 0x35c]
push eax
call fcn.1002b3f0
add esp, 8
lea ecx, [ebp - 0x330]
push ecx
mov edx, dword [ebp - 0x35c]
push edx
call fcn.1002b3f0
add esp, 8
lea eax, [ebp - 0x360]
push eax
push 0x20019
push 0
mov ecx, dword [ebp - 0x35c]
push ecx
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x10022ba1
mov dword [ebp - 0x364], 1
push 0x104
push 0
lea edx, [ebp - 0x470]
push edx
call fcn.1002aa10
add esp, 0xc
mov dword [ebp - 0x220], 0x104
lea eax, [ebp - 0x220]
push eax
lea ecx, [ebp - 0x470]
push ecx
lea edx, [ebp - 0x364]
push edx
push 0
push str.ImagePath
mov eax, dword [ebp - 0x360]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10022b94
push 4
push str.___
lea ecx, [ebp - 0x470]
push ecx
call fcn.1002bfb7
add esp, 0xc
test eax, eax
jne 0x10022a96
lea edx, [ebp - 0x46c]
push edx
lea eax, [ebp - 0x218]
push eax
call fcn.1002b3e0
add esp, 8
jmp 0x10022b10
push 0xd
push str._SystemRoot__
lea ecx, [ebp - 0x470]
push ecx
call fcn.1002bfb7
add esp, 0xc
test eax, eax
jne 0x10022ac8
lea edx, [ebp - 0x463]
push edx
lea eax, [ebp - 0x218]
push eax
call fcn.1002b3f0
add esp, 8
jmp 0x10022b10
push 0xc
push str.SystemRoot_
lea ecx, [ebp - 0x470]
push ecx
call fcn.1002bfb7
add esp, 0xc
test eax, eax
jne 0x10022afa
lea edx, [ebp - 0x464]
push edx
lea eax, [ebp - 0x218]
push eax
call fcn.1002b3f0
add esp, 8
jmp 0x10022b10
lea ecx, [ebp - 0x470]
push ecx
lea edx, [ebp - 0x218]
push edx
call fcn.1002b3e0
add esp, 8
push 0x104
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push 3
lea ecx, [ebp - 0x218]
push ecx
lea edx, [ebp - 0x110]
push edx
call fcn.1002bfb7
add esp, 0xc
test eax, eax
jne 0x10022b53
lea eax, [ebp - 0x218]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1002b3e0
add esp, 8
jmp 0x10022b8a
lea edx, [ebp - 0x110]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1002b3e0
add esp, 8
push 0x1004172c
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.1002b3f0
add esp, 8
lea edx, [ebp - 0x218]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.1002b3f0
add esp, 8
mov dword [ebp - 0x22c], 1
mov ecx, dword [ebp - 0x360]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 0x35c], 0
je 0x10022bb9
mov edx, dword [ebp - 0x35c]
push edx
call fcn.1002b28a
add esp, 4
jmp 0x10022bc0
mov eax, dword [ebp - 0x228]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp - 0x22c]
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1002ae45
mov esp, ebp
pop ebp
ret