Function at 0x408cec
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffdb0
xor edx, edx
mov dword [ebp - 0x24c], edx
mov dword [ebp - 0x250], edx
mov dword [ebp - 0x248], edx
mov dword [ebp - 0x234], edx
mov dword [ebp - 8], edx
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x20], edx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x408f06
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x44]
lea eax, [ebp - 0x14]
call sub.RtlVcl160.bpl__System__IntfClear_qqrr45System__DelphiInterface_t17System_IInterface_
push eax
push 0x408f14
push 1
push 0
mov eax, dword [sym.imp.RtlVcl160.bpl__Winapi_Activex_CLSID_StdComponentCategoryMgr]
push eax
call sub.ole32.dll_CoCreateInstance
mov dword [ebp - 0x10], eax
test byte [ebp - 0xd], 0x80
jne 0x408db4
lea eax, [ebp - 8]
call sub.RtlVcl160.bpl__System__IntfClear_qqrr45System__DelphiInterface_t17System_IInterface_
push eax
push 0
push 0
mov eax, dword [sym.imp.PublicPkg160.bpl__Datasnap_Midconst_CATID_MIDASInterceptor]
push eax
push 1
mov eax, dword [ebp - 0x14]
push eax
mov eax, dword [eax]
call dword [eax + 0x14]
call sub.RtlVcl160.bpl__System_Win_Comobj_OleCheck_qqrl
jmp 0x408d98
lea edx, [ebp - 0x234]
lea eax, [ebp - 0x30]
call sub.RtlVcl160.bpl__System_Win_Comobj_ClassIDToProgID_qqrrx5_GUID
mov edx, dword [ebp - 0x234]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx + 0x38]
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x30]
push eax
push 1
mov eax, dword [ebp - 8]
push eax
mov eax, dword [eax]
call dword [eax + 0xc]
test eax, eax
je 0x408d7c
jmp 0x408ec5
lea eax, [ebp - 0x1c]
push eax
push 0x20019
push 0
push 0x408f24
push 0x80000000
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x408ec5
xor eax, eax
push ebp
push 0x408ebe
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
mov dword [ebp - 0x18], eax
jmp 0x408e86
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x230]
mov dword [ebp - 0x244], eax
mov byte [ebp - 0x240], 0xa
lea edx, [ebp - 0x248]
mov eax, dword [sym.imp.PublicPkg160.bpl__Datasnap_Midconst_CATID_MIDASInterceptor]
call sub.RtlVcl160.bpl__System_Win_Comobj_GUIDToString_qqrrx5_GUID
mov eax, dword [ebp - 0x248]
mov dword [ebp - 0x23c], eax
mov byte [ebp - 0x238], 0x11
lea edx, [ebp - 0x244]
mov ecx, 1
mov eax, 0x408f3c
call sub.RtlVcl160.bpl__System_Sysutils_Format_qqrx20System_UnicodeStringpx14System_TVarRecxi
lea eax, [ebp - 0x250]
lea edx, [ebp - 0x230]
mov ecx, pe_nt_image_headers32
call sub.RtlVcl160.bpl__System__UStrFromWArray_qqrr20System_UnicodeStringpbi
mov eax, dword [ebp - 0x250]
lea edx, [ebp - 0x244]
call sub.RtlVcl160.bpl__System_Win_Comobj_StringToGUID_qqrx20System_UnicodeString
lea eax, [ebp - 0x244]
lea edx, [ebp - 0x24c]
call sub.RtlVcl160.bpl__System_Win_Comobj_ClassIDToProgID_qqrrx5_GUID
mov edx, dword [ebp - 0x24c]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx + 0x38]
inc dword [ebp - 0x18]
push 0x200
lea eax, [ebp - 0x230]
push eax
mov eax, dword [ebp - 0x18]
push eax
mov eax, dword [ebp - 0x1c]
push eax
call sub.advapi32.dll_RegEnumKeyW
test eax, eax
je 0x408dee
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408ec5
mov eax, dword [ebp - 0x1c]
push eax
call sub.advapi32.dll_RegCloseKey
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408f0d
lea eax, [ebp - 0x250]
mov edx, 3
call sub.RtlVcl160.bpl__System__UStrArrayClr_qqrpvi
lea eax, [ebp - 0x234]
call sub.RtlVcl160.bpl__System__UStrClr_qqrpv
lea eax, [ebp - 0x20]
call sub.RtlVcl160.bpl__System__UStrClr_qqrpv
lea eax, [ebp - 0x14]
call sub.RtlVcl160.bpl__System__IntfClear_qqrr45System__DelphiInterface_t17System_IInterface_
lea eax, [ebp - 8]
call sub.RtlVcl160.bpl__System__IntfClear_qqrr45System__DelphiInterface_t17System_IInterface_
ret