Function at 0x406e20
Capabilities:
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
push edi
xor edi, edi
push esi
lea esi, [ebp - 0x220]
push ebx
mov ebx, eax
mov eax, esi
shr eax, 0x10
sub esp, 0x25c
mov dword [ebp - 0x248], eax
jmp 0x406e58
test byte [global___dbch.0], 2
jne 0x406fe0
add edi, 1
mov dword [esp + 0xc], 0x104
mov dword [esp + 8], esi
mov dword [esp + 4], edi
mov eax, dword [ebx]
mov dword [esp], eax
call sym._RegEnumKeyW_16
sub esp, 0x10
cmp eax, 0x103
je 0x4070c8
test eax, eax
jne 0x406e48
lea eax, [ebp - 0x22c]
mov dword [esp], esi
mov dword [esp + 4], eax
call dbg.service_create
test eax, eax
jne 0x4070c8
test byte [global___dbch.0], 8
jne 0x407018
lea eax, [ebp - 0x228]
mov dword [esp + 0xc], 0x20019
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0
mov dword [esp + 4], esi
mov eax, dword [ebx]
mov dword [esp], eax
call sym._RegOpenKeyExW_20
mov edx, eax
mov eax, dword [ebp - 0x22c]
sub esp, 0x14
mov dword [ebp - 0x23c], eax
test edx, edx
jne 0x406fb7
mov ecx, dword [ebp - 0x228]
add eax, 0x40
mov dword [ebp - 0x224], 0
mov dword [ebp - 0x240], ecx
mov dword [esp + 0xc], eax
mov dword [esp + 8], 1
mov dword [esp + 4], str.ImagePath
mov dword [esp], ecx
call dbg.load_reg_string
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 8], 0
mov dword [esp + 4], str.Group
add eax, 0x44
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_string
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 8], 1
mov dword [esp + 4], str.ObjectName
add eax, 0x50
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_string
test eax, eax
mov dword [ebp - 0x244], eax
je 0x4070e7
lea esi, [esi]
mov eax, dword [ebp - 0x228]
mov dword [esp], eax
call sym._RegCloseKey_4
mov edx, dword [ebp - 0x244]
sub esp, 4
test byte [global___dbch.0], 2
jne 0x407080
mov eax, dword [ebp - 0x23c]
mov dword [esp], eax
call dbg.free_service_entry
jmp 0x406e55
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Error__ld_reading_key__d_name___skipping_n
mov dword [esp + 8], global___FUNCTION__.27
mov dword [esp + 4], global___dbch.0
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x406e55
mov eax, dword [ebp - 0x248]
test eax, eax
je 0x4070d2
mov dword [esp + 4], 0xffffffff
mov dword [esp], esi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, eax
sub esp, 8
mov eax, 0x41ac0d
test edx, edx
jne 0x40704c
mov eax, esi
call sym._wine_dbgstr_wn.part.0.constprop.0
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Loading_service__s_n
mov dword [esp + 8], global___FUNCTION__.27
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x406eab
mov eax, esi
mov dword [ebp - 0x240], edx
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0x14], eax
mov edx, dword [ebp - 0x240]
mov dword [esp + 0xc], str.Error__ld_reading_registry_key_for_service__s___skipping_n
mov dword [esp + 0x10], edx
mov dword [esp + 8], global___FUNCTION__.27
mov dword [esp + 4], global___dbch.0
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x406fc4
lea esp, [ebp - 0xc]
xor eax, eax
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 4], esi
mov dword [esp], 0x41ac00
call sym._wine_dbg_sprintf.constprop.0_1
jmp 0x40704c
mov eax, dword [ebp - 0x23c]
mov dword [esp + 4], str.DisplayName
add eax, 0x54
mov dword [esp + 0xc], eax
xor eax, eax
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_string
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
xor ecx, ecx
mov dword [esp + 4], str.Description
mov dword [esp + 8], ecx
add eax, 0x5c
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_string
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 8], 1
mov dword [esp + 4], str.DependOnService
add eax, 0x60
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_multisz
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
xor edx, edx
mov dword [esp + 4], str.DependOnGroup
mov dword [esp + 8], edx
add eax, 0x64
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_multisz
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 4], str.Type
add eax, 0x34
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_dword
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 4], str.Start
add eax, 0x38
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_dword
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 4], str.ErrorControl
add eax, 0x3c
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_dword
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 4], 0x41b5c0
add eax, 0x48
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_dword
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
mov eax, dword [ebp - 0x23c]
mov dword [esp + 4], str.PreshutdownTimeout
add eax, 0x58
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_dword
test eax, eax
mov dword [ebp - 0x244], eax
jne 0x406fa0
lea edx, [ebp - 0x224]
mov dword [esp + 4], str.WOW64
mov dword [esp + 8], edx
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_dword
lea edx, [ebp - 0x224]
test eax, eax
jne 0x4072fa
cmp dword [ebp - 0x224], 1
jne 0x4072fa
mov eax, dword [ebp - 0x23c]
mov dword [eax + 0x78], 1
mov dword [esp + 8], edx
mov dword [esp + 4], str.DelayedAutoStart
mov eax, dword [ebp - 0x240]
mov dword [esp], eax
call dbg.load_reg_dword
test eax, eax
jne 0x40732e
cmp dword [ebp - 0x224], 1
jne 0x40732e
mov eax, dword [ebp - 0x23c]
mov dword [eax + 0x7c], 1
movzx ecx, byte [global___dbch.0]
test cl, 8
jne 0x407547
mov eax, dword [ebp - 0x23c]
mov edx, dword [eax + 0x60]
xchg ebx, edx
mov eax, ecx
and eax, 8
cmp word [ebx], 0
je 0x4073ae
test al, al
jne 0x40736a
mov eax, ebx
jmp 0x40735f
add eax, 2
cmp word [eax], 0
jne 0x40735c
lea ebx, [eax + 2]
jmp 0x407349
mov eax, ebx
mov dword [ebp - 0x240], edx
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.______s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
movzx ecx, byte [global___dbch.0]
mov edx, dword [ebp - 0x240]
jmp 0x407358
mov ebx, edx
test al, al
je 0x4073f6
mov eax, dword [ebp - 0x23c]
mov edx, 0x41add6
mov eax, dword [eax + 0x64]
cmp word [eax], 0
mov eax, str._none_
mov dword [esp + 0xc], str.Group_dependencies___:__s_n
cmovne eax, edx
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp + 0x10], eax
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
mov eax, dword [ebp - 0x23c]
mov edx, dword [eax + 0x64]
xchg ebx, edx
cmp word [ebx], 0
je 0x407460
test byte [global___dbch.0], 8
jne 0x407422
mov eax, ebx
jmp 0x407417
add eax, 2
cmp word [eax], 0
jne 0x407414
lea ebx, [eax + 2]
jmp 0x407401
mov eax, ebx
mov dword [ebp - 0x240], edx
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.______s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
mov edx, dword [ebp - 0x240]
jmp 0x407410
mov eax, dword [ebp - 0x228]
mov ebx, edx
mov dword [esp], eax
call sym._RegCloseKey_4
mov eax, dword [ebp - 0x23c]
sub esp, 4
mov eax, dword [eax + 0x34]
test eax, eax
jne 0x4074c8
test byte [global___dbch.0], 8
je 0x406fc4
mov eax, esi
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.Even_the_service_type_not_set_for_service__s___skipping_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], global___FUNCTION__.27
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
jmp 0x406fc4
mov eax, dword [ebp - 0x23c]
mov dword [esp], eax
call dbg.validate_service_config
test eax, eax
jne 0x40751b
test byte [global___dbch.0], 2
je 0x406fc4
mov eax, esi
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.Invalid_configuration_of_service__s___skipping_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], global___FUNCTION__.27
mov dword [esp + 4], global___dbch.0
mov dword [esp], 1
call sym._wine_dbg_log.constprop.0_1
jmp 0x406fc4
mov ecx, dword [ebp - 0x23c]
mov eax, dword [ecx + 0x34]
mov dword [ecx + 8], ebx
mov dword [ecx + 0x14], eax
lea eax, [ebx + 0x10]
mov dword [ecx], eax
mov eax, dword [ebx + 0x14]
mov dword [ecx + 4], eax
mov dword [eax], ecx
mov dword [ebx + 0x14], ecx
mov dword [esp], ecx
call dbg.release_service
jmp 0x406e55
mov eax, dword [ebp - 0x23c]
mov eax, dword [eax + 0x40]
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.Image_path_____________s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
movzx ecx, byte [global___dbch.0]
test cl, 8
je 0x40733e
mov eax, dword [ebp - 0x23c]
mov eax, dword [eax + 0x44]
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.Group__________________s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
movzx ecx, byte [global___dbch.0]
test cl, 8
je 0x40733e
mov eax, dword [ebp - 0x23c]
mov eax, dword [eax + 0x50]
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.Service_account_name___s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
movzx ecx, byte [global___dbch.0]
test cl, 8
je 0x40733e
mov eax, dword [ebp - 0x23c]
mov eax, dword [eax + 0x54]
call sym._wine_dbgstr_wn.constprop.0_1
mov dword [esp + 0xc], str.Display_name___________s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
movzx ecx, byte [global___dbch.0]
test cl, 8
je 0x40733e
mov eax, dword [ebp - 0x23c]
mov edx, 0x41add6
mov eax, dword [eax + 0x60]
cmp word [eax], 0
mov eax, str._none_
mov dword [esp + 0xc], str.Service_dependencies_:__s_n
cmovne eax, edx
mov dword [esp + 8], str.load_service_config
mov dword [esp + 4], global___dbch.0
mov dword [esp + 0x10], eax
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0_1
movzx ecx, byte [global___dbch.0]
jmp 0x40733e